DSPRelated.com
Forums

Comparing the spectra of two acoustic signals

Started by turc...@gmail.com March 1, 2012
Hello everybody,
I want to compare the spectra of two acoustical signals (very short signals, with duration less than 300 milliseconds), but I don´t know which way is the best.

I would like to have a measure indicating where in the spectrum of a signal there is more energy.
Should I use the power spectral density?

I just want to know a general measure for the spectrum, a number summarizing the spectral content of a signal in order to compare it with an other signal.

Could you please suggest me which method I have to use?
Are there some functions in MATLAB in order to perform easily this coputation?

Help!
I don't have too much experience in signal analysis...sorry maybe you might find this question trivial!

Thanks in advance!

Cheers
Hi Luca,
I'm afraid your question is unclear. Compare the spectra how? To see how
similar/dis-similar they are? What type of acoustic signal are we talking
about? Speech? Music? There are many different spectral distance
measurements to choose from, perhaps if you provide more information about
your problem we can provide a little more guidance. For now I might suggest
cepstral distance as a starting point or normalized cross correlation.
Good luck,
-Brant

On Wed, Feb 22, 2012 at 5:30 PM, wrote:

> Hello everybody,
> I want to compare the spectra of two acoustical signals (very short
> signals, with duration less than 300 milliseconds), but I dont know which
> way is the best.
>
> I would like to have a measure indicating where in the spectrum of a
> signal there is more energy.
> Should I use the power spectral density?
>
> I just want to know a general measure for the spectrum, a number
> summarizing the spectral content of a signal in order to compare it with an
> other signal.
>
> Could you please suggest me which method I have to use?
> Are there some functions in MATLAB in order to perform easily this
> coputation?
>
> Help!
> I don't have too much experience in signal analysis...sorry maybe you
> might find this question trivial!
>
> Thanks in advance!
>
> Cheers
>
>
>
> _____________________________________
>
--
Brant Jameson
PhD Candidate
UC Santa Cruz Computer Engineering
http://people.ucsc.edu/~pheese
Yes,
sorry you are right. Actually I would like to compare the spectrum of
two footsteps sounds (very short duration then).

I don't want to arrive to an analysis on the main modes ecc. I just
want a measure expressing globally the differences...
Actually I think it could be useful to check the coherence between the
two power spectral densities.
If you also have some useful rutines in matlab please let me know.

Best

Luca
On Thu, Mar 1, 2012 at 7:32 PM, Brant Jameson wrote:

> Hi Luca,
> I'm afraid your question is unclear. Compare the spectra how? To see how
> similar/dis-similar they are? What type of acoustic signal are we talking
> about? Speech? Music? There are many different spectral distance
> measurements to choose from, perhaps if you provide more information about
> your problem we can provide a little more guidance. For now I might suggest
> cepstral distance as a starting point or normalized cross correlation.
> Good luck,
> -Brant
> On Wed, Feb 22, 2012 at 5:30 PM, wrote:
>
>> Hello everybody,
>> I want to compare the spectra of two acoustical signals (very short
>> signals, with duration less than 300 milliseconds), but I dont know which
>> way is the best.
>>
>> I would like to have a measure indicating where in the spectrum of a
>> signal there is more energy.
>> Should I use the power spectral density?
>>
>> I just want to know a general measure for the spectrum, a number
>> summarizing the spectral content of a signal in order to compare it with an
>> other signal.
>>
>> Could you please suggest me which method I have to use?
>> Are there some functions in MATLAB in order to perform easily this
>> coputation?
>>
>> Help!
>> I don't have too much experience in signal analysis...sorry maybe you
>> might find this question trivial!
>>
>> Thanks in advance!
>>
>> Cheers
>>
>>
>>
>> _____________________________________
>>
> --
> Brant Jameson
> PhD Candidate
> UC Santa Cruz Computer Engineering
> http://people.ucsc.edu/~pheese
--
---------------------------

"Music is a moral law:
It gives a soul to the Universe,
wings to the mind,
flight to the imagination,
a charm to sadness,
and life to everything.
It is the essence of order,
and leads to all that is good,
just and beautiful,
of which it is the invisible,
but nevertheless dazzling,
passionate, and eternal form".

Plato, 400 B.C. (from the Dialogues)
On 03/01/2012 02:19 PM, Luca Turchet wrote:
> Yes,
> sorry you are right. Actually I would like to compare the spectrum of
> two footsteps sounds (very short duration then).
>
> I don't want to arrive to an analysis on the main modes ecc. I just
> want a measure expressing globally the differences...
> Actually I think it could be useful to check the coherence between the
> two power spectral densities.
> If you also have some useful rutines in matlab please let me know.
>
> Best
>
> Luca
> On Thu, Mar 1, 2012 at 7:32 PM, Brant Jameson > > wrote:
>
> Hi Luca,
> I'm afraid your question is unclear. Compare the spectra how? To
> see how similar/dis-similar they are? What type of acoustic
> signal are we talking about? Speech? Music? There are many
> different spectral distance measurements to choose from, perhaps
> if you provide more information about your problem we can provide
> a little more guidance. For now I might suggest cepstral distance
> as a starting point or normalized cross correlation.
> Good luck,
> -Brant
> On Wed, Feb 22, 2012 at 5:30 PM, > > wrote:
>
> Hello everybody,
> I want to compare the spectra of two acoustical signals (very
> short signals, with duration less than 300 milliseconds), but
> I dont know which way is the best.
>
> I would like to have a measure indicating where in the
> spectrum of a signal there is more energy.
> Should I use the power spectral density?
>
> I just want to know a general measure for the spectrum, a
> number summarizing the spectral content of a signal in order
> to compare it with an other signal.
>
> Could you please suggest me which method I have to use?
> Are there some functions in MATLAB in order to perform easily
> this coputation?
>
> Help!
> I don't have too much experience in signal analysis...sorry
> maybe you might find this question trivial!
>
> Thanks in advance!
>
> Cheers
>
>
>
>
> a...
> --
> Brant Jameson
> PhD Candidate
> UC Santa Cruz Computer Engineering
> http://people.ucsc.edu/~pheese
> --
> ---------------------------
>
> "Music is a moral law:
> It gives a soul to the Universe,
> wings to the mind,
> flight to the imagination,
> a charm to sadness,
> and life to everything.
> It is the essence of order,
> and leads to all that is good,
> just and beautiful,
> of which it is the invisible,
> but nevertheless dazzling,
> passionate, and eternal form".
>
> Plato, 400 B.C. (from the Dialogues)
>
Sounds like a decent starting point,
Coherence = normalized cross correlation. Cepstral distance and
Itakura-Saito distances may also prove helpful. I believe some of these
measurements can be found in the voicebox toolkit
(http://www.ee.ic.ac.uk/hp/staff/dmb/voicebox/voicebox.html).
Good Luck,
-Brant
Thanks a lot!

Cheers

Luca
On Thu, Mar 1, 2012 at 11:23 PM, Brant wrote:

> **
> On 03/01/2012 02:19 PM, Luca Turchet wrote:
>
> Yes,
> sorry you are right. Actually I would like to compare the spectrum of
> two footsteps sounds (very short duration then).
>
> I don't want to arrive to an analysis on the main modes ecc. I just
> want a measure expressing globally the differences...
> Actually I think it could be useful to check the coherence between the
> two power spectral densities.
> If you also have some useful rutines in matlab please let me know.
>
> Best
>
> Luca
> On Thu, Mar 1, 2012 at 7:32 PM, Brant Jameson wrote:
>
>> Hi Luca,
>> I'm afraid your question is unclear. Compare the spectra how? To see
>> how similar/dis-similar they are? What type of acoustic signal are we
>> talking about? Speech? Music? There are many different spectral distance
>> measurements to choose from, perhaps if you provide more information about
>> your problem we can provide a little more guidance. For now I might suggest
>> cepstral distance as a starting point or normalized cross correlation.
>> Good luck,
>> -Brant
>> On Wed, Feb 22, 2012 at 5:30 PM, wrote:
>>
>>> Hello everybody,
>>> I want to compare the spectra of two acoustical signals (very short
>>> signals, with duration less than 300 milliseconds), but I dont know which
>>> way is the best.
>>>
>>> I would like to have a measure indicating where in the spectrum of a
>>> signal there is more energy.
>>> Should I use the power spectral density?
>>>
>>> I just want to know a general measure for the spectrum, a number
>>> summarizing the spectral content of a signal in order to compare it with an
>>> other signal.
>>>
>>> Could you please suggest me which method I have to use?
>>> Are there some functions in MATLAB in order to perform easily this
>>> coputation?
>>>
>>> Help!
>>> I don't have too much experience in signal analysis...sorry maybe you
>>> might find this question trivial!
>>>
>>> Thanks in advance!
>>>
>>> Cheers
>>>
>>>
>>>
>>>
>>>
>>>
>>>
>>> _____________________________________
>>>
>>>
>>>
>>>
>>>
>> --
>> Brant Jameson
>> PhD Candidate
>> UC Santa Cruz Computer Engineering
>> http://people.ucsc.edu/~pheese
> --
> ---------------------------
>
> "Music is a moral law:
> It gives a soul to the Universe,
> wings to the mind,
> flight to the imagination,
> a charm to sadness,
> and life to everything.
> It is the essence of order,
> and leads to all that is good,
> just and beautiful,
> of which it is the invisible,
> but nevertheless dazzling,
> passionate, and eternal form".
>
> Plato, 400 B.C. (from the Dialogues)
>
> Sounds like a decent starting point,
> Coherence = normalized cross correlation. Cepstral distance and
> Itakura-Saito distances may also prove helpful. I believe some of these
> measurements can be found in the voicebox toolkit (
> http://www.ee.ic.ac.uk/hp/staff/dmb/voicebox/voicebox.html).
> Good Luck,
> -Brant
>

--
---------------------------

"Music is a moral law:
It gives a soul to the Universe,
wings to the mind,
flight to the imagination,
a charm to sadness,
and life to everything.
It is the essence of order,
and leads to all that is good,
just and beautiful,
of which it is the invisible,
but nevertheless dazzling,
passionate, and eternal form".

Plato, 400 B.C. (from the Dialogues)
You could use "Spectral Distortion". This is a measure of the difference between 2 spectrums.

- Felipe

Hello everybody,
>I want to compare the spectra of two acoustical signals (very short signals, with duration less than 300 milliseconds), but I don´t know which way is the best.
>
>I would like to have a measure indicating where in the spectrum of a signal there is more energy.
>Should I use the power spectral density?
>
>I just want to know a general measure for the spectrum, a number summarizing the spectral content of a signal in order to compare it with an other signal.
>
>Could you please suggest me which method I have to use?
>Are there some functions in MATLAB in order to perform easily this coputation?
>
>Help!
>I don't have too much experience in signal analysis...sorry maybe you might find this question trivial!
>
>Thanks in advance!
>
>Cheers