FID_IS_infinity icon indicating copy to clipboard operation
FID_IS_infinity copied to clipboard

Imaginary Component Error

Open jonatelintelo opened this issue 1 year ago • 1 comments

I am trying to calculate the FID Infinity for 2000 images. I adjusted the assertion. Now the resulting error is as follows:

File "/ceph/csedu-scratch/project/jlintelo/stargan/get_scores.py", line 39, in evaluate_metrics_matrix
    FID_infinity = calculate_FID_infinity_path('/ceph/csedu-scratch/project/jlintelo/stargan/results/output_statistics.npz', os.path.join(root, model, 'eval', b), 50)
File "/ceph/csedu-scratch/project/jlintelo/stargan/score_infinity.py", line 163, in calculate_FID_infinity_path
    FID = numpy_calculate_frechet_distance(m, s, real_m, real_s)
File "/ceph/csedu-scratch/project/jlintelo/stargan/score_infinity.py", line 425, in numpy_calculate_frechet_distance
    raise ValueError('Imaginary component {}'.format(m))
ValueError: Imaginary component 4.791716326434472e+116

Is this error due to the fact I changed it to 2000 fake images and 2000 real ones? Or is this an issue on the scipy end?(as I have read this can be the case for other FID calculations.)

jonatelintelo avatar Nov 07 '23 16:11 jonatelintelo

pip install scipy==1.11.1

This seems to solve the issue.

vaishnavejp avatar Apr 12 '24 18:04 vaishnavejp