Station Beam Health Model

An implementation of a health model for station beams.

class StationBeamHealthModel(*args: Any, **kwargs: Any)[source]

A health model for station beams.

__init__(health_changed_callback: Callable, ignore_power_state: bool = False, thresholds: dict[str, float] | None = None) None[source]

Initialise a new instance.

Parameters:
  • health_changed_callback – a callback to be called when the health of the station beam (as evaluated by this model) changes

  • ignore_power_state – whether the health model should ignore the power state when computing health.

  • thresholds – Thresholds for failed degraded states.

antenna_health_changed(trl: str, health_state: ska_control_model.HealthState) None[source]

Handle change in station health.

This is a callback hook, called by the component manager when the health of a station changes. :param trl: the TRL of the antenna whose health has changed :param health_state: the new health state of the antenna.

evaluate_health() tuple[ska_control_model.HealthState, str][source]

Compute overall health of the station beam.

The overall health is based on the whether the beam is locked or not.

Returns:

an overall health of the station beam

is_beam_locked_changed(is_beam_locked: bool) None[source]

Handle a change in whether the station beam is locked.

This is a callback hook that is called when whether asubarray beam is locked changes.

Parameters:

is_beam_locked – whether the station beam is locked

resources_changed(antenna_trls: set[str]) None[source]

Change the resources used for the station beam.

Parameters:

antenna_trls – TRLs of the antennas used for the beam

station_fault_changed(station_fault: bool) None[source]

Handle a change in the fault state of the station beam’s station device.

This is a callback hook that is called when whether a station beam detects that the fault state of its station has changed. This could occur because the station’s health changes, or because the beam changes station.

Parameters:

station_fault – the fault state of the station that is controlled by this beam.

station_health_changed(station_health: ska_control_model.HealthState) None[source]

Handle a change in the health of the station device that this beam controls.

This is a callback hook that is called when whether a station beam detects that the health of its station has changed. This could occur because the station’s health changes, or because the beam changes station.

Parameters:

station_health – the health of the station that is controlled by this beam