I can and have fingerprinted songs into an SQL database using the dejavu code. When I run the --recognize file with a file of an already fingerprinted song, it recognizes it.
But, when i call python dejavu.py --recognize mic for an arbitrary number of seconds, and I play the song, nothing happens.
Nothing is printed on the screen and it doesn't even end. It just keeps going.
This is the traceback when I ctrl-C it.
Traceback (most recent call last):
File "dejavu.py", line 88, in
song = djv.recognize(MicrophoneRecognizer, seconds=opt_arg)
File "/Users/badrigomatam/Desktop/Aditya/python/dejavu-master/dejavu/init.py", line 180, in recognize
return r.recognize(*options, **kwoptions)
File "/Users/badrigomatam/Desktop/Aditya/python/dejavu-master/dejavu/recognize.py", line 106, in recognize
self.process_recording()
File "/Users/badrigomatam/Desktop/Aditya/python/dejavu-master/dejavu/recognize.py", line 83, in process_recording
data = self.stream.read(self.chunksize)
File "/anaconda3/lib/python3.7/site-packages/PyAudio-0.2.11-py3.7-macosx-10.7-x86_64.egg/pyaudio.py", line 608, in read
return pa.read_stream(self._stream, num_frames, exception_on_overflow)
I think there's something wrong with this stream.read() function, but I don't know what to do.
I can and have fingerprinted songs into an SQL database using the dejavu code. When I run the --recognize file with a file of an already fingerprinted song, it recognizes it.
But, when i call python dejavu.py --recognize mic for an arbitrary number of seconds, and I play the song, nothing happens.
Nothing is printed on the screen and it doesn't even end. It just keeps going.
This is the traceback when I ctrl-C it.
Traceback (most recent call last): File "dejavu.py", line 88, in
song = djv.recognize(MicrophoneRecognizer, seconds=opt_arg)
File "/Users/badrigomatam/Desktop/Aditya/python/dejavu-master/dejavu/init.py", line 180, in recognize
return r.recognize(*options, **kwoptions)
File "/Users/badrigomatam/Desktop/Aditya/python/dejavu-master/dejavu/recognize.py", line 106, in recognize
self.process_recording()
File "/Users/badrigomatam/Desktop/Aditya/python/dejavu-master/dejavu/recognize.py", line 83, in process_recording
data = self.stream.read(self.chunksize)
File "/anaconda3/lib/python3.7/site-packages/PyAudio-0.2.11-py3.7-macosx-10.7-x86_64.egg/pyaudio.py", line 608, in read
return pa.read_stream(self._stream, num_frames, exception_on_overflow)
I think there's something wrong with this stream.read() function, but I don't know what to do.
Can someone help, please?