Class StatBandpassMsgPackStrategy
Defined in File StatBandpassMsgPackStrategy.h
Inheritance Relationships
Base Type
public ska::pst::stat::StatMsgPackStrategy(Class StatMsgPackStrategy)
Class Documentation
-
class StatBandpassMsgPackStrategy : public ska::pst::stat::StatMsgPackStrategy
This class is used populate the “data_type”, “metadata”, and “data” sections of Bandpass MsgPack messages.
Public Functions
-
virtual void pack_data_type(msgpack::packer<std::stringstream> &packer) override
Sets the value of the data_type as “pst_bandpass”.
- Parameters
packer – the MsgPack packer to write the data type value to.
-
virtual void pack_metadata(msgpack::packer<std::stringstream> &packer, const StatStorage &storage, const ska::pst::common::AsciiHeader &config) override
Add metadata map to output MsgPack message.
The bandpass metadata are a map of the following:
“nchan” - the number of channels in in the bandpass.
”start_chan” - the value of the first channel in the bandpass, all other channels increase incrementally from this value.
”freq_min” - the centre frequency of the “start_chan”, in Hertz.
”freq_max” - the centre frequency of the last channel (i.e. start_chan + nchan - 1), in Hertz.
- Parameters
packer – the MsgPack packer to pack the metadata record into.
storage – the StatStorage to get metadata from.
config – the current configuration of the scan
-
virtual void pack_data(msgpack::packer<std::stringstream> &packer, const StatStorage &storage, const ska::pst::common::AsciiHeader &config) override
Add data to output MsgPack message.
The bandpass data are an array of polarisation data. The data for each polarisation is packed as a map with the following values:
“polarisation” - the name of the polarisation.
”data” - the bandpass data, the length of this matches the number of channels as per the StatStorage layout.
- Parameters
packer – the MsgPack packer to pack the metadata record into.
storage – the StatStorage to get metadata from.
config – the current configuration of the scan
-
virtual void pack_data_type(msgpack::packer<std::stringstream> &packer) override