# Calculate accuracy acc = accuracy(z.argmax(dim=1), data.y)