https://github.com/Sangarshanan/geopatra
Interactive Maps with Geopandas
https://github.com/Sangarshanan/geopatra
Last synced: 4 months ago
JSON representation
Interactive Maps with Geopandas
- Host: GitHub
- URL: https://github.com/Sangarshanan/geopatra
- Owner: Sangarshanan
- License: apache-2.0
- Created: 2020-02-06T20:51:15.000Z (almost 6 years ago)
- Default Branch: master
- Last Pushed: 2023-02-11T00:39:46.000Z (almost 3 years ago)
- Last Synced: 2024-11-07T21:09:43.979Z (about 1 year ago)
- Language: Python
- Homepage: https://geopatra.readthedocs.io/
- Size: 2.66 MB
- Stars: 51
- Watchers: 4
- Forks: 4
- Open Issues: 11
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
- Awesome-Geospatial - geopatra - Interactive Maps with Geopandas. (Python)
- awesome-gis - Geopatra - Create interactive maps with geopandas (Geospatial Library / Python)
README

  [](https://geopatra.readthedocs.io/en/latest/?badge=latest) [](https://github.com/ambv/black/)  [](https://pypi.org/project/geopatra/)
Create Interactive maps 🗺️ with your geodataframe
Geopatra extends geopandas for interactive mapping and attempts to wrap the goodness of amazing mapping libraries like Folium, Plotly, Kepler.gl, hvplot etc for rapidly creating interactive maps with Geodataframes
You can already create interactive maps easily with geopandas and Folium/ Plotly/ Kepler.gl. Geopatra is merely meant to make this easier and is more geared towards ease and currently does not support complex maps or intricate style control
## Installation
Everything is always a pip away
```
pip install geopatra
```
## Basic Usage
To quickly plot a geodataframe with folium, you gotta understand workflows in geopandas and folium.
```python
import folium
import geopandas
world = geopandas.read_file(geopandas.datasets.get_path('naturalearth_lowres'))
m = folium.Map(location = [4,10], zoom_start = 3)
folium.GeoJson(world.__geo_interface__).add_to(m)
```
With Geopatra all the parameters you set with folium become optional so you don't have to care about folium
```python
import geopatra
m = world.folium.plot()
```
Now you have a folium map object, which you can now use for more complex mapflows
Check out [docs](https://geopatra.readthedocs.io/en/latest/geopatra.html) for more examples
## Development
Clone the repo
```git
git clone git@github.com:Sangarshanan/geopatra.git
```
Run ```pre-commit install``` to install pre-commit into your git hooks. pre-commit will now run on every commit
Install the package with the amazing [poetry](https://github.com/python-poetry/poetry)
```
poetry install
```
Make the bla-bla-bla changes to code and run the tests and when full moon is nigh, build & publish
```
poetry build
poetry publish
```
To update versions
```
poetry add geopandas@^0.8.0
```