资源简介
完整的语音处理matlab程序。demo为利用ERB Gammatone 滤波器对语音信号进行处理。可以提取基于听觉感知的特征参数。
代码片段和文件信息
function output = ERBFilterBank(x fcoefs)
% function output = ERBFilterBank(x fcoefs)
% Process an input waveform with a gammatone filter bank. This function
% takes a single sound vector and returns an array of filter outputs one
% channel per row.
%
% The fcoefs parameter which completely specifies the Gammatone filterbank
% should be designed with the MakeERBFilters function. If it is omitted
% the filter coefficients are computed for you assuming a 22050Hz sampling
% rate and 64 filters regularly spaced on an ERB scale from fs/2 down to 100Hz.
%
% Malcolm Slaney @ Interval June 11 1998.
% (c) 1998 Interval Research Corporation
% Thanks to Alain de Cheveigne‘ for his suggestions and improvements.
if nargin < 1
error(‘Syntax: output_array = ERBFilterBank(input_vector[ fcoefs]);‘);
end
if nargin < 2
fcoefs = MakeERBFilters(2205064100);
end
if size(fcoefs2) ~= 10
error(‘fcoefs parameter passed to ERBFilterBank is the wrong size.‘);
end
if size(x2) < size(x1)
x = x‘;
end
A0 = fcoefs(:1);
A11 = fcoefs(:2);
A12 = fcoefs(:3);
A13 = fcoefs(:4);
A14 = fcoefs(:5);
A2 = fcoefs(:6);
B0 = fcoefs(:7);
B1 = fcoefs(:8);
B2 = fcoefs(:9);
gain= fcoefs(:10);
output = zeros(size(gain1) length(x));
for chan = 1: size(gain1)
y1=filter([A0(chan)/gain(chan) A11(chan)/gain(chan) ...
A2(chan)/gain(chan)] ...
[B0(chan) B1(chan) B2(chan)] x);
y2=filter([A0(chan) A12(chan) A2(chan)] ...
[B0(chan) B1(chan) B2(chan)] y1);
y3=filter([A0(chan) A13(chan) A2(chan)] ...
[B0(chan) B1(chan) B2(chan)] y2);
y4=filter([A0(chan) A14(chan) A2(chan)] ...
[B0(chan) B1(chan) B2(chan)] y3);
output(chan :) = y4;
end
if 0
semilogx((0:(length(x)-1))*(fs/length(x))20*log10(abs(fft(output))));
end
属性 大小 日期 时间 名称
----------- --------- ---------- ----- ----
目录 0 2009-03-12 19:16 gammatonegram\
文件 1766 1998-12-11 21:26 gammatonegram\ERBFilterBank.m
文件 1125 1998-12-11 22:16 gammatonegram\ERBSpace.m
文件 3940 2009-02-22 02:29 gammatonegram\fft2gammatonemx.m
文件 6382 2009-03-12 19:12 gammatonegram\gammatone_demo.m
文件 7280 2009-03-12 19:13 gammatonegram\gammatone_demo.png
文件 37226 2009-03-12 19:13 gammatonegram\gammatone_demo_01.png
文件 9764 2009-02-20 22:21 gammatonegram\gammatonegram.jpg
文件 2540 2009-02-23 21:08 gammatonegram\gammatonegram.m
文件 17004 2009-03-12 19:13 gammatonegram\index.html
文件 4626 1998-12-11 22:54 gammatonegram\MakeERBFilters.m
文件 85446 2002-04-09 01:11 gammatonegram\sa2.wav
文件 19276 2009-03-12 19:13 gammatonegram\gammatone_demo_02.png
文件 1544 2009-05-19 15:17 license.txt
评论
共有 条评论