I’m not sure how the julia package relates to PyTorch. Could you explain your use case a bit more and how PyTorch interacts with it? Based on your code it seems you are not using PyTorch at all or am I missing something?