W3cubDocs

/NumPy 1.17

numpy.flatiter.index

attribute

flatiter.index

Current flat index into the array.

Examples

>>> x = np.arange(6).reshape(2, 3)
>>> fl = x.flat
>>> fl.index
0
>>> fl.next()
0
>>> fl.index
1

© 2005–2019 NumPy Developers
Licensed under the 3-clause BSD License.
https://docs.scipy.org/doc/numpy-1.17.0/reference/generated/numpy.flatiter.index.html