-
Notifications
You must be signed in to change notification settings - Fork 364
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
2 changed files
with
76 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -128,6 +128,8 @@ dmypy.json | |
# Pyre type checker | ||
.pyre/ | ||
|
||
<_io.BytesIO* | ||
.vscode/* | ||
.idea/ | ||
cache/ | ||
prettybasicmaps/cache | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,74 @@ | ||
{ | ||
"cells": [ | ||
{ | ||
"cell_type": "code", | ||
"execution_count": null, | ||
"id": "770d1893-70b9-4c65-8651-903346f355a9", | ||
"metadata": {}, | ||
"outputs": [], | ||
"source": [ | ||
"from prettymapp.geo import get_aoi\n", | ||
"from prettymapp.osm import get_osm_geometries\n", | ||
"from prettymapp.plotting import Plot\n", | ||
"from prettymapp.settings import STYLES\n", | ||
"\n", | ||
"aoi = get_aoi(address=\"Praça Ferreira do Amaral, Macau\", radius=1100, rectangular=False)\n", | ||
"df = get_osm_geometries(aoi=aoi)\n", | ||
"\n", | ||
"fig = Plot(\n", | ||
" df=df,\n", | ||
" aoi_bounds=aoi.bounds,\n", | ||
" draw_settings=STYLES[\"Peach\"]\n", | ||
").plot_all()\n" | ||
] | ||
}, | ||
{ | ||
"cell_type": "code", | ||
"execution_count": null, | ||
"id": "1321e1fb-82d9-4d15-a4a3-696422063ecc", | ||
"metadata": {}, | ||
"outputs": [], | ||
"source": [ | ||
"from prettymapp.osm import get_osm_geometries_from_xml\n", | ||
"\n", | ||
"df = get_osm_geometries_from_xml(filepath=\"./tests/mock_data/osm_xml_file.osm\")\n", | ||
"aoi_bounds = df.total_bounds\n", | ||
"\n", | ||
"fig = Plot(\n", | ||
" df=df,\n", | ||
" aoi_bounds=aoi_bounds,\n", | ||
" draw_settings=STYLES[\"Peach\"]\n", | ||
").plot_all()" | ||
] | ||
}, | ||
{ | ||
"cell_type": "code", | ||
"execution_count": null, | ||
"id": "787f0a25-0eb4-45de-8889-2db572c09c26", | ||
"metadata": {}, | ||
"outputs": [], | ||
"source": [] | ||
} | ||
], | ||
"metadata": { | ||
"kernelspec": { | ||
"display_name": "prettymapp", | ||
"language": "python", | ||
"name": "prettymapp" | ||
}, | ||
"language_info": { | ||
"codemirror_mode": { | ||
"name": "ipython", | ||
"version": 3 | ||
}, | ||
"file_extension": ".py", | ||
"mimetype": "text/x-python", | ||
"name": "python", | ||
"nbconvert_exporter": "python", | ||
"pygments_lexer": "ipython3", | ||
"version": "3.12.3" | ||
} | ||
}, | ||
"nbformat": 4, | ||
"nbformat_minor": 5 | ||
} |