Run AquaCrop-OSPy over large regions in gridded format — from raw global datasets to interactive results.
One import, three stages
import geoaquacrop as gac
gac.preprocess.run(...) # download & harmonise the input datasets
gac.simulate.run(...) # run AquaCrop for every grid cell
gac.visualize.run() # explore the results
That is the whole API. Each stage is a separately maintained package, but you
never need to know their names: geoaquacrop presents them as one library.
gac.preprocess -> gac.simulate -> gac.visualize
| Stage | What it does | Repository | Documentation |
|---|---|---|---|
gac.preprocess |
Downloads and harmonises climate, soil, crop calendar and crop area data onto a common grid for a given polygon and period | geoaquacrop_preprocess | readthedocs |
gac.simulate |
Runs AquaCrop per grid cell in parallel; optional yield bias-correction and calibration against observations | geoaquacrop_simulate | readthedocs |
gac.visualize |
Interactive Dash/Plotly dashboard for exploring simulation outputs and climate inputs | geoaquacrop_visualize | readthedocs |
Installation
conda create -n geoaquacrop python=3.11
conda activate geoaquacrop
python -m pip install geoaquacrop
This installs all three stages.
For past climate data you also need a free Copernicus CDS account and API token — see the preprocessing documentation.
Installing a single stage
Each stage also works standalone, with the same function names:
python -m pip install geoaquacrop_preprocess # data preparation only
python -m pip install geoaquacrop_simulate # simulation only
python -m pip install geoaquacrop_visualize # visualisation only
import geoaquacrop_simulate as simulate
summary_file, daily_file = simulate.run(data_path='...', start_date='...',
end_date='...', crop='Wheat_winter')
gac.simulate.run and geoaquacrop_simulate.run are the same function, so
code written against either keeps working.
End-to-end example
A complete run for one region, using only gac.
import geoaquacrop as gac
# 1. prepare the input data
gac.preprocess.run(
domain_shape_path='high_plains.geojson', # polygon, EPSG:4326
start_year=2011,
end_year=2013,
api_token='your-copernicus-api-token',
cell_resolution=0.05,
workingdirectory='/data/high_plains',
)
# 2. run the simulation
summary_file, daily_file = gac.simulate.run(
data_path='/data/high_plains/processed', # fills all four input paths
start_date='2011/01/01',
end_date='2013/12/31',
crop='Wheat_winter',
irrigation='rainfed',
output_dir='outputs',
)
# 3. explore the results
gac.visualize.run() # then open http://localhost:8050
What each stage offers
gac.preprocess.run(...) # prepare every dataset
gac.preprocess.weather(...) # or re-run a single step
gac.preprocess.soil(...)
gac.preprocess.crop_calendar(...)
gac.preprocess.crop_area(...)
gac.simulate.run(data_path=..., ...) # simulate; returns (summary, daily)
gac.simulate.example_config() # inspect every available setting
gac.simulate.input_requirements() # print required files and units
gac.simulate.build_reference(...) # per-year, region-level yield reference
gac.simulate.correct(config) # bias-correct a saved run, no re-run
gac.simulate.compare([...]) # comparison figures and statistics
gac.simulate.load_results(path) # saved results as tidy per-year points
gac.visualize.run() # start the dashboard
Importing geoaquacrop is cheap: each stage — and its dependencies — loads only
when you first use it. If a stage is not installed, calling it tells you exactly
what to install.
Which stage do I need?
- Model outputs for a region, starting from nothing — all three.
- Already have gridded climate, soil and crop inputs —
gac.simulatealone. - Already have simulation outputs —
gac.visualizealone.
Documentation
- This toolchain — https://geoaquacrop.readthedocs.io
- Preprocessing — https://geoaquacrop-preprocess.readthedocs.io/en/latest/
- Simulation — https://geoaquacrop-simulate.readthedocs.io
- Visualisation — https://geoaquacrop-visualize.readthedocs.io/en/latest/
Contributors: see the stage package standard for the naming and API contract each stage follows.
Citation
If you use GeoAquaCrop in published work, please cite the toolchain and the underlying AquaCrop-OSPy model.
A preprint will be published soon. Until then, please cite:
Láng-Ritter, J., Bowden, C., Hosseini, S., Alkio, E., Tenkanen, H. & Foster, T. GeoAquaCrop: Large-scale agricultural crop modelling using open global data
License
Apache-2.0 — see LICENSE.
Metadata
Release files for geoaquacrop 0.1.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| geoaquacrop-0.1.1.tar.gz | 13.1 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| geoaquacrop-0.1.1-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 25.7 kB
Release files / geoaquacrop-0.1.1.tar.gz
| Download URL | geoaquacrop-0.1.1.tar.gz |
|---|---|
| Size | 13.1 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
586463b297ea20c506c977cabb19804ca1730587d0688e5481e348fdf3cdd81a
|
|
BLAKE2b-256 checksum How to use checksums |
ec5869b09ed742fb72f3e42be43b71788b75c1954ddf33c143727bbaf156dece
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Oct 7, 2026.
Transparency logRelease files / geoaquacrop-0.1.1-py3-none-any.whl
| Download URL | geoaquacrop-0.1.1-py3-none-any.whl |
|---|---|
| Size | 12.6 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
f4dcf460db5701865266322e4a050483fb2148600acf7ea094144be0fa558953
|
|
BLAKE2b-256 checksum How to use checksums |
e62225dc6f0bf5bf4f53400285f9ad67c98dddaf2ef562e458d39916cad8134e
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Oct 7, 2026.
Transparency log