No BSD License
-
HardTh(y,thld)
-
SoftTh(y,thld)
-
Wavelet_Denoise(varargin)
WAVELET_DENOISE Application M-file for Wavelet_Denoise.fig
-
daubcqf(N,TYPE)
-
denoise(x,h,type,option)
-
makesig(SigName,N)
[x,N] = makesig(SigName,N) Creates artificial test signal identical to the
-
mdwt(x,h,L);
-
midwt(x,h,L);
-
mirdwt(yl,yh,h,L);
-
mrdwt(x,h,L);
-
normalize(t1);
This function removes the DC component and normalizes wrt the max abs value
-
setopt(opt_par,default);
option = setopt(opt_par,default);
-
two_axes(varargin)
TWO_AXES Application M-file for two_axes.fig
-
Contents.m
-
compile.m
-
ex.m
-
ex1.m
-
find_syll.m
-
View all files
from
Wavelets Based Denoising
by Sheraz Khan
This program shows wavelets based denoising of audio file and arbitrary signals.
|
| find_syll.m |
%function h = find_syll(q)
wavread open4;
first_signal = ans;
vector1_length = length(first_signal);
f=0;
i=0;
s= 0;
count1 = 1;
start=0;
finish=0;
while s < 1
if max(abs(first_signal(count1:count1+1000))) > .99
i=i+1;
start(i) = count1;
f=0;
while f < 1
if max(abs(first_signal(count1:count1+1000))) < .99
finish(i) = count1;
f = 1;
else
count1 = count1 + 1000;
if count1+1000 > vector1_length
f = 1;
end
end
end
end
count1 = count1 + 1000;
if count1+1000 > vector1_length
s = 1;
end
end
count_syllable = length(start);
first_syll = first_signal(start(1):finish(1));
second_syll = first_signal(start(2):finish(2));
subplot(4,1,1)
plot(first_signal)
t1=[0:1/(length(first_syll)-1):1];
subplot(4,1,2);
plot(t1,first_syll)
t2=[0:1/(length(second_syll)-1):1];
subplot(4,1,3);
plot(t2,second_syll)
length_f = length(first_syll);
length_s = length(second_syll);
fft_first = abs(fft(first_syll));
half_f = round(length_f/2);
main_f = fft_first(half_f:length_f);
fft_second = abs(fft(second_syll));
half_s = round(length_s/2);
main_s = fft_second(half_s:length_s);
t1=[0:1/(length(main_f)-1):1];
subplot(3,1,1)
plot(t1,main_f)
t2=[0:1/(length(main_s)-1):1];
subplot(3,1,2)
plot(t2,main_s)
power_f = sum(main_f)/length(main_f);
power_s = sum(main_s)/length(main_s);
|
|
Contact us at files@mathworks.com