Here is a video demo of the NeuralPi running neural net models of an overdrive pedal and an all-tube amplifier:
NeuralPi was created out of a curiosity for machine learning and a passion for great guitar tone. I had developed several guitar plugins that use machine learning/neural networks, each building on what I had learned from the previous one. I had always had the idea of using this software to build a guitar pedal in the back of my mind. When I started digging into it, I found that much of the groundwork had already been done to make this a reality.
Using Elk Audio OS, a low latency Linux based operating system, I was able to convert my already developed neural network plugin into stand-alone guitar effect running on the Raspberry Pi 4. The audio card (HiFiBerry DAC+ADC) was selected out of a desire to get the highest quality sound at the cheapest price. In total, I would only have to spend about $150 to build the NeuralPi, and $50 of that was for the enclosure (optional) and the various audio adapters for using guitar cables with the HiFiBerry input/output.
Let me back up, why would someone want to use neural networks for electric guitar? It turns out that certain neural network models are well suited for the task of emulating the dynamic response of amplifiers and pedals (guitar effects). Musicians pay top dollar for amplifiers with expensive vacuum tube components, because they produce the best sound. Using machine learning, you can take input/output recordings of a particular amp and train a model to behave just like the amp circuitry at a specific setting. This method is effective at modeling tube amps and distortion/overdrive, as well as certain aspects of audio compressors.
NeuralPi is a building block for creating any kind of guitar effect pedal you can dream of on the Raspberry Pi. One could modify the open source code to add user controls, model selection, and potentially an interface for recording and creating new models from your own amps and pedals.
A full step-by-step guide to building NeuralPi can be viewed here:
https://link.medium.com/MSP72Dfgxgb
List of parts and typical prices:Here is a list of everything I purchased for the project, all ordered from Amazon except for the HiFiBerry ADC +DAC, which I ordered from Chicago Electronics.
- Raspberry Pi 4b (Amazon), $50 (I’ve seen the Rpi4 on sale for $35)
- Rpi4 Power Adapter (USB-C connector, 5.1V — 3.5A) $10
- Micro SD card (minimum 8GB, I bought 32GB), $12
- Rpi4 + HiFiBerry compatible enclosure, (you can spend as much or as little as you want here; I bought a customizable enclosure suitable for prototyping, but a different enclosure would be better for a finished product) $20
- HDMI micro to Standard HDMI Adapter Cable (Rpi4 has 2 micro HDMI outputs) $8
- HiFi Berry ADC + DAC, (There is a “pro” version for $65, but I stuck with the standard version) $50
- Dual 1/4" Female to 1/8" Male Stereo Audio Adapter (for plugging the guitar into HifiBerry), $8
- Stereo Male RCA to 1/4" Female Audio Adapter (I bought 1/8" for to use with my headphones, but 1/4" would be the typical guitar pedal output), $8
Total Parts Cost: $166 + Taxes and Shipping
Comments