Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
MAINT: Make setting mask values with scalars faster.
The current implementation assigns the mask value to a.flat, where a is the mask being updated. In the scalar case, that is slower than assigning to a[...], so when a is an instance of int, float, np.bool_, or np.number use that instead.
- Loading branch information