fix grad flow

This commit is contained in:
Luciferian Ink 2025-01-18 02:02:56 -06:00
parent 5adf1c7133
commit 1ca0e04004

View file

@ -540,7 +540,7 @@ class Patcher:
if self.log_time:
s = time.time()
if entropies is not None:
scores = entropies.clone().detach().to(dtype=torch.float32)
scores = entropies.to(dtype=torch.float32)
elif preds is not None:
scores = entropy(preds)
else: