starplot 0.12.0__tar.gz → 0.12.2__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of starplot might be problematic. Click here for more details.
- {starplot-0.12.0 → starplot-0.12.2}/PKG-INFO +1 -1
- {starplot-0.12.0 → starplot-0.12.2}/docs/changelog.md +2 -0
- {starplot-0.12.0 → starplot-0.12.2}/docs/tutorial/09.md +3 -1
- {starplot-0.12.0 → starplot-0.12.2}/hash_checks/hashlock.yml +9 -5
- {starplot-0.12.0 → starplot-0.12.2}/hash_checks/map_checks.py +40 -19
- {starplot-0.12.0 → starplot-0.12.2}/src/starplot/__init__.py +1 -1
- {starplot-0.12.0 → starplot-0.12.2}/src/starplot/base.py +18 -2
- {starplot-0.12.0 → starplot-0.12.2}/src/starplot/map.py +17 -7
- {starplot-0.12.0 → starplot-0.12.2}/src/starplot/styles/base.py +6 -5
- {starplot-0.12.0 → starplot-0.12.2}/.dockerignore +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/.github/FUNDING.yml +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/.github/ISSUE_TEMPLATE/bug_report.md +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/.github/ISSUE_TEMPLATE/feature_request.md +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/.github/workflows/docs.yml +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/.github/workflows/release.yml +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/.github/workflows/test.yml +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/.gitignore +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/CODE_OF_CONDUCT.md +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/CONTRIBUTING.md +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/Dockerfile +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/LICENSE +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/Makefile +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/README.md +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/docs/about.md +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/docs/coming-soon.md +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/docs/css/extra.css +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/docs/custom/main.html +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/docs/data/.keep +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/docs/data-sources.md +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/docs/examples/map-big-dipper.md +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/docs/examples/map-big.md +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/docs/examples/map-canis-major.md +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/docs/examples/map-comet-neowise.md +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/docs/examples/map-milky-way-stars.md +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/docs/examples/map-orion.md +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/docs/examples/map-orthographic.md +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/docs/examples/map-sagittarius.md +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/docs/examples/optic-m45.md +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/docs/examples/optic-moon-saturn.md +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/docs/examples/optic-orion.md +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/docs/examples/optic-solar-eclipse.md +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/docs/examples/star-chart-basic.md +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/docs/examples/star-chart-detail.md +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/docs/examples.md +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/docs/gallery.md +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/docs/images/banner.png +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/docs/images/banner.svg +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/docs/images/banner.vectornator +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/docs/images/celestial-globe.svg +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/docs/images/examples/.keep +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/docs/images/favicon.png +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/docs/images/favicon.svg +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/docs/images/logo.png +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/docs/images/logo.svg +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/docs/images/logo.vectornator +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/docs/images/logo2.png +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/docs/images/logo2.vectornator +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/docs/images/logo500.png +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/docs/images/mono.png +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/docs/images/mono.svg +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/docs/images/star.svg +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/docs/images/tutorial/.keep +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/docs/index.md +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/docs/installation.md +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/docs/license.md +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/docs/reference-callables.md +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/docs/reference-data.md +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/docs/reference-mapplot.md +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/docs/reference-models.md +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/docs/reference-ongc.md +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/docs/reference-opticplot.md +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/docs/reference-selecting-objects.md +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/docs/reference-styling.md +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/docs/robots.txt +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/docs/tutorial/01.md +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/docs/tutorial/02.md +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/docs/tutorial/03.md +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/docs/tutorial/04.md +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/docs/tutorial/05.md +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/docs/tutorial/06.md +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/docs/tutorial/07.md +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/docs/tutorial/08.md +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/docs/tutorial.md +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/examples/examples.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/examples/map_big.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/examples/map_big_dipper.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/examples/map_canis_major.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/examples/map_comet_neowise.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/examples/map_milky_way_stars.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/examples/map_orion.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/examples/map_orthographic.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/examples/map_sagittarius.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/examples/optic_m45.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/examples/optic_moon_saturn.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/examples/optic_orion_nebula.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/examples/optic_solar_eclipse.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/examples/star_chart_basic.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/examples/star_chart_detail.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/hash_checks/__init__.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/hash_checks/data/.keep +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/hash_checks/hashio.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/hash_checks/optic_checks.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/hash_checks/template.html +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/hash_checks/zenith_checks.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/mkdocs.yml +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/pyproject.toml +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/requirements-dev.txt +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/requirements.txt +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/scripts/constellation_hips.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/scripts/download_cons.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/scripts/ecliptic.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/scripts/gallery.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/scripts/geopack.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/scripts/gpack_constellations.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/scripts/hip.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/scripts/hip_parquet.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/scripts/ipy.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/scripts/moonphases.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/scripts/ongc_docdata.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/scripts/ongc_geopack.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/src/starplot/callables.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/src/starplot/data/__init__.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/src/starplot/data/bayer.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/src/starplot/data/bigsky.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/src/starplot/data/constellations.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/src/starplot/data/dsos.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/src/starplot/data/ecliptic.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/src/starplot/data/library/constellation_borders_inv.gpkg +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/src/starplot/data/library/constellation_lines_hips.json +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/src/starplot/data/library/constellation_lines_inv.gpkg +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/src/starplot/data/library/constellations.gpkg +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/src/starplot/data/library/constellations_hip.fab +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/src/starplot/data/library/de421_2001.bsp +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/src/starplot/data/library/milkyway.gpkg +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/src/starplot/data/library/milkyway_inv.gpkg +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/src/starplot/data/library/ongc.gpkg.zip +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/src/starplot/data/library/stars.bigsky.mag11.parquet +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/src/starplot/data/library/stars.hipparcos.parquet +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/src/starplot/data/messier.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/src/starplot/data/prep/__init__.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/src/starplot/data/prep/constellations.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/src/starplot/data/prep/dsos.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/src/starplot/data/prep/utils.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/src/starplot/data/stars.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/src/starplot/data/utils.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/src/starplot/geod.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/src/starplot/mixins.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/src/starplot/models/__init__.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/src/starplot/models/base.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/src/starplot/models/constellation.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/src/starplot/models/dso.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/src/starplot/models/geometry.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/src/starplot/models/moon.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/src/starplot/models/objects.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/src/starplot/models/planet.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/src/starplot/models/star.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/src/starplot/models/sun.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/src/starplot/optic.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/src/starplot/optics.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/src/starplot/plotters/__init__.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/src/starplot/plotters/dsos.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/src/starplot/plotters/stars.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/src/starplot/projections.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/src/starplot/styles/__init__.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/src/starplot/styles/ext/antique.yml +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/src/starplot/styles/ext/blue_dark.yml +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/src/starplot/styles/ext/blue_light.yml +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/src/starplot/styles/ext/blue_medium.yml +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/src/starplot/styles/ext/cb_wong.yml +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/src/starplot/styles/ext/color_print.yml +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/src/starplot/styles/ext/grayscale.yml +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/src/starplot/styles/ext/grayscale_dark.yml +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/src/starplot/styles/ext/map.yml +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/src/starplot/styles/ext/nord.yml +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/src/starplot/styles/ext/optic.yml +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/src/starplot/styles/extensions.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/src/starplot/styles/helpers.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/src/starplot/styles/markers.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/src/starplot/utils.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/tests/__init__.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/tests/data/.keep +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/tests/test_constellations.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/tests/test_data.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/tests/test_map.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/tests/test_models.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/tests/test_optic.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/tests/test_stars.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/tests/test_styles.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/tests/test_utils.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/tests/utils.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/tutorial/build.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/tutorial/tutorial_02.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/tutorial/tutorial_03.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/tutorial/tutorial_04.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/tutorial/tutorial_05.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/tutorial/tutorial_06.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/tutorial/tutorial_07.py +0 -0
- {starplot-0.12.0 → starplot-0.12.2}/tutorial/tutorial_08.py +0 -0
|
@@ -8,6 +8,8 @@
|
|
|
8
8
|
- Adds an ellipse marker for galaxies
|
|
9
9
|
- Adds colors for some DSO labels that were missing them in some style extensions
|
|
10
10
|
- Removed the kwarg `types` from `dsos`, so ALL DSO types are plotted by default
|
|
11
|
+
- [**v0.12.1**] Fixes issue with plotting the Milky Way when it consists of multiple polygons
|
|
12
|
+
- [**v0.12.2**] Allows tuples for line styles on polygons and adds geometry kwarg to polygon function
|
|
11
13
|
|
|
12
14
|
## v0.11.x
|
|
13
15
|
[Documentation](https://archives.starplot.dev/0.11.4/)
|
|
@@ -5,7 +5,9 @@ title: 9 - Where to Go From Here
|
|
|
5
5
|
---
|
|
6
6
|
{ align=right width="180" .off-glb }
|
|
7
7
|
|
|
8
|
-
**Congratulations on finishing the tutorial!**
|
|
8
|
+
**Congratulations on finishing the tutorial!**
|
|
9
|
+
|
|
10
|
+
You're now a certified Level-1 Starplotter 🤩
|
|
9
11
|
|
|
10
12
|
The purpose of the tutorial was just to give you an intro to some of Starplot's features, so there's more to explore by checking out the rest of the documentation. Here are some good places to check out next:
|
|
11
13
|
|
|
@@ -11,11 +11,15 @@ map_gridlines:
|
|
|
11
11
|
filename: /starplot/hash_checks/data/map-gridlines.png
|
|
12
12
|
phash: f82acf9c3c616392
|
|
13
13
|
map_label_callables:
|
|
14
|
-
dhash:
|
|
14
|
+
dhash: 80988c0c9c8c88a080988c0c9c8c88a0809a9d1d0d9d9aa0
|
|
15
15
|
filename: /starplot/hash_checks/data/map-m45-label-callables.png
|
|
16
|
-
phash:
|
|
16
|
+
phash: b238cdc92ce63699
|
|
17
|
+
map_milky_way_multi_polygon:
|
|
18
|
+
dhash: 351b89e4243a2604711b88e434322604751b88e424362624
|
|
19
|
+
filename: /starplot/hash_checks/data/map-milky-way-multi-polygon.png
|
|
20
|
+
phash: bc8bf89e90ce5a44
|
|
17
21
|
map_mollweide:
|
|
18
|
-
dhash:
|
|
22
|
+
dhash: 0b2933632b3317070b2933632b3317070f295b6323130707
|
|
19
23
|
filename: /starplot/hash_checks/data/map-mollweide.png
|
|
20
24
|
phash: fa9af698c0259566
|
|
21
25
|
map_moon_phase_waxing_crescent:
|
|
@@ -39,9 +43,9 @@ map_plot_limit_by_geometry:
|
|
|
39
43
|
filename: /starplot/hash_checks/data/map-limit-by-geometry.png
|
|
40
44
|
phash: e54d9b926c6d1692
|
|
41
45
|
map_scope_bino_fov:
|
|
42
|
-
dhash:
|
|
46
|
+
dhash: 0bc0808c8c8080802bc6b22d4da9928c2bc6b22d4da9928c
|
|
43
47
|
filename: /starplot/hash_checks/data/map-scope-bino-fov.png
|
|
44
|
-
phash:
|
|
48
|
+
phash: e46b296e6e293964
|
|
45
49
|
map_stereo_base:
|
|
46
50
|
dhash: 627666f07c3c3436627666f0382c3436727666f2ecc89416
|
|
47
51
|
filename: /starplot/hash_checks/data/map-stereo-north-base.png
|
|
@@ -450,35 +450,36 @@ def check_map_plot_custom_clip_path_virgo():
|
|
|
450
450
|
|
|
451
451
|
|
|
452
452
|
def check_map_label_callables():
|
|
453
|
+
style = STYLE.extend(
|
|
454
|
+
{
|
|
455
|
+
"dso_open_cluster": {
|
|
456
|
+
"label": {
|
|
457
|
+
"font_size": 28,
|
|
458
|
+
"font_weight": "bold",
|
|
459
|
+
"offset_x": 310,
|
|
460
|
+
"offset_y": 240,
|
|
461
|
+
}
|
|
462
|
+
},
|
|
463
|
+
}
|
|
464
|
+
)
|
|
453
465
|
p = MapPlot(
|
|
454
466
|
projection=Projection.MILLER,
|
|
455
467
|
ra_min=3.5,
|
|
456
468
|
ra_max=4,
|
|
457
469
|
dec_min=22,
|
|
458
470
|
dec_max=26,
|
|
459
|
-
style=
|
|
460
|
-
{
|
|
461
|
-
"dso_open_cluster": {
|
|
462
|
-
"label": {
|
|
463
|
-
"font_size": 28,
|
|
464
|
-
"font_weight": "bold",
|
|
465
|
-
"offset_x": 310,
|
|
466
|
-
"offset_y": 240,
|
|
467
|
-
}
|
|
468
|
-
},
|
|
469
|
-
}
|
|
470
|
-
),
|
|
471
|
+
style=style,
|
|
471
472
|
resolution=2000,
|
|
472
473
|
)
|
|
473
474
|
m45 = DSO.get(m="45")
|
|
474
475
|
|
|
475
|
-
p.
|
|
476
|
-
|
|
477
|
-
|
|
478
|
-
|
|
479
|
-
|
|
480
|
-
|
|
481
|
-
|
|
476
|
+
p.polygon(
|
|
477
|
+
geometry=m45.geometry,
|
|
478
|
+
style__color=None,
|
|
479
|
+
style__fill_color=style.dso_open_cluster.marker.color,
|
|
480
|
+
style__edge_color="#000",
|
|
481
|
+
style__edge_width=4,
|
|
482
|
+
style__line_style=(0, (1.2, 8)),
|
|
482
483
|
)
|
|
483
484
|
|
|
484
485
|
p.stars(
|
|
@@ -491,3 +492,23 @@ def check_map_label_callables():
|
|
|
491
492
|
p.export(filename)
|
|
492
493
|
p.close_fig()
|
|
493
494
|
return filename
|
|
495
|
+
|
|
496
|
+
|
|
497
|
+
def check_map_milky_way_multi_polygon():
|
|
498
|
+
p = MapPlot(
|
|
499
|
+
projection=Projection.MILLER,
|
|
500
|
+
ra_min=17.5,
|
|
501
|
+
ra_max=19.5,
|
|
502
|
+
dec_min=-40,
|
|
503
|
+
dec_max=0,
|
|
504
|
+
style=STYLE,
|
|
505
|
+
resolution=2000,
|
|
506
|
+
)
|
|
507
|
+
p.stars(mag=6, bayer_labels=True)
|
|
508
|
+
p.constellations()
|
|
509
|
+
p.milky_way()
|
|
510
|
+
|
|
511
|
+
filename = DATA_PATH / "map-milky-way-multi-polygon.png"
|
|
512
|
+
p.export(filename)
|
|
513
|
+
p.close_fig()
|
|
514
|
+
return filename
|
|
@@ -10,6 +10,7 @@ from matplotlib import patches
|
|
|
10
10
|
from matplotlib import pyplot as plt, patheffects
|
|
11
11
|
from matplotlib.lines import Line2D
|
|
12
12
|
from pytz import timezone
|
|
13
|
+
from shapely import Polygon
|
|
13
14
|
|
|
14
15
|
from starplot import geod, models
|
|
15
16
|
from starplot.data import load, ecliptic
|
|
@@ -498,13 +499,28 @@ class BasePlot(ABC):
|
|
|
498
499
|
self.ax.add_patch(patch)
|
|
499
500
|
|
|
500
501
|
@use_style(PolygonStyle)
|
|
501
|
-
def polygon(
|
|
502
|
-
|
|
502
|
+
def polygon(
|
|
503
|
+
self,
|
|
504
|
+
style: PolygonStyle,
|
|
505
|
+
points: list = None,
|
|
506
|
+
geometry: Polygon = None,
|
|
507
|
+
):
|
|
508
|
+
"""
|
|
509
|
+
Plots a polygon.
|
|
510
|
+
|
|
511
|
+
Must pass in either `points` **or** `geometry` (but not both).
|
|
503
512
|
|
|
504
513
|
Args:
|
|
505
514
|
points: List of polygon points `[(ra, dec), ...]` - **must be in counterclockwise order**
|
|
515
|
+
geometry: A shapely Polygon. If this value is passed, then the `points` kwarg will be ignored.
|
|
506
516
|
style: Style of polygon
|
|
507
517
|
"""
|
|
518
|
+
if points is None and geometry is None:
|
|
519
|
+
raise ValueError("Must pass points or geometry when plotting polygons.")
|
|
520
|
+
|
|
521
|
+
if geometry is not None:
|
|
522
|
+
points = list(zip(*geometry.exterior.coords.xy))
|
|
523
|
+
|
|
508
524
|
_points = [(ra * 15, dec) for ra, dec in points]
|
|
509
525
|
self._polygon(_points, style)
|
|
510
526
|
|
|
@@ -451,17 +451,27 @@ class MapPlot(BasePlot, ExtentMaskMixin, StarPlotterMixin, DsoPlotterMixin):
|
|
|
451
451
|
"""
|
|
452
452
|
mw = self._read_geo_package(DataFiles.MILKY_WAY.value)
|
|
453
453
|
|
|
454
|
-
if
|
|
455
|
-
|
|
456
|
-
gs = mw.geometry.to_crs(self._plate_carree)
|
|
457
|
-
mw_union = gs.buffer(0.1).unary_union.buffer(-0.1)
|
|
458
|
-
points = list(zip(*mw_union.boundary.coords.xy))
|
|
454
|
+
if mw.empty:
|
|
455
|
+
return
|
|
459
456
|
|
|
457
|
+
def _prepare_polygon(p):
|
|
458
|
+
points = list(zip(*p.boundary.coords.xy))
|
|
460
459
|
# convert lon to RA and reverse so the coordinates are counterclockwise order
|
|
461
|
-
|
|
460
|
+
return [(lon_to_ra(lon) * 15, dec) for lon, dec in reversed(points)]
|
|
461
|
+
|
|
462
|
+
# create union of all Milky Way patches
|
|
463
|
+
gs = mw.geometry.to_crs(self._plate_carree)
|
|
464
|
+
mw_union = gs.buffer(0.1).unary_union.buffer(-0.1)
|
|
465
|
+
polygons = []
|
|
466
|
+
|
|
467
|
+
if mw_union.geom_type == "MultiPolygon":
|
|
468
|
+
polygons.extend([_prepare_polygon(polygon) for polygon in mw_union.geoms])
|
|
469
|
+
else:
|
|
470
|
+
polygons.append(_prepare_polygon(mw_union))
|
|
462
471
|
|
|
472
|
+
for polygon_points in polygons:
|
|
463
473
|
self._polygon(
|
|
464
|
-
|
|
474
|
+
polygon_points,
|
|
465
475
|
style=style,
|
|
466
476
|
)
|
|
467
477
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import json
|
|
2
2
|
from enum import Enum
|
|
3
3
|
from pathlib import Path
|
|
4
|
-
from typing import Optional
|
|
4
|
+
from typing import Optional, Union
|
|
5
5
|
from functools import cache
|
|
6
6
|
|
|
7
7
|
import yaml
|
|
@@ -332,8 +332,8 @@ class LineStyle(BaseStyle):
|
|
|
332
332
|
color: ColorStr = ColorStr("#000")
|
|
333
333
|
"""Color of the line. Can be a hex, rgb, hsl, or word string."""
|
|
334
334
|
|
|
335
|
-
style: LineStyleEnum = LineStyleEnum.SOLID
|
|
336
|
-
"""Style of the line (e.g. solid, dashed, etc)."""
|
|
335
|
+
style: Union[LineStyleEnum, tuple] = LineStyleEnum.SOLID
|
|
336
|
+
"""Style of the line (e.g. solid, dashed, etc). Can be a predefined value in `LineStyleEnum` or a [Matplotlib linestyle tuple](https://matplotlib.org/stable/gallery/lines_bars_and_markers/linestyles.html)."""
|
|
337
337
|
|
|
338
338
|
dash_capstyle: DashCapStyleEnum = DashCapStyleEnum.PROJECTING
|
|
339
339
|
"""Style of dash endpoints"""
|
|
@@ -401,8 +401,8 @@ class PolygonStyle(BaseStyle):
|
|
|
401
401
|
fill_color: Optional[ColorStr] = None
|
|
402
402
|
"""Fill color of the polygon"""
|
|
403
403
|
|
|
404
|
-
line_style: LineStyleEnum = LineStyleEnum.SOLID
|
|
405
|
-
"""Edge line style"""
|
|
404
|
+
line_style: Union[LineStyleEnum, tuple] = LineStyleEnum.SOLID
|
|
405
|
+
"""Edge line style. Can be a predefined value in `LineStyleEnum` or a [Matplotlib linestyle tuple](https://matplotlib.org/stable/gallery/lines_bars_and_markers/linestyles.html)."""
|
|
406
406
|
|
|
407
407
|
alpha: float = 1.0
|
|
408
408
|
"""Alpha value (controls transparency)"""
|
|
@@ -419,6 +419,7 @@ class PolygonStyle(BaseStyle):
|
|
|
419
419
|
linestyle=self.line_style,
|
|
420
420
|
alpha=self.alpha,
|
|
421
421
|
zorder=self.zorder,
|
|
422
|
+
capstyle="round",
|
|
422
423
|
)
|
|
423
424
|
if self.color:
|
|
424
425
|
styles["color"] = self.color.as_hex()
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{starplot-0.12.0 → starplot-0.12.2}/src/starplot/data/library/constellation_borders_inv.gpkg
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|