Process

class openmsimodel.entity.base.process.Process(name: str, *, template: ClassVar[ProcessTemplate | MeasurementTemplate] = None, notes: str | None = None, conditions: list[Condition] | None = None, parameters: list[Parameter] | None = None, which: Literal['spec', 'run', 'both'] = 'spec')

Bases: ProcessOrMeasurement

Base element for processes.

property spec: ProcessSpec

The underlying process spec.

property run: ProcessRun

The underlying process run.

classmethod from_spec_or_run(name: str, *, notes: str | None = None, spec: ProcessSpec = None, run: ProcessRun = None) Process

Instantiate a Process from a spec or run with appropriate validation.

Note that the spec’s template will be set to the class template, and the run’s spec will be set to this spec.