pub fn estimate_key(
hpcp: &[f32],
assumes_12tet: bool,
min_correlation: f32,
) -> Result<Option<KeyEstimate>, AudioError>Expand description
Estimate the musical key of a 12-bin HPCP frame/profile.
hpcp: pitch-class profile; must be at least 12 bins (bin 0 = C).assumes_12tet: caller-declared assumption. Iffalse, abstains.min_correlation: acceptance threshold; below it the result isOk(None)(abstain). A value around0.6–0.7is typical for confident keys.
Returns Ok(Some(KeyEstimate)) when a key is proposed, Ok(None) when the
function abstains.
§Errors
AudioError::InvalidParameterifhpcpis empty.