@@ -516,7 +516,7 @@ def __call__(self, X, alpha=None, bytes=False):
516516 # masked values are substituted below; no need to fill them here
517517
518518 if xa .dtype .char in np .typecodes ['Float' ]:
519- np . putmask (xa , xa == 1.0 , 0.9999999 ) #Treat 1.0 as slightly less than 1.
519+ cbook . _putmask (xa , xa == 1.0 , 0.9999999 ) #Treat 1.0 as slightly less than 1.
520520 # The following clip is fast, and prevents possible
521521 # conversion of large positive values to negative integers.
522522
@@ -528,15 +528,15 @@ def __call__(self, X, alpha=None, bytes=False):
528528
529529 # ensure that all 'under' values will still have negative
530530 # value after casting to int
531- np . putmask (xa , xa < 0.0 , - 1 )
531+ cbook . _putmask (xa , xa < 0.0 , - 1 )
532532 xa = xa .astype (int )
533533 # Set the over-range indices before the under-range;
534534 # otherwise the under-range values get converted to over-range.
535- np . putmask (xa , xa > self .N - 1 , self ._i_over )
536- np . putmask (xa , xa < 0 , self ._i_under )
535+ cbook . _putmask (xa , xa > self .N - 1 , self ._i_over )
536+ cbook . _putmask (xa , xa < 0 , self ._i_under )
537537 if mask_bad is not None :
538538 if mask_bad .shape == xa .shape :
539- np . putmask (xa , mask_bad , self ._i_bad )
539+ cbook . _putmask (xa , mask_bad , self ._i_bad )
540540 elif mask_bad :
541541 xa .fill (self ._i_bad )
542542 if bytes :
@@ -927,7 +927,7 @@ def __call__(self, value, clip=None):
927927 mask = (resdat <= 0 )
928928 else :
929929 mask |= resdat <= 0
930- np . putmask (resdat , mask , 1 )
930+ cbook . _putmask (resdat , mask , 1 )
931931 np .log (resdat , resdat )
932932 resdat -= np .log (vmin )
933933 resdat /= (np .log (vmax ) - np .log (vmin ))
0 commit comments