Image segmentation questions

1515
4
09-06-2018 05:46 PM
Labels (1)
RuthSpell1
New Contributor II

I have segmented an image in ArcGIS Pro using the Segmentation tool under Image Classification.  I now want to convert the image segments to polygons with the Raster to Polygon tool.  I have several questions about segmentation before I convert it to polygons.

1.   When there is a single pixel that is connected diagonally to a larger cluster of pixels and the single pixel and the pixels in the larger cluster all have the same value, does that mean they are all part of a single segment? In other words, can a segment extend to diagonally neighboring pixels?   

2.  What does the Value field in the segmented image represent?  I initially assumed it was a unique segment ID, but now I am seeing multiple, spatially separated clusters with the same value.   

3.  When you convert the segmented image to polygons with the Raster to Polygon tool, what field should be used to assign values from the cells in the input raster to the polygons in the output polygon feature class?  I had hoped there would be a field representing a unique segment ID that could be passed from the segmented image to the polygons.  But that doesn't seem to be the case, unless I'm missing something.   I tried using ObjectID, but got an error message (ERROR 000861 that said Field type is not valid).  And there doesn't seem to be any point in using the Value field since it doesn't appear to be unique for each segment.      

3.  When I segment my image (a 3 band image), the output is a 3 band image where the corresponding pixels in each output band have the same value.  Why does the Segmentation tool produce a 3 band output image where each band is exactly the same?  Shouldn't it produce a one band image where each cluster of similar pixels has a unique id?  

Thanks for any help,

Ruth

4 Replies
DanPatterson_Retired
MVP Emeritus

As a side tangent.... raster tables don't behave the same way as featureclass tables.

Consider several discrete and separate raster areas separated by one another but they have the same value.  Let us say, 3 separate non-connected areas with a value of 1)

In the raster table, you will see one entry for 'Value' which will be 1,  and a cell count.  That is a 'Zone', it is analogous to a multipart polygon.  To make them into separate entities you have to use 'RegionGroup' to split up the zone into separate entities, which will have a separate ID, count, but the same value.

Second Raster to Polygon—Conversion toolbox | ArcGIS Desktop  has 2 methods, each have their use.  Yes a single pixel touching a zone of like-valued pixels will be considered as part of the same zone.  You can clean those up using regiongroup and 'Nibble', but that is another story.

This doesn't answer your question, but puts some of your questions into context or raster world and less about remote sensing world

RuthSpell1
New Contributor II

Thanks for your response.  I see that my thinking on segments was incorrect.  Apparently they are more like unsupervised clusters where there can be multiple, geographically separated clusters with the same value rather than spatially discrete image objects. 

With that understanding, and the region group tool, I should be able to move forward towards my end goal.  It will just take more steps than I initially envisioned.

Thank you for the clarification.

Ruth

0 Kudos
NeilAyres
MVP Alum

I had hoped there would be a field representing a unique segment ID that could be passed from the segmented image to the polygons.

If you do want each separate "patch" to have its own unique id then look at the region group tool.

Without specific knowledge of what you are doing and what you want to get, it is difficult to comment further.

RuthSpell1
New Contributor II

Thanks Neil.  The region group tool will help.

0 Kudos