facebookresearch / kill-the-bits

Code for: "And the bit goes down: Revisiting the quantization of neural networks"
Other
636 stars 123 forks source link

已压缩模型进行指定图片测试 #34

Closed findlazygirl closed 4 years ago

findlazygirl commented 4 years ago

作者您好: 看到您的程序中有压缩模型,想请问您已压缩的resnet18可以在自己的指定图片上进行目标分类准确度测试吗?按照您给出的评估语句,python inference.py --model resnet18 --state-dict-compressed models/compressed/resnet18_small_blocks.pth --device cuda --data-path YOUR_IMAGENET_PATH 自己创建的Image文件夹,将指定图片放进去,将YOUR IMAGENET PATH更改为./Image,测试不成功。想请您指点一下,谢谢!

pierrestock commented 4 years ago

Hi @findlazygirl,

Thanks for your interest in our work! Below is what I could understand from your post:

_"Hello author: Seeing that you have a compression model in your program, would you like to ask if your compressed resnet18 can be used to test the accuracy of the target classification on your specified picture? According to the evaluation statement you gave, python inference.py --model resnet18 --state-dict-compressed models / compressed / resnet18_small_blocks.pth --device cuda --data-path YOUR_IMAGENETPATH The Image folder created by yourself, put the specified picture into it, change YOUR IMAGENET PATH to ./Image, the test is not successful. I would like to ask you for your advice, thank you!"

The folder YOUR_IMAGENET_PATH is organized as /train' and '/val' splits, each folder containing classes subfolders with images. So the general organization is '/train_or_val/class/img.jpg.

Hope this helps!

findlazygirl commented 4 years ago

ok.Thank you. 

---原始邮件--- 发件人: "Pierre Stock"<notifications@github.com> 发送时间: 2020年4月28日(周二) 下午4:01 收件人: "facebookresearch/kill-the-bits"<kill-the-bits@noreply.github.com>; 抄送: "Mention"<mention@noreply.github.com>;"findlazygirl"<2848500799@qq.com>; 主题: Re: [facebookresearch/kill-the-bits] 已压缩模型进行指定图片测试 (#34)

Hi @findlazygirl,

Thanks for your interest in our work! Below is what I could understand from your post:

"Hello author: Seeing that you have a compression model in your program, would you like to ask if your compressed resnet18 can be used to test the accuracy of the target classification on your specified picture? According to the evaluation statement you gave, python inference.py --model resnet18 --state-dict-compressed models / compressed / resnet18_small_blocks.pth --device cuda --data-path YOUR_IMAGENET_PATH The Image folder created by yourself, put the specified picture into it, change YOUR IMAGENET PATH to ./Image, the test is not successful. I would like to ask you for your advice, thank you!"

The folder YOUR_IMAGENET_PATH is organized as /train' and '/val' splits, each folder containing classes subfolders with images. So the general organization is '/train_or_val/class/img.jpg.

Hope this helps!

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub, or unsubscribe.