dodal.devices.util.lookup_tables#
All the public methods in this module return a lookup table of some kind that converts the source value s to a target value t for different values of s.
Functions
|
Returns a numpy formatted lookup table for required positions of an ID gap to provide emission at a given beam energy. |
|
Returns a callable that converts values by linear interpolation of lookup table values. |
|
Parse a generic lookup table with a number of columns >= 2 and return a list in column major order of the values in it. |
- async dodal.devices.util.lookup_tables.energy_distance_table(lookup_table_path: str) ndarray [source]#
Returns a numpy formatted lookup table for required positions of an ID gap to provide emission at a given beam energy.
- Parameters:
lookup_table_path (
str
) – Path to lookup table- Returns:
Lookup table
- Return type:
ndarray
- dodal.devices.util.lookup_tables.parse_lookup_table(filename: str) list[Sequence] [source]#
Parse a generic lookup table with a number of columns >= 2 and return a list in column major order of the values in it.
- dodal.devices.util.lookup_tables.linear_interpolation_lut(s_values: Sequence, t_values: Sequence) Callable[[float], float] [source]#
Returns a callable that converts values by linear interpolation of lookup table values.
If the value falls outside the lookup table then the closest value will be used.