Back to rankings

DBraun/DawDreamer

C++dirt.design/DawDreamer/

Digital Audio Workstation with Python; VST instruments/effects, parameter automation, FAUST, JAX, Warp Markers, and JUCE processors

juceaudiopythondawvstaudio-pluginaudio-processingfaustvst3vst3-hostmidisynthesizer
Star Growth
Stars
1.3k
Forks
95
Weekly Growth
โ€”
Issues
57
5001k
Aug 2020Jul 2022Jul 2024Jul 2026
README
  _____                       _____
 |  __ \                     |  __ \
 | |  | |   __ _  __      __ | |  | |  _ __    ___    __ _   _ __ ___     ___   _ __
 | |  | |  / _` | \ \ /\ / / | |  | | | '__|  / _ \  / _` | | '_ ` _ \   / _ \ | '__|
 | |__| | | (_| |  \ V  V /  | |__| | | |    |  __/ | (_| | | | | | | | |  __/ | |
 |_____/   \__,_|   \_/\_/   |_____/  |_|     \___|  \__,_| |_| |_| |_|  \___| |_|

* * Digital Audio Workstation with Python * *

Supported Platforms Test Badge PyPI version fury.io GPLv3 license GitHub Repo stars Generic badge

DawDreamer

Read the introduction to DawDreamer, which was presented as a Late-Breaking Demo at the 2021 ISMIR Conference.

DawDreamer is an audio-processing Python framework supporting core DAW features and beyond:

  • Composing graphs of multi-channel audio processors
  • Audio playback
  • VST instruments and effects (with UI editing and state loading/saving)
  • FAUST effects and polyphonic instruments
  • Time-stretching and looping, optionally according to Ableton Live warp markers
  • Pitch-warping
  • Parameter automation at audio-rate and at pulses-per-quarter-note
  • Parameter automation saving in absolute audio-rate time
  • MIDI playback in absolute time and PPQN time
  • MIDI file export in absolute time
  • Rendering and saving multiple processors simultaneously
  • Support for the Faust Box and Signal APIs
  • Transpiling Faust code to JAX/Flax and other target languages (C++, Rust, Wasm, etc.)
  • Machine learning experiments with QDax
  • Multiprocessing support
  • Full support on macOS, Windows, Linux, Google Colab, and Ubuntu Dockerfile

DawDreamer's foundation is JUCE, with a user-friendly Python interface thanks to nanobind. DawDreamer evolved from an earlier VSTi audio "renderer", RenderMan.

Installation

macOS requirements:

  • 64-bit Python 3.11-3.14
  • Apple Silicon
  • macOS 11.0 or higher

Windows requirements:

  • x86_64 CPU
  • 64-bit Python 3.11-3.14

Linux requirements:

  • x86_64 CPU
  • 64-bit Python 3.11-3.14

Install with PyPI:

pip install dawdreamer

API Documentation

https://dbraun.github.io/DawDreamer/

Basic Example

Using Faust, let's make a stereo sine-tone at 440 Hz and -6 dB. You can run this code as-is.

import dawdreamer as daw
from scipy.io import wavfile
SAMPLE_RATE = 44100
engine = daw.RenderEngine(SAMPLE_RATE, 512)  # 512 block size
faust_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 Hz
faust_processor.set_parameter("/MySine/vol", -6.)  # -6 dB volume

engine.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.T)

# Change settings and re-render
faust_processor.set_parameter("/MySine/freq", 880.)  # 880 Hz
engine.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.

import dawdreamer as daw
from scipy.io import wavfile
SAMPLE_RATE = 44100
INSTRUMENT_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", INSTRUMENT_PATH)
print("inputs:", synth.get_num_input_channels())
print("outputs:", 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.)

# optionally capture intermediate audio
synth.record = True

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_wet.wav", SAMPLE_RATE, audio.T)
synth_audio = engine.get_audio("synth")
wavfile.write("synth_demo_dry.wav", SAMPLE_RATE, synth_audio.T)
synth.clear_midi()
# add midi again, render again, and so on...

Known Issues

Compatibility with JAX and other LLVM-based libraries

DawDreamer must be imported before JAX or other LLVM-based libraries (such as PyTorch with TorchScript, Numba, etc.) to avoid LLVM initialization conflicts that can cause segmentation faults:

# CORRECT:
import dawdreamer as daw  # Import DawDreamer first!
import jax

# WRONG - May cause segfault:
import jax
import dawdreamer as daw  # Importing after JAX can crash!

Why? Both DawDreamer (via Faust's LLVM backend) and JAX use LLVM internally. When JAX initializes LLVM first (e.g., by calling jax.devices()), importing DawDreamer afterward can cause conflicts in LLVM's global state, resulting in a crash.

Workaround: Always import dawdreamer at the top of your Python file, before any JAX or related libraries.

Documentation

Full documentation: https://dbraun.github.io/DawDreamer/

License

DawDreamer 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 of JUCE, nanobind, Libsamplerate, Rubber Band Library, Steinberg VST2/3, and FAUST.

Related repositories
juce-framework/JUCE

JUCE is an open-source cross-platform C++ application framework for desktop and mobile applications, including VST, VST3, AU, AUv3, LV2 and AAX audio plug-ins.

C++Otherjucec-plus-plus
juce.com
8.7k2.1k
spotify/pedalboard

๐ŸŽ› ๐Ÿ”Š A Python library for audio.

C++GNU General Public License v3.0vst3vst3-host
spotify.github.io/pedalboard
6.2k346
helio-fm/helio-sequencer

Libre music sequencer for desktop and mobile platforms

C++GNU General Public License v3.0audio-applicationsmusic-composition
helio.fm
3.5k139
zrythm/zrythm

a highly automated and intuitive digital audio workstation - official mirror

C++Otherdawmusic-composition
zrythm.org
3k130
monocasual/giada

Your Hardcore Loop Machine.

C++GNU General Public License v3.0giadamidi
giadamusic.com
2.1k115
kushview/element

Element Audio Plugin Host

C++audio-applicationsvst-host
kushview.net/element/
1.6k128
benkuper/Chataigne

Artist-friendly Modular Machine for Art and Technology

C++GNU General Public License v3.0artjuce
benjamin.kuperberg.fr/chataigne
1.6k90
Tracktion/tracktion_engine

Tracktion Engine module

C++Otheraudiocpp
1.4k211
christophhart/HISE

The open source framework for sample based instruments

C++Othersampler-enginejuce
hise.audio
1.4k163
jatinchowdhury18/AnalogTapeModel

Physical modelling signal processing for analog tape recording

C++GNU General Public License v3.0audio-effectaudio-plugin
1.4k74
GuitarML/SmartGuitarAmp

Guitar plugin made with JUCE that uses neural networks to emulate a tube amplifier.

C++Apache License 2.0audio-processingguitar
guitarml.com
1.3k62
sudara/awesome-juce

A curated list of JUCE modules, templates, plugins, oh my!

RubyRubyGemsMIT Licenseawesome-listjuce
1.3k64