Skip to content

[6.40] [tmva][sofie] Drop NumPy C API dependency from SOFIE parsers#22581

Merged
guitargeek merged 1 commit into
root-project:v6-40-00-patchesfrom
root-project-bot:BP_6.40_pull_22566
Jun 11, 2026
Merged

[6.40] [tmva][sofie] Drop NumPy C API dependency from SOFIE parsers#22581
guitargeek merged 1 commit into
root-project:v6-40-00-patchesfrom
root-project-bot:BP_6.40_pull_22566

Conversation

@root-project-bot

Copy link
Copy Markdown

Backport of #22566, requested by @guitargeek.

The PyTorch parser and the parser unit tests included
`<numpy/arrayobject.h>` and linked against `Python3::NumPy` purely to
read tensor shapes and data pointers
(`PyArray_NDIM`/`PyArray_DIM`/`PyArray_DATA`). This coupled SOFIE to a
specific NumPy ABI at build/link time, even though NumPy is only ever
needed at runtime to produce the arrays on the Python side.

This commit repaces these uses with the generic CPython API.

(cherry picked from commit f799703)
@guitargeek guitargeek merged commit 6c3b5c3 into root-project:v6-40-00-patches Jun 11, 2026
36 of 38 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants