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

Cleanup Parallel Backend #529

Merged
merged 21 commits into from
Mar 26, 2024
Merged

Cleanup Parallel Backend #529

merged 21 commits into from
Mar 26, 2024

Conversation

AnesBenmerzoug
Copy link
Collaborator

@AnesBenmerzoug AnesBenmerzoug commented Mar 20, 2024

Description

This PR closes #360 #535 #536 and addresses part of #385

Changes

  • Adapted docstrings and code to rely on user to configure joblib and initialize ray with desired parameters.
  • Set minimum version of joblib to 1.3.0 in order to support parallel_config context manager.
  • Deprecated most fields of ParallelConfig except for backend in preparation for removing it altogether in favour of letting the user instantiate the parallel backend instance and passing it to the method.
  • Moved parallelization and caching documentation to separated advanced usage page and expanded it.
  • Fixed caching and dask influence calculator docstrings.

Checklist

  • Wrote Unit tests (if necessary)
  • Updated Documentation (if necessary)
  • Updated Changelog
  • If notebooks were added/changed, added boilerplate cells are tagged with "tags": ["hide"] or "tags": ["hide-input"]

@AnesBenmerzoug AnesBenmerzoug self-assigned this Mar 20, 2024
@mdbenito mdbenito added the cleanup when code is ugly or unreadable and needs restyling label Mar 21, 2024
@mdbenito mdbenito added this to the v0.9.0 milestone Mar 21, 2024
Copy link
Collaborator

@mdbenito mdbenito left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cool. Simple is always better 👍🏽 I left a few minor comments and a few questions. Maybe we can talk on Monday about how the final usage pattern will look like?

src/pydvl/utils/caching/disk.py Outdated Show resolved Hide resolved
docs/getting-started/advanced-usage.md Outdated Show resolved Hide resolved
docs/getting-started/advanced-usage.md Outdated Show resolved Hide resolved
docs/getting-started/advanced-usage.md Outdated Show resolved Hide resolved
docs/getting-started/advanced-usage.md Outdated Show resolved Hide resolved
docs/getting-started/advanced-usage.md Outdated Show resolved Hide resolved
docs/getting-started/advanced-usage.md Outdated Show resolved Hide resolved
tests/value/shapley/test_montecarlo.py Show resolved Hide resolved
src/pydvl/parallel/backends/joblib.py Show resolved Hide resolved
tests/utils/test_caching.py Show resolved Hide resolved
mdbenito
mdbenito previously approved these changes Mar 26, 2024
Copy link
Collaborator

@mdbenito mdbenito left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looking good 👍🏽

docs/getting-started/first-steps.md Outdated Show resolved Hide resolved
src/pydvl/parallel/config.py Show resolved Hide resolved
@AnesBenmerzoug AnesBenmerzoug merged commit 3705f0d into develop Mar 26, 2024
23 checks passed
@mdbenito mdbenito deleted the cleanup/parallel-backend branch March 26, 2024 17:58
@mdbenito mdbenito linked an issue Mar 26, 2024 that may be closed by this pull request
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cleanup when code is ugly or unreadable and needs restyling
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add options to ray.remote in MapReduce and add num_cpus, num_gpus explicitly clearification.
2 participants