MoreFit: A More Optimised, Rapid and Efficient Fit
Christoph Langenbruch
TL;DR
MoreFit tackles the computational bottlenecks of unbinned maximum likelihood fits in high-energy physics by introducing computation graphs that are compiled just-in-time and executed on heterogeneous backends via OpenCL and LLVM. The framework enables analytic derivatives through symbolic differentiation, automatic buffering of parameter- and event-dependent terms, and automatic optimisation to reduce redundant calculations, significantly speeding up both the fit and generation of pseudoexperiments. Benchmark results against RooFit and zfit demonstrate substantial speedups on CPU and GPU, including orders-of-magnitude improvements in some scenarios, underscoring the value of parallelism and automatic optimisations for large-scale parameter inference. By relying on open standards and a lightweight C++ design, MoreFit aims for broad usability and future expansion to more PDFs, acceptance corrections, and potentially binned fits, enabling more robust and scalable statistical analyses in particle physics.
Abstract
Parameter estimation via unbinned maximum likelihood fits is a central technique in particle physics. This article introduces MoreFit, which aims to provide a more optimised, rapid and efficient fitting solution for unbinned maximum likelihood fits. MoreFit is developed with a focus on parallelism and relies on computation graphs that are compiled just-in-time. Several novel automatic optimisation techniques are employed on the computation graphs that significantly increase performance compared to conventional approaches. MoreFit can make efficient use of a wide range of heterogeneous platforms through its compute backends that rely on open standards. It provides an OpenCL backend for execution on GPUs of all major vendors, and a backend based on LLVM and Clang for single- or multithreaded execution on CPUs, which in addition allows for SIMD vectorisation. MoreFit is benchmarked against several other fitting frameworks and shows very promising performance, illustrating the power of the approach.
