pycdp
pycdp
This is a project I’ve been investing a lot of time in, and I’m very excited about it… It’s also hard to explain to people what the hell I’m doing. So here’s an attempt at an explanation.
A few months ago, I asked Richard Devine if he had used SuperCollider much. His response was that he had used SC for several years, but was currently really into CDP.
I greatly respect Mr. Devine’s opinions on software, so I researched it. I found that there was no demo available, nor sample sounds, nor screenshots… it was weird ghost software, but 20+-year old software. So, I contacted the company for an evaluation copy, they obliged. When I received it, I immediately dropped everything I was doing and began puzzling over it.
So, what is CDP?
I’ll cut and paste directly from CDP’s site (which is here http://www.composersdesktop.com/):
The vast range of CDP processing functions and extensive documentation provide an essential toolbox for innovative sound designers, electroacoustic composers and educators.
Because of its roots…
CDP itself is comprised entirely of command line utilities, no GUI. You feed a program a file, some parameters, and out comes another file.
What of CDP GUIs?
If you take a look at the Composer’s Desktop Project homepage you’ll notice several GUIs have been written. The most notable (and one might say it is the default GUI) is Sound Loom, which is written and maintained by the main developer of CDP, Trevor Wishart.
All of these GUIs exist to make working with the command-line programs easier and in the case of Sound Loom, batch processing and process chaining are available (among other useful things).
Ok, what is pycdp?
When I first received CDP I was astounded at the sounds I was getting out of it, but unhappy with Sound Loom (for reasons I won’t get into, it’s a fine program).
After some cognitive dissonance, I decided I’d write my own GUI, but as I began writing the core of it, I realized my work in progress could be used within Python scripts, so I tried writing some with no GUI in mind at all and the results were great!
So, I decided to shift the goal of my project to “simply” wrap all CDP processes within a Python module, with the ultimate product being a module anyone can use to create CDP scripts.
Here’s an example using only a few processes:
from pycdp import *
if __name__ == “__main__”: # python convention, but i think you can leave it out…
mono = cdp.housekeep.chans(4)
norm = cdp.modify.loudness(3)
scrub = cdp.modify.radical(3)
scrub.l = -48
scrub.h = 24
scrub.dur = 2
scrub2 = cdp.modify.radical(3)
scrub2.l = -12
scrub2.h = 24
scrub2.dur = 2
reverse = cdp.modify.radical(1)
rev = cdp.modify.revecho(3)
rev2 = cdp.modify.revecho(3)
rev2.s = 0.2
rev2.r = 0.5
rev2.e = 500
chain = []
chain.append(mono)
chain.append(scrub)
chain.append(rev)
chain.append(scrub2)
chain.append(rev2)
chain.append(reverse)
chain.append(norm)
output_files = cdp.run_chain(chain, sys.argv[1:], False)
print output_files # debug!
That’s pretty readable even if you don’t know Python, isn’t it?
Why is this awesome?
It’s all Python-based!
The reason that is important may not be clear unless you’re familiar with Python, but I strongly believe it’s the best tool for the job. (Other languages could probably work just fine for this project, but I like Python, so Python it is.)
I’ll list a few examples of some projects that would be trivial to implement with Python:
- Generate parameters for processes based on information in a database, a flat file, or at random.
- Generate parameters for processes based on real-time data pulled from the net (even though the processes will still be offline). Twitter to pycdp?
- Run chains on demand (imagine a web request that accepts and returns audio).
- Manage files.
- Convert output to sampler file formats (an easy one that comes to mind is Renoise’s XML-based XNRI file format).
- Build and collect sub-chains you like and reuse them. This is a topic that I’ll cover in more detail when I write formal documentation. Trust me when I say this will be a very useful feature.
- Write a GUI…
Also planned are tools to work with data CDP uses that is not audio or spectral, such as breakpoint envelope files.
PERSONALLY, I intend to use this to build chains of processes to run against folders of audio files, to generate samples for musical endeavors.
This should also be a very useful tool for sound designers of all shapes and sizes.
Trying pycdp pt. 1
First of all, CDP IS REQUIRED!
There is unfortunately no demo, but you may be able to request a for-sale-or-return copy for evaluation (this is what I did). Contact information is available on the CDP homepage.
Trying pycdp pt. 2
Currently pycdp is usable, but unstable. You’ll want to use subversion to check out the source code for the latest version. OSX has subversion installed by default. PC users can google subversion and get an installer
To check pycdp out using subversion:
Basic knowledge of installing a python module is needed, I won’t explain it here because you should know how to do that if you’re going to play with unstable code
See also:
Documentation
Automatically-generated documentation is available, but not complete. You can find this in the doc/ directory. This will give you a list of available wrapped processes and their parameters. Any parameters prefixed with “-” are optional.
[...] pycdp [...]
wow that sounds really cool. i’ve dabbled a little bit with processing (from processing.org) for motion stuff, but one of these days i want to start working on sound design and such. someday
Hi Anthony,
i tried processing while it was still in early beta. it’s really nice, I wish I had gotten into it more, I don’t really have the time to now. Maybe in the future
I’ve been trying to get into sound design more and more after sticking to basic synthesis for a very long time.After using Max/MSP for a long stretch, I tried SuperCollider 3 (free) which sounds amazing, but the language you use to develop your synths / effects it is a bit too insane for me.
I had no idea what CDP was until Mr. Devine mentioned it, and I still couldn’t figure out what it was by looking at their website. However, a lot of respected artists use it (according to various people I’ve talked to). Mr. Devine actually mentions it in interviews as his secret weapon, so it seemed like it was wise to check into it. It really is quite a secret weapon, especially considering how difficult it can be to use it.
Haven“t you tried the Soundshaper GUI fro CDP? I think it is easier to work with than Sound Loom.
I would try Soundshaper but I’m using OSX.