How koaokano/geosplit works
GeoSplit is a Python CLI and API for validating GeoJSON, splitting FeatureCollections and GeoPackage layers, and converting between GeoJSON and GeoPackage. The main user workflow enters through the CLI or public Python API, then reaches validation, planning, and splitting or conversion. Core also handles streamed GeoJSON parsing and recoverable output transactions. GeoPackage operations depend on optional GeoPandas support. The graph follows excerpted calls and README-described capabilities; unsampled core paths are not expanded into additional implementation details.
Main entry points: cli.py Command interface · core.py Streaming and splitting · convert.py GeoPackage splitting · __init__.py Public API
Components 14
User entry points
- Command interface
src/geosplit/cli.py - Public API
src/geosplit/__init__.py
GeoJSON processing
- GeoJSON validation
src/geosplit/validation.py - Streaming and splitting
src/geosplit/core.py - Batch iteration
src/geosplit/core.py - Split planning
src/geosplit/core.py - GeoJSON chunks
src/geosplit/core.py
GeoPackage operations
- Format conversion
src/geosplit/convert.py - GeoPackage splitting
src/geosplit/convert.py - GeoPandas
Output management
- Output transactions
src/geosplit/core.py - Output files
Other components
- CLI user
- Python API user
Connections 20
- CLI user → Command interface: runs commands
- Python API user → Public API: calls API
src/geosplit/__init__.py - Command interface → GeoJSON validation: validates
src/geosplit/cli.py - Command interface → Streaming and splitting: splits GeoJSON
src/geosplit/cli.py - Command interface → Split planning: plans splits
src/geosplit/cli.py - Command interface → Format conversion: converts formats
src/geosplit/cli.py - Command interface → GeoPackage splitting: splits layers
src/geosplit/cli.py - Public API → Streaming and splitting: exports split API
src/geosplit/__init__.py - Public API → GeoJSON validation: exports validation
src/geosplit/__init__.py - GeoJSON validation → Streaming and splitting: reads features
src/geosplit/validation.py - Streaming and splitting → Batch iteration: yields batches
README.md - Streaming and splitting → Split planning: builds plans
README.md - Split planning → GeoJSON chunks: plans chunks
README.md - Streaming and splitting → Output transactions: stages outputs
src/geosplit/core.py - Output transactions → Output files: commits files
- Format conversion → GeoPandas: reads and writes
src/geosplit/convert.py - GeoPackage splitting → GeoPandas: reads layers
src/geosplit/convert.py - GeoPackage splitting → Output transactions: commits chunks
src/geosplit/convert.py - Format conversion → Output files: writes converted file
src/geosplit/convert.py - GeoPackage splitting → Output files: writes layer chunks
src/geosplit/convert.py