Can you elibrate your answer? I am not quit understand of the narrow usage. I know there is a slice method of tensor.
I got trouble in slice.
My tensor is size as : [2976, 4], which is 2976 rows and 4 columns.
I want get the first 2 columns:
priors.slice(1, 0, 2)
Got error:
terminate called after throwing an instance of 'std::runtime_error'
what(): invalid argument 0: Sizes of tensors must match except in dimension 0. Got 1 and 2 in dimension 1 at /media/jintain/sg/ai/libs/pytorch/aten/src/THC/generic/THCTensorMath.cu:71