阅读背景:

Numpy 2d数组,选择满足2个数组条件的索引

来源:互联网 

I have two 3x3 arrays. One of them indicates if an element is black (let's say 0's - white, 1's black) and another what is the cost of an element. Is there a nice way to get indices of for example all elements that are black and their price is higher than certain value? I know I can use np.where() to select from one array, but how to do it on two (if they have the same shapes)I have two 3x3 arrays. One of them indicates if




你的当前访问异常,请进行认证后继续阅读剩余内容。

分享到: