pygeodesy 24.5.15__py2.py3-none-any.whl → 24.6.1__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.5.15.dist-info → PyGeodesy-24.6.1.dist-info}/METADATA +6 -5
- PyGeodesy-24.6.1.dist-info/RECORD +116 -0
- pygeodesy/__init__.py +4 -4
- pygeodesy/albers.py +41 -41
- pygeodesy/auxilats/__init__.py +1 -1
- pygeodesy/auxilats/__main__.py +2 -2
- pygeodesy/auxilats/auxAngle.py +32 -31
- pygeodesy/auxilats/auxLat.py +80 -51
- pygeodesy/azimuthal.py +123 -124
- pygeodesy/basics.py +46 -10
- pygeodesy/booleans.py +13 -14
- pygeodesy/cartesianBase.py +25 -23
- pygeodesy/clipy.py +3 -3
- pygeodesy/constants.py +3 -3
- pygeodesy/css.py +50 -42
- pygeodesy/datums.py +42 -41
- pygeodesy/deprecated/functions.py +9 -3
- pygeodesy/dms.py +6 -6
- pygeodesy/ecef.py +41 -41
- pygeodesy/ellipsoidalBase.py +41 -41
- pygeodesy/ellipsoidalBaseDI.py +3 -4
- pygeodesy/ellipsoidalGeodSolve.py +2 -2
- pygeodesy/ellipsoidalKarney.py +3 -3
- pygeodesy/ellipsoidalNvector.py +11 -12
- pygeodesy/ellipsoids.py +45 -38
- pygeodesy/elliptic.py +3 -4
- pygeodesy/epsg.py +4 -3
- pygeodesy/errors.py +52 -20
- pygeodesy/etm.py +68 -65
- pygeodesy/fmath.py +44 -49
- pygeodesy/formy.py +129 -115
- pygeodesy/frechet.py +118 -103
- pygeodesy/fstats.py +21 -14
- pygeodesy/fsums.py +124 -80
- pygeodesy/gars.py +10 -9
- pygeodesy/geodesicw.py +19 -17
- pygeodesy/geodesicx/__init__.py +1 -1
- pygeodesy/geodesicx/__main__.py +2 -2
- pygeodesy/geodesicx/gx.py +39 -33
- pygeodesy/geodesicx/gxarea.py +12 -9
- pygeodesy/geodesicx/gxbases.py +3 -4
- pygeodesy/geodesicx/gxline.py +6 -8
- pygeodesy/geodsolve.py +29 -28
- pygeodesy/geohash.py +60 -57
- pygeodesy/geoids.py +34 -32
- pygeodesy/hausdorff.py +114 -101
- pygeodesy/heights.py +137 -130
- pygeodesy/internals.py +16 -11
- pygeodesy/interns.py +3 -6
- pygeodesy/iters.py +19 -17
- pygeodesy/karney.py +21 -17
- pygeodesy/ktm.py +25 -18
- pygeodesy/latlonBase.py +12 -11
- pygeodesy/lazily.py +6 -6
- pygeodesy/lcc.py +24 -25
- pygeodesy/ltp.py +143 -113
- pygeodesy/ltpTuples.py +207 -150
- pygeodesy/mgrs.py +26 -26
- pygeodesy/named.py +172 -90
- pygeodesy/namedTuples.py +33 -25
- pygeodesy/nvectorBase.py +8 -8
- pygeodesy/osgr.py +40 -48
- pygeodesy/points.py +18 -18
- pygeodesy/props.py +29 -16
- pygeodesy/rhumb/__init__.py +1 -1
- pygeodesy/rhumb/aux_.py +13 -15
- pygeodesy/rhumb/bases.py +12 -5
- pygeodesy/rhumb/ekx.py +24 -18
- pygeodesy/rhumb/solve.py +13 -10
- pygeodesy/simplify.py +16 -16
- pygeodesy/solveBase.py +18 -18
- pygeodesy/sphericalBase.py +17 -21
- pygeodesy/sphericalTrigonometry.py +21 -21
- pygeodesy/streprs.py +5 -5
- pygeodesy/trf.py +13 -11
- pygeodesy/triaxials.py +68 -64
- pygeodesy/units.py +35 -35
- pygeodesy/unitsBase.py +24 -11
- pygeodesy/ups.py +66 -70
- pygeodesy/utily.py +3 -3
- pygeodesy/utm.py +183 -187
- pygeodesy/utmups.py +38 -38
- pygeodesy/utmupsBase.py +104 -106
- pygeodesy/vector2d.py +6 -7
- pygeodesy/vector3d.py +16 -17
- pygeodesy/vector3dBase.py +4 -5
- pygeodesy/webmercator.py +43 -51
- PyGeodesy-24.5.15.dist-info/RECORD +0 -116
- {PyGeodesy-24.5.15.dist-info → PyGeodesy-24.6.1.dist-info}/WHEEL +0 -0
- {PyGeodesy-24.5.15.dist-info → PyGeodesy-24.6.1.dist-info}/top_level.txt +0 -0
pygeodesy/rhumb/aux_.py
CHANGED
|
@@ -32,22 +32,22 @@ from pygeodesy.auxilats.auxAngle import AuxMu, AuxPhi, hypot
|
|
|
32
32
|
from pygeodesy.auxilats.auxDLat import AuxDLat, _DClenshaw
|
|
33
33
|
# from pygeodesy.auxilats.auxDST import AuxDST # _MODS
|
|
34
34
|
from pygeodesy.auxilats.auxily import _Dlam, _Dp0Dpsi, _Ufloats
|
|
35
|
-
from pygeodesy.basics import copysign0, _reverange,
|
|
35
|
+
from pygeodesy.basics import copysign0, _reverange, _xkwds_get1
|
|
36
36
|
from pygeodesy.constants import EPS_2, MANT_DIG, PI4, isinf, \
|
|
37
37
|
_0_0, _4_0, _720_0, _log2, _over
|
|
38
|
-
from pygeodesy.datums import _WGS84
|
|
39
|
-
# from pygeodesy.errors import
|
|
38
|
+
# from pygeodesy.datums import _WGS84 # from .rhumb.bases
|
|
39
|
+
# from pygeodesy.errors import _xkwds_get1 # from .basics
|
|
40
40
|
from pygeodesy.karney import Caps, _polynomial
|
|
41
41
|
# from pygeodesy.fmath import hypot # from .auxilats.auxAngle
|
|
42
|
-
# from pygeodesy.interns import NN # from .datums
|
|
43
42
|
from pygeodesy.lazily import _ALL_DOCS, _ALL_LAZY, _ALL_MODS as _MODS
|
|
44
|
-
# from pygeodesy.props import Property_RO # from .
|
|
45
|
-
from pygeodesy.rhumb.bases import RhumbBase, RhumbLineBase,
|
|
43
|
+
# from pygeodesy.props import Property_RO # from .rhumb.bases
|
|
44
|
+
from pygeodesy.rhumb.bases import RhumbBase, RhumbLineBase, \
|
|
45
|
+
Property_RO, _WGS84
|
|
46
46
|
|
|
47
47
|
from math import ceil as _ceil, fabs, radians
|
|
48
48
|
|
|
49
49
|
__all__ = _ALL_LAZY.rhumb_aux_
|
|
50
|
-
__version__ = '
|
|
50
|
+
__version__ = '24.05.29'
|
|
51
51
|
|
|
52
52
|
# DIGITS = (sizeof(real) * 8) bits
|
|
53
53
|
# = (ctypes.sizeof(ctypes.c_double(1.0)) * 8) bits
|
|
@@ -68,7 +68,7 @@ class RhumbAux(RhumbBase):
|
|
|
68
68
|
installed, version 1.16 or later.
|
|
69
69
|
'''
|
|
70
70
|
|
|
71
|
-
def __init__(self, a_earth=_WGS84, f=None, exact=True,
|
|
71
|
+
def __init__(self, a_earth=_WGS84, f=None, exact=True, **TMorder_name): # PYCHOK signature
|
|
72
72
|
'''New C{RhumbAux}.
|
|
73
73
|
|
|
74
74
|
@kwarg a_earth: This rhumb's earth model (L{Datum}, L{Ellipsoid},
|
|
@@ -79,18 +79,16 @@ class RhumbAux(RhumbBase):
|
|
|
79
79
|
@kwarg exact: If C{True}, use the exact expressions for the I{Auxiliary
|
|
80
80
|
Latitudes}, otherwise use the I{Fourier} series expansion
|
|
81
81
|
(C{bool}), see also property C{exact}.
|
|
82
|
-
@kwarg
|
|
83
|
-
|
|
84
|
-
|
|
82
|
+
@kwarg TMorder_name: Optional C{B{name}=NN} (C{str}) and optional
|
|
83
|
+
keyword argument C{B{TMorder}=6} for the order of
|
|
84
|
+
the L{KTransverseMercator}, see property C{TMorder}.
|
|
85
85
|
|
|
86
86
|
@raise ImportError: Package C{numpy} not found or not installed, only
|
|
87
87
|
required for area C{S12} when C{B{exact} is True}.
|
|
88
88
|
|
|
89
89
|
@raise RhumbError: Invalid B{C{a_earth}}, B{C{f}} or B{C{TMorder}}.
|
|
90
90
|
'''
|
|
91
|
-
RhumbBase.__init__(self, a_earth, f, exact,
|
|
92
|
-
if TMorder:
|
|
93
|
-
self.Tmorder = _xkwds_get(TMorder, TMorder=RhumbBase._mTM)
|
|
91
|
+
RhumbBase.__init__(self, a_earth, f, exact, TMorder_name)
|
|
94
92
|
|
|
95
93
|
def areaux(self, **exact):
|
|
96
94
|
'''Get this ellipsoid's B{C{exact}} surface area (C{meter} I{squared}).
|
|
@@ -110,7 +108,7 @@ class RhumbAux(RhumbBase):
|
|
|
110
108
|
@see: U{The area of rhumb polygons<https://ArXiv.org/pdf/2303.03219.pdf>}
|
|
111
109
|
and method L{auxilats.AuxLat.AuthalicRadius2}.
|
|
112
110
|
'''
|
|
113
|
-
x =
|
|
111
|
+
x = _xkwds_get1(exact, exact=self.exact)
|
|
114
112
|
a = (self._c2 * _720_0) if bool(x) is self.exact else (
|
|
115
113
|
self._auxD.AuthalicRadius2(exact=x, f_max=self.f_max) * PI4)
|
|
116
114
|
return a
|
pygeodesy/rhumb/bases.py
CHANGED
|
@@ -52,7 +52,7 @@ from pygeodesy.vector3d import _intersect3d3, Vector3d # in .Intersection below
|
|
|
52
52
|
from math import cos, fabs
|
|
53
53
|
|
|
54
54
|
__all__ = ()
|
|
55
|
-
__version__ = '24.05.
|
|
55
|
+
__version__ = '24.05.29'
|
|
56
56
|
|
|
57
57
|
_anti_ = _Dash('anti')
|
|
58
58
|
_rls = [] # instances of C{RbumbLine...} to be updated
|
|
@@ -95,10 +95,17 @@ class RhumbBase(_CapsBase):
|
|
|
95
95
|
_f_max = _0_01
|
|
96
96
|
_mTM = 6 # see .TMorder
|
|
97
97
|
|
|
98
|
-
def __init__(self, a_earth, f, exact,
|
|
98
|
+
def __init__(self, a_earth, f, exact, TMorder_name):
|
|
99
99
|
'''New C{RhumbAux} or C{Rhumb}.
|
|
100
100
|
'''
|
|
101
|
-
|
|
101
|
+
if TMorder_name:
|
|
102
|
+
M = self._mTM
|
|
103
|
+
m, name = _xkwds_pop2(TMorder_name, TMorder=M)
|
|
104
|
+
if m != M:
|
|
105
|
+
self.TMorder = m
|
|
106
|
+
else:
|
|
107
|
+
name = {}
|
|
108
|
+
_earth_datum(self, a_earth, f=f, **name)
|
|
102
109
|
if not exact:
|
|
103
110
|
self.exact = False
|
|
104
111
|
if name:
|
|
@@ -425,13 +432,13 @@ class RhumbBase(_CapsBase):
|
|
|
425
432
|
|
|
426
433
|
@Property
|
|
427
434
|
def TMorder(self):
|
|
428
|
-
'''Get the
|
|
435
|
+
'''Get the L{KTransverseMercator} order (C{int}, 4, 5, 6, 7 or 8).
|
|
429
436
|
'''
|
|
430
437
|
return self._mTM
|
|
431
438
|
|
|
432
439
|
@TMorder.setter # PYCHOK setter!
|
|
433
440
|
def TMorder(self, order):
|
|
434
|
-
'''Set the
|
|
441
|
+
'''Set the L{KTransverseMercator} order (C{int}, 4, 5, 6, 7 or 8).
|
|
435
442
|
|
|
436
443
|
@note: Setting C{TMorder} turns property C{exact} off, but only
|
|
437
444
|
for L{Rhumb} instances.
|
pygeodesy/rhumb/ekx.py
CHANGED
|
@@ -25,24 +25,25 @@ from __future__ import division as _; del _ # PYCHOK semicolon
|
|
|
25
25
|
from pygeodesy.basics import copysign0, neg
|
|
26
26
|
from pygeodesy.constants import PI_2, _0_0s, _0_0, _0_5, _1_0, \
|
|
27
27
|
_2_0, _4_0, _720_0, _over, _1_over
|
|
28
|
-
from pygeodesy.datums import _WGS84
|
|
28
|
+
# from pygeodesy.datums import _WGS84 # from .rhumb.bases
|
|
29
29
|
# from pygeodesy.deprecated import RhumbOrder2Tuple # _MODS
|
|
30
|
-
from pygeodesy.errors import RhumbError, _Xorder
|
|
30
|
+
from pygeodesy.errors import RhumbError, _xkwds_pop2, _Xorder
|
|
31
31
|
from pygeodesy.fmath import hypot, hypot1
|
|
32
32
|
# from pygeodesy.fsums import fsum1f_ # _MODS
|
|
33
|
-
# from pygeodesy.
|
|
34
|
-
from pygeodesy.karney import Caps, NN
|
|
33
|
+
# from pygeodesy.karney import Caps # from .rhumb.bases
|
|
35
34
|
from pygeodesy.ktm import KTransverseMercator, _Xs, \
|
|
36
35
|
_AlpCoeffs, _BetCoeffs # PYCHOK used!
|
|
37
36
|
from pygeodesy.lazily import _ALL_DOCS, _ALL_LAZY, _ALL_MODS as _MODS
|
|
38
|
-
from pygeodesy.props import deprecated_method, Property, Property_RO,
|
|
39
|
-
|
|
37
|
+
from pygeodesy.props import deprecated_method, Property, Property_RO, \
|
|
38
|
+
property_RO
|
|
39
|
+
from pygeodesy.rhumb.bases import RhumbBase, RhumbLineBase, \
|
|
40
|
+
Caps, _update_all_rls, _WGS84
|
|
40
41
|
from pygeodesy.utily import atan1, sincos2_
|
|
41
42
|
|
|
42
43
|
from math import asinh, atan, cos, cosh, radians, sin, sinh, sqrt, tan
|
|
43
44
|
|
|
44
45
|
__all__ = _ALL_LAZY.rhumb_ekx
|
|
45
|
-
__version__ = '
|
|
46
|
+
__version__ = '24.05.30'
|
|
46
47
|
|
|
47
48
|
|
|
48
49
|
class Rhumb(RhumbBase):
|
|
@@ -54,7 +55,7 @@ class Rhumb(RhumbBase):
|
|
|
54
55
|
'''
|
|
55
56
|
_mRA = 6 # see .RAorder
|
|
56
57
|
|
|
57
|
-
def __init__(self, a_earth=_WGS84, f=None, exact=True,
|
|
58
|
+
def __init__(self, a_earth=_WGS84, f=None, exact=True, **RA_TMorder_name):
|
|
58
59
|
'''New C{Rhumb}.
|
|
59
60
|
|
|
60
61
|
@kwarg a_earth: This rhumb's earth model (L{Datum}, L{Ellipsoid},
|
|
@@ -67,15 +68,20 @@ class Rhumb(RhumbBase):
|
|
|
67
68
|
series expansion (C{bool} or C{None}), see also properties
|
|
68
69
|
C{exact} and C{TMorder}.
|
|
69
70
|
@kwarg name: Optional name (C{str}).
|
|
70
|
-
@kwarg
|
|
71
|
-
|
|
72
|
-
|
|
71
|
+
@kwarg RA_TMorder_name: Optional C{B{name}=NN} (C{str}) and optional keyword
|
|
72
|
+
arguments B{C{RAorder}=6} and B{C{TMorder}=6} to set the respective
|
|
73
|
+
C{order}, see properties C{RAorder} and C{TMorder}.
|
|
73
74
|
|
|
74
|
-
@raise RhumbError: Invalid B{C{a_earth}}, B{C{f}} or B{C{
|
|
75
|
+
@raise RhumbError: Invalid B{C{a_earth}}, B{C{f}}, B{C{RAorder}} or B{C{TMorder}}.
|
|
75
76
|
'''
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
77
|
+
if RA_TMorder_name:
|
|
78
|
+
M = self._mRA
|
|
79
|
+
m, kwds = _xkwds_pop2(RA_TMorder_name, RAorder=M)
|
|
80
|
+
if m != M:
|
|
81
|
+
self.RAorder = m
|
|
82
|
+
else:
|
|
83
|
+
kwds = {}
|
|
84
|
+
RhumbBase.__init__(self, a_earth, f, exact, kwds)
|
|
79
85
|
|
|
80
86
|
@Property_RO
|
|
81
87
|
def _A2(self): # Conformal2RectifyingCoeffs
|
|
@@ -184,7 +190,7 @@ class Rhumb(RhumbBase):
|
|
|
184
190
|
return self.ellipsoid._Lpr # degrees(._Lpd)
|
|
185
191
|
|
|
186
192
|
@deprecated_method
|
|
187
|
-
def orders(self, RAorder=
|
|
193
|
+
def orders(self, RAorder=6, TMorder=6): # PYCHOK no cover
|
|
188
194
|
'''DEPRECATED, use properties C{RAorder} and/or C{TMorder}.
|
|
189
195
|
|
|
190
196
|
Get and set the I{RAorder} and/or I{TMorder}.
|
|
@@ -198,9 +204,9 @@ class Rhumb(RhumbBase):
|
|
|
198
204
|
with the previous C{RAorder} and C{TMorder} setting.
|
|
199
205
|
'''
|
|
200
206
|
t = _MODS.deprecated.classes.RhumbOrder2Tuple(self.RAorder, self.TMorder)
|
|
201
|
-
if RAorder
|
|
207
|
+
if RAorder != t.RAorder: # PYCHOK attr
|
|
202
208
|
self.RAorder = RAorder
|
|
203
|
-
if TMorder
|
|
209
|
+
if TMorder != t.TMorder: # PYCHOK attr
|
|
204
210
|
self.TMorder = TMorder
|
|
205
211
|
return t
|
|
206
212
|
|
pygeodesy/rhumb/solve.py
CHANGED
|
@@ -21,7 +21,7 @@ from pygeodesy.solveBase import _SolveBase, _SolveLineBase
|
|
|
21
21
|
from pygeodesy.utily import _unrollon, _Wrap, wrap360
|
|
22
22
|
|
|
23
23
|
__all__ = _ALL_LAZY.rhumb_solve
|
|
24
|
-
__version__ = '24.
|
|
24
|
+
__version__ = '24.05.31'
|
|
25
25
|
|
|
26
26
|
|
|
27
27
|
class _RhumbSolveBase(_SolveBase):
|
|
@@ -90,13 +90,13 @@ class RhumbSolve(_RhumbSolveBase):
|
|
|
90
90
|
@note: This C{rhumb} is intended I{for testing purposes only}, it invokes the C{RhumbSolve}
|
|
91
91
|
executable for I{every} method call.
|
|
92
92
|
'''
|
|
93
|
-
# def Area(self, polyline=False, name
|
|
93
|
+
# def Area(self, polyline=False, **name):
|
|
94
94
|
# '''Set up a L{RhumbArea} to compute area and
|
|
95
95
|
# perimeter of a polygon.
|
|
96
96
|
#
|
|
97
97
|
# @kwarg polyline: If C{True} perimeter only, otherwise
|
|
98
98
|
# area and perimeter (C{bool}).
|
|
99
|
-
# @kwarg name: Optional name (C{str}).
|
|
99
|
+
# @kwarg name: Optional C{B{name}=NN} (C{str}).
|
|
100
100
|
#
|
|
101
101
|
# @return: A L{RhumbArea} instance.
|
|
102
102
|
#
|
|
@@ -104,7 +104,7 @@ class RhumbSolve(_RhumbSolveBase):
|
|
|
104
104
|
# to the returned L{RhumbAreaExact} instance.
|
|
105
105
|
# '''
|
|
106
106
|
# rA = _MODS.rhumbs.rhumb*.RhumbArea(self, polyline=polyline,
|
|
107
|
-
#
|
|
107
|
+
# name=self._name__(name))
|
|
108
108
|
# if self.verbose or self.debug: # PYCHOK no cover
|
|
109
109
|
# rA.verbose = True
|
|
110
110
|
# return rA
|
|
@@ -140,7 +140,7 @@ class RhumbSolve(_RhumbSolveBase):
|
|
|
140
140
|
'''
|
|
141
141
|
return self.DirectLine(ll1.lat, ll1.lon, azi12, **name_caps)
|
|
142
142
|
|
|
143
|
-
def DirectLine(self, lat1, lon1, azi1, caps=Caps.STANDARD, name
|
|
143
|
+
def DirectLine(self, lat1, lon1, azi1, caps=Caps.STANDARD, **name):
|
|
144
144
|
'''Set up a L{RhumbLineSolve} in terms of the I{direct} rhumb
|
|
145
145
|
problem to compute several points on a single rhumb line.
|
|
146
146
|
|
|
@@ -150,6 +150,7 @@ class RhumbSolve(_RhumbSolveBase):
|
|
|
150
150
|
@kwarg caps: Bit-or'ed combination of L{Caps} values specifying
|
|
151
151
|
the capabilities the L{RhumbLineSolve} instance
|
|
152
152
|
should possess, always C{Caps.ALL}.
|
|
153
|
+
@kwarg name: Optional C{B{name}=NN} (C{str}).
|
|
153
154
|
|
|
154
155
|
@return: A L{RhumbLineSolve} instance.
|
|
155
156
|
|
|
@@ -161,7 +162,7 @@ class RhumbSolve(_RhumbSolveBase):
|
|
|
161
162
|
<https://GeographicLib.SourceForge.io/C++/doc/classGeographicLib_1_1RhumbExact.html>}
|
|
162
163
|
and Python U{Rhumb.Line<https://GeographicLib.SourceForge.io/Python/doc/code.html>}.
|
|
163
164
|
'''
|
|
164
|
-
return RhumbLineSolve(self, lat1, lon1, azi1, caps=caps, name=
|
|
165
|
+
return RhumbLineSolve(self, lat1, lon1, azi1, caps=caps, name=self._name__(name))
|
|
165
166
|
|
|
166
167
|
def _GDictDirect(self, lat, lon, azi1, arcmode, s12_a12, *unused, **floats): # PYCHOK signature
|
|
167
168
|
'''(INTERNAL) Get C{_GenDirect}-like result as an 8-item C{GDict}.
|
|
@@ -206,7 +207,7 @@ class RhumbSolve(_RhumbSolveBase):
|
|
|
206
207
|
ll2 = _unrollon(ll1, _Wrap.point(ll2))
|
|
207
208
|
return self.InverseLine(ll1.lat, ll1.lon, ll2.lat, ll2.lon, **name_caps)
|
|
208
209
|
|
|
209
|
-
def InverseLine(self, lat1, lon1, lat2, lon2, caps=Caps.STANDARD, name
|
|
210
|
+
def InverseLine(self, lat1, lon1, lat2, lon2, caps=Caps.STANDARD, **name):
|
|
210
211
|
'''Define a L{RhumbLineSolve} in terms of the I{inverse}
|
|
211
212
|
rhumb problem.
|
|
212
213
|
|
|
@@ -215,6 +216,7 @@ class RhumbSolve(_RhumbSolveBase):
|
|
|
215
216
|
@arg lat2: Latitude of the second point (C{degrees90}).
|
|
216
217
|
@arg lon2: Longitude of the second point (C{degrees180}).
|
|
217
218
|
@kwarg caps: Optional C{caps}, see L{RhumbLine} C{B{caps}}.
|
|
219
|
+
@kwarg name: Optional C{B{name}=NN} (C{str}).
|
|
218
220
|
|
|
219
221
|
@return: A L{RhumbLineSolve} instance and invoke its method
|
|
220
222
|
L{RhumbLine.Position} to compute each point.
|
|
@@ -224,7 +226,7 @@ class RhumbSolve(_RhumbSolveBase):
|
|
|
224
226
|
'''
|
|
225
227
|
r = self.Inverse(lat1, lon1, lat2, lon2) # outmask=Caps.AZIMUTH
|
|
226
228
|
return RhumbLineSolve(self, lat1, lon1, r.azi12, caps=caps,
|
|
227
|
-
|
|
229
|
+
name=self._name__(name))
|
|
228
230
|
|
|
229
231
|
Line = DirectLine
|
|
230
232
|
|
|
@@ -239,7 +241,7 @@ class RhumbLineSolve(_RhumbSolveBase, _SolveLineBase):
|
|
|
239
241
|
@note: This C{rhumb line} is intended I{for testing purposes only}, it invokes the C{RhumbSolve}
|
|
240
242
|
executable for I{every} method call.
|
|
241
243
|
'''
|
|
242
|
-
def __init__(self, rhumb, lat1, lon1, azi12, caps=Caps.STANDARD, name
|
|
244
|
+
def __init__(self, rhumb, lat1, lon1, azi12, caps=Caps.STANDARD, **name):
|
|
243
245
|
'''New L{RhumbLineSolve} instance, allowing points to be found along
|
|
244
246
|
a rhumb starting at C{(B{lat1}, B{lon1})} with azimuth B{C{azi12}}.
|
|
245
247
|
|
|
@@ -252,6 +254,7 @@ class RhumbLineSolve(_RhumbSolveBase, _SolveLineBase):
|
|
|
252
254
|
possess, always C{Caps.ALL}. Use C{Caps.LINE_OFF}
|
|
253
255
|
if updates to the B{C{rhumb}} should I{not} be
|
|
254
256
|
reflected in this L{RhumbLineSolve} instance.
|
|
257
|
+
@kwarg name: Optional C{B{name}=NN} (C{str}).
|
|
255
258
|
|
|
256
259
|
@kwarg name: Optional name (C{str}).
|
|
257
260
|
|
|
@@ -264,7 +267,7 @@ class RhumbLineSolve(_RhumbSolveBase, _SolveLineBase):
|
|
|
264
267
|
_xinstanceof(RhumbSolve, rhumb=rhumb)
|
|
265
268
|
if (caps & Caps.LINE_OFF): # copy to avoid updates
|
|
266
269
|
rhumb = rhumb.copy(deep=False, name=NN(_UNDER_, rhumb.name))
|
|
267
|
-
_SolveLineBase.__init__(self, rhumb, lat1, lon1, caps,
|
|
270
|
+
_SolveLineBase.__init__(self, rhumb, lat1, lon1, caps, azi12=azi12, **name)
|
|
268
271
|
try:
|
|
269
272
|
self.RhumbSolve = rhumb.RhumbSolve # rhumb or copy of rhumb
|
|
270
273
|
except RhumbError:
|
pygeodesy/simplify.py
CHANGED
|
@@ -43,7 +43,7 @@ list of simplified point I{indices} instead of the simplified points.
|
|
|
43
43
|
The first and last index are always the first and last original index.
|
|
44
44
|
|
|
45
45
|
Finally, any additional keyword arguments B{C{options}} to all functions
|
|
46
|
-
are passed thru to function L{pygeodesy.
|
|
46
|
+
are passed thru to function L{pygeodesy.equirectangular4} to specify the
|
|
47
47
|
distance approximation.
|
|
48
48
|
|
|
49
49
|
To process C{NumPy} arrays containing rows of lat-, longitude and
|
|
@@ -77,7 +77,7 @@ from __future__ import division as _; del _ # PYCHOK semicolon
|
|
|
77
77
|
from pygeodesy.constants import EPS, R_M, _1_0
|
|
78
78
|
from pygeodesy.errors import _AttributeError, _ValueError
|
|
79
79
|
from pygeodesy.fmath import len2, sqrt0
|
|
80
|
-
from pygeodesy.formy import
|
|
80
|
+
from pygeodesy.formy import equirectangular4
|
|
81
81
|
from pygeodesy.interns import _small_, _too_
|
|
82
82
|
from pygeodesy.iters import isNumpy2, isTuple2
|
|
83
83
|
# from pygeodesy.lazily import _ALL_LAZY # from .units
|
|
@@ -86,7 +86,7 @@ from pygeodesy.units import _ALL_LAZY, _1mm, Radius_
|
|
|
86
86
|
from math import degrees, fabs, radians
|
|
87
87
|
|
|
88
88
|
__all__ = _ALL_LAZY.simplify
|
|
89
|
-
__version__ = '
|
|
89
|
+
__version__ = '24.05.25'
|
|
90
90
|
|
|
91
91
|
|
|
92
92
|
# try:
|
|
@@ -240,7 +240,7 @@ class _Sy(object):
|
|
|
240
240
|
and the (longitudinal) unrollment.
|
|
241
241
|
'''
|
|
242
242
|
p1, p2= self.pts[i], self.pts[j]
|
|
243
|
-
return
|
|
243
|
+
return equirectangular4(p1.lat, p1.lon,
|
|
244
244
|
p2.lat, p2.lon, **self.options)
|
|
245
245
|
|
|
246
246
|
def h2t(self, i1, i0, i2):
|
|
@@ -386,12 +386,12 @@ def simplify1(points, distance=_1mm, radius=R_M, indices=False, **options):
|
|
|
386
386
|
@kwarg indices: If C{True} return the simplified point indices
|
|
387
387
|
instead of the simplified points (C{bool}).
|
|
388
388
|
@kwarg options: Optional keyword arguments passed thru to
|
|
389
|
-
function L{pygeodesy.
|
|
389
|
+
function L{pygeodesy.equirectangular4}.
|
|
390
390
|
|
|
391
391
|
@return: Simplified points (C{LatLon}[]).
|
|
392
392
|
|
|
393
393
|
@raise LimitError: Lat- and/or longitudinal delta exceeds the B{C{limit}},
|
|
394
|
-
see function L{pygeodesy.
|
|
394
|
+
see function L{pygeodesy.equirectangular4}.
|
|
395
395
|
|
|
396
396
|
@raise ValueError: Tolerance B{C{distance}} or B{C{radius}} too small.
|
|
397
397
|
'''
|
|
@@ -431,12 +431,12 @@ def simplifyRDP(points, distance=_1mm, radius=R_M, shortest=False,
|
|
|
431
431
|
@kwarg indices: If C{True} return the simplified point indices
|
|
432
432
|
instead of the simplified points (C{bool}).
|
|
433
433
|
@kwarg options: Optional keyword arguments passed thru to
|
|
434
|
-
function L{pygeodesy.
|
|
434
|
+
function L{pygeodesy.equirectangular4}.
|
|
435
435
|
|
|
436
436
|
@return: Simplified points (C{LatLon}[]).
|
|
437
437
|
|
|
438
438
|
@raise LimitError: Lat- and/or longitudinal delta exceeds the B{C{limit}},
|
|
439
|
-
see function L{pygeodesy.
|
|
439
|
+
see function L{pygeodesy.equirectangular4}.
|
|
440
440
|
|
|
441
441
|
@raise ValueError: Tolerance B{C{distance}} or B{C{radius}} too small.
|
|
442
442
|
'''
|
|
@@ -465,12 +465,12 @@ def simplifyRDPm(points, distance=_1mm, radius=R_M, shortest=False,
|
|
|
465
465
|
@kwarg indices: If C{True} return the simplified point indices
|
|
466
466
|
instead of the simplified points (C{bool}).
|
|
467
467
|
@kwarg options: Optional keyword arguments passed thru to
|
|
468
|
-
function L{pygeodesy.
|
|
468
|
+
function L{pygeodesy.equirectangular4}.
|
|
469
469
|
|
|
470
470
|
@return: Simplified points (C{LatLon}[]).
|
|
471
471
|
|
|
472
472
|
@raise LimitError: Lat- and/or longitudinal delta exceeds the B{C{limit}},
|
|
473
|
-
see function L{pygeodesy.
|
|
473
|
+
see function L{pygeodesy.equirectangular4}.
|
|
474
474
|
|
|
475
475
|
@raise ValueError: Tolerance B{C{distance}} or B{C{radius}} too small.
|
|
476
476
|
'''
|
|
@@ -496,12 +496,12 @@ def simplifyRW(points, pipe=_1mm, radius=R_M, shortest=False,
|
|
|
496
496
|
@kwarg indices: If C{True} return the simplified point indices
|
|
497
497
|
instead of the simplified points (C{bool}).
|
|
498
498
|
@kwarg options: Optional keyword arguments passed thru to
|
|
499
|
-
function L{pygeodesy.
|
|
499
|
+
function L{pygeodesy.equirectangular4}.
|
|
500
500
|
|
|
501
501
|
@return: Simplified points (C{LatLon}[]).
|
|
502
502
|
|
|
503
503
|
@raise LimitError: Lat- and/or longitudinal delta exceeds the B{C{limit}},
|
|
504
|
-
see function L{pygeodesy.
|
|
504
|
+
see function L{pygeodesy.equirectangular4}.
|
|
505
505
|
|
|
506
506
|
@raise ValueError: Tolerance B{C{pipe}} or B{C{radius}} too small.
|
|
507
507
|
'''
|
|
@@ -547,7 +547,7 @@ def simplifyVW(points, area=_1mm, radius=R_M, attr=None,
|
|
|
547
547
|
@kwarg indices: If C{True} return the simplified point indices
|
|
548
548
|
instead of the simplified points (C{bool}).
|
|
549
549
|
@kwarg options: Optional keyword arguments passed thru to
|
|
550
|
-
function L{pygeodesy.
|
|
550
|
+
function L{pygeodesy.equirectangular4}.
|
|
551
551
|
|
|
552
552
|
@return: Simplified points (C{LatLon}[]).
|
|
553
553
|
|
|
@@ -555,7 +555,7 @@ def simplifyVW(points, area=_1mm, radius=R_M, attr=None,
|
|
|
555
555
|
B{C{points}}.
|
|
556
556
|
|
|
557
557
|
@raise LimitError: Lat- and/or longitudinal delta exceeds the B{C{limit}},
|
|
558
|
-
see function L{pygeodesy.
|
|
558
|
+
see function L{pygeodesy.equirectangular4}.
|
|
559
559
|
|
|
560
560
|
@raise ValueError: Tolerance B{C{area}} or B{C{radius}} too small.
|
|
561
561
|
'''
|
|
@@ -603,7 +603,7 @@ def simplifyVWm(points, area=_1mm, radius=R_M, attr=None,
|
|
|
603
603
|
@kwarg indices: If C{True} return the simplified point indices
|
|
604
604
|
instead of the simplified points (C{bool}).
|
|
605
605
|
@kwarg options: Optional keyword arguments passed thru to
|
|
606
|
-
function L{pygeodesy.
|
|
606
|
+
function L{pygeodesy.equirectangular4}.
|
|
607
607
|
|
|
608
608
|
@return: Simplified points (C{LatLon}[]).
|
|
609
609
|
|
|
@@ -611,7 +611,7 @@ def simplifyVWm(points, area=_1mm, radius=R_M, attr=None,
|
|
|
611
611
|
B{C{points}}.
|
|
612
612
|
|
|
613
613
|
@raise LimitError: Lat- and/or longitudinal delta exceeds the B{C{limit}},
|
|
614
|
-
see function L{pygeodesy.
|
|
614
|
+
see function L{pygeodesy.equirectangular4}.
|
|
615
615
|
|
|
616
616
|
@raise ValueError: Tolerance B{C{area}} or B{C{radius}} too small.
|
|
617
617
|
'''
|
pygeodesy/solveBase.py
CHANGED
|
@@ -8,13 +8,13 @@ from pygeodesy.basics import map2, ub2str, _zip
|
|
|
8
8
|
from pygeodesy.constants import DIG
|
|
9
9
|
from pygeodesy.datums import _earth_datum, _WGS84, _EWGS84
|
|
10
10
|
# from pygeodesy.ellipsoids import _EWGS84 # from .datums
|
|
11
|
-
from pygeodesy.errors import _AssertionError,
|
|
11
|
+
from pygeodesy.errors import _AssertionError, _xkwds_get1, _xkwds_item2
|
|
12
12
|
from pygeodesy.internals import _enquote, printf
|
|
13
13
|
from pygeodesy.interns import NN, _0_, _BACKSLASH_, _COMMASPACE_, \
|
|
14
|
-
_EQUAL_, _Error_,
|
|
14
|
+
_EQUAL_, _Error_, _SPACE_, _UNUSED_
|
|
15
15
|
from pygeodesy.karney import Caps, _CapsBase, GDict
|
|
16
16
|
from pygeodesy.lazily import _ALL_DOCS, _ALL_LAZY, _unlazy
|
|
17
|
-
from pygeodesy.named import callername, notOverloaded
|
|
17
|
+
from pygeodesy.named import callername, _name2__, notOverloaded
|
|
18
18
|
from pygeodesy.props import Property, Property_RO, property_RO, _update_all
|
|
19
19
|
from pygeodesy.streprs import Fmt, fstr, fstrzs, pairs, strs
|
|
20
20
|
from pygeodesy.units import Precision_
|
|
@@ -23,7 +23,7 @@ from pygeodesy.utily import unroll180, wrap360 # PYCHOK shared
|
|
|
23
23
|
from subprocess import PIPE as _PIPE, Popen as _Popen, STDOUT as _STDOUT
|
|
24
24
|
|
|
25
25
|
__all__ = _ALL_LAZY.solveBase
|
|
26
|
-
__version__ = '24.
|
|
26
|
+
__version__ = '24.05.31'
|
|
27
27
|
|
|
28
28
|
_ERROR_ = 'ERROR'
|
|
29
29
|
_text_True = dict() if _unlazy else dict(text=True)
|
|
@@ -106,7 +106,7 @@ class _SolveLineSolveBase(_CapsBase):
|
|
|
106
106
|
if floats:
|
|
107
107
|
v = map(float, v)
|
|
108
108
|
r = GDict(_zip(n, v)) # strict=True
|
|
109
|
-
return self._iter2tion(r, r)
|
|
109
|
+
return self._iter2tion(r, **r)
|
|
110
110
|
|
|
111
111
|
@property_RO
|
|
112
112
|
def invokation(self):
|
|
@@ -132,12 +132,12 @@ class _SolveLineSolveBase(_CapsBase):
|
|
|
132
132
|
@note: The C{Solve} return code is in property L{status}.
|
|
133
133
|
'''
|
|
134
134
|
c = (self._Solve_path,) + map2(str, options)
|
|
135
|
-
i =
|
|
135
|
+
i = _xkwds_get1(stdin, stdin=None)
|
|
136
136
|
r = self._invoke(c, stdin=i)
|
|
137
137
|
s = self.status
|
|
138
138
|
if s:
|
|
139
139
|
raise self._Error(cmd=_cmd_stdin_(c, i), status=s,
|
|
140
|
-
|
|
140
|
+
txt_not_=_0_)
|
|
141
141
|
if self.verbose: # PYCHOK no cover
|
|
142
142
|
self._print(r)
|
|
143
143
|
return r
|
|
@@ -221,7 +221,7 @@ class _SolveLineSolveBase(_CapsBase):
|
|
|
221
221
|
_ = self.version # test path and ...
|
|
222
222
|
if self.status: # ... return code
|
|
223
223
|
S_p = Solve_path or {self._Solve_name: _enquote(path)}
|
|
224
|
-
raise self._Error(status=self.status,
|
|
224
|
+
raise self._Error(status=self.status, txt_not_=_0_, **S_p)
|
|
225
225
|
hold = path
|
|
226
226
|
finally: # restore in case of error
|
|
227
227
|
if self._Solve_path != hold:
|
|
@@ -275,7 +275,7 @@ class _SolveBase(_SolveLineSolveBase):
|
|
|
275
275
|
'''
|
|
276
276
|
_datum = _WGS84
|
|
277
277
|
|
|
278
|
-
def __init__(self, a_ellipsoid=_EWGS84, f=None, path=NN, name
|
|
278
|
+
def __init__(self, a_ellipsoid=_EWGS84, f=None, path=NN, **name):
|
|
279
279
|
'''New C{Solve} instance.
|
|
280
280
|
|
|
281
281
|
@arg a_ellipsoid: An ellipsoid (L{Ellipsoid}) or datum (L{Datum}) or
|
|
@@ -285,11 +285,11 @@ class _SolveBase(_SolveLineSolveBase):
|
|
|
285
285
|
is specified as C{scalar}.
|
|
286
286
|
@kwarg path: Optionally, the (fully qualified) path to the C{GeodSolve}
|
|
287
287
|
or C{RhumbSolve} executable (C{filename}).
|
|
288
|
-
@kwarg name: Optional name (C{str}).
|
|
288
|
+
@kwarg name: Optional C{B{name}=NN} (C{str}).
|
|
289
289
|
|
|
290
290
|
@raise TypeError: Invalid B{C{a_ellipsoid}} or B{C{f}}.
|
|
291
291
|
'''
|
|
292
|
-
_earth_datum(self, a_ellipsoid, f=f, name
|
|
292
|
+
_earth_datum(self, a_ellipsoid, f=f, **name)
|
|
293
293
|
if name:
|
|
294
294
|
self.name = name
|
|
295
295
|
if path:
|
|
@@ -352,7 +352,7 @@ class _SolveBase(_SolveLineSolveBase):
|
|
|
352
352
|
'''
|
|
353
353
|
if arcmode:
|
|
354
354
|
raise self._Error(arcmode=arcmode, txt=str(NotImplemented))
|
|
355
|
-
floats =
|
|
355
|
+
floats = _xkwds_get1(floats, floats=True)
|
|
356
356
|
return self._GDictInvoke(self._cmdDirect, floats, self._Names_Direct,
|
|
357
357
|
lat, lon, azi, s12_a12)
|
|
358
358
|
|
|
@@ -360,7 +360,7 @@ class _SolveBase(_SolveLineSolveBase):
|
|
|
360
360
|
'''(INTERNAL) Get C{_GenInverse}-like result as C{GDict}, but
|
|
361
361
|
I{without} C{_SALPs_CALPs_}.
|
|
362
362
|
'''
|
|
363
|
-
floats =
|
|
363
|
+
floats = _xkwds_get1(floats, floats=True)
|
|
364
364
|
return self._GDictInvoke(self._cmdInverse, floats, self._Names_Inverse,
|
|
365
365
|
lat1, lon1, lat2, lon2)
|
|
366
366
|
|
|
@@ -394,16 +394,16 @@ class _SolveLineBase(_SolveLineSolveBase):
|
|
|
394
394
|
# _lla1 = {}
|
|
395
395
|
_solve = None # L{GeodesicSolve} or L{RhumbSolve} instance
|
|
396
396
|
|
|
397
|
-
def __init__(self, solve, lat1, lon1, caps,
|
|
397
|
+
def __init__(self, solve, lat1, lon1, caps, **azi_name):
|
|
398
|
+
name, azi = _name2__(azi_name, _or_nameof=solve)
|
|
399
|
+
if name:
|
|
400
|
+
self.name = name
|
|
401
|
+
|
|
398
402
|
self._caps = caps | Caps._LINE
|
|
399
403
|
self._debug = solve._debug & Caps._DEBUG_ALL
|
|
400
404
|
self._lla1 = GDict(lat1=lat1, lon1=lon1, **azi)
|
|
401
405
|
self._solve = solve
|
|
402
406
|
|
|
403
|
-
n = name or solve.name
|
|
404
|
-
if n:
|
|
405
|
-
self.name = n
|
|
406
|
-
|
|
407
407
|
@Property_RO
|
|
408
408
|
def _cmdDistance(self):
|
|
409
409
|
'''(INTERNAL) Get the C{GeodSolve} I{-L} cmd (C{tuple}).
|
pygeodesy/sphericalBase.py
CHANGED
|
@@ -21,18 +21,18 @@ from pygeodesy.datums import Datums, _earth_ellipsoid, _spherical_datum
|
|
|
21
21
|
from pygeodesy.errors import IntersectionError, _ValueError, \
|
|
22
22
|
_xattr, _xError
|
|
23
23
|
from pygeodesy.fmath import favg, fdot, hypot, sqrt_a
|
|
24
|
-
from pygeodesy.interns import
|
|
25
|
-
|
|
26
|
-
|
|
24
|
+
from pygeodesy.interns import _COMMA_, _concentric_, _datum_, _distant_, \
|
|
25
|
+
_exceed_PI_radians_, _name_, _near_, \
|
|
26
|
+
_radius_, _too_
|
|
27
27
|
from pygeodesy.latlonBase import LatLonBase, _trilaterate5 # PYCHOK passed
|
|
28
28
|
from pygeodesy.lazily import _ALL_DOCS, _ALL_LAZY, _ALL_MODS as _MODS
|
|
29
29
|
# from pygeodesy.namedTuples import Bearing2Tuple # from .cartesianBase
|
|
30
30
|
from pygeodesy.nvectorBase import NvectorBase, Fmt, _xattrs
|
|
31
|
-
from pygeodesy.props import deprecated_method, property_doc_, \
|
|
32
|
-
|
|
31
|
+
from pygeodesy.props import deprecated_method, property_doc_, property_RO, \
|
|
32
|
+
_update_all
|
|
33
33
|
# from pygeodesy.streprs import Fmt, _xattrs # from .nvectorBase
|
|
34
|
-
from pygeodesy.units import
|
|
35
|
-
|
|
34
|
+
from pygeodesy.units import Bearing, Bearing_, _isRadius, Radians_, Radius, \
|
|
35
|
+
Radius_, Scalar_, _100km
|
|
36
36
|
from pygeodesy.utily import acos1, asin1, atan2b, atan2d, degrees90, \
|
|
37
37
|
degrees180, sincos2, sincos2d, _unrollon, \
|
|
38
38
|
tanPI_2_2, wrapPI
|
|
@@ -40,7 +40,7 @@ from pygeodesy.utily import acos1, asin1, atan2b, atan2d, degrees90, \
|
|
|
40
40
|
from math import cos, fabs, log, sin, sqrt
|
|
41
41
|
|
|
42
42
|
__all__ = _ALL_LAZY.sphericalBase
|
|
43
|
-
__version__ = '
|
|
43
|
+
__version__ = '24.05.31'
|
|
44
44
|
|
|
45
45
|
|
|
46
46
|
class CartesianSphericalBase(CartesianBase):
|
|
@@ -117,7 +117,7 @@ class LatLonSphericalBase(LatLonBase):
|
|
|
117
117
|
_datum = Datums.Sphere # spherical L{Datum}
|
|
118
118
|
_napieradius = _100km
|
|
119
119
|
|
|
120
|
-
def __init__(self, latlonh, lon=None, height=0, datum=None, wrap=False, name
|
|
120
|
+
def __init__(self, latlonh, lon=None, height=0, datum=None, wrap=False, **name):
|
|
121
121
|
'''Create a spherical C{LatLon} point frome the given lat-, longitude and
|
|
122
122
|
height on the given datum.
|
|
123
123
|
|
|
@@ -132,12 +132,12 @@ class LatLonSphericalBase(LatLonBase):
|
|
|
132
132
|
conventionally).
|
|
133
133
|
@kwarg wrap: If C{True}, wrap or I{normalize} B{C{lat}} and B{C{lon}}
|
|
134
134
|
(C{bool}).
|
|
135
|
-
@kwarg name: Optional name (C{str}).
|
|
135
|
+
@kwarg name: Optional C{B{name}=NN} (C{str}).
|
|
136
136
|
|
|
137
137
|
@raise TypeError: If B{C{latlonh}} is not a C{LatLon} or B{C{datum}} not
|
|
138
138
|
spherical.
|
|
139
139
|
'''
|
|
140
|
-
LatLonBase.__init__(self, latlonh, lon=lon, height=height, wrap=wrap, name
|
|
140
|
+
LatLonBase.__init__(self, latlonh, lon=lon, height=height, wrap=wrap, **name)
|
|
141
141
|
if datum not in (None, self.datum):
|
|
142
142
|
self.datum = datum
|
|
143
143
|
|
|
@@ -302,26 +302,22 @@ class LatLonSphericalBase(LatLonBase):
|
|
|
302
302
|
# raise _xError(x, this=self, point=point, other=other, **radius_exact_height_wrap)
|
|
303
303
|
# return p.midpointTo(q)
|
|
304
304
|
|
|
305
|
-
def parse(self, strllh, height=0, sep=_COMMA_, name
|
|
305
|
+
def parse(self, strllh, height=0, sep=_COMMA_, **name):
|
|
306
306
|
'''Parse a string representing a similar, spherical C{LatLon}
|
|
307
307
|
point, consisting of C{"lat, lon[, height]"}.
|
|
308
308
|
|
|
309
|
-
@arg strllh: Lat, lon and optional height (C{str}),
|
|
310
|
-
|
|
309
|
+
@arg strllh: Lat, lon and optional height (C{str}), see function
|
|
310
|
+
L{pygeodesy.parse3llh}.
|
|
311
311
|
@kwarg height: Optional, default height (C{meter}).
|
|
312
312
|
@kwarg sep: Optional separator (C{str}).
|
|
313
|
-
@kwarg name: Optional
|
|
314
|
-
overriding this name.
|
|
313
|
+
@kwarg name: Optional C{B{name}=NN} (C{str}), overriding this name.
|
|
315
314
|
|
|
316
315
|
@return: The similar point (spherical C{LatLon}).
|
|
317
316
|
|
|
318
317
|
@raise ParseError: Invalid B{C{strllh}}.
|
|
319
318
|
'''
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
if name:
|
|
323
|
-
r.rename(name)
|
|
324
|
-
return r
|
|
319
|
+
llh = _MODS.dms.parse3llh(strllh, height=height, sep=sep)
|
|
320
|
+
return self.classof(*llh, **name)
|
|
325
321
|
|
|
326
322
|
@property_RO
|
|
327
323
|
def _radius(self):
|