Skip to content

Pytorch 1.8 and 1.9 compatibility#1

Open
jbojar wants to merge 2 commits into
masterfrom
pytorch-1.9.0-compatibility
Open

Pytorch 1.8 and 1.9 compatibility#1
jbojar wants to merge 2 commits into
masterfrom
pytorch-1.9.0-compatibility

Conversation

@jbojar
Copy link
Copy Markdown
Owner

@jbojar jbojar commented Aug 11, 2021

This version should be compatible with multiple PyTorch versions (it works at least on 1.6.0, 1.7.1, 1.8.1, 1.9.0).

This fix is based on suggestions from this comment zh217#15 (comment) by @SunnerLi and on existing but not fully working PR zh217#21 by @underdogliu.

My version does not use version checking during execution of dct calculation. Instead it tries to import new torch.fft module and conditionally defines three functions using either new or old implementation of FFT. This is done only once, when module is imported.

@jbojar jbojar force-pushed the pytorch-1.9.0-compatibility branch from d2f0005 to 0002278 Compare August 13, 2021 13:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant