pygeodesy.heights

Package pygeodesy :: Module heights |
[frames] | no frames]

# Module heights

Height interpolations at `LatLon` points from known `knots`.

Classes HeightCubic, HeightIDWcosineLaw, HeightIDWdistanceTo, HeightIDWequirectangular, HeightIDWeuclidean, HeightIDWflatLocal, HeightIDWflatPolar, HeightIDWhaversine, HeightIDWhubeny, HeightIDWkarney, HeightIDWthomas, HeightIDWvincentys, HeightLinear, HeightLSQBiSpline and HeightSmoothBiSpline to interpolate the height of `LatLon` locations or separate lat-/longitudes from a set of `LatLon` points with known heights.

# Typical usage

1. Get or create a set of `LatLon` points with known heights, called `knots`. The `knots` do not need to be ordered in any particular way.

   `>>> ...`

2. Select one of the `Height` classes for height interpolation

   `>>> from pygeodesy import HeightCubic as HeightXyz # or an other Height... class`

3. Instantiate a height interpolator with the `knots` and use keyword arguments to select different interpolation options

   `>>> hinterpolator = HeightXyz(knots, **options)`

4. Get the interpolated height of `LatLon` location(s) with

   `>>> ll = LatLon(1, 2, ...)`

   `>>> h = hinterpolator(ll)`

   or

   `>>> h0, h1, h2, ... = hinterpolator(ll0, ll1, ll2, ...)`

   or a list, tuple, generator, etc. of `LatLon`s

   `>>> hs = hinterpolator(lls)`

5. For separate lat- and longitudes invoke the `height` method as

   `>>> h = hinterpolator.height(lat, lon)`

   or as 2 lists, 2 tuples, etc.

   `>>> hs = hinterpolator.height(lats, lons)`

   or for several positionals use the `height_` method

   `>>> h1, h2, ... = hinterpolator.height_(lat1, lon1, lat2, lon2, ...)`

Notes:

- Classes HeightCubic and HeightLinear require package numpy, classes HeightLSQBiSpline and HeightSmoothBiSpline require package scipy. Classes HeightIDWkarney and HeightIDWdistanceTo -if used with ellipsoidalKarney.LatLon points- require Karney's geographiclib package to be installed.
- Errors from `scipy` are raised as SciPyErrors. Warnings issued by `scipy` can be thrown as SciPyWarning exceptions, provided Python `warnings` are filtered accordingly, see SciPyWarning.

See Also: SciPy Interpolation.

Version: 26.02.02

Classes
| HeightError Height interpolator `Height...` or interpolation issue.
| _HeightNamed (INTERNAL) Interpolator base class.
| _HeightBase (INTERNAL) Interpolator base class.
| HeightCubic Height interpolator based on `SciPy` interp2d `kind='cubic'` or bisplrep/-ev `kx=ky=3`.
| HeightLinear Height interpolator based on `SciPy` interp2d `kind='linear'` or bisplrep/-ev `kx=ky=1`.
| HeightLSQBiSpline Height interpolator using `SciPy` LSQSphereBivariateSpline.
| HeightSmoothBiSpline Height interpolator using `SciPy` SmoothSphereBivariateSpline.
| _HeightIDW (INTERNAL) Base class for Inverse Distance Weighting (IDW) height interpolators.
| HeightIDWcosineLaw Height interpolator using Inverse Distance Weighting (IDW) and function pygeodesy.cosineLaw.
| HeightIDWdistanceTo Height interpolator using Inverse Distance Weighting (IDW) and the points' `LatLon.distanceTo` method.
| HeightIDWequirectangular Height interpolator using Inverse Distance Weighting (IDW) and function pygeodesy.equirectangular4.
| HeightIDWeuclidean Height interpolator using Inverse Distance Weighting (IDW) and function pygeodesy.euclidean_.
| HeightIDWexact Height interpolator using Inverse Distance Weighting (IDW) and method GeodesicExact.Inverse.
| HeightIDWflatLocal Height interpolator using Inverse Distance Weighting (IDW) and the function pygeodesy.flatLocal_/pygeodesy.hubeny_.
| HeightIDWflatPolar Height interpolator using Inverse Distance Weighting (IDW) and function pygeodesy.flatPolar_.
| HeightIDWhaversine Height interpolator using Inverse Distance Weighting (IDW) and function pygeodesy.haversine_.
| HeightIDWhubeny Height interpolator using Inverse Distance Weighting (IDW) and the function pygeodesy.flatLocal_/pygeodesy.hubeny_.
| HeightIDWkarney Height interpolator using Inverse Distance Weighting (IDW) and Karney's geographiclib method geodesic.Geodesic.Inverse.
| HeightIDWthomas Height interpolator using Inverse Distance Weighting (IDW) and function pygeodesy.thomas_.
| HeightIDWvincentys Height interpolator using Inverse Distance Weighting (IDW) and function pygeodesy.vincentys_.

Variables
| __all__ = `_ALL_LAZY.heights`