13

I want to vectorize that rasterfile with its 6 landuse classes. The classification is very noisy and have to be generalized before.

The result should be a polygone vector file.

I use SAGA, (GRASS) and QGIS.

enter image description here

5 Answers 5

14

To simplify the raster it might be worth looking at gdal_sieve, it's available under the "Raster" menu. See: http://www.gdal.org/gdal_sieve.html

N.

2
  • Tryed several times with sieve and majority filter. Best results with sieve! Thanks! I will post the result after its finished...
    – MartinMap
    Commented Aug 21, 2012 at 14:44
  • gdal_sieve seems to be deprecated for now Commented Jun 21, 2023 at 9:42
5

To generalize, try running a majority filter. This is available in saga (and grass as well, check markusN his answer). An explanation for how it works from arcgis: http://edndoc.esri.com/arcobjects/9.2/net/shared/geoprocessing/spatial_analyst_tools/majority_filter.htm

3

you can use gdal_polygonize.py for converting raster to vector, if u previously use . some information is here.

produces a polygon feature layer from a raster

SYNOPSIS

gdal_polygonize.py [-o name=value] [-nomask] [-mask filename] raster_file [-b band] [-q] [-f ogr_format] out_file [layer] [fieldname]

beside this in qgis you can use Polygonize tool for your needs. it is under the Raster > Conversion > Polygonize (Raster to vector) menu.

if u dont see anything except Raster Calculater under Raster menu, you have to enter Manage Plugins under Plugins, then enable GdalTools. that is all..

i hope it helps you...

3

You can first use the "mode" operator of r.neighbors in GRASS GIS (via Sextante plugin), then vectorize with r.to.vect to obtain polygons. Perhaps the "mode" operator should be run more than one time.

2

Using the majority filter with a kernel of 5 by 5 pixels gives the best results for me.

1
  • 3
    Please explain your answer in detail.
    – Sunil
    Commented Oct 23, 2013 at 9:35

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.