matplotlib-map-utils 2.0.1__py3-none-any.whl → 2.0.2__py3-none-any.whl
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.
- matplotlib_map_utils/core/scale_bar.py +3 -3
- {matplotlib_map_utils-2.0.1.dist-info → matplotlib_map_utils-2.0.2.dist-info}/METADATA +7 -5
- {matplotlib_map_utils-2.0.1.dist-info → matplotlib_map_utils-2.0.2.dist-info}/RECORD +6 -6
- {matplotlib_map_utils-2.0.1.dist-info → matplotlib_map_utils-2.0.2.dist-info}/WHEEL +1 -1
- {matplotlib_map_utils-2.0.1.dist-info → matplotlib_map_utils-2.0.2.dist-info}/LICENSE +0 -0
- {matplotlib_map_utils-2.0.1.dist-info → matplotlib_map_utils-2.0.2.dist-info}/top_level.txt +0 -0
@@ -679,7 +679,7 @@ def _config_bar(ax, bar):
|
|
679
679
|
# If the provided units are in degrees, we will convert to meters first
|
680
680
|
# This will recalculate the ax_range
|
681
681
|
if units_proj=="degree":
|
682
|
-
warnings.warn(f"Provided CRS {bar[
|
682
|
+
warnings.warn(f"Provided CRS {bar['projection']} uses degrees. An attempt will be made at conversion, but there will be accuracy issues: it is recommended that you use a projected CRS instead.")
|
683
683
|
ylim = ax.get_ylim()
|
684
684
|
xlim = ax.get_xlim()
|
685
685
|
# Using https://github.com/seangrogan/great_circle_calculator/blob/master/great_circle_calculator/great_circle_calculator.py
|
@@ -706,7 +706,7 @@ def _config_bar(ax, bar):
|
|
706
706
|
try:
|
707
707
|
units_user = sbt.units_standard.get(bar["unit"])
|
708
708
|
except:
|
709
|
-
warnings.warn(f"Desired output units selected by user ({bar[
|
709
|
+
warnings.warn(f"Desired output units selected by user ({bar['unit']}) are considered invalid; please use one of the units specified in the units_standard dictionary in defaults.py")
|
710
710
|
units_user = None
|
711
711
|
|
712
712
|
# Converting
|
@@ -749,7 +749,7 @@ def _config_bar(ax, bar):
|
|
749
749
|
if bar["length"] < ax_dim:
|
750
750
|
bar_max = (bar["length"] / ax_dim) * ax_range
|
751
751
|
else:
|
752
|
-
warnings.warn(f"Provided bar length ({bar[
|
752
|
+
warnings.warn(f"Provided bar length ({bar['length']}) is greater than the axis length ({ax_dim}); setting bar length to default (25% of axis length).")
|
753
753
|
bar_max = 0.25 * ax_range
|
754
754
|
# If bar["max"] is provided, don't need to go through all of this effort
|
755
755
|
else:
|
@@ -1,6 +1,6 @@
|
|
1
1
|
Metadata-Version: 2.2
|
2
2
|
Name: matplotlib-map-utils
|
3
|
-
Version: 2.0.
|
3
|
+
Version: 2.0.2
|
4
4
|
Summary: A suite of tools for creating maps in matplotlib
|
5
5
|
Author-email: David Moss <davidmoss1221@gmail.com>
|
6
6
|
Project-URL: Homepage, https://github.com/moss-xyz/matplotlib-map-utils/
|
@@ -8,7 +8,7 @@ Project-URL: Bug Tracker, https://github.com/moss-xyz/matplotlib-map-utils/issue
|
|
8
8
|
Classifier: Programming Language :: Python :: 3
|
9
9
|
Classifier: License :: OSI Approved :: GNU General Public License (GPL)
|
10
10
|
Classifier: Operating System :: OS Independent
|
11
|
-
Requires-Python: >=3.
|
11
|
+
Requires-Python: >=3.10
|
12
12
|
Description-Content-Type: text/markdown
|
13
13
|
License-File: LICENSE
|
14
14
|
Requires-Dist: matplotlib>=3.9.0
|
@@ -49,11 +49,11 @@ pip install matplotlib-map-utils
|
|
49
49
|
|
50
50
|
The requirements for this package are:
|
51
51
|
|
52
|
-
* `python >= 3.
|
52
|
+
* `python >= 3.10` (due to the use of the pipe operator to concatenate dictionaries and types)
|
53
53
|
|
54
|
-
* `matplotlib >= 3.9
|
54
|
+
* `matplotlib >= 3.9` (might work with lower versions but not guaranteed)
|
55
55
|
|
56
|
-
* `cartopy >= 0.23
|
56
|
+
* `cartopy >= 0.23` (due to earlier bug with calling `copy()` on `CRS` objects)
|
57
57
|
|
58
58
|
---
|
59
59
|
|
@@ -246,6 +246,8 @@ Two more projects assisted with the creation of this script:
|
|
246
246
|
|
247
247
|
- `v2.0.1`: Fixed a bug in the `dual_bars()` function that prevented empty dictionaries to be passed. Also added a warning when auto-calculated bar widths appear to be exceeding the dimension of the axis (usually occurs when the axis is <2 kilometeres or miles long, depending on the units selected).
|
248
248
|
|
249
|
+
- `v2.0.2`: Changed f-string formatting to alternate double and single quotes, so as to maintain compatibility with versions of Python before 3.12 (see [here](https://github.com/moss-xyz/matplotlib-map-utils/issues/3)). However, this did reveal that another aspect of the code, namely concatenating `type` in function arguments, requires 3.10, and so the minimum python version was incremented.
|
250
|
+
|
249
251
|
#### Future Roadmap
|
250
252
|
|
251
253
|
With the release of `v2.x`, and the addition of **Scale Bar** tools, this project has achieved the two main objectives that I set out to.
|
@@ -1,7 +1,7 @@
|
|
1
1
|
matplotlib_map_utils/__init__.py,sha256=X6lN1yfP4ckb6l-ej20YqFvIHUNLZQxRWnvvyWBlJEY,305
|
2
2
|
matplotlib_map_utils/core/__init__.py,sha256=G4fxPpfE77EhZr7yGZCjppP7zvwRthl8yHM0b2KgrFs,184
|
3
3
|
matplotlib_map_utils/core/north_arrow.py,sha256=vikwYtSP2-sPRF_SQBALezB3uEY_PHA9dglm503hkvU,22531
|
4
|
-
matplotlib_map_utils/core/scale_bar.py,sha256=
|
4
|
+
matplotlib_map_utils/core/scale_bar.py,sha256=l2tS35xa_pv40lag4Y00hT6FEGhQ-wOb07ipxDUYCNw,62248
|
5
5
|
matplotlib_map_utils/defaults/__init__.py,sha256=_pegE5kv_sb0ansSF4XpWBRwboaP4zUjWY1KIGbK-TE,119
|
6
6
|
matplotlib_map_utils/defaults/north_arrow.py,sha256=uZb1RsUWxFTHywm8HATj_9iPF_GjCs_Z2HOn0JchjTY,8571
|
7
7
|
matplotlib_map_utils/defaults/scale_bar.py,sha256=GpXiWUHcOsv43G1HOfpqw-dzDPQQzQB7RNdtIf0e7Bc,8225
|
@@ -11,8 +11,8 @@ matplotlib_map_utils/validation/__init__.py,sha256=0fL3N63jxjRwTU44b7-6ZYZJfOT_0
|
|
11
11
|
matplotlib_map_utils/validation/functions.py,sha256=QpOHs-GQ1NUMXO0HxAtEZvAcrXwsIE2ekqUhYm-IKGg,11783
|
12
12
|
matplotlib_map_utils/validation/north_arrow.py,sha256=dlWbcKit7dq93PJVrv1efE_865irT6zwBuqD6NYLYPg,10349
|
13
13
|
matplotlib_map_utils/validation/scale_bar.py,sha256=7rYs7ei0rQ5iJfapcBWkn7s4P-CnSh9B441GpsGpFO4,17628
|
14
|
-
matplotlib_map_utils-2.0.
|
15
|
-
matplotlib_map_utils-2.0.
|
16
|
-
matplotlib_map_utils-2.0.
|
17
|
-
matplotlib_map_utils-2.0.
|
18
|
-
matplotlib_map_utils-2.0.
|
14
|
+
matplotlib_map_utils-2.0.2.dist-info/LICENSE,sha256=aFLFZg6LEJFpTlNQ8su3__jw4GfV-xWBmC1cePkKZVw,35802
|
15
|
+
matplotlib_map_utils-2.0.2.dist-info/METADATA,sha256=cZsNz3TQGutdiC34xRb_KkCyGuOFhNoB6MiWf2-66dU,11060
|
16
|
+
matplotlib_map_utils-2.0.2.dist-info/WHEEL,sha256=52BFRY2Up02UkjOa29eZOS2VxUrpPORXg1pkohGGUS8,91
|
17
|
+
matplotlib_map_utils-2.0.2.dist-info/top_level.txt,sha256=6UyDpxsnMhSOd9a-abQe0lLJveybJyYtUHMdX7zXgKA,21
|
18
|
+
matplotlib_map_utils-2.0.2.dist-info/RECORD,,
|
File without changes
|
File without changes
|