Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ImportError: cannot import name 'ConvBNReLUFusion' from 'torch.quantization.fx.fusion_patterns' #268

Open
huangweiwh opened this issue Apr 15, 2024 · 3 comments

Comments

@huangweiwh
Copy link

When I try to ptq mobilenetv2, I get an error: "ImportError: cannot import name 'ConvBNReLUFusion' from 'torch.quantization.fx.fusion_patterns'"

@corin-lyz
Copy link

Have you solved this problem? I also encountered this problem

@wuchangli
Copy link

wuchangli commented Jun 17, 2024

torch==1.10.0 has this, but the newest torch removed it. How do adapt it to the newest torch?

@ardeal
Copy link

ardeal commented Aug 2, 2024

I am able to solve this problem.

  1. if you install torch 1.10.0, you are not able to install other related packages.
  2. if you run MQBench on the latest torch, you are not able to import those mudules as which is removed by Pytorch.

I have already update this module and run it on the latest torch. The quantization accuracy is also good.

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

No branches or pull requests

4 participants