View source: R/pitchTrackers.R
getPitchHps | R Documentation |
Internal soundgen function.
getPitchHps(
frame,
freqs,
bin,
hpsThres,
hpsNum,
hpsNorm,
hpsPenalty,
pitchFloor,
pitchCeiling
)
frame |
the abs spectrum of a frame, as returned by
|
freqs |
frequency per bin of spectrogram |
bin |
spectrogram bin width, Hz |
hpsThres |
voicing threshold (unitless, ~0 to 1) |
hpsNum |
the number of times the spectrum is downsampled |
hpsNorm |
the amount of inflation of hps pitch certainty (0 = none) |
hpsPenalty |
the amount of penalizing hps candidates in low frequencies (0 = none) |
pitchFloor , pitchCeiling |
absolute bounds for pitch candidates (Hz) |
Estimates pitch per frame using the harmonic product spectrum. Algorithm: downsample the spectrum repeatedly padding with 0 to the original length, then multiply the resulting scaled spectra. This has the effect of emphasizing f0, which should hopefully become the highest spectral peak. See https://cnx.org/contents/i5AAkZCP@2/Pitch-Detection-Algorithms
Returns either NULL or a dataframe of pitch candidates.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.