农机虚拟装配分类检测网络数据集构建方法

    李承恩, 邹湘军, 练国平, 林俊强, 张坡, 陈明猷, 叶磊

    李承恩, 邹湘军, 练国平, 等. 农机虚拟装配分类检测网络数据集构建方法[J]. 华南农业大学学报, 2021, 42(6): 117-125. DOI: 10.7671/j.issn.1001-411X.202104005
    引用本文: 李承恩, 邹湘军, 练国平, 等. 农机虚拟装配分类检测网络数据集构建方法[J]. 华南农业大学学报, 2021, 42(6): 117-125. DOI: 10.7671/j.issn.1001-411X.202104005
    LI Cheng’en, ZOU Xiangjun, LIAN Guoping, et al. Data set construction method of virtual assembly classification detection network for agricultural machinery[J]. Journal of South China Agricultural University, 2021, 42(6): 117-125. DOI: 10.7671/j.issn.1001-411X.202104005
    Citation: LI Cheng’en, ZOU Xiangjun, LIAN Guoping, et al. Data set construction method of virtual assembly classification detection network for agricultural machinery[J]. Journal of South China Agricultural University, 2021, 42(6): 117-125. DOI: 10.7671/j.issn.1001-411X.202104005

    农机虚拟装配分类检测网络数据集构建方法

    基金项目: 国家重点研发计划(20170700103)
    详细信息
      作者简介:

      李承恩(1996—),男,硕士研究生,E-mail: 976849268@qq.com

      通讯作者:

      邹湘军(1957—),女,教授,博士,E-mail: xjzou@163.com

    • 中图分类号: S24; TP391

    Data set construction method of virtual assembly classification detection network for agricultural machinery

    • 摘要:
      目的 

      虚拟装配在工业中可节约生产成本,提升机械部件生产效率。现有的虚拟现实引擎缺乏自动建立碰撞体功能,无法完整还原实际装配过程中的物理属性;通用化构建零件网格实体是提升虚拟装配实用性、精确性及通用性的重要途径。

      方法 

      以批量农机部件为样本对象,设计批量预处理算法及改进采样相关算法,通过构建三维模型样本的图片数据集,训练人工智能分类检测网络,从图片中分类并检测相关参数,实现自动构建碰撞体功能。

      结果 

      经过优化算法处理训练得到的分类检测网络从图片分类零件种类的精度在98%以上,从图片检测零件各项碰撞体构建参数的精度在98%以上;未经优化处理训练的网络不收敛。

      结论 

      本研究方法可以有效提升人工智能分类检测网络的识别精度及训练效率,结合碰撞体参数化构建程序,可提升碰撞体建模精度。

      Abstract:
      Objective 

      Virtual assembly can save production cost and improve the production efficiency of mechanical parts in industry. Due to the lack of the function of automatically creating collision body, the existing virtual reality engine can not completely restore the physical properties in the actual assembly process. Universaly building mechanical part grid entity is the important approach for improving practicability, accuracy and universality of virtual assembly.

      Method 

      The batch preprocessing algorithm and the improved sampling algorithm were designed for the batch agricultural machinery parts sampling. The image data set of three-dimensional model sample was constructed to train the artificial intelligence classification detection network, which can classify and detect the relevant parameters from the image samples, and realize the function of automatic construction of collision body.

      Result 

      The accuracy of the classification network trained by the optimized algorithm was more than 98% for the classification of parts from pictures, and more than 98% for the construction parameters of collision bodies from pictures. However, the network without optimized training did not converge.

      Conclusion 

      This method can effectively improve the recognition accuracy and training efficiency of the artificial intelligence classification detection network, and improve the modeling accuracy of the collision body by combining with the collision body parameterization construction program.

    • 图  1   三维模型样本批量格式转换

      Figure  1.   Batch format conversion of 3D model sample

      图  2   数据集优化处理算法总架构及流程

      Figure  2.   General framework and flow path of data set enhancement algorithm

      图  3   计算包围盒正交坐标系

      Figure  3.   Calculate the bounding box orthogonal coordinate system

      图  4   坐标轴系建立部分过程示意图

      Figure  4.   Schematic diagram of partial process of coordinate axes establishment

      图  5   调整坐标系

      Figure  5.   Adjust the coordinate system

      图  6   创建包围盒

      a:拨叉,b:紧固环,c:轴,d:齿轮

      Figure  6.   Create the bounding box

      a: Fork, b: Ring, c: Bearing, d: Gear

      图  7   样本不同缩放比例效果对比

      Figure  7.   Effect comparison of different sample zoom levels

      图  8   缩放比例为4的样本

      Figure  8.   Sample with zoom level of four

      图  9   缩放前样本

      Figure  9.   Samples before scaling

      图  10   缩放后样本

      Figure  10.   Samples after scaling

      图  11   透视相机(a)及正交投影相机(b)

      Figure  11.   Perspective camera (a) and orthogonal projection camera (b)

      图  12   相机阵列

      Figure  12.   Camera array

      图  13   不同分辨率的训练曲线

      Figure  13.   Training curve with different resolutions

      图  14   不同分辨率样本强边缘检测处理结果

      Figure  14.   Strong edge detection processing results of samples with different resolutions

      图  15   随机位姿所得样本

      Figure  15.   Samples with random pose

      图  16   损失值及精确值迭代变化过程

      Figure  16.   Iterative change process of loss value and accuracy

      图  17   OpenCV检测相关参数示意图

      Figure  17.   Schematic diagram of parameters related to OpenCV detection

      表  1   不同分辨率的训练数据

      Table  1   Training data with different resolutions

      分辨率
      Resolution
      迭代次数
      The number of iterations
      损失值
      Loss value
      320 × 320 28 2.87
      480 × 480 86 2.05
      960 × 960 77 0.33
      1 440 × 1 440 显存不足
      Insufficient memory

      None
      1 960 × 1 960 显存不足
      Insufficient memory

      None
      2 560 × 2 560 显存不足
      Insufficient memory

      None
      下载: 导出CSV

      表  2   部分检测数据

      Table  2   Part of the test data

      处理1)
      Treatment
      检测精度/%
      Accuracy
      损失值
      Loss
      value
      迭代次数
      The number
      of iterations
      结果
      Result
      BCD 62.92 0.91 22 不收敛
      Misconvergence
      ACD 60.98 0.90 17 不收敛
      Misconvergence
      ABD 91.87 0.30 56 收敛
      Convergence
      ABC 88.13 0.39 49 收敛
      Convergence
      ABCD 98.54 0.33 77 收敛
      Convergence
      空白对照
      Blank control
      23.13 2.25 8 不收敛
      Misconvergence
      1) A:坐标转换,B:尺寸归一化,C:采样空间优化,D:随机采样
      1) A: Coordinate transformation, B: Size normalization, C: Sampling space optimization, D: Random sampling
      下载: 导出CSV

      表  3   部分三维模型检测数据

      Table  3   Partial inspection data of 3D model

      样本名称
      Sample
      name
      实际齿顶圆
      半径/mm
      Actural
      outside radius
      检测齿顶圆
      半径/mm
      Detected
      outside radius
      相对误差/%
      Relative
      error
      gear_ (27) 32.00 31.58 1.3
      gear_ (28) 136.00 133.42 1.9
      gear_ (29) 56.00 55.27 1.3
      gear_ (30) 72.00 70.99 1.4
      gear_ (31) 72.00 71.01 1.4
      gear_ (32) 36.00 35.53 1.3
      下载: 导出CSV
    • [1] 邹湘军, 孙健, 何汉武, 等. 虚拟现实技术的演变发展与展望[J]. 系统仿真学报, 2004(9): 1905-1909. doi: 10.3969/j.issn.1004-731X.2004.09.015
      [2] 陈燕, 曾泽钦, 王杰, 等. 收获机虚拟环境模型与仿真平台构建[J]. 农业机械学报, 2019, 50(7): 159-166. doi: 10.6041/j.issn.1000-1298.2019.07.016
      [3] 邹湘军, 孙健, 何汉武. 虚拟环境下的生产线三维动态仿真及其建模[J]. 组合机床与自动化加工技术, 2004(4): 29-31. doi: 10.3969/j.issn.1001-2265.2004.04.012
      [4]

      SHAO N, DING X, LIU J. Tolerance analysis of spur gears based on skin model shapes and a boundary element method[J]. Mechanism and Machine Theory, 2020, 144: 103658. doi: 10.1016/j.mechmachtheory.2019.103658.

      [5] 朱忠祥, 陈莉, 李山山, 等. 基于虚拟现实的联合收获机底盘虚拟装配关键技术[J]. 农业机械学报, 2013, 44(S2): 262-267.
      [6] 林木, 张永春, 单丽君. 基于强化学习和虚拟现实技术的机械仿真教学系统研究[J]. 中国设备工程, 2020(22): 228-229. doi: 10.3969/j.issn.1671-0711.2020.22.132
      [7] 刘伟良, 王红军, 邹湘军, 等. 基于知识的变速箱齿轮虚拟设计研究[J]. 华南农业大学学报, 2020, 41(4): 120-126. doi: 10.7671/j.issn.1001-411X.201912024
      [8] 万华明, 杨丽, 邹湘军, 等. 基于VR技术的几何建模与优化[J]. 苏州科技学院学报(自然科学版), 2009, 26(4): 20-24.
      [9] 李承恩, 邹湘军, 曾泽钦, 等. 基于虚拟碰撞体的弧齿锥齿轮网格实体构建算法[J]. 系统仿真学报, 2021, 33(4): 837-844.
      [10]

      LUO L, TANG Y, ZOU X, et al. Vision-based extraction of spatial information in grape clusters for harvesting robots[J]. Biosystems Engineering, 2016, 151: 90-104. doi: 10.1016/j.biosystemseng.2016.08.026

      [11]

      TANG Y, CHEN M, WANG C, et al. Recognition and localization methods  for  vision-based  fruit  picking  robots: A review[J]. Frontiers in Plant Science, 2020, 11: 510. doi: 10.3389/fpls.2020.00510.

      [12]

      TANG Y, LI L, WANG C, et al. Real-time detection of surface deformation and strain in recycled aggregate concrete-filled steel tubular columns via four-ocular vision[J]. Robotics and Computer-Integrated Manufacturing, 2019, 59: 36-46. doi: 10.1016/j.rcim.2019.03.001

      [13]

      ZHUANG C, MIAO T, LIU J, et al. The connotation of digital twin, and the construction and application method of shop-floor digital twin[J]. Robotics and Computer-Integrated Manufacturing, 2021, 68: 102075. doi: 10.1016/j.rcim.2020.102075.

      [14] 陈燕, 王佳盛, 曾泽钦, 等. 大视场下荔枝采摘机器人的视觉预定位方法[J]. 农业工程学报, 2019, 35(23): 48-54. doi: 10.11975/j.issn.1002-6819.2019.23.006
      [15] 邹湘军, 孙健, 何汉武, 等. 虚拟环境中多Agent决策的冲突证据合成研究[J]. 系统仿真学报, 2006(4): 1010-1014. doi: 10.3969/j.issn.1004-731X.2006.04.050
      [16] 吴烽云, 张坡, 邹湘军, 等. 基于复杂部件虚拟装配的智能决策行为[J]. 自动化与信息工程, 2019, 40(5): 1-5. doi: 10.3969/j.issn.1674-2605.2019.05.001
      [17]

      ZOU X, HE H, WU Y, et al. Automatic 3D point cloud registration algorithm based on triangle similarity ratio consistency[J]. IET Image Processing, 2020, 14(14): 3314-3323.

      [18] 高伟, 王昱霖, 宋笑迎, 等. 基于虚拟现实技术下深度学习环境的构建研究[J]. 软件, 2019, 40(5): 42-46. doi: 10.3969/j.issn.1003-6970.2019.05.009
      [19] 梁锋, 钟建强, 罗培锋, 等. CATIA VBA二次开发在装配中批量搜索零件的应用[J]. 汽车实用技术, 2021, 46(1): 32-35.
      [20] 齐江飞, 戈北京, 范颖超, 等. Inventor图纸编号和名称批量自动更改方法研究与应用[J]. 科技创新与应用, 2020(4): 167-169.
      [21] 赵仁兵, 刘金科. 基于Unigraphics NX二次开发功能的批量后置软件[J]. 机械制造, 2020, 58(11): 53-58. doi: 10.3969/j.issn.1000-4998.2020.11.016
      [22] 郭鹏, 张新艳, 余建波. 基于深度强化学习与有限元仿真集成的拉深成形控制[J]. 机械工程学报, 2020, 56(20): 47-58.
      [23] 康文利, 周学辉. 虚拟装配快速碰撞干涉检验算法的研究[J]. 机械工程与自动化, 2010(4): 53-55. doi: 10.3969/j.issn.1672-6413.2010.04.019
      [24] 张炫, 杨艳. 基于改进随机霍夫变换的直线提取算法[J]. 信息技术, 2017(12): 6-9.
      [25] 张天煜, 冯华君, 徐之海, 等. 基于强边缘宽度直方图的图像清晰度指标[J]. 浙江大学学报(工学版), 2014, 48(2): 312-320.
    图(17)  /  表(3)
    计量
    • 文章访问数:  733
    • HTML全文浏览量:  12
    • PDF下载量:  651
    • 被引次数: 0
    出版历程
    • 收稿日期:  2021-04-06
    • 网络出版日期:  2023-05-17
    • 刊出日期:  2021-11-09

    目录

      /

      返回文章
      返回