File tree Expand file tree Collapse file tree 1 file changed +4
-8
lines changed Expand file tree Collapse file tree 1 file changed +4
-8
lines changed Original file line number Diff line number Diff line change @@ -328,11 +328,9 @@ def transform(self, a):
328328 masked = ma .masked_inside (a , - self .linthresh , self .linthresh , copy = False )
329329 log = sign * self .linthresh * (1 + ma .log (np .abs (masked ) / self .linthresh ))
330330 if masked .mask .any ():
331- return np .asarray (ma .where (masked .mask ,
332- a ,
333- log ))
331+ return ma .where (masked .mask , a , log )
334332 else :
335- return np . asarray ( log )
333+ return log
336334
337335 def inverted (self ):
338336 return SymmetricalLogScale .InvertedSymmetricalLogTransform (self .base , self .linthresh )
@@ -355,11 +353,9 @@ def transform(self, a):
355353 masked = ma .masked_inside (a , - self .linthresh , self .linthresh , copy = False )
356354 exp = sign * self .linthresh * ma .exp (sign * masked / self .linthresh - 1 )
357355 if masked .mask .any ():
358- return np .asarray (ma .where (masked .mask ,
359- a ,
360- exp ))
356+ return ma .where (masked .mask , a , exp )
361357 else :
362- return np . asarray ( exp )
358+ return exp
363359
364360 def __init__ (self , axis , ** kwargs ):
365361 """
You can’t perform that action at this time.
0 commit comments