How can i find the centroid of the wavelet coefficients from each frame of the audio signal?

1 次查看(过去 30 天)
Hi,i have to find the centroid of the wavelet coefficients for each frame of the audio signal.,i've applied wavedec to decompose the audio into 5 levels CA5,CD1,CD2,CD3,CD4,CD5 from that i have to find the energy and centroid of the wavelet coefficients.Is there anybody know about this?
  4 个评论
maxina dialin
maxina dialin 2012-10-9
that is not a image.,actually it is a audio signal.,sry i mentioned that is a image. i applied wavedec for an audio signal.,after that i have to calculate energy and centroid of the wavelet coefficients(approximation and detail)for all frames of the audio signal.,i dnt know how to do.,can u pls help me?

请先登录,再进行评论。

回答(1 个)

Wayne King
Wayne King 2012-10-8
编辑:Wayne King 2012-10-8
You can use wenergy() to find the energy in the output of wavedec()
load noisdopp;
[C,L] = wavedec(noisdopp,5,'sym4');
[Ea,Ed] = wenergy(C,L);
What do you mean by centroid? The mean? You can do that with detcoef() although the mean of the detail coefficients will be close to zero at each level I would suspect.
details = detcoef(C,L,'cells');
centroids = cellfun(@mean,details);
  1 个评论
maxina dialin
maxina dialin 2012-10-9
no.,actually i have to find one centroid value for all coefficients., if i use the function what you suggested above means i get 5 values.(since decomposition level is 5) but i want a single centroid value for coefficients including app. and detail coefficients.(ca5,cd1...cd5) how can i do that? the formula which i have to use is sum(i*(x(i)^2))/sum(x(i))^2 where x(i) is the ith wavelet coefficient.i=1,2..6(since we have 6 coefficients ca5,cd1...cd5) do u have any idea about this?

请先登录,再进行评论。

类别

Help CenterFile Exchange 中查找有关 Signal Analysis 的更多信息

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by