当前位置:网站首页>[target tracking] pedestrian attitude recognition based on frame difference method combined with Kalman filter, with matlab code
[target tracking] pedestrian attitude recognition based on frame difference method combined with Kalman filter, with matlab code
2022-04-23 20:08:00 【Matlab research studio】
1 brief introduction
In order to solve the problem of target tracking loss caused by scale change in video frame target tracking , A processing method of adaptive tracking window is proposed , The difference between the estimated position of the next frame and the target position of the current frame is used as the detection amount , Adaptively adjust the tracking window , Achieve effective detection and tracking of targets . Experimental results show that : This method can effectively reduce the probability of target loss , Prevent false tracking of targets , Adapt to target scale changes .
2 Part of the code
% extracts the center (cc,cr) and radius of the largest blob
function [stats,N,flag,foremm]=extract(Imwork,Imback,index)%,fig1,fig2,fig3,fig15,index)
cc = 0;
cr = 0;
flag = 0;
[MR,MC,Dim] = size(Imback);
%Imwork(:,:,1),Imwork(:,:,2),Imwork(:,:,3), They are the images RGB value ,
% The purpose of the program is to extract two pictures R,G,B The difference between the three channels is greater than 10 Part of ( Two valued )
% subtract background & select pixels with a big difference
fore = zeros(MR,MC);
fore = imabsdiff(Imwork,Imback);
% To binarize , Remove image noise
Im2=im2bw(fore,80/255);
% Expand the image
foremm = bwmorph(Im2,'dilate',4); %2 time
% select largest object
labeled = bwlabel(foremm,4); % Label the connected part of the binary image .
stats = regionprops(labeled,['basic']); % obtain label Graphic properties of % Use string 'basic', Property :'Area','Centroid' and 'BoundingBox' Will be calculated
[N,W] = size(stats);
if N < 1
return
end
% do bubble sort (large to small) on regions in case there are more than 1
id = zeros(N); % N Is the number of detected targets
for i = 1 : N
id(i) = i;
end
for i = 1 : N-1
for j = i+1 : N
if stats(i).Area < stats(j).Area
tmp = stats(i);
stats(i) = stats(j);
stats(j) = tmp;
tmp = id(i);
id(i) = id(j);
id(j) = tmp;
end
end
end
% make sure that there is at least 1 big region
if stats(1).Area < 100
return
end
%selected = (labeled==id(1));
flag = 1;
return
3 Simulation results
4 reference
[1] Li Yanyan , Tian Ruijuan , Zhang Xianxian . A combination method based on frame difference Kalman Filtering moving target tracking method [J]. Ordnance automation , 2019, 38(4):4.
About bloggers : Good at intelligent optimization algorithms 、 Neural networks predict 、 signal processing 、 Cellular automata 、 The image processing 、 Path planning 、 UAV and other fields Matlab Simulation , relevant matlab Code problems can be exchanged by private letter .
Some theories cite network literature , If there is infringement, contact the blogger to delete .
版权声明
本文为[Matlab research studio]所创,转载请带上原文链接,感谢
https://yzsam.com/2022/04/202204232006078273.html
边栏推荐
- R语言使用econocharts包创建微观经济或宏观经济图、indifference函数可视化无差异曲线、自定义计算交叉点、自定义配置indifference函数的参数丰富可视化效果
- MySQL数据库 - 单表查询(二)
- SRS deployment
- 【2022】将3D目标检测看作序列预测-Point2Seq: Detecting 3D Objects as Sequences
- A simple (redisson based) distributed synchronization tool class encapsulation
- MySQL lock
- Class loading process of JVM
- 对普通bean进行Autowired字段注入
- 记录:调用mapper报空指针;<foreach>不去重的用法;
- Mfcc: Mel frequency cepstrum coefficient calculation of perceived frequency and actual frequency conversion
猜你喜欢
Distinction between pointer array and array pointer
Project training of Software College of Shandong University - Innovation Training - network security shooting range experimental platform (V)
Shanda Wangan shooting range experimental platform project - personal record (V)
Understanding various team patterns in scrum patterns
Kubernetes introduction to mastery - ktconnect (full name: kubernetes toolkit connect) is a small tool based on kubernetes environment to improve the efficiency of local test joint debugging.
【webrtc】Add x264 encoder for CEF/Chromium
Scrum Patterns之理解各种团队模式
aqs的学习
MySQL 进阶 锁 -- MySQL锁概述、MySQL锁的分类:全局锁(数据备份)、表级锁(表共享读锁、表独占写锁、元数据锁、意向锁)、行级锁(行锁、间隙锁、临键锁)
The textarea cursor cannot be controlled by the keyboard due to antd dropdown + modal + textarea
随机推荐
MySQL advanced lock - overview of MySQL locks and classification of MySQL locks: global lock (data backup), table level lock (table shared read lock, table exclusive write lock, metadata lock and inte
Go recursively loops through folders
Devops integration - environment variables and building tools of Jenkins service
Record: call mapper to report null pointer Foreach > the usage of not removing repetition;
nc基础用法
uIP1.0 主动发送的问题理解
深度分析数据恢复原理——那些数据可以恢复那些不可以数据恢复软件
Project training of Software College of Shandong University - Innovation Training - network security shooting range experimental platform (6)
记录:调用mapper报空指针;<foreach>不去重的用法;
Mysql database - connection query
Fundamentals of programming language (2)
数据库查询 - 选课系统
【文本分类案例】(4) RNN、LSTM 电影评价倾向分类,附TensorFlow完整代码
FFT物理意义: 1024点FFT就是1024个实数,实际进入fft的输入是1024个复数(虚部为0),输出也是1024个复数,有效的数据是前512个复数
本地调用feign接口报404
Esp8266 - beginner level Chapter 1
Design of library management database system
R语言使用timeROC包计算存在竞争风险情况下的生存资料多时间AUC值、使用cox模型、并添加协变量、R语言使用timeROC包的plotAUCcurve函数可视化多时间生存资料的AUC曲线
Mfcc: Mel frequency cepstrum coefficient calculation of perceived frequency and actual frequency conversion
Kubernetes introduction to mastery - ktconnect (full name: kubernetes toolkit connect) is a small tool based on kubernetes environment to improve the efficiency of local test joint debugging.