User guide
This page documents the active kashima.mapper workflow.
Prerequisites
Install the package with pip:
python -m pip install --upgrade pip
python -m pip install kashima
Local catalogs and auxiliary datasets must exist either in the user cache or in the package data bundled with kashima. Packaged CSVs are seed/snapshot data; run the cache update helpers when you need current daily catalogs.
To populate or refresh the cache:
from kashima.mapper import downloadAllCatalogs, updateAllCatalogs
downloadAllCatalogs(include_faults=True)
updateAllCatalogs(include_faults=True)
Build A Map
from kashima.mapper import buildMap
result = buildMap(
latitude=-32.86758,
longitude=-68.88867,
radius_km=500,
project_name="Mendoza seismicity",
client="Example Mining Co.",
)
print(result["html"])
print(result["csv"])
The map builder can combine:
- USGS, GCMT, and ISC catalogs;
- GEM, USGS Quaternary, EFSM20, and user GeoJSON faults;
- the packaged ISC station layer;
- optional user event catalogs in the normalized mapper schema.
Catalog Builders
Use the catalog builders when you need the normalized catalog tables directly:
from kashima.mapper import buildUSGSCatalog, buildGCMTCatalog, buildISCCatalog
usgs = buildUSGSCatalog()
gcmt = buildGCMTCatalog()
isc = buildISCCatalog()
buildCatalog() is the generic wrapper for supported mapper catalog sources:
"usgs", "gcmt", and "isc".
Development Notes
Database event-table hydration is outside the active mapper API and must be
handled by a separate gmsp contract.