I am new in DSP, trying to calculate fundamental frequency ( f(0) ) for each segmented frame of the audio file. The methods of F0 estimation can be divided into three categories:

  • based on temporal dynamics of the signal time-domain;
  • based on the frequency structure frequency-domain, and
  • hybrid methods.

Most of the examples are estimating fundamental frequency based on the frequency structure frequency-domain, I am looking for based on temporal dynamics of the signal time-domain.

This article provides some information but I am still not clear how to calculate it in the time domain?


This is the code, I have found, used so far :

def freq_from_autocorr(sig, fs):
    Estimate frequency using autocorrelation
    # Calculate autocorrelation and throw away the negative lags
    corr = correlate(sig, sig, mode='full')
    corr = corr[len(corr)//2:]

    # Find the first low point
    d = diff(corr)
    start = nonzero(d > 0)[0][0]

    # Find the next peak after the low point (other than 0 lag).  This bit is
    # not reliable for long signals, due to the desired peak occurring between
    # samples, and other peaks appearing higher.
    # Should use a weighting function to de-emphasize the peaks at longer lags.
    peak = argmax(corr[start:]) + start
    px, py = parabolic(corr, peak)

    return fs / px

How to estimate in time domain?

Thanks in advance!

  • 1
    $\begingroup$ What is the reason you don't want to use the FFT? $\endgroup$ May 1, 2020 at 0:00

1 Answer 1


This paper by Philip McLeod details finding pitch in the time domain, and specifically that it avoids the reduced resolution of equivalent frequency domain approaches due to the windowing required to eliminate spectral leakage.


I don't have experience with this approach but would be very interested in comparative results to the best frequency domain approach- if you could post them, assuming you pursue this further.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.