91av视频/亚洲h视频/操亚洲美女/外国一级黄色毛片 - 国产三级三级三级三级

  • 大小: 2KB
    文件類型: .m
    金幣: 1
    下載: 0 次
    發布日期: 2021-05-12
  • 語言: Matlab
  • 標簽: 幀差法??

資源簡介

基于機器視覺常見的幀間差分的運動目標檢測程序

資源截圖

代碼片段和文件信息

mov=aviread(‘C:\Documents?and?Settings\Administrator\桌面\照片\cup.avi‘);
temp=size(mov);?
fnum=temp(2);
for?i=1:fnum
????strtemp=strcat(int2str(i)‘.‘‘JPG‘);
????imwrite(mov(i).cdata(:::)strtemp);
end??????????%??從視頻中提出每一幀圖像
o=1;
e=‘.jpg‘;
for?i=1:15
????u=o-1;v=o-2;
????m=int2str(o);
????n=int2str(u);h=int2str(v);
????s=strcat(me);%%把字符串b與m連接后在連接e得到圖像文件存儲的位置
????m=imread(s);%%從S處把圖像讀取出來
????m=rgb2gray(m);%%將圖像M灰度化
???
m=medfilt2(m[33]);
if(o>=3)
????????s=strcat(ne);
????????n=imread(s);
????????n=rgb2gray(n);
????????s=strcat(he);
????????h=imread(s);
????????h=rgb2gray(h);
????????
????????n=medfilt2(n[33]);
????????h=medfilt2(h[33]);

????????q=im2double(m);%%將圖像數組轉換為double型
????????w=im2double(n);?g=im2double(h);
????????c=q-w;j=w-g;
????????
????????th=10/255;
????????
????????k=find(abs(c)>=th);
????????c(k)=1;
????????k=find(abs(c)????????c(k)=0;??
????????c=bwareaopen(c15);
??????????
????????se90=strel?(‘line‘390);se0=strel?(‘line‘30);
???????

評論

共有 條評論