like this:
>> arr = np.array([[0, 50], [100, 150], [200, 250]])
>>> values = [100, 200, 300]
>>> arr in values
expect:
array([[False, False],
[ True, False],
[ True, False]])
result:
ValueError: The truth value of an array with more than one element is ambiguous. Use a.any() or a.all()
I wrote following code and it works, but this code cannot accept changing length of list
(arr==values[0]) | (arr==values[1]) | (arr==values[2])
np.isin(arr,values)