Audio ML on Bare Metal
GEMM, Memory Layout, and Real-Time Dataflow on Embedded ARM
Audio hardware built around classical DSPs and embedded CPUs (guitar amps, pedals, synths) wasn't designed with machine learning in mind. Yet, Neural Amp Modeler (NAM) can be made to run on the ubiquitous ARM Cortex-M7 at 2x real-time, and models with hundreds of parameters can be trained in tens of milliseconds on the RP2350, a £1 chip. This talk is all about taking a trained model and getting it to run in real time on hardware that has no NPU and no GPU. The core of any ML model is the General Matrix Multiply (GEMM), but on these chips the matrix multiplication is only part of the story — real-time performance comes just as much from the memory layout, weight and data ordering, and streaming dataflow.
We'll work through two case studies that sit at opposite ends of the embedded ML trade-off. First, Neural Amp Modeler's WaveNet-style A2 architecture for modelling amps and other nonlinear audio systems, running on devices from the ARM Cortex-M7 to the A73 — where the bottleneck is dataflow, not arithmetic. Second, meMLP, a lightweight engine for training small neural networks directly on embedded devices, running on the ultra-low-power Cortex-M33 — where the GEMM kernel itself is the hard problem. For each, we'll show how chip pipeline design, memory layout, and weight/data ordering determine whether you hit real time or not.
You'll leave with a practical understanding of how to map ML computation onto an embedded chip's actual hardware features, what the memory trade-offs look like, and benchmarking results showing what NAM A2-Lite and meMLP actually achieve on these chips. If your product has a DSP in it, this talk is about finding out what it can really do in the ML era.
Andrea Martelloni
Andrea is a DSP Engineer and a PhD in Artificial Intelligence and Music at Queen Mary University of London. Currently at Blackstar Amplification, he worked on porting Neural Amp Modeler onto the BEAM range of digital guitar processing devices. Previously, he co-created the meMLP library to allow training ML models directly on musical instruments, and developed the HITar (MIDI Innovation Awards 2023 winner). His ADC 2023 talk “Deep learning for DSP engineers” was co-presented alongside Franco Caspe.