Repository navigation
Fix SliceDataset NumPy copy protocol - #1170
Ganesh1729-ui wants to merge 1 commit into
Conversation
|
Additional validation summary for The added cases fail 24/32 before the fix, with eight controls already passing. |
|
Follow-up for review: this aligns SliceDataset.array with the NumPy copy protocol. copy=None and copy=True materialize independently, while copy=False fails before reading items. The 32 focused regressions distinguish the cases; available cross-version validations are recorded in the PR. |
|
CI follow-up for The NumPy copy-protocol cases and the separate NumPy 1/2 fork validation are linked above. Please approve the upstream test workflow when ready; those fork results are separate from this blocked upstream run. |
|
Thanks for the PR. As maintainers of skorch, we decided to update the status of the skorch project. As a consequence, we will close this PR. Your effort is still appreciated. |
Closes #1169.
Change
Accept
copy=NoneinSliceDataset.__array__following theNumPy migration guide.
Materialization allocates an independent array for
copy=True/None;copy=FalseraisesValueErrorbefore reading items.Add 32 cases for NumPy/Torch vectors/scalars, dtypes, memory independence and
rejection, plus a changelog entry. Protocol deprecations are errors in these tests.
Validation
fixed 1,160 pass, 160 skip, 46 deselect, 1 xfail, with unchanged 45 warnings
and existing L-BFGS retries.
NumPy2 CPU 1,132 → 1,164 passes; NumPy1 affected modules 397 → 409
passes, 24 → 44 skips. A broader NumPy1 run stops at unchanged upstream's
L-BFGS failure before testing the fix. Windows NumPy1 retains 21 baseline
dtype failures (376 → 388 passes).
installed-wheel conversions plus early rejection pass.
HF/LLM, distributed, GPU and the full matrix were not run. Six checkpoint/compile
cases are excluded for previously reproduced Windows path/MSVC limitations.
Existing empty-dataset PR #1168 remains separate.
AI assisted investigation, implementation and testing; no human review is claimed.