m3resp.QualityFlag#
- class m3resp.QualityFlag(name, passed, severity, modality=None, category=None, signal_name=None, breath_id=None, breath_ids=None, start_time=None, end_time=None, message=None, value=None, threshold=None, metadata=<factory>)[source]#
The outcome of one quality check against a signal, breath, or run.
A flag covers the whole signal by default. To represent a signal that’s only bad for part of its duration (e.g. good except for a noisy period in the middle), emit one QualityFlag per affected window with start_time/end_time set, rather than a single flag for the whole signal - signal_name ties them all back to the same signal.
A flag about one breath sets breath_id. A flag about several breaths judged together (for example ten breaths marked as a stable stretch, or a set of breaths with gaps between them) sets breath_ids. Set one or the other; setting both, or an empty breath_ids list, raises ValueError. The per-breath steps use the breath’s zero-based position in its breath list as the id (
"0","1", …), the same as for ParameterResult.breath_id.Methods
JSON-serializable representation, one key per field in field order.
Attributes
- Parameters: