It depends a bit on your use case and where these tensors are coming from.
Generally you could use:

trainable parameters registering them to the model via nn.Parameter(List)

Non-trainable tensors via self.regiter_buffer (or set the requires_grad attribute of a parameter to False): this would properly register the tensors into the model and they would also show up in the state_dict, so you could save/load them
Non-trainable tensors via self.register_buffer(tensor, persistent=False) which will be registered into the model, but won’t show up in the state_dict

Pass tensors to the forward method (with the right dtype and on the right device


However, if you need to create new tensors in the forward, you could use the .device attribute of any parameter (assuming they are all pushed to the device already). In your use case I don’t know how self.pairs is treated, but as already described a plain list won’t be registered, so you would need to push these tensors to the device manually.