Closed wyp19930313 closed 4 years ago
pitch is defined as 1) sample_rate / f0 (for voiced regions), and 2) 0 (for unvoiced regions).
See https://github.com/r9y9/SPTK/blob/master/bin/pitch/swipe/swipe.c#L562-L564 for exact code for the conversion.
I understand, thank you very much for your answer.
Hello, I want to know what is the conversion relationship between f0 and pitch? I run the same data to get f0 and pitch, which are different from the conversion relationship I know.
f0 = pysptk.swipe(data.astype(np.float64), fs=16000, hopsize=80, min=60, max=200, otype="f0") pitch = pysptk.swipe(data.astype(np.float64), fs=16000, hopsize=80, min=60, max=200, otype="pitch") f0[:6]
Out[4]: array([ 60. , 60. , 60. , 196.24851072, 194.48506966, 0. ])
pitch[:6] Out[5]: array([266.66666667, 266.66666667, 266.66666667, 81.52928112, 82.26852595, 0. ])