SciPy

numpy.ma.masked_array.flat

attribute

masked_array.flat

Return a flat iterator, or set a flattened version of self to value.