Skip to content

Tmp merged#42

Open
oliviermattelaer wants to merge 17 commits into
postprocessing_linkingfrom
tmp_merged
Open

Tmp merged#42
oliviermattelaer wants to merge 17 commits into
postprocessing_linkingfrom
tmp_merged

Conversation

@oliviermattelaer

Copy link
Copy Markdown
Contributor

No description provided.

Qubitol and others added 15 commits July 9, 2026 17:08
Truth value is reported in #28.
Processes metadata are reported in
tests/check_xsec_processees/reference.json
Tolerance and number of events can be set on the workflow file.
Especially for testing purposes, we make the workflow runnable when
pushing to the repository.
The systematic cross-section CI self-skipped with
"NNPDF23_lo_as_0130_qed LHAPDF data not found" because it relied on the
NNPDF23 grid being pre-baked into the HEPTools cache, which is not
guaranteed.

The mg7 runtime reads the PDF grid directly from
$LHAPDF_DATA_PATH/<set>/<set>_0000.dat (mg7/madevent.py, ms.PdfGrid), so
it only needs the grid data -- not the LHAPDF C++ library. Add an
install_lhapdf_pdfset composite action that installs the set with the
lhapdf-management package into a cached, writable dir and exports
LHAPDF_DATA_PATH, and wire it into the workflow in place of the fragile
restore_heptools_lhapdf dependency.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Per reviewer request, replace the standalone
run_check_xsec_processes.py driver with a unittest.TestCase
(tests/acceptance_tests/test_check_xsec_processes_mg7.py) that generates
one test_<section>_<id>_mg7 method per process from the reference table,
so the whole suite is discoverable and launchable through
tests/test_manager.py -- the single, locally-runnable entry point used by
the other mg7 acceptance tests.

The tolerance and event count stay settable via the MG7_XSEC_TOLERANCE /
MG7_XSEC_EVENTS environment variables. The workflow now launches each
section with a regexp, e.g.
    ./tests/test_manager.py test_ttx_decay_.*_mg7 -pA -t0
and the reference table moves next to the test as
check_xsec_processes_reference.json.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
FLV coupling definition (single source of truth):
- add base_objects.FLV_Coupling.get_partner_indices() and route the
  Fortran, C++, mg7 and Python backends through it, fixing the transposed
  PARTNER/PARTNER2/VAL table for a single merged leg not in the first
  position (e.g. the merged neutrino of w+ ta+ vt~)
- process_checks: pass the flavor group position (not the PDG) and index 1
  (not -1) for unmerged legs to smatrix, matching the standalone FLAV_TABLE
- mg7: null-initialise FLV_COUPLING::value[] so the cIPF_value setup does
  not dereference uninitialised pointers (segfault on single-entry couplings)

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
The MGONGPU_HARDCODE_PARAM cIPF_value initializer read every value[]
slot unconditionally (and via `.real()` on a cxtype* pointer). Flavor
slots with no coupling are null (FLV_COUPLING constructor), so guard
each read as `value[i] ? value[i]->real() : 0`, matching the runtime
(non-hardcoded) path and fixing both the null dereference and the
pointer access.

mg7: fix out-of-bounds flavor index in the runtime flavor table (segfault)

The per-flavor tFlavors table (used at runtime to index the FLV_COUPLING
partner1/partner2/value arrays, size max_flavor) was built with a naive
f-1: for a merged leg flavors[0] holds the constituent PDG, so a merged
neutrino gave index 16-1=15, well out of range -> out-of-bounds read and
segfault. Convert a merged leg's PDG to its 0-based position inside the
merged group instead (unmerged legs map to 0). This only surfaced for
merged leptons/neutrinos; light quarks worked because PDG 1..4 equals the
position. Matches the standalone_cpp flavor_table, which was already correct.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@oliviermattelaer

Copy link
Copy Markdown
Contributor Author

This is not designed to be merged per say.
This PR is the sum of #31 #32 #33

It is just to see what is the current status with madspace CI when all of them are merged into a single branch.
This show that only 3 CI are not working anymore (3jets) and (ttx_decay)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants