Optimization using pathwise algorithmic derivatives of electromagnetic shower simulations

Among the well-known methods to approximate derivatives of expectancies computed by Monte-Carlo simulations, averages of pathwise derivatives are often the easiest one to apply. Computing them via algorithmic differentiation typically does not require major manual analysis and rewriting of the code, even for very complex programs like simulations of particle-detector interactions in high-energy physics. However, the pathwise derivative estimator can be biased if there are discontinuities in the program, which may diminish its value for applications. This work integrates algorithmic differentiation into the electromagnetic shower simulation code HepEmShow based on G4HepEm, allowing us to study how well pathwise derivatives approximate derivatives of energy depositions in a sampling calorimeter with respect to parameters of the beam and geometry. We found that when multiple scattering is disabled in the simulation, means of pathwise derivatives converge quickly to their expected values, and these are close to the actual derivatives of the energy deposition. Additionally, we demonstrate the applicability of this novel gradient estimator for stochastic gradient-based optimization in a model example. • We have successfully applied algorithmic differentiation to a stochastic particle simulation. • The entire electromagnetic shower simulation is “AD-friendly”, except for the implementation of multiple scattering. • The resulting gradient estimator can be useful for optimization in high- energy physics.

Authors

Institutions

Publication Details

Journal
Computer Physics Communications
Published
2024-12-31
DOI
https://doi.org/10.1016/j.cpc.2024.109491
Citations
6
Primary Topic
Astrophysics and Cosmic Phenomena
Type
article
Field-Weighted Citation Impact
3.96
Controls
|||
ALL TIME
JAN
FEB
MAR
APR
MAY
JUN
JUL
AUG
SEP
OCT
article

Optimization using pathwise algorithmic derivatives of electromagnetic shower simulations

M. Kagan, Nicolas R. Gauger, L. Heinrich, D. J. Lange et al.
6 citations
Computer Physics Communications
Astrophysics and Cosmic Phenomena
3.96
article

Optimization using pathwise algorithmic derivatives of electromagnetic shower simulations

M. Kagan, Nicolas R. Gauger, L. Heinrich, D. J. Lange, Max Aehle, Vassil Vassilev, Mihály Novák
article en
6 citations

Abstract

Among the well-known methods to approximate derivatives of expectancies computed by Monte-Carlo simulations, averages of pathwise derivatives are often the easiest one to apply. Computing them via algorithmic differentiation typically does not require major manual analysis and rewriting of the code, even for very complex programs like simulations of particle-detector interactions in high-energy physics. However, the pathwise derivative estimator can be biased if there are discontinuities in the program, which may diminish its value for applications. This work integrates algorithmic differentiation into the electromagnetic shower simulation code HepEmShow based on G4HepEm, allowing us to study how well pathwise derivatives approximate derivatives of energy depositions in a sampling calorimeter with respect to parameters of the beam and geometry. We found that when multiple scattering is disabled in the simulation, means of pathwise derivatives converge quickly to their expected values, and these are close to the actual derivatives of the energy deposition. Additionally, we demonstrate the applicability of this novel gradient estimator for stochastic gradient-based optimization in a model example. • We have successfully applied algorithmic differentiation to a stochastic particle simulation. • The entire electromagnetic shower simulation is “AD-friendly”, except for the implementation of multiple scattering. • The resulting gradient estimator can be useful for optimization in high- energy physics.

Computer Physics CommunicationsVol. 309
University of Kaiserslautern (DE), Princeton University (US), SLAC National Accelerator Laboratory (US), European Organization for Nuclear Research (CH), MTU Aero Engines (Germany) (DE)
Openalex Percentile: Top 5%
Astrophysics and Cosmic Phenomena
3.96
AI Navigator

Ask Laika to Summarize, Analyze, and Connect papers live on the map.

Summarize Papers & Methodologies

Extract key findings, datasets, and comparative methods across publications.

Benchmark Rankings & Visual Analytics

Rank top research institutions, authors, funders, topics, and journals by Field-Weighted Citation Impact (FWCI) and paper volume with instant charts.

Connect Distant Disciplines

Bridge topological clusters on the map to find hidden collaborative intersections.