anira-project / anira

an architecture for neural network inference in real-time audio applications
Apache License 2.0
83 stars 1 forks source link

Stereo inference? #1

Open leoauri opened 4 weeks ago

leoauri commented 4 weeks ago

Hi!

I'm considering using anira for a project. I see notes that stereo inference is not fully implemented yet. What's missing?

Thanks :) Leo

faressc commented 3 weeks ago

Hi Leo, Thanks for reaching out. There are quite a few places in the code that need to be adapted to stereo/multichannel processing. These include the backend processors. I will have an in-depth look what needs to be done and report back. Cheers Fares

leoauri commented 3 weeks ago

Thanks Fares!

faressc commented 3 weeks ago

You’re welcome! One class that already supports multichannel mostly is the InferenceManager. Starting from there all other classes need to be adapted to multi channel processing in a similar way that are in the process or prepare callback. This includes the InferenceThread, InferenceThreadPool, SessionElement and default PrePostProcessor. The ThreadSafeStructs then need to be prepared with multichannel input and output buffers, getting their channel num from the inference config. If you plan on implementing this, let me know if you have further questions. Otherwise as I am currently focusing on the Bela implementation for the next release, it will take me some time to finish this. Cheers!