1
GDAL полігонізувати в python, створюючи порожній багатокутник?
У мене виникають проблеми з використанням функції Polygonize в python. Приклад кулінарної книги для цього можна знайти тут . Відповідна частина мого коду: sourceRaster = gdal.Open('myraster.tif') band = sourceRaster.GetRasterBand(1) bandArray = band.ReadAsArray() outShapefile = "polygonized" driver = ogr.GetDriverByName("ESRI Shapefile") if os.path.exists(outShapefile+".shp"): driver.DeleteDataSource(outShapefile+".shp") outDatasource = driver.CreateDataSource(outShapefile+ ".shp") outLayer = outDatasource.CreateLayer("polygonized", srs=None) …