ignorm#
- class diffsptk.GeneralizedCepstrumInverseGainNormalization(cep_order: int, gamma: float = 0, c: int | None = None)[source]#
See this page for details.
- Parameters:
- cep_orderint >= 0
The order of the cepstrum, \(M\).
- gammafloat in [-1, 1]
The gamma parameter, \(\gamma\).
- cint >= 1 or None
The number of filter stages.
References
[1]T. Kobayashi et al., “Spectral analysis using generalized cepstrum,” IEEE Transactions on Acoustics, Speech, and Signal Processing, vol. 32, no. 5, pp. 1087-1089, 1984.
- forward(y: Tensor) Tensor [source]#
Perform cepstrum inverse gain normalization.
- Parameters:
- yTensor [shape=(…, M+1)]
The normalized generalized cepstrum.
- Returns:
- xTensor [shape=(…, M+1)]
The generalized cepstrum.
Examples
>>> x = diffsptk.ramp(1, 4) >>> gnorm = diffsptk.GeneralizedCepstrumGainNormalization(3, c=2) >>> ignorm = diffsptk.GeneralizedCepstrumInverseGainNormalization(3, c=2) >>> x2 = ignorm(gnorm(x)) >>> x2 tensor([1., 2., 3., 4.])
- diffsptk.functional.ignorm(y: Tensor, gamma: float = 0, c: int | None = None) Tensor [source]#
Perform cepstrum inverse gain normalization.
- Parameters:
- yTensor [shape=(…, M+1)]
The normalized generalized cepstrum.
- gammafloat in [-1, 1]
The gamma parameter, \(\gamma\).
- cint >= 1 or None
The number of filter stages.
- Returns:
- outTensor [shape=(…, M+1)]
The generalized cepstrum.