mt_metadata.processing.aurora.run

Classes

Run

Base class for all metadata objects with Pydantic validation.

Module Contents

class mt_metadata.processing.aurora.run.Run(**data)

Bases: mt_metadata.base.MetadataBase

Base class for all metadata objects with Pydantic validation.

MetadataBase extends DotNotationBaseModel (which inherits from Pydantic’s BaseModel) to provide automatic validation according to metadata standards. It adds functionality beyond dictionaries, supporting JSON, XML, pandas Series, and other formats for metadata interchange.

_skip_equals

Private attribute listing fields to skip in equality comparisons

Type:

list[str]

_fields

Private attribute caching field information

Type:

dict[str, Any]

Notes

  • All field assignments are validated automatically via Pydantic

  • None values are converted to appropriate defaults (empty string or 0.0)

  • Supports nested attribute access via dot notation

  • Thread-safe for read operations after initialization

id: Annotated[str, Field(default='', description='run ID', alias=None, json_schema_extra={'units': None, 'required': True, 'examples': ['001']})]
input_channels: Annotated[list[mt_metadata.processing.aurora.channel.Channel], Field(default_factory=list, description='List of input channels (source)', alias=None, json_schema_extra={'units': None, 'required': True, 'examples': ['hx, hy']})]
output_channels: Annotated[list[mt_metadata.processing.aurora.channel.Channel], Field(default_factory=list, description='List of output channels (response)', alias=None, json_schema_extra={'units': None, 'required': True, 'examples': ['ex, ey, hz']})]
time_periods: Annotated[list[mt_metadata.common.TimePeriod], Field(default_factory=list, description='List of time periods to process', alias=None, json_schema_extra={'units': None, 'required': True, 'examples': ["[{'start': '2020-01-01T00:00:00', 'end': '2020-01-01T01:00:00'}]"]})]
sample_rate: Annotated[float, Field(default=1.0, description='sample rate of the run', alias=None, json_schema_extra={'units': 'samples per second', 'required': True, 'examples': ['1']})]
classmethod validate_channel_list(values, info)
classmethod validate_time_periods(values, info)
property channel_scale_factors: dict[str, float]
set_channel_scale_factors(values)

Validate and process channel scale factors.

Parameters:

values (Union[dict, float]) – The scale factors for the channels.

Raises:

TypeError – If the input is not a dictionary or float.

property input_channel_names: list[str]

list of channel names

property output_channel_names: list[str]

list of channel names