TransWikia.com

Using GeoPandas generated .gpkg in ArcMap

Geographic Information Systems Asked by Nicolas Cadieux on September 25, 2020

I am using GeoPandas to create .gpkg files. Using GeoDataFrame.to_file()

When opening the files in ArcMap, it takes a long time updating the file extent. Files already have an spatial index as this is a GeoPackage.

Is there a way to specify the GeoPandas GeoDataFrame extent and code that’s in the GeoPackage?

Also, files open in ArcMap with a .main prefix in front of my specified layer name which may be an ArcGIS thing.

It’s looking good in QGIS.

One Answer

.main is not a problem. With SQLite you can attach other databases and the name (or schema) of the master database is "main". Most other clients just does not show it.

The extent of each table is stored into metadata table gpkg_contents http://www.geopackage.org/spec121/index.html#_gpkg_contents. The GeoPackage standard says

The bounding box (min_x, min_y, max_x, max_y) provides an informative bounding box of the content. Applications may use this bounding box as the extents of a default view but there are no requirements that this bounding box be exact or represent the minimum bounding box of the content. The values are in the units specified by that CRS.

If ArcGIS or any other client wants to get extent that is guaranteed to be accurate it must read every single feature. Usually it is waste of time. The reason for allowing the bbox in the metadata to be an estimate is that otherwise it should be calculated again after each insert/delete/edit.

Answered by user30184 on September 25, 2020

Add your own answers!

Ask a Question

Get help from others!

© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP