DSPRelated.com
Forums

Frequency detection on device with that has high pass filter

Started by thun...@hotmail.com April 2, 2012
I'm trying to do frequency detection on a class of devices whose PCM encoder applies a high pass filter. My frequency detection algorithm works well unless I try and do frequency detection for the lower notes that are dampened by the HPF.

Determining the frequency with the highest peak should work fine for the types of sounds I use (the fundamental frequency is always the loudest in my environment). However, in the case where the fundamental frequency lies within the dampened region of the HPF, its amplitude shows up on the spectrum as being much lower than its harmonic frequencies.

So I tried applying harmonic product spectrum analysis. While there was some improvement over highest-peak detection, the harmonic frequencies are still being detected for most sounds with a fundamental frequency in the dampened region. With HPS, it seems to just detect the first major harmonic outside of the dampened region.

I've eliminated the possibility that the error in detection is due to aliasing.

The HPF seems to lower the amplitudes on a sliding scale by up to 50dB (the lower the note, the greater the reduction). I've attempted to reverse the HPF by applying a low pass filter appropriately, but it's too difficult to determine the amount of amplitude reduction occurring. The HPF used on each device is slightly different, meaning I need to make a unique LPF for each device, which is just not feasible.

I would have given up trying to detect the frequency of the lower notes on these devices, however I see other applications are able to detect lower frequencies flawlessly. My question is, what frequency detection algorithm could these other applications using? Any advice?

Thank you,
Scott
Scott-

The normal procedure would be frequency compensation; i.e. measure the transfer function of the device and apply an
inverse filter prior to specific processing. For the detection you describe, this should work assuming you can
tolerate the reduced SNR in the area of the HPF.

But you say that your device has a non-deterministic HPF that varies per device. This would have to be substantial
variation for you to be unable to compensate with a fixed inverse filter. What kind of device have you got there?

-Jeff

> I'm trying to do frequency detection on a class of devices whose PCM encoder applies a high pass filter. My frequency
> detection algorithm works well unless I try and do frequency detection for the lower notes that are dampened by the
> HPF.
>
> Determining the frequency with the highest peak should work fine for the types of sounds I use (the fundamental
> frequency is always the loudest in my environment). However, in the case where the fundamental frequency lies within
> the dampened region of the HPF, its amplitude shows up on the spectrum as being much lower than its harmonic
> frequencies.
>
> So I tried applying harmonic product spectrum analysis. While there was some improvement over highest-peak detection,
> the harmonic frequencies are still being detected for most sounds with a fundamental frequency in the dampened region.
> With HPS, it seems to just detect the first major harmonic outside of the dampened region.
>
> I've eliminated the possibility that the error in detection is due to aliasing.
>
> The HPF seems to lower the amplitudes on a sliding scale by up to 50dB (the lower the note, the greater the
> reduction). I've attempted to reverse the HPF by applying a low pass filter appropriately, but it's too difficult to
> determine the amount of amplitude reduction occurring. The HPF used on each device is slightly different, meaning I
> need to make a unique LPF for each device, which is just not feasible.
>
> I would have given up trying to detect the frequency of the lower notes on these devices, however I see other
> applications are able to detect lower frequencies flawlessly. My question is, what frequency detection algorithm could
> these other applications using? Any advice?
>
> Thank you,
> Scott
I'm trying to do frequency detection on a class of devices whose PCM encoder applies a high pass filter. My frequency detection algorithm works well unless I try and do frequency detection for the lower notes that are dampened by the HPF.
>
>Determining the frequency with the highest peak should work fine for the types of sounds I use (the fundamental frequency is always the loudest in my environment). However, in the case where the fundamental frequency lies within the dampened region of the HPF, its amplitude shows up on the spectrum as being much lower than its harmonic frequencies.
>
>So I tried applying harmonic product spectrum analysis. While there was some improvement over highest-peak detection, the harmonic frequencies are still being detected for most sounds with a fundamental frequency in the dampened region. With HPS, it seems to just detect the first major harmonic outside of the dampened region.
>
>I've eliminated the possibility that the error in detection is due to aliasing.
>
>The HPF seems to lower the amplitudes on a sliding scale by up to 50dB (the lower the note, the greater the reduction). I've attempted to reverse the HPF by applying a low pass filter appropriately, but it's too difficult to determine the amount of amplitude reduction occurring. The HPF used on each device is slightly different, meaning I need to make a unique LPF for each device, which is just not feasible.
>
>I would have given up trying to detect the frequency of the lower notes on these devices, however I see other applications are able to detect lower frequencies flawlessly. My question is, what frequency detection algorithm could these other applications using? Any advice?
>
>Thank you,
>Scott

Hi Scott,

Why not using any of the other techniques for pitch detection, such as autocorrelation or cepstral analysis?

Other idea, you can apply linear prediction analysis frame by frame in order to get a whitened version of the signal. So, then you can use HPS or a comb filter.
- Felipe