imglsadf#

diffsptk.IMLSA#

alias of PseudoInverseMGLSADigitalFilter

class diffsptk.PseudoInverseMGLSADigitalFilter(filter_order, frame_period, **kwargs)[source]#

See PseudoMGLSADigitalFilter() for details.

forward(y, mc)[source]#

Apply an inverse MGLSA digital filter.

Parameters:
yTensor [shape=(…, T)]

Audio signal.

mcTensor [shape=(…, T/P, M+1)]

Mel-generalized cepstrum, not MLSA digital filter coefficients.

Returns:
outTensor [shape=(…, T)]

Residual signal.

Examples

>>> M = 4
>>> y = diffsptk.step(3)
>>> mc = diffsptk.nrand(2, M)
>>> mc
tensor([[ 0.8457,  1.5812,  0.1379,  1.6558,  1.4591],
        [-1.3714, -0.9669, -1.2025, -1.3683, -0.2352]])
>>> imglsadf = diffsptk.IMLSA(M, frame_period=2)
>>> x = imglsadf(y.view(1, -1), mc.view(1, 2, M + 1))
>>> x
tensor([[ 0.4293,  1.0592,  7.9349, 14.9794]])