Installation
Install
Section titled “Install”python -m pip install mapcvuv pip install mapcv# or, in a uv project:uv add mapcvpipx install mapcvmapcv needs Python 3.10 or newer (3.10 – 3.14 are tested). One pre-built wheel per platform covers every supported Python version:
| Platform | Wheel |
|---|---|
| Linux x86-64 and aarch64 (glibc, e.g. Ubuntu, Debian, Docker on Apple Silicon) | yes |
| Linux x86-64 and aarch64 (musl, e.g. Alpine) | yes |
| macOS (Intel and Apple Silicon) | yes |
| Windows x86-64 | yes |
| Other (for example Windows on ARM) | builds from the source distribution; needs a Rust toolchain |
The base install is small: Pillow, NumPy, Shapely, Pydantic, Typer, Rich, PyYAML, pyproj (its wheel bundles PROJ, so there is nothing else to install) and pyshp (a pure-Python Shapefile reader, so Shapefile labels work out of the box; GeoPackage needs only the standard library). Nothing needs a system library. XYZ tiles, GeoTIFF/COG files (local, https:// or public s3://) and Sentinel-2 COGs from a STAC catalog (type: stac_cog) work with the base install alone. Sentinel-2 EOPF Zarr products, Google Earth Engine, GeoParquet labels and some export formats need an extra.
Optional extras
Section titled “Optional extras”| Extra | Install | Adds | Python |
|---|---|---|---|
zarr |
pip install "mapcv[zarr]" |
Sentinel-2 L2A EOPF Zarr input: xarray-eopf, xarray, Dask, zarr 2, numba (≥ 0.68), s3fs, pystac-client. It is large: about 76 packages, 180 MB to download and 560 MB installed (Python 3.13), so uv pip install is much faster than pip. |
3.10 – 3.13 |
parquet |
pip install "mapcv[parquet]" |
GeoParquet label files (.parquet, .geoparquet): pyarrow |
3.10 – 3.14 |
export |
pip install "mapcv[export]" |
Every mapcv export format and reading a Zarr export with MapcvDataset: pyarrow for hf-parquet (Hugging Face Parquet) and zarr 2 for zarr (7 packages and about 200 MB installed, most of it pyarrow). webdataset and terratorch need nothing extra |
3.10 – 3.14 (zarr 2 only up to 3.13) |
gee |
pip install "mapcv[gee]" |
Google Earth Engine imagery (imagery.earth_engine): the earthengine-api client. Log in once with earthengine authenticate |
3.10 – 3.14 |
mcp |
pip install "mapcv[mcp]" |
The MCP server for AI agents (mapcv mcp): the official MCP Python SDK and its dependencies. See Use mapcv with AI agents |
3.10 – 3.14 |
Verify
Section titled “Verify”$ mapcv --versionmapcv 0.3.1mapcv --help (or mapcv -h) lists the commands, grouped in the order you use them: 1. Build a dataset (init, plan, generate), 2. Use a dataset (info, split, stats, card, verify, export) and 3. Utilities (validate, cache, mcp, doctor). If the shell says command not found, activate the environment you installed into (see Installed into a virtual environment? above), or run python -m pip show mapcv to see where it went.
Shell completion
Section titled “Shell completion”mapcv’s CLI is built with Typer, which can install tab completion for bash, zsh, fish and PowerShell:
mapcv --install-completion # install for the current shell, then restart itmapcv --show-completion # print the script, to install it yourselfBuild from source
Section titled “Build from source”Use this for development or on platforms without a wheel.
-
Install Rust (stable) and Python 3.10+.
-
Clone the repository:
Terminal window git clone https://github.com/tahamukhtar20/mapcvcd mapcv -
Build and install into the active environment.
--releaseturns on Rust optimisations; debug builds are much slower.Terminal window python -m pip install maturinmaturin develop --releaseContributors use
uv sync --all-extras && uv run maturin developinstead; see Contributing.
Head to the Quickstart to build your first dataset.