I'm using the Orfeo Toolbox for segementation of large Very High Resolution Satellite images. It performs very well and i'm mostly very happy with it. But I still get some weird/bad results that I assume are related to the partition of the process in tiles.
I'm doing this:
#Segmentation variables
spatialr = '7'
maxiter = '6000'
ranger = '2,6'
minsize = '8000'
tilesize = '1048'
simplify = '0.4'
# SEGMENTATION
print "Performing image segmentation"
app = otbApplication.Registry.CreateApplication("Segmentation")
app.SetParameterString("in", imagem_base_com_ndvi)
app.SetParameterString("filter.meanshift.spatialr", spatialr)
app.SetParameterString("filter.meanshift.maxiter", maxiter)
app.SetParameterString("filter.meanshift.ranger", ranger)
app.SetParameterString("filter.meanshift.minsize", minsize)
app.SetParameterString("mode.vector.inmask", image_mask)
app.SetParameterString("mode.vector.stitch", 'True')
app.SetParameterString("mode.vector.out", vector_out)
app.SetParameterString("mode.vector.simplify", simplify)
app.SetParameterString("mode.vector.outmode", 'ovw')
app.SetParameterString("mode.vector.tilesize", tilesize)
app.SetParameterString("mode.vector.neighbor", 'True')
app.ExecuteAndWriteOutput()
Here are some examples of the resulting segmentation:
Anyone has ideas to help me avoid these errors?
Thanks.