Swapping a neural network model at runtime.
-
would you be able to share a full working project? i've been working to create something similar, a free plugin for archiving and making old and un-updated free vst effects plugins available for modern pcs (windows only old compressors, unique saturation algorithms, etc), and im happy to help troubleshoot and get something working for everyone! i've been using NAM for my captures but havent had luck getting them to load yet in HISE so ill happily test with AIDA-X if it actually is running in HISE right now
-
@sinewavekid
The snip found in this thread will get you goingHardcoded Neural Network does not work as expected
If anyone wants to start learning about RTneural, here's a snip that contains a model of the ProCo Rat pedal: HiseSnippet 20992.3oc6810imccdcmUKp1Rh1dlDj.ja4...
Forum (forum.hise.audio)
-
awesome thank you! ill try to get one network working smoothly today, then test out some methods to make a combobox to select between networks and also somehow reload/clear/initialize them. my first guess would be to make some function which clears out/resets the old network somehow, a quick chatgpt gave me something like this, but im sure itll need tweaking
// Define the model(s) const var MLmodel_1 = {MODEL1 JSON HERE}; const var MLmodel_2 = {MODEL2 JSON HERE}; const var tf = Engine.createNeuralNetwork("TensorFlowNetwork"); //function to clear/initialize the models (can be linked to a combobox in the future) function loadModel() { tf.clearModel(); tf.reset(); //no idea if this is needed lol tf.loadTensorFlowModel(MLmodel_1); } loadModel();
hopefully it's a start to keep experimenting !
-
@sinewavekid you need to create multiple networks for each model and then select them from the node via the drop down.
-
@Christoph-Hart said in Swapping a neural network model at runtime.:
@sinewavekid you need to create multiple networks for each model and then select them from the node via the drop down.
But, beyond multiple neural models, the CPU usage is not working efficiently even in a single model right now.
Did you fix the high cpu usage problem?
-
@Christoph-Hart
I had assumed that "NeuralNetwork.clearModel()" would allow me to reset the NN, then I could follow with a new "NeuralNetwork.loadTensorFlowModel( var modelJSON)" function call. It obviously doesn't work this way.....but it would be amazing if it could....just sayin...lol. -
@Christoph-Hart awesome thank you for the info that is super helpful! is it possible to then select between them via scripting or by linking to a combobox or slider?
-
@scottmire The photo from HISE Developer for Tinder.
-
@JulesV no.
-
@clevername27 LOL....I feel a bit bad about that. I didn't know it would do that.