matlabsignal-processingspeech-recognitionpitchpitch-tracking

find Pitch-synchronous windowing based on pitch tracking


As seen in comment link a pitch by Talkin’s Robust Algorithm for Pitch Tracking in voicebox (function name is "fxrapt") is extracted.

http://www.ee.ic.ac.uk/hp/staff/dmb/voicebox/doc/voicebox/fxrapt.html

However, I need to find pitch pulses in the LP error signal by detecting the maximum amplitude within each pitch period. For each pitch pulse, a Hamming window of two pitch periods long. if T(i-1), T(i), T(i+1) denote the locations of three successive pitch pulses. How can I design a analysis window for the pitch pulse at spans from T(i-1) to T(i+1), as illustrated in bellow link Figure ?

enter image description here

I am looking for MATLAB code for it. I will really appreciate, if anyone can help me. Thanks.


Solution

  • Steps:

    these two steps can be done like this:

    while ( (k+Step-1) <= Nsamples )
    
        frame = x(k:k+steps-1);
    
        P=PITCHTRACK_FUNCTION_HERE
    
        [v, l] = max(abs(frame(1:P*2)));
    
       if count == 1
    
          marks(count) = l;
    
       else
    
         marks(count) = l+k-1;
    
      count = count +1;
    
      k=k+Step;
    
    end
    

    PS:

    x = your signal

    Nsamples = length(x)

    k = begins with 1

    Step = 256 or 512 or 1024 or 2048