Skip to content

Commit

Permalink
Optimized 'Domain._valid_value_mask(X, where)' method
Browse files Browse the repository at this point in the history
  • Loading branch information
vruusmann committed Dec 5, 2023
1 parent 4625273 commit d2f7a28
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions sklearn2pmml/decoration/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -115,8 +115,7 @@ def is_missing(X, missing_value):
return pandas.isnull(X)

def _valid_value_mask(self, X, where):
mask = numpy.full(X.shape, True, dtype = bool)
return numpy.logical_and(mask, where)
return where

def _transform_missing_values(self, X, where):
if self.missing_value_treatment == "return_invalid":
Expand Down

0 comments on commit d2f7a28

Please sign in to comment.