xtensor icon indicating copy to clipboard operation
xtensor copied to clipboard

fancy indexing

Open junghyun-avikus opened this issue 3 years ago • 0 comments

Does xtensor provide a function similar to fancy indexing in numpy?

For example, you can get a numpy array by doing the following

import numpy as np

a = np.random.rand(3, 5)
b = a[[2, 0, 1]]  # fancy indexing

junghyun-avikus avatar Jul 25 '22 08:07 junghyun-avikus