《计算机应用》唯一官方网站 ›› 2025, Vol. 45 ›› Issue (2): 610-615.DOI: 10.11772/j.issn.1001-9081.2024020227
• 多媒体计算与计算机仿真 • 上一篇
收稿日期:
2024-03-05
修回日期:
2024-05-16
接受日期:
2024-05-20
发布日期:
2024-06-04
出版日期:
2025-02-10
通讯作者:
金世俊
作者简介:
文诗佳(2000—),女,湖南衡阳人,硕士研究生,主要研究方向:移动机器人导航、视觉同时定位与建图、路径规划;
Received:
2024-03-05
Revised:
2024-05-16
Accepted:
2024-05-20
Online:
2024-06-04
Published:
2025-02-10
Contact:
Shijun JING
About author:
WEN Shijia, born in 2000, M. S. candidate. Her research interests include mobile robot navigation, visual simultaneous location and mapping, path planning.
摘要:
针对动态物体严重干扰同时定位与建图(SLAM)系统正常运行的问题,提出一种基于目标检测和特征点关联的动态视觉SLAM算法。首先,利用YOLOv5目标检测网络得到环境中潜在动态物体的信息,并基于简易目标跟踪对图像漏检进行补偿;其次,为解决单一特征点的几何约束方法易出现误判的问题,依据图像的位置信息和光流信息建立特征点关联,再结合极线约束判断关系网的动态性;再次,结合两种方法剔除图像中的动态特征点,并用剩余的静态特征点加权估计位姿;最后,对静态环境建立稠密点云地图。在TUM(Technical University of Munich)公开数据集上的对比和消融实验的结果表明,与ORB-SLAM2和DS-SLAM(Dynamic Semantic SLAM)相比,所提算法在高动态场景下的绝对轨迹误差(ATE)中的均方根误差(RMSE)分别至少降低了95.22%和5.61%。可见,所提算法在保证实时性的同时提高了准确性和鲁棒性。
中图分类号:
文诗佳, 金世俊. 结合目标检测和特征点关联的动态视觉SLAM算法[J]. 计算机应用, 2025, 45(2): 610-615.
Shijia WEN, Shijun JING. Dynamic visual SLAM algorithm incorporating object detection and feature point association[J]. Journal of Computer Applications, 2025, 45(2): 610-615.
动态程度 | 数据集 | 绝对轨迹误差/m | 性能提升/% | ||||
---|---|---|---|---|---|---|---|
ORB-SLAM2 | 本文算法 | ||||||
RMSE | STD | RMSE | STD | RMSE | STD | ||
静态 | fr1_xyz | 0.009 8 | 0.005 3 | 0.009 9 | 0.005 2 | -1.02 | 1.89 |
fr1_desk | 0.015 8 | 0.009 2 | 0.015 8 | 0.009 4 | 0.00 | -2.17 | |
低动态 | fr3_sitting_xyz | 0.009 6 | 0.004 8 | 0.009 3 | 0.004 6 | 3.13 | 4.17 |
fr3_sitting_static | 0.008 6 | 0.004 2 | 0.007 0 | 0.003 5 | 18.60 | 16.67 | |
高动态 | fr3_walking_rpy | 0.903 1 | 0.492 7 | 0.032 8 | 0.018 3 | 96.37 | 96.29 |
fr3_walking_xyz | 0.735 7 | 0.424 0 | 0.014 3 | 0.006 7 | 98.06 | 98.42 | |
fr3_walking_static | 0.383 5 | 0.134 9 | 0.007 4 | 0.003 4 | 98.07 | 97.48 | |
fr3_walking_halfsphere | 0.598 4 | 0.300 2 | 0.028 6 | 0.014 2 | 95.22 | 95.27 |
表1 本文算法与ORB-SLAM2的ATE对比
Tab. 1 ATE comparison of proposed algorithm and ORB-SLAM2
动态程度 | 数据集 | 绝对轨迹误差/m | 性能提升/% | ||||
---|---|---|---|---|---|---|---|
ORB-SLAM2 | 本文算法 | ||||||
RMSE | STD | RMSE | STD | RMSE | STD | ||
静态 | fr1_xyz | 0.009 8 | 0.005 3 | 0.009 9 | 0.005 2 | -1.02 | 1.89 |
fr1_desk | 0.015 8 | 0.009 2 | 0.015 8 | 0.009 4 | 0.00 | -2.17 | |
低动态 | fr3_sitting_xyz | 0.009 6 | 0.004 8 | 0.009 3 | 0.004 6 | 3.13 | 4.17 |
fr3_sitting_static | 0.008 6 | 0.004 2 | 0.007 0 | 0.003 5 | 18.60 | 16.67 | |
高动态 | fr3_walking_rpy | 0.903 1 | 0.492 7 | 0.032 8 | 0.018 3 | 96.37 | 96.29 |
fr3_walking_xyz | 0.735 7 | 0.424 0 | 0.014 3 | 0.006 7 | 98.06 | 98.42 | |
fr3_walking_static | 0.383 5 | 0.134 9 | 0.007 4 | 0.003 4 | 98.07 | 97.48 | |
fr3_walking_halfsphere | 0.598 4 | 0.300 2 | 0.028 6 | 0.014 2 | 95.22 | 95.27 |
动态 程度 | 数据集 | 本文算法 | ORBSLAM2+YOLOv5s | ORB-SLAM2+几何约束 (含特征关联) | ORB-SLAM2+YOLOv5s+ 几何约束(不含特征关联) | ||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|
ATE/m | R.RPE/(°) | T.RPE /m | ATE/m | R.RPE /(°) | T.RPE /m | ATE/m | R.RPE /(°) | T.RPE /m | ATE/m | R.RPE /(°) | T.RPE /m | ||
静态 | fr1_xyz | 0.009 9 | 0.387 9 | 0.006 0 | 0.010 2 | 0.405 7 | 0.006 2 | 0.009 9 | 0.398 4 | 0.006 0 | 0.010 1 | 0.386 9 | 0.005 9 |
fr1_desk | 0.015 8 | 0.563 6 | 0.009 5 | 0.016 2 | 0.572 3 | 0.009 4 | 0.015 0 | 0.575 6 | 0.009 3 | 0.015 0 | 0.560 3 | 0.009 3 | |
低动态 | fr3_sitting_xyz | 0.009 3 | 0.315 9 | 0.008 5 | 0.009 5 | 0.314 4 | 0.008 6 | 0.017 2 | 0.328 2 | 0.009 9 | 0.015 1 | 0.327 5 | 0.009 6 |
fr3_sitting_static | 0.007 0 | 0.165 2 | 0.005 3 | 0.005 8 | 0.150 3 | 0.004 4 | 0.006 1 | 0.150 3 | 0.004 5 | 0.006 0 | 0.151 6 | 0.004 7 | |
高动态 | fr3_walking_xyz | 0.014 3 | 0.385 4 | 0.011 5 | 0.015 1 | 0.389 3 | 0.016 1 | 0.242 3 | 0.600 4 | 0.133 3 | 0.018 0 | 0.404 5 | 0.022 7 |
fr3_walking_rpy | 0.032 8 | 0.500 0 | 0.021 3 | 0.044 1 | 0.526 5 | 0.045 7 | 0.228 3 | 0.541 9 | 0.061 8 | 0.156 5 | 0.576 4 | 0.156 5 | |
fr3_walking_static | 0.007 4 | 0.176 0 | 0.006 0 | 0.009 8 | 0.187 2 | 0.009 9 | 0.009 9 | 0.206 9 | 0.009 6 | 0.010 1 | 0.201 8 | 0.010 1 | |
fr3_walking_halfsphere | 0.028 6 | 0.418 0 | 0.013 8 | 0.033 0 | 0.420 6 | 0.025 8 | 0.029 4 | 0.485 6 | 0.030 9 | 0.036 8 | 0.428 5 | 0.023 9 |
表2 消融实验中ATE与在旋转(R.RPE)和平移部分(T.PRE)的RPE的RMSE结果
Tab. 2 Results of RMSE of ATE, RPE in the rotation part (R.RPE) and RPE in the translation part (T.PRE) in ablation experiments
动态 程度 | 数据集 | 本文算法 | ORBSLAM2+YOLOv5s | ORB-SLAM2+几何约束 (含特征关联) | ORB-SLAM2+YOLOv5s+ 几何约束(不含特征关联) | ||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|
ATE/m | R.RPE/(°) | T.RPE /m | ATE/m | R.RPE /(°) | T.RPE /m | ATE/m | R.RPE /(°) | T.RPE /m | ATE/m | R.RPE /(°) | T.RPE /m | ||
静态 | fr1_xyz | 0.009 9 | 0.387 9 | 0.006 0 | 0.010 2 | 0.405 7 | 0.006 2 | 0.009 9 | 0.398 4 | 0.006 0 | 0.010 1 | 0.386 9 | 0.005 9 |
fr1_desk | 0.015 8 | 0.563 6 | 0.009 5 | 0.016 2 | 0.572 3 | 0.009 4 | 0.015 0 | 0.575 6 | 0.009 3 | 0.015 0 | 0.560 3 | 0.009 3 | |
低动态 | fr3_sitting_xyz | 0.009 3 | 0.315 9 | 0.008 5 | 0.009 5 | 0.314 4 | 0.008 6 | 0.017 2 | 0.328 2 | 0.009 9 | 0.015 1 | 0.327 5 | 0.009 6 |
fr3_sitting_static | 0.007 0 | 0.165 2 | 0.005 3 | 0.005 8 | 0.150 3 | 0.004 4 | 0.006 1 | 0.150 3 | 0.004 5 | 0.006 0 | 0.151 6 | 0.004 7 | |
高动态 | fr3_walking_xyz | 0.014 3 | 0.385 4 | 0.011 5 | 0.015 1 | 0.389 3 | 0.016 1 | 0.242 3 | 0.600 4 | 0.133 3 | 0.018 0 | 0.404 5 | 0.022 7 |
fr3_walking_rpy | 0.032 8 | 0.500 0 | 0.021 3 | 0.044 1 | 0.526 5 | 0.045 7 | 0.228 3 | 0.541 9 | 0.061 8 | 0.156 5 | 0.576 4 | 0.156 5 | |
fr3_walking_static | 0.007 4 | 0.176 0 | 0.006 0 | 0.009 8 | 0.187 2 | 0.009 9 | 0.009 9 | 0.206 9 | 0.009 6 | 0.010 1 | 0.201 8 | 0.010 1 | |
fr3_walking_halfsphere | 0.028 6 | 0.418 0 | 0.013 8 | 0.033 0 | 0.420 6 | 0.025 8 | 0.029 4 | 0.485 6 | 0.030 9 | 0.036 8 | 0.428 5 | 0.023 9 |
动态 程度 | 数据集 | 本文系统 | Dynamic-VINS[ | DynaSLAM[ | DS-SLAM[ | ISC-SLAM[ | |||||
---|---|---|---|---|---|---|---|---|---|---|---|
RMSE | STD | RMSE | STD | RMSE | STD | RMSE | STD | RMSE | STD | ||
低动态 | fr3_sitting_xyz | 0.009 6 | 0.004 8 | 0.015 0 | 0.006 5 | 0.020 5 | 0.009 8 | ||||
fr3_sitting_static | 0.008 6 | 0.004 2 | 0.273 5 | 0.121 5 | |||||||
高动态 | fr3_walking_xyz | 0.014 3 | 0.006 7 | 0.048 6 | 0.015 0 | 0.008 6 | 0.024 7 | 0.016 1 | 0.014 8 | 0.007 7 | |
fr3_walking_rpy | 0.032 8 | 0.017 3 | 0.062 9 | 0.035 0 | 0.043 7 | 0.444 2 | 0.235 0 | 0.035 8 | 0.020 7 | ||
fr3_walking_static | 0.007 4 | 0.003 4 | 0.007 7 | 0.006 0 | 0.003 4 | 0.008 1 | 0.003 6 | 0.007 3 | 0.003 3 | ||
fr3_walking_halfsphere | 0.028 6 | 0.014 2 | 0.060 8 | 0.025 0 | 0.016 1 | 0.030 3 | 0.015 9 | 0.030 3 | 0.014 6 |
表3 本文算法与DynaSLAM、DS-SLAM、Dynamic-VINS、ISC-SLAM的ATE对比 (m)
Tab. 3 ATE comparison of proposed algorithm, DynaSLAM, DS-SLAM, Dynamic-VINS and ISC-SLAM
动态 程度 | 数据集 | 本文系统 | Dynamic-VINS[ | DynaSLAM[ | DS-SLAM[ | ISC-SLAM[ | |||||
---|---|---|---|---|---|---|---|---|---|---|---|
RMSE | STD | RMSE | STD | RMSE | STD | RMSE | STD | RMSE | STD | ||
低动态 | fr3_sitting_xyz | 0.009 6 | 0.004 8 | 0.015 0 | 0.006 5 | 0.020 5 | 0.009 8 | ||||
fr3_sitting_static | 0.008 6 | 0.004 2 | 0.273 5 | 0.121 5 | |||||||
高动态 | fr3_walking_xyz | 0.014 3 | 0.006 7 | 0.048 6 | 0.015 0 | 0.008 6 | 0.024 7 | 0.016 1 | 0.014 8 | 0.007 7 | |
fr3_walking_rpy | 0.032 8 | 0.017 3 | 0.062 9 | 0.035 0 | 0.043 7 | 0.444 2 | 0.235 0 | 0.035 8 | 0.020 7 | ||
fr3_walking_static | 0.007 4 | 0.003 4 | 0.007 7 | 0.006 0 | 0.003 4 | 0.008 1 | 0.003 6 | 0.007 3 | 0.003 3 | ||
fr3_walking_halfsphere | 0.028 6 | 0.014 2 | 0.060 8 | 0.025 0 | 0.016 1 | 0.030 3 | 0.015 9 | 0.030 3 | 0.014 6 |
算法 | 定位丢失帧数 | ||
---|---|---|---|
fr3_w_xyz | fr3_w_rpy | fr3_ w_halfsphere | |
ORB-SLAM2 | 151 | 0 | 209 |
ORB-SLAM2+YOLOv5 | 0 | 123 | 14 |
本文算法 | 0 | 61 | 0 |
表4 不同算法的跟踪丢失帧数
Tab. 4 Numbers of lost frames tracked by different algorithms
算法 | 定位丢失帧数 | ||
---|---|---|---|
fr3_w_xyz | fr3_w_rpy | fr3_ w_halfsphere | |
ORB-SLAM2 | 151 | 0 | 209 |
ORB-SLAM2+YOLOv5 | 0 | 123 | 14 |
本文算法 | 0 | 61 | 0 |
算法 | 平均跟踪时间 |
---|---|
ORB-SLAM2 | 36.78 |
DynaSLAM | 578.74 |
ISC-SLAM | 87.93 |
DS-SLAM | 59.40 |
本文算法(TensorRT加速前) | 133.60 |
本文算法(TensorRT加速后) | 53.25 |
表5 算法跟踪时间对比 (ms)
Tab. 5 Comparison of algorithm tracking time
算法 | 平均跟踪时间 |
---|---|
ORB-SLAM2 | 36.78 |
DynaSLAM | 578.74 |
ISC-SLAM | 87.93 |
DS-SLAM | 59.40 |
本文算法(TensorRT加速前) | 133.60 |
本文算法(TensorRT加速后) | 53.25 |
1 | CADENA C, CARLONE L, CARRILLO H, et al. Past, present, and future of simultaneous localization and mapping: toward the robust-perception age[J]. IEEE Transactions on Robotics, 2016, 32(6): 1309-1332. |
2 | DAVISON A J, REID I D, MOLTON N D, et al. MonoSLAM: real-time single camera SLAM[J]. IEEE Transactions on Pattern Analysis and Machine Intelligence, 2007, 29(6): 1052-1067. |
3 | FORSTER C, PIZZOLI M, SCARAMUZZA D. SVO: fast semi-direct monocular visual odometry[C]// Proceedings of the 2014 IEEE International Conference on Robotics and Automation. Piscataway: IEEE, 2014: 15-22. |
4 | ENGEL J, KOLTUN V, CREMERS D. Direct sparse odometry[J]. IEEE Transactions on Pattern Analysis and Machine Intelligence, 2018, 40(3): 611-625. |
5 | MUR-ARTAL R, TARDÓS J D. ORB-SLAM2: an open-source SLAM system for monocular, stereo and RGB-D cameras[J]. IEEE Transactions on Robotics, 2017, 33(5): 1255-1262. |
6 | SINGH G, WU M, DO M V, et al. Fast semantic-aware motion state detection for visual SLAM in dynamic environment[J]. IEEE Transactions on Intelligent Transportation Systems, 2022, 23(12): 23014-23030. |
7 | ZHANG C, ZHANG R, JIN S, et al. PFD-SLAM: a new RGB-D SLAM for dynamic indoor environments based on non-prior semantic segmentation[J]. Remote Sensing, 2022, 14(10): No.2445. |
8 | SUN Y, LIU M, MENG M Q H. Improving RGB-D SLAM in dynamic environments: a motion removal approach[J]. Robotics and Autonomous Systems, 2017, 89: 110-122. |
9 | LI S, LEE D. RGB-D SLAM in dynamic environments using static point weighting[J]. IEEE Robotics and Automation Letters, 2017, 2(4): 2263-2270. |
10 | 黄泽霞,邵春莉. 深度学习下的视觉SLAM综述[J]. 机器人, 2023, 45(6):756-768. |
HUANG Z X, SHAO C L. Survey of visual SLAM based on deep learning[J]. Robot, 2023, 45(6):756-768. | |
11 | 席志红,温家旭. 基于目标检测的室内动态场景定位与建图[J]. 计算机应用, 2022, 42(9): 2853-2857. |
XI Z H, WEN J X. Indoor dynamic scene localization and mapping based on target detection[J]. Journal of Computer Applications, 2022, 42(9): 2853-2857. | |
12 | LIU J, LI X, LIU Y, et al. RGB-D inertial odometry for a resource-restricted robot in dynamic environments[J]. IEEE Robotics and Automation Letters, 2022, 7(4): 9573-9580. |
13 | 刘丰宇,程向红,曹毅. 基于深度学习与特征点速度约束的室内动态SLAM方法[J]. 中国惯性技术学报, 2023, 31(5): 438-443. |
LIU F Y, CHENG X H, CAO Y. An indoor dynamic SLAM method based on deep learning and feature point velocity constraint[J]. Journal of Chinese Inertial Technology, 2023, 31(5):438-443. | |
14 | BESCOS B, FÁCIL J M, CIVERA J, et al. DynaSLAM: tracking, mapping and inpainting in dynamic scenes[J]. IEEE Robotics and Automation Letters, 2018, 3(4): 4076-4083. |
15 | HE K, GKIOXARI G, DOLLÁR P, et al. Mask R-CNN[J]. IEEE Transactions on Pattern Analysis and Machine Intelligence, 2020, 42(2): 386-397. |
16 | YU C, LIU Z, LIU X J, et al. DS-SLAM: a semantic visual SLAM towards dynamic environments[C]// Proceedings of the 2018 IEEE/RSJ International Conference on Intelligent Robots and Systems. Piscataway: IEEE, 2018: 1168-1174. |
17 | BADRINARAYANAN V, KENDALL A, CIPOLLA R. SegNet: a deep convolutional encoder-decoder architecture for image segmentation[J]. IEEE Transactions on Pattern Analysis and Machine Intelligence, 2017, 39(12): 2481-2495. |
18 | 肖田邹子,周小博,罗欣,等. 动态环境下结合实例分割与聚类的鲁棒RGB-D SLAM系统[J]. 计算机应用, 2023, 43(4): 1220-1225. |
XIAO T Z Z, ZHOU X B, LUO X, et al. Robust RGB-D SLAM system incorporating instance segmentation and clustering in dynamic environment[J]. Journal of Computer Applications, 2023, 43(4): 1220-1225. | |
19 | XU Z, RONG Z, WU Y. A survey: which features are required for dynamic visual simultaneous localization and mapping?[J]. Visual Computing for Industry, Biomedicine, and Art, 2021, 4: No.20. |
20 | Ultralytics. YOLOv5[EB/OL]. [2024-01-24].. |
21 | LIN T Y, MAIRE M, BELONGIE S,et al. Microsoft COCO: common objects in context[C]// Proceedings of the 2014 European Conference on Computer Vision, LNCS 8693. Cham: Springer, 2014:740-755. |
22 | STURM J, ENGELHARD N, ENDRES F, et al. A benchmark for the evaluation of RGB-D SLAM systems[C]// Proceedings of the 2012 IEEE/RSJ International Conference on Intelligent Robots and Systems. Piscataway: IEEE, 2012: 573-580. |
23 | GRUPP M. EVO: Python package for the evaluation of odometry and SLAM[EB/OL]. [2024-01-24].. |
[1] | 洪梓榕, 包广清. 基于集成学习的雷达自动目标识别综述[J]. 《计算机应用》唯一官方网站, 2025, 45(2): 371-382. |
[2] | 杨晟, 李岩. 面向目标检测的对比知识蒸馏方法[J]. 《计算机应用》唯一官方网站, 2025, 45(2): 354-361. |
[3] | 刘赏, 周煜炜, 代娆, 董林芳, 刘猛. 融合注意力和上下文信息的遥感图像小目标检测算法[J]. 《计算机应用》唯一官方网站, 2025, 45(1): 292-300. |
[4] | 王丽芳, 吴荆双, 尹鹏亮, 胡立华. 基于注意力机制和能量函数的动作识别算法[J]. 《计算机应用》唯一官方网站, 2025, 45(1): 234-239. |
[5] | 杨博然, 蔺素珍, 李大威, 禄晓飞, 崔晨辉. 基于信息补偿的红外弱小目标检测方法[J]. 《计算机应用》唯一官方网站, 2025, 45(1): 284-291. |
[6] | 潘烨新, 杨哲. 基于多级特征双向融合的小目标检测优化模型[J]. 《计算机应用》唯一官方网站, 2024, 44(9): 2871-2877. |
[7] | 李烨恒, 罗光圣, 苏前敏. 基于改进YOLOv5的Logo检测算法[J]. 《计算机应用》唯一官方网站, 2024, 44(8): 2580-2587. |
[8] | 张英俊, 李牛牛, 谢斌红, 张睿, 陆望东. 课程学习指导下的半监督目标检测框架[J]. 《计算机应用》唯一官方网站, 2024, 44(8): 2326-2333. |
[9] | 徐松, 张文博, 王一帆. 基于时空信息的轻量视频显著性目标检测网络[J]. 《计算机应用》唯一官方网站, 2024, 44(7): 2192-2199. |
[10] | 孙逊, 冯睿锋, 陈彦如. 基于深度与实例分割融合的单目3D目标检测方法[J]. 《计算机应用》唯一官方网站, 2024, 44(7): 2208-2215. |
[11] | 姬张建, 杜娜. 基于改进VariFocalNet的微小目标检测[J]. 《计算机应用》唯一官方网站, 2024, 44(7): 2200-2207. |
[12] | 刘越, 刘芳, 武奥运, 柴秋月, 王天笑. 基于自注意力机制与图卷积的3D目标检测网络[J]. 《计算机应用》唯一官方网站, 2024, 44(6): 1972-1977. |
[13] | 邓亚平, 李迎江. YOLO算法及其在自动驾驶场景中目标检测综述[J]. 《计算机应用》唯一官方网站, 2024, 44(6): 1949-1958. |
[14] | 耿焕同, 刘振宇, 蒋骏, 范子辰, 李嘉兴. 基于改进YOLOv8的嵌入式道路裂缝检测算法[J]. 《计算机应用》唯一官方网站, 2024, 44(5): 1613-1618. |
[15] | 宋霄罡, 张冬冬, 张鹏飞, 梁莉, 黑新宏. 面向复杂施工环境的实时目标检测算法[J]. 《计算机应用》唯一官方网站, 2024, 44(5): 1605-1612. |
阅读次数 | ||||||
全文 |
|
|||||
摘要 |
|
|||||