bjbschmitt / AMFM_decompy

Package containing the tools necessary for decomposing a speech signal into its modulated components (also known as AM-FM decomposition). Includes the algorithms of the QHM family and the YAAPT pitch tracker.
MIT License
85 stars 18 forks source link

TypeError: pcm2float() got an unexpected keyword argument 'dtype' #8

Closed richardhemphill closed 4 years ago

richardhemphill commented 4 years ago

The parameter name of 'dtype' in the call to pcm2float() does not match the actual parameter name of 'output_dtype'.

https://github.com/bjbschmitt/AMFM_decompy/blob/9921baa2d6208de7a61b0fabb2da2e9fe8ed7bc7/amfm_decompy/basic_tools.py#L39

bjbschmitt commented 4 years ago

Hi Richard, thank you for your feedback. Could you please send me the wav that caused the issue, so that I can reproduce it here and implement the proper fix?

richardhemphill commented 4 years ago

(http://www.ws.binghamton.edu/zahorian/yaapt/yaapt.zip)

Within zip, YAPPT_v4.0\sample\f1nw0000pes_short.wav

import amfm_decompy.basic_tools as basic signal = basic.SignalObj('f1nw0000pes_short.wav')

bjbschmitt commented 4 years ago

Ok, I have tested

import amfm_decompy.basic_tools as basic signal = basic.SignalObj('f1nw0000pes_short.wav')

and everything went fine. Could you please send a print screen from your error message? Maybe it can help me to find out why it is not working in your computer.

richardhemphill commented 4 years ago

See attached. pcm2float.pptx

bjbschmitt commented 4 years ago

Ok, I understand now your point, the name of the variable is wrong. I will fix it then and also make some improvements.

The only thing strange is the fact that this bug remained unnoticed for so much time. As I mentioned, my computer ignores it and probably employs the default value for output_dtype. Maybe it is something related with the installed Python/Conda version, or something like that.

bjbschmitt commented 4 years ago

Hi Richard, sorry about the delay. I have fixed the bug and uploaded the new AMFM_decompy 1.0.9 version to both PyPi and github repositories. The documentation has also been updated as well.

Please upgrade your AMFM_decompy version through pip and check if the problem has in fact been solved.

richardhemphill commented 4 years ago

Latest version works. Thanks.