remove .cpu()

This commit is contained in:
hoshi-hiyouga authored and GitHub committed 2024-09-02 10:10:53 +08:00
1 parent 60fc6b926e
commit a6c6750e8a
1 file changed
+1 -1
+1 -1
View File
@@ -54,7 +54,7 @@ def eval_logit_processor(logits: "torch.Tensor", labels: "torch.Tensor") -> "tor
if logits.dim() != 3:
raise ValueError("Cannot process the logits.")
return torch.argmax(logits, dim=-1).cpu()
return torch.argmax(logits, dim=-1)
@dataclass