CRAN Package Check Results for Package snic

Last updated on 2026-11-11 12:51:16 CET.

Flavor Version Tinstall Tcheck Ttotal Status Flags
r-devel-linux-x86_64-debian-clang 0.6.1 5.88 49.41 55.29 ERROR
r-devel-linux-x86_64-debian-gcc 0.6.1 4.12 40.28 44.40 ERROR
r-devel-linux-x86_64-fedora-clang 0.6.1 OK
r-devel-linux-x86_64-fedora-gcc 0.6.1 145.69 OK
r-devel-windows-x86_64 0.6.1 10.00 315.00 325.00 OK
r-patched-linux-x86_64 0.6.1 OK
r-release-linux-x86_64 0.6.1 5.41 171.60 177.01 OK
r-release-macos-arm64 0.6.1 2.00 51.00 53.00 OK
r-release-macos-x86_64 0.6.1 5.00 167.00 172.00 OK
r-release-windows-x86_64 0.6.1 13.00 216.00 229.00 OK
r-oldrel-macos-arm64 0.6.1 OK
r-oldrel-macos-x86_64 0.6.1 5.00 243.00 248.00 OK
r-oldrel-windows-x86_64 0.6.1 15.00 262.00 277.00 OK

Check Details

Version: 0.6.1
Check: examples
Result: ERROR Running examples in ‘snic-Ex.R’ failed The error most likely occurred in: > base::assign(".ptime", proc.time(), pos = "CheckExEnv") > ### Name: snic > ### Title: Simple Non-Iterative Clustering (SNIC) segmentation > ### Aliases: snic > > ### ** Examples > > # Example 1: Geospatial raster > if (requireNamespace("terra", quietly = TRUE) && terra_is_working()) { + path <- system.file("demo-geotiff", package = "snic", mustWork = TRUE) + files <- file.path( + path, + c( + "S2_20LMR_B02_20220630.tif", + "S2_20LMR_B04_20220630.tif", + "S2_20LMR_B08_20220630.tif", + "S2_20LMR_B12_20220630.tif" + ) + ) + + # Downsample for speed (optional) + s2 <- terra::aggregate(terra::rast(files), fact = 8) + + # Generate a regular grid of seeds (lat/lon because CRS is present) + seeds <- snic_grid( + s2, + type = "rectangular", + spacing = 10L, + padding = 18L + ) + + # Run segmentation + seg <- snic(s2, seeds, compactness = 0.25) + + # Visualize RGB composite with seeds and segment boundaries + snic_plot( + s2, + r = 4, g = 3, b = 1, + stretch = "lin", + seeds = seeds, + seg = seg + ) + } > > # Example 2: In-memory image (JPEG) + Lab transform > # Uses an example image shipped with the package (no terra needed) > if (requireNamespace("jpeg", quietly = TRUE)) { + img_path <- system.file( + "demo-jpeg/clownfish.jpeg", + package = "snic", + mustWork = TRUE + ) + rgb <- jpeg::readJPEG(img_path) # h x w x 3 in [0, 1] + + # Convert sRGB -> CIE Lab for perceptual clustering + dims <- dim(rgb) + dim(rgb) <- c(dims[1] * dims[2], dims[3]) + lab <- grDevices::convertColor( + rgb, + from = "sRGB", + to = "Lab", + scale.in = 1, + scale.out = 1 / 255 + ) + dim(lab) <- dims + dim(rgb) <- dims + + # Seeds in pixel coordinates for array inputs + seeds_rc <- snic_grid(lab, type = "hexagonal", spacing = 20L) + + # Segment in Lab space and plot L channel with boundaries + seg <- snic(lab, seeds_rc, compactness = 0.1) + + snic_plot( + rgb, + r = 1L, + g = 2L, + b = 3L, + seg = seg, + seg_plot_args = list( + border = "black" + ) + ) + } Error in loadNamespace(x) : there is no package called ‘terra’ Calls: snic_plot ... loadNamespace -> withRestarts -> withOneRestart -> doWithOneRestart Execution halted Flavors: r-devel-linux-x86_64-debian-clang, r-devel-linux-x86_64-debian-gcc

Version: 0.6.1
Check: re-building of vignette outputs
Result: ERROR Error(s) in re-building vignettes: ... --- re-building ‘snic-array-pipeline.Rmd’ using rmarkdown Quitting from snic-array-pipeline.Rmd:54-56 [array-image-rgb] ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ <error/rlang_error> Error in `loadNamespace()`: ! there is no package called 'terra' --- Backtrace: ▆ 1. ├─snic::snic_plot(rgb, r = 1, g = 2, b = 3) 2. │ ├─snic:::.arr_to_x(.rast_tmpl(x), .x_to_arr(x)) 3. │ └─snic:::.rast_tmpl(x) 4. └─base::loadNamespace(x) 5. └─base::withRestarts(stop(cond), retry_loadNamespace = function() NULL) 6. └─base (local) withOneRestart(expr, restarts[[1L]]) 7. └─base (local) doWithOneRestart(return(expr), restart) ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Error: processing vignette 'snic-array-pipeline.Rmd' failed with diagnostics: there is no package called 'terra' --- failed re-building ‘snic-array-pipeline.Rmd’ --- re-building ‘snic-spatraster-pipeline.Rmd’ using rmarkdown [WARNING] Deprecated: --mathjax. Use --math-method=mathjax[:URL] instead. --- finished re-building ‘snic-spatraster-pipeline.Rmd’ SUMMARY: processing the following file failed: ‘snic-array-pipeline.Rmd’ Error: Vignette re-building failed. Execution halted Flavors: r-devel-linux-x86_64-debian-clang, r-devel-linux-x86_64-debian-gcc