If you are using just PyTorch functions, Autograd will be able to create the backward pass automatically. However, if you are using plain Python or bumpy methods, you might break the computation graph, which will stop the backward pass.
Which methods are you using, which are not implemented in PyTorch?