[GRASS-user] Question to the input seed grid of i.segment
Raphael Knevels
raphael.knevels at uni-jena.de
Tue Jan 24 11:40:57 PST 2017
Thanks for the quick response :-)
The extent of my region is also the extent of my imagery-group. For i.segment I used as memory 10240 MB with a threshold of 0.25.
In SAGA I used at first Seed Generation (Band Width of 18, but I also varied this parameter) for producing the Seed Output. The Seed Output is a raster with floating point values. Moreover, the Seed Output contains single pixels distributed over the hole area. The "space" between those pixels is "no data". The segmentation is then computed by Seeded Region Growing with the seed grid as input.
"Seeds in i.segment have to be polygons not points. These polygons are represented by identical positive integer values (= IDs) in adjacent pixels, and they have to cover the entire region. When used as seeds for a segmentation, these polygons are the further merged."
-> alright. That means, I definitely must convert the no data values in the SAGA Seed Output to zero or any other integer number.
Meanwhile, I also tried the segmentation result of SAGA Seeded Region Growing as Seeds for GRASS - this works...
" You could try using the brand new i.superpixels.slic add-on to create superpixels which you can then use as seeds."
-> I could successfully install and open it ("g.extension i.superpixels.slic", GRASS 7.2.0). However, when I run the tool with default settings, GRASS gives a problem message and finishs the process.
Raphael
-----Ursprüngliche Nachricht-----
Von: Moritz Lennert [mailto:mlennert at club.worldonline.be]
Gesendet: Dienstag, 24. Januar 2017 19:11
An: grass-user at lists.osgeo.org; Raphael Knevels
Betreff: Re: [GRASS-user] Question to the input seed grid of i.segment
Le 24 janvier 2017 18:42:22 GMT+01:00, Raphael Knevels <raphael.knevels at uni-jena.de> a écrit :
>Dear GRASS-community,
>
>
>
>I have to perform a multi-scale, object-oriented analysis on an image
>with about 93'535'000 pixels^^
>
>
>
>I'm doing the process on a server, so I need for one simple
>segmentation process approximately 700-800 minutes depending on the
>threshold.
This does seem rather long. Is your computational region set to the extent and resolution of your raster ?
Also try setting the memory parameter of I.segment to a higher value (depending on your server's resources).
Which thresholds have you tried ?
>The
>same
>process in SAGA takes around 60 minutes with the use of seed points (as
>grid pixels).
Which segmentation algorithm do you use in SAGA ?
>But in SAGA there is no possibility for hierarchical segmentation.
>Therefore, I would like to use the seed points of SAGA as Input for
>GRASS
>7.2.0 to speed up i.segment.
>
>
>
>However, I am not capable to transform the seeds of SAGA to a
>meaningful i.segment input. How has to look an optimal input seeds grid
>for GRASS?
>
>
>
>- I've already found out is that it must be an integer grid with
>positive seed numbers. The float-grid output of SAGA seed contains
>single pixels surrounded by no-data values. When I transform the SAGA
>seed to an integer grid and into GRASS (by (r)gdal), I have to give no
>data values a positive number. Negative values in the seed-grid-input
>lead to an error in i.segment.
Seeds in i.segment have to be polygons not points. These polygons are represented by identical positive integer values (= IDs) in adjacent pixels, and they have to cover the entire region. When used as seeds for a segmentation, these polygons are the further merged.
I don't really understand what your seed points represent, but unless they have a semantic meaning related to the objects you are trying to identify, I'm not sure they are really relevant.
You could try using the brand new i.superpixels.slic add-on to create superpixels which you can then use as seeds.
Moritz
More information about the grass-user
mailing list