asteroid icon indicating copy to clipboard operation
asteroid copied to clipboard

Quick fix for XUMX in torch 2.0

Open DavidDiazGuerra opened this issue 1 year ago • 1 comments

Hello!

I know we should ideally rewrite the XUMX model to work with the new torch's complex type, but it is possible to workaround this by just converting the new type to the old format just after calling torch.stft using torch.view_as_real and then converting it back to the new type with torch.view_as_complex before calling to torch.istft (#662) . This is not the ideal solution but I think it would be useful to allow people to keep using XUMX till the model is fully rewrited.

Best, David

DavidDiazGuerra avatar Nov 07 '23 08:11 DavidDiazGuerra

Thank you very much for the PR !

@r-sawata, do you agree ?

mpariente avatar Nov 07 '23 09:11 mpariente

Yea I confirmed this PR and actually tried to run it on my local. It looks having no any problems and will be suitable for future update of PyTorch, so I totally agree with this PR.

Thank you so much for your PR, @DavidDiazGuerra.

Could you merge this to master if you're fine, @mpariente?

r-sawata avatar Mar 18 '24 11:03 r-sawata