Add the SPEX approximator to shapiq#379
Conversation
…ctionValues, and added SMT
Moved all parameters to the init. added support for soft vs. hard parameter passed by user.
…ctions in sparse-transform
sparse approximator base passing tests
added tests for approximate -- all failing
first approximate test now passing
added more tests for approximate
…he base of next pypi release
# Conflicts: # docs/source/notebooks/language_notebooks/language_model_game.ipynb # docs/source/notebooks/vision_notebooks/vision_transformer.ipynb # shapiq/approximator/__init__.py # shapiq/approximator/_base.py # shapiq/game_theory/indices.py # shapiq/games/benchmark/_setup/_vit_setup.py # shapiq/games/benchmark/local_xai/benchmark_image.py
|
@justinkang221 amazing what you guys did here! ❤️ I will go through the PR as soon as possible! |
|
Sounds good @mmschlk. One thing I wanted to highlight is that I added "sparse-transform" and "galois" to the dependencies. I know you mentioned you wanted to mark them as optional, so feel free to make that change, I wasn't sure how best to handle it. |
mmschlk
left a comment
There was a problem hiding this comment.
This is so super nice! I don't see any reason why we should not merge directly! The only thing, I would add is a tutorial/introduction notebook which goes a bit beyond the current additions to the existing notebooks. But this I think we can tackle also at a later date. :)
It seems like the dependencies are pretty lightweight and seem to install already in all python versions in the tests. So I would leave it as is for now and monitor how it goes. :) |
|
I will do minor things like adding it to changelog and adding your method more prominently into the docs next. |
This pull request adds the SPEX method for computing attributions over large input spaces with up to$n \approx 1000$ features. SPEX was developed at UC Berkeley, and uses ideas from information and coding theory to ensure fast and efficient computation of interactions.
The article detailing the SPEX algorithm is available here:
https://arxiv.org/pdf/2502.13870
A version of this article will appear at ICML 2025.