30 Commits

Author SHA1 Message Date
marceloprates
f62ed5fbb7 Bump version 2025-03-03 18:31:45 -03:00
marceloprates
598aa6b0ef Bump version 2025-03-03 18:29:28 -03:00
marceloprates
b8c7abc10f Bump version 2025-03-03 18:28:45 -03:00
marceloprates
6ad8f8a1a9 Updated app 2025-03-03 18:20:58 -03:00
marceloprates
ded7e41e08 Updated app 2025-03-03 17:03:00 -03:00
marceloprates
7c8d465e55 Added placeholder image for streamlit app 2025-03-03 17:01:49 -03:00
marceloprates
da87a351ef Merge branch 'main' of github.com:marceloprates/prettymaps 2025-03-03 17:00:40 -03:00
marceloprates
98eabec453 Added placeholder image for streamlit app 2025-03-03 17:00:07 -03:00
Marcelo de Oliveira Rosa Prates
c7d0ab8548 Update app.py
Reduced max radius to 10km
2025-03-03 16:07:22 -03:00
Marcelo de Oliveira Rosa Prates
ab662fd09f Update README.md 2025-03-03 16:05:13 -03:00
Marcelo de Oliveira Rosa Prates
1d3eba9d26 Update README.md 2025-03-03 15:46:50 -03:00
Marcelo de Oliveira Rosa Prates
9994faca0d Update README.md 2025-03-03 15:45:57 -03:00
Marcelo de Oliveira Rosa Prates
e8f5dc4a39 Update README.md 2025-03-03 15:44:51 -03:00
marceloprates
06915bc803 updated app 2025-03-03 15:20:53 -03:00
marceloprates
8fd248e85e updated app 2025-03-03 15:16:02 -03:00
marceloprates
b8486d6d1c added setup.sh for streamlit cloud 2025-03-03 15:00:45 -03:00
marceloprates
bce6af8d18 updated app 2025-03-03 14:59:03 -03:00
marceloprates
97bfa4b8c3 Added packages.txt 2025-03-03 14:56:36 -03:00
marceloprates
9ca09a8b2c updated app 2025-03-03 14:54:29 -03:00
marceloprates
bd1dcb4ab8 updated app 2025-03-03 14:48:42 -03:00
marceloprates
9dea3e9812 Merge branch 'main' of github.com:marceloprates/prettymaps 2025-03-03 14:46:48 -03:00
marceloprates
fe064afa79 updated app 2025-03-03 14:46:40 -03:00
Marcelo de Oliveira Rosa Prates
d179e70db5 Added Dev Container Folder 2025-03-03 14:39:12 -03:00
marceloprates
421ff6c25a merge 2025-03-03 14:16:58 -03:00
marceloprates
c9296bf973 1) Added support for rendering sea geometries automatically 2) added support for drawing hillshades 3) added support for adding keypoints 4) refactored code 5) optimized code by making fewer requests to overpass API 6) added frontend (streamlit) app 2025-03-03 14:16:23 -03:00
Marcelo de Oliveira Rosa Prates
2da2395112 Update setup.py 2025-01-12 13:40:30 -03:00
Marcelo de Oliveira Rosa Prates
4c530c6491 Merge pull request #129 from HalFrgrd/patch-1
Use `retain_all` when fetching graph
2025-01-12 13:39:29 -03:00
Marcelo Prates
c090ade075 Changed version number 2025-01-12 13:28:57 -03:00
C4K3
7343fc502d Fix osmnx dependency to version 1
Without this it will try to install osmnx version 2, which had breaking
changes and causes prettymaps to fail with the error
```
AttributeError: module 'osmnx' has no attribute 'project_gdf'. Did you mean: 'project_graph'?
```
2024-12-26 06:27:34 -08:00
HalFrgrd
68323c567e Use retain_all when fetching graph 2024-07-06 14:16:02 +01:00
157 changed files with 2132 additions and 23358 deletions

View File

@@ -0,0 +1,33 @@
{
"name": "Python 3",
// Or use a Dockerfile or Docker Compose file. More info: https://containers.dev/guide/dockerfile
"image": "mcr.microsoft.com/devcontainers/python:1-3.11-bullseye",
"customizations": {
"codespaces": {
"openFiles": [
"README.md",
"prettymaps/app.py"
]
},
"vscode": {
"settings": {},
"extensions": [
"ms-python.python",
"ms-python.vscode-pylance"
]
}
},
"updateContentCommand": "[ -f packages.txt ] && sudo apt update && sudo apt upgrade -y && sudo xargs apt install -y <packages.txt; [ -f requirements.txt ] && pip3 install --user -r requirements.txt; pip3 install --user streamlit; echo '✅ Packages installed and Requirements met'",
"postAttachCommand": {
"server": "streamlit run prettymaps/app.py --server.enableCORS false --server.enableXsrfProtection false"
},
"portsAttributes": {
"8501": {
"label": "Application",
"onAutoForward": "openPreview"
}
},
"forwardPorts": [
8501
]
}

0
.github/FUNDING.yml vendored Executable file → Normal file
View File

0
.github/workflows/publish-package.yml vendored Executable file → Normal file
View File

0
.gitignore vendored Executable file → Normal file
View File

0
LICENSE Executable file → Normal file
View File

0
MANIFEST.in Executable file → Normal file
View File

513
README.md Executable file → Normal file
View File

@@ -1,14 +1,14 @@
```python
# Install prettymaps using pip:
#!pip install prettymaps
```
# prettymaps
A minimal Python library to draw customized maps from [OpenStreetMap](https://www.openstreetmap.org/#map=12/11.0733/106.3078) created using the [osmnx](https://github.com/gboeing/osmnx), [matplotlib](https://matplotlib.org/), [shapely](https://shapely.readthedocs.io/en/stable/index.html) and [vsketch](https://github.com/abey79/vsketch) packages.
![](https://github.com/marceloprates/prettymaps/raw/main/prints/heerhugowaard.png)
# Prettymaps is now available as a streamlit app!
[![Streamlit App](https://img.shields.io/badge/Streamlit-Live-blue?logo=streamlit)](https://prettymaps.streamlit.app/)
[![image](https://github.com/user-attachments/assets/14e56496-9eab-4b31-ad05-6227d56cfbd2)](https://prettymaps.streamlit.app/)
<!--![](https://github.com/marceloprates/prettymaps/raw/main/prints/heerhugowaard.png)-->
This work is [licensed](LICENSE) under a GNU Affero General Public License v3.0 (you can make commercial use, distribute and modify this project, but must **disclose** the source code with the license and copyright notice)
@@ -24,17 +24,17 @@ This work is [licensed](LICENSE) under a GNU Affero General Public License v3.0
## As seen on [Hacker News](https://web.archive.org/web/20210825160918/https://news.ycombinator.com/news):
![](https://github.com/marceloprates/prettymaps/raw/main/prints/hackernews-prettymaps.png)
<picture>
<source media="(prefers-color-scheme: dark)" srcset="https://api.star-history.com/svg?repos=marceloprates/prettymaps&type=Date&theme=dark" />
<source media="(prefers-color-scheme: light)" srcset="https://api.star-history.com/svg?repos=marceloprates/prettymaps&type=Date" />
<img alt="Star History Chart" src="https://api.star-history.com/svg?repos=star-history/star-history&type=Date" />
</picture>
## [prettymaps subreddit](https://www.reddit.com/r/prettymaps_/)
## [Google Colaboratory Demo](https://colab.research.google.com/github/marceloprates/prettymaps/blob/master/notebooks/examples.ipynb)
# Installation
To enable plotter mode:
```
pip install git+https://github.com/abey79/vsketch@1.0.0
```
### Install locally:
Install prettymaps with:
@@ -52,6 +52,13 @@ Install prettymaps with:
Then **restart the runtime** (Runtime -> Restart Runtime) before importing prettymaps
# Run front-end
After prettymaps is installed, you can run the front-end (streamlit) application from the prettymaps repository using:
```
streamlit run app.py
```
# Tutorial
Plotting with prettymaps is very simple. Run:
@@ -66,6 +73,9 @@ prettymaps.plot(your_query)
```python
%reload_ext autoreload
%autoreload 2
import prettymaps
plot = prettymaps.plot('Stad van de Zon, Heerhugowaard, Netherlands')
@@ -73,7 +83,7 @@ plot = prettymaps.plot('Stad van de Zon, Heerhugowaard, Netherlands')
![png](README_files/README_8_0.png)
![png](README_files/README_7_0.png)
@@ -93,7 +103,7 @@ plot = prettymaps.plot(
![png](README_files/README_10_0.png)
![png](README_files/README_9_0.png)
@@ -180,11 +190,16 @@ prettymaps.presets()
</tr>
<tr>
<th>8</th>
<td>my-preset</td>
<td>{'layers': {'building': {'tags': {'building': ...</td>
</tr>
<tr>
<th>9</th>
<td>plotter</td>
<td>{'layers': {'perimeter': {}, 'streets': {'widt...</td>
</tr>
<tr>
<th>9</th>
<th>10</th>
<td>tijuca</td>
<td>{'layers': {'perimeter': {}, 'streets': {'widt...</td>
</tr>
@@ -206,7 +221,7 @@ prettymaps.preset('default')
Preset(params={'layers': {'perimeter': {}, 'streets': {'width': {'motorway': 5, 'trunk': 5, 'primary': 4.5, 'secondary': 4, 'tertiary': 3.5, 'cycleway': 3.5, 'residential': 3, 'service': 2, 'unclassified': 2, 'pedestrian': 2, 'footway': 1}}, 'building': {'tags': {'building': True, 'landuse': 'construction'}}, 'water': {'tags': {'natural': ['water', 'bay']}}, 'forest': {'tags': {'landuse': 'forest'}}, 'green': {'tags': {'landuse': ['grass', 'orchard'], 'natural': ['island', 'wood'], 'leisure': 'park'}}, 'beach': {'tags': {'natural': 'beach'}}, 'parking': {'tags': {'amenity': 'parking', 'highway': 'pedestrian', 'man_made': 'pier'}}}, 'style': {'perimeter': {'fill': False, 'lw': 0, 'zorder': 0}, 'background': {'fc': '#F2F4CB', 'zorder': -1}, 'green': {'fc': '#8BB174', 'ec': '#2F3737', 'hatch_c': '#A7C497', 'hatch': 'ooo...', 'lw': 1, 'zorder': 1}, 'forest': {'fc': '#64B96A', 'ec': '#2F3737', 'lw': 1, 'zorder': 2}, 'water': {'fc': '#a8e1e6', 'ec': '#2F3737', 'hatch_c': '#9bc3d4', 'hatch': 'ooo...', 'lw': 1, 'zorder': 3}, 'beach': {'fc': '#FCE19C', 'ec': '#2F3737', 'hatch_c': '#d4d196', 'hatch': 'ooo...', 'lw': 1, 'zorder': 3}, 'parking': {'fc': '#F2F4CB', 'ec': '#2F3737', 'lw': 1, 'zorder': 3}, 'streets': {'fc': '#2F3737', 'ec': '#475657', 'alpha': 1, 'lw': 0, 'zorder': 4}, 'building': {'palette': ['#433633', '#FF5E5B'], 'ec': '#2F3737', 'lw': 0.5, 'zorder': 5}}, 'circle': None, 'radius': 500})
Preset(params={'layers': {'perimeter': {}, 'streets': {'width': {'motorway': 5, 'trunk': 5, 'primary': 4.5, 'secondary': 4, 'tertiary': 3.5, 'cycleway': 3.5, 'residential': 3, 'service': 2, 'unclassified': 2, 'pedestrian': 2, 'footway': 1}}, 'waterway': {'tags': {'waterway': ['river', 'stream']}, 'width': {'river': 20, 'stream': 10}}, 'building': {'tags': {'building': True, 'landuse': 'construction'}}, 'water': {'tags': {'natural': ['water', 'bay']}}, 'sea': {}, 'forest': {'tags': {'landuse': 'forest'}}, 'green': {'tags': {'landuse': ['grass', 'orchard'], 'natural': ['island', 'wood', 'wetland'], 'leisure': 'park'}}, 'rock': {'tags': {'natural': 'bare_rock'}}, 'beach': {'tags': {'natural': 'beach'}}, 'parking': {'tags': {'amenity': 'parking', 'highway': 'pedestrian', 'man_made': 'pier'}}}, 'style': {'perimeter': {'fill': False, 'lw': 0, 'zorder': 0}, 'background': {'fc': '#F2F4CB', 'zorder': -1}, 'green': {'fc': '#8BB174', 'ec': '#2F3737', 'hatch_c': '#A7C497', 'hatch': 'ooo...', 'lw': 1, 'zorder': 1}, 'forest': {'fc': '#64B96A', 'ec': '#2F3737', 'lw': 1, 'zorder': 2}, 'water': {'fc': '#a8e1e6', 'ec': '#2F3737', 'hatch_c': '#9bc3d4', 'hatch': 'ooo...', 'lw': 1, 'zorder': 99}, 'sea': {'fc': '#a8e1e6', 'ec': '#2F3737', 'hatch_c': '#9bc3d4', 'hatch': 'ooo...', 'lw': 1, 'zorder': 99}, 'waterway': {'fc': '#a8e1e6', 'ec': '#2F3737', 'hatch_c': '#9bc3d4', 'hatch': 'ooo...', 'lw': 1, 'zorder': 200}, 'beach': {'fc': '#FCE19C', 'ec': '#2F3737', 'hatch_c': '#d4d196', 'hatch': 'ooo...', 'lw': 1, 'zorder': 3}, 'parking': {'fc': '#F2F4CB', 'ec': '#2F3737', 'lw': 1, 'zorder': 3}, 'streets': {'fc': '#2F3737', 'ec': '#475657', 'alpha': 1, 'lw': 0, 'zorder': 4}, 'building': {'palette': ['#433633', '#FF5E5B'], 'ec': '#2F3737', 'lw': 0.5, 'zorder': 5}, 'rock': {'fc': '#BDC0BA', 'ec': '#2F3737', 'lw': 1, 'zorder': 6}}, 'circle': None, 'radius': 500})
@@ -365,7 +380,7 @@ plot = prettymaps.plot(
![png](README_files/README_16_0.png)
![png](README_files/README_15_0.png)
@@ -386,7 +401,7 @@ plot = prettymaps.plot(
![png](README_files/README_18_0.png)
![png](README_files/README_17_0.png)
@@ -422,68 +437,41 @@ plot.geodataframes['building']
<thead>
<tr style="text-align: right;">
<th></th>
<th></th>
<th>geometry</th>
<th>bicycle</th>
<th>highway</th>
<th>leisure</th>
<th>addr:housenumber</th>
<th>addr:street</th>
<th>amenity</th>
<th>operator</th>
<th>website</th>
<th>geometry</th>
<th>addr:postcode</th>
<th>name</th>
<th>office</th>
<th>opening_hours</th>
<th>historic</th>
<th>...</th>
<th>contact:phone</th>
<th>contact:website</th>
<th>bus</th>
<th>public_transport</th>
<th>source:name</th>
<th>government</th>
<th>smoothness</th>
<th>inscription</th>
<th>ways</th>
<th>boat</th>
<th>name:fr</th>
<th>type</th>
<th>building:part</th>
<th>architect</th>
</tr>
<tr>
<th>element_type</th>
<th>osmid</th>
<th></th>
<th></th>
<th></th>
<th></th>
<th></th>
<th></th>
<th></th>
<th></th>
<th></th>
<th></th>
<th></th>
<th></th>
<th></th>
<th></th>
<th></th>
<th></th>
<th></th>
<th></th>
<th></th>
<th></th>
<th></th>
</tr>
</thead>
<tbody>
<tr>
<th>node</th>
<th>2407915698</th>
<th>(node, 2407915698)</th>
<td>POINT (-51.23212 -30.03670)</td>
<td>NaN</td>
<td>NaN</td>
<td>NaN</td>
<td>820</td>
<td>Rua Washington Luiz</td>
<td>NaN</td>
<td>NaN</td>
<td>NaN</td>
<td>POINT (-51.23212 -30.0367)</td>
<td>90010-460</td>
<td>NaN</td>
<td>NaN</td>
<td>NaN</td>
<td>...</td>
<td>NaN</td>
@@ -498,17 +486,16 @@ plot.geodataframes['building']
<td>NaN</td>
</tr>
<tr>
<th rowspan="4" valign="top">way</th>
<th>126665330</th>
<th>(way, 126665330)</th>
<td>POLYGON ((-51.23518 -30.03275, -51.23512 -30.0...</td>
<td>NaN</td>
<td>NaN</td>
<td>NaN</td>
<td>387</td>
<td>Rua dos Andradas</td>
<td>place_of_worship</td>
<td>NaN</td>
<td>NaN</td>
<td>POLYGON ((-51.23518 -30.03275, -51.23512 -30.0...</td>
<td>90020-002</td>
<td>Igreja Nossa Senhora das Dores</td>
<td>NaN</td>
<td>NaN</td>
<td>...</td>
<td>NaN</td>
@@ -523,17 +510,17 @@ plot.geodataframes['building']
<td>NaN</td>
</tr>
<tr>
<th>126665331</th>
<th>(way, 126665331)</th>
<td>POLYGON ((-51.23167 -30.03066, -51.23160 -30.0...</td>
<td>NaN</td>
<td>NaN</td>
<td>NaN</td>
<td>1001</td>
<td>Rua dos Andradas</td>
<td>NaN</td>
<td>NaN</td>
<td>http://www.ruadapraiashopping.com.br</td>
<td>POLYGON ((-51.23167 -30.03066, -51.2316 -30.03...</td>
<td>90020-015</td>
<td>Rua da Praia Shopping</td>
<td>https://www.ruadapraiashopping.com.br/</td>
<td>NaN</td>
<td>Mo-Fr 09:00-21:00; Sa 08:00-20:00</td>
<td>...</td>
<td>NaN</td>
<td>NaN</td>
@@ -547,17 +534,17 @@ plot.geodataframes['building']
<td>NaN</td>
</tr>
<tr>
<th>129176990</th>
<th>(way, 129176990)</th>
<td>POLYGON ((-51.23117 -30.02891, -51.23120 -30.0...</td>
<td>NaN</td>
<td>NaN</td>
<td>NaN</td>
<td>1020</td>
<td>Rua 7 de Setembro</td>
<td>NaN</td>
<td>NaN</td>
<td>http://www.memorial.rs.gov.br</td>
<td>POLYGON ((-51.23117 -30.02891, -51.2312 -30.02...</td>
<td>90010-191</td>
<td>Memorial do Rio Grande do Sul</td>
<td>NaN</td>
<td>Tu-Sa 10:00-18:00</td>
<td>...</td>
<td>NaN</td>
<td>NaN</td>
@@ -571,17 +558,17 @@ plot.geodataframes['building']
<td>NaN</td>
</tr>
<tr>
<th>129176991</th>
<th>(way, 129176991)</th>
<td>POLYGON ((-51.23153 -30.02914, -51.23156 -30.0...</td>
<td>NaN</td>
<td>NaN</td>
<td>NaN</td>
<td>NaN</td>
<td>Praça da Alfândega</td>
<td>NaN</td>
<td>NaN</td>
<td>http://www.margs.rs.gov.br</td>
<td>POLYGON ((-51.23153 -30.02914, -51.23156 -30.0...</td>
<td>90010-150</td>
<td>Museu de Arte do Rio Grande do Sul</td>
<td>https://www.margs.rs.gov.br/</td>
<td>NaN</td>
<td>Tu-Su 10:00-19:00</td>
<td>...</td>
<td>NaN</td>
<td>NaN</td>
@@ -595,7 +582,6 @@ plot.geodataframes['building']
<td>NaN</td>
</tr>
<tr>
<th>...</th>
<th>...</th>
<td>...</td>
<td>...</td>
@@ -620,40 +606,39 @@ plot.geodataframes['building']
<td>...</td>
</tr>
<tr>
<th rowspan="5" valign="top">relation</th>
<th>6760281</th>
<td>NaN</td>
<td>NaN</td>
<td>NaN</td>
<td>NaN</td>
<td>NaN</td>
<th>(relation, 6760281)</th>
<td>POLYGON ((-51.23238 -30.03337, -51.23223 -30.0...</td>
<td>NaN</td>
<td>NaN</td>
<td>NaN</td>
<td>NaN</td>
<td>...</td>
<td>NaN</td>
<td>NaN</td>
<td>NaN</td>
<td>NaN</td>
<td>NaN</td>
<td>...</td>
<td>NaN</td>
<td>NaN</td>
<td>NaN</td>
<td>NaN</td>
<td>[457506887, 457506886]</td>
<td>NaN</td>
<td>NaN</td>
<td>multipolygon</td>
<td>NaN</td>
<td>NaN</td>
</tr>
<tr>
<th>6760282</th>
<th>(relation, 6760282)</th>
<td>POLYGON ((-51.23203 -30.03340, -51.23203 -30.0...</td>
<td>NaN</td>
<td>NaN</td>
<td>NaN</td>
<td>NaN</td>
<td>NaN</td>
<td>NaN</td>
<td>POLYGON ((-51.23203 -30.0334, -51.23203 -30.03...</td>
<td>NaN</td>
<td>Atheneu Espírita Cruzeiro do Sul</td>
<td>NaN</td>
<td>NaN</td>
<td>...</td>
@@ -661,23 +646,23 @@ plot.geodataframes['building']
<td>NaN</td>
<td>NaN</td>
<td>NaN</td>
<td>NaN</td>
<td>[457506875, 457506889, 457506888]</td>
<td>NaN</td>
<td>NaN</td>
<td>multipolygon</td>
<td>NaN</td>
<td>NaN</td>
</tr>
<tr>
<th>6760283</th>
<td>NaN</td>
<td>NaN</td>
<td>NaN</td>
<td>NaN</td>
<td>NaN</td>
<th>(relation, 6760283)</th>
<td>POLYGON ((-51.23284 -30.03367, -51.23288 -30.0...</td>
<td>NaN</td>
<td>Palacete Chaves</td>
<td>NaN</td>
<td>NaN</td>
<td>NaN</td>
<td>NaN</td>
<td>NaN</td>
<td>NaN</td>
<td>NaN</td>
<td>NaN</td>
<td>...</td>
@@ -685,64 +670,64 @@ plot.geodataframes['building']
<td>NaN</td>
<td>NaN</td>
<td>NaN</td>
<td>NaN</td>
<td>[457506897, 457506896]</td>
<td>NaN</td>
<td>NaN</td>
<td>multipolygon</td>
<td>NaN</td>
<td>Theodor Wiederspahn</td>
</tr>
<tr>
<th>6760284</th>
<td>NaN</td>
<td>NaN</td>
<td>NaN</td>
<td>NaN</td>
<td>NaN</td>
<th>(relation, 6760284)</th>
<td>POLYGON ((-51.23499 -30.03412, -51.23498 -30.0...</td>
<td>NaN</td>
<td>NaN</td>
<td>NaN</td>
<td>NaN</td>
<td>...</td>
<td>NaN</td>
<td>NaN</td>
<td>NaN</td>
<td>NaN</td>
<td>NaN</td>
<td>...</td>
<td>NaN</td>
<td>NaN</td>
<td>NaN</td>
<td>NaN</td>
<td>[457506910, 457506913]</td>
<td>NaN</td>
<td>NaN</td>
<td>multipolygon</td>
<td>NaN</td>
<td>NaN</td>
</tr>
<tr>
<th>14393526</th>
<th>(relation, 14393526)</th>
<td>POLYGON ((-51.23125 -30.02813, -51.23128 -30.0...</td>
<td>NaN</td>
<td>NaN</td>
<td>NaN</td>
<td>1044</td>
<td>Rua Siqueira Campos</td>
<td>NaN</td>
<td>NaN</td>
<td>https://www.sefaz.rs.gov.br</td>
<td>POLYGON ((-51.23125 -30.02813, -51.23128 -30.0...</td>
<td>NaN</td>
<td>Secretaria Estadual da Fazenda</td>
<td>NaN</td>
<td>NaN</td>
<td>...</td>
<td>NaN</td>
<td>NaN</td>
<td>NaN</td>
<td>NaN</td>
<td>NaN</td>
<td>[236213286, 1081974882]</td>
<td>NaN</td>
<td>NaN</td>
<td>multipolygon</td>
<td>NaN</td>
<td>NaN</td>
</tr>
</tbody>
</table>
<p>2423 rows × 105 columns</p>
<p>2420 rows × 167 columns</p>
</div>
@@ -756,7 +741,7 @@ plot.geodataframes['building'][
].geometry[0]
```
/home/marcelo/anaconda3/envs/prettymaps/lib/python3.11/site-packages/geopandas/geoseries.py:720: FutureWarning: Series.__getitem__ treating keys as positions is deprecated. In a future version, integer keys will always be treated as labels (consistent with DataFrame behavior). To access a value by position, use `ser.iloc[pos]`
/home/marcelo/anaconda3/envs/prettymaps/lib/python3.11/site-packages/geopandas/geoseries.py:648: FutureWarning: Series.__getitem__ treating keys as positions is deprecated. In a future version, integer keys will always be treated as labels (consistent with DataFrame behavior). To access a value by position, use `ser.iloc[pos]`
val = getattr(super(), mtd)(*args, **kwargs)
@@ -764,7 +749,7 @@ plot.geodataframes['building'][
![svg](README_files/README_22_1.svg)
![svg](README_files/README_21_1.svg)
@@ -805,7 +790,7 @@ for ax,building in zip(np.concatenate(axes),buildings):
![png](README_files/README_24_0.png)
![png](README_files/README_23_0.png)
@@ -818,6 +803,7 @@ import prettymaps
plot = prettymaps.plot(
(41.39491,2.17557),
preset = 'barcelona',
show = False # We don't want to render the map yet
)
# Change background color
@@ -830,12 +816,6 @@ _ = plot.ax.set_title(
)
```
![png](README_files/README_26_0.png)
Use **plotter** mode to export a pen plotter-compatible SVG (thanks to abey79's amazing [vsketch](https://github.com/abey79/vsketch) library)
@@ -854,7 +834,7 @@ plot = prettymaps.plot(
![png](README_files/README_28_0.png)
![png](README_files/README_27_0.png)
@@ -865,27 +845,17 @@ Some other examples
import prettymaps
plot = prettymaps.plot(
# City name
'Barra da Tijuca',
dilate = 0,
figsize = (22,10),
preset = 'tijuca',
)
```
```python
import prettymaps
plot = prettymaps.plot(
'Stad van de Zon, Heerhugowaard, Netherlands',
preset = 'heerhugowaard',
adjust_aspect_ratio = False
)
```
![png](README_files/README_31_0.png)
![png](README_files/README_29_0.png)
@@ -953,189 +923,6 @@ prettymaps.preset('my-preset')
Use prettymaps.delete_preset() to delete presets:
```python
# Show presets before deletion
print('Before deletion:')
display(prettymaps.presets())
# Delete 'my-preset'
prettymaps.delete_preset('my-preset')
# Show presets after deletion
print('After deletion:')
display(prettymaps.presets())
```
Before deletion:
<div>
<style scoped>
.dataframe tbody tr th:only-of-type {
vertical-align: middle;
}
.dataframe tbody tr th {
vertical-align: top;
}
.dataframe thead th {
text-align: right;
}
</style>
<table border="1" class="dataframe">
<thead>
<tr style="text-align: right;">
<th></th>
<th>preset</th>
<th>params</th>
</tr>
</thead>
<tbody>
<tr>
<th>0</th>
<td>abraca-redencao</td>
<td>{'layers': {'perimeter': {}, 'streets': {'widt...</td>
</tr>
<tr>
<th>1</th>
<td>barcelona</td>
<td>{'layers': {'perimeter': {'circle': False}, 's...</td>
</tr>
<tr>
<th>2</th>
<td>barcelona-plotter</td>
<td>{'layers': {'streets': {'width': {'primary': 5...</td>
</tr>
<tr>
<th>3</th>
<td>cb-bf-f</td>
<td>{'layers': {'streets': {'width': {'trunk': 6, ...</td>
</tr>
<tr>
<th>4</th>
<td>default</td>
<td>{'layers': {'perimeter': {}, 'streets': {'widt...</td>
</tr>
<tr>
<th>5</th>
<td>heerhugowaard</td>
<td>{'layers': {'perimeter': {}, 'streets': {'widt...</td>
</tr>
<tr>
<th>6</th>
<td>macao</td>
<td>{'layers': {'perimeter': {}, 'streets': {'cust...</td>
</tr>
<tr>
<th>7</th>
<td>minimal</td>
<td>{'layers': {'perimeter': {}, 'streets': {'widt...</td>
</tr>
<tr>
<th>8</th>
<td>my-preset</td>
<td>{'layers': {'building': {'tags': {'building': ...</td>
</tr>
<tr>
<th>9</th>
<td>plotter</td>
<td>{'layers': {'perimeter': {}, 'streets': {'widt...</td>
</tr>
<tr>
<th>10</th>
<td>tijuca</td>
<td>{'layers': {'perimeter': {}, 'streets': {'widt...</td>
</tr>
</tbody>
</table>
</div>
After deletion:
<div>
<style scoped>
.dataframe tbody tr th:only-of-type {
vertical-align: middle;
}
.dataframe tbody tr th {
vertical-align: top;
}
.dataframe thead th {
text-align: right;
}
</style>
<table border="1" class="dataframe">
<thead>
<tr style="text-align: right;">
<th></th>
<th>preset</th>
<th>params</th>
</tr>
</thead>
<tbody>
<tr>
<th>0</th>
<td>abraca-redencao</td>
<td>{'layers': {'perimeter': {}, 'streets': {'widt...</td>
</tr>
<tr>
<th>1</th>
<td>barcelona</td>
<td>{'layers': {'perimeter': {'circle': False}, 's...</td>
</tr>
<tr>
<th>2</th>
<td>barcelona-plotter</td>
<td>{'layers': {'streets': {'width': {'primary': 5...</td>
</tr>
<tr>
<th>3</th>
<td>cb-bf-f</td>
<td>{'layers': {'streets': {'width': {'trunk': 6, ...</td>
</tr>
<tr>
<th>4</th>
<td>default</td>
<td>{'layers': {'perimeter': {}, 'streets': {'widt...</td>
</tr>
<tr>
<th>5</th>
<td>heerhugowaard</td>
<td>{'layers': {'perimeter': {}, 'streets': {'widt...</td>
</tr>
<tr>
<th>6</th>
<td>macao</td>
<td>{'layers': {'perimeter': {}, 'streets': {'cust...</td>
</tr>
<tr>
<th>7</th>
<td>minimal</td>
<td>{'layers': {'perimeter': {}, 'streets': {'widt...</td>
</tr>
<tr>
<th>8</th>
<td>plotter</td>
<td>{'layers': {'perimeter': {}, 'streets': {'widt...</td>
</tr>
<tr>
<th>9</th>
<td>tijuca</td>
<td>{'layers': {'perimeter': {}, 'streets': {'widt...</td>
</tr>
</tbody>
</table>
</div>
Use **prettymaps.multiplot** and **prettymaps.Subplot** to draw multiple regions on the same canvas
@@ -1154,6 +941,7 @@ plot = prettymaps.multiplot(
),
prettymaps.Subplot(
'Farroupilha, Porto Alegre',
layers = {'building': {'tags': {'building': True}}},
style={'building': {'palette': ['#EEE4E1', '#E7D8C9', '#E6BEAE']}}
),
# Load a global preset
@@ -1165,23 +953,78 @@ plot = prettymaps.multiplot(
![png](README_files/README_37_0.png)
![png](README_files/README_33_0.png)
<Figure size 3600x3600 with 0 Axes>
<Figure size 3600x3600 with 0 Axes>
<Figure size 3600x3600 with 0 Axes>
# Add hillshade
```python
plot = prettymaps.plot(
'Honolulu',
radius = 5500,
figsize = 'a4',
layers = {'hillshade': {
'azdeg': 315,
'altdeg': 45,
'vert_exag': 1,
'dx': 1,
'dy': 1,
'alpha': 0.75,
}},
)
```
The autoreload extension is already loaded. To reload it, use:
%reload_ext autoreload
make: Entering directory '/home/marcelo/.cache/elevation/SRTM1'
make: Nothing to be done for 'download'.
make: Leaving directory '/home/marcelo/.cache/elevation/SRTM1'
make: Entering directory '/home/marcelo/.cache/elevation/SRTM1'
make: Nothing to be done for 'all'.
make: Leaving directory '/home/marcelo/.cache/elevation/SRTM1'
make: Entering directory '/home/marcelo/.cache/elevation/SRTM1'
cp SRTM1.vrt SRTM1.2d5b6f11e0e74b44a9386ba897fb0852.vrt
make: Leaving directory '/home/marcelo/.cache/elevation/SRTM1'
make: Entering directory '/home/marcelo/.cache/elevation/SRTM1'
gdal_translate -q -co TILED=YES -co COMPRESS=DEFLATE -co ZLEVEL=9 -co PREDICTOR=2 -projwin -157.90125854957773 21.364471426268267 -157.81006761682832 21.244615177105388 SRTM1.2d5b6f11e0e74b44a9386ba897fb0852.vrt /home/marcelo/Projects/Art/prettymaps/notebooks/elevationa.tif
rm -f SRTM1.2d5b6f11e0e74b44a9386ba897fb0852.vrt
make: Leaving directory '/home/marcelo/.cache/elevation/SRTM1'
WARNING:matplotlib.axes._base:Ignoring fixed y limits to fulfill fixed data aspect with adjustable data limits.
![png](README_files/README_35_2.png)
# Add keypoints
```python
plot = prettymaps.plot(
'Garopaba',
radius = 5000,
figsize = 'a4',
layers = {'building': False},
keypoints = {
# Search for general keypoints specified by OSM tags
'tags': {'natural': ['beach']},
# Or, search by specific name or free-text search
# pretymaps will use a fuzzy string matching to search for the specified name
'specific': {
'pedra branca': {'tags': {'natural': ['peak']}},
}
},
)
```
![png](README_files/README_37_0.png)

BIN
README_files/README_14_0.png Executable file → Normal file

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.3 MiB

After

Width:  |  Height:  |  Size: 3.6 MiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.1 MiB

After

Width:  |  Height:  |  Size: 3.6 MiB

BIN
README_files/README_16_0.png Executable file → Normal file

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.1 MiB

After

Width:  |  Height:  |  Size: 1.1 MiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.4 MiB

After

Width:  |  Height:  |  Size: 1.1 MiB

0
README_files/README_20_0.svg Executable file → Normal file
View File

Before

Width:  |  Height:  |  Size: 3.4 KiB

After

Width:  |  Height:  |  Size: 3.4 KiB

View File

@@ -0,0 +1 @@
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="100.0" height="100.0" viewBox="-51.23032682800001 -30.034281028 0.0006073560000103839 0.0008053559999900983" preserveAspectRatio="xMinYMin meet"><g transform="matrix(1,0,0,-1,0,-60.067756700000004)"><path fill-rule="evenodd" fill="#66cc99" stroke="#555555" stroke-width="1.6107119999801965e-05" opacity="0.6" d="M -51.2298412,-30.03353870000001 L -51.2298154,-30.033540599999984 L -51.2298126,-30.0335408 L -51.2298129,-30.033544300000003 L -51.2297808,-30.033546700000002 L -51.2297805,-30.033544400000007 L -51.2297758,-30.0335447 L -51.2297562,-30.0335462 L -51.2297493,-30.033546699999995 L -51.2297572,-30.033627 L -51.22975770000001,-30.033632 L -51.2298302,-30.033626299999995 L -51.2298538,-30.033865 L -51.2298442,-30.033865799999994 L -51.2298477,-30.033909500000004 L -51.2298412,-30.03390990000001 L -51.2298357,-30.03390249999999 L -51.2298133,-30.033912799999996 L -51.2298168,-30.0339188 L -51.2297959,-30.0339406 L -51.2297906,-30.033939 L -51.2297826,-30.03395859999999 L -51.2297866,-30.033959199999998 L -51.2297957,-30.034019000000004 L -51.2297902,-30.034021399999997 L -51.229800700000006,-30.0340417 L -51.2298073,-30.0340393 L -51.2298344,-30.034053999999994 L -51.2298319,-30.034065200000008 L -51.2298509,-30.034070399999994 L -51.2298558,-30.034059600000003 L -51.2298704,-30.0340585 L -51.2298741,-30.034097 L -51.2298921,-30.034095599999993 L -51.2298985,-30.03416019999999 L -51.2298609,-30.034163 L -51.2298683,-30.034238599999984 L -51.2299531,-30.0342322 L -51.2299549,-30.0342512 L -51.2301846,-30.034234 L -51.2301825,-30.03421339999999 L -51.2302643,-30.03420729999999 L -51.2302569,-30.034132200000002 L -51.2302241,-30.034134599999994 L -51.2302178,-30.0340702 L -51.2302266,-30.034069400000007 L -51.2302229,-30.034030399999995 L -51.2302285,-30.03403000000001 L -51.230236500000004,-30.0340294 L -51.2302396,-30.034038299999995 L -51.230256600000004,-30.03403409999999 L -51.2302532,-30.0340242 L -51.230280900000004,-30.034001599999996 L -51.2302902,-30.0340033 L -51.23029700000001,-30.03398119999999 L -51.2302871,-30.0339784 L -51.2302841,-30.033920999999992 L -51.2302898,-30.033919600000008 L -51.2302806,-30.0338995 L -51.2302726,-30.033902399999995 L -51.2302486,-30.033885599999994 L -51.2302511,-30.033877399999998 L -51.2302264,-30.033868700000003 L -51.2302198,-30.033880699999987 L -51.2302148,-30.033878999999995 L -51.230213000000006,-30.03383810000001 L -51.2302054,-30.033838700000004 L -51.2301818,-30.0336 L -51.2302499,-30.033594899999997 L -51.2302471,-30.033566499999996 L -51.2302452,-30.033566699999998 L -51.2302423,-30.0335373 L -51.2302448,-30.033537100000004 L -51.2302419,-30.0335085 L -51.2302051,-30.033511199999992 L -51.2302053,-30.03351359999999 L -51.2301756,-30.0335159 L -51.2301752,-30.033512399999992 L -51.23014450000001,-30.0335147 L -51.2301449,-30.033518200000003 L -51.2300854,-30.033522699999995 L -51.2300843,-30.03351139999999 L -51.2300823,-30.0335115 L -51.2300635,-30.033512799999997 L -51.2300628,-30.033505500000008 L -51.2300334,-30.0335078 L -51.2300336,-30.03350989999999 L -51.2300339,-30.033513 L -51.22995280000001,-30.033519100000003 L -51.229952600000004,-30.033516999999996 L -51.2299524,-30.0335151 L -51.2299225,-30.03351729999999 L -51.2299228,-30.033520499999998 L -51.2298995,-30.03352229999999 L -51.2299009,-30.033536999999992 L -51.2298443,-30.033541300000003 L -51.229844,-30.0335385 L -51.2298412,-30.03353870000001 z" /></g></svg>

After

Width:  |  Height:  |  Size: 3.4 KiB

BIN
README_files/README_22_0.png Executable file → Normal file

Binary file not shown.

Before

Width:  |  Height:  |  Size: 68 KiB

After

Width:  |  Height:  |  Size: 65 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 65 KiB

After

Width:  |  Height:  |  Size: 65 KiB

0
README_files/README_24_0.png Executable file → Normal file
View File

Before

Width:  |  Height:  |  Size: 65 KiB

After

Width:  |  Height:  |  Size: 65 KiB

0
README_files/README_26_0.png Executable file → Normal file
View File

Before

Width:  |  Height:  |  Size: 5.4 MiB

After

Width:  |  Height:  |  Size: 5.4 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.4 MiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 164 KiB

After

Width:  |  Height:  |  Size: 2.4 MiB

BIN
README_files/README_28_0.png Executable file → Normal file

Binary file not shown.

Before

Width:  |  Height:  |  Size: 164 KiB

After

Width:  |  Height:  |  Size: 1.6 MiB

BIN
README_files/README_29_0.png Executable file → Normal file

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.1 MiB

After

Width:  |  Height:  |  Size: 1.6 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 780 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 779 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.2 MiB

0
README_files/README_35_0.png Executable file → Normal file
View File

Before

Width:  |  Height:  |  Size: 1.2 MiB

After

Width:  |  Height:  |  Size: 1.2 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.2 MiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 800 KiB

After

Width:  |  Height:  |  Size: 2.3 MiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 800 KiB

After

Width:  |  Height:  |  Size: 2.3 MiB

BIN
README_files/README_6_0.png Executable file → Normal file

Binary file not shown.

Before

Width:  |  Height:  |  Size: 903 KiB

After

Width:  |  Height:  |  Size: 2.2 MiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.0 MiB

After

Width:  |  Height:  |  Size: 2.2 MiB

BIN
README_files/README_8_0.png Executable file → Normal file

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.0 MiB

After

Width:  |  Height:  |  Size: 1.1 MiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.5 MiB

After

Width:  |  Height:  |  Size: 1.1 MiB

186
app.py Normal file
View File

@@ -0,0 +1,186 @@
import streamlit as st
import logging
from matplotlib import pyplot as plt
import sys
import os
import io
# Set Streamlit to use the wide layout
st.set_page_config(layout="wide")
# Add repo root to sys.path
sys.path.insert(0, os.path.abspath(os.path.dirname(__file__)))
import prettymaps
# Initialize session state for last_image
if "last_image" not in st.session_state:
st.session_state.last_image = None
logging.basicConfig(
level=logging.INFO, format="%(asctime)s - %(levelname)s - %(message)s"
)
presets = prettymaps.presets().to_dict()
# Set the title of the app
st.title("prettymaps")
cols = st.columns([1, 2])
with cols[0]:
query = st.text_area(
"Location", value="Stad van de Zon, Heerhugowaard, Netherlands", height=86
)
radius = st.slider("Radius (km)", 0.5, 10.0, 0.75, step=0.5)
circular = st.checkbox("Circular map", value=False)
# Preset selector
preset_options = list(presets["preset"].values())
selected_preset = st.selectbox(
"Select a Preset", preset_options, index=preset_options.index("default")
)
# Add input for number of colors
style = prettymaps.preset(selected_preset).params["style"]
palette = (
style["building"]["palette"]
if "building" in style and "palette" in style["building"]
else ["#433633", "#FF5E5B"]
)
num_colors = st.number_input(
"Number of colors", min_value=1, value=len(palette), step=1
)
custom_palette = {}
color_cols = st.columns(len(palette))
for i in range(len(palette) // 1): # Calculate the number of rows needed
for j, col in enumerate(color_cols):
idx = i * 4 + j
if idx < num_colors:
color = col.color_picker(
f"Color {idx + 1:02d}", palette[idx % len(palette)]
)
custom_palette[idx] = color
# Add page size options
page_size_col, dpi_col = st.columns(2)
with page_size_col:
page_size = st.selectbox(
"Page Size", ["A4", "A5", "A3", "A2", "A1", "Custom"], index=0
)
with dpi_col:
dpi = st.number_input("DPI", min_value=72, max_value=600, value=300, step=50)
if page_size == "Custom":
width = st.number_input("Custom Width (inches)", min_value=1.0, value=8.27)
height = st.number_input("Custom Height (inches)", min_value=1.0, value=11.69)
else:
page_sizes = {
"A4": (8.27, 11.69),
"A5": (5.83, 8.27),
"A3": (11.69, 16.54),
"A2": (16.54, 23.39),
"A1": (23.39, 33.11),
}
width, height = page_sizes[page_size]
# Layer selection
st.subheader("Select Layers")
layers = {
"hillshade": st.checkbox("Hillshade", value="hillshade" in style),
"buildings": st.checkbox("Buildings", value="buildings" in style),
"streets": st.checkbox("Streets", value="streets" in style),
"waterway": st.checkbox("Waterway", value="waterway" in style),
"building": st.checkbox("Building", value="building" in style),
"water": st.checkbox("Water", value="water" in style),
"sea": st.checkbox("Sea", value="sea" in style),
"forest": st.checkbox("Forest", value="forest" in style),
"green": st.checkbox("Green", value="green" in style),
"rock": st.checkbox("Rock", value="rock" in style),
"beach": st.checkbox("Beach", value="beach" in style),
"parking": st.checkbox("Parking", value="parking" in style),
}
# Hillshade parameters
if layers["hillshade"]:
st.subheader("Hillshade Parameters")
azdeg = st.number_input(
"Azimuth (degrees)", min_value=0, max_value=360, value=315
)
altdeg = st.number_input(
"Altitude (degrees)", min_value=0, max_value=90, value=45
)
vert_exag = st.number_input("Vertical Exaggeration", min_value=0.1, value=1.0)
dx = st.number_input("dx", min_value=0.1, value=1.0)
dy = st.number_input("dy", min_value=0.1, value=1.0)
alpha = st.number_input("Alpha", min_value=0.0, max_value=1.0, value=0.75)
# Add a button in a new column to the right
with cols[1]:
for i in range(0):
st.write("")
button = st.button(
"Generate",
key="generate_map",
help="Click to generate the map",
type="primary",
icon=":material/map:",
use_container_width=True,
)
if button: # or "last_image" in st.session_state:
hillshade_params = (
{
"azdeg": azdeg,
"altdeg": altdeg,
"vert_exag": vert_exag,
"dx": dx,
"dy": dy,
"alpha": alpha,
}
if layers["hillshade"]
else {}
)
with st.spinner("Generating map..."):
fig, ax = plt.subplots(figsize=(width, height), dpi=300)
prettymaps.plot(
query,
radius=1000 * radius,
circle=circular,
layers={k: (False if v == False else {}) for k, v in layers.items()},
style={"building": {"palette": list(custom_palette.values())}},
figsize=(width, height),
preset=selected_preset,
show=False,
ax=ax,
)
buf = io.BytesIO()
plt.savefig(buf, format="png", bbox_inches="tight", dpi=150)
buf.seek(0)
st.session_state.last_image = buf
# Save the figure to a file
fig_path = "/tmp/generated_map.png"
with open(fig_path, "wb") as f:
f.write(st.session_state.last_image.getbuffer())
# Provide a download button
with open(fig_path, "rb") as file:
btn = st.download_button(
label="Download Map",
data=file,
file_name=f"{query}.png",
mime="image/png",
use_container_width=True,
)
st.image(st.session_state.last_image, use_container_width=True)
else:
if st.session_state.last_image:
st.image(st.session_state.last_image, use_container_width=True)
else:
st.image(
"https://github.com/marceloprates/prettymaps/blob/main/prints/app_placeholder.png?raw=true",
use_container_width=True,
)

View File

@@ -1,20 +0,0 @@
# Minimal makefile for Sphinx documentation
#
# You can set these variables from the command line, and also
# from the environment for the first two.
SPHINXOPTS ?=
SPHINXBUILD ?= sphinx-build
SOURCEDIR = source
BUILDDIR = build
# Put it first so that "make" without argument is like "make help".
help:
@$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
.PHONY: help Makefile
# Catch-all target: route all unknown targets to Sphinx using the new
# "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS).
%: Makefile
@$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)

Binary file not shown.

Binary file not shown.

View File

@@ -1,4 +0,0 @@
# Sphinx build info version 1
# This file hashes the configuration used when building these files. When it is not found, a full rebuild will be done.
config: 8771b312a9639bc9e00f00cb777a65cf
tags: 645f666f9bcd5a90fca523b33c5a78b7

Binary file not shown.

Binary file not shown.

Binary file not shown.

View File

@@ -1,22 +0,0 @@
.. prettymaps documentation master file, created by
sphinx-quickstart on Mon Sep 6 11:38:01 2021.
You can adapt this file completely to your liking, but it should at least
contain the root `toctree` directive.
Welcome to prettymaps's documentation!
======================================
.. toctree::
:maxdepth: 2
:caption: Contents:
prettymaps
Indices and tables
==================
* :ref:`genindex`
* :ref:`modindex`
* :ref:`search`

View File

@@ -1,12 +0,0 @@
User reference
==============
User reference for the prettymaps package.
prettymaps module
--------------------
.. automodule:: prettymaps
:members:
.. autofunction:: plot

View File

@@ -1,701 +0,0 @@
@import url("basic.css");
/* -- page layout ----------------------------------------------------------- */
body {
font-family: Georgia, serif;
font-size: 17px;
background-color: #fff;
color: #000;
margin: 0;
padding: 0;
}
div.document {
width: 940px;
margin: 30px auto 0 auto;
}
div.documentwrapper {
float: left;
width: 100%;
}
div.bodywrapper {
margin: 0 0 0 220px;
}
div.sphinxsidebar {
width: 220px;
font-size: 14px;
line-height: 1.5;
}
hr {
border: 1px solid #B1B4B6;
}
div.body {
background-color: #fff;
color: #3E4349;
padding: 0 30px 0 30px;
}
div.body > .section {
text-align: left;
}
div.footer {
width: 940px;
margin: 20px auto 30px auto;
font-size: 14px;
color: #888;
text-align: right;
}
div.footer a {
color: #888;
}
p.caption {
font-family: inherit;
font-size: inherit;
}
div.relations {
display: none;
}
div.sphinxsidebar a {
color: #444;
text-decoration: none;
border-bottom: 1px dotted #999;
}
div.sphinxsidebar a:hover {
border-bottom: 1px solid #999;
}
div.sphinxsidebarwrapper {
padding: 18px 10px;
}
div.sphinxsidebarwrapper p.logo {
padding: 0;
margin: -10px 0 0 0px;
text-align: center;
}
div.sphinxsidebarwrapper h1.logo {
margin-top: -10px;
text-align: center;
margin-bottom: 5px;
text-align: left;
}
div.sphinxsidebarwrapper h1.logo-name {
margin-top: 0px;
}
div.sphinxsidebarwrapper p.blurb {
margin-top: 0;
font-style: normal;
}
div.sphinxsidebar h3,
div.sphinxsidebar h4 {
font-family: Georgia, serif;
color: #444;
font-size: 24px;
font-weight: normal;
margin: 0 0 5px 0;
padding: 0;
}
div.sphinxsidebar h4 {
font-size: 20px;
}
div.sphinxsidebar h3 a {
color: #444;
}
div.sphinxsidebar p.logo a,
div.sphinxsidebar h3 a,
div.sphinxsidebar p.logo a:hover,
div.sphinxsidebar h3 a:hover {
border: none;
}
div.sphinxsidebar p {
color: #555;
margin: 10px 0;
}
div.sphinxsidebar ul {
margin: 10px 0;
padding: 0;
color: #000;
}
div.sphinxsidebar ul li.toctree-l1 > a {
font-size: 120%;
}
div.sphinxsidebar ul li.toctree-l2 > a {
font-size: 110%;
}
div.sphinxsidebar input {
border: 1px solid #CCC;
font-family: Georgia, serif;
font-size: 1em;
}
div.sphinxsidebar hr {
border: none;
height: 1px;
color: #AAA;
background: #AAA;
text-align: left;
margin-left: 0;
width: 50%;
}
div.sphinxsidebar .badge {
border-bottom: none;
}
div.sphinxsidebar .badge:hover {
border-bottom: none;
}
/* To address an issue with donation coming after search */
div.sphinxsidebar h3.donation {
margin-top: 10px;
}
/* -- body styles ----------------------------------------------------------- */
a {
color: #004B6B;
text-decoration: underline;
}
a:hover {
color: #6D4100;
text-decoration: underline;
}
div.body h1,
div.body h2,
div.body h3,
div.body h4,
div.body h5,
div.body h6 {
font-family: Georgia, serif;
font-weight: normal;
margin: 30px 0px 10px 0px;
padding: 0;
}
div.body h1 { margin-top: 0; padding-top: 0; font-size: 240%; }
div.body h2 { font-size: 180%; }
div.body h3 { font-size: 150%; }
div.body h4 { font-size: 130%; }
div.body h5 { font-size: 100%; }
div.body h6 { font-size: 100%; }
a.headerlink {
color: #DDD;
padding: 0 4px;
text-decoration: none;
}
a.headerlink:hover {
color: #444;
background: #EAEAEA;
}
div.body p, div.body dd, div.body li {
line-height: 1.4em;
}
div.admonition {
margin: 20px 0px;
padding: 10px 30px;
background-color: #EEE;
border: 1px solid #CCC;
}
div.admonition tt.xref, div.admonition code.xref, div.admonition a tt {
background-color: #FBFBFB;
border-bottom: 1px solid #fafafa;
}
div.admonition p.admonition-title {
font-family: Georgia, serif;
font-weight: normal;
font-size: 24px;
margin: 0 0 10px 0;
padding: 0;
line-height: 1;
}
div.admonition p.last {
margin-bottom: 0;
}
div.highlight {
background-color: #fff;
}
dt:target, .highlight {
background: #FAF3E8;
}
div.warning {
background-color: #FCC;
border: 1px solid #FAA;
}
div.danger {
background-color: #FCC;
border: 1px solid #FAA;
-moz-box-shadow: 2px 2px 4px #D52C2C;
-webkit-box-shadow: 2px 2px 4px #D52C2C;
box-shadow: 2px 2px 4px #D52C2C;
}
div.error {
background-color: #FCC;
border: 1px solid #FAA;
-moz-box-shadow: 2px 2px 4px #D52C2C;
-webkit-box-shadow: 2px 2px 4px #D52C2C;
box-shadow: 2px 2px 4px #D52C2C;
}
div.caution {
background-color: #FCC;
border: 1px solid #FAA;
}
div.attention {
background-color: #FCC;
border: 1px solid #FAA;
}
div.important {
background-color: #EEE;
border: 1px solid #CCC;
}
div.note {
background-color: #EEE;
border: 1px solid #CCC;
}
div.tip {
background-color: #EEE;
border: 1px solid #CCC;
}
div.hint {
background-color: #EEE;
border: 1px solid #CCC;
}
div.seealso {
background-color: #EEE;
border: 1px solid #CCC;
}
div.topic {
background-color: #EEE;
}
p.admonition-title {
display: inline;
}
p.admonition-title:after {
content: ":";
}
pre, tt, code {
font-family: 'Consolas', 'Menlo', 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', monospace;
font-size: 0.9em;
}
.hll {
background-color: #FFC;
margin: 0 -12px;
padding: 0 12px;
display: block;
}
img.screenshot {
}
tt.descname, tt.descclassname, code.descname, code.descclassname {
font-size: 0.95em;
}
tt.descname, code.descname {
padding-right: 0.08em;
}
img.screenshot {
-moz-box-shadow: 2px 2px 4px #EEE;
-webkit-box-shadow: 2px 2px 4px #EEE;
box-shadow: 2px 2px 4px #EEE;
}
table.docutils {
border: 1px solid #888;
-moz-box-shadow: 2px 2px 4px #EEE;
-webkit-box-shadow: 2px 2px 4px #EEE;
box-shadow: 2px 2px 4px #EEE;
}
table.docutils td, table.docutils th {
border: 1px solid #888;
padding: 0.25em 0.7em;
}
table.field-list, table.footnote {
border: none;
-moz-box-shadow: none;
-webkit-box-shadow: none;
box-shadow: none;
}
table.footnote {
margin: 15px 0;
width: 100%;
border: 1px solid #EEE;
background: #FDFDFD;
font-size: 0.9em;
}
table.footnote + table.footnote {
margin-top: -15px;
border-top: none;
}
table.field-list th {
padding: 0 0.8em 0 0;
}
table.field-list td {
padding: 0;
}
table.field-list p {
margin-bottom: 0.8em;
}
/* Cloned from
* https://github.com/sphinx-doc/sphinx/commit/ef60dbfce09286b20b7385333d63a60321784e68
*/
.field-name {
-moz-hyphens: manual;
-ms-hyphens: manual;
-webkit-hyphens: manual;
hyphens: manual;
}
table.footnote td.label {
width: .1px;
padding: 0.3em 0 0.3em 0.5em;
}
table.footnote td {
padding: 0.3em 0.5em;
}
dl {
margin: 0;
padding: 0;
}
dl dd {
margin-left: 30px;
}
blockquote {
margin: 0 0 0 30px;
padding: 0;
}
ul, ol {
/* Matches the 30px from the narrow-screen "li > ul" selector below */
margin: 10px 0 10px 30px;
padding: 0;
}
pre {
background: #EEE;
padding: 7px 30px;
margin: 15px 0px;
line-height: 1.3em;
}
div.viewcode-block:target {
background: #ffd;
}
dl pre, blockquote pre, li pre {
margin-left: 0;
padding-left: 30px;
}
tt, code {
background-color: #ecf0f3;
color: #222;
/* padding: 1px 2px; */
}
tt.xref, code.xref, a tt {
background-color: #FBFBFB;
border-bottom: 1px solid #fff;
}
a.reference {
text-decoration: none;
border-bottom: 1px dotted #004B6B;
}
/* Don't put an underline on images */
a.image-reference, a.image-reference:hover {
border-bottom: none;
}
a.reference:hover {
border-bottom: 1px solid #6D4100;
}
a.footnote-reference {
text-decoration: none;
font-size: 0.7em;
vertical-align: top;
border-bottom: 1px dotted #004B6B;
}
a.footnote-reference:hover {
border-bottom: 1px solid #6D4100;
}
a:hover tt, a:hover code {
background: #EEE;
}
@media screen and (max-width: 870px) {
div.sphinxsidebar {
display: none;
}
div.document {
width: 100%;
}
div.documentwrapper {
margin-left: 0;
margin-top: 0;
margin-right: 0;
margin-bottom: 0;
}
div.bodywrapper {
margin-top: 0;
margin-right: 0;
margin-bottom: 0;
margin-left: 0;
}
ul {
margin-left: 0;
}
li > ul {
/* Matches the 30px from the "ul, ol" selector above */
margin-left: 30px;
}
.document {
width: auto;
}
.footer {
width: auto;
}
.bodywrapper {
margin: 0;
}
.footer {
width: auto;
}
.github {
display: none;
}
}
@media screen and (max-width: 875px) {
body {
margin: 0;
padding: 20px 30px;
}
div.documentwrapper {
float: none;
background: #fff;
}
div.sphinxsidebar {
display: block;
float: none;
width: 102.5%;
margin: 50px -30px -20px -30px;
padding: 10px 20px;
background: #333;
color: #FFF;
}
div.sphinxsidebar h3, div.sphinxsidebar h4, div.sphinxsidebar p,
div.sphinxsidebar h3 a {
color: #fff;
}
div.sphinxsidebar a {
color: #AAA;
}
div.sphinxsidebar p.logo {
display: none;
}
div.document {
width: 100%;
margin: 0;
}
div.footer {
display: none;
}
div.bodywrapper {
margin: 0;
}
div.body {
min-height: 0;
padding: 0;
}
.rtd_doc_footer {
display: none;
}
.document {
width: auto;
}
.footer {
width: auto;
}
.footer {
width: auto;
}
.github {
display: none;
}
}
/* misc. */
.revsys-inline {
display: none!important;
}
/* Make nested-list/multi-paragraph items look better in Releases changelog
* pages. Without this, docutils' magical list fuckery causes inconsistent
* formatting between different release sub-lists.
*/
div#changelog > div.section > ul > li > p:only-child {
margin-bottom: 0;
}
/* Hide fugly table cell borders in ..bibliography:: directive output */
table.docutils.citation, table.docutils.citation td, table.docutils.citation th {
border: none;
/* Below needed in some edge cases; if not applied, bottom shadows appear */
-moz-box-shadow: none;
-webkit-box-shadow: none;
box-shadow: none;
}
/* relbar */
.related {
line-height: 30px;
width: 100%;
font-size: 0.9rem;
}
.related.top {
border-bottom: 1px solid #EEE;
margin-bottom: 20px;
}
.related.bottom {
border-top: 1px solid #EEE;
}
.related ul {
padding: 0;
margin: 0;
list-style: none;
}
.related li {
display: inline;
}
nav#rellinks {
float: right;
}
nav#rellinks li+li:before {
content: "|";
}
nav#breadcrumbs li+li:before {
content: "\00BB";
}
/* Hide certain items when printing */
@media print {
div.related {
display: none;
}
}

View File

@@ -1,855 +0,0 @@
/*
* basic.css
* ~~~~~~~~~
*
* Sphinx stylesheet -- basic theme.
*
* :copyright: Copyright 2007-2020 by the Sphinx team, see AUTHORS.
* :license: BSD, see LICENSE for details.
*
*/
/* -- main layout ----------------------------------------------------------- */
div.clearer {
clear: both;
}
div.section::after {
display: block;
content: '';
clear: left;
}
/* -- relbar ---------------------------------------------------------------- */
div.related {
width: 100%;
font-size: 90%;
}
div.related h3 {
display: none;
}
div.related ul {
margin: 0;
padding: 0 0 0 10px;
list-style: none;
}
div.related li {
display: inline;
}
div.related li.right {
float: right;
margin-right: 5px;
}
/* -- sidebar --------------------------------------------------------------- */
div.sphinxsidebarwrapper {
padding: 10px 5px 0 10px;
}
div.sphinxsidebar {
float: left;
width: 230px;
margin-left: -100%;
font-size: 90%;
word-wrap: break-word;
overflow-wrap : break-word;
}
div.sphinxsidebar ul {
list-style: none;
}
div.sphinxsidebar ul ul,
div.sphinxsidebar ul.want-points {
margin-left: 20px;
list-style: square;
}
div.sphinxsidebar ul ul {
margin-top: 0;
margin-bottom: 0;
}
div.sphinxsidebar form {
margin-top: 10px;
}
div.sphinxsidebar input {
border: 1px solid #98dbcc;
font-family: sans-serif;
font-size: 1em;
}
div.sphinxsidebar #searchbox form.search {
overflow: hidden;
}
div.sphinxsidebar #searchbox input[type="text"] {
float: left;
width: 80%;
padding: 0.25em;
box-sizing: border-box;
}
div.sphinxsidebar #searchbox input[type="submit"] {
float: left;
width: 20%;
border-left: none;
padding: 0.25em;
box-sizing: border-box;
}
img {
border: 0;
max-width: 100%;
}
/* -- search page ----------------------------------------------------------- */
ul.search {
margin: 10px 0 0 20px;
padding: 0;
}
ul.search li {
padding: 5px 0 5px 20px;
background-image: url(file.png);
background-repeat: no-repeat;
background-position: 0 7px;
}
ul.search li a {
font-weight: bold;
}
ul.search li div.context {
color: #888;
margin: 2px 0 0 30px;
text-align: left;
}
ul.keywordmatches li.goodmatch a {
font-weight: bold;
}
/* -- index page ------------------------------------------------------------ */
table.contentstable {
width: 90%;
margin-left: auto;
margin-right: auto;
}
table.contentstable p.biglink {
line-height: 150%;
}
a.biglink {
font-size: 1.3em;
}
span.linkdescr {
font-style: italic;
padding-top: 5px;
font-size: 90%;
}
/* -- general index --------------------------------------------------------- */
table.indextable {
width: 100%;
}
table.indextable td {
text-align: left;
vertical-align: top;
}
table.indextable ul {
margin-top: 0;
margin-bottom: 0;
list-style-type: none;
}
table.indextable > tbody > tr > td > ul {
padding-left: 0em;
}
table.indextable tr.pcap {
height: 10px;
}
table.indextable tr.cap {
margin-top: 10px;
background-color: #f2f2f2;
}
img.toggler {
margin-right: 3px;
margin-top: 3px;
cursor: pointer;
}
div.modindex-jumpbox {
border-top: 1px solid #ddd;
border-bottom: 1px solid #ddd;
margin: 1em 0 1em 0;
padding: 0.4em;
}
div.genindex-jumpbox {
border-top: 1px solid #ddd;
border-bottom: 1px solid #ddd;
margin: 1em 0 1em 0;
padding: 0.4em;
}
/* -- domain module index --------------------------------------------------- */
table.modindextable td {
padding: 2px;
border-collapse: collapse;
}
/* -- general body styles --------------------------------------------------- */
div.body {
min-width: 450px;
max-width: 800px;
}
div.body p, div.body dd, div.body li, div.body blockquote {
-moz-hyphens: auto;
-ms-hyphens: auto;
-webkit-hyphens: auto;
hyphens: auto;
}
a.headerlink {
visibility: hidden;
}
a.brackets:before,
span.brackets > a:before{
content: "[";
}
a.brackets:after,
span.brackets > a:after {
content: "]";
}
h1:hover > a.headerlink,
h2:hover > a.headerlink,
h3:hover > a.headerlink,
h4:hover > a.headerlink,
h5:hover > a.headerlink,
h6:hover > a.headerlink,
dt:hover > a.headerlink,
caption:hover > a.headerlink,
p.caption:hover > a.headerlink,
div.code-block-caption:hover > a.headerlink {
visibility: visible;
}
div.body p.caption {
text-align: inherit;
}
div.body td {
text-align: left;
}
.first {
margin-top: 0 !important;
}
p.rubric {
margin-top: 30px;
font-weight: bold;
}
img.align-left, .figure.align-left, object.align-left {
clear: left;
float: left;
margin-right: 1em;
}
img.align-right, .figure.align-right, object.align-right {
clear: right;
float: right;
margin-left: 1em;
}
img.align-center, .figure.align-center, object.align-center {
display: block;
margin-left: auto;
margin-right: auto;
}
img.align-default, .figure.align-default {
display: block;
margin-left: auto;
margin-right: auto;
}
.align-left {
text-align: left;
}
.align-center {
text-align: center;
}
.align-default {
text-align: center;
}
.align-right {
text-align: right;
}
/* -- sidebars -------------------------------------------------------------- */
div.sidebar {
margin: 0 0 0.5em 1em;
border: 1px solid #ddb;
padding: 7px;
background-color: #ffe;
width: 40%;
float: right;
clear: right;
overflow-x: auto;
}
p.sidebar-title {
font-weight: bold;
}
div.admonition, div.topic, blockquote {
clear: left;
}
/* -- topics ---------------------------------------------------------------- */
div.topic {
border: 1px solid #ccc;
padding: 7px;
margin: 10px 0 10px 0;
}
p.topic-title {
font-size: 1.1em;
font-weight: bold;
margin-top: 10px;
}
/* -- admonitions ----------------------------------------------------------- */
div.admonition {
margin-top: 10px;
margin-bottom: 10px;
padding: 7px;
}
div.admonition dt {
font-weight: bold;
}
p.admonition-title {
margin: 0px 10px 5px 0px;
font-weight: bold;
}
div.body p.centered {
text-align: center;
margin-top: 25px;
}
/* -- content of sidebars/topics/admonitions -------------------------------- */
div.sidebar > :last-child,
div.topic > :last-child,
div.admonition > :last-child {
margin-bottom: 0;
}
div.sidebar::after,
div.topic::after,
div.admonition::after,
blockquote::after {
display: block;
content: '';
clear: both;
}
/* -- tables ---------------------------------------------------------------- */
table.docutils {
margin-top: 10px;
margin-bottom: 10px;
border: 0;
border-collapse: collapse;
}
table.align-center {
margin-left: auto;
margin-right: auto;
}
table.align-default {
margin-left: auto;
margin-right: auto;
}
table caption span.caption-number {
font-style: italic;
}
table caption span.caption-text {
}
table.docutils td, table.docutils th {
padding: 1px 8px 1px 5px;
border-top: 0;
border-left: 0;
border-right: 0;
border-bottom: 1px solid #aaa;
}
table.footnote td, table.footnote th {
border: 0 !important;
}
th {
text-align: left;
padding-right: 5px;
}
table.citation {
border-left: solid 1px gray;
margin-left: 1px;
}
table.citation td {
border-bottom: none;
}
th > :first-child,
td > :first-child {
margin-top: 0px;
}
th > :last-child,
td > :last-child {
margin-bottom: 0px;
}
/* -- figures --------------------------------------------------------------- */
div.figure {
margin: 0.5em;
padding: 0.5em;
}
div.figure p.caption {
padding: 0.3em;
}
div.figure p.caption span.caption-number {
font-style: italic;
}
div.figure p.caption span.caption-text {
}
/* -- field list styles ----------------------------------------------------- */
table.field-list td, table.field-list th {
border: 0 !important;
}
.field-list ul {
margin: 0;
padding-left: 1em;
}
.field-list p {
margin: 0;
}
.field-name {
-moz-hyphens: manual;
-ms-hyphens: manual;
-webkit-hyphens: manual;
hyphens: manual;
}
/* -- hlist styles ---------------------------------------------------------- */
table.hlist {
margin: 1em 0;
}
table.hlist td {
vertical-align: top;
}
/* -- other body styles ----------------------------------------------------- */
ol.arabic {
list-style: decimal;
}
ol.loweralpha {
list-style: lower-alpha;
}
ol.upperalpha {
list-style: upper-alpha;
}
ol.lowerroman {
list-style: lower-roman;
}
ol.upperroman {
list-style: upper-roman;
}
:not(li) > ol > li:first-child > :first-child,
:not(li) > ul > li:first-child > :first-child {
margin-top: 0px;
}
:not(li) > ol > li:last-child > :last-child,
:not(li) > ul > li:last-child > :last-child {
margin-bottom: 0px;
}
ol.simple ol p,
ol.simple ul p,
ul.simple ol p,
ul.simple ul p {
margin-top: 0;
}
ol.simple > li:not(:first-child) > p,
ul.simple > li:not(:first-child) > p {
margin-top: 0;
}
ol.simple p,
ul.simple p {
margin-bottom: 0;
}
dl.footnote > dt,
dl.citation > dt {
float: left;
margin-right: 0.5em;
}
dl.footnote > dd,
dl.citation > dd {
margin-bottom: 0em;
}
dl.footnote > dd:after,
dl.citation > dd:after {
content: "";
clear: both;
}
dl.field-list {
display: grid;
grid-template-columns: fit-content(30%) auto;
}
dl.field-list > dt {
font-weight: bold;
word-break: break-word;
padding-left: 0.5em;
padding-right: 5px;
}
dl.field-list > dt:after {
content: ":";
}
dl.field-list > dd {
padding-left: 0.5em;
margin-top: 0em;
margin-left: 0em;
margin-bottom: 0em;
}
dl {
margin-bottom: 15px;
}
dd > :first-child {
margin-top: 0px;
}
dd ul, dd table {
margin-bottom: 10px;
}
dd {
margin-top: 3px;
margin-bottom: 10px;
margin-left: 30px;
}
dl > dd:last-child,
dl > dd:last-child > :last-child {
margin-bottom: 0;
}
dt:target, span.highlighted {
background-color: #fbe54e;
}
rect.highlighted {
fill: #fbe54e;
}
dl.glossary dt {
font-weight: bold;
font-size: 1.1em;
}
.optional {
font-size: 1.3em;
}
.sig-paren {
font-size: larger;
}
.versionmodified {
font-style: italic;
}
.system-message {
background-color: #fda;
padding: 5px;
border: 3px solid red;
}
.footnote:target {
background-color: #ffa;
}
.line-block {
display: block;
margin-top: 1em;
margin-bottom: 1em;
}
.line-block .line-block {
margin-top: 0;
margin-bottom: 0;
margin-left: 1.5em;
}
.guilabel, .menuselection {
font-family: sans-serif;
}
.accelerator {
text-decoration: underline;
}
.classifier {
font-style: oblique;
}
.classifier:before {
font-style: normal;
margin: 0.5em;
content: ":";
}
abbr, acronym {
border-bottom: dotted 1px;
cursor: help;
}
/* -- code displays --------------------------------------------------------- */
pre {
overflow: auto;
overflow-y: hidden; /* fixes display issues on Chrome browsers */
}
pre, div[class*="highlight-"] {
clear: both;
}
span.pre {
-moz-hyphens: none;
-ms-hyphens: none;
-webkit-hyphens: none;
hyphens: none;
}
div[class*="highlight-"] {
margin: 1em 0;
}
td.linenos pre {
border: 0;
background-color: transparent;
color: #aaa;
}
table.highlighttable {
display: block;
}
table.highlighttable tbody {
display: block;
}
table.highlighttable tr {
display: flex;
}
table.highlighttable td {
margin: 0;
padding: 0;
}
table.highlighttable td.linenos {
padding-right: 0.5em;
}
table.highlighttable td.code {
flex: 1;
overflow: hidden;
}
.highlight .hll {
display: block;
}
div.highlight pre,
table.highlighttable pre {
margin: 0;
}
div.code-block-caption + div {
margin-top: 0;
}
div.code-block-caption {
margin-top: 1em;
padding: 2px 5px;
font-size: small;
}
div.code-block-caption code {
background-color: transparent;
}
table.highlighttable td.linenos,
div.doctest > div.highlight span.gp { /* gp: Generic.Prompt */
user-select: none;
}
div.code-block-caption span.caption-number {
padding: 0.1em 0.3em;
font-style: italic;
}
div.code-block-caption span.caption-text {
}
div.literal-block-wrapper {
margin: 1em 0;
}
code.descname {
background-color: transparent;
font-weight: bold;
font-size: 1.2em;
}
code.descclassname {
background-color: transparent;
}
code.xref, a code {
background-color: transparent;
font-weight: bold;
}
h1 code, h2 code, h3 code, h4 code, h5 code, h6 code {
background-color: transparent;
}
.viewcode-link {
float: right;
}
.viewcode-back {
float: right;
font-family: sans-serif;
}
div.viewcode-block:target {
margin: -1px -10px;
padding: 0 10px;
}
/* -- math display ---------------------------------------------------------- */
img.math {
vertical-align: middle;
}
div.body div.math p {
text-align: center;
}
span.eqno {
float: right;
}
span.eqno a.headerlink {
position: absolute;
z-index: 1;
}
div.math:hover a.headerlink {
visibility: visible;
}
/* -- printout stylesheet --------------------------------------------------- */
@media print {
div.document,
div.documentwrapper,
div.bodywrapper {
margin: 0 !important;
width: 100%;
}
div.sphinxsidebar,
div.related,
div.footer,
#top-link {
display: none;
}
}

View File

@@ -1,266 +0,0 @@
/*
* classic.css_t
* ~~~~~~~~~~~~~
*
* Sphinx stylesheet -- classic theme.
*
* :copyright: Copyright 2007-2020 by the Sphinx team, see AUTHORS.
* :license: BSD, see LICENSE for details.
*
*/
@import url("basic.css");
/* -- page layout ----------------------------------------------------------- */
html {
/* CSS hack for macOS's scrollbar (see #1125) */
background-color: #FFFFFF;
}
body {
font-family: sans-serif;
font-size: 100%;
background-color: #11303d;
color: #000;
margin: 0;
padding: 0;
}
div.document {
background-color: #1c4e63;
}
div.documentwrapper {
float: left;
width: 100%;
}
div.bodywrapper {
margin: 0 0 0 230px;
}
div.body {
background-color: #ffffff;
color: #000000;
padding: 0 20px 30px 20px;
}
div.footer {
color: #ffffff;
width: 100%;
padding: 9px 0 9px 0;
text-align: center;
font-size: 75%;
}
div.footer a {
color: #ffffff;
text-decoration: underline;
}
div.related {
background-color: #133f52;
line-height: 30px;
color: #ffffff;
}
div.related a {
color: #ffffff;
}
div.sphinxsidebar {
}
div.sphinxsidebar h3 {
font-family: 'Trebuchet MS', sans-serif;
color: #ffffff;
font-size: 1.4em;
font-weight: normal;
margin: 0;
padding: 0;
}
div.sphinxsidebar h3 a {
color: #ffffff;
}
div.sphinxsidebar h4 {
font-family: 'Trebuchet MS', sans-serif;
color: #ffffff;
font-size: 1.3em;
font-weight: normal;
margin: 5px 0 0 0;
padding: 0;
}
div.sphinxsidebar p {
color: #ffffff;
}
div.sphinxsidebar p.topless {
margin: 5px 10px 10px 10px;
}
div.sphinxsidebar ul {
margin: 10px;
padding: 0;
color: #ffffff;
}
div.sphinxsidebar a {
color: #98dbcc;
}
div.sphinxsidebar input {
border: 1px solid #98dbcc;
font-family: sans-serif;
font-size: 1em;
}
/* -- hyperlink styles ------------------------------------------------------ */
a {
color: #355f7c;
text-decoration: none;
}
a:visited {
color: #355f7c;
text-decoration: none;
}
a:hover {
text-decoration: underline;
}
/* -- body styles ----------------------------------------------------------- */
div.body h1,
div.body h2,
div.body h3,
div.body h4,
div.body h5,
div.body h6 {
font-family: 'Trebuchet MS', sans-serif;
background-color: #f2f2f2;
font-weight: normal;
color: #20435c;
border-bottom: 1px solid #ccc;
margin: 20px -20px 10px -20px;
padding: 3px 0 3px 10px;
}
div.body h1 { margin-top: 0; font-size: 200%; }
div.body h2 { font-size: 160%; }
div.body h3 { font-size: 140%; }
div.body h4 { font-size: 120%; }
div.body h5 { font-size: 110%; }
div.body h6 { font-size: 100%; }
a.headerlink {
color: #c60f0f;
font-size: 0.8em;
padding: 0 4px 0 4px;
text-decoration: none;
}
a.headerlink:hover {
background-color: #c60f0f;
color: white;
}
div.body p, div.body dd, div.body li, div.body blockquote {
text-align: justify;
line-height: 130%;
}
div.admonition p.admonition-title + p {
display: inline;
}
div.admonition p {
margin-bottom: 5px;
}
div.admonition pre {
margin-bottom: 5px;
}
div.admonition ul, div.admonition ol {
margin-bottom: 5px;
}
div.note {
background-color: #eee;
border: 1px solid #ccc;
}
div.seealso {
background-color: #ffc;
border: 1px solid #ff6;
}
div.topic {
background-color: #eee;
}
div.warning {
background-color: #ffe4e4;
border: 1px solid #f66;
}
p.admonition-title {
display: inline;
}
p.admonition-title:after {
content: ":";
}
pre {
padding: 5px;
background-color: unset;
color: unset;
line-height: 120%;
border: 1px solid #ac9;
border-left: none;
border-right: none;
}
code {
background-color: #ecf0f3;
padding: 0 1px 0 1px;
font-size: 0.95em;
}
th, dl.field-list > dt {
background-color: #ede;
}
.warning code {
background: #efc2c2;
}
.note code {
background: #d6d6d6;
}
.viewcode-back {
font-family: sans-serif;
}
div.viewcode-block:target {
background-color: #f4debf;
border-top: 1px solid #ac9;
border-bottom: 1px solid #ac9;
}
div.code-block-caption {
color: #efefef;
background-color: #1c4e63;
}

View File

@@ -1 +0,0 @@
.fa:before{-webkit-font-smoothing:antialiased}.clearfix{*zoom:1}.clearfix:after,.clearfix:before{display:table;content:""}.clearfix:after{clear:both}@font-face{font-family:FontAwesome;font-style:normal;font-weight:400;src:url(fonts/fontawesome-webfont.eot?674f50d287a8c48dc19ba404d20fe713?#iefix) format("embedded-opentype"),url(fonts/fontawesome-webfont.woff2?af7ae505a9eed503f8b8e6982036873e) format("woff2"),url(fonts/fontawesome-webfont.woff?fee66e712a8a08eef5805a46892932ad) format("woff"),url(fonts/fontawesome-webfont.ttf?b06871f281fee6b241d60582ae9369b9) format("truetype"),url(fonts/fontawesome-webfont.svg?912ec66d7572ff821749319396470bde#FontAwesome) format("svg")}.fa:before{font-family:FontAwesome;font-style:normal;font-weight:400;line-height:1}.fa:before,a .fa{text-decoration:inherit}.fa:before,a .fa,li .fa{display:inline-block}li .fa-large:before{width:1.875em}ul.fas{list-style-type:none;margin-left:2em;text-indent:-.8em}ul.fas li .fa{width:.8em}ul.fas li .fa-large:before{vertical-align:baseline}.fa-book:before,.icon-book:before{content:"\f02d"}.fa-caret-down:before,.icon-caret-down:before{content:"\f0d7"}.fa-caret-up:before,.icon-caret-up:before{content:"\f0d8"}.fa-caret-left:before,.icon-caret-left:before{content:"\f0d9"}.fa-caret-right:before,.icon-caret-right:before{content:"\f0da"}.rst-versions{position:fixed;bottom:0;left:0;width:300px;color:#fcfcfc;background:#1f1d1d;font-family:Lato,proxima-nova,Helvetica Neue,Arial,sans-serif;z-index:400}.rst-versions a{color:#2980b9;text-decoration:none}.rst-versions .rst-badge-small{display:none}.rst-versions .rst-current-version{padding:12px;background-color:#272525;display:block;text-align:right;font-size:90%;cursor:pointer;color:#27ae60}.rst-versions .rst-current-version:after{clear:both;content:"";display:block}.rst-versions .rst-current-version .fa{color:#fcfcfc}.rst-versions .rst-current-version .fa-book,.rst-versions .rst-current-version .icon-book{float:left}.rst-versions .rst-current-version.rst-out-of-date{background-color:#e74c3c;color:#fff}.rst-versions .rst-current-version.rst-active-old-version{background-color:#f1c40f;color:#000}.rst-versions.shift-up{height:auto;max-height:100%;overflow-y:scroll}.rst-versions.shift-up .rst-other-versions{display:block}.rst-versions .rst-other-versions{font-size:90%;padding:12px;color:grey;display:none}.rst-versions .rst-other-versions hr{display:block;height:1px;border:0;margin:20px 0;padding:0;border-top:1px solid #413d3d}.rst-versions .rst-other-versions dd{display:inline-block;margin:0}.rst-versions .rst-other-versions dd a{display:inline-block;padding:6px;color:#fcfcfc}.rst-versions.rst-badge{width:auto;bottom:20px;right:20px;left:auto;border:none;max-width:300px;max-height:90%}.rst-versions.rst-badge .fa-book,.rst-versions.rst-badge .icon-book{float:none;line-height:30px}.rst-versions.rst-badge.shift-up .rst-current-version{text-align:right}.rst-versions.rst-badge.shift-up .rst-current-version .fa-book,.rst-versions.rst-badge.shift-up .rst-current-version .icon-book{float:left}.rst-versions.rst-badge>.rst-current-version{width:auto;height:30px;line-height:30px;padding:0 6px;display:block;text-align:center}@media screen and (max-width:768px){.rst-versions{width:85%;display:none}.rst-versions.shift{display:block}}

File diff suppressed because it is too large Load Diff

Before

Width:  |  Height:  |  Size: 434 KiB

Binary file not shown.

Binary file not shown.

File diff suppressed because one or more lines are too long

View File

@@ -1 +0,0 @@
/* This file intentionally left blank. */

View File

@@ -1 +0,0 @@
@import url("classic.css");

View File

@@ -1,315 +0,0 @@
/*
* doctools.js
* ~~~~~~~~~~~
*
* Sphinx JavaScript utilities for all documentation.
*
* :copyright: Copyright 2007-2020 by the Sphinx team, see AUTHORS.
* :license: BSD, see LICENSE for details.
*
*/
/**
* select a different prefix for underscore
*/
$u = _.noConflict();
/**
* make the code below compatible with browsers without
* an installed firebug like debugger
if (!window.console || !console.firebug) {
var names = ["log", "debug", "info", "warn", "error", "assert", "dir",
"dirxml", "group", "groupEnd", "time", "timeEnd", "count", "trace",
"profile", "profileEnd"];
window.console = {};
for (var i = 0; i < names.length; ++i)
window.console[names[i]] = function() {};
}
*/
/**
* small helper function to urldecode strings
*/
jQuery.urldecode = function(x) {
return decodeURIComponent(x).replace(/\+/g, ' ');
};
/**
* small helper function to urlencode strings
*/
jQuery.urlencode = encodeURIComponent;
/**
* This function returns the parsed url parameters of the
* current request. Multiple values per key are supported,
* it will always return arrays of strings for the value parts.
*/
jQuery.getQueryParameters = function(s) {
if (typeof s === 'undefined')
s = document.location.search;
var parts = s.substr(s.indexOf('?') + 1).split('&');
var result = {};
for (var i = 0; i < parts.length; i++) {
var tmp = parts[i].split('=', 2);
var key = jQuery.urldecode(tmp[0]);
var value = jQuery.urldecode(tmp[1]);
if (key in result)
result[key].push(value);
else
result[key] = [value];
}
return result;
};
/**
* highlight a given string on a jquery object by wrapping it in
* span elements with the given class name.
*/
jQuery.fn.highlightText = function(text, className) {
function highlight(node, addItems) {
if (node.nodeType === 3) {
var val = node.nodeValue;
var pos = val.toLowerCase().indexOf(text);
if (pos >= 0 &&
!jQuery(node.parentNode).hasClass(className) &&
!jQuery(node.parentNode).hasClass("nohighlight")) {
var span;
var isInSVG = jQuery(node).closest("body, svg, foreignObject").is("svg");
if (isInSVG) {
span = document.createElementNS("http://www.w3.org/2000/svg", "tspan");
} else {
span = document.createElement("span");
span.className = className;
}
span.appendChild(document.createTextNode(val.substr(pos, text.length)));
node.parentNode.insertBefore(span, node.parentNode.insertBefore(
document.createTextNode(val.substr(pos + text.length)),
node.nextSibling));
node.nodeValue = val.substr(0, pos);
if (isInSVG) {
var rect = document.createElementNS("http://www.w3.org/2000/svg", "rect");
var bbox = node.parentElement.getBBox();
rect.x.baseVal.value = bbox.x;
rect.y.baseVal.value = bbox.y;
rect.width.baseVal.value = bbox.width;
rect.height.baseVal.value = bbox.height;
rect.setAttribute('class', className);
addItems.push({
"parent": node.parentNode,
"target": rect});
}
}
}
else if (!jQuery(node).is("button, select, textarea")) {
jQuery.each(node.childNodes, function() {
highlight(this, addItems);
});
}
}
var addItems = [];
var result = this.each(function() {
highlight(this, addItems);
});
for (var i = 0; i < addItems.length; ++i) {
jQuery(addItems[i].parent).before(addItems[i].target);
}
return result;
};
/*
* backward compatibility for jQuery.browser
* This will be supported until firefox bug is fixed.
*/
if (!jQuery.browser) {
jQuery.uaMatch = function(ua) {
ua = ua.toLowerCase();
var match = /(chrome)[ \/]([\w.]+)/.exec(ua) ||
/(webkit)[ \/]([\w.]+)/.exec(ua) ||
/(opera)(?:.*version|)[ \/]([\w.]+)/.exec(ua) ||
/(msie) ([\w.]+)/.exec(ua) ||
ua.indexOf("compatible") < 0 && /(mozilla)(?:.*? rv:([\w.]+)|)/.exec(ua) ||
[];
return {
browser: match[ 1 ] || "",
version: match[ 2 ] || "0"
};
};
jQuery.browser = {};
jQuery.browser[jQuery.uaMatch(navigator.userAgent).browser] = true;
}
/**
* Small JavaScript module for the documentation.
*/
var Documentation = {
init : function() {
this.fixFirefoxAnchorBug();
this.highlightSearchWords();
this.initIndexTable();
if (DOCUMENTATION_OPTIONS.NAVIGATION_WITH_KEYS) {
this.initOnKeyListeners();
}
},
/**
* i18n support
*/
TRANSLATIONS : {},
PLURAL_EXPR : function(n) { return n === 1 ? 0 : 1; },
LOCALE : 'unknown',
// gettext and ngettext don't access this so that the functions
// can safely bound to a different name (_ = Documentation.gettext)
gettext : function(string) {
var translated = Documentation.TRANSLATIONS[string];
if (typeof translated === 'undefined')
return string;
return (typeof translated === 'string') ? translated : translated[0];
},
ngettext : function(singular, plural, n) {
var translated = Documentation.TRANSLATIONS[singular];
if (typeof translated === 'undefined')
return (n == 1) ? singular : plural;
return translated[Documentation.PLURALEXPR(n)];
},
addTranslations : function(catalog) {
for (var key in catalog.messages)
this.TRANSLATIONS[key] = catalog.messages[key];
this.PLURAL_EXPR = new Function('n', 'return +(' + catalog.plural_expr + ')');
this.LOCALE = catalog.locale;
},
/**
* add context elements like header anchor links
*/
addContextElements : function() {
$('div[id] > :header:first').each(function() {
$('<a class="headerlink">\u00B6</a>').
attr('href', '#' + this.id).
attr('title', _('Permalink to this headline')).
appendTo(this);
});
$('dt[id]').each(function() {
$('<a class="headerlink">\u00B6</a>').
attr('href', '#' + this.id).
attr('title', _('Permalink to this definition')).
appendTo(this);
});
},
/**
* workaround a firefox stupidity
* see: https://bugzilla.mozilla.org/show_bug.cgi?id=645075
*/
fixFirefoxAnchorBug : function() {
if (document.location.hash && $.browser.mozilla)
window.setTimeout(function() {
document.location.href += '';
}, 10);
},
/**
* highlight the search words provided in the url in the text
*/
highlightSearchWords : function() {
var params = $.getQueryParameters();
var terms = (params.highlight) ? params.highlight[0].split(/\s+/) : [];
if (terms.length) {
var body = $('div.body');
if (!body.length) {
body = $('body');
}
window.setTimeout(function() {
$.each(terms, function() {
body.highlightText(this.toLowerCase(), 'highlighted');
});
}, 10);
$('<p class="highlight-link"><a href="javascript:Documentation.' +
'hideSearchWords()">' + _('Hide Search Matches') + '</a></p>')
.appendTo($('#searchbox'));
}
},
/**
* init the domain index toggle buttons
*/
initIndexTable : function() {
var togglers = $('img.toggler').click(function() {
var src = $(this).attr('src');
var idnum = $(this).attr('id').substr(7);
$('tr.cg-' + idnum).toggle();
if (src.substr(-9) === 'minus.png')
$(this).attr('src', src.substr(0, src.length-9) + 'plus.png');
else
$(this).attr('src', src.substr(0, src.length-8) + 'minus.png');
}).css('display', '');
if (DOCUMENTATION_OPTIONS.COLLAPSE_INDEX) {
togglers.click();
}
},
/**
* helper function to hide the search marks again
*/
hideSearchWords : function() {
$('#searchbox .highlight-link').fadeOut(300);
$('span.highlighted').removeClass('highlighted');
},
/**
* make the url absolute
*/
makeURL : function(relativeURL) {
return DOCUMENTATION_OPTIONS.URL_ROOT + '/' + relativeURL;
},
/**
* get the current relative url
*/
getCurrentURL : function() {
var path = document.location.pathname;
var parts = path.split(/\//);
$.each(DOCUMENTATION_OPTIONS.URL_ROOT.split(/\//), function() {
if (this === '..')
parts.pop();
});
var url = parts.join('/');
return path.substring(url.lastIndexOf('/') + 1, path.length - 1);
},
initOnKeyListeners: function() {
$(document).keydown(function(event) {
var activeElementType = document.activeElement.tagName;
// don't navigate when in search box or textarea
if (activeElementType !== 'TEXTAREA' && activeElementType !== 'INPUT' && activeElementType !== 'SELECT'
&& !event.altKey && !event.ctrlKey && !event.metaKey && !event.shiftKey) {
switch (event.keyCode) {
case 37: // left
var prevHref = $('link[rel="prev"]').prop('href');
if (prevHref) {
window.location.href = prevHref;
return false;
}
case 39: // right
var nextHref = $('link[rel="next"]').prop('href');
if (nextHref) {
window.location.href = nextHref;
return false;
}
}
}
});
}
};
// quick alias for translations
_ = Documentation.gettext;
$(document).ready(function() {
Documentation.init();
});

View File

@@ -1,12 +0,0 @@
var DOCUMENTATION_OPTIONS = {
URL_ROOT: document.getElementById("documentation_options").getAttribute('data-url_root'),
VERSION: '1.0.0',
LANGUAGE: 'None',
COLLAPSE_INDEX: false,
BUILDER: 'html',
FILE_SUFFIX: '.html',
LINK_SUFFIX: '.html',
HAS_SOURCE: true,
SOURCELINK_SUFFIX: '.txt',
NAVIGATION_WITH_KEYS: false
};

Binary file not shown.

Before

Width:  |  Height:  |  Size: 286 B

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Some files were not shown because too many files have changed in this diff Show More