Can i save tuple in tensor?

is there a way to put tuple in tensor?
e.g.
FM = torch.ones(1,4,3,3)
FM[0,0,1,1] = (2,2)

I don’t think we can.

Instead, you may use the tensor list.

FM = [torch.ones(1,4,3,3) for i in range(2)]
FM[0][0,0,1,1] = 2
FM[1][0,0,1,1] = 2

No, tensors are restricted to floats and ints, in varying sizes:

https://pytorch.org/docs/stable/tensor_attributes.html#tensor-attributes-doc