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

Semi-values and samplers #319

Merged
merged 65 commits into from
Mar 13, 2023
Merged

Semi-values and samplers #319

merged 65 commits into from
Mar 13, 2023

Conversation

mdbenito
Copy link
Collaborator

@mdbenito mdbenito commented Mar 12, 2023

Description

This PR closes #121, closes #224 and closes #225. It doesn't remove any previous functionality and thus could make it into https://github.com/appliedAI-Initiative/pyDVL/milestone/14 .

Things missing (for other PRs)

Changes

  • Introduces the abc PowersetSampler and several specializations for uniform, antithetic, deterministic, or permutation sampling.
  • Introduces semi-values as the combination of a sampler and a Coefficient, with only one function allowing for all combinations
  • Implements Data Banzhaf and Beta Shapley as particular cases of the above
  • Fixes a bug with boolean operations for StoppingCriterion.completion()
  • Fixes some types here and there
  • Fixes notation in the documentation for permutation Shapley

Checklist

  • Wrote Unit tests (if necessary)
  • Updated Documentation (if necessary)
  • Updated Changelog
  • If notebooks were added/changed, added boilerplate cells are tagged with "nbsphinx":"hidden"

# Conflicts:
#	src/pydvl/value/results.py
# Conflicts:
#	README.md
#	src/pydvl/utils/numeric.py
#	src/pydvl/value/results.py
# Conflicts:
#	src/pydvl/utils/numeric.py
#	src/pydvl/value/loo/naive.py
#	src/pydvl/value/results.py
#	src/pydvl/value/shapley/knn.py
#	src/pydvl/value/shapley/montecarlo.py
#	src/pydvl/value/shapley/naive.py
#	src/pydvl/value/stopping.py
#	tests/test_results.py
#	tests/value/conftest.py
#	tests/value/loo/conftest.py
@mdbenito mdbenito changed the title Feature/sampler Semi-values and samplers Mar 12, 2023
@mdbenito mdbenito added this to the v0.5.1 milestone Mar 12, 2023
@mdbenito mdbenito self-assigned this Mar 12, 2023
@mdbenito mdbenito marked this pull request as ready for review March 12, 2023 16:32
@AnesBenmerzoug
Copy link
Collaborator

According to semver.org, adding new functionality should not go into a patch version. Only backwards compatible bug fixes should be part of it.

This should be split. The bug fixes can be part of 0.5.1 and the rest can be part of 0.6.0

@mdbenito mdbenito merged commit aa8aa46 into develop Mar 13, 2023
@mdbenito mdbenito deleted the feature/sampler branch March 13, 2023 16:33
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
2 participants