While geospatial data is often supplied in the form of vector-format files such as shapefiles, there are situations where shapefiles are unsuitable or inefficient. One such situation is where you need to take geospatial data from one library and use it in a different library. For example, imagine that you have read a set of geometries out of a shapefile and want to store them in a database, or work with them using the
shapely library. Because all the different Python libraries use their own private classes to represent geospatial data, you can't just take an OGR
Geometry object and pass it to
shapely, or use a GDAL
SpatialReference object to define the datum and projection to use for data stored in a database. ...