lets’ say I have a tensor with content:
[0,55,49,38,2,0,96,28,2,0,73,2]
0 is begin of sentence token
2 is end of sentence token
I want to do random sentence permutation as like
[0,73,2,0,55,49,38,2,0,96,28,2]
or
[0,73,2,0,96,28,2,0,55,49,38,2]
how can I do it?
Thanks.