What if the tensor has no elements in it?
How do i solve this?
import torch
x = torch.tensor([])
x = torch.cat((x,3),0)
#outputs an error
Exception has occurred: TypeError
expected Tensor as element 1 in argument 0, but got int
x = torch.cat((x,3),0)
^^^^^^^^^^^^^^^^^^
TypeError: expected Tensor as element 1 in argument 0, but got int