Solved by albanD in post #2 
              
              
                If your want to backprop through all these, then you need to have them. 
An alternative is to trade memory for compute using the torch.utils.checkpoint module.