spacetelescope / stcal

https://stcal.readthedocs.io/en/latest/
Other
10 stars 32 forks source link

JP-3678: Ensure C extension works with multiprocessing #268

Closed kmacdonald-stsci closed 3 months ago

kmacdonald-stsci commented 4 months ago

Resolves JP-3678

Closes #8618

This PR addresses an error in multiprocessing with the selection of the OLS_C algorithm. The C extension flag was not properly passed to the sliced data when prepared for multiprocessing, so the old python code ran, even the the C extension was selected. The C extension selection is now properly passed to the sliced data, so the C extension will be run when multiprocessing is selected.

Checklist

codecov[bot] commented 4 months ago

Codecov Report

Attention: Patch coverage is 55.55556% with 4 lines in your changes missing coverage. Please review.

Project coverage is 83.76%. Comparing base (5772579) to head (8c92688). Report is 180 commits behind head on main.

Files with missing lines Patch % Lines
src/stcal/ramp_fitting/ols_fit.py 57.14% 3 Missing :warning:
src/stcal/ramp_fitting/ramp_fit.py 0.00% 1 Missing :warning:
Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #268 +/- ## ========================================== - Coverage 83.79% 83.76% -0.03% ========================================== Files 35 35 Lines 6998 7004 +6 ========================================== + Hits 5864 5867 +3 - Misses 1134 1137 +3 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

kmacdonald-stsci commented 4 months ago

Running a regression test:

https://plwishmaster.stsci.edu:8081/job/RT/job/JWST-Developers-Pull-Requests/1576/

melanieclarke commented 4 months ago

I forgot to mention - I looked at the regression tests that failed and they are unrelated. These three tests seem to intermittently fail fairly often (test_nirspec_missing_msa_fail, test_nirspec_missing_msa_nofail, and test_duplicate_names).

nden commented 4 months ago

I started another test run - the previous one did not pick up the correct commit and did not test the changes in this PR. https://plwishmaster.stsci.edu:8081/job/RT/job/JWST-Developers-Pull-Requests/1579/

Failures are unrelated.