Filter löschen
Filter löschen

error in code for pitch tracking

2 Ansichten (letzte 30 Tage)
danny Sharah
danny Sharah am 10 Apr. 2015
i am using matlab 7.1 version. following code for "pitch track" of audio signal is downloaded
from link "http://labrosa.ee.columbia.edu/projects/pitchflow/". i am getting error at logfsgram()
saying that " Undefined function 'logfsgram' for input arguments of type 'double'.
Error in demo_pitchflow (line 26) logfsgram(d,256,sr); " how can i solve it?please help. code is as below..
% Load a sound file
[d,sr] = audioread(['/u/drspeech/data/swordfish/code/ehist/' ... 'BABEL_OP1_206_65882_20121201_174526_outLine.sph']);
% Plot its log-frequency spectrogram
subplot(311)
logfsgram(d,256,sr);
caxis([-30 30]);
% Calculate the normalized cross-correlation of adjacent log-f spectra
sxc = pitchflow(d, sr);
subplot(312)
tt = [0:(size(sxc,2)-1)]*0.010;
rr = [1:size(sxc,1)] - (size(sxc, 1)+1)/2; imagesc(tt, rr, sxc); axis('xy'); grid
% Collapse each excerpt from the cross-corrletions into 3 features,
% the first three moments of the exponentiated NCC
dpf = pitchflow_collapse(sxc);
subplot(313)
plot(tt, dpf);
% Overplot the first moment on the xcorr, to show it tracks the main peak
subplot(312)
hold on;
plot(tt, dpf(2,:), '-w');
hold off
% Line up and zoom in
linkaxes([subplot(311),subplot(312),subplot(313)], 'x')
axis([196 200 -5 10])

Antworten (0)

Kategorien

Mehr zu Audio I/O and Waveform Generation finden Sie in Help Center und File Exchange

Tags

Community Treasure Hunt

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

Start Hunting!

Translated by