dqa.tasks.ml.RandomizeAndSubsample#
- class dqa.tasks.ml.RandomizeAndSubsample(ratio: float = 1, size: int | None = None, **kwargs)#
Randomly subsamples data to a specified relative ratio or absolute size.
Chooses a random sub-array of the input along the axis 0. The corresponding indices are drawn with replacement.
- Parameters:
ratio (float, default=1) – The resulting array has the size ratio * original_size along axis 0.
size (int, default=None) – If specified, this determines the absolute size of the output along axis 0. If None, then the value given for ratio is considered.
Methods
finish
()Can perform actions that are required to clean up after the task has finished, e.g. close network connections etc.
in_out_default
input_output_dataset
input_output_machine
input_output_mode
input_output_name
log
modify_data_row
modify_dataset
modify_dataset_dict
modify_machine
modify_measurement
set_logging_level
transfer_metadata