Update model.py

Fixed the indentation of the suggestion.
This commit is contained in:
Pedro Dessanti 2025-01-27 10:36:57 -03:00 committed by GitHub
parent 9bf00671cf
commit c47ecaa800
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -793,6 +793,7 @@ class Transformer(nn.Module):
all_logits = [torch.empty_like(logits) for _ in range(world_size)] all_logits = [torch.empty_like(logits) for _ in range(world_size)]
dist.all_gather(all_logits, logits) dist.all_gather(all_logits, logits)
logits = torch.cat(all_logits, dim=-1) logits = torch.cat(all_logits, dim=-1)
return logits return logits