[c++] Refine concurrency configuration (soma.compute_concurrency_level)#2978
[c++] Refine concurrency configuration (soma.compute_concurrency_level)#2978bkmartinjr merged 14 commits intomainfrom
soma.compute_concurrency_level)#2978Conversation
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #2978 +/- ##
===========================================
- Coverage 89.73% 61.23% -28.50%
===========================================
Files 39 94 +55
Lines 4080 12530 +8450
Branches 0 786 +786
===========================================
+ Hits 3661 7673 +4012
- Misses 419 4657 +4238
- Partials 0 200 +200
Flags with carried forward coverage won't be shown. Click here to find out more.
|
soma.compute_concurrency_level)
| import numpy as np | ||
|
|
||
| with pytest.raises(tiledbsoma.SOMAError): | ||
| with pytest.raises((tiledbsoma.SOMAError, RuntimeError)): |
There was a problem hiding this comment.
I'll help you fix this -- already done on #2963
TileDB-SOMA/apis/python/src/tiledbsoma/pytiledbsoma.cc
Lines 36 to 45 in c08b5cf
- (one example callsite)
TileDB-SOMA/apis/python/src/tiledbsoma/soma_array.cc
Lines 348 to 352 in c08b5cf
There was a problem hiding this comment.
There was a problem hiding this comment.
Broader issue - filed as sc-54978
|
|
||
|
|
||
| def test_malformed_concurrency_config_value(): | ||
| import numpy as np |
There was a problem hiding this comment.
Why import in the test instead of up top?
There was a problem hiding this comment.
Just trying to isolate test dependencies. But not a major issue either way....
Issue and/or context:
Introduces direct control over the native thread pool concurrency level in SOMA. Previously, it was indirectly controlled by the TileDB Core
sm.compute_currency_controlconfiguration, and would create a thread pool that was 1/2 the size of that value.Changes:
This PR introduces a new context configuration setting:
soma.compute_currency_level, which defaults to the host CPU count. It can be set with an numeric value,eg., in Python:Notes for Reviewer:
sc-54891
the PR also adds: