pygeodesy 25.10.10__py2.py3-none-any.whl → 25.12.12__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.
Files changed (126) hide show
  1. pygeodesy/__init__.py +25 -12
  2. pygeodesy/__main__.py +1 -1
  3. pygeodesy/albers.py +1 -1
  4. pygeodesy/angles.py +960 -0
  5. pygeodesy/auxilats/_CX_4.py +1 -1
  6. pygeodesy/auxilats/_CX_6.py +1 -1
  7. pygeodesy/auxilats/_CX_8.py +1 -1
  8. pygeodesy/auxilats/_CX_Rs.py +1 -1
  9. pygeodesy/auxilats/__init__.py +2 -2
  10. pygeodesy/auxilats/__main__.py +1 -1
  11. pygeodesy/auxilats/auxAngle.py +7 -8
  12. pygeodesy/auxilats/auxDLat.py +1 -1
  13. pygeodesy/auxilats/auxDST.py +1 -1
  14. pygeodesy/auxilats/auxLat.py +1 -1
  15. pygeodesy/auxilats/auxily.py +1 -1
  16. pygeodesy/azimuthal.py +6 -5
  17. pygeodesy/basics.py +14 -10
  18. pygeodesy/booleans.py +8 -33
  19. pygeodesy/cartesianBase.py +7 -7
  20. pygeodesy/clipy.py +17 -23
  21. pygeodesy/constants.py +86 -63
  22. pygeodesy/css.py +1 -1
  23. pygeodesy/datums.py +1 -1
  24. pygeodesy/deprecated/__init__.py +2 -2
  25. pygeodesy/deprecated/bases.py +1 -1
  26. pygeodesy/deprecated/classes.py +32 -2
  27. pygeodesy/deprecated/consterns.py +1 -1
  28. pygeodesy/deprecated/datum.py +1 -1
  29. pygeodesy/deprecated/functions.py +1 -1
  30. pygeodesy/deprecated/nvector.py +1 -1
  31. pygeodesy/deprecated/rhumbBase.py +1 -1
  32. pygeodesy/deprecated/rhumbaux.py +1 -1
  33. pygeodesy/deprecated/rhumbsolve.py +1 -1
  34. pygeodesy/deprecated/rhumbx.py +1 -1
  35. pygeodesy/dms.py +1 -1
  36. pygeodesy/ecef.py +1 -1
  37. pygeodesy/ecefLocals.py +1 -1
  38. pygeodesy/elevations.py +1 -1
  39. pygeodesy/ellipsoidalBase.py +1 -1
  40. pygeodesy/ellipsoidalBaseDI.py +1 -1
  41. pygeodesy/ellipsoidalExact.py +1 -1
  42. pygeodesy/ellipsoidalGeodSolve.py +1 -1
  43. pygeodesy/ellipsoidalKarney.py +1 -1
  44. pygeodesy/ellipsoidalNvector.py +1 -1
  45. pygeodesy/ellipsoidalVincenty.py +1 -1
  46. pygeodesy/ellipsoids.py +7 -6
  47. pygeodesy/elliptic.py +1 -1
  48. pygeodesy/epsg.py +1 -1
  49. pygeodesy/errors.py +8 -4
  50. pygeodesy/etm.py +1 -1
  51. pygeodesy/fmath.py +15 -8
  52. pygeodesy/formy.py +107 -5
  53. pygeodesy/frechet.py +1 -1
  54. pygeodesy/fstats.py +1 -1
  55. pygeodesy/fsums.py +1 -1
  56. pygeodesy/gars.py +1 -1
  57. pygeodesy/geod3solve.py +488 -0
  58. pygeodesy/geodesici.py +4 -4
  59. pygeodesy/geodesicw.py +1 -1
  60. pygeodesy/geodesicx/_C4_24.py +1 -1
  61. pygeodesy/geodesicx/_C4_27.py +1 -1
  62. pygeodesy/geodesicx/_C4_30.py +1 -1
  63. pygeodesy/geodesicx/__init__.py +1 -1
  64. pygeodesy/geodesicx/__main__.py +1 -1
  65. pygeodesy/geodesicx/gx.py +1 -1
  66. pygeodesy/geodesicx/gxarea.py +1 -1
  67. pygeodesy/geodesicx/gxbases.py +1 -1
  68. pygeodesy/geodesicx/gxline.py +1 -1
  69. pygeodesy/geodsolve.py +70 -102
  70. pygeodesy/geohash.py +1 -1
  71. pygeodesy/geoids.py +1 -1
  72. pygeodesy/hausdorff.py +1 -1
  73. pygeodesy/heights.py +1 -1
  74. pygeodesy/internals.py +3 -3
  75. pygeodesy/interns.py +3 -3
  76. pygeodesy/iters.py +1 -1
  77. pygeodesy/karney.py +132 -116
  78. pygeodesy/ktm.py +1 -1
  79. pygeodesy/latlonBase.py +1 -1
  80. pygeodesy/lazily.py +25 -13
  81. pygeodesy/lcc.py +1 -1
  82. pygeodesy/ltp.py +1 -1
  83. pygeodesy/ltpTuples.py +1 -1
  84. pygeodesy/mgrs.py +3 -3
  85. pygeodesy/named.py +14 -9
  86. pygeodesy/namedTuples.py +1 -1
  87. pygeodesy/nvectorBase.py +1 -1
  88. pygeodesy/osgr.py +1 -1
  89. pygeodesy/points.py +1 -1
  90. pygeodesy/props.py +1 -1
  91. pygeodesy/resections.py +1 -1
  92. pygeodesy/rhumb/__init__.py +8 -6
  93. pygeodesy/rhumb/aux_.py +1 -1
  94. pygeodesy/rhumb/bases.py +1 -1
  95. pygeodesy/rhumb/ekx.py +1 -1
  96. pygeodesy/rhumb/solve.py +91 -84
  97. pygeodesy/simplify.py +1 -1
  98. pygeodesy/solveBase.py +72 -49
  99. pygeodesy/sphericalBase.py +1 -1
  100. pygeodesy/sphericalNvector.py +1 -1
  101. pygeodesy/sphericalTrigonometry.py +1 -1
  102. pygeodesy/streprs.py +6 -4
  103. pygeodesy/trf.py +1 -1
  104. pygeodesy/triaxials/__init__.py +70 -0
  105. pygeodesy/triaxials/bases.py +935 -0
  106. pygeodesy/triaxials/conformal3.py +617 -0
  107. pygeodesy/triaxials/triaxial3.py +969 -0
  108. pygeodesy/triaxials/triaxial5.py +1220 -0
  109. pygeodesy/units.py +6 -1
  110. pygeodesy/unitsBase.py +1 -1
  111. pygeodesy/ups.py +2 -3
  112. pygeodesy/utily.py +19 -15
  113. pygeodesy/utm.py +1 -1
  114. pygeodesy/utmups.py +1 -1
  115. pygeodesy/utmupsBase.py +1 -1
  116. pygeodesy/vector2d.py +2 -2
  117. pygeodesy/vector3d.py +1 -1
  118. pygeodesy/vector3dBase.py +195 -51
  119. pygeodesy/webmercator.py +1 -1
  120. pygeodesy/wgrs.py +1 -1
  121. {pygeodesy-25.10.10.dist-info → pygeodesy-25.12.12.dist-info}/METADATA +13 -13
  122. pygeodesy-25.12.12.dist-info/RECORD +125 -0
  123. pygeodesy/triaxials.py +0 -1566
  124. pygeodesy-25.10.10.dist-info/RECORD +0 -119
  125. {pygeodesy-25.10.10.dist-info → pygeodesy-25.12.12.dist-info}/WHEEL +0 -0
  126. {pygeodesy-25.10.10.dist-info → pygeodesy-25.12.12.dist-info}/top_level.txt +0 -0
@@ -120,7 +120,7 @@ del _Rcoeffs, _Rdict, _Rtuple
120
120
 
121
121
  # **) MIT License
122
122
  #
123
- # Copyright (C) 2023-2025 -- mrJean1 at Gmail -- All Rights Reserved.
123
+ # Copyright (C) 2023-2026 -- mrJean1 at Gmail -- All Rights Reserved.
124
124
  #
125
125
  # Permission is hereby granted, free of charge, to any person obtaining a
126
126
  # copy of this software and associated documentation files (the "Software"),
@@ -168,7 +168,7 @@ del _Rcoeffs, _Rdict, _Rtuple
168
168
 
169
169
  # **) MIT License
170
170
  #
171
- # Copyright (C) 2023-2025 -- mrJean1 at Gmail -- All Rights Reserved.
171
+ # Copyright (C) 2023-2026 -- mrJean1 at Gmail -- All Rights Reserved.
172
172
  #
173
173
  # Permission is hereby granted, free of charge, to any person obtaining a
174
174
  # copy of this software and associated documentation files (the "Software"),
@@ -227,7 +227,7 @@ del _Rcoeffs, _Rdict, _Rtuple
227
227
 
228
228
  # **) MIT License
229
229
  #
230
- # Copyright (C) 2023-2025 -- mrJean1 at Gmail -- All Rights Reserved.
230
+ # Copyright (C) 2023-2026 -- mrJean1 at Gmail -- All Rights Reserved.
231
231
  #
232
232
  # Permission is hereby granted, free of charge, to any person obtaining a
233
233
  # copy of this software and associated documentation files (the "Software"),
@@ -220,7 +220,7 @@ class _Rtuple(list): # MUST be list, NOT tuple!
220
220
 
221
221
  # **) MIT License
222
222
  #
223
- # Copyright (C) 2024-2025 -- mrJean1 at Gmail -- All Rights Reserved.
223
+ # Copyright (C) 2024-2026 -- mrJean1 at Gmail -- All Rights Reserved.
224
224
  #
225
225
  # Permission is hereby granted, free of charge, to any person obtaining a
226
226
  # copy of this software and associated documentation files (the "Software"),
@@ -29,11 +29,11 @@ from pygeodesy.lazily import _ALL_OTHER
29
29
  # no modules: auxAngle, auxDLat, auxDST, auxily, auxLat
30
30
  __all__ = _ALL_OTHER(Aux, AuxAngle, AuxDLat, AuxDST, AuxLat,
31
31
  AuxBeta, AuxChi, AuxMu, AuxPhi, AuxTheta, AuxXi)
32
- __version__ = '25.08.28'
32
+ __version__ = '25.12.02'
33
33
 
34
34
  # **) MIT License
35
35
  #
36
- # Copyright (C) 2023-2025 -- mrJean1 at Gmail -- All Rights Reserved.
36
+ # Copyright (C) 2023-2026 -- mrJean1 at Gmail -- All Rights Reserved.
37
37
  #
38
38
  # Permission is hereby granted, free of charge, to any person obtaining a
39
39
  # copy of this software and associated documentation files (the "Software"),
@@ -53,7 +53,7 @@ _main(ALorder=int(argv[1])) if len(argv) == 2 and argv[1].isdigit() else _main()
53
53
 
54
54
  # **) MIT License
55
55
  #
56
- # Copyright (C) 2023-2025 -- mrJean1 at Gmail -- All Rights Reserved.
56
+ # Copyright (C) 2023-2026 -- mrJean1 at Gmail -- All Rights Reserved.
57
57
  #
58
58
  # Permission is hereby granted, free of charge, to any person obtaining a
59
59
  # copy of this software and associated documentation files (the "Software"),
@@ -16,8 +16,8 @@ from __future__ import division as _; del _ # noqa: E702 ;
16
16
 
17
17
  from pygeodesy.auxilats.auxily import Aux, _Aux2Greek, AuxError
18
18
  from pygeodesy.basics import map1, map2, _xinstanceof
19
- from pygeodesy.constants import EPS, _INF_NAN_NINF, MAX, NAN, _0_0, _0_5, _1_0, \
20
- _copysign_1_0, isfinite, isnan, _over, _pos_self
19
+ from pygeodesy.constants import EPS, MAX, NAN, _0_0, _0_5, _1_0, _copysign_1_0, \
20
+ isfinite, isnan, _over, _pos_self
21
21
  # from pygeodesy.errors import AuxError # from .auxilats.auxily
22
22
  from pygeodesy.fmath import hypot, unstr
23
23
  from pygeodesy.fsums import _add_op_, _iadd_op_, _isub_op_, _sub_op_
@@ -32,11 +32,10 @@ from pygeodesy.utily import atan2, atan2d, sincos2, sincos2d
32
32
  from math import asinh, copysign, degrees, fabs, radians, sinh
33
33
 
34
34
  __all__ = ()
35
- __version__ = '25.08.31'
35
+ __version__ = '25.12.02'
36
36
 
37
- _0_INF_NAN_NINF = (0, _0_0) + _INF_NAN_NINF
38
- _MAX_2 = MAX * _0_5 # PYCHOK used!
39
- # del _INF_NAN_NINF, MAX
37
+ _MAX_2 = MAX * _0_5 # PYCHOK used!
38
+ # del MAX
40
39
 
41
40
 
42
41
  class AuxAngle(_Named):
@@ -519,7 +518,7 @@ def _yx2(yx):
519
518
  try:
520
519
  y, x = yx
521
520
  y, x = map1(float, y, x)
522
- if y in _0_INF_NAN_NINF:
521
+ if not (y and isfinite(y)):
523
522
  x = _copysign_1_0(x)
524
523
  except (TypeError, ValueError) as X:
525
524
  raise AuxError(y=y, x=x, cause=X)
@@ -530,7 +529,7 @@ __all__ += _ALL_DOCS(AuxAngle, *_AUXClass.values())
530
529
 
531
530
  # **) MIT License
532
531
  #
533
- # Copyright (C) 2023-2025 -- mrJean1 at Gmail -- All Rights Reserved.
532
+ # Copyright (C) 2023-2026 -- mrJean1 at Gmail -- All Rights Reserved.
534
533
  #
535
534
  # Permission is hereby granted, free of charge, to any person obtaining a
536
535
  # copy of this software and associated documentation files (the "Software"),
@@ -282,7 +282,7 @@ __all__ += _ALL_DOCS(AuxDLat)
282
282
 
283
283
  # **) MIT License
284
284
  #
285
- # Copyright (C) 2023-2025 -- mrJean1 at Gmail -- All Rights Reserved.
285
+ # Copyright (C) 2023-2026 -- mrJean1 at Gmail -- All Rights Reserved.
286
286
  #
287
287
  # Permission is hereby granted, free of charge, to any person obtaining a
288
288
  # copy of this software and associated documentation files (the "Software"),
@@ -274,7 +274,7 @@ __all__ += _ALL_DOCS(AuxDST)
274
274
 
275
275
  # **) MIT License
276
276
  #
277
- # Copyright (C) 2023-2025 -- mrJean1 at Gmail -- All Rights Reserved.
277
+ # Copyright (C) 2023-2026 -- mrJean1 at Gmail -- All Rights Reserved.
278
278
  #
279
279
  # Permission is hereby granted, free of charge, to any person obtaining a
280
280
  # copy of this software and associated documentation files (the "Software"),
@@ -847,7 +847,7 @@ __all__ += _ALL_DOCS(AuxLat)
847
847
 
848
848
  # **) MIT License
849
849
  #
850
- # Copyright (C) 2023-2025 -- mrJean1 at Gmail -- All Rights Reserved.
850
+ # Copyright (C) 2023-2026 -- mrJean1 at Gmail -- All Rights Reserved.
851
851
  #
852
852
  # Permission is hereby granted, free of charge, to any person obtaining a
853
853
  # copy of this software and associated documentation files (the "Software"),
@@ -235,7 +235,7 @@ del _Rkey
235
235
 
236
236
  # **) MIT License
237
237
  #
238
- # Copyright (C) 2023-2025 -- mrJean1 at Gmail -- All Rights Reserved.
238
+ # Copyright (C) 2023-2026 -- mrJean1 at Gmail -- All Rights Reserved.
239
239
  #
240
240
  # Permission is hereby granted, free of charge, to any person obtaining a
241
241
  # copy of this software and associated documentation files (the "Software"),
pygeodesy/azimuthal.py CHANGED
@@ -48,7 +48,7 @@ from pygeodesy.constants import EPS, EPS0, EPS1, NAN, isnon0, _umod_360, \
48
48
  from pygeodesy.ellipsoidalBase import LatLonEllipsoidalBase as _LLEB, \
49
49
  _isin, _xinstanceof
50
50
  from pygeodesy.datums import _spherical_datum, _WGS84
51
- from pygeodesy.errors import _ValueError, _xdatum, _xkwds
51
+ from pygeodesy.errors import _ValueError, _xattr, _xdatum, _xkwds
52
52
  from pygeodesy.fmath import euclid, hypot as _hypot, Fsum
53
53
  # from pygeodesy.fsums import Fsum # from .fmath
54
54
  # from pygeodesy.formy import antipode # _MODS
@@ -71,7 +71,7 @@ from pygeodesy.utily import asin1, atan1, atan2, atan2b, atan2d, \
71
71
  from math import acos, degrees, fabs, sin, sqrt
72
72
 
73
73
  __all__ = _ALL_LAZY.azimuthal
74
- __version__ = '25.09.29'
74
+ __version__ = '25.11.29'
75
75
 
76
76
  _EPS_K = _EPStol * _0_1 # Karney's eps_ or _EPSmin * _0_1?
77
77
  _over_horizon_ = 'over horizon'
@@ -195,8 +195,9 @@ class _AzimuthalBase(_NamedBase):
195
195
  '''
196
196
  B = _LLEB if self.datum.isEllipsoidal else _LLB
197
197
  _xinstanceof(B, LatLon2Tuple, LatLon4Tuple, latlon0=latlon0)
198
- if hasattr(latlon0, _datum_):
199
- _xdatum(self.datum, latlon0.datum, Error=AzimuthalError)
198
+ D = _xattr(latlon0, datum=B)
199
+ if D is not B:
200
+ _xdatum(self.datum, D, Error=AzimuthalError)
200
201
  self.reset(latlon0.lat, latlon0.lon)
201
202
 
202
203
  @Property_RO
@@ -1118,7 +1119,7 @@ __all__ += _ALL_DOCS(_AzimuthalBase, _AzimuthalGeodesic, _EquidistantBase, _Gnom
1118
1119
 
1119
1120
  # **) MIT License
1120
1121
  #
1121
- # Copyright (C) 2016-2025 -- mrJean1 at Gmail -- All Rights Reserved.
1122
+ # Copyright (C) 2016-2026 -- mrJean1 at Gmail -- All Rights Reserved.
1122
1123
  #
1123
1124
  # Permission is hereby granted, free of charge, to any person obtaining a
1124
1125
  # copy of this software and associated documentation files (the "Software"),
pygeodesy/basics.py CHANGED
@@ -37,7 +37,7 @@ from math import copysign as _copysign
37
37
  # import inspect as _inspect # _MODS
38
38
 
39
39
  __all__ = _ALL_LAZY.basics
40
- __version__ = '25.09.04'
40
+ __version__ = '25.12.02'
41
41
 
42
42
  _below_ = 'below'
43
43
  _list_tuple_types = (list, tuple)
@@ -347,8 +347,8 @@ def isfloat(obj, both=False):
347
347
 
348
348
 
349
349
  try:
350
- isidentifier = str.isidentifier # Python 3, must be str
351
- except AttributeError: # Python 2-
350
+ isidentifier = str.isidentifier # must be str
351
+ except AttributeError: # 2.0-
352
352
 
353
353
  def isidentifier(obj):
354
354
  '''Is B{C{obj}}ect a Python identifier?
@@ -445,7 +445,7 @@ def isiterabletype(obj, method='__iter__'):
445
445
 
446
446
 
447
447
  try:
448
- from keyword import iskeyword # Python 2.7+
448
+ from keyword import iskeyword # 2.7+
449
449
  except ImportError:
450
450
 
451
451
  def iskeyword(unused):
@@ -713,12 +713,16 @@ def _reverange(n, stop=-1, step=-1):
713
713
  return range(n - 1, stop, step)
714
714
 
715
715
 
716
- def signBit(x):
717
- '''Return C{signbit(B{x})}, like C++, see also L{isneg}.
716
+ try:
717
+ from math import signbit as signBit # 3.15+
718
+ except ImportError:
718
719
 
719
- @return: C{True} if C{B{x} < 0} or C{NEG0} (C{bool}).
720
- '''
721
- return (x or _copysign(1, x)) < 0
720
+ def signBit(x):
721
+ '''Return C{signbit(B{x})}, like C++, see also L{isneg}.
722
+
723
+ @return: C{True} if C{B{x} < 0} or C{NEG0} (C{bool}).
724
+ '''
725
+ return (x or _copysign(1, x)) < 0
722
726
 
723
727
 
724
728
  def _signOf(x, ref): # in .fsums
@@ -1029,7 +1033,7 @@ _XPACKAGES = _splituple(_envPYGEODESY(_xpackages_).lower()) # test/bases._X_OK
1029
1033
 
1030
1034
  # **) MIT License
1031
1035
  #
1032
- # Copyright (C) 2016-2025 -- mrJean1 at Gmail -- All Rights Reserved.
1036
+ # Copyright (C) 2016-2026 -- mrJean1 at Gmail -- All Rights Reserved.
1033
1037
  #
1034
1038
  # Permission is hereby granted, free of charge, to any person obtaining a
1035
1039
  # copy of this software and associated documentation files (the "Software"),
pygeodesy/booleans.py CHANGED
@@ -45,7 +45,7 @@ from pygeodesy.utily import fabs, _unrollon, _Wrap
45
45
  # from math import fabs # from .utily
46
46
 
47
47
  __all__ = _ALL_LAZY.booleans
48
- __version__ = '25.09.04'
48
+ __version__ = '25.10.30'
49
49
 
50
50
  _0EPS = EPS # near-zero, positive
51
51
  _EPS0 = -EPS # near-zero, negative
@@ -1434,17 +1434,14 @@ class _CompositeGH(_CompositeBase):
1434
1434
 
1435
1435
  def _clip(self, corners, s_entry, c_entry, Clas=None,
1436
1436
  **closed_inull_raiser_xtend_eps):
1437
- # Clip this polygon with another one, C{corners}.
1438
-
1439
- # Core of Greiner/Hormann's algorithm, enhanced U{Correia's
1440
- # <https://GitHub.com/helderco/univ-polyclip>} implementation***
1441
- # and extended to optionally handle so-called "degenerate cases"
1437
+ # Clip this polygon with another one, C{corners}, using
1438
+ # Greiner/Hormann's algorithm extended to optionally
1439
+ # handle some so-called "degenerate cases"
1442
1440
  S = self
1443
1441
  C = self._class(corners, closed_inull_raiser_xtend_eps,
1444
1442
  raiser=False, xtend=False)
1445
1443
  bt = C._bottom_top_eps2
1446
1444
  lr = C._left_right_eps2
1447
-
1448
1445
  # 1. find intersections
1449
1446
  for s1, s2, Sc in S._edges3(**closed_inull_raiser_xtend_eps):
1450
1447
  if not (_outside(s1.x, s2.x, *lr) or
@@ -1507,13 +1504,13 @@ class _CompositeGH(_CompositeBase):
1507
1504
 
1508
1505
  @property
1509
1506
  def xtend(self):
1510
- '''Get the option to handle I{degenerate cases} (C{bool}).
1507
+ '''Get the option to handle some I{degenerate cases} (C{bool}).
1511
1508
  '''
1512
1509
  return self._xtend
1513
1510
 
1514
1511
  @xtend.setter # PYCHOK setter!
1515
1512
  def xtend(self, xtend):
1516
- '''Set the option to handle I{degenerate cases} (C{bool}).
1513
+ '''Set the option to handle some I{degenerate cases} (C{bool}).
1517
1514
  '''
1518
1515
  self._xtend = bool(xtend)
1519
1516
 
@@ -1825,9 +1822,7 @@ class BooleanFHP(_CompositeFHP, _BooleanBase):
1825
1822
  class BooleanGH(_CompositeGH, _BooleanBase):
1826
1823
  '''I{Composite} class providing I{boolean} operations between two
1827
1824
  I{composites} using the U{Greiner-Hormann<http://www.Inf.USI.CH/
1828
- hormann/papers/Greiner.1998.ECO.pdf>} algorithm and U{Correia
1829
- <https://GitHub.com/helderco/univ-polyclip>}'s implementation,
1830
- modified and extended.
1825
+ hormann/papers/Greiner.1998.ECO.pdf>} algorithm, extended.
1831
1826
 
1832
1827
  The supported operations between (composite) polygon A and B are:
1833
1828
 
@@ -1984,7 +1979,7 @@ __all__ += _ALL_DOCS(_BooleanBase, _Clip,
1984
1979
 
1985
1980
  # **) MIT License
1986
1981
  #
1987
- # Copyright (C) 2018-2025 -- mrJean1 at Gmail -- All Rights Reserved.
1982
+ # Copyright (C) 2018-2026 -- mrJean1 at Gmail -- All Rights Reserved.
1988
1983
  #
1989
1984
  # Permission is hereby granted, free of charge, to any person obtaining a
1990
1985
  # copy of this software and associated documentation files (the "Software"),
@@ -2003,23 +1998,3 @@ __all__ += _ALL_DOCS(_BooleanBase, _Clip,
2003
1998
  # OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
2004
1999
  # ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
2005
2000
  # OTHER DEALINGS IN THE SOFTWARE.
2006
-
2007
- # ***) GNU GPL 3
2008
- #
2009
- # Copyright (C) 2011-2012 Helder Correia <Helder.MC@Gmail.com>
2010
- #
2011
- # This program is free software: you can redistribute it and/or
2012
- # modify it under the terms of the GNU General Public License as
2013
- # published by the Free Software Foundation, either version 3 of
2014
- # the License, or any later version.
2015
- #
2016
- # This program is distributed in the hope that it will be useful,
2017
- # but WITHOUT ANY WARRANTY; without even the implied warranty of
2018
- # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
2019
- # GNU General Public License for more details.
2020
- #
2021
- # You should have received a copy of the GNU General Public License
2022
- # along with this program. If not, see <http://www.GNU.org/licenses/>.
2023
- #
2024
- # You should have received the README file along with this program.
2025
- # If not, see <https://GitHub.com/helderco/univ-polyclip>.
@@ -11,8 +11,8 @@ U{https://www.Movable-Type.co.UK/scripts/geodesy/docs/latlon-ellipsoidal.js.html
11
11
  '''
12
12
 
13
13
  from pygeodesy.basics import _isin, _xinstanceof, typename
14
- from pygeodesy.constants import EPS, EPS0, INT0, PI2, _isfinite, isnear0, \
15
- _0_0, _1_0, _N_1_0, _2_0, _4_0, _6_0
14
+ from pygeodesy.constants import EPS, EPS0, INT0, NAN, PI2, _isfinite, \
15
+ _0_0, _1_0, _N_1_0, _2_0, _4_0, _6_0, isnear0
16
16
  from pygeodesy.datums import Datum, _earth_ellipsoid, _spherical_datum, \
17
17
  Transform, _WGS84
18
18
  # from pygeodesy.ecef import EcefKarney # _MODS
@@ -34,7 +34,7 @@ from pygeodesy.props import deprecated_method, Property, Property_RO, \
34
34
  property_doc_, property_RO, _update_all
35
35
  # from pygeodesy import resections as _resections # _MODS.into
36
36
  # from pygeodesy.streprs import Fmt # from .fsums
37
- # from pygeodesy.triaxials import Triaxial_ # _MODS
37
+ # from pygeodesy.triaxials.triaxial5 import Triaxial_ # _MODS
38
38
  from pygeodesy.units import Degrees, Height, _heigHt, _isMeter, Meter, Radians
39
39
  from pygeodesy.utily import acos1, atan2, sincos2d, sincos2_, degrees, radians
40
40
  from pygeodesy.vector3d import Vector3d, _xyzhdlln4
@@ -43,7 +43,7 @@ from pygeodesy.vector3d import Vector3d, _xyzhdlln4
43
43
  # from math import degrees, fabs, radians, sqrt # from .fmath, .utily
44
44
 
45
45
  __all__ = _ALL_LAZY.cartesianBase
46
- __version__ = '25.08.24'
46
+ __version__ = '25.11.07'
47
47
 
48
48
  _r_ = 'r'
49
49
  _resections = _MODS.into(resections=__name__)
@@ -326,7 +326,7 @@ class CartesianBase(Vector3d, _EcefLocal):
326
326
  try:
327
327
  r = self.datum.ellipsoid.height4(self, normal=True)
328
328
  except (AttributeError, ValueError): # no datum, null cartesian,
329
- r = Vector4Tuple(self.x, self.y, self.z, 0, name__=self.height4)
329
+ r = Vector4Tuple(self.x, self.y, self.z, NAN, name__=self.height4)
330
330
  return r
331
331
 
332
332
  def height4(self, earth=None, normal=True, **Cartesian_and_kwds):
@@ -361,7 +361,7 @@ class CartesianBase(Vector3d, _EcefLocal):
361
361
  d = self.datum if earth is None else earth
362
362
  if normal and d is self.datum:
363
363
  r = self._height4
364
- elif isinstance(d, _MODS.triaxials.Triaxial_):
364
+ elif isinstance(d, _MODS.triaxials.triaxial5.Triaxial_):
365
365
  r = d.height4(self, normal=normal)
366
366
  try:
367
367
  d = d.toEllipsoid(name=n)
@@ -994,7 +994,7 @@ __all__ += _ALL_DOCS(CartesianBase)
994
994
 
995
995
  # **) MIT License
996
996
  #
997
- # Copyright (C) 2016-2025 -- mrJean1 at Gmail -- All Rights Reserved.
997
+ # Copyright (C) 2016-2026 -- mrJean1 at Gmail -- All Rights Reserved.
998
998
  #
999
999
  # Permission is hereby granted, free of charge, to any person obtaining a
1000
1000
  # copy of this software and associated documentation files (the "Software"),
pygeodesy/clipy.py CHANGED
@@ -31,7 +31,7 @@ from pygeodesy.units import Bool, FIx, HeightX, Lat, Lon, Number_
31
31
  # from math import fabs # from .fmath
32
32
 
33
33
  __all__ = _ALL_LAZY.clipy
34
- __version__ = '25.05.12'
34
+ __version__ = '25.10.30'
35
35
 
36
36
  _fj_ = 'fj'
37
37
  _original_ = 'original'
@@ -237,9 +237,8 @@ def clipCS4(points, lowerleft, upperight, closed=False, inull=False):
237
237
 
238
238
 
239
239
  class ClipFHP4Tuple(_NamedTuple):
240
- '''4-Tuple C{(lat, lon, height, clipid)} for each point of the
241
- L{clipFHP4} result with the C{lat}-, C{lon}gitude, C{height}
242
- and C{clipid} of the polygon or clip.
240
+ '''4-Tuple C{(lat, lon, height, clipid)} for each point of the L{clipFHP4} result
241
+ with the C{lat}-, C{lon}gitude, C{height} and C{clipid} of the polygon or clip.
243
242
 
244
243
  @note: The C{height} is a L{HeightX} instance if this point is
245
244
  an intersection, otherwise a L{Height} or C{int(0)}.
@@ -275,14 +274,13 @@ def clipFHP4(points, corners, closed=False, inull=False, raiser=False, eps=EPS):
275
274
  as the B{C{points}} and B{C{corners}} coordinates).
276
275
 
277
276
  @return: Yield a L{ClipFHP4Tuple}C{(lat, lon, height, clipid)} for each
278
- clipped point. The result may consist of several clips, each
279
- a (closed) polygon with a unique C{clipid}.
277
+ clipped point. The result may consist of several I{clips}, each
278
+ a (closed) polygon with a unique C{clipid} identifier.
280
279
 
281
280
  @raise ClipError: Insufficient B{C{points}} or B{C{corners}} or an open clip.
282
281
 
283
282
  @see: U{Forster, Hormann and Popa<https://www.ScienceDirect.com/science/
284
- article/pii/S259014861930007X>}, class L{BooleanFHP} and function
285
- L{clipGH4}.
283
+ article/pii/S259014861930007X>} and class L{BooleanFHP}.
286
284
  '''
287
285
  P = _MODS.booleans._CompositeFHP(points, kind=_points_, raiser=raiser,
288
286
  eps=eps, name__=clipFHP4)
@@ -292,12 +290,11 @@ def clipFHP4(points, corners, closed=False, inull=False, raiser=False, eps=EPS):
292
290
 
293
291
 
294
292
  class ClipGH4Tuple(ClipFHP4Tuple):
295
- '''4-Tuple C{(lat, lon, height, clipid)} for each point of the
296
- L{clipGH4} result with the C{lat}-, C{lon}gitude, C{height}
297
- and C{clipid} of the polygon or clip.
293
+ '''4-Tuple C{(lat, lon, height, clipid)} for each point of the L{clipGH4} result
294
+ with the C{lat}-, C{lon}gitude, C{height} and C{clipid} of the polygon or clip.
298
295
 
299
- @note: The C{height} is a L{HeightX} instance if this is
300
- an intersection, otherwise a L{Height} or C{int(0)}.
296
+ @note: The C{height} is a L{HeightX} instance if this is an intersection,
297
+ otherwise a L{Height} or C{int(0)}.
301
298
  '''
302
299
  _Names_ = ClipFHP4Tuple._Names_
303
300
  _Units_ = ClipFHP4Tuple._Units_
@@ -305,8 +302,7 @@ class ClipGH4Tuple(ClipFHP4Tuple):
305
302
 
306
303
  def clipGH4(points, corners, closed=False, inull=False, raiser=True, xtend=False, eps=EPS):
307
304
  '''Clip one or more polygons against a clip region or box using the U{Greiner-Hormann
308
- <http://www.Inf.USI.CH/hormann/papers/Greiner.1998.ECO.pdf>} algorithm, U{Correia
309
- <https://GitHub.com/helderco/univ-polyclip>}'s implementation modified and extended.
305
+ <http://www.Inf.USI.CH/hormann/papers/Greiner.1998.ECO.pdf>} algorithm, extended.
310
306
 
311
307
  @arg points: The polygon points and clips (C{LatLon}[]).
312
308
  @arg corners: Three or more points defining the clip regions (C{LatLon}[])
@@ -320,19 +316,17 @@ def clipGH4(points, corners, closed=False, inull=False, raiser=True, xtend=False
320
316
  as the B{C{points}} and B{C{corners}} coordinates).
321
317
 
322
318
  @return: Yield a L{ClipGH4Tuple}C{(lat, lon, height, clipid)} for each
323
- clipped point. The result may consist of several clips, each
324
- a (closed) polygon with a unique C{clipid}.
319
+ clipped point. The result may consist of several I{clips}, each
320
+ a (closed) polygon with a unique C{clipid} identifier.
325
321
 
326
322
  @raise ClipError: Insufficient B{C{points}} or B{C{corners}}, an open clip,
327
323
  a I{degenerate case} or I{unhandled} intersection.
328
324
 
329
325
  @note: To handle I{degenerate cases} like C{point-edge} and C{point-point}
330
- intersections, use function L{clipFHP4}.
326
+ intersections I{properly}, use function L{clipFHP4}.
331
327
 
332
- @see: U{Greiner-Hormann<https://WikiPedia.org/wiki/Greiner–Hormann_clipping_algorithm>},
333
- U{Ionel Daniel Stroe<https://Davis.WPI.edu/~matt/courses/clipping/>}, I{Correia}'s
334
- U{univ-polyclip<https://GitHub.com/helderco/univ-polyclip>}, class L{BooleanGH}
335
- and function L{clipFHP4}.
328
+ @see: U{Greiner-Hormann<https://WikiPedia.org/wiki/Greiner–Hormann_clipping_algorithm>}
329
+ and class L{BooleanGH}.
336
330
  '''
337
331
  S = _MODS.booleans._CompositeGH(points, raiser=raiser, xtend=xtend, eps=eps,
338
332
  name__=clipGH4, kind=_points_)
@@ -684,7 +678,7 @@ def clipSH3(points, corners, closed=False, inull=False):
684
678
 
685
679
  # **) MIT License
686
680
  #
687
- # Copyright (C) 2018-2025 -- mrJean1 at Gmail -- All Rights Reserved.
681
+ # Copyright (C) 2018-2026 -- mrJean1 at Gmail -- All Rights Reserved.
688
682
  #
689
683
  # Permission is hereby granted, free of charge, to any person obtaining a
690
684
  # copy of this software and associated documentation files (the "Software"),