24–28 Aug 2026
Kirchhoff Institute for Physics (KIP)
Europe/Berlin timezone

Enabling portable and optimized Machine Learning Inference through code generation

27 Aug 2026, 14:20
8m
3.404

3.404

Real-time Data Processing 🔀 Real-Time Data Processing

Speaker

Sanjiban Sengupta (CERN, University of Manchester)

Description

SOFIE, or the System for Optimized Fast Inference code Emit, is a tool developed by the ML4EP team at CERN that translates trained machine learning models into self-contained, low-latency C++ code. The generated code is portable, hardware-agnostic, and highly optimized while depending only on BLAS libraries.

Code generated by SOFIE achieves portability across different hardware architectures by leveraging the abstract buffer definitions provided by the alpaka[1] library for heterogeneous programming. In addition to generating portable C++ code, SOFIE incorporates several optimization methods that improve inference efficiency, including aggressive kernel fusion, efficient memory allocation and management, and support for inference on quantized models.

Beyond model inference, SOFIE serves as a component in several projects. These include Yukti, a header-only interface that provides a unified zero-copy API for machine learning inference runtimes. Furthermore, SOFIE is used in RooFit as a neural surrogate for likelihood evaluation, with automatic differentiation provided by CLAD, a source-to-source automatic differentiation tool for C++. Embedding BOA Constrictor[2], SOFIE provides a hardware-agnostic pipeline for highly optimized compression and decompression while remaining independent of the underlying hardware architecture.

[1] Matthes, A., Widera, R., Zenker, E., Worpitz, B., Huebl, A., & Bussmann, M. (2017, June 30). Tuning and optimization for a variety of many-core architectures without changing a single line of implementation code using the Alpaka library. Retrieved from http://arxiv.org/abs/1706.10086
[2] Gupta, A., Doglioni, C., & Elliott, T. J. (2026). BOA constrictor: a Mamba-based lossless compressor for scientific data. Machine Learning: Science and Technology, 7(3), 035014. doi:10.1088/2632-2153/ae64a9

Authors

Sanjiban Sengupta (CERN, University of Manchester) Dr Lorenzo Moneta (CERN)

Co-authors

Presentation materials

There are no materials yet.