Thanks for the explanation!
So what should I do if I want to get a 2D tensor from a bunch of 1D tensor? I tried this:

x = Variable(torch.FloatTensor([[1,2],[3,4]]))
z = torch.cat([x[0,1],x[1,0]],0)
y = torch.cat([z,z],1)

But got this:

Traceback (most recent call last):
File “pra.py”, line 86, in 
y = torch.cat([z,z],1)
File “/usr/local/lib/python2.7/site-packages/torch/autograd/variable.py”, line 748, in cat
return Concat(dim)(*iterable)
File “/usr/local/lib/python2.7/site-packages/torch/autograd/_functions/tensor.py”, line 303, in forward
self.input_sizes = [i.size(self.dim) for i in inputs]
RuntimeError: dimension 2 out of range of 1D tensor at /Users/soumith/code/pytorch-builder/wheel/pytorch-src/torch/lib/TH/generic/THTensor.c:24

update:
Never mind, I did that using tensor.unsqueeze().