pygeodesy 24.9.9__py2.py3-none-any.whl → 24.9.24__py2.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.
- {PyGeodesy-24.9.9.dist-info → PyGeodesy-24.9.24.dist-info}/METADATA +6 -6
- {PyGeodesy-24.9.9.dist-info → PyGeodesy-24.9.24.dist-info}/RECORD +21 -21
- pygeodesy/__init__.py +7 -5
- pygeodesy/basics.py +9 -10
- pygeodesy/booleans.py +4 -4
- pygeodesy/clipy.py +7 -7
- pygeodesy/constants.py +19 -7
- pygeodesy/deprecated/__init__.py +1 -1
- pygeodesy/deprecated/functions.py +9 -1
- pygeodesy/errors.py +32 -5
- pygeodesy/fmath.py +36 -15
- pygeodesy/fstats.py +8 -12
- pygeodesy/fsums.py +726 -466
- pygeodesy/karney.py +1 -5
- pygeodesy/lazily.py +6 -6
- pygeodesy/points.py +3 -3
- pygeodesy/resections.py +2 -2
- pygeodesy/sphericalNvector.py +4 -4
- pygeodesy/sphericalTrigonometry.py +2 -2
- {PyGeodesy-24.9.9.dist-info → PyGeodesy-24.9.24.dist-info}/WHEEL +0 -0
- {PyGeodesy-24.9.9.dist-info → PyGeodesy-24.9.24.dist-info}/top_level.txt +0 -0
pygeodesy/karney.py
CHANGED
|
@@ -165,7 +165,7 @@ from pygeodesy.utily import atan2d, sincos2d, tand, _unrollon, fabs
|
|
|
165
165
|
# from math import fabs # from .utily
|
|
166
166
|
|
|
167
167
|
__all__ = _ALL_LAZY.karney
|
|
168
|
-
__version__ = '24.09.
|
|
168
|
+
__version__ = '24.09.13'
|
|
169
169
|
|
|
170
170
|
_K_2_0 = _getenv('PYGEODESY_GEOGRAPHICLIB', _2_)
|
|
171
171
|
_K_2_4 = _K_2_0 == '2.4'
|
|
@@ -835,10 +835,6 @@ except ImportError: # Python 3.12-
|
|
|
835
835
|
# S = Fhorner(x, *cs, incx=False)
|
|
836
836
|
# return float(S)
|
|
837
837
|
|
|
838
|
-
# def _poly_fma(x, s, *cs): # scalar x, s, cs
|
|
839
|
-
# S = Fsum(s)._fma_scalar(None, x, *cs)
|
|
840
|
-
# return float(S)
|
|
841
|
-
|
|
842
838
|
def _polynomial(x, cs, i, j): # PYCHOK shared
|
|
843
839
|
'''(INTERNAL) Like C++ C{GeographicLib.Math.hpp.polyval} but with a
|
|
844
840
|
signature and cascaded summation different from C{karney._sum3}.
|
pygeodesy/lazily.py
CHANGED
|
@@ -255,7 +255,7 @@ _ALL_LAZY = _NamedEnum_RO(_name='_ALL_LAZY',
|
|
|
255
255
|
fmath=_i('Fdot', 'Fhorner', 'Fhypot', 'Fpolynomial', 'Fpowers', 'Fcbrt', 'Froot', 'Fsqrt',
|
|
256
256
|
'bqrt', 'cbrt', 'cbrt2', 'euclid', 'euclid_',
|
|
257
257
|
'facos1', 'fasin1', 'fatan', 'fatan1', 'fatan2', 'favg',
|
|
258
|
-
'fdot', 'fdot3', 'fma', 'fmean', 'fmean_', 'fhorner', 'fidw', 'fpolynomial',
|
|
258
|
+
'fdot', 'fdot3', 'fma', 'fmean', 'fmean_', 'fhorner', 'fidw', 'f2mul_', 'fpolynomial',
|
|
259
259
|
'fpowers', 'fprod', 'frandoms', 'frange', 'freduce', 'fremainder',
|
|
260
260
|
'hypot', 'hypot_', 'hypot1', 'hypot2', 'hypot2_',
|
|
261
261
|
'norm2', 'norm_', 'sqrt0', 'sqrt3', 'sqrt_a', 'zcrt', 'zqrt'),
|
|
@@ -280,8 +280,8 @@ _ALL_LAZY = _NamedEnum_RO(_name='_ALL_LAZY',
|
|
|
280
280
|
'FrechetVincentys', 'Frechet6Tuple',
|
|
281
281
|
'frechet_'),
|
|
282
282
|
fstats=_i('Fcook', 'Flinear', 'Fwelford'),
|
|
283
|
-
fsums=_i('Fsum', '
|
|
284
|
-
'fsum', 'fsum_', 'fsumf_', 'fsum1', 'fsum1_', 'fsum1f_'),
|
|
283
|
+
fsums=_i('Fsum', 'DivMod2Tuple', 'Fsum2Tuple', 'ResidualError',
|
|
284
|
+
'f2product', 'fsum', 'fsum_', 'fsumf_', 'fsum1', 'fsum1_', 'fsum1f_', 'nonfiniterrors'),
|
|
285
285
|
gars=_i('Garef', 'GARSError'),
|
|
286
286
|
geodesici=_i('Intersectool', 'Intersectool5Tuple', 'Intersect7Tuple',
|
|
287
287
|
'Intersector', 'Intersector5Tuple', 'Middle5Tuple', 'XDict'),
|
|
@@ -420,8 +420,8 @@ _ALL_DEPRECATED = _NamedEnum_RO(_name='_ALL_DEPRECATED',
|
|
|
420
420
|
'clipCS3', 'clipDMS', 'clipStr', 'collins', 'copysign', # ... and spherical flavors
|
|
421
421
|
'decodeEPSG2', 'encodeEPSG', 'enStr2', 'equirectangular_', 'equirectangular3',
|
|
422
422
|
'excessAbc', 'excessGirard', 'excessLHuilier',
|
|
423
|
-
'false2f', 'falsed2f', 'float0', 'fStr', 'fStrzs', '
|
|
424
|
-
'inStr', 'isenclosedby', 'istuplist',
|
|
423
|
+
'false2f', 'falsed2f', 'float0', 'fStr', 'fStrzs', 'Fsum2product',
|
|
424
|
+
'hypot3', 'inStr', 'isenclosedby', 'istuplist',
|
|
425
425
|
'joined', 'joined_', 'nearestOn3', 'nearestOn4',
|
|
426
426
|
'parseUTM', 'perimeterof', 'polygon', 'scalar', 'simplify2',
|
|
427
427
|
'tienstra', 'toUtm', 'triAngle4',
|
|
@@ -526,7 +526,7 @@ class _ALL_MODS(_internals._MODS_Base):
|
|
|
526
526
|
_internals._MODS = _ALL_MODS = _ALL_MODS() # PYCHOK singleton
|
|
527
527
|
|
|
528
528
|
__all__ = _ALL_LAZY.lazily
|
|
529
|
-
__version__ = '24.09.
|
|
529
|
+
__version__ = '24.09.19'
|
|
530
530
|
|
|
531
531
|
|
|
532
532
|
def _ALL_OTHER(*objs):
|
pygeodesy/points.py
CHANGED
|
@@ -62,7 +62,7 @@ from pygeodesy.utily import atan2b, degrees90, degrees180, degrees2m, \
|
|
|
62
62
|
from math import cos, fabs, fmod as _fmod, radians, sin
|
|
63
63
|
|
|
64
64
|
__all__ = _ALL_LAZY.points
|
|
65
|
-
__version__ = '24.
|
|
65
|
+
__version__ = '24.09.23'
|
|
66
66
|
|
|
67
67
|
_ilat_ = 'ilat'
|
|
68
68
|
_ilon_ = 'ilon'
|
|
@@ -1430,7 +1430,7 @@ def ispolar(points, wrap=False):
|
|
|
1430
1430
|
|
|
1431
1431
|
# summation of course deltas around pole is 0° rather than normally ±360°
|
|
1432
1432
|
# <https://blog.Element84.com/determining-if-a-spherical-polygon-contains-a-pole.html>
|
|
1433
|
-
s = fsum(_cds(points, wrap)
|
|
1433
|
+
s = fsum(_cds(points, wrap))
|
|
1434
1434
|
# XXX fix (intermittant) edge crossing pole - eg (85,90), (85,0), (85,-90)
|
|
1435
1435
|
return fabs(s) < 90 # "zero-ish"
|
|
1436
1436
|
|
|
@@ -1631,7 +1631,7 @@ def perimeterOf(points, closed=False, adjust=True, radius=R_M, wrap=True):
|
|
|
1631
1631
|
d = points._sum1(perimeterOf, closed=True, adjust=adjust,
|
|
1632
1632
|
radius=radius, wrap=wrap)
|
|
1633
1633
|
else:
|
|
1634
|
-
d = fsum(_degs(points, closed, adjust, wrap)
|
|
1634
|
+
d = fsum(_degs(points, closed, adjust, wrap))
|
|
1635
1635
|
return degrees2m(d, radius=radius)
|
|
1636
1636
|
|
|
1637
1637
|
|
pygeodesy/resections.py
CHANGED
|
@@ -34,7 +34,7 @@ from pygeodesy.vector3d import _otherV3d, Vector3d
|
|
|
34
34
|
from math import cos, atan2, degrees, fabs, radians, sin, sqrt
|
|
35
35
|
|
|
36
36
|
__all__ = _ALL_LAZY.resections
|
|
37
|
-
__version__ = '24.
|
|
37
|
+
__version__ = '24.09.23'
|
|
38
38
|
|
|
39
39
|
_concyclic_ = 'concyclic'
|
|
40
40
|
_PA_ = 'PA'
|
|
@@ -664,7 +664,7 @@ def tienstra7(pointA, pointB, pointC, alpha, beta=None, gamma=None,
|
|
|
664
664
|
dB = _deg_ks(_triAngle(a, c, b), sb, ks, _B_)
|
|
665
665
|
dC = _deg_ks(_triAngle(a, b, c), sc, ks, _C_)
|
|
666
666
|
|
|
667
|
-
k = fsum1(ks
|
|
667
|
+
k = fsum1(ks)
|
|
668
668
|
if isnear0(k):
|
|
669
669
|
raise ValueError(Fmt.EQUAL(K=k))
|
|
670
670
|
x = Fdot(ks, A.x, B.x, C.x).fover(k)
|
pygeodesy/sphericalNvector.py
CHANGED
|
@@ -61,7 +61,7 @@ from pygeodesy.utily import atan2, degrees360, fabs, sincos2, sincos2_, \
|
|
|
61
61
|
# from math import atan2, fabs # from utily
|
|
62
62
|
|
|
63
63
|
__all__ = _ALL_LAZY.sphericalNvector
|
|
64
|
-
__version__ = '24.
|
|
64
|
+
__version__ = '24.09.23'
|
|
65
65
|
|
|
66
66
|
_lines_ = 'lines'
|
|
67
67
|
|
|
@@ -491,7 +491,7 @@ class LatLon(LatLonNvectorBase, LatLonSphericalBase):
|
|
|
491
491
|
# an exterior point will sum to 0°. On a sphere, enclosed
|
|
492
492
|
# point angles will sum to less than 360° (due to spherical
|
|
493
493
|
# excess), exterior point angles will be small but non-zero.
|
|
494
|
-
s = fsum(_subtangles(points, wrap)
|
|
494
|
+
s = fsum(_subtangles(points, wrap)) # normal vector
|
|
495
495
|
# XXX are winding number optimisations equally applicable to
|
|
496
496
|
# spherical surface?
|
|
497
497
|
return fabs(s) > PI
|
|
@@ -846,7 +846,7 @@ def areaOf(points, radius=R_M, wrap=False):
|
|
|
846
846
|
# angle between edges is π−α or π+α, where α is angle between
|
|
847
847
|
# great-circle vectors; so sum α, then take n·π − |Σα| (cannot
|
|
848
848
|
# use Σ(π−|α|) as concave polygons would fail)
|
|
849
|
-
s = fsum(_interangles(points, wrap)
|
|
849
|
+
s = fsum(_interangles(points, wrap))
|
|
850
850
|
# using Girard’s theorem: A = [Σθᵢ − (n−2)·π]·R²
|
|
851
851
|
# (PI2 - abs(s) == (n*PI - abs(s)) - (n-2)*PI)
|
|
852
852
|
r = fabs(PI2 - fabs(s))
|
|
@@ -1138,7 +1138,7 @@ def perimeterOf(points, closed=False, radius=R_M, wrap=False):
|
|
|
1138
1138
|
notImplemented(None, closed=closed, points=_composite_)
|
|
1139
1139
|
r = points._sum2(LatLon, perimeterOf, closed=True, radius=None, wrap=wrap)
|
|
1140
1140
|
else:
|
|
1141
|
-
r = fsum(_rads(points, closed, wrap)
|
|
1141
|
+
r = fsum(_rads(points, closed, wrap))
|
|
1142
1142
|
return r if radius is None else (Radius(radius) * r)
|
|
1143
1143
|
|
|
1144
1144
|
|
|
@@ -54,7 +54,7 @@ from pygeodesy.vector3d import sumOf, Vector3d
|
|
|
54
54
|
from math import asin, atan2, cos, degrees, fabs, radians, sin
|
|
55
55
|
|
|
56
56
|
__all__ = _ALL_LAZY.sphericalTrigonometry
|
|
57
|
-
__version__ = '24.
|
|
57
|
+
__version__ = '24.09.23'
|
|
58
58
|
|
|
59
59
|
_PI_EPS4 = PI - EPS4
|
|
60
60
|
if _PI_EPS4 >= PI:
|
|
@@ -1302,7 +1302,7 @@ def perimeterOf(points, closed=False, radius=R_M, wrap=True):
|
|
|
1302
1302
|
raise _ValueError(closed=closed, points=_composite_)
|
|
1303
1303
|
r = points._sum2(LatLon, perimeterOf, closed=True, radius=radius, wrap=wrap)
|
|
1304
1304
|
else:
|
|
1305
|
-
r = fsum(_rads(points, closed, wrap)
|
|
1305
|
+
r = fsum(_rads(points, closed, wrap))
|
|
1306
1306
|
return _radians2m(r, radius)
|
|
1307
1307
|
|
|
1308
1308
|
|
|
File without changes
|
|
File without changes
|