Harry24k/adversarial-attacks-pytorch

FileNotFoundError: [WinError 3] The system cannot find the path specified: './data/imagenet'

tryingmybest99 opened this issue · 1 comments

❔ Any questions

I was trying to implement the White-box Attack on ImageNet but got this error. FileNotFoundError: [WinError 3] The system cannot find the path specified: './data/imagenet' I currently only have the imagenet_class_index.json
in my data folder, may I know where to get the files for imagenet? Thanks in advance!

Hi @tryingmybest99 , you can download it from here https://www.image-net.org/download.php

I just found a way to download it, this way you don't need to log in 😁.

wget https://image-net.org/data/ILSVRC/2012/ILSVRC2012_img_train.tar --no-check-certificate
wget https://image-net.org/data/ILSVRC/2012/ILSVRC2012_img_val.tar --no-check-certificate
wget https://image-net.org/data/ILSVRC/2012/ILSVRC2012_devkit_t12.tar.gz --no-check-certificate

If you prefer to use BT downloads, here are sites that offer them.

Training Set ILSVRC2012_img_train.tar:
https://academictorrents.com/details/a306397ccf9c2ead27155983c254227c0fd938e2

Validation Set ILSVRC2012_img_val.tar:
https://academictorrents.com/details/5d6d0df7ed81efd49ca99ea4737e0ae5e3a5f2e5

But file ILSVRC2012_devkit_t12.tar.gz there still needs to be downloaded from the official website mentioned above, which is not included in this BT site.

wget https://image-net.org/data/ILSVRC/2012/ILSVRC2012_devkit_t12.tar.gz --no-check-certificate

And the pytorch example https://pytorch.org/vision/main/generated/torchvision.datasets.ImageNet.html

Here are some backups of mirror sites, you can pick a fast one to download.

https://s3.amazonaws.com/yaroslavvb/ILSVRC2012_img_val.tar
https://image-net.org/challenges/LSVRC/2012/nonpub/ILSVRC2012_img_val.tar
http://www.image-net.org/challenges/LSVRC/2012/nonpub/ILSVRC2012_img_val.tar
https://archive.org/download/ILSVRC2012_img_train.tar/ILSVRC2012_img_train.tar