apsg 1.3.3__py3-none-any.whl → 1.3.4__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.
- apsg/__init__.py +1 -1
- apsg/database/_alchemy.py +0 -1
- apsg/plotting/_projection.py +12 -4
- apsg/plotting/_stereonet.py +15 -14
- {apsg-1.3.3.dist-info → apsg-1.3.4.dist-info}/METADATA +1 -1
- {apsg-1.3.3.dist-info → apsg-1.3.4.dist-info}/RECORD +10 -10
- {apsg-1.3.3.dist-info → apsg-1.3.4.dist-info}/WHEEL +0 -0
- {apsg-1.3.3.dist-info → apsg-1.3.4.dist-info}/entry_points.txt +0 -0
- {apsg-1.3.3.dist-info → apsg-1.3.4.dist-info}/licenses/LICENSE +0 -0
- {apsg-1.3.3.dist-info → apsg-1.3.4.dist-info}/top_level.txt +0 -0
apsg/__init__.py
CHANGED
apsg/database/_alchemy.py
CHANGED
apsg/plotting/_projection.py
CHANGED
|
@@ -26,14 +26,18 @@ class Projection:
|
|
|
26
26
|
if self.hemisphere == "upper":
|
|
27
27
|
X, Y = self._project(-x, -y, -z)
|
|
28
28
|
if clip_inside:
|
|
29
|
-
outside =
|
|
29
|
+
outside = np.logical_and(
|
|
30
|
+
X * X + Y * Y > 1.0, ~np.isclose(X * X + Y * Y, 1)
|
|
31
|
+
)
|
|
30
32
|
X[outside] = np.nan
|
|
31
33
|
Y[outside] = np.nan
|
|
32
34
|
return -X, -Y
|
|
33
35
|
else:
|
|
34
36
|
X, Y = self._project(x, y, z)
|
|
35
37
|
if clip_inside:
|
|
36
|
-
outside =
|
|
38
|
+
outside = np.logical_and(
|
|
39
|
+
X * X + Y * Y > 1.0, ~np.isclose(X * X + Y * Y, 1)
|
|
40
|
+
)
|
|
37
41
|
X[outside] = np.nan
|
|
38
42
|
Y[outside] = np.nan
|
|
39
43
|
return X, Y
|
|
@@ -44,8 +48,12 @@ class Projection:
|
|
|
44
48
|
X1, Y1 = self._project(x, y, z)
|
|
45
49
|
X2, Y2 = self._project(-x, -y, -z)
|
|
46
50
|
if clip_inside:
|
|
47
|
-
outside1 =
|
|
48
|
-
|
|
51
|
+
outside1 = np.logical_and(
|
|
52
|
+
X1 * X1 + Y1 * Y1 > 1.0, ~np.isclose(X1 * X1 + Y1 * Y1, 1)
|
|
53
|
+
)
|
|
54
|
+
outside2 = np.logical_and(
|
|
55
|
+
X2 * X2 + Y2 * Y2 > 1.0, ~np.isclose(X2 * X2 + Y2 * Y2, 1)
|
|
56
|
+
)
|
|
49
57
|
X1[outside1] = np.nan
|
|
50
58
|
Y1[outside1] = np.nan
|
|
51
59
|
X2[outside2] = np.nan
|
apsg/plotting/_stereonet.py
CHANGED
|
@@ -939,6 +939,7 @@ def quicknet(*args, **kwargs):
|
|
|
939
939
|
savefig_kwargs (dict): dict passed to ``plt.savefig``
|
|
940
940
|
fol_as_pole (bool): True to plot planar features as poles,
|
|
941
941
|
False for plotting as great circle. Default `False`
|
|
942
|
+
Additional kwargs are passed to StereoNet method
|
|
942
943
|
|
|
943
944
|
Example:
|
|
944
945
|
>>> l = linset.random_fisher(position=lin(120, 50))
|
|
@@ -949,39 +950,39 @@ def quicknet(*args, **kwargs):
|
|
|
949
950
|
filename = kwargs.get("filename", "stereonet.png")
|
|
950
951
|
savefig_kwargs = kwargs.get("savefig_kwargs", {})
|
|
951
952
|
fol_as_pole = kwargs.get("fol_as_pole", False)
|
|
952
|
-
label = kwargs.get("label", "_nolegend_")
|
|
953
|
+
kwargs["label"] = kwargs.get("label", "_nolegend_")
|
|
953
954
|
s = StereoNet(**kwargs)
|
|
954
955
|
for arg in args:
|
|
955
956
|
if isinstance(arg, Vector3):
|
|
956
957
|
if isinstance(arg, Foliation):
|
|
957
958
|
if fol_as_pole:
|
|
958
|
-
s.pole(arg,
|
|
959
|
+
s.pole(arg, **kwargs)
|
|
959
960
|
else:
|
|
960
|
-
s.great_circle(arg,
|
|
961
|
+
s.great_circle(arg, **kwargs)
|
|
961
962
|
elif isinstance(arg, Lineation):
|
|
962
|
-
s.line(arg,
|
|
963
|
+
s.line(arg, **kwargs)
|
|
963
964
|
else:
|
|
964
|
-
s.vector(arg,
|
|
965
|
+
s.vector(arg, **kwargs)
|
|
965
966
|
elif isinstance(arg, Fault):
|
|
966
|
-
s.fault(arg,
|
|
967
|
+
s.fault(arg, **kwargs)
|
|
967
968
|
elif isinstance(arg, Pair):
|
|
968
|
-
s.pair(arg,
|
|
969
|
+
s.pair(arg, **kwargs)
|
|
969
970
|
elif isinstance(arg, Cone):
|
|
970
|
-
s.cone(arg,
|
|
971
|
+
s.cone(arg, **kwargs)
|
|
971
972
|
elif isinstance(arg, Vector3Set):
|
|
972
973
|
if isinstance(arg, FoliationSet):
|
|
973
974
|
if fol_as_pole:
|
|
974
|
-
s.pole(arg,
|
|
975
|
+
s.pole(arg, **kwargs)
|
|
975
976
|
else:
|
|
976
|
-
s.great_circle(arg,
|
|
977
|
+
s.great_circle(arg, **kwargs)
|
|
977
978
|
elif isinstance(arg, LineationSet):
|
|
978
|
-
s.line(arg,
|
|
979
|
+
s.line(arg, **kwargs)
|
|
979
980
|
else:
|
|
980
|
-
s.vector(arg,
|
|
981
|
+
s.vector(arg, **kwargs)
|
|
981
982
|
elif isinstance(arg, FaultSet):
|
|
982
|
-
s.fault(arg,
|
|
983
|
+
s.fault(arg, **kwargs)
|
|
983
984
|
elif isinstance(arg, PairSet):
|
|
984
|
-
s.pair(arg,
|
|
985
|
+
s.pair(arg, **kwargs)
|
|
985
986
|
else:
|
|
986
987
|
print(f"{type(arg)} not supported.")
|
|
987
988
|
if savefig:
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
apsg/__init__.py,sha256
|
|
1
|
+
apsg/__init__.py,sha256=-6B9IAuTnyKs_jwpjcUz4lRL5QvrcH1pzUyazuh5gwc,1966
|
|
2
2
|
apsg/config.py,sha256=X3_yXT96xXlVxFA94EfYFKJbrcGIHT0PvB9s8EKmYOg,4569
|
|
3
3
|
apsg/shell.py,sha256=1D0PeB7qXzlpiOf2QYGo6OJlEVN1KJPYld1GEREBiFg,707
|
|
4
4
|
apsg/database/__init__.py,sha256=7Rvcf1KBBBNhoM28ZlvQ01CkScQTroFkoS4d1kD55Ws,315
|
|
5
|
-
apsg/database/_alchemy.py,sha256=
|
|
5
|
+
apsg/database/_alchemy.py,sha256=geV3Q6ZLdGvjzxry7GTHHIQq6t_ccsUxZvuv13CLYFQ,19467
|
|
6
6
|
apsg/database/_sdbread.py,sha256=EP0hSp6_4-DZZptkMNDgKnQ3GD58mpr_SAgFohKu6xQ,11017
|
|
7
7
|
apsg/decorator/__init__.py,sha256=fZ-dxpldQIk6-2JhVnCj-Tsl8bz2nvoGOyG7uXKvBfg,160
|
|
8
8
|
apsg/decorator/_decorator.py,sha256=8TMSrcVvhU5UCbNMrnyrW3-65qo20_6N2ShtXd3bP-k,1194
|
|
@@ -26,13 +26,13 @@ apsg/plotting/__init__.py,sha256=immav5OfKhYlOGZWUsFjuBp7k71vr2xLYygQkO6Oimc,627
|
|
|
26
26
|
apsg/plotting/_fabricplot.py,sha256=yjy3DEhIZfq448FYKnQb3EhqLm9-f-EZHJEamG98k9Q,18858
|
|
27
27
|
apsg/plotting/_paleomagplots.py,sha256=Gw-fqYJVjNxTNXLwAiUKnFUBoOTZv2MEd3XACLmQ6AM,2325
|
|
28
28
|
apsg/plotting/_plot_artists.py,sha256=6S0EKCqYU6rlBxcxcXALTk9PaUK6QL-BgUKmZH8tkMc,21059
|
|
29
|
-
apsg/plotting/_projection.py,sha256=
|
|
29
|
+
apsg/plotting/_projection.py,sha256=ix67PwOU2WGjryEcsHlVIMpcVC9yxy45ycOV9k5x_Q8,11805
|
|
30
30
|
apsg/plotting/_roseplot.py,sha256=jbaUXSb3DIcXs0pWAQUTZfdlA2XcbquT0yHLYDjLirQ,12808
|
|
31
31
|
apsg/plotting/_stereogrid.py,sha256=awh7MwN1WgszhOlr6UgR20wHQJ8u778-Tf_w1uflrV4,11869
|
|
32
|
-
apsg/plotting/_stereonet.py,sha256
|
|
33
|
-
apsg-1.3.
|
|
34
|
-
apsg-1.3.
|
|
35
|
-
apsg-1.3.
|
|
36
|
-
apsg-1.3.
|
|
37
|
-
apsg-1.3.
|
|
38
|
-
apsg-1.3.
|
|
32
|
+
apsg/plotting/_stereonet.py,sha256=uHJXluFMkeaI4yzD9pGc4DIlgjZA01INySLKtUHLAlU,36624
|
|
33
|
+
apsg-1.3.4.dist-info/licenses/LICENSE,sha256=lY0kfpVRrzcgVZq7pI6rLK5WYiUMWe0bdKpDelN6hk8,1120
|
|
34
|
+
apsg-1.3.4.dist-info/METADATA,sha256=7HV-9ufjlab_qZ0vL3D-Il9UObgVg_FTRUfOZxGmENY,8298
|
|
35
|
+
apsg-1.3.4.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
|
|
36
|
+
apsg-1.3.4.dist-info/entry_points.txt,sha256=SowP7_uRI0NJuzznKBXyM9BJcSwBxbXo6Iz5LUo9mEQ,42
|
|
37
|
+
apsg-1.3.4.dist-info/top_level.txt,sha256=xWxwi0nqqOyKdmpsszfR-bmqnNpgVbhnLRuIKGJnaUM,5
|
|
38
|
+
apsg-1.3.4.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|