Hi I want to make the following tensor
tensor([[1., 1., 1., 1., 1.],
[2., 2., 2., 2., 2.],
[3., 3., 3., 3., 3.],
[4., 4., 4., 4., 4.],
[5., 5., 5., 5., 5.],
[6., 6., 6., 6., 6.]])
to
tensor([[1., 1., 1., 1., 1., 4., 4., 4., 4., 4.]
[2., 2., 2., 2., 2., 5., 5., 5., 5., 5.],
[3., 3., 3., 3., 3., 6., 6., 6., 6., 6.]])
I tried to do with view, but failed to do so. I want to do it so that I can compute backward() on the tensor.
Can anyone help?