Closed lajash closed 9 years ago
Looks like this is yet another problem with scikits.audiolab
(perhaps an incompatibility with LLVM/CLang) This will be fixed if issue #1 is.
Thanks for the prompt reply. Is there anyway to use this without the audio lab features ?
Probably. I think I only used scikits.audiolab
to read in MP3 data. I'll see if I can make a branch without it.
That would be great. Many thanks Jason.
There's now a branch sans-audiolab
that does not have the scikits.audiolab
package as a dependency. This means that you can't use the plotting script, but the library functions will still work.
OK super .. many thanks Jason …
On Sep 13, 2014, at 2:12 PM, Jason Heeris notifications@github.com wrote:
There's now a branch sans-audiolab that does not have the scikits.audiolab package as a dependency. This means that you can't use the plotting script, but the library functions will still work.
— Reply to this email directly or view it on GitHub.
I just updated the branch so that the plotting script works again, but only on WAV files. To run it on the sample OGG file, you'll need to convert it to WAV with eg. sox
:
$ sox samples/FurElise.ogg samples/FurElise.wav
$ python -m gammatone samples/FurElise.wav -d 10
Excellent mate .. many thanks. On Sep 13, 2014, at 7:03 PM, Jason Heeris notifications@github.com wrote:
I just updated the branch so that the plotting script works again, but only on WAV files. To run it on the sample OGG file, you'll need to convert it to WAV with eg. sox:
$ sox samples/FurElise.ogg samples/FurElise.wav $ python -m gammatone samples/FurElise.wav -d 10 — Reply to this email directly or view it on GitHub.
Did you check pysndfile? It could be a good scikits.audiolab replacement.
Since both are just wrappers around libsndfile
, and it's actually compiling libsndfile
that's the pain point, I don't know that pysndfile
would be much of an improvement :/
I think I'd rather just restrict the scope of the project to processing raw data, and let anyone integrating it work out how to get that data in. I could then write a separate script as a demo project, to separate the dependencies for the library from the dependencies for the demo.
I think that is a good approach. It's actually not hard to get a libsndfile binary for Windows (the official distribution has installers for Win32 and Win64), but I agree that is totally out of the scope of your project.
By the way, great job! I did exactly the same for the Julia programming language, but I guess I'll be using your code for a while, as I'm working on a Python code base right now.
I actually did install the libsndfile
binary, but pip
still couldn't compile the wrapper code for it. It's possible that I would have been able to get it working eventually, but I don't want my library to be that difficult to install.
If you've implemented it in Julia, you might find some of the simplifications I've made to be useful too. Just look through the commit history for anything mentioning vectorisation or simplification.
Fixed by 35314bddb04d163740e274b63fa1ec4b4172bada.
Installing from source on Mavericks ( using setup.py with python3.4) results in the following errors : running install running bdist_egg running egg_info writing top-level names to Gammatone.egg-info/top_level.txt writing requirements to Gammatone.egg-info/requires.txt writing dependency_links to Gammatone.egg-info/dependency_links.txt writing entry points to Gammatone.egg-info/entry_points.txt writing Gammatone.egg-info/PKG-INFO reading manifest file 'Gammatone.egg-info/SOURCES.txt' writing manifest file 'Gammatone.egg-info/SOURCES.txt' installing library code to build/bdist.macosx-10.6-intel/egg running install_lib running build_py creating build/bdist.macosx-10.6-intel/egg creating build/bdist.macosx-10.6-intel/egg/gammatone copying build/lib/gammatone/init.py -> build/bdist.macosx-10.6-intel/egg/gammatone copying build/lib/gammatone/main.py -> build/bdist.macosx-10.6-intel/egg/gammatone copying build/lib/gammatone/fftweight.py -> build/bdist.macosx-10.6-intel/egg/gammatone copying build/lib/gammatone/filters.py -> build/bdist.macosx-10.6-intel/egg/gammatone copying build/lib/gammatone/gtgram.py -> build/bdist.macosx-10.6-intel/egg/gammatone copying build/lib/gammatone/plot.py -> build/bdist.macosx-10.6-intel/egg/gammatone creating build/bdist.macosx-10.6-intel/egg/tests copying build/lib/tests/init.py -> build/bdist.macosx-10.6-intel/egg/tests copying build/lib/tests/test_cfs.py -> build/bdist.macosx-10.6-intel/egg/tests copying build/lib/tests/test_erb_space.py -> build/bdist.macosx-10.6-intel/egg/tests copying build/lib/tests/test_fft_gtgram.py -> build/bdist.macosx-10.6-intel/egg/tests copying build/lib/tests/test_fft_weights.py -> build/bdist.macosx-10.6-intel/egg/tests copying build/lib/tests/test_filterbank.py -> build/bdist.macosx-10.6-intel/egg/tests copying build/lib/tests/test_gammatone_filters.py -> build/bdist.macosx-10.6-intel/egg/tests copying build/lib/tests/test_gammatonegram.py -> build/bdist.macosx-10.6-intel/egg/tests copying build/lib/tests/test_specgram.py -> build/bdist.macosx-10.6-intel/egg/tests byte-compiling build/bdist.macosx-10.6-intel/egg/gammatone/init.py to init.cpython-34.pyc byte-compiling build/bdist.macosx-10.6-intel/egg/gammatone/main.py to main.cpython-34.pyc byte-compiling build/bdist.macosx-10.6-intel/egg/gammatone/fftweight.py to fftweight.cpython-34.pyc byte-compiling build/bdist.macosx-10.6-intel/egg/gammatone/filters.py to filters.cpython-34.pyc byte-compiling build/bdist.macosx-10.6-intel/egg/gammatone/gtgram.py to gtgram.cpython-34.pyc byte-compiling build/bdist.macosx-10.6-intel/egg/gammatone/plot.py to plot.cpython-34.pyc byte-compiling build/bdist.macosx-10.6-intel/egg/tests/init.py to init.cpython-34.pyc byte-compiling build/bdist.macosx-10.6-intel/egg/tests/test_cfs.py to test_cfs.cpython-34.pyc byte-compiling build/bdist.macosx-10.6-intel/egg/tests/test_erb_space.py to test_erb_space.cpython-34.pyc byte-compiling build/bdist.macosx-10.6-intel/egg/tests/test_fft_gtgram.py to test_fft_gtgram.cpython-34.pyc byte-compiling build/bdist.macosx-10.6-intel/egg/tests/test_fft_weights.py to test_fft_weights.cpython-34.pyc byte-compiling build/bdist.macosx-10.6-intel/egg/tests/test_filterbank.py to test_filterbank.cpython-34.pyc byte-compiling build/bdist.macosx-10.6-intel/egg/tests/test_gammatone_filters.py to test_gammatone_filters.cpython-34.pyc byte-compiling build/bdist.macosx-10.6-intel/egg/tests/test_gammatonegram.py to test_gammatonegram.cpython-34.pyc byte-compiling build/bdist.macosx-10.6-intel/egg/tests/test_specgram.py to test_specgram.cpython-34.pyc creating build/bdist.macosx-10.6-intel/egg/EGG-INFO copying Gammatone.egg-info/PKG-INFO -> build/bdist.macosx-10.6-intel/egg/EGG-INFO copying Gammatone.egg-info/SOURCES.txt -> build/bdist.macosx-10.6-intel/egg/EGG-INFO copying Gammatone.egg-info/dependency_links.txt -> build/bdist.macosx-10.6-intel/egg/EGG-INFO copying Gammatone.egg-info/entry_points.txt -> build/bdist.macosx-10.6-intel/egg/EGG-INFO copying Gammatone.egg-info/requires.txt -> build/bdist.macosx-10.6-intel/egg/EGG-INFO copying Gammatone.egg-info/top_level.txt -> build/bdist.macosx-10.6-intel/egg/EGG-INFO zip_safe flag not set; analyzing archive contents... creating 'dist/Gammatone-1.0-py3.4.egg' and adding 'build/bdist.macosx-10.6-intel/egg' to it removing 'build/bdist.macosx-10.6-intel/egg' (and everything under it) Processing Gammatone-1.0-py3.4.egg Copying Gammatone-1.0-py3.4.egg to /Library/Frameworks/Python.framework/Versions/3.4/lib/python3.4/site-packages Adding Gammatone 1.0 to easy-install.pth file Installing gammatone script to /Library/Frameworks/Python.framework/Versions/3.4/bin
Installed /Library/Frameworks/Python.framework/Versions/3.4/lib/python3.4/site-packages/Gammatone-1.0-py3.4.egg Processing dependencies for Gammatone==1.0 Searching for scikits.audiolab>=0.11.0.p3.1 Best match: scikits.audiolab 0.11.0.p3.1 Downloading https://github.com/detly/audiolab/archive/0.11.0.p3.1.zip#egg=scikits.audiolab-0.11.0.p3.1 Processing 0.11.0.p3.1.zip Writing /tmp/easy_install-1g_vbqt3/audiolab-0.11.0.p3.1/setup.cfg Running audiolab-0.11.0.p3.1/setup.py -q bdist_egg --dist-dir /tmp/easy_install-1g_vbqt3/audiolab-0.11.0.p3.1/egg-dist-tmp-ub0c5ts1 Warning: distutils distribution has been initialized, it may be too late to add an extension _sndfileWarning: distutils distribution has been initialized, it may be too late to add a subpackage pysndfile/private/tmp/easy_install-1g_vbqt3/audiolab-0.11.0.p3.1/audiolab/soundio/setup.py:21: UserWarning: Alsa not found - alsa backend not build warnings.warn("Alsa not found - alsa backend not build") warning: no files found matching 'scikits/audiolab/test_data/original.aif' warning: no files found matching 'scikits/audiolab/test_data/test.aiff' warning: no files found matching 'scikits/audiolab/test_data/test.au' warning: no files found matching 'scikits/audiolab/test_data/test.flac' warning: no files found matching 'scikits/audiolab/test_data/test.raw' warning: no files found matching 'scikits/audiolab/test_data/test.sdif' warning: no files found matching 'scikits/audiolab/testdata/test.wav' warning: no files found matching '' under directory 'docs/pdf' warning: no files found matching '_' under directory 'docs/html' warning: manifest_maker: MANIFEST.in, line 19: 'recursive-include' expects
warning: manifest_maker: MANIFEST.in, line 20: 'recursive-include' expects
warning: no files found matching 'scikits/audiolab/pysndfile/_sndfile.pyx' warning: no files found matching 'scikits/audiolab/soundio/macosx/macosx_backend.pyx' warning: no files found matching 'scikits/audiolab/soundio/alsa/_alsa_backend.pyx' warning: no files found matching 'scikits/audiolab/pysndfile/_sndfile.c' warning: no files found matching 'scikits/audiolab/soundio/macosx/macosx_backend.c' warning: no files found matching 'scikits/audiolab/soundio/alsa/_alsa_backend.c' In file included from /private/tmp/easy_install-1g_vbqt3/audiolab-0.11.0.p3.1/audiolab/pysndfile/_sndfile.c:275: In file included from /Library/Frameworks/Python.framework/Versions/3.4/lib/python3.4/site-packages/numpy/core/include/numpy/arrayobject.h:4: In file included from /Library/Frameworks/Python.framework/Versions/3.4/lib/python3.4/site-packages/numpy/core/include/numpy/ndarrayobject.h:17: In file included from /Library/Frameworks/Python.framework/Versions/3.4/lib/python3.4/site-packages/numpy/core/include/numpy/ndarraytypes.h:1761: /Library/Frameworks/Python.framework/Versions/3.4/lib/python3.4/site-packages/numpy/core/include/numpy/npy_1_7_deprecated_api.h:15:2: warning: "Using deprecated NumPy API, disable it by " "#defining NPY_NO_DEPRECATED_API NPY_1_7_API_VERSION" [-W#warnings]
warning "Using deprecated NumPy API, disable it by " \
^ /private/tmp/easy_install-1g_vbqt3/audiolab-0.11.0.p3.1/audiolab/pysndfile/_sndfile.c:957:59: error: a parameter list without types is only allowed in a function definition static CYTHON_INLINE PyObject _Pyx_PyInt_to_py___quad_t(quad_t); ^ /private/tmp/easy_install-1g_vbqt3/audiolab-0.11.0.p3.1/audiolab/pysndfile/_sndfile.c:959:22: error: unknown type name 'quad_t'; did you mean 'u_quad_t'? static CYTHON_INLINE quad_t Pyx_PyInt_frompyquad_t(PyObject ); ^
~~~ u_quad_t /usr/include/sys/types.h:95:20: note: 'u_quad_t' declared here typedef u_int64_t u_quadt; / quads _/ ^ /private/tmp/easy_install-1g_vbqt3/audiolab-0.11.0.p3.1/audiolab/pysndfile/_sndfile.c:1640:14: warning: explicitly assigning a variable of type 'PyObject ' (aka 'struct _object *') to itself [-Wself-assign] __pyx_self = __pyx_self;