Saving results in a list without detaching them will not only store the actual tensor but also the entire computation graph if the tensor is still attached to it. It depends on your use case how to “solve” it, as the mentioned usage is not wrong by itself, if you explicitly want to store the computation graphs. If not, then detach the tensor before appending them to a list.