espnet2.layers.augmentation.contrast
Less than 1 minute
espnet2.layers.augmentation.contrast
espnet2.layers.augmentation.contrast(waveform, sample_rate: int = 16000, enhancement_amount: float = 75.0)
Apply contrast effect to the input signal to make it sound louder.
- Parameters:
- waveform (torch.Tensor) – audio signal (…, time)
- sample_rate (int) – sampling rate in Hz (not used)
- enhancement_amount (float) – controls the amount of the enhancement Allowed range of values for enhancement_amount : 0-100 Note that enhancement_amount = 0 still gives a significant contrast enhancement.
- Returns: filtered signal (…, time)
- Return type: ret (torch.Tensor)