Skip to content

Add additional parameters to generate_counterfactuals() function#251

Merged
amit-sharma merged 4 commits intomasterfrom
gaugup/AddAdditionalParamsGenCF
Jan 25, 2022
Merged

Add additional parameters to generate_counterfactuals() function#251
amit-sharma merged 4 commits intomasterfrom
gaugup/AddAdditionalParamsGenCF

Conversation

@gaugup
Copy link
Copy Markdown
Collaborator

@gaugup gaugup commented Dec 1, 2021

It seems the generate_counterfactuals() method in dice_genetic.py support many more arguments than the ones supported in generate_counterfactuals() in explainer_base.py. Adding the additional parameters to generate_counterfactuals() in explainer_base.py.

Signed-off-by: gaugup gaugup@microsoft.com

Signed-off-by: gaugup <gaugup@microsoft.com>
@github-actions
Copy link
Copy Markdown

github-actions Bot commented Dec 1, 2021

Unit Test Results

    1 files  ±0      1 suites  ±0   12m 51s ⏱️ -11s
221 tests ±0  216 ✔️ ±0  5 💤 ±0  0 ±0 

Results for commit 9c4d58b. ± Comparison against base commit e6a1dc3.

♻️ This comment has been updated with latest results.

@amit-sharma
Copy link
Copy Markdown
Collaborator

amit-sharma commented Dec 4, 2021

I like the idea of making it consistent. But the problem is that all methods do not support these parameters. For example, dice_random will ignore categorical_penalty, even if a user sets its value.

For each parameter, shall we write in the docstring on which algorithms support it? Would that be a good way to communicate this? If that sounds good, I'm happy to edit the docstring with this info.

@gaugup
Copy link
Copy Markdown
Collaborator Author

gaugup commented Dec 6, 2021

I like the idea of making it consistent. But the problem is that all methods do not support these parameters. For example, dice_random will ignore categorical_penalty, even if a user sets its value.

For each parameter, shall we write in the docstring on which algorithms support it? Would that be a good way to communicate this? If that sounds good, I'm happy to edit the docstring with this info.

Sure, please go ahead and add the relevant docstrings.

@amit-sharma
Copy link
Copy Markdown
Collaborator

Okay will add these in the next few days.

@gaugup gaugup linked an issue Jan 3, 2022 that may be closed by this pull request
@amit-sharma amit-sharma merged commit 8c92630 into master Jan 25, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

How to improve counterfactuals

2 participants