From: Thomas Fillon Date: Wed, 14 Jan 2015 15:13:45 +0000 (+0100) Subject: Update README (from doc/make_readme.sh) X-Git-Tag: 0.7^2~26 X-Git-Url: https://git.parisson.com/?a=commitdiff_plain;h=72248e8c4b91ae7288f8c9b0ddb5267f7cd66f14;p=timeside.git Update README (from doc/make_readme.sh) --- diff --git a/README.rst b/README.rst index 95d1054..9b8229d 100644 --- a/README.rst +++ b/README.rst @@ -58,48 +58,58 @@ The streaming architecture of TimeSide relies on 2 main parts: a processing engi Dive in ======== -To list all available plugins:: +To list all available plugins: - import timeside.core - timeside.core.list_processors() +.. testcleanup:: -Define some processors:: + os.remove('sweep.ogg') + os.remove('waveform.png') - from timeside.core import get_processor - decoder = get_processor('file_decoder')('sweep.wav') - grapher = get_processor('waveform_simple')() - analyzer = get_processor('level')() - encoder = get_processor('vorbis_encoder')('sweep.ogg') +.. doctest:: -Then run the *magic* pipeline:: + >>> import timeside + >>> timeside.core.list_processors() # doctest: +SKIP - (decoder | grapher | analyzer | encoder).run() -Render the grapher results:: +Define some processors: - grapher.render(output='waveform.png') +.. doctest:: -Show the analyzer results:: + >>> from timeside.core import get_processor + >>> from timeside.core.tools.test_samples import samples + >>> wavfile = samples['sweep.wav'] + >>> decoder = get_processor('file_decoder')(wavfile) + >>> grapher = get_processor('waveform_simple')() + >>> analyzer = get_processor('level')() + >>> encoder = get_processor('vorbis_encoder')('sweep.ogg') - print 'Level:', analyzer.results +Then run the *magic* pipeline: -The encoded OGG file should also be there... +.. doctest:: -For more extensive examples, please see the `full documentation `_. + >>> (decoder | grapher | analyzer | encoder).run() +Render the grapher results: -News -===== +.. doctest:: -0.7 + >>> grapher.render(output='waveform.png') - * Code refactoring: +Show the analyzer results: - - Create a new module `timeside.plugins` and move processors therein: timeside.plugins.decodr, timeside.plugins.analyzer, timeside.plugins.encoder, timeside.plugins.fx - - `timeside.plugins` is a `namespace package `_ enabling external plugins to be automatically plug into TimeSide (see for example `timeside-diadems `_). - - To properly manage the namespace packages structure, the TimeSide main module is now `timeside.core` and code should now be initialized with `import timeside.core`. - * Move all analyzers developped by the partners of the Diadems project to a new repository: `timeside-diadems `_ +.. doctest:: + >>> print 'Level:', analyzer.results # doctest: +ELLIPSIS + Level: {'level.max': AnalyzerResult(...)} + + +The encoded OGG file should also be there... + +For more extensive examples, please see the `full documentation `_. + + +News +===== 0.6.1