Technical skills > PyTorch | Basics | Priority > Flashcards
For a 2x2 outputs object, what will this code do? predictions = torch.nn.functional.softmax(outputs.logits, dim=-1)
pytorch hugging-face
Softmax along the columns (here, the -1 dim) to produce probabilities across columns.
Source