as in title. Is it defined?
I need this value in order to implement a custom loss function. Right now I am using:
PI=torch.acos(torch.Tensor([-1]))
Thank you!
as in title. Is it defined?
I need this value in order to implement a custom loss function. Right now I am using:
PI=torch.acos(torch.Tensor([-1]))
Thank you!
Hi,
You have it in the python math library. But we don’t have a special one in pytorch, you will need to create a tensor with it.
import math
print(torch.Tensor([math.pi]))