📄 endpoint_watch.m
字号:
function purewatch()
clear;
fclose('all');
frame_step=192;
temp=0;
% Fp_Speech=fopen('D:\test_kwspot\voice_converted\TargetFile\F_005.dat','r');
Fp_Speech=fopen('D:\PiPi_Demo\皮皮-男人8k拆分\8k_F_013.dat','r');
% notefile='D:\test_kwspot\lpccfea\vad\F_005vad.dat';
notefile='D:\PiPi_Demo\皮皮-男人8k-vad-auto\F_013.vad';
fidr=fopen(notefile,'rt');
str=fgetl(fidr);
fseek(Fp_Speech,198,'bof');
temp=fread(Fp_Speech,1,'int16');
Sentence_Num=temp;
frames_sent=0;
for iSentence_Num=0:Sentence_Num-1,
frames=fscanf(fidr,'%3d %3d', 2);
% frames = frames/2;
fseek(Fp_Speech,200,'bof');
fseek(Fp_Speech,2*4*iSentence_Num,'cof');
Off_Set=fread(Fp_Speech,1,'int32');
SentenceLength_Byte=fread(Fp_Speech,1,'int32');
fseek(Fp_Speech,Off_Set,'bof');
VoiceData_Short=fread(Fp_Speech,SentenceLength_Byte/2,'int16');
% soundsc(VoiceData_Short,8000);
% if(iSentence_Num < 79)
% continue;
% end
figure(2);
x = (1:length(VoiceData_Short))/frame_step;
plot(x,VoiceData_Short);
hold on
plot(frames,2,'go');
hold off
string=int2str(iSentence_Num+1);
string=strcat(string,' of ');
string1=int2str(Sentence_Num);
string=strcat(string,string1);
title(string);
xlabel('start and end point','FontSize',12)
pause
end
fclose('all');
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -