Skip to content

AttributeError: module 'torch' has no attribute 'rfft' in #254

@PunnawatSiri

Description

@PunnawatSiri

Thank you for your work. While I tried to use it, I got this error:

File "/usr/local/lib/python3.11/dist-packages/IQA_pytorch/FSIM.py", line 81, in phasecong2 imagefft = torch.rfft(im,2,onesided=False) ^^^^^^^^^^ File "/usr/local/lib/python3.11/dist-packages/torch/__init__.py", line 2681, in __getattr__ raise AttributeError(f"module '{__name__}' has no attribute '{name}'") AttributeError: module 'torch' has no attribute 'rfft'

My setup :
IQA-pytorch 0.1
torch 2.6.0+cu124

After some research I found that I need to degrade torch to torch==1.7.1 , but pip doesn't support this version anymore.
Would it be convenient for you to support newer version of torch?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions