/  PyMDB  /  Calibrators

Calibrators

Calibrator

class yamcs.pymdb.Calibrator

Bases: object

Transform a raw value (e.g. an integer count from a spacecraft) to an engineering value for users (e.g. a float).

__init__() None

Polynomial

class yamcs.pymdb.Polynomial

Bases: Calibrator

A calibration type where a curve in a raw vs calibrated plane is described using a set of polynomial coefficients. Raw values are converted to calibrated values by finding a position on the curve corresponding to the raw value.

__init__(coefficients: list[float]) None
coefficients: list[float]

Coefficients ordered from X^0 to X^n

Interpolate

class yamcs.pymdb.Interpolate

Bases: Calibrator

One-dimensional piecewise interpolation. A segmented line in a raw vs calibrated plane is described using a set of points. Raw values are converted to calibrated values by finding a position on the line corresponding to the raw value.

__init__(xp: list[float], fp: list[float]) None
fp: list[float]

The y-coordinates of the data-points. Should have same length as xp.

xp: list[float]

The x-coordinates of the data points. Should be increasing.