Package: dawdreamer
_____                       _____                                                  
 |  __ \                     |  __ \                                                 
 | |  | |   __ _  __      __ | |  | |  _ __    ___    __ _   _ __ ___     ___   _ __ 
 | |  | |  / _` | \ \ /\ / / | |  | | | '__|  / _ \  / _` | | '_ ` _ \   / _ \ | '__|
 | |__| | | (_| |  \ V  V /  | |__| | | |    |  __/ | (_| | | | | | | | |  __/ | |   
 |_____/   \__,_|   \_/\_/   |_____/  |_|     \___|  \__,_| |_| |_| |_|  \___| |_|   
                                                                                     
* * Digital Audio Workstation with Python * *DawDreamerRead theintroductionto DawDreamer, which was presented as a Late-Breaking Demo at the2021 ISMIR Conference.DawDreamer is an audio-processing Python framework supporting coreDAWfeatures and beyond:Composing graphs of multi-channel audio processorsAudio playbackVST instruments and effects(with UI editing and state loading/saving)FAUSTeffects and polyphonic instrumentsTime-stretching and looping, optionally according to Ableton Live warp markersPitch-warpingParameter automation at audio-rate and at pulses-per-quarter-noteParameter automation saving in absolute audio-rate timeMIDI playback in absolute time and PPQN timeMIDI file export in absolute timeRendering and saving multiple processors simultaneouslySupport for theFaust Boxand Signal APIsTranspiling Faust code toJAX/Flaxand other target languages (C++, Rust, Wasm, etc.)Machine learning experiments withQDaxMultiprocessing supportFull support on macOS, Windows, Linux, Google Colab, and Ubuntu DockerfileDawDreamer's foundation isJUCE, with a user-friendly Python interface thanks topybind11. DawDreamer evolved from an earlier VSTi audio "renderer",RenderMan.InstallationmacOS requirements:64-bit Python 3.9 or highermacOS 11.0 or higherWindows requirements:64-bit Python 3.8 or higherLinux requirements:64-bit Python 3.8 or higherInstall withPyPI:pip install dawdreamerAPI Documentationhttps://dirt.design/DawDreamer/Basic ExampleUsing Faust, let's make a stereo sine-tone at 440 Hz and -6 dB. You can run this code as-is.importdawdreamerasdawfromscipy.ioimportwavfileSAMPLE_RATE=44100engine=daw.RenderEngine(SAMPLE_RATE,512)# 512 block sizefaust_processor=engine.make_faust_processor("faust")faust_processor.set_dsp_string("""declare name "MySine";freq = hslider("freq", 440, 0, 20000, 0);gain = hslider("vol[unit:dB]", 0, -120, 20, 0) : ba.db2linear;process = freq : os.osc : _*gain <: si.bus(2);""")print(faust_processor.get_parameters_description())engine.load_graph([(faust_processor,[])])faust_processor.set_parameter("/MySine/freq",440.)# 440 Hzfaust_processor.set_parameter("/MySine/vol",-6.)# -6 dB volumeengine.set_bpm(120.)engine.render(4.,beats=True)# render 4 beats.audio=engine.get_audio()# shaped (2, N samples)wavfile.write('sine_demo.wav',SAMPLE_RATE,audio.transpose())# Change settings and re-renderfaust_processor.set_parameter("/MySine/freq",880.)# 880 Hzengine.render(4.,beats=True)# and so on...Next, let's make a graph with a VST instrument and effect. This graph will be simple, but you can make more complicated ones.importdawdreamerasdawfromscipy.ioimportwavfileSAMPLE_RATE=44100INSTRUMENT_PATH="path/to/instrument.dll"EFFECT_PATH="path/to/effect.dll"engine=daw.RenderEngine(SAMPLE_RATE,512)engine.set_bpm(120.)synth=engine.make_plugin_processor("synth",PLUGIN_PATH)print('inputs:',synth.get_num_input_channels())print('inputs:',synth.get_num_output_channels())print(synth.get_parameters_description())synth.set_parameter(7,.1234)# (MIDI note, velocity, start sec, duration sec)synth.add_midi_note(60,100,0.0,2.)effect=engine.make_plugin_processor("effect",EFFECT_PATH)engine.load_graph([(synth,[]),(effect,[synth.get_name()])# effect needs 2 channels, and "synth" provides those 2.])engine.render(4.)# render 4 seconds.audio=engine.get_audio()wavfile.write('synth_demo.wav',SAMPLE_RATE,audio.transpose())synth.clear_midi()# add midi again, render again, and so on...Please refer to theWiki,examples,API documentation, andtests.LicenseDawDreamer is licensed under GPLv3 to make it easier to comply with all of the dependent projects. If you use DawDreamer, you must obey the licenses ofJUCE,pybind11,Libsamplerate,Rubber Band Library,Steinberg VST2/3, andFAUST.Thanks to contributors to the originalRenderManfedden, RenderMan creatorjgefeleharritaylorcannoneyed