Let's suppose I have an image such that image.shape=(280,280,3)
If I do img[[[1,2],[1,2],[1,2]]].shape, I obtain (2,). But I expected to obtain (2,2,2)...
How can slicing be performed simultaneously on several dimensions in numpy?
https://stackoverflow.com/questions/65746064/multidimensional-indexing-in-numpy-array January 16, 2021 at 10:57AM
没有评论:
发表评论