espnet2.layers.augmentation.clipping
Less than 1 minute
espnet2.layers.augmentation.clipping
espnet2.layers.augmentation.clipping(waveform, sample_rate: int, min_quantile: float = 0.0, max_quantile: float = 0.9)
Apply the clipping distortion to the input signal.
- Parameters:
- waveform (torch.Tensor) – audio signal (…, time)
- sample_rate (int) – sampling rate in Hz (not used)
- min_quantile (float) – lower bound on the total percent of samples to be clipped
- max_quantile (float) – upper bound on the total percent of samples to be clipped
- Returns: clipped signal (…, time)
- Return type: ret (torch.Tensor)