Solved by LeviViana in post #2 
              
              
                No there isn’t a pretty built-in way. 
There are however a lot of ugly ways of doing so. You can, for instance, define torch.pi at run-time: 
import torch
torch.pi = torch.acos(torch.zeros(1)).item() * 2 # which is 3.1415927410125732

You can even modify the __init__.py file (which is located in pri…