From 0bf076b1d22cb0ea38133ca23bd83238a189246d Mon Sep 17 00:00:00 2001 From: Derek Glazier Date: Fri, 19 Sep 2025 09:44:58 +0100 Subject: [PATCH] add doxygen action --- .github/workflows/doxygen-deploy.yml | 8 +- docs/index.html | 174 +++++++++++++++++++++++++++ 2 files changed, 179 insertions(+), 3 deletions(-) create mode 100644 docs/index.html diff --git a/.github/workflows/doxygen-deploy.yml b/.github/workflows/doxygen-deploy.yml index e09bd2a..f8b6b6f 100644 --- a/.github/workflows/doxygen-deploy.yml +++ b/.github/workflows/doxygen-deploy.yml @@ -41,9 +41,11 @@ jobs: - name: Prepare site for deployment run: | - mkdir -p _site/reference - cp docs/index.html _site/ - mv doxygen-html/* _site/reference/ + # Create the final deployment directory + mkdir -p _site + # Copy your new custom landing page to be the site's root index.html + cp docs/index.html _site/index.html + # Move the generated doxygen files into the 'reference' subdirectory - name: Upload artifact uses: actions/upload-pages-artifact@v3 diff --git a/docs/index.html b/docs/index.html new file mode 100644 index 0000000..104b62c --- /dev/null +++ b/docs/index.html @@ -0,0 +1,174 @@ + + + + + + RAD | Reaction Aware Dataframes + + + + + +
+ +
+

RAD: Reaction Aware Dataframes

+

Modern Particle & Nuclear Physics Data Analysis with ROOT RDataFrame

+ View Full Class Reference (Doxygen) +
+ + +
+

Core Concepts

+
+
+

Reaction Configuration

+

RAD is built around the idea of configuring a physics reaction as a ConfigReaction object, which manages the full analysis process.

+
    +
  • Simplifies code for different final states and data formats (HepMC, ePIC, etc.)
  • +
  • Designed for ROOT RDataFrame, with header-only, runtime parsing
  • +
  • Automates MC matching, truth variable calculation, and combinatorial analysis
  • +
  • User code focuses on defining particles and analysis logic, not boilerplate
  • +
+
+
+

Modular Utilities

+

RAD provides a suite of utility classes and functions for:

+
    +
  • Particle creation (ParticleCreator)
  • +
  • Kinematic calculations (BasicKinematics, ReactionKinematicsRDF)
  • +
  • Histogram management (Histogrammer)
  • +
  • Random number generation (Random)
  • +
+

These are composed with your ConfigReaction object for flexible analysis workflows.

+
+
+
+ + +
+

Code Structure & Workflow

+
+
Class Hierarchy & Usage Flow
+
+ ConfigReaction (abstract base) + +
+
+ ElectroIonReaction +
+
+ HepMCElectro + For MC generator analysis (HepMC3 data) +
+
+ ePICReaction + User-defined: for real experiments (ePIC, etc.) +
+
+
+ PhotoIonReaction +
+
+ HepMCPhoto + MC generator analysis (photoproduction) +
+
+ [YourExperimentPhoto] + User-defined: for real experiments +
+
+
+ + ParticleCreator, Histogrammer, Utilities + Composition: instantiated and used with your reaction object +
+
+ Note: For new analyses, subclass ElectroIonReaction or PhotoIonReaction to match your experiment and data format. Use ParticleCreator to define particles, and Histogrammer to manage histograms. +
+
+
+
Typical Analysis Workflow
+
    +
  • Choose reaction type: Subclass ElectroIonReaction or PhotoIonReaction (e.g. HepMCElectro for MC, or your experiment's class)
  • +
  • Configure particles: Use ParticleCreator to assign indices and build composite particles
  • +
  • Define analysis steps: Kinematics, selection, truth-matching, etc. (using utilities)
  • +
  • Histogram management: Instantiate Histogrammer with your reaction object, configure histograms and splits
  • +
  • Run analysis: Execute interactively through ROOT (typically root example.C)
  • +
+
+
+ + +
+

Example Usage: ProcessHepMCY.C

+
+
// Setup for MC generator data (HepMC3)
+#include "HepMCElectro.h"
+#include "ParticleCreator.h"
+#include "Indicing.h"
+#include "Histogrammer.h"
+#include "BasicKinematicsRDF.h"
+#include "ReactionKinematicsRDF.h"
+#include "ElectronScatterKinematicsRDF.h"
+#include 
+#include 
+
+void ProcessHepMCY() {
+  using namespace rad::names::data_type; // For MC(), Rec(), Truth() types
+  ROOT::EnableImplicitMT(4);
+
+  // 1. Create reaction object for HepMC3 MC data
+  rad::config::HepMCElectro hepmc{"hepmc3_tree", "data_file.root"};
+  hepmc.AliasMomentumComponents();
+
+  // 2. Define particles (using ParticleCreator)
+  rad::config::ParticleCreator particles{hepmc};
+  // Assign indices, build composite particles...
+
+  // 3. Create and draw histograms (using Histogrammer)
+  rad::histo::Histogrammer histo{hepmc};
+  // Configure histograms, draw with histo.DrawSame("Q2",gPad);
+
+  // 4. Process and analyze event data...
+}
+// Run with: root examples/ProcessHepMCY.C
+        
+

This workflow is typical for both MC generator and real experimental data (just swap the reaction class for your experiment).

+
+
+ + +
+

Build & Usage

+
+

Quick Install

+
git clone https://github.com/dglazier/rad
+export ROOT_INCLUDE_PATH=/path/to/rad/include:$ROOT_INCLUDE_PATH
+ +

Interactive Analysis

+
root examples/ProcessHepMCY.C
+

No build required (header-only). Analysis is performed interactively in ROOT using C++ scripts.

+
+
+ + + +
+ +