1
Python and Java API / Export shapes to gpkg file
« on: February 10, 2024, 07:03:18 PM »
Dear Metashape developers,
We need to export a geometry in a GeoPackage file, but executing code:
We get error: OSError: SQL logic error (1)
But we do not get any error using the SHP format:
Please, what is the solution to get our geometry exported in GPKG format?
Thank you for your time
We need to export a geometry in a GeoPackage file, but executing code:
Code: [Select]
layer = chunk.shapes.groups[0]
chunk.exportShapes(
path=os.path.join(output_path, 'roi.gpkg'),
save_polygons=True,
groups=[layer.key],
format=Metashape.ShapesFormatGeoPackage,
crs=chunk.crs
)We get error: OSError: SQL logic error (1)
But we do not get any error using the SHP format:
Code: [Select]
layer = chunk.shapes.groups[0]
chunk.exportShapes(
path=os.path.join(output_path, 'roi.shp'),
save_polygons=True,
groups=[layer.key],
format=Metashape.ShapesFormatSHP,
crs=chunk.crs
)Please, what is the solution to get our geometry exported in GPKG format?
Thank you for your time