# Generative Unfolding Eval

> Evaluates a generative ML model's ability to correct detector effects (unfolding) for highly boosted hadronic top-quark decays. It probes the model's capacity to reconstruct high-dimensional kinematic phase space while mitigating simulation-induced model bias and accurately extracting the top_mass_measurement. Use when the user wants to benchmark on CMS benchmark top-pair simulation, or asks about evaluating this task. Reports top_mass_measurement.

- Skill: `qhjqhj00/generative-unfolding-eval` (Agent Skill)
- Install (CLI): `npx skillmds add qhjqhj00/generative-unfolding-eval`
- Raw SKILL.md: https://api.skillmd.com/api/skills/qhjqhj00/generative-unfolding-eval/raw
- Safety review: pending
- Works with: Claude Code, Claude.ai, OpenAI Codex
- Category: AI & ML
- Author: qhjqhj00 (https://skillmd.com/u/qhjqhj00)
- Updated: 2026-09-08
- Page: https://skillmd.com/skills/qhjqhj00/generative-unfolding-eval

---


# generative-unfolding-eval

> How to Unfold Top Decays — Favaro et al. (2025) (arXiv:2501.12363, 2025)

## What this evaluates

Evaluates a generative ML model's ability to correct detector effects (unfolding) for highly boosted hadronic top-quark decays. It probes the model's capacity to reconstruct high-dimensional kinematic phase space while mitigating simulation-induced model bias and accurately extracting the top_mass_measurement.

## Datasets

- **CMS benchmark top-pair simulation** — total 800000; splits: train (600000), test (-1)

## Metrics

- `top_mass_measurement` **(primary)** — range: other (GeV)
  - The absolute deviation between the top-quark mass extracted from the unfolded 3-jet invariant mass distribution ($M_{jjj}$) and the true generator mass (172.5 GeV). Extracted via fitting the unfolded distribution to theoretical or particle-level predictions.

## Input / output format

**Input**: Detector-level (reco) 4-momenta of three XCone subjets (mass, $p_T$, $\phi$, $\eta$), derived 2-jet masses, missing transverse momentum, and lepton kinematics.

**Output**: Generator-level (gen) 4-momenta for the three subjets (mass, $p_T$, $\phi$, $\eta$) representing the full 12-dimensional phase space.

## Scoring recipe

```python
def compute_top_mass_accuracy(unfolded_jets, true_mass=172.5):
    # Compute 3-jet invariant mass for each unfolded event
    M_jjj = compute_invariant_mass(unfolded_jets)
    # Fit unfolded distribution to particle-level template
    fitted_mass = fit_peak(M_jjj, template="particle_level")
    # Return absolute deviation
    return abs(fitted_mass - true_mass)
```

## Common pitfalls

- Assuming a fixed top mass in the simulation training data introduces significant model bias if the true mass differs.
- Using 2-jet masses as explicit features sacrifices individual azimuthal angles, potentially generating unphysical kinematics ($\cos \Delta \phi \notin [0,1]$).
- Background processes (e.g., $W$+jets) are subtracted bin-wise in the reference CMS analysis but are neglected in this study, which may overestimate performance on real data.

## Evidence (verbatim from paper)

> This analysis unfolds the reconstructed 3-subject mass $M_{jjj}$ and the corresponding reconstructed transverse momentum, $p_{T,jjj}$ to measure the top mass. The result from our CMS benchmark analysis [34] is shown in Fig. 1. It shows the differential top pair cross section as a function of the top-jet invariant mass, compared to theory predictions for different top masses.

## Citation

```bibtex
@misc{favaro2025unfoldtopdecays,
  title={How to Unfold Top Decays},
  author={Favaro et al. (2025)},
  year={2025},
  note={arXiv:2501.12363}
}
```

- arXiv: 2501.12363

