PageRenderTime 102ms CodeModel.GetById 100ms app.highlight 0ms RepoModel.GetById 2ms app.codeStats 0ms

/examples/shell/README

http://echo-nest-remix.googlecode.com/
#! | 40 lines | 31 code | 9 blank | 0 comment | 0 complexity | bcfc04ef58e98ed6aee8863f6b442df4 MD5 | raw file
 1remix.py
 2========
 3
 4A stupid shell for the Echo Nest Remix API.
 5
 6I had SuperCollider one-liner envy, so I created this.
 7
 8
 9Commands:
10  load: loads the filename
11  play: play the result of the last command, if it can be played (currently Mac only)
12  save: save the result of the last command, if it can be rendered
13  help: be minimally helpful
14  anything else: try to interpret it in the current environment
15
16Environment:
17  beats, bars, tatums, sections, segments: all from the currently loaded file
18  _: the last-defined AudioRenderable
19  analysis: container for all the other analysis products in the file
20  
21  libraries (i.e., the namespace you have to work with):
22    from echonest.audio import *
23    from echonest.audio import AudioQuantumList as aql
24    from echonest.audio import AudioQuantum as aq
25    from echonest.selection import *
26    from echonest.sorting import *
27
28$ ./remix.py ../music/BillieJean.mp3
29
30> tatums.that(fall_on_the(1))
31> play
32> save bj.mp3
33> load ../music/aha.mp3
34> segments.that(have_pitch_max(analysis.key['value']))
35> play
36> beats.that(overlap_starts_of(_))
37> play
38> ^D
39
40$