ndexk (1);
% Search further forward for frame with energy greater than ITLl = ITUf: -1:1 (Erg_Vectorf (l)
= length (Erg_Vector)-indexl (1) +1;% Tentative finish index
% Search back from start index for crossing rates higher than IZCT
= min (start, 25); m = start: -1: start-BackSearch +1 = ZCR_Vector (m); rate> IZCT = ZCRCountb + 1; = m; ZCRCountb> 3 = realstart;% If IZCT is exceeded in more than 3 frames
% set start to last index where IZCT is exceeded
% Search forward from finish index for crossing rates higher than IZCT = min (length (Erg_Vector)-finish, 25); n = finish +1: finish + FwdSearch = ZCR_Vector (n); rate> ; IZCT = ZCRCountf + 1; = n; ZCRCountf> 3 = realfinish;% If IZCT is exceeded in more than 3 frames
% set finish to last index where IZCT is exceeded
_start = FrmIndex (start);% actual sample index for frame 'start'_finish = FrmIndex (finish-1);% actual sample index for frame' finish '= x (x_start: x_finish); % T rim speech sample by start and finish indices
1.3. Лістинг mfsscf.m
FMatrix = mfccf (num, s, Fs)
% Syntax: M = mfccf (num, s, Fs);
% Computes and returns the mfcc coefficients for a speech signal s
% where num is the required number of MFCC coefficients. It utilises the
% function 'melbankm' from the toolbox 'Voicebox' by Mike Brooks
= 512;% Number of FFT points = 0.025;% Frame duration in seconds = floor (Fs * Tf);% Number of samples per frame = 24;% Number of mel filters = length (s );% total number of samples in speech = 0.01;% Frame step in seconds = Fs * Ts;% Frame step in samples = 1; = [1, -0.97];% a and b are high pass filter coefficients = floor ( l/FrameStep);% Maximum no of frames in speech sample = zeros (noFrames-2, num);% Matrix to hold cepstral coefficients = 1: num;% Lifter vector index = 1 + floor ((num)/2) * (sin (lifter * pi/num));% raised sine lifter version
mean (abs (s))> 0.01 = s/max (s);% Normalises to compensate for mic vol differences
% Segment the signal into overlapping frames and compute MFCC coefficientsi = 1: noFrames-2 = s ((i-1) * FrameStep +1: (i-1) * FrameStep + N);% Holds individual frames = sum (frame. ^ 2);% Frame energy = max (Ce1, 2e-22);% floors to 2 X 10 raised to power -22 = log (Ce2); = filter (b, a, frame );% High pass pre-emphasis filter = framef. * hamming (N);% multiplies each frame with hamming window = fft (F, N);% computes the fft = melbankm (fn, n, Fs);% creates 24 filter, mel filter bank = 1 + floor (n/2); = log10 (melf * abs (...