mcallistertyler / audio-fingerprinting-similarity

Compares two audio files fingerprints
4 stars 0 forks source link

module 'chromaprint' has no attribute 'FingerprintError' #1

Open WestbrookZero opened 4 years ago

WestbrookZero commented 4 years ago

My environment is python==3.7 pyacoustid==1.1.7 、fuzzywuzzy==0.18.0 、 chromaprint==0.5 Calculating fingerprint of source file calculate fingerprints of audio file Traceback (most recent call last): File "D:\InstallPath\Develop\Anaconda3\5.3.1\envs\ComplexYOLO\lib\site-packages\acoustid.py", line 204, in fingerprint fper = chromaprint.Fingerprinter() AttributeError: module 'chromaprint' has no attribute 'Fingerprinter'

During handling of the above exception, another exception occurred:

Traceback (most recent call last): File "D:/Projects/SpeechCompare/audio-fingerprinting-similarity-master/compare_fingerprints.py", line 31, in source_fingerprint = calculate_fingerprints(source_file) File "D:/Projects/SpeechCompare/audio-fingerprinting-similarity-master/compare_fingerprints.py", line 8, in calculate_fingerprints duration, fp_encoded = acoustid.fingerprint_file(filename) File "D:\InstallPath\Develop\Anaconda3\5.3.1\envs\ComplexYOLO\lib\site-packages\acoustid.py", line 324, in fingerprint_file return _fingerprint_file_audioread(path, maxlength) File "D:\InstallPath\Develop\Anaconda3\5.3.1\envs\ComplexYOLO\lib\site-packages\acoustid.py", line 267, in _fingerprint_file_audioread fp = fingerprint(f.samplerate, f.channels, iter(f), maxlength) File "D:\InstallPath\Develop\Anaconda3\5.3.1\envs\ComplexYOLO\lib\site-packages\acoustid.py", line 215, in fingerprint except chromaprint.FingerprintError: AttributeError: module 'chromaprint' has no attribute 'FingerprintError'

naikshubham commented 4 years ago

My environment is python==3.7 pyacoustid==1.1.7 、fuzzywuzzy==0.18.0 、 chromaprint==0.5 Calculating fingerprint of source file calculate fingerprints of audio file Traceback (most recent call last): File "D:\InstallPath\Develop\Anaconda3\5.3.1\envs\ComplexYOLO\lib\site-packages\acoustid.py", line 204, in fingerprint fper = chromaprint.Fingerprinter() AttributeError: module 'chromaprint' has no attribute 'Fingerprinter'

During handling of the above exception, another exception occurred:

Traceback (most recent call last): File "D:/Projects/SpeechCompare/audio-fingerprinting-similarity-master/compare_fingerprints.py", line 31, in source_fingerprint = calculate_fingerprints(source_file) File "D:/Projects/SpeechCompare/audio-fingerprinting-similarity-master/compare_fingerprints.py", line 8, in calculate_fingerprints duration, fp_encoded = acoustid.fingerprint_file(filename) File "D:\InstallPath\Develop\Anaconda3\5.3.1\envs\ComplexYOLO\lib\site-packages\acoustid.py", line 324, in fingerprint_file return _fingerprint_file_audioread(path, maxlength) File "D:\InstallPath\Develop\Anaconda3\5.3.1\envs\ComplexYOLO\lib\site-packages\acoustid.py", line 267, in _fingerprint_file_audioread fp = fingerprint(f.samplerate, f.channels, iter(f), maxlength) File "D:\InstallPath\Develop\Anaconda3\5.3.1\envs\ComplexYOLO\lib\site-packages\acoustid.py", line 215, in fingerprint except chromaprint.FingerprintError: AttributeError: module 'chromaprint' has no attribute 'FingerprintError'

Even I am getting same error

AlexLopezPedrosa commented 4 years ago

Probably late to answer that, but I had the same issue and I solved it. The problem for me was that I had the chromaprint library in my lib/python3.x/site-packages folder.

To check that you just have to enter the command pip list | grep chromaprint (OSx case), and it'll pop up whether you have this library in the folder or not.

To get rid of it you just have to enter the command pip uninstall chromaprint and it'll take it away.

npit commented 2 years ago

@AlexLopezPedrosa fix works, thanks.

albertopasqualetto commented 1 year ago

The reason is that chromaprint needs to be removed from requirements.txt