Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

setting kwrags silent for tqdm progress bar in kernelshap #803

Open
SarahAlidoost opened this issue Jun 18, 2024 · 0 comments · May be fixed by #811
Open

setting kwrags silent for tqdm progress bar in kernelshap #803

SarahAlidoost opened this issue Jun 18, 2024 · 0 comments · May be fixed by #811
Assignees
Labels
enhancement New feature or request

Comments

@SarahAlidoost
Copy link
Contributor

The method kernelshap generates a tqdm progress bar, see here. It is useful to be able to hide the progress bar if explainer should be run several times. The original method has a kwargs silent to hide tqdm progress bar, see here. However, it is not possible to pass this argument through dianna because of the get_kwargs_applicable_to_function (in this function args is only inspected. The args attribute contains a list of positional arguments and keyword arguments, but it does not include **kwargs-style arguments.).

To address the issue, we can add silent: bool = False, to __init__ function of KERNELSHAPTabular and pass it to self.explainer.shap_values as self.explainer.shap_values(input_tabular, silent=self.silent, **explain_instance_kwargs)

@SarahAlidoost SarahAlidoost added the enhancement New feature or request label Jun 18, 2024
@SarahAlidoost SarahAlidoost linked a pull request Jun 26, 2024 that will close this issue
@SarahAlidoost SarahAlidoost self-assigned this Jul 3, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant