Skip to main content

SignalFlow is a sound synthesis library designed to make it quick and intuitive to explore complex sonic ideas

Project description

SignalFlow

ci stability-beta

SignalFlow is a sound synthesis framework designed for clear and concise expression of complex musical ideas. It has an extensive Python API, for fluid audio experimentation in iPython/Jupyter. Its core is written in C++11, so it can also be embedded into other cross-platform applications.

SignalFlow is in beta status. Interfaces may be subject to change.

Example

from signalflow import *

#--------------------------------------------------------------------------------
# An AudioGraph is made up of a network of interconnected Nodes, which generate
# and process audio. 
#--------------------------------------------------------------------------------
graph = AudioGraph()

#--------------------------------------------------------------------------------
# Passing an array of frequencies creates a stereo output.
#--------------------------------------------------------------------------------
sine = SineOscillator([440, 880])

#--------------------------------------------------------------------------------
# Simple attack/sustain/release envelope with linear curves.
#--------------------------------------------------------------------------------
env = ASREnvelope(0.01, 0.1, 0.5)

#--------------------------------------------------------------------------------
# Use standard arithmetic operations to combine signals. When a multi-channel 
# signal is multiplied by a mono signal, the mono signal is auto-upmixed.
#--------------------------------------------------------------------------------
output = sine * env

#--------------------------------------------------------------------------------
# Connect the output to the graph, and begin playback.
#--------------------------------------------------------------------------------
output.play()
graph.wait()

Installation

SignalFlow requires Python 3.8 or above.

Installation: macOS

macOS

Install an up-to-date version of Python 3 using Homebrew (guide): brew install python3

Install SignalFlow using pip:

pip3 install signalflow

That's it! To test that it is installed successfully, play a test tone by running: signalflow test

From source

To build on macOS from source, install dependencies with Homebrew:

brew install cmake python libsndfile libsoundio

Clone this repository, then build and install with pip:

pip3 install .
Installation: Linux, Raspberry Pi

Linux, Raspberry Pi

SignalFlow supports Linux (verified on Ubuntu 20.04 and Raspberry Pi OS buster) with alsa and pulseaudio backends.

Via pip

Installation via pip is supported for Linux x86_64. To install:

pip3 install signalflow

That's it! To test that it is installed successfully, play a test tone by running: signalflow test.

If installation does not succeed, follow the instructions for building from source below.

From source

To build the Python library from source on Linux, install dependencies with apt:

apt-get install -y git cmake g++ python3-pip libasound2-dev libsndfile1-dev libsoundio-dev fftw3-dev

If you experience an error on Raspberry Pi libf77blas.so.3: cannot open shared object file:

sudo apt-get install -y libatlas-base-dev

Clone this repository, then build and install with pip:

pip3 install .
Installation: Windows

Windows

This is work in progress.

Currently, dependencies need to be downloaded and built by hand. These can be placed anywhere.

To build SignalFlow, use the CMake GUI. Press configure and you will see three empty fields to fill in with the path to the two build folders and the FFTW binaries folder (see above). Set these parameters then press Configure, then Generate then Open. Then build in Visual Studio 2019.

As of 2021-03-03, only the signalflow project has been ported to build correctly on Windows. Only tested in x64 and for Debug builds. Tested using Visual Studio 2019.

Installation: C++ only (no Python layer)

To build and install the C++ core without the Python binding layer:

mkdir build
cd build
cmake ..
make -j8

Examples

See examples for a number of example scripts.

Documentation

More detailed documentation can be found at signalflow.dev.

Node classes

The following Node classes are currently included with the base distribution:

Category Classes
Analysis CrossCorrelate, OnsetDetector, VampAnalysis
Buffer BeatCutter, BufferLooper, BufferPlayer, BufferRecorder, FeedbackBufferReader, FeedbackBufferWriter, GrainSegments, Granulator, SegmentPlayer
Control MouseX, MouseY, MouseDown
Envelope ADSREnvelope, ASREnvelope, DetectSilence, Envelope, Line, RectangularEnvelope
FFT FFTContinuousPhaseVocoder, FFTConvolve, FFT, FFTNode, FFTOpNode, FFTFindPeaks, IFFT, FFTLPF, FFTNoiseGate, FFTPhaseVocoder, FFTTonality, FFTZeroPhase
Operators Add, AmplitudeToDecibels, DecibelsToAmplitude, ChannelArray, ChannelCrossfade, ChannelMixer, ChannelSelect, Equal, NotEqual, GreaterThan, GreaterThanOrEqual, LessThan, LessThanOrEqual, Modulo, Abs, If, Divide, FrequencyToMidiNote, MidiNoteToFrequency, Multiply, Pow, RoundToScale, Round, ScaleLinExp, ScaleLinLin, Subtract, Sum, Sin, Cos, Tan, Tanh
Oscillators Constant, Impulse, LFO, SawLFO, SawOscillator, SineLFO, SineOscillator, SquareLFO, SquareOscillator, TriangleLFO, TriangleOscillator, Wavetable, Wavetable2D
Processors Clip, Fold, Smooth, WetDry, Wrap
Processors: Delays AllpassDelay, CombDelay, OneTapDelay, Stutter
Processors: Distortion Resample, SampleAndHold, Squiz, WaveShaper
Processors: Dynamics Compressor, Gate, Maximiser, RMS
Processors: Filters BiquadFilter, EQ, MoogVCF, SVFilter
Processors: Panning AzimuthPanner, ChannelPanner, SpatialPanner, StereoBalance, StereoPanner, StereoWidth
Sequencing ClockDivider, Counter, Euclidean, FlipFlop, ImpulseSequence, Index, Latch, Sequence
Stochastic Logistic, PinkNoise, RandomBrownian, RandomChoice, RandomCoin, RandomExponentialDist, RandomExponential, RandomGaussian, RandomImpulseSequence, RandomImpulse, RandomUniform, StochasticNode, WhiteNoise

Contributors

Thanks to the following contributors:

  • Arthur Carabott (@acarabott), Tim Murray-Browne (@timmb): Windows support
  • Dan Stowell (@danstowell): Build improvements
  • Marc Fargas (@telenieko): Generous donation of the signalflow pypi namespace

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distributions

signalflow-0.4.3-cp312-cp312-win_amd64.whl (3.0 MB view details)

Uploaded CPython 3.12 Windows x86-64

signalflow-0.4.3-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (4.4 MB view details)

Uploaded CPython 3.12 manylinux: glibc 2.17+ x86-64

signalflow-0.4.3-cp312-cp312-macosx_11_0_arm64.whl (1.8 MB view details)

Uploaded CPython 3.12 macOS 11.0+ ARM64

signalflow-0.4.3-cp312-cp312-macosx_10_9_x86_64.whl (1.7 MB view details)

Uploaded CPython 3.12 macOS 10.9+ x86-64

signalflow-0.4.3-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (4.4 MB view details)

Uploaded CPython 3.11 manylinux: glibc 2.17+ x86-64

signalflow-0.4.3-cp311-cp311-macosx_11_0_arm64.whl (1.8 MB view details)

Uploaded CPython 3.11 macOS 11.0+ ARM64

signalflow-0.4.3-cp311-cp311-macosx_10_9_x86_64.whl (1.7 MB view details)

Uploaded CPython 3.11 macOS 10.9+ x86-64

signalflow-0.4.3-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (4.4 MB view details)

Uploaded CPython 3.10 manylinux: glibc 2.17+ x86-64

signalflow-0.4.3-cp310-cp310-macosx_11_0_arm64.whl (1.8 MB view details)

Uploaded CPython 3.10 macOS 11.0+ ARM64

signalflow-0.4.3-cp310-cp310-macosx_10_9_x86_64.whl (1.7 MB view details)

Uploaded CPython 3.10 macOS 10.9+ x86-64

signalflow-0.4.3-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (4.4 MB view details)

Uploaded CPython 3.9 manylinux: glibc 2.17+ x86-64

signalflow-0.4.3-cp39-cp39-macosx_11_0_arm64.whl (1.8 MB view details)

Uploaded CPython 3.9 macOS 11.0+ ARM64

signalflow-0.4.3-cp39-cp39-macosx_10_9_x86_64.whl (1.7 MB view details)

Uploaded CPython 3.9 macOS 10.9+ x86-64

signalflow-0.4.3-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (4.4 MB view details)

Uploaded CPython 3.8 manylinux: glibc 2.17+ x86-64

signalflow-0.4.3-cp38-cp38-macosx_11_0_arm64.whl (1.8 MB view details)

Uploaded CPython 3.8 macOS 11.0+ ARM64

signalflow-0.4.3-cp38-cp38-macosx_10_9_x86_64.whl (1.7 MB view details)

Uploaded CPython 3.8 macOS 10.9+ x86-64

File details

Details for the file signalflow-0.4.3-cp312-cp312-win_amd64.whl.

File metadata

File hashes

Hashes for signalflow-0.4.3-cp312-cp312-win_amd64.whl
Algorithm Hash digest
SHA256 dd44010ad0f41e8663b35332287cbf0eef7a8bc5bb561746e38738c4e5bceb6f
MD5 cb31e02f08ccd6ecc8762bdd5703b650
BLAKE2b-256 5930272b920a836507382be94c4515c85927da14d4888e5f0752827cad0c1393

See more details on using hashes here.

File details

Details for the file signalflow-0.4.3-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for signalflow-0.4.3-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 2fc335b8c8b6ec85210b83643ac43d18eabb00726714f95bdfa8bd2cddf9920a
MD5 20d272abbc75f463a5c88067740967cd
BLAKE2b-256 54d50dc3ab260d3ba4e12e9fd703792acb47320c037f39cedb906a1c9cc04cb6

See more details on using hashes here.

File details

Details for the file signalflow-0.4.3-cp312-cp312-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for signalflow-0.4.3-cp312-cp312-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 98012bc48a1361db0158a0eb605f651a7c05bb9a4c016bb3aa7dbc4df56151a0
MD5 f83645b4642e5382ef3bba9cc22979f1
BLAKE2b-256 437514e4dbe1faa05ed07dee91f773a310c45d8ca48d8afb5dc7444cff1e4d32

See more details on using hashes here.

File details

Details for the file signalflow-0.4.3-cp312-cp312-macosx_10_9_x86_64.whl.

File metadata

File hashes

Hashes for signalflow-0.4.3-cp312-cp312-macosx_10_9_x86_64.whl
Algorithm Hash digest
SHA256 fecd754f14434f8da73983d1b2753dd4b822e5e9683cb0f025338a3091c25ab9
MD5 f7879be57a3607b1e345c9ce5176ca37
BLAKE2b-256 0073c0bce002bdfbe78c7e5f148b158119ede78e08fd6dad6f5134c1fd90fd66

See more details on using hashes here.

File details

Details for the file signalflow-0.4.3-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for signalflow-0.4.3-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 7290e69aa24d5756b3337b8c3e55e5db3d4d0ea8d91483cf6e957185da94d25f
MD5 9c61a8ec5712e87b9dd609f05b218212
BLAKE2b-256 e8b3d8653e3ee45d3bd017b6d66fc6e13f3a6e3de140cb22ead6c87a7c24d986

See more details on using hashes here.

File details

Details for the file signalflow-0.4.3-cp311-cp311-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for signalflow-0.4.3-cp311-cp311-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 023f9665d5ae2f0b793b3c78dc44a8c3521935d1968ee1e5f144b003818dfc63
MD5 e7bbba79aa0c23b36d0781c4aba83bc8
BLAKE2b-256 4c2659d204c28814466b294448cfff64c2bccfe29d58d769b35faf9fd2838c95

See more details on using hashes here.

File details

Details for the file signalflow-0.4.3-cp311-cp311-macosx_10_9_x86_64.whl.

File metadata

File hashes

Hashes for signalflow-0.4.3-cp311-cp311-macosx_10_9_x86_64.whl
Algorithm Hash digest
SHA256 0135eb86017304594b9415ab65f7352b3580f842daf1a3fcaed0e6631ff4619a
MD5 8ab76b1bd3a51eb47b816bb31512097c
BLAKE2b-256 b479cf83ea2619cbbf1a155f16706217fdc92074165e6c84cc038d52c4d7c4ca

See more details on using hashes here.

File details

Details for the file signalflow-0.4.3-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for signalflow-0.4.3-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 0ba634b87552aaf2c1231013e4592f1729a10b6e8bc0bd9d4eb7ef8ff8d8a17e
MD5 9f879020589fe402b8c43331849b24f7
BLAKE2b-256 33055f103346536d49b036c1922376ce3ff1f47e6758c99dc39c3e60f349f461

See more details on using hashes here.

File details

Details for the file signalflow-0.4.3-cp310-cp310-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for signalflow-0.4.3-cp310-cp310-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 f3db899dcab8baa9df6f0d8ca610179d651e428ad19e82ff22e1008a785e03df
MD5 f984294f0920ea6354e7dbb7cf1cfa07
BLAKE2b-256 17d98db442b16893b6da5b2bc3c5756cfab0119b3650b303bff0d058157eadc3

See more details on using hashes here.

File details

Details for the file signalflow-0.4.3-cp310-cp310-macosx_10_9_x86_64.whl.

File metadata

File hashes

Hashes for signalflow-0.4.3-cp310-cp310-macosx_10_9_x86_64.whl
Algorithm Hash digest
SHA256 10076c91d875eecf77a28c4008f2ef90423fee50bcbee370ebe1e7ac9fd592ea
MD5 e92a2d154b0336db197b9161639fc96b
BLAKE2b-256 c9c045757e5508fc8bf3e6f3fcc6453a745c10c6e0a755c007df3739cb08760f

See more details on using hashes here.

File details

Details for the file signalflow-0.4.3-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for signalflow-0.4.3-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 e947a109f77413eff17dd1578e5045514d82cf5cc6b559ef04d7be6b92780ed0
MD5 6dd91830f9cb702c547f3b79f4a01a72
BLAKE2b-256 e6bf1428632724bd2e3e602544f9193a686ee63be1bd7ce666c7a0ab79d19c68

See more details on using hashes here.

File details

Details for the file signalflow-0.4.3-cp39-cp39-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for signalflow-0.4.3-cp39-cp39-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 b06ceefd174a180f65d066c47415d40e0e0a9c5b227e74ba5dc5f8feb6992fc0
MD5 963fb2972224e45c1082705c9d3305ed
BLAKE2b-256 5d89b8421662b52882c2d152adcda8f96bb788651ab9badd4f76dd42d17f9fff

See more details on using hashes here.

File details

Details for the file signalflow-0.4.3-cp39-cp39-macosx_10_9_x86_64.whl.

File metadata

File hashes

Hashes for signalflow-0.4.3-cp39-cp39-macosx_10_9_x86_64.whl
Algorithm Hash digest
SHA256 4dedb0fba5a4d87cf65dc85f57133cb2d35bc250779dce62981c673f7fe9c2f2
MD5 397c58f6483e60dd64254fe734e6c8dd
BLAKE2b-256 7803aad168161ca706fc12ca1763b386b3d59381f13cd53f498c810dedff656b

See more details on using hashes here.

File details

Details for the file signalflow-0.4.3-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for signalflow-0.4.3-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 99e1b1432cc2b29af95d8d62bb9ab5603190f51735295630adacd382381e91ee
MD5 3a6809be672c83b5e932fc5f5c831d0d
BLAKE2b-256 dca64a92638e59b56bcd52aac2dea9fdfe53dbf02c1e62e851b1b2a4d2bb47c5

See more details on using hashes here.

File details

Details for the file signalflow-0.4.3-cp38-cp38-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for signalflow-0.4.3-cp38-cp38-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 d03c8a903fc37e27d1cf000da0dee5a8cde07a43fa4e84d865a7b176dee96af5
MD5 da2ce4322c4194351229301bed3072b2
BLAKE2b-256 e210a4b15bc428555b7a05e67efae2229d69d6d6d235483389aabc8e3d764b1f

See more details on using hashes here.

File details

Details for the file signalflow-0.4.3-cp38-cp38-macosx_10_9_x86_64.whl.

File metadata

File hashes

Hashes for signalflow-0.4.3-cp38-cp38-macosx_10_9_x86_64.whl
Algorithm Hash digest
SHA256 e352ed87178a1be6885efe0c83911021221aa363126be9d67edc87000b2b9284
MD5 c7e26fe8a2d39b557bbeb989624aec3c
BLAKE2b-256 a65d5183f4295da15b8a9d5b37b2e921dcbd835a50dcad43cde98054d8dd4355

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page