v2.0.0 – Beta 4 (In Development)
Source code: https://github.com/luvsound/pippi
What is this?
Pippi is a library of computer music modules for python.
It includes a few handy data structures for music like
Wavetable, which are operator-overloaded
to make working with sounds and control structures simpler.
It also includes a lot of useful methods for doing common and
not-so-common transformations to sounds and control structures.
from pippi import dsp sound1 = dsp.read('sound1.wav') sound2 = dsp.read('sound2.flac') # Mix two sounds both = sound1 & sound2 # Apply a skewed hann Wavetable as an envelope to a sound enveloped = sound * dsp.win('hann').skewed(0.6) # Or the same, via a shortcut method on the `SoundBuffer` enveloped = sound.env('hann') # Synthesize a 10 second graincloud from the sound, # with grain length modulating between 20ms and 2s # over a hann shaped curve. cloudy = enveloped.cloud(10, grainlength=dsp.win('hann', dsp.MS*20, 2))
It comes with several oscs:
Alias– a highly aliased pulse train osc
Bar– a bar physical model (from Soundpipe)
Drunk– does a drunk walk on the y axis over a fixed set of random points w/hermite interpolation for smooth waveshapes (kind of like dynamic stochastic synthesis in one dimension)
DSS– a basic implementation of dynamic stochastic synthesis that does a drunk walk in two dimensions over a random set of breakpoints
FM– a basic two operator FM synth w/harmonicity ratio & modulation index controls
Fold– an infinite folding wavetable osc
Osc– an everyday wavetable osc
Osc2d– a 2d morphing wavetable osc
Pluck– a plucked string physical model (adapted from JOS)
Pulsar– a pulsar synthesis engine
Pulsar2d– a 2d morphing pulsar synthesis engine (pairs well with a stack of wavetables extracted with the
SineOsc– a simple sinewave osc (doesn’t use wavetables)
Tukey– a tukey-window-based osc with waveshape modulation between square-like and sine-like
And many built-in effects and transformations:
- Easy independent control over pitch and speed for any
- Several forms of waveshaping and distortion including a crossover distortion ported from supercollider
- Sweapable highpass, lowpass, bandpass and band reject butterworth filters from Soundpipe
- Lots more!
As well as support for pitch and harmony transformations and non-standard tuning systems
from pippi import tune # Get a list of frequencies from a list of scale degrees frequencies = tune.fromdegrees([1,3,5,9], octave=3, root='a', scale