Replies: 2 comments 1 reply
-
@pgarz Thanks for all the ideas! Using the Pytorch models directly might make it more flexible on the ML side, but I like using RTNeural because it was specifically made for audio, and the benchmarks show that for smaller models it is significantly faster for real-time. I'm definitely not opposed to testing things out, or even making a full plugin to show how it can be done. Using the M1 chipset to optimize training would be awesome. Basically I'm for any of those things you would like to do, but I would want to fully test things out and ensure it offers a performance or feature improvement for the end user before implementing into the official GuitarML main branches. It might be beneficial to create a new repo to test using a fully Pytorch workflow, or when trying new model architectures. The current repo I use for ML training is: https://github.com/GuitarML/Automated-GuitarAmpModelling Not sure if you were looking at PedalNetRT, but I haven't touched that in awhile. The above repo contains support for wavenet training and I'd recommend starting there, but I do like the pytorch-lightning implementations when feasible. The more DAW's we can support the better, Logic is one I definitely want to keep supporting. I didn't have any issues running in Logic when I had the free trial, but if you find anything you can create a new issue. Thanks and let me know what you think! |
Beta Was this translation helpful? Give feedback.
-
@pgarz Indeed! Time-based real-time with neural nets will be a challenge. Any small optimizations in processing the neural nets would be a huge benefit, since we're interested in running the net at 44.1kHz or higher. Also, knowing that we're touching on the same subjects as Apple's research is very exciting. |
Beta Was this translation helpful? Give feedback.
-
Firstly, let me introduce myself. I'm Pedro Garzon, professionally an ML engineer at a startup doing AI for scientific simulations. I have a background in AI from Stanford as well. More importantly, I've had the same idea of making a neural guitar pedal before. So glad someone started the groundwork foundations! I've spent most of my free time over quarantine just practicing guitar and exploring tones. I've been catching up on DL for audio and I really think 2022 can be a break-out year to making a supremely affordable neural pedal. I've got some ideas
Here are some technical infrastructure ideas
Build PyTorch support
std::vector<torch::jit::IValue> inputs; inputs.push_back(torch::ones({1, 3, 224, 224})); // Execute the model and turn its output into a tensor. at::Tensor output = module.forward(inputs).toTensor();
One could also convert PyTorch to ONNX and run the models on the ONNX C++ runtime, which can be faster at smaller batch sizes
It appears one could load PyTorch directly on a Rasberry Pi, but the hardware costs go up considerably. Instead it might make more sense to build for on computer processing https://qengineering.eu/install-pytorch-on-raspberry-pi-4.html
Build-in support for M1 chip training
It seems the M1 series of chips have a bright future in audio production: https://www.waves.com/apple-m1-for-music-producers
It's already possible to run Pytorch directly on M1 chips https://towardsdatascience.com/yes-you-can-run-pytorch-natively-on-m1-macbooks-and-heres-how-35d2eaa07a83
Leveraging M1 computation could be a computational breakthrough and squeezing real-time performance out of more complicated network architectures.
With PyTorch, we could take advantage of Pytorch Lightning as well and highly organize the data-loading and model training code to be extremely modular and readable
Support for on local computer recording
We're quite limited by the current memory/CPU capabilities of the RasberryPi setup. So it would be ideal to also have Pytorch models be capable of running locally on the host computer running a DAW for recording
There also might be a way to use the RasberryPi as the main interface for the guitar. So we could have a chain going guitar -> RasberryPi -> host computer for processing -> back to RasberryPi -> real-world amp
Logic Pro X support
And here are some very brief avenues of exploring richer network architectures:
Transformers, VQ-VAE, WaveNet-like architectures, Diffusion models, Fourier Transform tricks
All of which have PyTorch implementations!
Eager to hear feedback! Def the first step is point number building out a tighter PyTorch infrastructure
Beta Was this translation helpful? Give feedback.
All reactions