转载自:http://ganeshtiwaridotcomdotnp.blogspot.com/2011/08/silence-removal-and-end-point-detection.html

Visithttp://ganeshtiwaridotcomdotnp.blogspot.com/2011/06/final-report-text-prompted-remote.html for more detail about our project.
For the purpose of silence removal of captured sound, we used the algorithm specified in
"A New Silence Removal and Endpoint Detection Algorithm for Speech and Speaker Recognition Applications"
Our actual system was in JAVAbut we verified the performance of this algorithm in MATLAB.

Inputs and Output

Here is the Matlab code : 
It first records sound for 5 seconds and removes the silence and then plays back.

//silence removal and end point detection
THRESHOLD=0.3; // adjust value yourself
TIME=;
%capture;
Fs = ;
y = wavrecord(TIME*Fs,Fs);
%plot(y)
%wavplay(y,Fs);
samplePerFrame=floor(Fs/);
bgSampleCount=floor(Fs/); %according to formula, sample needed for khz %----------
%calculation of mean and std
bgSample=[];
for i=::bgSampleCount
bgSample=[bgSample y(i)];
end
meanVal=mean(bgSample);
sDev=std(bgSample);
%----------
%identify voiced or not for each value
for i=::length(y)
if(abs(y(i)-meanVal)/sDev > THRESHOLD)
voiced(i)=;
else
voiced(i)=;
end
end % identify voiced or not for each frame
%discard insufficient samples of last frame usefulSamples=length(y)-mod(length(y),samplePerFrame);
frameCount=usefulSamples/samplePerFrame;
voicedFrameCount=;
for i=::frameCount
cVoiced=;
cUnVoiced=;
for j=i*samplePerFrame-samplePerFrame+::(i*samplePerFrame)
if(voiced(j)==)
cVoiced=(cVoiced+);
else
cUnVoiced=cUnVoiced+;
end
end
%mark frame for voiced/unvoiced
if(cVoiced>cUnVoiced)
voicedFrameCount=voicedFrameCount+;
voicedUnvoiced(i)=;
else
voicedUnvoiced(i)=;
end
end silenceRemovedSignal=[]; %-----
for i=::frameCount
if(voicedUnvoiced(i)==)
for j=i*samplePerFrame-samplePerFrame+::(i*samplePerFrame)
silenceRemovedSignal= [silenceRemovedSignal y(j)];
end
end
end %---display plot and play both sounds
figure; plot(y);
figure; plot(silenceRemovedSignal);
%%%play
wavplay(y,Fs);
wavplay(silenceRemovedSignal,Fs);

NOTE: Don't forget to adjust the microphone level and sound boost feature to achieve good results.

问:Wow.. Excellent.. Can u help me compare the efficiency of this algorithm with the STE and ZCR methods?? Thank you

答:As shown in research paper, the comparision of efficiency is as follows :
Phrases______STE______ZCR-STE__Proposed_Method
Combination
lock number__77.9531% 70.3720% 83.5565%
Running Text_50.8391% 50.1231% 59.7181%

最新文章

  1. php : 基础(3)
  2. CSS样式-文字超出宽部分用省略号代替
  3. surface RT app安装心得
  4. 用Qt图形视图框架开发拼图游戏
  5. Android 内存相关 onTrimMemory,onLowMemory,MemoryInfo()
  6. 省市县 三级 四级联动Javascript JQ 插件PCASClass.js
  7. Java笔记(十五)……面向对象IV多态(polymorphism)
  8. js 获取时间对象代码
  9. 升级Python至2.7.8,并安装django
  10. 路由器刷机常见第三方固件及管理前端种类(OpenWrt、Tomato、DD-Wrt)
  11. [国嵌攻略][071][Coredump故障分析]
  12. LDA主体模型
  13. 配置ubuntu
  14. 英语初级学习系列-00-Hello-打招呼
  15. ASP.Net Post方式获取数据流的一种简单写法
  16. 我眼中的 Docker(二)Image
  17. 激活函数(ReLU, Swish, Maxout)
  18. Python 进程之间共享数据
  19. Mac下搭建react及bable
  20. ThiNet: A Filter Level Pruning Method for Deep Neural Network Compression笔记

热门文章

  1. linux 导出mysql数据库表及数据
  2. Linux下dstat的安装(适用任何版本)
  3. UVa 1671 语言的历史——判断两个DFA是否等价
  4. mui 点击长按复制文本
  5. Centos 下 Apache 原生 Hbase + Phoenix 集群安装(转载)
  6. 用SAM实现后缀排序
  7. 洛谷 P2627 修剪草坪 题解
  8. PHP chmod() 函数
  9. threejs行星运动小demo总结
  10. windows下的上帝模式,很好用,细想,很恐怖啊