polyfemos.front.sohplot.offsets.UWVOffsets — polyfemos 0.3.29 documentation

# polyfemos.front.sohplot.offsets.UWVOffsets

class `polyfemos.front.sohplot.offsets.` `UWVOffsets`

  Bases: `object`

  A class for UWV to NEZ conversion

  The transforming function for each sensor is defined in `transform_func()`

  Public Methods

  `__init__`()
  `clear`()

    Initializes `self.offsets` attribute into it’s default value.

  `isnan`()

    Checks if every value (U, W and V) is defined. If every one is defined, the coordinate transformation can be done.

    Return type

      bool

    Returns

      returns `False` if the coordinate trasformation is possible.

  `transform`(sensor, component)

    Transform offsets, UWV to NEZ

    Parameters

      - sensor (str) – Which transformation function is used, defined in `transform_func()`

      - conponent (str) – Which component after transformation is returned, N, E or Z.

    Return type

      `UTCDateTime`, float

    Returns

      timevalue and value of N, E or Z offset

  `update`(dtstr, key, value)

    Stores given `value` to offset U, W or V.

    Parameters

      - dtstr (str) – datetime compatible string or other value compatible with `UTCDateTime`

      - key (str) – Which offset is updated, U, W or V

      - value (str) – string representing float value of the offset,

  Special Methods

  `__bool__`()
    Return type

      bool

    Returns

      returns `True` if the coordinate trasformation is possible.