# jslawless/run3-mj-pass-the-aux architecture

> Architecture diagram of the GitHub repository jslawless/run3-mj-pass-the-aux, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-10-03). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/jslawless/run3-mj-pass-the-aux
- Repository: https://github.com/jslawless/run3-mj-pass-the-aux

## Overview

This repository supports Run 3 RPV gluino production studies: generating simulated samples, scanning generator qCut settings, extracting production metrics, converting NANOGEN events into CombinatorialSolver HDF5 inputs, and validating gluino/jet events with plots. The README provides no further architecture detail. Edges reflect only relationships visible in the supplied excerpts; the validation excerpt is partial, and the HDF5 converter’s evaluator dependency is external.

Main entry points: [`qcut_studies/submit_gen_qcut_scan.py`](https://github.com/jslawless/run3-mj-pass-the-aux/blob/main/qcut_studies/submit_gen_qcut_scan.py) (qCut scan submitter), [`scan_mcm_numbers.py`](https://github.com/jslawless/run3-mj-pass-the-aux/blob/main/scan_mcm_numbers.py) (McM metrics scan), [`combsolver_h5/nanogen_to_h5.py`](https://github.com/jslawless/run3-mj-pass-the-aux/blob/main/combsolver_h5/nanogen_to_h5.py) (HDF5 dataset converter), [`validation_scripts/sample_validation_plots.py`](https://github.com/jslawless/run3-mj-pass-the-aux/blob/main/validation_scripts/sample_validation_plots.py) (Event validation plots)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_production["Event Production"]
  node_gen_config["GEN configuration"]
  node_lhe_configs["LHE configurations"]
  node_qcut_submit["qCut scan submitter"]
  node_qcut_template["GEN fragment template"]
  node_mcm_scan["McM metrics scan"]
  node_scan_outputs["Per-mass outputs and CSV"]
end

subgraph group_preparation["Data Preparation"]
  node_h5_converter["HDF5 dataset converter<br/>[nanogen_to_h5.py]"]
  node_h5_dataset[("CombinatorialSolver HDF5")]
end

subgraph group_validation["Validation"]
  node_validation_plots["Event validation plots"]
end

node_researcher(("Researcher"))
node_lhe_input["LHE ROOT input"]
node_gridpack["MadGraph gridpack"]
node_cmsdriver["cmsDriver"]
node_cmsrun["cmsRun"]
node_nanogen_root["NANOGEN ROOT input"]
node_truth_match["Truth matching"]
node_root_input["ROOT event input"]
node_plot_output["Plot output"]

node_researcher -->|"configures scan"| node_qcut_submit
node_lhe_input -->|"supplies LHE file"| node_qcut_submit
node_qcut_submit -->|"renders fragments"| node_qcut_template
node_qcut_submit -->|"invokes"| node_cmsdriver
node_qcut_submit -->|"submits jobs for"| node_cmsrun
node_researcher -->|"configures scan"| node_mcm_scan
node_mcm_scan -->|"runs per mass"| node_cmsdriver
node_mcm_scan -->|"runs generated cfg"| node_cmsrun
node_gridpack -->|"configured as input"| node_gen_config
node_lhe_configs -->|"references mass gridpacks"| node_gridpack
node_mcm_scan -->|"writes logs and CSV"| node_scan_outputs
node_researcher -->|"provides input paths"| node_h5_converter
node_nanogen_root -->|"reads events"| node_h5_converter
node_h5_converter -->|"calls truth assignment"| node_truth_match
node_h5_converter -->|"writes datasets"| node_h5_dataset
node_researcher -->|"selects input and mode"| node_validation_plots
node_root_input -->|"reads events"| node_validation_plots
node_validation_plots -->|"renders plots"| node_plot_output

click node_gen_config "https://github.com/jslawless/run3-mj-pass-the-aux/blob/main/qcut_studies/RPVGluinoGluinoToJets_UDD112_TuneCP5_13p6TeV_madgraphMLM-pythia8_wmLHEGS_cff.py"
click node_lhe_configs "https://github.com/jslawless/run3-mj-pass-the-aux/blob/main/qcut_studies/RPVGluinoGluinoToJets_UDD112_M-1000_LHE_cff.py"
click node_qcut_submit "https://github.com/jslawless/run3-mj-pass-the-aux/blob/main/qcut_studies/submit_gen_qcut_scan.py"
click node_qcut_template "https://github.com/jslawless/run3-mj-pass-the-aux/blob/main/qcut_studies/RPVGluinoGluinoToJets_UDD112_GEN_cff.py.in"
click node_mcm_scan "https://github.com/jslawless/run3-mj-pass-the-aux/blob/main/scan_mcm_numbers.py"
click node_h5_converter "https://github.com/jslawless/run3-mj-pass-the-aux/blob/main/combsolver_h5/nanogen_to_h5.py"
click node_validation_plots "https://github.com/jslawless/run3-mj-pass-the-aux/blob/main/validation_scripts/sample_validation_plots.py"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_gen_config,node_lhe_configs,node_qcut_submit,node_qcut_template,node_mcm_scan,node_scan_outputs toneBlue
class node_h5_converter,node_h5_dataset toneAmber
class node_validation_plots toneMint
class node_researcher,node_lhe_input,node_gridpack,node_cmsdriver,node_cmsrun,node_nanogen_root,node_truth_match,node_root_input,node_plot_output toneIndigo
```

## Components

### Event Production

- [GEN configuration](https://github.com/jslawless/run3-mj-pass-the-aux/blob/main/qcut_studies/RPVGluinoGluinoToJets_UDD112_TuneCP5_13p6TeV_madgraphMLM-pythia8_wmLHEGS_cff.py): `qcut_studies/RPVGluinoGluinoToJets_UDD112_TuneCP5_13p6TeV_madgraphMLM-pythia8_wmLHEGS_cff.py`
- [LHE configurations](https://github.com/jslawless/run3-mj-pass-the-aux/blob/main/qcut_studies/RPVGluinoGluinoToJets_UDD112_M-1000_LHE_cff.py): `qcut_studies/RPVGluinoGluinoToJets_UDD112_M-1000_LHE_cff.py`
- [qCut scan submitter](https://github.com/jslawless/run3-mj-pass-the-aux/blob/main/qcut_studies/submit_gen_qcut_scan.py): `qcut_studies/submit_gen_qcut_scan.py`
- [GEN fragment template](https://github.com/jslawless/run3-mj-pass-the-aux/blob/main/qcut_studies/RPVGluinoGluinoToJets_UDD112_GEN_cff.py.in): `qcut_studies/RPVGluinoGluinoToJets_UDD112_GEN_cff.py.in`
- [McM metrics scan](https://github.com/jslawless/run3-mj-pass-the-aux/blob/main/scan_mcm_numbers.py): `scan_mcm_numbers.py`
- **Per-mass outputs and CSV**

### Data Preparation

- [HDF5 dataset converter](https://github.com/jslawless/run3-mj-pass-the-aux/blob/main/combsolver_h5/nanogen_to_h5.py): `combsolver_h5/nanogen_to_h5.py`
- **CombinatorialSolver HDF5**

### Validation

- [Event validation plots](https://github.com/jslawless/run3-mj-pass-the-aux/blob/main/validation_scripts/sample_validation_plots.py): `validation_scripts/sample_validation_plots.py`

### Other components

- **Researcher**
- **LHE ROOT input**
- **MadGraph gridpack**
- **cmsDriver**
- **cmsRun**
- **NANOGEN ROOT input**
- **Truth matching**
- **ROOT event input**
- **Plot output**

## Connections

- Researcher → qCut scan submitter: configures scan (evidence: `qcut_studies/submit_gen_qcut_scan.py`)
- LHE ROOT input → qCut scan submitter: supplies LHE file (evidence: `qcut_studies/submit_gen_qcut_scan.py`)
- qCut scan submitter → GEN fragment template: renders fragments (evidence: `qcut_studies/submit_gen_qcut_scan.py`)
- qCut scan submitter → cmsDriver: invokes (evidence: `qcut_studies/submit_gen_qcut_scan.py`)
- qCut scan submitter → cmsRun: submits jobs for (evidence: `qcut_studies/submit_gen_qcut_scan.py`)
- Researcher → McM metrics scan: configures scan (evidence: `scan_mcm_numbers.py`)
- McM metrics scan → cmsDriver: runs per mass (evidence: `scan_mcm_numbers.py`)
- McM metrics scan → cmsRun: runs generated cfg (evidence: `scan_mcm_numbers.py`)
- MadGraph gridpack → GEN configuration: configured as input (evidence: `qcut_studies/RPVGluinoGluinoToJets_UDD112_TuneCP5_13p6TeV_madgraphMLM-pythia8_wmLHEGS_cff.py`)
- LHE configurations → MadGraph gridpack: references mass gridpacks (evidence: `qcut_studies/RPVGluinoGluinoToJets_UDD112_M-1000_LHE_cff.py`)
- McM metrics scan → Per-mass outputs and CSV: writes logs and CSV (evidence: `scan_mcm_numbers.py`)
- Researcher → HDF5 dataset converter: provides input paths (evidence: `combsolver_h5/nanogen_to_h5.py`)
- NANOGEN ROOT input → HDF5 dataset converter: reads events (evidence: `combsolver_h5/nanogen_to_h5.py`)
- HDF5 dataset converter → Truth matching: calls truth assignment (evidence: `combsolver_h5/nanogen_to_h5.py`)
- HDF5 dataset converter → CombinatorialSolver HDF5: writes datasets (evidence: `combsolver_h5/nanogen_to_h5.py`)
- Researcher → Event validation plots: selects input and mode (evidence: `validation_scripts/sample_validation_plots.py`)
- ROOT event input → Event validation plots: reads events (evidence: `validation_scripts/sample_validation_plots.py`)
- Event validation plots → Plot output: renders plots (evidence: `validation_scripts/sample_validation_plots.py`)
