The sample_rate parameter must be supplied when perceptual_weighting = True
This module requires that pred and target are batched stereo tensors of shape (batch size, 2, seq_len)
This creates a breaking change since we are removing the default values for fft_sizes, hop_sizes, and win_lens. This is to reduce potential errors by using the default values, which may not be optimal for all audio sampling rates.
If you are using mel or perceptual_weighting you will need to move the loss function to the save device as the model. Need to make a note of this in the README with some examples.
This should enable the use of simple A-weighting as a pre-filtering process before computing the sum and difference signals.
Example usage:
Notes:
sample_rate
parameter must be supplied whenperceptual_weighting = True
pred
andtarget
are batched stereo tensors of shape (batch size, 2, seq_len)fft_sizes
,hop_sizes
, andwin_lens
. This is to reduce potential errors by using the default values, which may not be optimal for all audio sampling rates.