indexof

Index of element in NumPy array

Index of element in NumPy array Question: In Python we can get the index of a value in an array by using .index(). But with a NumPy array, when I try to do: decoding.index(i) I get: AttributeError: ‘numpy.ndarray’ object has no attribute ‘index’ How could I do this on a NumPy array? Asked By: Marc …

Total answers: 6