saftig.evaluation.dataset ========================= .. py:module:: saftig.evaluation.dataset .. autoapi-nested-parse:: A representation of a dataset for the evaluation of noise mitigation methods. Attributes ---------- .. autoapisummary:: saftig.evaluation.dataset.NDArrayF Classes ------- .. autoapisummary:: saftig.evaluation.dataset.EvaluationDataset Module Contents --------------- .. py:data:: NDArrayF .. py:class:: EvaluationDataset(sample_rate, witness_conditioning, target_conditioning, witness_evaluation, target_evaluation, signal_conditioning = None, signal_evaluation = None, name = 'Unnamed', target_unit = '1') A representation of a dataset for the evaluation of noise mitigation methods. Provided sequences will be stored as immutable float64 numpy arrays. :param sample_rate: Sample rate in Hz :param witness_conditioning: witness channel data for the conditioning format: witness_conditioning[sequence_idx][channel_idx][sample_idx] :param target_conditioning: target channel data for the conditioning format: witness_conditioning[sequence_idx][sample_idx] :param witness_evaluation: witness channel data for the evaluation :param target_evaluation: target channel data for the evaluation :param signal_conditioning: (Optional) A signal that can be subtracted from the target for performance metrics :param signal_evaluation: (Optional) A signal that can be subtracted from the target for performance metrics :param name: (Optional) a string describing the dataset .. py:attribute:: sample_rate :type: float .. py:attribute:: witness_conditioning :type: collections.abc.Sequence[collections.abc.Sequence[NDArrayF]] .. py:attribute:: target_conditioning :type: collections.abc.Sequence[NDArrayF] .. py:attribute:: witness_evaluation :type: collections.abc.Sequence[collections.abc.Sequence[NDArrayF]] .. py:attribute:: target_evaluation :type: collections.abc.Sequence[NDArrayF] .. py:attribute:: signal_conditioning :type: collections.abc.Sequence[NDArrayF] | None .. py:attribute:: signal_evaluation :type: collections.abc.Sequence[NDArrayF] | None .. py:attribute:: name :type: str .. py:attribute:: target_unit :type: str .. py:method:: _prepare_dataset(witness_inp, target_inp, signal_inp = None) :staticmethod: Convert input to immutable np.float64 arrays and check shape .. py:method:: get_min_sequence_len(separate = False) Get the length of the shortest sequence in the dataset :param separate: If True, returns the minimum separately for conditioning and evaluation data. .. py:method:: _hash_wts_data(witness, target, signal = None) :staticmethod: Calculate a hash value for a set of witness, target, signal data .. py:method:: hash_bytes() return a hash over the dataset data as a bytes object .. py:method:: __hash__()