ska_pst.send.metadata

Module class for structure used for writing YAML meta data files.

class ska_pst.send.metadata.PstConfig(image: str = '', version: str = '')[source]

A data class to represent the config field of a pst metadata file.

Configuration of generating software.

Variables
  • image (str) – chart name

  • version (str) – chart version

image: str = ''
version: str = ''
class ska_pst.send.metadata.PstContext(observer: str = '', intent: str = 'Tied-array beam observation', notes: str = '')[source]

A data class to represent the context field of a pst metadata file.

context is meant to be data passed verbatim through from OET/TMC as part of AssignResources (SDP) or Configure (other sub-systems). To be made part of ska_telmodel schemas.

Variables
  • observer (str) – Name or role of the person conducting the observation

  • intent (str) – intent passed from OET/TMC

  • notes (str) – notes passed from OET/TMC

intent: str = 'Tied-array beam observation'
notes: str = ''
observer: str = ''
class ska_pst.send.metadata.PstFiles(description: str = '', path: str = '', size: int = 0, status: str = 'done')[source]

A data class to represent the files field of a pst metadata file.

Documentation concerning files coupled to the pst metadata file.

Variables
  • description (str) –

  • path (str) –

  • size (int) –

  • status (str) –

description: str = ''
path: str = ''
size: int = 0
status: str = 'done'
class ska_pst.send.metadata.PstMetaData(interface: str = '', execution_block: str = '', context: ~ska_pst.send.metadata.PstContext = <factory>, config: ~ska_pst.send.metadata.PstConfig = <factory>, files: ~typing.List[~ska_pst.send.metadata.PstFiles] = <factory>, obscore: ~ska_pst.send.metadata.PstObsCore = <factory>)[source]

Class representing the PST metadata.

This class encapsulates the metadata information for a PST (Processing Science Target) data product. It includes details about the interface, execution block, context, configuration, files, and observation core information.

Variables
  • interface (str) – The interface of the metadata.

  • execution_block (str) – The execution block identifier.

  • context (PstContext) – The context information for the PST data.

  • config (PstConfig) – The configuration information for the PST data.

  • files (List[PstFiles]) – List of files associated with the PST data.

  • obscore (PstObsCore) – The observation core information for the PST data.

config: PstConfig
context: PstContext
execution_block: str = ''
files: List[PstFiles]
interface: str = ''
obscore: PstObsCore
to_yaml() str[source]

Get the object properties in yaml representation in string format.

property yaml_object: yaml.YAMLObject

Get the object properties as a yaml object.

class ska_pst.send.metadata.PstObsCore(dataproduct_type: str = 'timeseries', dataproduct_subtype: str = 'voltages', calib_level: int = 0, obs_id: str = '', access_estsize: int = 0, target_name: str = '', s_ra: float = 0.0, s_dec: float = 0.0, t_min: float = 0.0, t_max: float = 0.0, t_resolution: float = 0.0, t_exptime: float = 0.0, facility_name: str = 'SKA-Observatory', instrument_name: str = '', pol_xel: int = 0, pol_states: str = '', em_xel: int = 0, em_unit: str = 'Hz', em_min: float = 0.0, em_max: float = 0.0, em_res_power: str = '', em_resolution: float = 0.0, o_ucd: str = 'null')[source]

A dataclass to definition of the standard IVOA ObsCore table/view.

Variables
  • dataproduct_type (str) – Logical data product type, such as image, cube, spectrum, sed, timeseries, visibility, event or measurements

  • dataproduct_subtype (str) – voltages, oversampled, channelised, quantised voltages

  • calib_level (int) – Calibration level (0, 1, 2, 3, 4) 0 = Raw instrumental data 1 = Instrumental data in a standard format (FITS, VOTable, SDFITS, ASDM, etc.) 2 = Calibrated, science ready data with the instrument signature removed 3 = Enhanced data products like mosaics, resampled or drizzled images, or heavily processed survey fields 4 = Analysis data products generated after some scientific data manipulation or interpretation.

  • obs_id (str) – scan id

  • access_estsize (int) – value derived from the recorded data files upon stop_scan()

  • target_name (str) – Astronomical object observed

  • s_ra (float) – Centre of observation right ascension, ICRS

  • s_dec (float) – Centre of observation declination, ICRS

  • t_min (str) – Start time in MJD

  • t_max (str) – Stop time in MJD

  • t_resolution (float) – Temporal resolution FWHM (full width at half maximum)

  • t_exptime (float) – Total exposure time.

  • facility_name (str) – The observatory or facility used to collect the data

  • instrument_name (str) – The name of the instrument used for the acquisition of the observation

  • pol_xel (int) – Number of polarization samples

  • pol_states (str) – List of polarization states

  • em_xel (int) – Number of elements along the spectral axis

  • em_unit (str) – Spectral coordinates unit type. Defaults to Hz.

  • em_min (float) – Start in spectral coordinates (vacuum wavelength)

  • em_max (float) – Stop in spectral coordinates (vacuum wavelength)

  • em_res_power (str) – Spectral resolving power

  • em_resolution (float) – Spectral resolution

  • o_ucd (str) – Unified Content Descriptor of observable e.g. phot.count or phot.flux.density see section 4.18 and B.6.4.1 in Obscore standard, UCD1+ controlled vocabulary and especially list of observables), not really anything suitable for PST.

access_estsize: int = 0
calib_level: int = 0
dataproduct_subtype: str = 'voltages'
dataproduct_type: str = 'timeseries'
em_max: float = 0.0
em_min: float = 0.0
em_res_power: str = ''
em_resolution: float = 0.0
em_unit: str = 'Hz'
em_xel: int = 0
facility_name: str = 'SKA-Observatory'
instrument_name: str = ''
o_ucd: str = 'null'
obs_id: str = ''
pol_states: str = ''
pol_xel: int = 0
s_dec: float = 0.0
s_ra: float = 0.0
t_exptime: float = 0.0
t_max: float = 0.0
t_min: float = 0.0
t_resolution: float = 0.0
target_name: str = ''