IBM / BadDiffusion

Official repo to reproduce the paper "How to Backdoor Diffusion Models?" published at CVPR 2023
Apache License 2.0
82 stars 5 forks source link

error in CIFAR10 datasets and Celeba-HQ dataset #11

Open LANCEREN opened 10 months ago

LANCEREN commented 10 months ago

Hi, thank you for this interesting work. I was trying to run this code to learn more details about your paper but encountered the following error. For CIFAR10 datasets, it warms "Traceback (most recent call last): File "/home/renge/anaconda3/envs/BadDiff/lib/python3.8/site-packages/datasets/load.py", line 1172, in dataset_module_factory raise e1 from None File "/home/renge/anaconda3/envs/BadDiff/lib/python3.8/site-packages/datasets/load.py", line 1129, in dataset_module_factory raise ConnectionError(f"Couldn't reach '{path}' on the Hub ({type(e).__name__})") ConnectionErrorpython-BaseException : Couldn't reach 'cifar10' on the Hub (ConnectionError)" I think it may be the Internet problem, so I prepared the Celeba-HQ dataset locally in path "./datasets/celeba_hq_256". However, it warms that "Traceback (most recent call last): File "/home/renge/anaconda3/envs/BadDiff/lib/python3.8/site-packages/datasets/data_files.py", line 458, in get_data_patterns_locally return _get_data_files_patterns(resolver) File "/home/renge/anaconda3/envs/BadDiff/lib/python3.8/site-packages/datasets/data_files.py", line 235, in _get_data_files_patterns data_files = pattern_resolver(pattern) File "/home/renge/anaconda3/envs/BadDiff/lib/python3.8/site-packages/datasets/data_files.py", line 276, in _resolve_single_pattern_locally python-BaseException glob_iter = [PurePath(filepath) for filepath in fs.glob(pattern) if fs.isfile(filepath)] File "/home/renge/anaconda3/envs/BadDiff/lib/python3.8/site-packages/fsspec/spec.py", line 606, in glob pattern = glob_translate(path + ("/" if ends_with_sep else "")) File "/home/renge/anaconda3/envs/BadDiff/lib/python3.8/site-packages/fsspec/utils.py", line 734, in glob_translate raise ValueError( ValueError: Invalid pattern: '**' can only be an entire path component". I cannot understand what happened in "datasets" module and function "load_dataset", could you help me please?

LANCEREN commented 10 months ago

微信截图_20231215120019 微信图片_20231215120055

FrankCCCCC commented 10 months ago

Hello, thank you for your interests. However, I cannot reprodued your issue. Could you give me your environment and commends?