# Folder containing the python.exe file used by ArcGIS 10.x
# Replace this with your own folder
arcgisPython <- "C:/Python27/ArcGIS10.x"
# A multiband raster with features used for segmentation
inputSegmFeat <- "C:/Users/MyUserName/MyFiles/myRaster.tif"
segmentation_ArcGIS_MShift(inputSegmFeat,
outputSegmRst = "C:/Users/MyUserName/MyFiles/outSegm.tif", # Output segmented raster - change this
SpectralDetail = 12.3, # Change this
SpatialDetail = 15, # Change this
MinSegmentSize = 25, # Change this
pythonPath = arcgisPython,
verbose = TRUE)
devtools::install_bitbucket("joao_goncalves/segoptim")
library(SegOptim)
# See the help page for the function?segmentation_OTB_LSMS
outSegmRst <- segmentation_OTB_LSMS(
inputRstPath = "C:/Users/User/MyFiles/inputSegFeat.tif"
SpectralRange = 3.1, SpatialRange = 4.5,
MinSize = 20,
outputSegmRst = "C:/Users/User/MyFiles/segmentedRaster.tif",
verbose = TRUE,
otbBinPath = "C:/OTB/bin",
lsms_maxiter = 20,
tilesizex = 3500,
tilesizey = 3500,
RAM = 4096) # <- The available memory option here
remove.packages("SegOptim")
devtools::install_bitbucket("joao_goncalves/segoptim")
(...)
** building package indices
** testing if installed package can be loaded
*** arch - i386
*** arch - x64
* DONE (SegOptim)
In R CMD INSTALLlibrary(SegOptim)
?segmentation_OTB_LSMS
# Arguments
# (...)
#RAM Available memory for processing the image data (in MB).