Date
1 - 2 of 2
Binary raster to geojson
ashnair0007@...
Given a binary numpy array (array of 0s and 1s where 0=background), what would be the best way to polygonise this raster and write it to a geojson?
|
|
Sean Gillies
https://rasterio.readthedocs.io/en/latest/cli.html#shapes is a command line program for extracting GeoJSON shapes from a raster. It's a thin wrapper around rasterio.features.dataset_features() (see https://github.com/mapbox/rasterio/blob/master/rasterio/rio/shapes.py). On Sat, Dec 26, 2020 at 11:32 PM <ashnair0007@...> wrote: Given a binary numpy array (array of 0s and 1s where 0=background), what would be the best way to polygonise this raster and write it to a geojson? --
Sean Gillies |
|