list of tensors into tensors

Viewed 937

I have a list like

xs = [tensor1, tensor2, tensor3....]

I want to change it into a tensor so that I can feed xs and ys into the Pytorch DataLoader. I tried this,

xs = torch.Tensor(xs)

but it doesn't work as the individual elements are not items but tensors.

1 Answers
Related