Tuesday, November 17, 2026

nam-cpu-trainer

A couple of months ago I released the first version of nam-cpu-trainer, a Neural Amp Modeler (NAM) trainer designed for high performance on CPUs.

NAM training on CPU has historically been impractical since the pytorch-based official trainer is notoriously slow if you aren't running it with a GPU (that isn't the nam trainer's fault, really - pytorch on CPU is just slow).

A while back I decided to work on a project to improve my understanding of modern neural network learning methods. The result of that is  cpugrad, a fully custom, CPU-based machine learning library focused primarily (currently, anyway) on time series data (ie: audio samples).

nam-cpu-trainer was my first major test of a real-world problem using cpugrad. It has come along so well that, in the latest release, it now supports all of the functionality needed to train NAM A2 models. Accuracy in my testing is on par or better than the official nam trainer, and CPU training performance is comparable to an equivalent-tier GPU. Ie: don't expect your old laptop CPU to outperform an RTX 5090, but my Ryzen 7 5700x using nam-cpu-trainer outperforms pytorch on my RX6700 GPU. 

SpiceForge - a LiveSPICE-based audio circuit editor and live simulator

I recently released the first version of a SpiceForge, a cross-platform circuit editor and live simulator built on top of the foundation of LiveSPICE.

Key features over LiveSPICE are a new circuit simulator that supports fully dynamic pots and switches, a cross-platform editing and simulation front-end app, and a cross-platform audio backend (currently ASIO and JACK).

 

Saturday, May 23, 2026

Building for Raspberry Pi using Github Actions

While Raspberry Pi SBCs have gotten significantly more powerful over the years, they are still pretty limited compared to a PC when it come to compiling. Building a complicated project on a Pi4 or even a Pi5 can be slow, and it is easy to run out of memory when compiling on the smaller (ie: 1-2GB) versions.

I wanted to provide release binaries for Raspberry Pi for several of my GitHub projects, and didn't want to do a manual build and upload. Fortunately, with a bit of digging, I found and was able to use Pieter Pas'  docker-arm-cross-toolchain to build for Raspberry Pi using GitHub actions.

Here is an example snippet for setting up a Pi4/Pi5 build matrix in a Github action:

name: Raspberry Pi Build on: workflow_dispatch: jobs: build-rpi: name: Build Raspberry Pi strategy: matrix: native_arch: [rpi4, rpi5] runs-on: ubuntu-latest container: image: ghcr.io/tttapa/docker-arm-cross-toolchain:aarch64-rpi3-linux-gnu-gcc12 steps: ...do something

Note the "gcc12" at the end of the docker image path. This ensures that your RPi build will work on RPi OS versions going back to Bookworm.

When you get to building, assuming that you are using CMake, you can specify the build tools by using:

-DCMAKE_TOOLCHAIN_FILE=/home/develop/opt/x-tools/aarch64-rpi3-linux-gnu/aarch64-${{ matrix.native_arch }}-linux-gnu.toolchain.cmake

You can see this at work in myneural-amp-modeler-lv2 and NeuralAudio GitHub repositories. Have a look at the "release" GitHub actions.