starplot 0.12.0__tar.gz → 0.12.1__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.

Files changed (198) hide show
  1. {starplot-0.12.0 → starplot-0.12.1}/PKG-INFO +1 -1
  2. {starplot-0.12.0 → starplot-0.12.1}/docs/changelog.md +1 -0
  3. {starplot-0.12.0 → starplot-0.12.1}/hash_checks/hashlock.yml +4 -0
  4. {starplot-0.12.0 → starplot-0.12.1}/hash_checks/map_checks.py +20 -0
  5. {starplot-0.12.0 → starplot-0.12.1}/src/starplot/__init__.py +1 -1
  6. {starplot-0.12.0 → starplot-0.12.1}/src/starplot/map.py +17 -7
  7. {starplot-0.12.0 → starplot-0.12.1}/.dockerignore +0 -0
  8. {starplot-0.12.0 → starplot-0.12.1}/.github/FUNDING.yml +0 -0
  9. {starplot-0.12.0 → starplot-0.12.1}/.github/ISSUE_TEMPLATE/bug_report.md +0 -0
  10. {starplot-0.12.0 → starplot-0.12.1}/.github/ISSUE_TEMPLATE/feature_request.md +0 -0
  11. {starplot-0.12.0 → starplot-0.12.1}/.github/workflows/docs.yml +0 -0
  12. {starplot-0.12.0 → starplot-0.12.1}/.github/workflows/release.yml +0 -0
  13. {starplot-0.12.0 → starplot-0.12.1}/.github/workflows/test.yml +0 -0
  14. {starplot-0.12.0 → starplot-0.12.1}/.gitignore +0 -0
  15. {starplot-0.12.0 → starplot-0.12.1}/CODE_OF_CONDUCT.md +0 -0
  16. {starplot-0.12.0 → starplot-0.12.1}/CONTRIBUTING.md +0 -0
  17. {starplot-0.12.0 → starplot-0.12.1}/Dockerfile +0 -0
  18. {starplot-0.12.0 → starplot-0.12.1}/LICENSE +0 -0
  19. {starplot-0.12.0 → starplot-0.12.1}/Makefile +0 -0
  20. {starplot-0.12.0 → starplot-0.12.1}/README.md +0 -0
  21. {starplot-0.12.0 → starplot-0.12.1}/docs/about.md +0 -0
  22. {starplot-0.12.0 → starplot-0.12.1}/docs/coming-soon.md +0 -0
  23. {starplot-0.12.0 → starplot-0.12.1}/docs/css/extra.css +0 -0
  24. {starplot-0.12.0 → starplot-0.12.1}/docs/custom/main.html +0 -0
  25. {starplot-0.12.0 → starplot-0.12.1}/docs/data/.keep +0 -0
  26. {starplot-0.12.0 → starplot-0.12.1}/docs/data-sources.md +0 -0
  27. {starplot-0.12.0 → starplot-0.12.1}/docs/examples/map-big-dipper.md +0 -0
  28. {starplot-0.12.0 → starplot-0.12.1}/docs/examples/map-big.md +0 -0
  29. {starplot-0.12.0 → starplot-0.12.1}/docs/examples/map-canis-major.md +0 -0
  30. {starplot-0.12.0 → starplot-0.12.1}/docs/examples/map-comet-neowise.md +0 -0
  31. {starplot-0.12.0 → starplot-0.12.1}/docs/examples/map-milky-way-stars.md +0 -0
  32. {starplot-0.12.0 → starplot-0.12.1}/docs/examples/map-orion.md +0 -0
  33. {starplot-0.12.0 → starplot-0.12.1}/docs/examples/map-orthographic.md +0 -0
  34. {starplot-0.12.0 → starplot-0.12.1}/docs/examples/map-sagittarius.md +0 -0
  35. {starplot-0.12.0 → starplot-0.12.1}/docs/examples/optic-m45.md +0 -0
  36. {starplot-0.12.0 → starplot-0.12.1}/docs/examples/optic-moon-saturn.md +0 -0
  37. {starplot-0.12.0 → starplot-0.12.1}/docs/examples/optic-orion.md +0 -0
  38. {starplot-0.12.0 → starplot-0.12.1}/docs/examples/optic-solar-eclipse.md +0 -0
  39. {starplot-0.12.0 → starplot-0.12.1}/docs/examples/star-chart-basic.md +0 -0
  40. {starplot-0.12.0 → starplot-0.12.1}/docs/examples/star-chart-detail.md +0 -0
  41. {starplot-0.12.0 → starplot-0.12.1}/docs/examples.md +0 -0
  42. {starplot-0.12.0 → starplot-0.12.1}/docs/gallery.md +0 -0
  43. {starplot-0.12.0 → starplot-0.12.1}/docs/images/banner.png +0 -0
  44. {starplot-0.12.0 → starplot-0.12.1}/docs/images/banner.svg +0 -0
  45. {starplot-0.12.0 → starplot-0.12.1}/docs/images/banner.vectornator +0 -0
  46. {starplot-0.12.0 → starplot-0.12.1}/docs/images/celestial-globe.svg +0 -0
  47. {starplot-0.12.0 → starplot-0.12.1}/docs/images/examples/.keep +0 -0
  48. {starplot-0.12.0 → starplot-0.12.1}/docs/images/favicon.png +0 -0
  49. {starplot-0.12.0 → starplot-0.12.1}/docs/images/favicon.svg +0 -0
  50. {starplot-0.12.0 → starplot-0.12.1}/docs/images/logo.png +0 -0
  51. {starplot-0.12.0 → starplot-0.12.1}/docs/images/logo.svg +0 -0
  52. {starplot-0.12.0 → starplot-0.12.1}/docs/images/logo.vectornator +0 -0
  53. {starplot-0.12.0 → starplot-0.12.1}/docs/images/logo2.png +0 -0
  54. {starplot-0.12.0 → starplot-0.12.1}/docs/images/logo2.vectornator +0 -0
  55. {starplot-0.12.0 → starplot-0.12.1}/docs/images/logo500.png +0 -0
  56. {starplot-0.12.0 → starplot-0.12.1}/docs/images/mono.png +0 -0
  57. {starplot-0.12.0 → starplot-0.12.1}/docs/images/mono.svg +0 -0
  58. {starplot-0.12.0 → starplot-0.12.1}/docs/images/star.svg +0 -0
  59. {starplot-0.12.0 → starplot-0.12.1}/docs/images/tutorial/.keep +0 -0
  60. {starplot-0.12.0 → starplot-0.12.1}/docs/index.md +0 -0
  61. {starplot-0.12.0 → starplot-0.12.1}/docs/installation.md +0 -0
  62. {starplot-0.12.0 → starplot-0.12.1}/docs/license.md +0 -0
  63. {starplot-0.12.0 → starplot-0.12.1}/docs/reference-callables.md +0 -0
  64. {starplot-0.12.0 → starplot-0.12.1}/docs/reference-data.md +0 -0
  65. {starplot-0.12.0 → starplot-0.12.1}/docs/reference-mapplot.md +0 -0
  66. {starplot-0.12.0 → starplot-0.12.1}/docs/reference-models.md +0 -0
  67. {starplot-0.12.0 → starplot-0.12.1}/docs/reference-ongc.md +0 -0
  68. {starplot-0.12.0 → starplot-0.12.1}/docs/reference-opticplot.md +0 -0
  69. {starplot-0.12.0 → starplot-0.12.1}/docs/reference-selecting-objects.md +0 -0
  70. {starplot-0.12.0 → starplot-0.12.1}/docs/reference-styling.md +0 -0
  71. {starplot-0.12.0 → starplot-0.12.1}/docs/robots.txt +0 -0
  72. {starplot-0.12.0 → starplot-0.12.1}/docs/tutorial/01.md +0 -0
  73. {starplot-0.12.0 → starplot-0.12.1}/docs/tutorial/02.md +0 -0
  74. {starplot-0.12.0 → starplot-0.12.1}/docs/tutorial/03.md +0 -0
  75. {starplot-0.12.0 → starplot-0.12.1}/docs/tutorial/04.md +0 -0
  76. {starplot-0.12.0 → starplot-0.12.1}/docs/tutorial/05.md +0 -0
  77. {starplot-0.12.0 → starplot-0.12.1}/docs/tutorial/06.md +0 -0
  78. {starplot-0.12.0 → starplot-0.12.1}/docs/tutorial/07.md +0 -0
  79. {starplot-0.12.0 → starplot-0.12.1}/docs/tutorial/08.md +0 -0
  80. {starplot-0.12.0 → starplot-0.12.1}/docs/tutorial/09.md +0 -0
  81. {starplot-0.12.0 → starplot-0.12.1}/docs/tutorial.md +0 -0
  82. {starplot-0.12.0 → starplot-0.12.1}/examples/examples.py +0 -0
  83. {starplot-0.12.0 → starplot-0.12.1}/examples/map_big.py +0 -0
  84. {starplot-0.12.0 → starplot-0.12.1}/examples/map_big_dipper.py +0 -0
  85. {starplot-0.12.0 → starplot-0.12.1}/examples/map_canis_major.py +0 -0
  86. {starplot-0.12.0 → starplot-0.12.1}/examples/map_comet_neowise.py +0 -0
  87. {starplot-0.12.0 → starplot-0.12.1}/examples/map_milky_way_stars.py +0 -0
  88. {starplot-0.12.0 → starplot-0.12.1}/examples/map_orion.py +0 -0
  89. {starplot-0.12.0 → starplot-0.12.1}/examples/map_orthographic.py +0 -0
  90. {starplot-0.12.0 → starplot-0.12.1}/examples/map_sagittarius.py +0 -0
  91. {starplot-0.12.0 → starplot-0.12.1}/examples/optic_m45.py +0 -0
  92. {starplot-0.12.0 → starplot-0.12.1}/examples/optic_moon_saturn.py +0 -0
  93. {starplot-0.12.0 → starplot-0.12.1}/examples/optic_orion_nebula.py +0 -0
  94. {starplot-0.12.0 → starplot-0.12.1}/examples/optic_solar_eclipse.py +0 -0
  95. {starplot-0.12.0 → starplot-0.12.1}/examples/star_chart_basic.py +0 -0
  96. {starplot-0.12.0 → starplot-0.12.1}/examples/star_chart_detail.py +0 -0
  97. {starplot-0.12.0 → starplot-0.12.1}/hash_checks/__init__.py +0 -0
  98. {starplot-0.12.0 → starplot-0.12.1}/hash_checks/data/.keep +0 -0
  99. {starplot-0.12.0 → starplot-0.12.1}/hash_checks/hashio.py +0 -0
  100. {starplot-0.12.0 → starplot-0.12.1}/hash_checks/optic_checks.py +0 -0
  101. {starplot-0.12.0 → starplot-0.12.1}/hash_checks/template.html +0 -0
  102. {starplot-0.12.0 → starplot-0.12.1}/hash_checks/zenith_checks.py +0 -0
  103. {starplot-0.12.0 → starplot-0.12.1}/mkdocs.yml +0 -0
  104. {starplot-0.12.0 → starplot-0.12.1}/pyproject.toml +0 -0
  105. {starplot-0.12.0 → starplot-0.12.1}/requirements-dev.txt +0 -0
  106. {starplot-0.12.0 → starplot-0.12.1}/requirements.txt +0 -0
  107. {starplot-0.12.0 → starplot-0.12.1}/scripts/constellation_hips.py +0 -0
  108. {starplot-0.12.0 → starplot-0.12.1}/scripts/download_cons.py +0 -0
  109. {starplot-0.12.0 → starplot-0.12.1}/scripts/ecliptic.py +0 -0
  110. {starplot-0.12.0 → starplot-0.12.1}/scripts/gallery.py +0 -0
  111. {starplot-0.12.0 → starplot-0.12.1}/scripts/geopack.py +0 -0
  112. {starplot-0.12.0 → starplot-0.12.1}/scripts/gpack_constellations.py +0 -0
  113. {starplot-0.12.0 → starplot-0.12.1}/scripts/hip.py +0 -0
  114. {starplot-0.12.0 → starplot-0.12.1}/scripts/hip_parquet.py +0 -0
  115. {starplot-0.12.0 → starplot-0.12.1}/scripts/ipy.py +0 -0
  116. {starplot-0.12.0 → starplot-0.12.1}/scripts/moonphases.py +0 -0
  117. {starplot-0.12.0 → starplot-0.12.1}/scripts/ongc_docdata.py +0 -0
  118. {starplot-0.12.0 → starplot-0.12.1}/scripts/ongc_geopack.py +0 -0
  119. {starplot-0.12.0 → starplot-0.12.1}/src/starplot/base.py +0 -0
  120. {starplot-0.12.0 → starplot-0.12.1}/src/starplot/callables.py +0 -0
  121. {starplot-0.12.0 → starplot-0.12.1}/src/starplot/data/__init__.py +0 -0
  122. {starplot-0.12.0 → starplot-0.12.1}/src/starplot/data/bayer.py +0 -0
  123. {starplot-0.12.0 → starplot-0.12.1}/src/starplot/data/bigsky.py +0 -0
  124. {starplot-0.12.0 → starplot-0.12.1}/src/starplot/data/constellations.py +0 -0
  125. {starplot-0.12.0 → starplot-0.12.1}/src/starplot/data/dsos.py +0 -0
  126. {starplot-0.12.0 → starplot-0.12.1}/src/starplot/data/ecliptic.py +0 -0
  127. {starplot-0.12.0 → starplot-0.12.1}/src/starplot/data/library/constellation_borders_inv.gpkg +0 -0
  128. {starplot-0.12.0 → starplot-0.12.1}/src/starplot/data/library/constellation_lines_hips.json +0 -0
  129. {starplot-0.12.0 → starplot-0.12.1}/src/starplot/data/library/constellation_lines_inv.gpkg +0 -0
  130. {starplot-0.12.0 → starplot-0.12.1}/src/starplot/data/library/constellations.gpkg +0 -0
  131. {starplot-0.12.0 → starplot-0.12.1}/src/starplot/data/library/constellations_hip.fab +0 -0
  132. {starplot-0.12.0 → starplot-0.12.1}/src/starplot/data/library/de421_2001.bsp +0 -0
  133. {starplot-0.12.0 → starplot-0.12.1}/src/starplot/data/library/milkyway.gpkg +0 -0
  134. {starplot-0.12.0 → starplot-0.12.1}/src/starplot/data/library/milkyway_inv.gpkg +0 -0
  135. {starplot-0.12.0 → starplot-0.12.1}/src/starplot/data/library/ongc.gpkg.zip +0 -0
  136. {starplot-0.12.0 → starplot-0.12.1}/src/starplot/data/library/stars.bigsky.mag11.parquet +0 -0
  137. {starplot-0.12.0 → starplot-0.12.1}/src/starplot/data/library/stars.hipparcos.parquet +0 -0
  138. {starplot-0.12.0 → starplot-0.12.1}/src/starplot/data/messier.py +0 -0
  139. {starplot-0.12.0 → starplot-0.12.1}/src/starplot/data/prep/__init__.py +0 -0
  140. {starplot-0.12.0 → starplot-0.12.1}/src/starplot/data/prep/constellations.py +0 -0
  141. {starplot-0.12.0 → starplot-0.12.1}/src/starplot/data/prep/dsos.py +0 -0
  142. {starplot-0.12.0 → starplot-0.12.1}/src/starplot/data/prep/utils.py +0 -0
  143. {starplot-0.12.0 → starplot-0.12.1}/src/starplot/data/stars.py +0 -0
  144. {starplot-0.12.0 → starplot-0.12.1}/src/starplot/data/utils.py +0 -0
  145. {starplot-0.12.0 → starplot-0.12.1}/src/starplot/geod.py +0 -0
  146. {starplot-0.12.0 → starplot-0.12.1}/src/starplot/mixins.py +0 -0
  147. {starplot-0.12.0 → starplot-0.12.1}/src/starplot/models/__init__.py +0 -0
  148. {starplot-0.12.0 → starplot-0.12.1}/src/starplot/models/base.py +0 -0
  149. {starplot-0.12.0 → starplot-0.12.1}/src/starplot/models/constellation.py +0 -0
  150. {starplot-0.12.0 → starplot-0.12.1}/src/starplot/models/dso.py +0 -0
  151. {starplot-0.12.0 → starplot-0.12.1}/src/starplot/models/geometry.py +0 -0
  152. {starplot-0.12.0 → starplot-0.12.1}/src/starplot/models/moon.py +0 -0
  153. {starplot-0.12.0 → starplot-0.12.1}/src/starplot/models/objects.py +0 -0
  154. {starplot-0.12.0 → starplot-0.12.1}/src/starplot/models/planet.py +0 -0
  155. {starplot-0.12.0 → starplot-0.12.1}/src/starplot/models/star.py +0 -0
  156. {starplot-0.12.0 → starplot-0.12.1}/src/starplot/models/sun.py +0 -0
  157. {starplot-0.12.0 → starplot-0.12.1}/src/starplot/optic.py +0 -0
  158. {starplot-0.12.0 → starplot-0.12.1}/src/starplot/optics.py +0 -0
  159. {starplot-0.12.0 → starplot-0.12.1}/src/starplot/plotters/__init__.py +0 -0
  160. {starplot-0.12.0 → starplot-0.12.1}/src/starplot/plotters/dsos.py +0 -0
  161. {starplot-0.12.0 → starplot-0.12.1}/src/starplot/plotters/stars.py +0 -0
  162. {starplot-0.12.0 → starplot-0.12.1}/src/starplot/projections.py +0 -0
  163. {starplot-0.12.0 → starplot-0.12.1}/src/starplot/styles/__init__.py +0 -0
  164. {starplot-0.12.0 → starplot-0.12.1}/src/starplot/styles/base.py +0 -0
  165. {starplot-0.12.0 → starplot-0.12.1}/src/starplot/styles/ext/antique.yml +0 -0
  166. {starplot-0.12.0 → starplot-0.12.1}/src/starplot/styles/ext/blue_dark.yml +0 -0
  167. {starplot-0.12.0 → starplot-0.12.1}/src/starplot/styles/ext/blue_light.yml +0 -0
  168. {starplot-0.12.0 → starplot-0.12.1}/src/starplot/styles/ext/blue_medium.yml +0 -0
  169. {starplot-0.12.0 → starplot-0.12.1}/src/starplot/styles/ext/cb_wong.yml +0 -0
  170. {starplot-0.12.0 → starplot-0.12.1}/src/starplot/styles/ext/color_print.yml +0 -0
  171. {starplot-0.12.0 → starplot-0.12.1}/src/starplot/styles/ext/grayscale.yml +0 -0
  172. {starplot-0.12.0 → starplot-0.12.1}/src/starplot/styles/ext/grayscale_dark.yml +0 -0
  173. {starplot-0.12.0 → starplot-0.12.1}/src/starplot/styles/ext/map.yml +0 -0
  174. {starplot-0.12.0 → starplot-0.12.1}/src/starplot/styles/ext/nord.yml +0 -0
  175. {starplot-0.12.0 → starplot-0.12.1}/src/starplot/styles/ext/optic.yml +0 -0
  176. {starplot-0.12.0 → starplot-0.12.1}/src/starplot/styles/extensions.py +0 -0
  177. {starplot-0.12.0 → starplot-0.12.1}/src/starplot/styles/helpers.py +0 -0
  178. {starplot-0.12.0 → starplot-0.12.1}/src/starplot/styles/markers.py +0 -0
  179. {starplot-0.12.0 → starplot-0.12.1}/src/starplot/utils.py +0 -0
  180. {starplot-0.12.0 → starplot-0.12.1}/tests/__init__.py +0 -0
  181. {starplot-0.12.0 → starplot-0.12.1}/tests/data/.keep +0 -0
  182. {starplot-0.12.0 → starplot-0.12.1}/tests/test_constellations.py +0 -0
  183. {starplot-0.12.0 → starplot-0.12.1}/tests/test_data.py +0 -0
  184. {starplot-0.12.0 → starplot-0.12.1}/tests/test_map.py +0 -0
  185. {starplot-0.12.0 → starplot-0.12.1}/tests/test_models.py +0 -0
  186. {starplot-0.12.0 → starplot-0.12.1}/tests/test_optic.py +0 -0
  187. {starplot-0.12.0 → starplot-0.12.1}/tests/test_stars.py +0 -0
  188. {starplot-0.12.0 → starplot-0.12.1}/tests/test_styles.py +0 -0
  189. {starplot-0.12.0 → starplot-0.12.1}/tests/test_utils.py +0 -0
  190. {starplot-0.12.0 → starplot-0.12.1}/tests/utils.py +0 -0
  191. {starplot-0.12.0 → starplot-0.12.1}/tutorial/build.py +0 -0
  192. {starplot-0.12.0 → starplot-0.12.1}/tutorial/tutorial_02.py +0 -0
  193. {starplot-0.12.0 → starplot-0.12.1}/tutorial/tutorial_03.py +0 -0
  194. {starplot-0.12.0 → starplot-0.12.1}/tutorial/tutorial_04.py +0 -0
  195. {starplot-0.12.0 → starplot-0.12.1}/tutorial/tutorial_05.py +0 -0
  196. {starplot-0.12.0 → starplot-0.12.1}/tutorial/tutorial_06.py +0 -0
  197. {starplot-0.12.0 → starplot-0.12.1}/tutorial/tutorial_07.py +0 -0
  198. {starplot-0.12.0 → starplot-0.12.1}/tutorial/tutorial_08.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: starplot
3
- Version: 0.12.0
3
+ Version: 0.12.1
4
4
  Summary: Star charts and maps
5
5
  Keywords: astronomy,stars,charts,maps,constellations
6
6
  Author-email: Steve Berardi <hello@steveberardi.com>
@@ -8,6 +8,7 @@
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
11
12
 
12
13
  ## v0.11.x
13
14
  [Documentation](https://archives.starplot.dev/0.11.4/)
@@ -14,6 +14,10 @@ map_label_callables:
14
14
  dhash: 80948c8c9c8c88a080988c8c9c8c88a0809c8d0d9d9c98a0
15
15
  filename: /starplot/hash_checks/data/map-m45-label-callables.png
16
16
  phash: b26ccd99316664cd
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
22
  dhash: 0f2933632b3317070f2933632b3317070f295b6323130707
19
23
  filename: /starplot/hash_checks/data/map-mollweide.png
@@ -491,3 +491,23 @@ def check_map_label_callables():
491
491
  p.export(filename)
492
492
  p.close_fig()
493
493
  return filename
494
+
495
+
496
+ def check_map_milky_way_multi_polygon():
497
+ p = MapPlot(
498
+ projection=Projection.MILLER,
499
+ ra_min=17.5,
500
+ ra_max=19.5,
501
+ dec_min=-40,
502
+ dec_max=0,
503
+ style=STYLE,
504
+ resolution=2000,
505
+ )
506
+ p.stars(mag=6, bayer_labels=True)
507
+ p.constellations()
508
+ p.milky_way()
509
+
510
+ filename = DATA_PATH / "map-milky-way-multi-polygon.png"
511
+ p.export(filename)
512
+ p.close_fig()
513
+ return filename
@@ -1,6 +1,6 @@
1
1
  """Star charts and maps"""
2
2
 
3
- __version__ = "0.12.0"
3
+ __version__ = "0.12.1"
4
4
 
5
5
  from .base import BasePlot # noqa: F401
6
6
  from .map import MapPlot, Projection # noqa: F401
@@ -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 not mw.empty:
455
- # create union of all Milky Way patches
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
- points = [(lon_to_ra(lon) * 15, dec) for lon, dec in reversed(points)]
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
- points,
474
+ polygon_points,
465
475
  style=style,
466
476
  )
467
477
 
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