I am running a deep network on GPU so ideally all of my code should work effeciently under GPU (so torch rather than numpy) and I am trying to round the tensor values with torch.round()
but the result is not expected:
testing_value = torch.tensor(3.440000057220459)
torch.round(testing_value, decimals = 2)
this output results tensor(3.4400)
, but shouldn't it be tensor(3.44)
?
How can I fix this?