-
Notifications
You must be signed in to change notification settings - Fork 428
Make multiprocessing calls aware of parallelism used during testing #1404
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
Merged
+657
−295
Merged
Changes from all commits
Commits
Show all changes
44 commits
Select commit
Hold shift + click to select a range
84d55b2
Move conftest.py to the top level
mhucka 021f05c
Add pytest fixture to set threadpool limits
mhucka ca38653
Count available CPU resources more carefully
mhucka 0967fef
Add unit tests for new cpu counting code
mhucka 632ec44
Make type ignore comments more specific
mhucka af3d4d8
Ignore not found import
mhucka 98c417d
Update src/openfermion/utils/operator_utils_test.py
mhucka 259e36e
Fix error in worker calculation
mhucka ac2cdf8
Format
mhucka f5b7795
Move `get_available_cpu_count()` to config.py
mhucka 0031a24
Set MKL_NUM_THREADS before loading numpy and others
mhucka 173c1ec
Resolve pylint errors about import order
mhucka 0f8e91e
Merge branch 'main' into control-multiprocessing
mhucka f08ba34
Update src/openfermion/resource_estimates/thc/utils/thc_factorization.py
mhucka d0d1702
Update src/openfermion/resource_estimates/thc/utils/thc_objectives.py
mhucka a288b96
Fix merge conflicts
mhucka 40ba3e8
Set OMP_NUM_THREADS and OPENBLAS_NUM_THREADS too
mhucka a957806
Update src/openfermion/config.py
mhucka 8a278ee
Avoid inefficiency when num processes < 1
mhucka 2768ebb
Update src/openfermion/config.py
mhucka 6f8fdff
Set threading limits here too
mhucka 81ae963
Add more test coverage
mhucka 1832e6e
Update `CONTRIBUTING.md` and fix errors
mhucka b51b431
Don't pass --jobs=0 to pylint by default
mhucka 61c3b0a
Don't pass `-n auto` by default and update script
mhucka aa6d637
Set the thread variables unconditionally
mhucka 02c4392
Take out conditional setting of the threads variables
mhucka 3918f93
Change handling of parallelism in check/all
mhucka 7914648
Add threadpoolctl to the pytest dependencies
mhucka db7309b
Use different number of items for affinity test
mhucka e6fa64f
Regenerate requirements files
mhucka 43ec834
Use self.qubit_operator
mhucka b49816c
Be more DRY
mhucka 09ec544
Be more DRY
mhucka e682c5e
Fix typo
mhucka 11a2e48
Merge branch 'main' into control-multiprocessing
mhucka e1c0cbc
Do not set pylint "jobs" in `.pylintrc`
mhucka 2cb9c14
Make check/pylint print something when it's successful
mhucka 74d65ce
Add psutil to pytest dependencies
mhucka a9bbf02
Add parallelism option to mypy
mhucka f329f9f
Print a more noticeable "running ABC" message
mhucka a6fd00e
Make check/shellcheck print something when it's successful
mhucka 8e50d3c
Tell people about the `-j 0` option
mhucka 7f36f75
Regenerate requirements files after change to pytest.txt
mhucka File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.