Solved by colesbury in post #2 
              
              
                Most of the core PyTorch functions on the torch package and on torch.Tensor are generated from Declarations.yaml (*) using gen_python_functions.cpp. The generated files look like: 
python_torch_functions.cpp 
python_variable_methods.cpp 
We don’t use pybind11 here for a few reasons: 

We need to dis…