python - Autocorrelation and Fundamental Frequency -


i trying figure out fundamental frequency of sound

i try detect fundamental frequency autocorrelation.

i found code:

corr = np.correlate(signal, signal, mode='full') maxcorr = np.argmax(corr) corr = corr / corr[maxcorr] corr = corr[corr.size / 2:] 

i got graph code above: enter image description here

index of maximum value 3145. , sample rate 44100.

so... got fundamental frequency 44100/3145 = 14.02.

this way wrong since sound piano c4 should around 261hz.

how can fundamental frequency autocorrelation?

added:

this graph of c4 of piano enter image description here


Comments

Popular posts from this blog

Ansible - ERROR! the field 'hosts' is required but was not set -

customize file_field button ruby on rails -

SoapUI on windows 10 - high DPI/4K scaling issue -