Is there any way in FME to extract polygon contours out of raster grid?
Using Professional Edition 64/32 on Windows 7 64bit
Is there any way in FME to extract polygon contours out of raster grid?
Using Professional Edition 64/32 on Windows 7 64bit
For instance reduce colors using inkscape or gimp.
you could then use a reasterexpressionevaluator to query the color of the polygon (assuming it has a unique color in the grid.) Then set all others to nvd (novalue) then a rasterpolyycoercer and then dissolving.
Correct me if I am wrong, I think your solution will not work on these grids.
An idea.
Round the cell values with a RasterCellValueRounder (if you set -2 to the Decimal Places parameter, cell values will be rounded by 100 place).
Transform the raster to polygons with a RasterToPolygonCoercer.
If necessary, make the boundaries smooth with a Generalizer (McMaster algorithm, Preserve Shared Boundaries: Yes).
Takashi
Yes i would not advise doing that on this type of grid. ;_)
FME contourgenereator is supposed to be able to handle rasters.
I tried a extent of 2400X2400 pixel to countourinterval of 1000. This conversion took 39 secs.
This is just a reader for the grid and a contourgenerator.
These grids are large, you would want to tile the raster, or read it in in smaller tiles (create user parameters for the search envelope in the navigator and or use a ).It's simply large.
Yes FME contourgenerator can produce countours, but the output is polyline and my task is to produce polygon.
The an Areabuilder.
Incompletes are at the edge of the extent.
In a worksbench i have made to exract levels of groundwater i do following:
I extract the hull with a hullacumulator and intersect this with the contour lines.
then i create areas with areabuilder. (maybe some snapping and linejoiner will be required, depending on data)
This gives fully closed contourplates.
I also order the contourplates to sort the highest on top (in case you want to do an AreaOnArea overlay)
In the pic i have not done that (yet though)
Here is contours to fullcoverage area..\\
This is a simple workbench
Joining in posted pic was not done with elevation. because you can not know if the boundary intersects contours with same elevation.
If you use elevation, you must at least use a higher contour density.
Here is same area with elavation as group by parameter. As you can see the result will not fully close. As the boundingboxboundary has no elevation of its own.
Data is sorted by elevation descending.
Now it is running on density 10..it is at over 3 million contourlines and still running strong...lol.
;)
Yes it works like a charm on small area, now I am processing the whole area.