I am currently working on a specialization project on simulating guitar effects with Evolutionary Algorithms, and want to use Python and CSound to do this.
The idea is to generate effect parameters in my algorithm in Python, send them to CSound and apply the filter to the audio file, then send the new audio file back to Python to perform frequency analysis for comparison with the target audio file (this will be done in a loop till the audio file is similar enough to the target audio file, so sending/receiving between CSound and Python will be done alot).
Shortly phrased, how do I get Python to send data to a CSound(.csd file), how do I read the data in the .csd file, and how do I send a .wav file from CSound to Python? It is also preferred that this can work dynamically on its own till the criterions for the audio file is met.
Thanks in advance
You can use Csound's python API, so you can run Csound within python and pass values using the software bus. See csound.h. You might also want to use the csPerfThread wrapper class which can schedule messages to and from Csound when it is running. All functionality is available from python.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With