Package pygeodesy :: Module hausdorff :: Class Hausdorff |
[frames] | no frames]

# Class Hausdorff

      object --+
               |
    named._Named --+
                   |
                  Hausdorff

Known Subclasses:
  - HausdorffDegrees
  - , HausdorffRadians

Hausdorff base class, requires method Hausdorff.distance to be overloaded.

Instance Methods
__init__(self, points, seed=None, name=`'````'`, units=`'````'`) New Hausdorff calculator. |
directed(self, points, early=True) Compute only the `forward Hausdorff` distance. |
distance(self, point1, point2) Distance between 2 points from `.point`. |
point(self, point) Convert a `model` or `target` point for the `.distance` method. |
symmetric(self, points, early=True) Compute the combined `forward and reverse Hausdorff` distance. |
Inherited from `named._Named`: `__copy__`, `__repr__`, `__str__`, `classof`, `copy` Inherited from `object`: `__delattr__`, `__format__`, `__getattribute__`, `__hash__`, `__new__`, `__reduce__`, `__reduce_ex__`, `__setattr__`, `__sizeof__`, `__subclasshook__`

Properties
| seed Get the random sampling seed (`any` or `None`).
| units Get the distance units (`str` or `""`).
Inherited from `named._Named`: `classname`, `classnaming`, `name`, `named`, `named2` Inherited from `object`: `__class__`

Method Details

### __init__(self, points, seed=None, name=`'````'`, units=`'````'`) (Constructor) |
New Hausdorff calculator. Parameters: `points` - Initial set of points, aka the `model` or `template` (`LatLon`[], `Numpy2LatLon`[], `Tuple2LatLon`[] or `other`[]). `seed` - Random sampling seed (`any`) or `None`, `0` or `False` for no random sampling. `name` - Optional calculator name (`str`). `units` - Optional, distance units (`str`). Raises: `HausdorffError` - Insufficient number of `points` or invalid `seed`. Overrides: object.__init__

### directed(self, points, early=True) |
Compute only the `forward Hausdorff` distance. Parameters: `points` - Second set of points, aka the `target` (`LatLon`[], `Numpy2LatLon`[], `Tuple2LatLon`[] or `other`[]). `early` - Enable or disable early breaking (`bool`). Returns: A Hausdorff6Tuple`(hd, i, j, mn, md, units)`. Raises: `HausdorffError` - Insufficient number of `points`.

### distance(self, point1, point2) |
Distance between 2 points from `.point`. Raises: `AssertionError` - Not overloaded. Note: This method must be overloaded.

### symmetric(self, points, early=True) |
Compute the combined `forward and reverse Hausdorff` distance. Parameters: `points` - Second set of points, aka the `target` (`LatLon`[], `Numpy2LatLon`[], `Tuple2LatLon`[] or `other`[]). `early` - Enable or disable early breaking (`bool`). Returns: A Hausdorff6Tuple`(hd, i, j, mn, md, units)`. Raises: `HausdorffError` - Insufficient number of `points`.

Property Details

### seed Get the random sampling seed (`any` or `None`). Get Method: seed(self) - Get the random sampling seed (`any` or `None`). Set Method: seed(self, seed) - Set the random sampling seed.

### units Get the distance units (`str` or `""`). Get Method: units(self) - Get the distance units (`str` or `""`). Set Method: units(self, units) - Set the distance units.