NVlabs / LSGM

The Official PyTorch Implementation of "LSGM: Score-based Generative Modeling in Latent Space" (NeurIPS 2021)
Other
340 stars 49 forks source link

Precomputing feature statistics: No module named 'fid' #17

Open fikry102 opened 8 months ago

fikry102 commented 8 months ago

I use the following command: python scripts/precompute_fid_statistics.py --data data/cifar10 --dataset cifar10 --fid_dir fid_stats_dir

  File "scripts/precompute_fid_statistics.py", line 9, in <module>
    from fid.fid_score import compute_statistics_of_generator, save_statistics
ModuleNotFoundError: No module named 'fid'

How to solve this problem?

After I move "precompute_fid_statistics.py" out of the folder "scripts", everything is okay:

Files already downloaded and verified
Files already downloaded and verified
len train queue 782 len val queue 157 batch size 64
Downloading: "https://github.com/mseitzer/pytorch-fid/releases/download/fid_weights/pt_inception-2015-12-05-6726825d.pth" to fid_stats_dir/pt_inception-2015-12-05-6726825d.pth
100.0%
Starting to sample.