Metadata-Version: 2.4
Name: cartoload
Version: 0.1.0
Summary: Convert raster geodata into GPS raser device maps
Project-URL: Repository, https://github.com/burgdev/cartoload
Project-URL: Documentation, https://burgdev.github.io/cartoload/
Project-URL: Changelog, https://github.com/burgdev/cartoload/blob/main/CHANGELOG.md
Project-URL: Releases, https://github.com/burgdev/cartoload/releases
License: LGPL-3.0-or-later
License-File: LICENSE
Classifier: Development Status :: 3 - Alpha
Classifier: Intended Audience :: Developers
Classifier: Intended Audience :: End Users/Desktop
Classifier: License :: OSI Approved :: GNU Lesser General Public License v3 or later (LGPLv3+)
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Topic :: Scientific/Engineering :: GIS
Requires-Python: >=3.11
Requires-Dist: click>=8.0
Requires-Dist: cryptography>=48.0.0
Requires-Dist: mozjpeg-lossless-optimization>=1.0
Requires-Dist: numpy>=1.24
Requires-Dist: pillow>=10.0
Requires-Dist: pyproj>=3.7.2
Requires-Dist: pystac-client>=0.6
Requires-Dist: pyyaml>=6.0
Requires-Dist: rasterio>=1.4.4
Requires-Dist: requests>=2.28
Requires-Dist: rich>=13.0
Description-Content-Type: text/markdown

# cartoload

Convert raster geodata into Garmin GPS raster maps (`*.img`).

`cartoload` is an open-source CLI tool and Python library that converts geodata from WMTS or GeoTIFF source into raster maps for Garmin GPS devices. It is the pipeline engine behind the [Cartoload](https://cartoload.com) service, but is fully usable standalone.

## Installation

```bash
pip install cartoload
```

or just run it with `uvx`

```bash
uvx cartoload --help
```

## Quick Start

```bash
# Build a layer from example configs
cartoload build \
    --sources examples/configs/sources/swisstopo.yaml \
    --layers examples/configs/layers/switzerland.yaml \
    --layer ch_basemap_25k
```

## Usage as a Library

```python
from cartoload.config import SourceConfig, LayerConfig
from cartoload.pipeline import build_layer

source = SourceConfig(id="my_source", type="wmts", url_template="...")
layer = LayerConfig(id="my_layer", name="My Layer", source="my_source")
output_path = await build_layer(layer, cache_dir="/tmp/cache")
```

## Documentation

Full documentation is available at [burgdev.github.io/cartoload](https://burgdev.github.io/cartoload/).

## Development

```bash
git clone https://github.com/burgdev/cartoload.git
cd cartoload
uv sync --all-groups
just test
```

### Docker Build

```bash
just docker build [--mkgmap]
./cartoload-docker build -c config.yaml -l my_layer          # server image
./cartoload-docker --local build -c config.yaml -l my_layer   # local image
./cartoload-docker --local --mkgmap build ...                  # local mkgmap image
```

## License

`LGPL` - see [LICENSE](https://github.com/burgdev/cartoload/blob/main/LICENSE) file.
