AI-Assisted Detector Design for the EIC (AID(2)E)

M. Diefenthaler    C. Fanelli    L. O. Gerlach    W. Guan    T. Horn    A. Jentsch    M. Lin    K. Nagai    H. Nayak    C. Pecar    K. Suresh    A. Vossen    T. Wang    T. Wenaus    (AID(2)E collaboration)
Abstract

Artificial Intelligence is poised to transform the design of complex, large-scale detectors like ePIC at the future Electron Ion Collider. Featuring a central detector with additional detecting systems in the far forward and far backward regions, the ePIC experiment incorporates numerous design parameters and objectives, including performance, physics reach, and cost, constrained by mechanical and geometric limits. This project aims to develop a scalable, distributed AI-assisted detector design for the EIC (AID(2)E), employing state-of-the-art multiobjective optimization to tackle complex designs. Supported by the ePIC software stack and using Geant4 simulations, our approach benefits from transparent parameterization and advanced AI features. The workflow leverages the PanDA and iDDS systems, used in major experiments such as ATLAS at CERN LHC, the Rubin Observatory, and sPHENIX at RHIC, to manage the compute intensive demands of ePIC detector simulations. Tailored enhancements to the PanDA system focus on usability, scalability, automation, and monitoring. Ultimately, this project aims to establish a robust design capability, apply a distributed AI-assisted workflow to the ePIC detector, and extend its applications to the design of the second detector (Detector-2) in the EIC, as well as to calibration and alignment tasks. Additionally, we are develo** advanced data science tools to efficiently navigate the complex, multidimensional trade-offs identified through this optimization process.

1 Introduction

The Electron Ion Collider (EIC) stands out as one of the pioneering large-scale experiments to incorporate artificial intelligence (AI) right from its design phase. As highlighted in the 2019 DOE Town Halls on AI for Science: “AI techniques that can optimize the design of complex, large-scale experiments have the potential to revolutionize the way experimental nuclear physics is currently done.” This paper presents AID(2)E, a DOE-funded initiative aimed at develo** a scalable and distributed framework for AI-assisted detector design at the EIC.

The project was initiated to address the limitations of current detector optimization methods. Traditionally, each subsystem is optimized individually within global design constraints before integration. This conventional approach, often relying on ad hoc or brute-force methods like grid search, is sub-optimal. It struggles with handling multiple design parameters, fails to optimize multiple objectives simultaneously (such as efficiency, resolution, and costs), and lacks holistic optimization of the entire detector. Furthermore, it does not fully exploit the benefits of multi-objective optimization, which can reveal optimal trade-offs between competing objectives. The rationale for employing a multi-objective optimization approach in detector design is that there is no single optimal solution; instead, there exists a spectrum of viable solutions that balance factors such as detector response, physics design requirements, and costs. This is especially significant given the high costs associated with large-scale detectors, exemplified by the estimated $300M budget for the ePIC detector [1]. As demonstrated in previous studies (e.g., [2, 3]), these methods provide new insights into internal correlations among design parameters and enable trade-offs that are not achievable with traditional methods. AI-assisted optimization complements the expertise of detector specialists and, as shown in [3], can improve objectives compared to a baseline design across a large phase space. A holistic optimization of the entire detector, considering multiple objectives simultaneously, represents a paradigm shift in detector design. AI-assisted methods can significantly impact future large nuclear physics projects, such as those at the EIC. Using realistic simulation pipelines and minimizing the computational budget required, the AID(2)E Collaboration aims to streamline the design process while ensuring high-fidelity results. The primary goal of AID(2)E is to develop infrastructure that optimizes detector design in a scalable and distributed manner. The project begins with two closure tests designed to demonstrate the convergence of the Pareto front in multi-objective optimization problems and to validate the effectiveness of distributing the compute-intensive simulations of design points suggested by the optimizer. AID(2)E has already made contributions towards optimizing the ePIC detector subsystems. Currently, the collaboration is optimizing two detector subsystems, which are discussed in this proceeding. This optimization approach can potentially be extended to other subsystems of ePIC, making it one of the first large-scale detector designed with the assistance of AI. Evaluating different solutions on the Pareto front of ePIC at various budget levels can yield significant cost benefits. Even fractional improvements in objectives, such as resolution and efficiency, can lead to a more efficient use of beam time, a major cost factor for the EIC over its lifetime. Characterizing the Pareto front can inform the design of a complementary Detector-2 at EIC. Our team is also develo** a suite of data science tools to facilitate effective exploration of the determined Pareto front [4]. It is worth mentioning that the AID(2)E framework also holds potential for other applications, such as calibration and distributed machine learning inference engines. Furthermore, AID(2)E aims to engage the community through bootcamps and short-term schools for students.

2 Methodology and Strategy

The primary goal of the AID(2)E project is to develop a scalable and distributed AI-assisted Detector Design framework for the EIC, specifically focusing on the ePIC detector. Central to AID(2)E is Multi-Objective Optimization (MOO), which evaluates various design objectives such as sub-detector intrinsic responses (e.g., resolution and efficiency), performance for key EIC physics channels, and material cost proxies. This project is pioneering in its application of MOO at such a scale, facilitated by a develo** distributed workflow infrastructure, enhanced with PanDA for simulation workflows [5]. Our strategy includes two closure tests: first, we want to test and characterize the perforamnce of approaches like Multi-Objective Bayesian Optimization (MOBO) [6] and Multi-Objective Genetic Algorithms (MOGA), specifically NSGA-II [7], using test functions. The second one proves the effectiveness of distributing the simulations of different design points, coordinating data collection for objective updates, and refining the design iteratively. The framework supports continuous and distributed AI-driven optimization. Initial efforts are concentrated on optimizing specific sub-detector systems within ePIC, paving the way for broader application. Detailed discussions on the optimization approach, distributed workflow, and specific applications to the ePIC detector are presented in what follows.

Multi-Objective Optimization

The definition of a generic detector MOO problem can be formulated as follows:

min𝐟𝐦(𝐱)𝑚𝑖𝑛subscript𝐟𝐦𝐱\displaystyle min\ \mathbf{f_{m}}(\mathbf{x})italic_m italic_i italic_n bold_f start_POSTSUBSCRIPT bold_m end_POSTSUBSCRIPT ( bold_x ) m=1,,M(𝐨𝐛𝐣𝐞𝐜𝐭𝐢𝐯𝐞𝐬)𝑚1𝑀𝐨𝐛𝐣𝐞𝐜𝐭𝐢𝐯𝐞𝐬\displaystyle\ \ \ \ \ \ m=1,\cdots,M\ \ \ \mathbf{(objectives)}italic_m = 1 , ⋯ , italic_M ( bold_objectives ) (2.1)
s.t.𝐠𝐣(𝐱)0,\displaystyle s.t.\ \ \ \mathbf{g_{j}}(\mathbf{x})\leq 0,italic_s . italic_t . bold_g start_POSTSUBSCRIPT bold_j end_POSTSUBSCRIPT ( bold_x ) ≤ 0 , j=1,,J(𝐢𝐧𝐞𝐪𝐮𝐚𝐥𝐢𝐭𝐲𝐜𝐨𝐧𝐬𝐭𝐫𝐚𝐢𝐧𝐭𝐬)𝑗1𝐽𝐢𝐧𝐞𝐪𝐮𝐚𝐥𝐢𝐭𝐲𝐜𝐨𝐧𝐬𝐭𝐫𝐚𝐢𝐧𝐭𝐬\displaystyle\ \ \ \ \ \ j=1,\cdots,J\ \ \ \ \ \mathbf{(inequality\ % constraints)}italic_j = 1 , ⋯ , italic_J ( bold_inequality bold_constraints )
𝐡𝐤(𝐱)=0,subscript𝐡𝐤𝐱0\displaystyle\ \ \ \ \ \mathbf{h_{k}}(\mathbf{x})=0,bold_h start_POSTSUBSCRIPT bold_k end_POSTSUBSCRIPT ( bold_x ) = 0 , k=1,,K(𝐞𝐪𝐮𝐚𝐥𝐢𝐭𝐲𝐜𝐨𝐧𝐬𝐭𝐫𝐚𝐢𝐧𝐭𝐬)𝑘1𝐾𝐞𝐪𝐮𝐚𝐥𝐢𝐭𝐲𝐜𝐨𝐧𝐬𝐭𝐫𝐚𝐢𝐧𝐭𝐬\displaystyle\ \ \ \ \ \ k=1,\cdots,K\ \ \ \ \mathbf{(equality\ constraints)}italic_k = 1 , ⋯ , italic_K ( bold_equality bold_constraints )
xiLxixiU,superscriptsubscript𝑥𝑖𝐿subscript𝑥𝑖superscriptsubscript𝑥𝑖𝑈\displaystyle x_{i}^{L}\leq x_{i}\leq x_{i}^{U},italic_x start_POSTSUBSCRIPT italic_i end_POSTSUBSCRIPT start_POSTSUPERSCRIPT italic_L end_POSTSUPERSCRIPT ≤ italic_x start_POSTSUBSCRIPT italic_i end_POSTSUBSCRIPT ≤ italic_x start_POSTSUBSCRIPT italic_i end_POSTSUBSCRIPT start_POSTSUPERSCRIPT italic_U end_POSTSUPERSCRIPT , i=1,,N(𝐩𝐚𝐫𝐚𝐦𝐞𝐭𝐞𝐫𝐬)𝑖1𝑁𝐩𝐚𝐫𝐚𝐦𝐞𝐭𝐞𝐫𝐬\displaystyle\ \ \ \ \ \ i=1,\cdots,N\ \ \ \ \ \mathbf{(parameters)}italic_i = 1 , ⋯ , italic_N ( bold_parameters )

where one has M𝑀Mitalic_M objective functions fmsubscript𝑓𝑚f_{m}italic_f start_POSTSUBSCRIPT italic_m end_POSTSUBSCRIPT to optimize (e.g., detector resolution, efficiency, signal/background for a physics channel, costs), subject to J𝐽Jitalic_J inequalities gj(x)subscript𝑔𝑗𝑥g_{j}(x)italic_g start_POSTSUBSCRIPT italic_j end_POSTSUBSCRIPT ( italic_x ) and K𝐾Kitalic_K equality constraints hk(z)subscript𝑘𝑧h_{k}(z)italic_h start_POSTSUBSCRIPT italic_k end_POSTSUBSCRIPT ( italic_z ) (e.g., mechanical constraints), in a design space of N𝑁Nitalic_N dimensions (e.g., geometry parameters that change the Geant4 design) with lower (xLsuperscript𝑥𝐿x^{L}italic_x start_POSTSUPERSCRIPT italic_L end_POSTSUPERSCRIPT) and upper (xUsuperscript𝑥𝑈x^{U}italic_x start_POSTSUPERSCRIPT italic_U end_POSTSUPERSCRIPT) bounds on each dimension. We are utilizing Multi-Objective Bayesian Optimization (MOBO) and Multi-Objective Optimization using Genetic Algorithms (MOGA) to tackle detector design optimization. These techniques assess multiple objectives such as sub-detector responses, physics channel performance, and material costs, and are detailed in our workflow illustrated in Fig. 1.

Refer to caption
Refer to caption
Figure 1: Multi-objective optimization workflows: The left panel shows the Bayesian workflow MOBO, which is the primary choice in this project (generally capable of providing accurate determination Pareto fronts). The right panel shows MOGA (NSGA-II, based on genetic algorithms [7]), which is an alternative approach (more suitable to handle, e.g., possible discontinuities or high-dimensional spaces).

MOBO is our primary choice for the ePIC detector, driven by our improved understanding of technology and parameter ranges, the ability to incorporate uncertainties and physics-inspired acquisition functions, and a more accurate approximation of the Pareto front compared to MOGA. This approach has proven efficient in requiring fewer evaluations to converge and allows for custom acquisition functions, supported by tools like ax-platform and BoTorch [8, 9]. We are currently testing MOBO with a qNEHVI acquisition function [10], optimizing for scalability across multiple design points and dimensions. Scalability challenges for MOBO include computational constraints as the number of observations grows, which we can address using techniques to manage the increasing complexity of the surrogate model, such as SAASBO and TURBO. Both MOBO and MOGA offer distinct computational and scalability properties that dictate their application and workload distribution, crucial for the efficient design of the ePIC detector. One advantage of MOGA compared to MOBO is the possibility of handling nondifferentiable terms, and higher dimensionality problems, leveraging the inherent parallelization of genetic algorithms.

Distributed Workflow

The AID2E team is committed to advancing AI-based detector design optimization at the EIC by develo** a scalable and distributed framework. This framework is refined through its application to the ePIC detector design and is delivered as a robust, experiment-agnostic solution ready for broader detector design applications. The project leverages existing, scalable distributed workflow and workload management tools like PanDA [11], developed for the ATLAS experiment and now supporting complex AI/ML workflows including Bayesian Optimization.

Historically, these systems have supported large-scale data handling and processing needs of the ATLAS experiment and other projects like the Rubin Observatory and sPHENIX, demonstrating the versatility and scalability of the PanDA and the intelligent Data Delivery Service (iDDS). These tools have been integral in managing workflows across diverse computing environments—grids, clouds, and supercomputers—enhancing their stability and adaptability.

Recent developments have focused on integrating complex AI/ML workflows, particularly those utilizing GPUs, into this system. This includes hyperparameter optimization and active learning based on Bayesian optimization, extending the capabilities of ATLAS analyses. Additionally, full-chain integrated production-analysis workflows, including the use of REANA in the analysis phase, have been supported. The PanDA/iDDS development program emphasizes ease of use and accessibility, supporting a range of AI/ML applications through a unified platform that integrates multiple computing facilities. This capability is critical for processing-intensive, distributed AI-based detector design, offering: (i) seamless operation across distributed resources; (ii) support for comprehensive AI/ML tools and full-chain workflows from simulation to iterative refinement; (iii) efficient authentication and user-friendly interfaces, including support for modern and legacy security mechanisms. Ultimately, this framework not only supports current project needs but is also adaptable to similar future applications, demonstrating its potential through an implementation of Bayesian Optimization-based active learning now enhancing the physics reach of ATLAS analyses.

Closure Tests

The primary objective of the closure tests within the AID(2)E framework is to rigorously evaluate system constraints and identify potential bottlenecks. This framework enhances the distribution of simulations using the ePIC software stack [12] and advances MOO techniques for detector design. The first closure test analyzes these bottlenecks within a test optimization problem, employing MOBO to assess its scalability and efficiency relative to problem complexity. To meet the computational demands of evaluating multiple detector design points, the ePIC detector design optimization requires a large volumes of simulated data. The PanDA System [11] is utilized to manage these tasks across varied geographic locations, coordinated by the iDDS. The second closure test integrates and stress-tests the PanDA framework, initially with test functions and subsequently with actual ePIC simulation payloads. This process validates the framework’s capability to efficiently distribute simulations and synchronize them with an optimization strategy, ensuring robust performance across diverse operational scenarios. A high-level workflow of the AID(2)E framework, based on the mentioned closure tests, is displayed in Fig. 2.

Refer to caption
Figure 2: High-level workflow of AID(2)E: We first demonstrate an AI-assisted framework handling multiple test objectives (“simulations”) with a known Pareto front (closure test 1). We also show the feasibility of distributing these simulations across various HPC/HTC clusters using the PanDA framework [11] (closure test 2). Following closure test 1, we replace the test functions with the ePIC software (compute-intensive simulations and reconstruction). The final step is a full integration, where the ePIC software is coupled with a distributed AI-assisted framework that asynchronously orchestrates the design points suggested by AI.

The primary goal of Closure Test 1 is to evaluate the complexity of the optimization algorithm for convergence with up to 5 objectives and 𝒪(100)𝒪100\mathcal{O}(100)caligraphic_O ( 100 ) design parameters. This test identifies bottlenecks in multi-objective Bayesian optimization algorithms and helps deploy the AID(2)E framework for complex optimization problems. A realistic test function is chosen to pinpoint choke points. Improvements are achieved by reducing computational time and space complexity or the number of iterations needed for convergence. Closure Test 1 uses a test function with a known Pareto front to evaluate convergence. The DTLZ-2 problem is selected for this purpose, defined as follows. Given n𝑛nitalic_n decision variables and M𝑀Mitalic_M objectives, where M2𝑀2M\geq 2italic_M ≥ 2, the decision vector x=[x1,x2,,xn]𝑥subscript𝑥1subscript𝑥2subscript𝑥𝑛x=[x_{1},x_{2},\ldots,x_{n}]italic_x = [ italic_x start_POSTSUBSCRIPT 1 end_POSTSUBSCRIPT , italic_x start_POSTSUBSCRIPT 2 end_POSTSUBSCRIPT , … , italic_x start_POSTSUBSCRIPT italic_n end_POSTSUBSCRIPT ] is subject to the constraints 0xi10subscript𝑥𝑖10\leq x_{i}\leq 10 ≤ italic_x start_POSTSUBSCRIPT italic_i end_POSTSUBSCRIPT ≤ 1 for i=1,2,,n𝑖12𝑛i=1,2,\ldots,nitalic_i = 1 , 2 , … , italic_n, and g(x)=i=Mn(xi0.5)2cos(20π(xi0.5))0𝑔𝑥superscriptsubscript𝑖𝑀𝑛superscriptsubscript𝑥𝑖0.5220𝜋subscript𝑥𝑖0.50g(x)=\sum_{i=M}^{n}(x_{i}-0.5)^{2}-\cos(20\pi(x_{i}-0.5))\leq 0italic_g ( italic_x ) = ∑ start_POSTSUBSCRIPT italic_i = italic_M end_POSTSUBSCRIPT start_POSTSUPERSCRIPT italic_n end_POSTSUPERSCRIPT ( italic_x start_POSTSUBSCRIPT italic_i end_POSTSUBSCRIPT - 0.5 ) start_POSTSUPERSCRIPT 2 end_POSTSUPERSCRIPT - roman_cos ( 20 italic_π ( italic_x start_POSTSUBSCRIPT italic_i end_POSTSUBSCRIPT - 0.5 ) ) ≤ 0. The objective functions are defined as:

f1(x)subscript𝑓1𝑥\displaystyle f_{1}(x)italic_f start_POSTSUBSCRIPT 1 end_POSTSUBSCRIPT ( italic_x ) =(1+g(x))cos(x1π2)cos(x2π2)cos(xM1π2)absent1𝑔𝑥subscript𝑥1𝜋2subscript𝑥2𝜋2subscript𝑥𝑀1𝜋2\displaystyle=(1+g(x))\cos\left(x_{1}\frac{\pi}{2}\right)\cos\left(x_{2}\frac{% \pi}{2}\right)\dotsm\cos\left(x_{M-1}\frac{\pi}{2}\right)= ( 1 + italic_g ( italic_x ) ) roman_cos ( italic_x start_POSTSUBSCRIPT 1 end_POSTSUBSCRIPT divide start_ARG italic_π end_ARG start_ARG 2 end_ARG ) roman_cos ( italic_x start_POSTSUBSCRIPT 2 end_POSTSUBSCRIPT divide start_ARG italic_π end_ARG start_ARG 2 end_ARG ) ⋯ roman_cos ( italic_x start_POSTSUBSCRIPT italic_M - 1 end_POSTSUBSCRIPT divide start_ARG italic_π end_ARG start_ARG 2 end_ARG )
f2(x)subscript𝑓2𝑥\displaystyle f_{2}(x)italic_f start_POSTSUBSCRIPT 2 end_POSTSUBSCRIPT ( italic_x ) =(1+g(x))cos(x1π2)cos(x2π2)sin(xM1π2)absent1𝑔𝑥subscript𝑥1𝜋2subscript𝑥2𝜋2subscript𝑥𝑀1𝜋2\displaystyle=(1+g(x))\cos\left(x_{1}\frac{\pi}{2}\right)\cos\left(x_{2}\frac{% \pi}{2}\right)\dotsm\sin\left(x_{M-1}\frac{\pi}{2}\right)= ( 1 + italic_g ( italic_x ) ) roman_cos ( italic_x start_POSTSUBSCRIPT 1 end_POSTSUBSCRIPT divide start_ARG italic_π end_ARG start_ARG 2 end_ARG ) roman_cos ( italic_x start_POSTSUBSCRIPT 2 end_POSTSUBSCRIPT divide start_ARG italic_π end_ARG start_ARG 2 end_ARG ) ⋯ roman_sin ( italic_x start_POSTSUBSCRIPT italic_M - 1 end_POSTSUBSCRIPT divide start_ARG italic_π end_ARG start_ARG 2 end_ARG )
f3(x)subscript𝑓3𝑥\displaystyle f_{3}(x)italic_f start_POSTSUBSCRIPT 3 end_POSTSUBSCRIPT ( italic_x ) =(1+g(x))cos(x1π2)cos(x2π2)sin(xM2π2)absent1𝑔𝑥subscript𝑥1𝜋2subscript𝑥2𝜋2subscript𝑥𝑀2𝜋2\displaystyle=(1+g(x))\cos\left(x_{1}\frac{\pi}{2}\right)\cos\left(x_{2}\frac{% \pi}{2}\right)\dotsm\sin\left(x_{M-2}\frac{\pi}{2}\right)= ( 1 + italic_g ( italic_x ) ) roman_cos ( italic_x start_POSTSUBSCRIPT 1 end_POSTSUBSCRIPT divide start_ARG italic_π end_ARG start_ARG 2 end_ARG ) roman_cos ( italic_x start_POSTSUBSCRIPT 2 end_POSTSUBSCRIPT divide start_ARG italic_π end_ARG start_ARG 2 end_ARG ) ⋯ roman_sin ( italic_x start_POSTSUBSCRIPT italic_M - 2 end_POSTSUBSCRIPT divide start_ARG italic_π end_ARG start_ARG 2 end_ARG )
\displaystyle\vdots
fM1(x)subscript𝑓𝑀1𝑥\displaystyle f_{M-1}(x)italic_f start_POSTSUBSCRIPT italic_M - 1 end_POSTSUBSCRIPT ( italic_x ) =(1+g(x))cos(x1π2)sin(x2π2)absent1𝑔𝑥subscript𝑥1𝜋2subscript𝑥2𝜋2\displaystyle=(1+g(x))\cos\left(x_{1}\frac{\pi}{2}\right)\sin\left(x_{2}\frac{% \pi}{2}\right)= ( 1 + italic_g ( italic_x ) ) roman_cos ( italic_x start_POSTSUBSCRIPT 1 end_POSTSUBSCRIPT divide start_ARG italic_π end_ARG start_ARG 2 end_ARG ) roman_sin ( italic_x start_POSTSUBSCRIPT 2 end_POSTSUBSCRIPT divide start_ARG italic_π end_ARG start_ARG 2 end_ARG )
fM(x)subscript𝑓𝑀𝑥\displaystyle f_{M}(x)italic_f start_POSTSUBSCRIPT italic_M end_POSTSUBSCRIPT ( italic_x ) =(1+g(x))sin(x1π2)absent1𝑔𝑥subscript𝑥1𝜋2\displaystyle=(1+g(x))\sin\left(x_{1}\frac{\pi}{2}\right)= ( 1 + italic_g ( italic_x ) ) roman_sin ( italic_x start_POSTSUBSCRIPT 1 end_POSTSUBSCRIPT divide start_ARG italic_π end_ARG start_ARG 2 end_ARG )

Here, g(x)𝑔𝑥g(x)italic_g ( italic_x ) is the sum constraint defined earlier. The solution to this multi-objective function is satisfied when at least M𝑀Mitalic_M design variables meet the condition xi=0.5subscript𝑥𝑖0.5x_{i}=0.5italic_x start_POSTSUBSCRIPT italic_i end_POSTSUBSCRIPT = 0.5 for i=1,2,,M𝑖12𝑀i=1,2,\ldots,Mitalic_i = 1 , 2 , … , italic_M. This function is chosen because, like real-world scenarios, not all design variables influence every objective. The true Pareto front for the DTLZ-2 problem is known for given n𝑛nitalic_n design variables and M𝑀Mitalic_M objectives. The convergence criterion is based on the computed hyper-volume, with a tolerance of 5%percent55\%5 % to the true hyper-volume:

|HVtrueHVi|HVtrue5%subscriptHVtruesubscriptHV𝑖subscriptHVtruepercent5\frac{|\text{HV}_{\text{true}}-\text{HV}_{i}|}{\text{HV}_{\text{true}}}\leq 5\%divide start_ARG | HV start_POSTSUBSCRIPT true end_POSTSUBSCRIPT - HV start_POSTSUBSCRIPT italic_i end_POSTSUBSCRIPT | end_ARG start_ARG HV start_POSTSUBSCRIPT true end_POSTSUBSCRIPT end_ARG ≤ 5 %

To understand the optimization algorithm’s complexity and bottlenecks, we study the time and space complexity as functions of M𝑀Mitalic_M objectives and n𝑛nitalic_n design variables. The overall complexity is the convolution of the complexities in building the surrogate model and using the acquisition function. Current studies evaluate these complexities at each step of the Bayesian process. Preliminary results are shown in Fig. 3.

Refer to caption
Refer to caption
Figure 3: Results from closure test (Left) The figure depicts the total explored points before DTLZ-2 convergence as a function of design parameters (n𝑛nitalic_n). Each trial was repeated for statistical robustness, with varying colors indicating a different number of objective. The process continued until either 1000 points were explored or convergence was reached, except for cases with n=[50,100]𝑛50100n=[50,100]italic_n = [ 50 , 100 ] and m=4𝑚4m=4italic_m = 4 where convergence was not achieved. A comparison with expected computational complexity is underway. (Right) The figure illustrates the time complexity of the qNEHVI acquisition function. According to [10], it is 𝒪(m(N+I)m)𝒪𝑚superscript𝑁𝐼𝑚\mathcal{O}(m\cdot(N+I)^{m})caligraphic_O ( italic_m ⋅ ( italic_N + italic_I ) start_POSTSUPERSCRIPT italic_m end_POSTSUPERSCRIPT ), where N𝑁Nitalic_N is the observed points and I𝐼Iitalic_I is partitions in the cached box decomposition. Further studies on varying design parameters and standard latency are in progress to elaborate on the problem’s complexity.

Future work will extend this to more combinations of surrogate models and acquisition functions to verify the complexities reported in the literature.

Closure Test 2 aims to efficiently distribute simulations for various optimization tasks through three stages of parallelization. First, multi-processing within a single node is used when simulation time is negligible compared to queue time. This is parallelized with Joblib, as in Closure Test 1. Second, parallelization with HPC workload managers like SLURM and PBS is applied when simulation time is comparable to queue time. Third, parallelization with PanDA [11] —a data-driven workload management system designed for the LHC data processing scale— is used when the simulation time is much longer than the queue wait time for job submission. Closure Test 2 objectives are to integrate the optimization pipeline to use PanDA for evaluating design points and to integrate the ePIC software stack with PanDA for detector design evaluation. PanDA offers advantages such as OIDC authentication for cross-site submissions and PanDA Monitor for job status tracking. Ongoing efforts include creating authentication pipelines and retrieving information from various sites.

Applications to the ePIC Detector

We are currently optimizing two detection systems in ePIC: the dual-RICH (dRICH) in the central region and the B0 detector in the forward region.

The dual-radiator Ring Imaging Cherenkov detector (dRICH) will provide charged-hadron particle ID in the forward rapidity region of ePIC for a wide momentum range of 2GeV/c<p<50GeV/csimilar-toabsent2GeV𝑐𝑝50GeV𝑐\sim 2\,\text{GeV}/c<p<50\,\text{GeV}/c∼ 2 GeV / italic_c < italic_p < 50 GeV / italic_c [13, 2]. The objective of this optimization is to improve pion-kaon and kaon-proton separation, as well as acceptance, at both low and high momentum across the full η𝜂\etaitalic_η range covered by the dRICH. An initial study applying MOBO to the design of the ePIC dRICH has been conducted, with design points evaluated using the ePIC full simulation. The design parameters used in this optimization are the aerogel disk radius, the spherical mirror position (z,x) and radius (with the z position constrained such that the mirror backplane is within 4 cm of the dRICH back wall), and the photosensor sphere position (z,x) and radius (with the z position constrained such that sensors are within the sensor box required for services). This totals seven design parameters with two hard constraints on the search space. Overlap checks are conducted for each sampled design point before simulation. For each design point, 1000 K+superscript𝐾K^{+}italic_K start_POSTSUPERSCRIPT + end_POSTSUPERSCRIPT and 1000 π+superscript𝜋\pi^{+}italic_π start_POSTSUPERSCRIPT + end_POSTSUPERSCRIPT particles are simulated in six p/η𝑝𝜂p/\etaitalic_p / italic_η ranges. The momentum values are 15GeV/c15GeV𝑐15\,\text{GeV}/c15 GeV / italic_c and 40GeV/c40GeV𝑐40\,\text{GeV}/c40 GeV / italic_c, at the upper edge of the momentum range covered by each radiator. The η𝜂\etaitalic_η ranges sampled are [1.3,2.0],[2.0,2.5],[2.5,3.5]1.32.02.02.52.53.5[1.3,2.0],\;[2.0,2.5],\;[2.5,3.5][ 1.3 , 2.0 ] , [ 2.0 , 2.5 ] , [ 2.5 , 3.5 ]. Following [2], the objectives chosen for this test optimization are the Nσ𝑁𝜎N\sigmaitalic_N italic_σ pion-kaon separation for the low and high η𝜂\etaitalic_η ranges, computed as

NσπK=|θKθπ|Nphotonsσθ,𝑁subscript𝜎𝜋𝐾delimited-⟨⟩subscript𝜃𝐾delimited-⟨⟩subscript𝜃𝜋delimited-⟨⟩subscript𝑁photonssubscript𝜎𝜃N\sigma_{\pi-K}=\frac{|\langle\theta_{K}\rangle-\langle\theta_{\pi}\rangle|% \sqrt{\langle N_{\text{photons}}\rangle}}{\sigma_{\theta}},italic_N italic_σ start_POSTSUBSCRIPT italic_π - italic_K end_POSTSUBSCRIPT = divide start_ARG | ⟨ italic_θ start_POSTSUBSCRIPT italic_K end_POSTSUBSCRIPT ⟩ - ⟨ italic_θ start_POSTSUBSCRIPT italic_π end_POSTSUBSCRIPT ⟩ | square-root start_ARG ⟨ italic_N start_POSTSUBSCRIPT photons end_POSTSUBSCRIPT ⟩ end_ARG end_ARG start_ARG italic_σ start_POSTSUBSCRIPT italic_θ end_POSTSUBSCRIPT end_ARG ,

where θdelimited-⟨⟩𝜃\langle\theta\rangle⟨ italic_θ ⟩ is the average reconstructed Cherenkov angle for pions/kaons, Nphotonsdelimited-⟨⟩subscript𝑁photons\langle N_{\text{photons}}\rangle⟨ italic_N start_POSTSUBSCRIPT photons end_POSTSUBSCRIPT ⟩ is the average number of reconstructed photons per track, and σθsubscript𝜎𝜃\sigma_{\theta}italic_σ start_POSTSUBSCRIPT italic_θ end_POSTSUBSCRIPT is the Cherenkov angle resolution from a Gaussian fit to the Cherenkov angle residual, averaged over pions and kaons. NσπK𝑁subscript𝜎𝜋𝐾N\sigma_{\pi-K}italic_N italic_σ start_POSTSUBSCRIPT italic_π - italic_K end_POSTSUBSCRIPT is averaged over the two momentum points for each η𝜂\etaitalic_η range. This optimization was carried out with 50 initial Sobol points, a SAASBO surrogate model, and a qNEHVI acquisition function, with the optimization executed for 200 total evaluations in batches of 10.111Definitions of Sobol points, SAASBO and qNEHVI can be found in the tutorial [14]. Convergence was achieved after 150 trials. Preliminary Pareto-optimal points found after these trials include potential designs that outperform the nominal dRICH geometry. Initial results shown at the dRICH working group meetings of ePIC suggest that while the nominal dRICH geometry is well-optimized for the large η𝜂\etaitalic_η region, the MOBO algorithm identifies opportunities for improvement within the available design space.

Far-forward detectors [15] measure very forward neutral and charged particles [16]. The EIC far-forward detectors consist of four independent subsystems: B0 Tracking and Photon Detection, Roman Pots, Off-Momentum Detectors, and the Zero-Degree Calorimeter. The B0 system measures charged particles in the forward direction and tags neutral particles. Off-momentum detectors measure charged particles from decays and fission, Roman pot detectors measure charged particles near the beam, and the zero-degree calorimeter measures neutral particles at small angles. The optimization objective for the B0 ECAL calorimeter is to improve momentum resolution under a non-homogeneous magnetic field while simultaneously increasing the B0 ECAL acceptance. Acceptance is defined as the ratio of the number of tracks before the first tracking disk to the number of showers detected by the B0 ECAL. This is challenging because the magnetic field peaks within a limited range in z𝑧zitalic_z, and moving it to extremes can disrupt acceptance. There are four main design parameters, specifically the disk z positions. Some constraints have also been applied to reflect the real scenario, such as all trackers should be placed within 6.65 m, and the sum of the z-positions of two subsequent trackers should be 10absent10\geq 10≥ 10 cm.

A visualization of the sub-detecting systems described in this section is shown in Fig. 4.

Refer to caption
Refer to caption
Figure 4: Sub-detector system in ePIC optimized with AID2E: (left) the dRICH design is characterized by two radiators (aerogel and gas) and 6 identical sectors with photosensors [17]; (right) The B0 Tracker and the B0 ECAL detector. The magnetic field in the B0 Region is inhomogenous making the optimization more challenging.

3 Broader Impact and Future Work

Our work with the dRICH and B0 sub-detectors at the ePIC experiment demonstrates the potential for extending our methodologies to other sub-detector systems, tailoring to the ePIC detector needs. Following the approach implemented in [3], the tracking system preceding the dRICH is a prime candidate for further optimization in combination with the dRICH. This method is largely experiment-agnostic and applicable to various detection systems, although MOBO currently handles up to four objective functions effectively. For more complex scenarios, the MOGA approach currently available within the AID2E framework offers a viable alternative.

Large-scale, compute-intensive applications often face resource-based limitations that hinder iterative development, training, and optimization. Our framework facilitates AI/ML workflows across geographically distributed, multi-platform sites, significantly enhancing the scalability and accessibility for researchers. This reduces barriers from small-scale development to large-scale deployment, enabling deeper and more complex model processing that can yield substantial scientific benefits. The potential applications of this framework include: (i) Design of future large-scale experiments in nuclear physics and high-energy physics, such as the early-stage second EIC detector, optimizing for complementarity with the ePIC detector across their full physics reach; (ii) Alignments and calibrations, addressing compute-intensive and multi-objective needs in detector operations; (iii) Multi-objective hyperparameter optimization for deep neural networks, aiming to balance network performance against complexity, as shown in [18].

4 Documentation and Outreach

We will employ GitBook along with other knowledge-sharing platforms to support our documentation and outreach efforts, ensuring that these resources are easily accessible to beginners. Automated documentation will be implemented using a Retrieval-Augmented Generation (RAG)-based approach, as described in [19], with an AI4EIC bot available to the public via a specific URL. The AID(2)E project employs a comprehensive suite of data science tools to analyze the results of various optimizations. Interested readers can refer to [20] for a dashboard that displays the performance of closure tests, and to [4] for an example of interactive navigation of Pareto front solutions from the ECCE tracker design. This project will also feature summer bootcamps on AI-assisted design optimization at William & Mary, incorporating lectures cited in [21] and [22], along with hands-on research activities with the AID(2)E group. Participants will engage in cutting-edge research, learning about AI applications in detector design and data science for physics. Additional information about the project is available in the main repository, detailed in [23].

5 Conclusions

We are actively working to integrate Multi-Objective Optimization with the EIC shell software, and initial results have already been obtained for two detector systems: the dRICH in the central region and the B0 in the far-forward region of ePIC. This development represents a significant milestone, testing the capabilities of our approach in a real-world scenario. Ultimately, our goal is to develop a scalable and distributed framework capable of holistically optimizing large-scale detectors. Detector-2 at the EIC currently presents an ideal application for this framework, considering its developmental stage. During construction phases of detector projects, numerous changes are often necessary, such as adjustments due to material availability or budget constraints. The AID(2)E framework is the ideal tool to optimize these design modifications efficiently, utilizing objectives like cost reduction. Moreover, this framework is poised to have broader impacts beyond its immediate application. It is versatile enough to be adapted for various experimental setups and is particularly well-suited for compute-intensive tasks that require Multi-Objective Optimization, such as calibrations and alignments or optimization of complex machine learning pipelines.

Acknowledgments

C.F., K.S. and H.N. were supported by the Office of Nuclear Physics of the U.S. Department of Energy under Grant Contract No. DE-SC0024625, C.P. and K.N. were supported by the Office of Nuclear Physics of the U.S. Department of Energy under Grant Contract No. DE-SC0024478

References

  • Ent [2022] R. Ent. Electron Ion Collider, 2022. JLUO Meeting on NSAC Long Range Plan.
  • Cisbani et al. [2020a] E. Cisbani, A. Del Dotto, C. Fanelli, M. Williams, et al. Ai-optimized detector design for the future electron-ion collider: the dual-radiator rich case. Journal of Instrumentation, 15(05):P05009, may 2020a. doi: 10.1088/1748-0221/15/05/P05009. URL https://dx.doi.org/10.1088/1748-0221/15/05/P05009.
  • Fanelli et al. [2023] C. Fanelli et al. AI-assisted optimization of the ECCE tracking system at the Electron Ion Collider. Nucl. Instrum. Methods Phys. Res. A, 1047:167748, 2023. ISSN 0168-9002. doi: https://doi.org/10.1016/j.nima.2022.167748. URL https://www.sciencedirect.com/science/article/pii/S0168900222010403.
  • [4] Interactive visualization of the Pareto front in a Geant4-based design for ECCE. https://ai4eicdetopt.pythonanywhere.com/.
  • Bernauer et al. [2022] JC Bernauer, CT Dean, C Fanelli, J Huang, K Kauder, D Lawrence, JD Osborn, C Paus, JK Adkins, Y Akiba, et al. Scientific computing plan for the ECCE detector at the Electron Ion Collider. Nuclear Instruments and Methods in Physics Research Section A: Accelerators, Spectrometers, Detectors and Associated Equipment, page 167859, 2022.
  • Frazier [2018] Peter I Frazier. A tutorial on Bayesian optimization. 2018.
  • Deb et al. [2002] Kalyanmoy Deb, Amrit Pratap, Sameer Agarwal, and TAMT Meyarivan. A fast and elitist multiobjective genetic algorithm: NSGA-II. IEEE transactions on evolutionary computation, 6(2):182–197, 2002.
  • Balandat et al. [2019] M Balandat, B Karrer, Daniel R. Jiang, S Daulton, and et. al. BoTorch: A Framework for Efficient Monte-Carlo Bayesian Optimization. 2019. doi: 10.48550/ARXIV.1910.06403. URL https://arxiv.longhoe.net/abs/1910.06403.
  • [9] Eytan Bakshy, Max Balandat, and Kostya Kashin. Open-sourcing Ax and BoTorch: New AI tools for Adaptive Experimentation. URL https://ai.facebook.com/blog/open-sourcing-ax-and-botorch-new-ai-tools-for-adaptive-experimentation/.
  • Daulton et al. [2021] Samuel Daulton, Maximilian Balandat, and Eytan Bakshy. Parallel bayesian optimization of multiple noisy objectives with expected hypervolume improvement, 2021.
  • Maeno et al. [2024] Tadashi Maeno, Aleksandr Alekseev, Fernando Harald Barreiro Megino, Kaushik De, Wen Guan, Edward Karavakis, Alexei Klimentov, Tatiana Korchuganova, FaHui Lin, Paul Nilsson, Torre Wenaus, Zhaoyu Yang, and Xin Zhao. Panda: Production and distributed analysis system. Computing and Software for Big Science, 8(1):4, 2024. ISSN 2510-2044. doi: 10.1007/s41781-024-00114-3. URL https://doi.org/10.1007/s41781-024-00114-3.
  • Lawrence, David [2024] Lawrence, David. Eic software overview. EPJ Web of Conf., 295:03011, 2024. doi: 10.1051/epjconf/202429503011. URL https://doi.org/10.1051/epjconf/202429503011.
  • Vallarino et al. [2024] S. Vallarino, M. Alexeev, P. Antonioli, L. Barion, M. Castro, M. Cavallina, M. Chiosso, E. Cisbani, M. Contalbrigo, A. Grisel Torres Ramos, D. Lattuada, F. Mammoliti, R. Malaguti, M. Mirazita, F. Noto, R. Preghenella, L.P. Rignanese, N. Rubini, M. Ruspa, C. Tuvé, and G. Volpe. Prototype of a dual-radiator rich detector for the electron–ion collider. Nuclear Instruments and Methods in Physics Research Section A: Accelerators, Spectrometers, Detectors and Associated Equipment, 1058:168834, 2024. ISSN 0168-9002. doi: https://doi.org/10.1016/j.nima.2023.168834. URL https://www.sciencedirect.com/science/article/pii/S0168900223008252.
  • [14] High-Dimensional Bayesian Optimization with SAASBO. URL https://ax.dev/versions/0.2.9/tutorials/saasbo.html. Ax tutorial.
  • Jentsch [2022] Alexander Jentsch. EIC Far Forward Detector Design. In APS April Meeting Abstracts, volume 2022 of APS Meeting Abstracts, page G04.003, April 2022.
  • Abdul Khalek and et. al [2022] R. Abdul Khalek and et. al. Science requirements and detector concepts for the electron-ion collider. Nuclear Physics A, 1026:122447, October 2022. ISSN 0375-9474. doi: 10.1016/j.nuclphysa.2022.122447. URL http://dx.doi.org/10.1016/j.nuclphysa.2022.122447.
  • Cisbani et al. [2020b] E. Cisbani, A. Del Dotto, C. Fanelli, et al. AI-optimized detector design for the future Electron-Ion Collider: the dual-radiator RICH case. J. Instrum., 15(05):P05009, 2020b.
  • eff [2022] Efficient Multi-Objective Neural Architecture Search with Ax, 2022. URL https://pytorch.org/blog/effective-multi-objective-nueral-architecture/#fully-automated-multi-objective-nas-with-ax.
  • Suresh et al. [2024] Karthik Suresh, Neeltje Kackar, Luke Schleck, and Cristiano Fanelli. Towards a RAG-based Summarization Agent for the Electron-Ion Collider. 2024.
  • [20] Multi-Objective Optimization Dashboard - AID(2)E Closure Tests Performance. URL https://wandb.ai/phys-meets-ml/AID2E-Closure-1?workspace=user-karthik18495.
  • Fanelli [2022] C. Fanelli. AI for Detector Design NNPSS-2022, july 2022. URL https://cfteach.github.io/nnpss/intro.html.
  • Fanelli [2023] C. Fanelli. Machine Learning for Nuclear Physics and the Electron Ion Collider, June 2023. URL https://cfteach.github.io/HUGS23/intro.html. The 38th Annual Hampton University Graduate Summer Program at Jefferson Lab.
  • The AIDE Collaboration() [2] The AID(2)E Collaboration. AID(2)E Repository. URL https://github.com/aid2e.