$query=”ogr2ogr -f GPKG $output.gpkg $shpfilepath.shp”; shell_exec($query); } The output file can be open in QGIS software. I have converted Road File of one such country. Here is the output look in QGIS tool after Converting Shapefile to GeoPackage. Change Coordinate system of Out...
When you open a file in 'w' mode, specify anencodingkeyword argument like 'latin1' or 'gb18030' or Fiona will make a guess at the appropriate encoding (potentially a wrong guess). All string properties of the features you write to the opened file must have Python unicode values. They a...
To create a valid Geopackage file like that, the geometry column type specified should be "Unknown": import shapely import geopandas as gpd gpd.GeoSeries( [ shapely.geometry.MultiLineString( [ shapely.geometry.LineString([[0, 0], [0, 1]]), shapely.geometry.LineString([[1...