Skip to content

Commit fb65d4d

Browse files
committed
Fix MPS
1 parent 72fede0 commit fb65d4d

1 file changed

Lines changed: 2 additions & 3 deletions

File tree

ignite/metrics/gan/fid.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -31,9 +31,8 @@ def fid_score(
3131
except ImportError:
3232
raise ModuleNotFoundError("fid_score requires scipy to be installed.")
3333

34-
mu1, mu2 = mu1.cpu(), mu2.cpu()
35-
sigma1, sigma2 = sigma1.cpu(), sigma2.cpu()
36-
34+
mu1, mu2 = mu1.detach().cpu(), mu2.detach().cpu()
35+
sigma1, sigma2 = sigma1.detach().cpu(), sigma2.detach().cpu()
3736
diff = mu1 - mu2
3837

3938
# Product might be almost singular

0 commit comments

Comments
 (0)