You're reading an old version of this documentation. For up-to-date information, please have a look at v0.2.

Dataset structure

The dataset is an essential concept of the ASpecD framework and in turn the trepr package, as it abstracts the different vendor formats and combines both, numerical data and metadata, in an easily accessible way. Even more, the general structure of a dataset allows to compare data of entirely different origin (read: spectroscopic method), as long as their axes are compatible.

Developers of the trepr package frequently need to get an overview of the structure of the dataset and its different subclasses, namely the ExperimentalDataset and CalculatedDataset. Whereas the API documentation of each class, trepr.dataset.ExperimentalDataset and trepr.dataset.CalculatedDataset, provides a lot of information, a simple and accessible presentation of the dataset structure is often what is needed.

Therefore, the structure of each of the dataset classes is provided below in YAML format, automatically generated from the actual source code.

Basic dataset

Base class for all kinds of datasets. Usually, either of the two subclasses will be used: ExperimentalDataset or CalculatedDataset. For both, the structure is documented below. For implementation details, see the API documentation of trepr.dataset.Dataset.

data:
  calculated: false
  data:
    type: numpy.ndarray
    dtype: float64
    array: []
  axes:
  - quantity: ''
    symbol: ''
    unit: ''
    label: ''
    values:
      type: numpy.ndarray
      dtype: float64
      array: []
  - quantity: ''
    symbol: ''
    unit: ''
    label: ''
    values:
      type: numpy.ndarray
      dtype: float64
      array: []
metadata: {}
history: []
analyses: []
annotations: []
representations: []
id: ''
label: ''
references: []
tasks: []
_origdata:
  calculated: false
  data:
    type: numpy.ndarray
    dtype: float64
    array: []
  axes:
  - quantity: ''
    symbol: ''
    unit: ''
    label: ''
    values:
      type: numpy.ndarray
      dtype: float64
      array: []
  - quantity: ''
    symbol: ''
    unit: ''
    label: ''
    values:
      type: numpy.ndarray
      dtype: float64
      array: []
_package_name: trepr
_history_pointer: -1

Experimental dataset

Entity containing both, numerical data as well as the corresponding metadata that are specific for the trEPR method. For implementation details, see the API documentation of trepr.dataset.ExperimentalDataset and trepr.dataset.ExperimentalDatasetMetadata.

data:
  calculated: false
  data:
    type: numpy.ndarray
    dtype: float64
    array: []
  axes:
  - quantity: ''
    symbol: ''
    unit: ''
    label: ''
    values:
      type: numpy.ndarray
      dtype: float64
      array: []
  - quantity: ''
    symbol: ''
    unit: ''
    label: ''
    values:
      type: numpy.ndarray
      dtype: float64
      array: []
metadata:
  measurement:
    label: ''
    start: null
    end: null
    purpose: ''
    operator: ''
    labbook_entry: ''
  sample:
    description: ''
    solvent: ''
    preparation: ''
    tube: ''
    name: ''
    id: null
    loi: ''
  temperature_control:
    cryostat: ''
    cryogen: ''
    temperature:
      unit: ''
      dimension: ''
      name: ''
      value: 0.0
    controller: ''
  transient:
    points: null
    length:
      unit: ''
      dimension: ''
      name: ''
      value: 0.0
    trigger_position: null
  experiment:
    runs: null
    shot_repetition_rate:
      unit: ''
      dimension: ''
      name: ''
      value: 0.0
  spectrometer:
    model: ''
    software: ''
  magnetic_field:
    field_probe_type: ''
    field_probe_model: ''
    start:
      unit: ''
      dimension: ''
      name: ''
      value: 0.0
    stop:
      unit: ''
      dimension: ''
      name: ''
      value: 0.0
    step:
      unit: ''
      dimension: ''
      name: ''
      value: 0.0
    sequence: ''
    controller: ''
    power_supply: ''
  background:
    field:
      unit: ''
      dimension: ''
      name: ''
      value: 0.0
    occurrence: null
    polarisation: ''
    intensity:
      unit: ''
      dimension: ''
      name: ''
      value: 0.0
  bridge:
    model: ''
    controller: ''
    attenuation:
      unit: ''
      dimension: ''
      name: ''
      value: 0.0
    power:
      unit: ''
      dimension: ''
      name: ''
      value: 0.0
    detection: ''
    frequency_counter: ''
    mw_frequency:
      unit: ''
      dimension: ''
      name: ''
      value: 0.0
  video_amplifier:
    bandwidth:
      unit: ''
      dimension: ''
      name: ''
      value: 0.0
    amplification:
      unit: ''
      dimension: ''
      name: ''
      value: 0.0
  recorder:
    model: ''
    averages: null
    time_base:
      unit: ''
      dimension: ''
      name: ''
      value: 0.0
    bandwidth:
      unit: ''
      dimension: ''
      name: ''
      value: 0.0
    pretrigger:
      unit: ''
      dimension: ''
      name: ''
      value: 0.0
    coupling: ''
    impedance:
      unit: ''
      dimension: ''
      name: ''
      value: 0.0
    sensitivity:
      unit: ''
      dimension: ''
      name: ''
      value: 0.0
  probehead:
    type: ''
    model: ''
    coupling: ''
  pump:
    type: ''
    model: ''
    wavelength:
      unit: ''
      dimension: ''
      name: ''
      value: 0.0
    power:
      unit: ''
      dimension: ''
      name: ''
      value: 0.0
    repetition_rate:
      unit: ''
      dimension: ''
      name: ''
      value: 0.0
    tunable_type: ''
    tunable_model: ''
    tunable_dye: ''
    tunable_position: null
    filter: ''
history: []
analyses: []
annotations: []
representations: []
id: ''
label: ''
references: []
tasks: []
time_stamp:
  calculated: false
  data:
    type: numpy.ndarray
    dtype: float64
    array: []
  axes:
  - quantity: ''
    symbol: ''
    unit: ''
    label: ''
    values:
      type: numpy.ndarray
      dtype: float64
      array: []
  - quantity: ''
    symbol: ''
    unit: ''
    label: ''
    values:
      type: numpy.ndarray
      dtype: float64
      array: []
microwave_frequency:
  calculated: false
  data:
    type: numpy.ndarray
    dtype: float64
    array: []
  axes:
  - quantity: ''
    symbol: ''
    unit: ''
    label: ''
    values:
      type: numpy.ndarray
      dtype: float64
      array: []
  - quantity: ''
    symbol: ''
    unit: ''
    label: ''
    values:
      type: numpy.ndarray
      dtype: float64
      array: []
_origdata:
  calculated: false
  data:
    type: numpy.ndarray
    dtype: float64
    array: []
  axes:
  - quantity: ''
    symbol: ''
    unit: ''
    label: ''
    values:
      type: numpy.ndarray
      dtype: float64
      array: []
  - quantity: ''
    symbol: ''
    unit: ''
    label: ''
    values:
      type: numpy.ndarray
      dtype: float64
      array: []
_package_name: trepr
_history_pointer: -1

Calculated dataset

Entity consisting of calculated data and corresponding metadata. For implementation details, see the API documentation of trepr.dataset.CalculatedDataset and trepr.dataset.CalculatedDatasetMetadata.

data:
  calculated: true
  data:
    type: numpy.ndarray
    dtype: float64
    array: []
  axes:
  - quantity: ''
    symbol: ''
    unit: ''
    label: ''
    values:
      type: numpy.ndarray
      dtype: float64
      array: []
  - quantity: ''
    symbol: ''
    unit: ''
    label: ''
    values:
      type: numpy.ndarray
      dtype: float64
      array: []
metadata:
  calculation:
    type: ''
    parameters: {}
history: []
analyses: []
annotations: []
representations: []
id: ''
label: ''
references: []
tasks: []
_origdata:
  calculated: true
  data:
    type: numpy.ndarray
    dtype: float64
    array: []
  axes:
  - quantity: ''
    symbol: ''
    unit: ''
    label: ''
    values:
      type: numpy.ndarray
      dtype: float64
      array: []
  - quantity: ''
    symbol: ''
    unit: ''
    label: ''
    values:
      type: numpy.ndarray
      dtype: float64
      array: []
_package_name: trepr
_history_pointer: -1