yhhhli / BRECQ

Pytorch implementation of BRECQ, ICLR 2021
MIT License
255 stars 56 forks source link

Quantization doesn't work? #31

Open praneet195 opened 2 years ago

praneet195 commented 2 years ago

Hi,

So I tried running your code on CIFAR-10 with a pre-trained ResNet50 model. I've attached the code below. My accuracy however does not come nearly as close to the float model which is around 93% but after quanitzation: I get:

Please help me with this. The code is inside the zip file.

main_cifar.zip s

mj0219 commented 7 months ago

Hi,

So I tried running your code on CIFAR-10 with a pre-trained ResNet50 model. I've attached the code below. My accuracy however does not come nearly as close to the float model which is around 93% but after quanitzation: I get:

  • Accuracy of the network on the 10000 test images: 10.0 % top5: 52.28 %

Please help me with this. The code is inside the zip file.

main_cifar.zip s

I encountered the same issue when using my pretrained model resnet18 on CIFAR-10 for experiments. The accuracy is only about ten percent. Have you resolved this?