https://github.com/eoda-dev/py-maplibregl
Python bindings for MapLibre GL JS
https://github.com/eoda-dev/py-maplibregl
geo mapbox maplibre
Last synced: 2 months ago
JSON representation
Python bindings for MapLibre GL JS
- Host: GitHub
- URL: https://github.com/eoda-dev/py-maplibregl
- Owner: eoda-dev
- License: mit
- Created: 2023-12-21T14:32:18.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2024-09-06T05:44:15.000Z (10 months ago)
- Last Synced: 2024-10-18T03:16:39.336Z (9 months ago)
- Topics: geo, mapbox, maplibre
- Language: Python
- Homepage: https://eoda-dev.github.io/py-maplibregl/
- Size: 4.61 MB
- Stars: 37
- Watchers: 4
- Forks: 5
- Open Issues: 32
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE.md
Awesome Lists containing this project
- awesome-maplibre - py-maplibregl - Python bindings for MapLibre GL JS with docs [eoda-dev.github.io/py-maplibregl](https://eoda-dev.github.io/py-maplibregl/) and examples [eoda-dev.github.io/py-maplibregl/examples/road_safety](https://eoda-dev.github.io/py-maplibregl/examples/road_safety/). (Bindings / Python)
README
# MapLibre for Python
[](https://img.shields.io/github/v/release/eoda-dev/py-maplibregl)
[](https://pypi.python.org/pypi/maplibre)
[](https://github.com/conda-forge/maplibre-feedstock)
[](https://anaconda.org/conda-forge/maplibre)
[](https://img.shields.io/github/actions/workflow/status/eoda-dev/py-maplibregl/pytest.yml?branch=main)
[](https://img.shields.io/github/license/eoda-dev/py-maplibregl)
[](https://github.com/maplibre/maplibre-gl-js/releases/tag/v5.3.1)MapLibre for Python provides Python bindings for [MapLibre GL JS](https://github.com/maplibre/maplibre-gl-js).
Furthermore, [Deck.GL Layers](https://deck.gl/docs/api-reference/layers) can be mixed with [MapLibre Layers](https://maplibre.org/maplibre-style-spec/layers/).It integrates seamlessly into [Shiny for Python](https://github.com/posit-dev/py-shiny), [Marimo](https://marimo.io/), [Jupyter](https://jupyter.org/) and [JupyterLite](https://github.com/jupyter-widgets-contrib/anywidget-lite).
## Installation
```bash
# Stable
pip install maplibre # minimalpip install "maplibre[shiny]" # shiny bindings
pip install "maplibre[ipywidget]" # marimo and jupyter bindings
pip install "maplibre[all]"
uv add maplibre
uv add "maplibre[all]"
# Unstable
pip install git+https://github.com/eoda-dev/py-maplibregl@devpip install "maplibre[all] @ git+https://github.com/eoda-dev/py-maplibregl@dev"
uv add "git+https://github.com/eoda-dev/py-maplibregl@dev[all]"
# Conda
conda install -c conda-forge maplibre
```## Quickstart
```python
from maplibre import Map, MapOptionsm = Map(MapOptions(center=(-123.1256, 49.24658), zoom=9))
m.save(preview=True)
```## Documentation
* [Basic usage](https://eoda-dev.github.io/py-maplibregl/)
* [API Documentation](https://eoda-dev.github.io/py-maplibregl/api/map/)
* [Examples](https://eoda-dev.github.io/py-maplibregl/examples/every_person_in_manhattan/)## Development
### Python
```bash
poetry installpoetry run pytest
poetry run pytest --ignore=maplibre/ipywidget.py --doctest-modules maplibre
```### JavaScript
See [maplibre-bindings](https://github.com/eoda-dev/maplibre-bindings)