Skip to content

Commit

Permalink
flake8 E125/W292 bestpractice reviewed
Browse files Browse the repository at this point in the history
  • Loading branch information
giandos200 committed Jan 15, 2022
1 parent 00dda52 commit 92fda2c
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions dice_ml/explainer_interfaces/explainer_base.py
Original file line number Diff line number Diff line change
Expand Up @@ -191,8 +191,8 @@ def check_query_instance_validity(self, features_to_vary, permitted_range, query

if feature not in features_to_vary and permitted_range is not None:
if feature in permitted_range and feature in self.data_interface.continuous_feature_names:
if not permitted_range[feature][0] <= query_instance[feature].values[0] <= permitted_range[feature][
1]:
if not permitted_range[feature][0] <= query_instance[feature].values[0] <= permitted_range[feature][\
1]:
raise ValueError("Feature:", feature,
"is outside the permitted range and isn't allowed to vary.")
elif feature in permitted_range and feature in self.data_interface.categorical_feature_names:
Expand Down Expand Up @@ -731,4 +731,4 @@ def _check_any_counterfactuals_computed(self, cf_examples_arr):
break
if no_cf_generated:
raise UserConfigValidationException(
"No counterfactuals found for any of the query points! Kindly check your configuration.")
"No counterfactuals found for any of the query points! Kindly check your configuration.")

0 comments on commit 92fda2c

Please sign in to comment.