From ae1c8e5f7020843d49ced92289791500889332a9 Mon Sep 17 00:00:00 2001 From: Alberto Pettarin Date: Tue, 19 Apr 2016 10:02:51 +0200 Subject: [PATCH 01/16] Added invoke in AbstractCLIProgram. v1.5.1 --- README.md | 2 +- README.rst | 2 +- VERSION | 2 +- aeneas/__init__.py | 2 +- aeneas/adjustboundaryalgorithm.py | 2 +- aeneas/analyzecontainer.py | 2 +- aeneas/audiofile.py | 2 +- aeneas/audiofilemfcc.py | 2 +- aeneas/cdtw/__init__.py | 2 +- aeneas/cdtw/cdtw_driver.c | 2 +- aeneas/cdtw/cdtw_func.c | 2 +- aeneas/cdtw/cdtw_func.h | 2 +- aeneas/cdtw/cdtw_py.c | 2 +- aeneas/cdtw/cdtw_setup.py | 4 ++-- aeneas/cdtw/cint.c | 2 +- aeneas/cdtw/cint.h | 2 +- aeneas/cew/__init__.py | 2 +- aeneas/cew/cew_driver.c | 2 +- aeneas/cew/cew_func.c | 2 +- aeneas/cew/cew_func.h | 2 +- aeneas/cew/cew_py.c | 2 +- aeneas/cew/cew_setup.py | 4 ++-- aeneas/cewsubprocess.py | 2 +- aeneas/cint/__init__.py | 2 +- aeneas/cint/cint.c | 2 +- aeneas/cint/cint.h | 2 +- aeneas/cmfcc/__init__.py | 2 +- aeneas/cmfcc/cint.c | 2 +- aeneas/cmfcc/cint.h | 2 +- aeneas/cmfcc/cmfcc_driver.c | 2 +- aeneas/cmfcc/cmfcc_func.c | 2 +- aeneas/cmfcc/cmfcc_func.h | 2 +- aeneas/cmfcc/cmfcc_py.c | 2 +- aeneas/cmfcc/cmfcc_setup.py | 4 ++-- aeneas/cmfcc/cwave_func.c | 2 +- aeneas/cmfcc/cwave_func.h | 2 +- aeneas/configuration.py | 2 +- aeneas/container.py | 2 +- aeneas/cwave/__init__.py | 2 +- aeneas/cwave/cint.c | 2 +- aeneas/cwave/cint.h | 2 +- aeneas/cwave/cwave_driver.c | 2 +- aeneas/cwave/cwave_func.c | 2 +- aeneas/cwave/cwave_func.h | 2 +- aeneas/cwave/cwave_py.c | 2 +- aeneas/cwave/cwave_setup.py | 4 ++-- aeneas/diagnostics.py | 2 +- aeneas/downloader.py | 2 +- aeneas/dtw.py | 6 +++--- aeneas/espeakwrapper.py | 2 +- aeneas/executejob.py | 2 +- aeneas/executetask.py | 2 +- aeneas/extra/__init__.py | 2 +- aeneas/extra/ctw_espeak.py | 2 +- aeneas/extra/ctw_speect.py | 2 +- aeneas/festivalwrapper.py | 2 +- aeneas/ffmpegwrapper.py | 2 +- aeneas/ffprobewrapper.py | 2 +- aeneas/globalconstants.py | 2 +- aeneas/globalfunctions.py | 2 +- aeneas/hierarchytype.py | 2 +- aeneas/idsortingalgorithm.py | 2 +- aeneas/job.py | 2 +- aeneas/language.py | 2 +- aeneas/logger.py | 2 +- aeneas/mfcc.py | 2 +- aeneas/nuancettsapiwrapper.py | 2 +- aeneas/plotter.py | 2 +- aeneas/res/__init__.py | 2 +- aeneas/runtimeconfiguration.py | 2 +- aeneas/sd.py | 2 +- aeneas/syncmap.py | 2 +- aeneas/synthesizer.py | 2 +- aeneas/task.py | 2 +- aeneas/tests/__init__.py | 2 +- aeneas/textfile.py | 2 +- aeneas/timevalue.py | 2 +- aeneas/tools/README.md | 6 ++++++ aeneas/tools/__init__.py | 2 +- aeneas/tools/abstract_cli_program.py | 12 +++++++----- aeneas/tools/convert_syncmap.py | 2 +- aeneas/tools/download.py | 2 +- aeneas/tools/execute_job.py | 2 +- aeneas/tools/execute_task.py | 8 ++++---- aeneas/tools/extract_mfcc.py | 2 +- aeneas/tools/ffmpeg_wrapper.py | 2 +- aeneas/tools/ffprobe_wrapper.py | 2 +- aeneas/tools/plot_waveform.py | 2 +- aeneas/tools/read_audio.py | 2 +- aeneas/tools/read_text.py | 2 +- aeneas/tools/run_sd.py | 2 +- aeneas/tools/run_vad.py | 2 +- aeneas/tools/synthesize_text.py | 2 +- aeneas/tools/validate.py | 2 +- aeneas/tree.py | 2 +- aeneas/ttswrapper.py | 2 +- aeneas/vad.py | 2 +- aeneas/validator.py | 2 +- aeneas_check_setup.py | 2 +- bin/aeneas_check_setup | 2 +- bin/aeneas_convert_syncmap | 4 ++-- bin/aeneas_download | 4 ++-- bin/aeneas_execute_job | 4 ++-- bin/aeneas_execute_task | 4 ++-- bin/aeneas_plot_waveform | 4 ++-- bin/aeneas_synthesize_text | 4 ++-- bin/aeneas_validate | 4 ++-- check_dependencies.py | 2 +- docs/source/changelog.rst | 5 +++++ docs/source/conf.py | 2 +- install_dependencies.sh | 2 +- run_all_unit_tests.py | 2 +- setup.py | 4 ++-- 113 files changed, 145 insertions(+), 132 deletions(-) diff --git a/README.md b/README.md index 196bfbb2..9e8a479d 100644 --- a/README.md +++ b/README.md @@ -2,7 +2,7 @@ **aeneas** is a Python/C library and a set of tools to automagically synchronize audio and text (aka forced alignment). -* Version: 1.5.0.2 +* Version: 1.5.1.0 * Date: 2016-04-09 * Developed by: [ReadBeyond](http://www.readbeyond.it/) * Lead Developer: [Alberto Pettarin](http://www.albertopettarin.it/) diff --git a/README.rst b/README.rst index b7fcd9d6..a7fb8656 100644 --- a/README.rst +++ b/README.rst @@ -4,7 +4,7 @@ aeneas **aeneas** is a Python/C library and a set of tools to automagically synchronize audio and text (aka forced alignment). -- Version: 1.5.0.2 +- Version: 1.5.1.0 - Date: 2016-04-09 - Developed by: `ReadBeyond `__ - Lead Developer: `Alberto Pettarin `__ diff --git a/VERSION b/VERSION index bc80560f..26ca5946 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -1.5.0 +1.5.1 diff --git a/aeneas/__init__.py b/aeneas/__init__.py index 3bb2b30b..2ba74d49 100644 --- a/aeneas/__init__.py +++ b/aeneas/__init__.py @@ -13,7 +13,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/adjustboundaryalgorithm.py b/aeneas/adjustboundaryalgorithm.py index 4651c746..0c07d6bc 100644 --- a/aeneas/adjustboundaryalgorithm.py +++ b/aeneas/adjustboundaryalgorithm.py @@ -30,7 +30,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/analyzecontainer.py b/aeneas/analyzecontainer.py index 9fcf6868..7889c143 100644 --- a/aeneas/analyzecontainer.py +++ b/aeneas/analyzecontainer.py @@ -32,7 +32,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/audiofile.py b/aeneas/audiofile.py index 25638fcc..7b139ec9 100644 --- a/aeneas/audiofile.py +++ b/aeneas/audiofile.py @@ -37,7 +37,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/audiofilemfcc.py b/aeneas/audiofilemfcc.py index 2dd5efb4..f1d17a30 100644 --- a/aeneas/audiofilemfcc.py +++ b/aeneas/audiofilemfcc.py @@ -29,7 +29,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/cdtw/__init__.py b/aeneas/cdtw/__init__.py index a8215303..abbd6102 100644 --- a/aeneas/cdtw/__init__.py +++ b/aeneas/cdtw/__init__.py @@ -114,7 +114,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL 3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/cdtw/cdtw_driver.c b/aeneas/cdtw/cdtw_driver.c index 6d511227..e3a5d1af 100644 --- a/aeneas/cdtw/cdtw_driver.c +++ b/aeneas/cdtw/cdtw_driver.c @@ -9,7 +9,7 @@ __copyright__ = """ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/cdtw/cdtw_func.c b/aeneas/cdtw/cdtw_func.c index 6bed35a3..f969a342 100644 --- a/aeneas/cdtw/cdtw_func.c +++ b/aeneas/cdtw/cdtw_func.c @@ -9,7 +9,7 @@ __copyright__ = """ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/cdtw/cdtw_func.h b/aeneas/cdtw/cdtw_func.h index abef0212..ea441816 100644 --- a/aeneas/cdtw/cdtw_func.h +++ b/aeneas/cdtw/cdtw_func.h @@ -9,7 +9,7 @@ __copyright__ = """ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/cdtw/cdtw_py.c b/aeneas/cdtw/cdtw_py.c index 14e516ea..f210c525 100644 --- a/aeneas/cdtw/cdtw_py.c +++ b/aeneas/cdtw/cdtw_py.c @@ -9,7 +9,7 @@ __copyright__ = """ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/cdtw/cdtw_setup.py b/aeneas/cdtw/cdtw_setup.py index aab0c739..61ee67c3 100644 --- a/aeneas/cdtw/cdtw_setup.py +++ b/aeneas/cdtw/cdtw_setup.py @@ -23,7 +23,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" @@ -31,7 +31,7 @@ setup( name="cdtw", - version="1.5.0", + version="1.5.1", description=""" Python C Extension for computing the DTW as fast as your bare metal allows. """, diff --git a/aeneas/cdtw/cint.c b/aeneas/cdtw/cint.c index 99541bfc..59c42993 100644 --- a/aeneas/cdtw/cint.c +++ b/aeneas/cdtw/cint.c @@ -9,7 +9,7 @@ __copyright__ = """ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/cdtw/cint.h b/aeneas/cdtw/cint.h index a8abed0e..dbffc375 100644 --- a/aeneas/cdtw/cint.h +++ b/aeneas/cdtw/cint.h @@ -9,7 +9,7 @@ __copyright__ = """ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/cew/__init__.py b/aeneas/cew/__init__.py index eea4eea4..c3f09e40 100644 --- a/aeneas/cew/__init__.py +++ b/aeneas/cew/__init__.py @@ -61,7 +61,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL 3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/cew/cew_driver.c b/aeneas/cew/cew_driver.c index 65354bc9..09c59527 100644 --- a/aeneas/cew/cew_driver.c +++ b/aeneas/cew/cew_driver.c @@ -9,7 +9,7 @@ __copyright__ = """ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/cew/cew_func.c b/aeneas/cew/cew_func.c index 2cfee22b..313983f7 100644 --- a/aeneas/cew/cew_func.c +++ b/aeneas/cew/cew_func.c @@ -9,7 +9,7 @@ __copyright__ = """ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/cew/cew_func.h b/aeneas/cew/cew_func.h index 7010d19c..f8129042 100644 --- a/aeneas/cew/cew_func.h +++ b/aeneas/cew/cew_func.h @@ -9,7 +9,7 @@ __copyright__ = """ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/cew/cew_py.c b/aeneas/cew/cew_py.c index 77661b60..022f5ff5 100644 --- a/aeneas/cew/cew_py.c +++ b/aeneas/cew/cew_py.c @@ -9,7 +9,7 @@ __copyright__ = """ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/cew/cew_setup.py b/aeneas/cew/cew_setup.py index 41de70a1..ec97c6e0 100644 --- a/aeneas/cew/cew_setup.py +++ b/aeneas/cew/cew_setup.py @@ -21,7 +21,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" @@ -29,7 +29,7 @@ setup( name="cew", - version="1.5.0", + version="1.5.1", description=""" Python C Extension for synthesizing text with eSpeak. """, diff --git a/aeneas/cewsubprocess.py b/aeneas/cewsubprocess.py index 1b69db80..c4e0b820 100644 --- a/aeneas/cewsubprocess.py +++ b/aeneas/cewsubprocess.py @@ -39,7 +39,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/cint/__init__.py b/aeneas/cint/__init__.py index 7087cd97..98c99b97 100644 --- a/aeneas/cint/__init__.py +++ b/aeneas/cint/__init__.py @@ -14,7 +14,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL 3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/cint/cint.c b/aeneas/cint/cint.c index 99541bfc..59c42993 100644 --- a/aeneas/cint/cint.c +++ b/aeneas/cint/cint.c @@ -9,7 +9,7 @@ __copyright__ = """ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/cint/cint.h b/aeneas/cint/cint.h index a8abed0e..dbffc375 100644 --- a/aeneas/cint/cint.h +++ b/aeneas/cint/cint.h @@ -9,7 +9,7 @@ __copyright__ = """ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/cmfcc/__init__.py b/aeneas/cmfcc/__init__.py index 16ea6cb7..b5f66845 100644 --- a/aeneas/cmfcc/__init__.py +++ b/aeneas/cmfcc/__init__.py @@ -58,7 +58,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL 3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/cmfcc/cint.c b/aeneas/cmfcc/cint.c index 99541bfc..59c42993 100644 --- a/aeneas/cmfcc/cint.c +++ b/aeneas/cmfcc/cint.c @@ -9,7 +9,7 @@ __copyright__ = """ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/cmfcc/cint.h b/aeneas/cmfcc/cint.h index a8abed0e..dbffc375 100644 --- a/aeneas/cmfcc/cint.h +++ b/aeneas/cmfcc/cint.h @@ -9,7 +9,7 @@ __copyright__ = """ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/cmfcc/cmfcc_driver.c b/aeneas/cmfcc/cmfcc_driver.c index cd87a2f5..46210cc2 100644 --- a/aeneas/cmfcc/cmfcc_driver.c +++ b/aeneas/cmfcc/cmfcc_driver.c @@ -9,7 +9,7 @@ __copyright__ = """ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/cmfcc/cmfcc_func.c b/aeneas/cmfcc/cmfcc_func.c index 7a9c1b7f..e1b5c1b6 100644 --- a/aeneas/cmfcc/cmfcc_func.c +++ b/aeneas/cmfcc/cmfcc_func.c @@ -9,7 +9,7 @@ __copyright__ = """ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/cmfcc/cmfcc_func.h b/aeneas/cmfcc/cmfcc_func.h index e6aa89b2..9eb97118 100644 --- a/aeneas/cmfcc/cmfcc_func.h +++ b/aeneas/cmfcc/cmfcc_func.h @@ -9,7 +9,7 @@ __copyright__ = """ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/cmfcc/cmfcc_py.c b/aeneas/cmfcc/cmfcc_py.c index b65df710..67b910a5 100644 --- a/aeneas/cmfcc/cmfcc_py.c +++ b/aeneas/cmfcc/cmfcc_py.c @@ -9,7 +9,7 @@ __copyright__ = """ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/cmfcc/cmfcc_setup.py b/aeneas/cmfcc/cmfcc_setup.py index dbc1fa1e..2ab45ffd 100644 --- a/aeneas/cmfcc/cmfcc_setup.py +++ b/aeneas/cmfcc/cmfcc_setup.py @@ -23,7 +23,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" @@ -31,7 +31,7 @@ setup( name="cmfcc", - version="1.5.0", + version="1.5.1", description=""" Python C Extension for computing the MFCCs as fast as your bare metal allows. """, diff --git a/aeneas/cmfcc/cwave_func.c b/aeneas/cmfcc/cwave_func.c index 5e717e99..9f4a5003 100644 --- a/aeneas/cmfcc/cwave_func.c +++ b/aeneas/cmfcc/cwave_func.c @@ -9,7 +9,7 @@ __copyright__ = """ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/cmfcc/cwave_func.h b/aeneas/cmfcc/cwave_func.h index ae429924..51ac3df6 100644 --- a/aeneas/cmfcc/cwave_func.h +++ b/aeneas/cmfcc/cwave_func.h @@ -9,7 +9,7 @@ __copyright__ = """ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/configuration.py b/aeneas/configuration.py index 9f45193a..f0c9a320 100644 --- a/aeneas/configuration.py +++ b/aeneas/configuration.py @@ -24,7 +24,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/container.py b/aeneas/container.py index c4aaeba2..dceb2429 100644 --- a/aeneas/container.py +++ b/aeneas/container.py @@ -31,7 +31,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/cwave/__init__.py b/aeneas/cwave/__init__.py index a435100a..2b831697 100644 --- a/aeneas/cwave/__init__.py +++ b/aeneas/cwave/__init__.py @@ -37,7 +37,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL 3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/cwave/cint.c b/aeneas/cwave/cint.c index 99541bfc..59c42993 100644 --- a/aeneas/cwave/cint.c +++ b/aeneas/cwave/cint.c @@ -9,7 +9,7 @@ __copyright__ = """ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/cwave/cint.h b/aeneas/cwave/cint.h index a8abed0e..dbffc375 100644 --- a/aeneas/cwave/cint.h +++ b/aeneas/cwave/cint.h @@ -9,7 +9,7 @@ __copyright__ = """ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/cwave/cwave_driver.c b/aeneas/cwave/cwave_driver.c index b1790e9f..1bc8dbce 100644 --- a/aeneas/cwave/cwave_driver.c +++ b/aeneas/cwave/cwave_driver.c @@ -9,7 +9,7 @@ __copyright__ = """ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/cwave/cwave_func.c b/aeneas/cwave/cwave_func.c index 5e717e99..9f4a5003 100644 --- a/aeneas/cwave/cwave_func.c +++ b/aeneas/cwave/cwave_func.c @@ -9,7 +9,7 @@ __copyright__ = """ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/cwave/cwave_func.h b/aeneas/cwave/cwave_func.h index ae429924..51ac3df6 100644 --- a/aeneas/cwave/cwave_func.h +++ b/aeneas/cwave/cwave_func.h @@ -9,7 +9,7 @@ __copyright__ = """ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/cwave/cwave_py.c b/aeneas/cwave/cwave_py.c index 06493adf..4a497598 100644 --- a/aeneas/cwave/cwave_py.c +++ b/aeneas/cwave/cwave_py.c @@ -9,7 +9,7 @@ __copyright__ = """ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/cwave/cwave_setup.py b/aeneas/cwave/cwave_setup.py index 513a23ed..ab3fe847 100644 --- a/aeneas/cwave/cwave_setup.py +++ b/aeneas/cwave/cwave_setup.py @@ -23,7 +23,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" @@ -31,7 +31,7 @@ setup( name="cwave", - version="1.5.0", + version="1.5.1", description=""" Python C Extension for for reading WAVE files. """, diff --git a/aeneas/diagnostics.py b/aeneas/diagnostics.py index f2b571b6..f5dbc805 100644 --- a/aeneas/diagnostics.py +++ b/aeneas/diagnostics.py @@ -27,7 +27,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/downloader.py b/aeneas/downloader.py index 3436b46e..2697c809 100644 --- a/aeneas/downloader.py +++ b/aeneas/downloader.py @@ -23,7 +23,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/dtw.py b/aeneas/dtw.py index 134e77e0..02575394 100644 --- a/aeneas/dtw.py +++ b/aeneas/dtw.py @@ -48,7 +48,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" @@ -310,7 +310,7 @@ def compute_accumulated_cost_matrix(self): self._compute_acm_c_extension, self._compute_acm_pure_python, (), - c_extension=True + c_extension=self.rconf[RuntimeConfiguration.C_EXTENSIONS] ) def _compute_acm_c_extension(self): @@ -355,7 +355,7 @@ def compute_path(self): self._compute_path_c_extension, self._compute_path_pure_python, (), - c_extension=True + c_extension=self.rconf[RuntimeConfiguration.C_EXTENSIONS] ) def _compute_path_c_extension(self): diff --git a/aeneas/espeakwrapper.py b/aeneas/espeakwrapper.py index 38c423fa..4fb60226 100644 --- a/aeneas/espeakwrapper.py +++ b/aeneas/espeakwrapper.py @@ -23,7 +23,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/executejob.py b/aeneas/executejob.py index 3590fe70..5d5e1479 100644 --- a/aeneas/executejob.py +++ b/aeneas/executejob.py @@ -30,7 +30,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/executetask.py b/aeneas/executetask.py index c949878d..405e7801 100644 --- a/aeneas/executetask.py +++ b/aeneas/executetask.py @@ -41,7 +41,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/extra/__init__.py b/aeneas/extra/__init__.py index 8b698ed4..bfac6fb1 100644 --- a/aeneas/extra/__init__.py +++ b/aeneas/extra/__init__.py @@ -13,7 +13,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL 3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/extra/ctw_espeak.py b/aeneas/extra/ctw_espeak.py index 7f8828f5..02a35ed4 100644 --- a/aeneas/extra/ctw_espeak.py +++ b/aeneas/extra/ctw_espeak.py @@ -18,7 +18,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/extra/ctw_speect.py b/aeneas/extra/ctw_speect.py index b7ade692..2bcfb91c 100644 --- a/aeneas/extra/ctw_speect.py +++ b/aeneas/extra/ctw_speect.py @@ -26,7 +26,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/festivalwrapper.py b/aeneas/festivalwrapper.py index 67dadd34..dd6a37af 100644 --- a/aeneas/festivalwrapper.py +++ b/aeneas/festivalwrapper.py @@ -21,7 +21,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/ffmpegwrapper.py b/aeneas/ffmpegwrapper.py index 108c7bae..b71995ca 100644 --- a/aeneas/ffmpegwrapper.py +++ b/aeneas/ffmpegwrapper.py @@ -23,7 +23,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/ffprobewrapper.py b/aeneas/ffprobewrapper.py index e3db20b4..0cb4638b 100644 --- a/aeneas/ffprobewrapper.py +++ b/aeneas/ffprobewrapper.py @@ -28,7 +28,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/globalconstants.py b/aeneas/globalconstants.py index 2d5aa210..43050c30 100644 --- a/aeneas/globalconstants.py +++ b/aeneas/globalconstants.py @@ -13,7 +13,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/globalfunctions.py b/aeneas/globalfunctions.py index 9767adf9..44522672 100644 --- a/aeneas/globalfunctions.py +++ b/aeneas/globalfunctions.py @@ -27,7 +27,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/hierarchytype.py b/aeneas/hierarchytype.py index 6f0007ec..e6532d65 100644 --- a/aeneas/hierarchytype.py +++ b/aeneas/hierarchytype.py @@ -15,7 +15,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/idsortingalgorithm.py b/aeneas/idsortingalgorithm.py index 1f9e4a63..01789644 100644 --- a/aeneas/idsortingalgorithm.py +++ b/aeneas/idsortingalgorithm.py @@ -24,7 +24,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/job.py b/aeneas/job.py index 9f24fa38..8a01a771 100644 --- a/aeneas/job.py +++ b/aeneas/job.py @@ -23,7 +23,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/language.py b/aeneas/language.py index f864cb48..ba0f57e8 100644 --- a/aeneas/language.py +++ b/aeneas/language.py @@ -14,7 +14,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/logger.py b/aeneas/logger.py index 4111171b..26de1c11 100644 --- a/aeneas/logger.py +++ b/aeneas/logger.py @@ -24,7 +24,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/mfcc.py b/aeneas/mfcc.py index 431cd470..333c7a21 100644 --- a/aeneas/mfcc.py +++ b/aeneas/mfcc.py @@ -27,7 +27,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/nuancettsapiwrapper.py b/aeneas/nuancettsapiwrapper.py index a2d74776..bd17700d 100644 --- a/aeneas/nuancettsapiwrapper.py +++ b/aeneas/nuancettsapiwrapper.py @@ -36,7 +36,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/plotter.py b/aeneas/plotter.py index 7a2c0eb9..7004bd79 100644 --- a/aeneas/plotter.py +++ b/aeneas/plotter.py @@ -35,7 +35,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/res/__init__.py b/aeneas/res/__init__.py index 6a0b0895..8d4980f4 100644 --- a/aeneas/res/__init__.py +++ b/aeneas/res/__init__.py @@ -13,7 +13,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL 3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/runtimeconfiguration.py b/aeneas/runtimeconfiguration.py index bb78c192..2e5677d3 100644 --- a/aeneas/runtimeconfiguration.py +++ b/aeneas/runtimeconfiguration.py @@ -24,7 +24,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/sd.py b/aeneas/sd.py index 1428c6ca..0639a386 100644 --- a/aeneas/sd.py +++ b/aeneas/sd.py @@ -34,7 +34,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/syncmap.py b/aeneas/syncmap.py index 48f770e1..336b627a 100644 --- a/aeneas/syncmap.py +++ b/aeneas/syncmap.py @@ -40,7 +40,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/synthesizer.py b/aeneas/synthesizer.py index abfa3aa8..693da782 100644 --- a/aeneas/synthesizer.py +++ b/aeneas/synthesizer.py @@ -28,7 +28,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/task.py b/aeneas/task.py index 09cc2f87..4cd55a80 100644 --- a/aeneas/task.py +++ b/aeneas/task.py @@ -29,7 +29,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/tests/__init__.py b/aeneas/tests/__init__.py index 803dc12d..c4f9fec4 100644 --- a/aeneas/tests/__init__.py +++ b/aeneas/tests/__init__.py @@ -15,7 +15,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL 3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/textfile.py b/aeneas/textfile.py index 2dafb94a..d37917a5 100644 --- a/aeneas/textfile.py +++ b/aeneas/textfile.py @@ -33,7 +33,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/timevalue.py b/aeneas/timevalue.py index 3541b6a1..bfbf7c1f 100644 --- a/aeneas/timevalue.py +++ b/aeneas/timevalue.py @@ -23,7 +23,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/tools/README.md b/aeneas/tools/README.md index bd3da1e2..a9c6f424 100644 --- a/aeneas/tools/README.md +++ b/aeneas/tools/README.md @@ -93,6 +93,12 @@ In the constructor of ``ExecuteTaskCLI`` you might want to specify ``use_sys=False`` so that the tool never calls a ``sys.exit()`` or outputs to stdout directly. +If you are creating an executable wrapper, like those in the ``aeneas/bin/`` directory, +you can also pass an ``invoke`` parameter to the constructor, +specifying the command string +(e.g., ``python your_tool_name.py`` or ``your_tool_name``, etc.) +which the user can use to invoke your tool. + Note that the first element of the ``arguments`` list must be a dummy placeholder, to formally resemble the ``sys.argv[0]``. (This defect will be removed in a future version.) diff --git a/aeneas/tools/__init__.py b/aeneas/tools/__init__.py index 56313b76..073fb85a 100644 --- a/aeneas/tools/__init__.py +++ b/aeneas/tools/__init__.py @@ -14,7 +14,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL 3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/tools/abstract_cli_program.py b/aeneas/tools/abstract_cli_program.py index 6d968dcf..b1d235c8 100644 --- a/aeneas/tools/abstract_cli_program.py +++ b/aeneas/tools/abstract_cli_program.py @@ -25,7 +25,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL 3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" @@ -41,6 +41,7 @@ class AbstractCLIProgram(Loggable): otherwise, never call ``sys.exit`` and just return a return code/value :type use_sys: bool + :param string invoke: the CLI command to be invoked :param rconf: a runtime configuration. Default: ``None``, meaning that default settings will be used. :type rconf: :class:`aeneas.runtimeconfiguration.RuntimeConfiguration` @@ -72,8 +73,9 @@ class AbstractCLIProgram(Loggable): TAG = u"CLI" - def __init__(self, use_sys=True, rconf=None, logger=None): + def __init__(self, use_sys=True, invoke=None, rconf=None, logger=None): super(AbstractCLIProgram, self).__init__(rconf=rconf, logger=logger) + self.invoke = u"python -m aeneas.tools.%s" % (self.NAME) if (invoke is None) else invoke self.use_sys = use_sys self.formal_arguments_raw = [] self.formal_arguments = [] @@ -171,7 +173,7 @@ def print_help(self, short=False): synopsis = [ u"SYNOPSIS", - u" python -m aeneas.tools.%s [-h|--help|--version]" % (self.NAME) + u" %s [-h|--help|--version]" % (self.invoke) ] if "synopsis" in self.HELP: for syn, opt in self.HELP["synopsis"]: @@ -179,7 +181,7 @@ def print_help(self, short=False): opt = u" [OPTIONS]" else: opt = u"" - synopsis.append(u" python -m aeneas.tools.%s %s%s" % (self.NAME, syn, opt)) + synopsis.append(u" %s %s%s" % (self.invoke, syn, opt)) synopsis.append(u"") @@ -208,7 +210,7 @@ def print_help(self, short=False): if ("examples" in self.HELP) and (len(self.HELP["examples"]) > 0): examples.append(u"EXAMPLES") for exa in self.HELP["examples"]: - examples.append(u" python -m aeneas.tools.%s %s" % (self.NAME, exa)) + examples.append(u" %s %s" % (self.invoke, exa)) examples.append(u"") footer = [ diff --git a/aeneas/tools/convert_syncmap.py b/aeneas/tools/convert_syncmap.py index ae0bd638..07b20e9e 100644 --- a/aeneas/tools/convert_syncmap.py +++ b/aeneas/tools/convert_syncmap.py @@ -22,7 +22,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL 3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/tools/download.py b/aeneas/tools/download.py index 2c356ff8..254d23fb 100644 --- a/aeneas/tools/download.py +++ b/aeneas/tools/download.py @@ -22,7 +22,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL 3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/tools/execute_job.py b/aeneas/tools/execute_job.py index 6f8cb0e4..4bb3f177 100644 --- a/aeneas/tools/execute_job.py +++ b/aeneas/tools/execute_job.py @@ -24,7 +24,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL 3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/tools/execute_task.py b/aeneas/tools/execute_task.py index 3b3010fa..34efe5a1 100644 --- a/aeneas/tools/execute_task.py +++ b/aeneas/tools/execute_task.py @@ -37,7 +37,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL 3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" @@ -617,15 +617,15 @@ def print_examples(self, full=False): msg.append(u"Example %d (%s)" % (i, example[u"description"])) # NOTE too verbose now that we have dozens of examples #msg.append(u" $ CONFIG_STRING=\"%s\"" % (example[u"config"])) - #msg.append(u" $ python -m aeneas.tools.%s %s %s \"$CONFIG_STRING\" %s %s" % ( - # self.NAME, + #msg.append(u" $ %s %s %s \"$CONFIG_STRING\" %s %s" % ( + # self.invoke, # example[u"audio"], # example[u"text"], # example[u"syncmap"], # example[u"options"] #)) #msg.append(u" or") - msg.append(u" $ python -m aeneas.tools.%s %s" % (self.NAME, key)) + msg.append(u" $ %s %s" % (self.invoke, key)) msg.append(u"") i += 1 self.print_generic(u"\n" + u"\n".join(msg) + u"\n") diff --git a/aeneas/tools/extract_mfcc.py b/aeneas/tools/extract_mfcc.py index 783642e6..de707d24 100644 --- a/aeneas/tools/extract_mfcc.py +++ b/aeneas/tools/extract_mfcc.py @@ -26,7 +26,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL 3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/tools/ffmpeg_wrapper.py b/aeneas/tools/ffmpeg_wrapper.py index 221dbef9..5e89e2ed 100644 --- a/aeneas/tools/ffmpeg_wrapper.py +++ b/aeneas/tools/ffmpeg_wrapper.py @@ -22,7 +22,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL 3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/tools/ffprobe_wrapper.py b/aeneas/tools/ffprobe_wrapper.py index 9b7b1197..ef2b79a9 100644 --- a/aeneas/tools/ffprobe_wrapper.py +++ b/aeneas/tools/ffprobe_wrapper.py @@ -24,7 +24,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL 3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/tools/plot_waveform.py b/aeneas/tools/plot_waveform.py index 6eb9d0ab..142b5c33 100644 --- a/aeneas/tools/plot_waveform.py +++ b/aeneas/tools/plot_waveform.py @@ -22,7 +22,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL 3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/tools/read_audio.py b/aeneas/tools/read_audio.py index 25c3992d..ba044958 100644 --- a/aeneas/tools/read_audio.py +++ b/aeneas/tools/read_audio.py @@ -23,7 +23,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL 3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/tools/read_text.py b/aeneas/tools/read_text.py index 2b33c121..f00fd38b 100644 --- a/aeneas/tools/read_text.py +++ b/aeneas/tools/read_text.py @@ -21,7 +21,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL 3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/tools/run_sd.py b/aeneas/tools/run_sd.py index c772f5b7..288ee56c 100644 --- a/aeneas/tools/run_sd.py +++ b/aeneas/tools/run_sd.py @@ -28,7 +28,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL 3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/tools/run_vad.py b/aeneas/tools/run_vad.py index d8688587..2b798694 100644 --- a/aeneas/tools/run_vad.py +++ b/aeneas/tools/run_vad.py @@ -26,7 +26,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL 3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/tools/synthesize_text.py b/aeneas/tools/synthesize_text.py index 8872a980..1e74d770 100644 --- a/aeneas/tools/synthesize_text.py +++ b/aeneas/tools/synthesize_text.py @@ -25,7 +25,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL 3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/tools/validate.py b/aeneas/tools/validate.py index 51bf6167..a98262ae 100644 --- a/aeneas/tools/validate.py +++ b/aeneas/tools/validate.py @@ -27,7 +27,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL 3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/tree.py b/aeneas/tree.py index b64dc5ba..bebf4d1e 100644 --- a/aeneas/tree.py +++ b/aeneas/tree.py @@ -20,7 +20,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/ttswrapper.py b/aeneas/ttswrapper.py index 429fe3e8..64f231d5 100644 --- a/aeneas/ttswrapper.py +++ b/aeneas/ttswrapper.py @@ -26,7 +26,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/vad.py b/aeneas/vad.py index 4cb833e9..384601fe 100644 --- a/aeneas/vad.py +++ b/aeneas/vad.py @@ -31,7 +31,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas/validator.py b/aeneas/validator.py index 75487708..8a883d91 100644 --- a/aeneas/validator.py +++ b/aeneas/validator.py @@ -33,7 +33,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL v3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/aeneas_check_setup.py b/aeneas_check_setup.py index 613be41c..ae427951 100644 --- a/aeneas_check_setup.py +++ b/aeneas_check_setup.py @@ -22,7 +22,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL 3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/bin/aeneas_check_setup b/bin/aeneas_check_setup index 613be41c..ae427951 100755 --- a/bin/aeneas_check_setup +++ b/bin/aeneas_check_setup @@ -22,7 +22,7 @@ __copyright__ = """ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL 3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/bin/aeneas_convert_syncmap b/bin/aeneas_convert_syncmap index 83e3f67d..d987f016 100755 --- a/bin/aeneas_convert_syncmap +++ b/bin/aeneas_convert_syncmap @@ -18,7 +18,7 @@ __copyright__ = """ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL 3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" @@ -26,7 +26,7 @@ def main(): """ Convert a sync map from a format to another. """ - ConvertSyncMapCLI().run(arguments=sys.argv) + ConvertSyncMapCLI(invoke="aeneas_convert_syncmap").run(arguments=sys.argv) if __name__ == '__main__': main() diff --git a/bin/aeneas_download b/bin/aeneas_download index 3f0fb136..28b11834 100755 --- a/bin/aeneas_download +++ b/bin/aeneas_download @@ -18,7 +18,7 @@ __copyright__ = """ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL 3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" @@ -26,7 +26,7 @@ def main(): """ Download an audio file from a YouTube video. """ - DownloadCLI().run(arguments=sys.argv) + DownloadCLI(invoke="aeneas_download").run(arguments=sys.argv) if __name__ == '__main__': main() diff --git a/bin/aeneas_execute_job b/bin/aeneas_execute_job index ce84e43d..dac43db6 100755 --- a/bin/aeneas_execute_job +++ b/bin/aeneas_execute_job @@ -20,7 +20,7 @@ __copyright__ = """ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL 3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" @@ -30,7 +30,7 @@ def main(): as a container and a configuration string (i.e., from a wizard). """ - ExecuteJobCLI().run(arguments=sys.argv) + ExecuteJobCLI(invoke="aeneas_execute_job").run(arguments=sys.argv) if __name__ == '__main__': main() diff --git a/bin/aeneas_execute_task b/bin/aeneas_execute_task index 1640e3ce..787936fc 100755 --- a/bin/aeneas_execute_task +++ b/bin/aeneas_execute_task @@ -19,7 +19,7 @@ __copyright__ = """ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL 3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" @@ -28,7 +28,7 @@ def main(): Execute a Task, that is, a pair of audio/text files and a configuration string. """ - ExecuteTaskCLI().run(arguments=sys.argv) + ExecuteTaskCLI(invoke="aeneas_execute_task").run(arguments=sys.argv) if __name__ == '__main__': main() diff --git a/bin/aeneas_plot_waveform b/bin/aeneas_plot_waveform index e0f69466..af287ad9 100755 --- a/bin/aeneas_plot_waveform +++ b/bin/aeneas_plot_waveform @@ -18,7 +18,7 @@ __copyright__ = """ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL 3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" @@ -26,7 +26,7 @@ def main(): """ Plot a waveform and labels to file. """ - PlotWaveformCLI().run(arguments=sys.argv) + PlotWaveformCLI(invoke="aeneas_plot_waveform").run(arguments=sys.argv) if __name__ == '__main__': main() diff --git a/bin/aeneas_synthesize_text b/bin/aeneas_synthesize_text index ec4bf834..33ff0d8e 100755 --- a/bin/aeneas_synthesize_text +++ b/bin/aeneas_synthesize_text @@ -19,7 +19,7 @@ __copyright__ = """ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL 3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" @@ -28,7 +28,7 @@ def main(): Synthesize several text fragments, producing a WAV audio file. """ - SynthesizeTextCLI().run(arguments=sys.argv) + SynthesizeTextCLI(invoke="aeneas_synthesize_text").run(arguments=sys.argv) if __name__ == '__main__': main() diff --git a/bin/aeneas_validate b/bin/aeneas_validate index 723e2183..0a66d17b 100755 --- a/bin/aeneas_validate +++ b/bin/aeneas_validate @@ -25,7 +25,7 @@ __copyright__ = """ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL 3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" @@ -40,7 +40,7 @@ def main(): 5. a job TXT configuration file 6. a job XML configuration file """ - ValidateCLI().run(arguments=sys.argv) + ValidateCLI(invoke="aeneas_validate").run(arguments=sys.argv) if __name__ == '__main__': main() diff --git a/check_dependencies.py b/check_dependencies.py index 613be41c..ae427951 100644 --- a/check_dependencies.py +++ b/check_dependencies.py @@ -22,7 +22,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL 3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/docs/source/changelog.rst b/docs/source/changelog.rst index 99ecf868..1022b522 100644 --- a/docs/source/changelog.rst +++ b/docs/source/changelog.rst @@ -1,6 +1,11 @@ Changelog ========= +v1.5.1 (2016-??-??) +------------------- + +#. Added ``invoke`` parameter to ``AbstractCLIProgram`` constructor and modified tools consequently + v1.5.0.2 (2016-04-09) --------------------- diff --git a/docs/source/conf.py b/docs/source/conf.py index 8fbdfd0a..2d7835aa 100644 --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -60,7 +60,7 @@ # The short X.Y version. version = '1.5' # The full version, including alpha/beta/rc tags. -release = '1.5.0' +release = '1.5.1' # The language for content autogenerated by Sphinx. Refer to documentation # for a list of supported languages. diff --git a/install_dependencies.sh b/install_dependencies.sh index a8c8e680..2e4b11c6 100644 --- a/install_dependencies.sh +++ b/install_dependencies.sh @@ -7,7 +7,7 @@ # Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) # """ # __license__ = "GNU AGPL 3" -# __version__ = "1.5.0" +# __version__ = "1.5.1" # __email__ = "aeneas@readbeyond.it" # __status__ = "Production" diff --git a/run_all_unit_tests.py b/run_all_unit_tests.py index be27c50e..2bed4998 100644 --- a/run_all_unit_tests.py +++ b/run_all_unit_tests.py @@ -19,7 +19,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL 3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" diff --git a/setup.py b/setup.py index 797e184f..8624e4d0 100644 --- a/setup.py +++ b/setup.py @@ -17,7 +17,7 @@ Copyright 2015-2016, Alberto Pettarin (www.albertopettarin.it) """ __license__ = "GNU AGPL 3" -__version__ = "1.5.0" +__version__ = "1.5.1" __email__ = "aeneas@readbeyond.it" __status__ = "Production" @@ -86,7 +86,7 @@ "aeneas.extra": ["*.md"], "aeneas.tools": ["res/*", "*.md"] }, - version="1.5.0.2", + version="1.5.1.0", description=SHORT_DESCRIPTION, author="Alberto Pettarin", author_email="alberto@albertopettarin.it", From 7aaf27bee89dffa439706fa37ec995849e38e51e Mon Sep 17 00:00:00 2001 From: Alberto Pettarin Date: Tue, 19 Apr 2016 10:55:57 +0200 Subject: [PATCH 02/16] Single C ext rconf killswitch. Fixed dtype=int issue in pure Python dtw code. --- aeneas/audiofilemfcc.py | 2 +- aeneas/dtw.py | 6 +++--- aeneas/globalfunctions.py | 34 +++++++++++++++++++------------- aeneas/runtimeconfiguration.py | 36 ++++++++++++++++++++++++++++++++++ aeneas/ttswrapper.py | 4 ++-- docs/source/changelog.rst | 2 ++ 6 files changed, 64 insertions(+), 20 deletions(-) diff --git a/aeneas/audiofilemfcc.py b/aeneas/audiofilemfcc.py index f1d17a30..18346463 100644 --- a/aeneas/audiofilemfcc.py +++ b/aeneas/audiofilemfcc.py @@ -134,7 +134,7 @@ def __init__( self._compute_mfcc_c_extension, self._compute_mfcc_pure_python, (), - c_extension=self.rconf[RuntimeConfiguration.C_EXTENSIONS] + rconf=self.rconf ) self.audio_length = self.audio_file.audio_length if audio_file_was_none: diff --git a/aeneas/dtw.py b/aeneas/dtw.py index 02575394..7fb0e226 100644 --- a/aeneas/dtw.py +++ b/aeneas/dtw.py @@ -310,7 +310,7 @@ def compute_accumulated_cost_matrix(self): self._compute_acm_c_extension, self._compute_acm_pure_python, (), - c_extension=self.rconf[RuntimeConfiguration.C_EXTENSIONS] + rconf=self.rconf ) def _compute_acm_c_extension(self): @@ -355,7 +355,7 @@ def compute_path(self): self._compute_path_c_extension, self._compute_path_pure_python, (), - c_extension=self.rconf[RuntimeConfiguration.C_EXTENSIONS] + rconf=self.rconf ) def _compute_path_c_extension(self): @@ -412,7 +412,7 @@ def _compute_cost_matrix(self): self.log(u"Limiting delta to m") delta = m cost_matrix = numpy.zeros((n, delta)) - centers = numpy.zeros(n) + centers = numpy.zeros(n, dtype=int) for i in range(n): # center j at row i center_j = (m * i) // n diff --git a/aeneas/globalfunctions.py b/aeneas/globalfunctions.py index 44522672..f2e6dc2c 100644 --- a/aeneas/globalfunctions.py +++ b/aeneas/globalfunctions.py @@ -759,7 +759,7 @@ def run_c_extension_with_fallback( c_function, py_function, args, - c_extension=True + rconf ): """ Run a function calling a C extension, falling back @@ -769,8 +769,8 @@ def run_c_extension_with_fallback( :param string extension: the name of the extension :param function c_function: the (Python) function calling the C extension :param function py_function: the (Python) function providing the fallback - :param bool c_extension: if ``True``, try running the C extension first; - if ``False``, directly run the pure Python fallback + :param rconf: the runtime configuration + :type rconf: :class:`aeneas.runtimeconfiguration.RuntimeConfiguration` :rtype: depends on the extension being called :raises: RuntimeError: if both the C extension and the pure Python code did not succeed. @@ -778,20 +778,26 @@ def run_c_extension_with_fallback( .. versionadded:: 1.4.0 """ computed = False - if (c_extension) and (c_function is not None): - log_function(u"C extensions enabled") - if can_run_c_extension(extension): - log_function([u"C extensions enabled and %s can be loaded", extension]) + if not rconf[u"c_extensions"]: + log_function(u"C extensions disabled") + elif not rconf[extension]: + log_function([u"C extension %s disabled", extension]) + else: + log_function([u"C extension %s enabled", extension]) + if c_function is None: + log_function(u"C function is None") + elif can_run_c_extension(extension): + log_function([u"C extension %s enabled and it can be loaded", extension]) computed, result = c_function(*args) else: - log_function([u"C extensions enabled but %s cannot be loaded", extension]) - else: - log_function(u"C extensions disabled") - if (not computed) and (py_function is not None): - log_function(u"Running the pure Python code") - computed, result = py_function(*args) + log_function([u"C extension %s enabled but it cannot be loaded", extension]) + if not computed: + if py_function is None: + log_function(u"Python function is None") + else: + log_function(u"Running the pure Python code") + computed, result = py_function(*args) if not computed: - # TODO create a more meaningful message raise RuntimeError(u"Both the C extension and the pure Python code failed. (Wrong arguments? Input too big?)") return result diff --git a/aeneas/runtimeconfiguration.py b/aeneas/runtimeconfiguration.py index 2e5677d3..4da9e4d5 100644 --- a/aeneas/runtimeconfiguration.py +++ b/aeneas/runtimeconfiguration.py @@ -58,11 +58,34 @@ class RuntimeConfiguration(Configuration): If ``True`` and Python C extensions are available, use them. Otherwise, use pure Python code. + This option is equivalent to + setting ``CDTW``, ``CEW`` and ``CMFCC`` at once. + Default: ``True``. .. versionadded:: 1.4.1 """ + CDTW = "cdtw" + """ + If ``True`` and Python C extension ``cdtw`` is available, use it. + Otherwise, use pure Python code. + + Default: ``True``. + + .. versionadded:: 1.5.1 + """ + + CEW = "cew" + """ + If ``True`` and Python C extension ``cew`` is available, use it. + Otherwise, use pure Python code. + + Default: ``True``. + + .. versionadded:: 1.5.1 + """ + CEW_SUBPROCESS_ENABLED = "cew_subprocess_enabled" """ If ``True``, calls to ``aeneas.cew`` will be done via ``subprocess``. @@ -84,6 +107,16 @@ class RuntimeConfiguration(Configuration): .. versionadded:: 1.5.0 """ + CMFCC = "cmfcc" + """ + If ``True`` and Python C extension ``cmfcc`` is available, use it. + Otherwise, use pure Python code. + + Default: ``True``. + + .. versionadded:: 1.5.1 + """ + DTW_ALGORITHM = "dtw_algorithm" """ DTW aligner algorithm. @@ -510,6 +543,9 @@ class RuntimeConfiguration(Configuration): (ALLOW_UNLISTED_LANGUAGES, (False, bool, [])), (C_EXTENSIONS, (True, bool, [])), + (CDTW, (True, bool, [])), + (CEW, (True, bool, [])), + (CMFCC, (True, bool, [])), (CEW_SUBPROCESS_ENABLED, (False, bool, [])), (CEW_SUBPROCESS_PATH, ("python", None, [])), # or a full path like "/usr/bin/python" diff --git a/aeneas/ttswrapper.py b/aeneas/ttswrapper.py index 64f231d5..2029fd5b 100644 --- a/aeneas/ttswrapper.py +++ b/aeneas/ttswrapper.py @@ -280,7 +280,7 @@ def synthesize_multiple(self, text_file, output_file_path, quit_after=None, back c_extension_function, subprocess_function, (text_file, output_file_path, quit_after, backwards), - c_extension=self.rconf[RuntimeConfiguration.C_EXTENSIONS] + rconf=self.rconf ) def _synthesize_multiple_python(self, text_file, output_file_path, quit_after=None, backwards=False): @@ -477,7 +477,7 @@ def synthesize_single(self, text, language, output_file_path): c_extension_function, subprocess_function, (text, voice_code, output_file_path), - c_extension=self.rconf[RuntimeConfiguration.C_EXTENSIONS] + rconf=self.rconf ) return result[0] diff --git a/docs/source/changelog.rst b/docs/source/changelog.rst index 1022b522..f84f100a 100644 --- a/docs/source/changelog.rst +++ b/docs/source/changelog.rst @@ -5,6 +5,8 @@ v1.5.1 (2016-??-??) ------------------- #. Added ``invoke`` parameter to ``AbstractCLIProgram`` constructor and modified tools consequently +#. Added rconf ``CDTW``, ``CEW``, and ``CMFCC`` parameters to prevent running a single C extension +#. Fixed a numerical issue in ``dtw.py`` by explicit stating ``dtype=int`` in ``centers`` initializer, pure Python code only v1.5.0.2 (2016-04-09) --------------------- From caf4d9dda480642512aa2becdb0cdf65b9676e3e Mon Sep 17 00:00:00 2001 From: Alberto Pettarin Date: Tue, 19 Apr 2016 11:54:39 +0200 Subject: [PATCH 03/16] Added check in execute_task for swapped args --- aeneas/audiofile.py | 71 ++++++++++++++++++++++++++++++++++++ aeneas/tools/execute_task.py | 8 ++++ 2 files changed, 79 insertions(+) diff --git a/aeneas/audiofile.py b/aeneas/audiofile.py index 7b139ec9..de2847d6 100644 --- a/aeneas/audiofile.py +++ b/aeneas/audiofile.py @@ -116,6 +116,77 @@ class AudioFile(Loggable): :type logger: :class:`~aeneas.logger.Logger` """ + FILE_EXTENSIONS = [ + u"3g2", + u"3gp", + u"aa", + u"aa3", + u"aac", + u"aax", + u"aiff", + u"alac", + u"amr", + u"ape", + u"asf", + u"at3", + u"at9", + u"au", + u"avi", + u"awb", + u"celt", + u"dct", + u"dss", + u"dvf", + u"eac", + u"flac", + u"flv", + u"gsm", + u"m4a", + u"m4b", + u"m4p", + u"m4v", + u"mid", + u"midi", + u"mkv", + u"mmf", + u"mov", + u"mp2", + u"mp3", + u"mp4", + u"mpc", + u"mpeg", + u"mpg", + u"mpv", + u"msv", + u"oga", + u"ogg", + u"ogv", + u"oma", + u"opus", + u"pcm", + u"qt", + u"ra", + u"ram", + u"raw", + u"riff", + u"rm", + u"rmvb", + u"shn", + u"sln", + u"theora", + u"tta", + u"vob", + u"vorbis", + u"vox", + u"wav", + u"webm", + u"wma", + u"wmv", + u"wv", + u"yuv", + ] + """ Extensions of common formats for audio (and video) files. """ + TAG = u"AudioFile" def __init__(self, file_path=None, is_mono_wave=False, rconf=None, logger=None): diff --git a/aeneas/tools/execute_task.py b/aeneas/tools/execute_task.py index 34efe5a1..2e98b7cc 100644 --- a/aeneas/tools/execute_task.py +++ b/aeneas/tools/execute_task.py @@ -11,6 +11,7 @@ import sys from aeneas.adjustboundaryalgorithm import AdjustBoundaryAlgorithm +from aeneas.audiofile import AudioFile from aeneas.downloader import Downloader from aeneas.espeakwrapper import ESPEAKWrapper from aeneas.executetask import ExecuteTask @@ -525,6 +526,13 @@ def perform_command(self): self.print_error(u"An unexpected error occurred while downloading audio from YouTube:") self.print_error(u"%s" % exc) return self.ERROR_EXIT_CODE + else: + audio_extension = gf.file_extension(audio_file_path) + if audio_extension.lower() not in AudioFile.FILE_EXTENSIONS: + self.print_warning(u"Your audio file path has extension '%s', which is uncommon for an audio file." % audio_extension) + self.print_warning(u"Attempting at executing your Task anyway.") + self.print_warning(u"If it fails, you might have swapped the first two arguments.") + self.print_warning(u"The audio file path should be the first argument, the text file path the second.") try: self.print_info(u"Creating task...") From 4fabbb44137a23fdb5ca308a8695ebb8127662c3 Mon Sep 17 00:00:00 2001 From: Alberto Pettarin Date: Tue, 19 Apr 2016 15:54:48 +0200 Subject: [PATCH 04/16] Better EAF sync map output --- README.md | 2 +- README.rst | 2 +- aeneas/container.py | 32 ++++++++++---------- aeneas/executetask.py | 1 - aeneas/globalconstants.py | 16 ++++++++++ aeneas/globalfunctions.py | 44 ++++++++++++++++++++-------- aeneas/syncmap.py | 8 ++--- aeneas/task.py | 21 ++++++------- aeneas/tests/test_globalfunctions.py | 6 ++++ aeneas/tools/execute_task.py | 1 + docs/source/changelog.rst | 2 ++ 11 files changed, 91 insertions(+), 44 deletions(-) diff --git a/README.md b/README.md index 9e8a479d..bc719c41 100644 --- a/README.md +++ b/README.md @@ -3,7 +3,7 @@ **aeneas** is a Python/C library and a set of tools to automagically synchronize audio and text (aka forced alignment). * Version: 1.5.1.0 -* Date: 2016-04-09 +* Date: 2016-??-?? * Developed by: [ReadBeyond](http://www.readbeyond.it/) * Lead Developer: [Alberto Pettarin](http://www.albertopettarin.it/) * License: the GNU Affero General Public License Version 3 (AGPL v3) diff --git a/README.rst b/README.rst index a7fb8656..c43b88d3 100644 --- a/README.rst +++ b/README.rst @@ -5,7 +5,7 @@ aeneas synchronize audio and text (aka forced alignment). - Version: 1.5.1.0 -- Date: 2016-04-09 +- Date: 2016-??-?? - Developed by: `ReadBeyond `__ - Lead Developer: `Alberto Pettarin `__ - License: the GNU Affero General Public License Version 3 (AGPL v3) diff --git a/aeneas/container.py b/aeneas/container.py index dceb2429..ee589432 100644 --- a/aeneas/container.py +++ b/aeneas/container.py @@ -363,19 +363,21 @@ def _set_actual_container(self): # set the actual container self.log(u"Setting actual container...") - # TODO map this - if self.container_format == ContainerFormat.ZIP: - self.actual_container = _ContainerZIP(self.file_path, rconf=self.rconf, logger=self.logger) - elif self.container_format == ContainerFormat.EPUB: - self.actual_container = _ContainerZIP(self.file_path, rconf=self.rconf, logger=self.logger) - elif self.container_format == ContainerFormat.TAR: - self.actual_container = _ContainerTAR(self.file_path, "", rconf=self.rconf, logger=self.logger) - elif self.container_format == ContainerFormat.TAR_GZ: - self.actual_container = _ContainerTAR(self.file_path, ":gz", rconf=self.rconf, logger=self.logger) - elif self.container_format == ContainerFormat.TAR_BZ2: - self.actual_container = _ContainerTAR(self.file_path, ":bz2", rconf=self.rconf, logger=self.logger) - elif self.container_format == ContainerFormat.UNPACKED: - self.actual_container = _ContainerUnpacked(self.file_path, rconf=self.rconf, logger=self.logger) + class_map = { + ContainerFormat.ZIP: (_ContainerZIP, None), + ContainerFormat.EPUB: (_ContainerZIP, None), + ContainerFormat.TAR: (_ContainerTAR, ""), + ContainerFormat.TAR_GZ: (_ContainerTAR, ":gz"), + ContainerFormat.TAR_BZ2: (_ContainerTAR, ":bz2"), + ContainerFormat.UNPACKED: (_ContainerUnpacked, None) + } + actual_class, variant = class_map[self.container_format] + self.actual_container = actual_class( + file_path=self.file_path, + variant=variant, + rconf=self.rconf, + logger=self.logger + ) self.log([u"Actual container format: '%s'", self.container_format]) self.log(u"Setting actual container... done") @@ -445,7 +447,7 @@ class _ContainerZIP(Loggable): TAG = u"ContainerZIP" - def __init__(self, file_path, rconf=None, logger=None): + def __init__(self, file_path, variant=None, rconf=None, logger=None): super(_ContainerZIP, self).__init__(rconf=rconf, logger=logger) self.file_path = file_path @@ -497,7 +499,7 @@ class _ContainerUnpacked(Loggable): TAG = u"ContainerUnpacked" - def __init__(self, file_path, rconf=None, logger=None): + def __init__(self, file_path, variant=None, rconf=None, logger=None): super(_ContainerUnpacked, self).__init__(rconf=rconf, logger=logger) self.file_path = file_path diff --git a/aeneas/executetask.py b/aeneas/executetask.py index 405e7801..54a65147 100644 --- a/aeneas/executetask.py +++ b/aeneas/executetask.py @@ -655,7 +655,6 @@ def _check_no_zero(self, min_mws): """ Check for fragments with zero duration """ if self.task.configuration["o_no_zero"]: self.log(u"Checking for fragments with zero duration...") - # TODO use min_mws when doable, e.g. only one fragment? delta = TimeValue("0.001") leaves = self.task.sync_map.fragments_tree.vleaves_not_empty # first and last leaves are HEAD and TAIL, skipping them diff --git a/aeneas/globalconstants.py b/aeneas/globalconstants.py index 43050c30..d3e1e33c 100644 --- a/aeneas/globalconstants.py +++ b/aeneas/globalconstants.py @@ -924,6 +924,22 @@ .. versionadded:: 1.5.0 """ +PPN_TASK_OS_FILE_EAF_AUDIO_REF = "os_task_file_eaf_audio_ref" +""" +The value of the ```` element in the output sync map, +complete with the ``file://`` prefix. +It applies to ``EAF`` sync maps only. + +Usage: config string, TXT config file, XML config file + +Values: string + +Example:: + + os_task_file_eaf_audio_ref=file:///audio/p001.mp3 + +""" + PPN_TASK_OS_FILE_SMIL_AUDIO_REF = "os_task_file_smil_audio_ref" """ The value of the ``src`` attribute for the ``