3D point cloud segmentation algorithm based on fused DenseNet and PointNet
-
摘要:
点云分割对于智能驾驶、物体检测和识别、逆向工程等任务非常重要。PointNet是一种能够直接处理点云数据的方法,近年来在点云分割任务中得到广泛应用,但其分割精度较低,而PointNet++的计算成本又较高。针对以上问题,提出一种融合DenseNet和PointNet的算法,用于点云分割,并引入三分支混合注意力机制,以提高PointNet在提取局部特征方面的能力。基于密集连接卷积网络(DenseNet)思想,提出用DenseNet-STN和DenseNet-MLP结构来替代PointNet中的空间变换网络(STN)和多层感知机(MLP);同时,使用Add连接代替密集块(DenseBlock)中的Concat连接,以提高对点特征间相关性的准确性,同时不显著增加模型复杂度。DenseNet-PointNet能够提高复杂分类问题的泛化能力,实现对复杂函数更好的逼近,从而提高点云分割的准确率。有效性和消融实验结果表明,本文算法具有良好的性能。点云分割实验结果表明,DenseNet-PointNet在大多数类别中的交并比(IoU)都高于PointNet的IoU,并在部分类别中也高于PointNet++,参数量是PointNet++的47.6%,浮点运算量(FLOPs)是PointNet++的49.1%。实验结果验证了DenseNet-PointNet的可行性和有效性。
-
关键词:
- 点云分割 /
- 密集连接卷积网络 /
- PointNet /
- DenseNet-PointNet
Abstract:Point cloud segmentation is crucial for key tasks, including intelligent driving, object recognition and detection, as well as reverse engineering. PointNet represents a direct point cloud data processing approach widely utilized in point cloud segmentation tasks. Nevertheless, it is associated with low segmentation accuracy and the computational cost of PointNet++ is high. Aiming at the above problems, an algorithm combining DenseNet and PointNet was proposed for the segmentation of point clouds. A three-branch hybrid attention mechanism was introduced to enhance PointNet capability to extract local features. DenseNet-STN and DenseNet-MLP structures were proposed to substitute spatial transformation networks (STNs) and multi-layer perceptrons (MLPs) in PointNet, in line with the dense connected convolutional networks (DenseNet) concept. At the same time, the add connection in DenseBlock, rather than the Concat connection, to enhance the accuracy of point feature correlation, without imposing significant complexity to the model. DenseNet-PointNet demonstrates effective generalization ability for complex classification problems and facilitates better function approximation, thereby improving the precision of point cloud segmentation. The findings of the effectiveness and ablation experiments show that the proposed algorithm performs well. The results of the point cloud segmentation experiments indicate that the intersection and concatenation ratio (IoU) of DenseNet-PointNet is superior to that of PointNet in most categories, and also higher than that of PointNet++ in some categories. DenseNet-PointNet achieves this with only 47.6% of the parameters of PointNet++, and 49.1% of the floating point operations (FLOPs). Therefore, these experimental results confirm the feasibility and availability of DenseNet-PointNet.
-
引言
随着自由曲面技术和精密制造技术的快速发展,出现了多种复杂屈光度分布的多焦点镜片。渐进多焦点镜片作为一种特殊的多焦点镜片,具有非旋转对称性和渐变的屈光度分布,能够弥补传统的球面和非球面镜片无法同时视远及视近的缺陷[1-2]。然而,由于其复杂的曲面面形设计及加工工艺,现有的检测标准和检测设备均不适用于评价渐进多焦点镜片的成像质量[3]。
波前像差的测量在渐进多焦点镜片的加工设计及成像质量评价中具有重要作用。由于被测镜片的直径通常大于波前传感器接收孔径,目前主要是利用子孔径拼接的方法测量镜片的波前像差信息。该方法主要是将大口径镜片划分为多个测量子区域,利用小口径传感器分别实现子区域波前像差的检测。通过最小二乘法得到各自子波面的拼接参数,再利用波前重构复原出整片镜片的波前像差,这种测量方法对于仪器精度要求较高,测量过程及数据处理较为繁琐。本文提出一种渐进多焦点镜片波前像差的扩束测量方法,该方法操作便捷,测量效率高,能高效地实现对渐进多焦点镜片波前像差分布信息的测量。
1 镜片波前像差的测量方法
1.1 哈特曼-夏克波前传感器测量原理
Hartmann-Shack(H-S)传感器的核心部件是微透镜阵列和CCD探测器[4]。当有光波入射到H-S波前传感器时,微透镜阵列将对波前信息进行采集,每个微透镜在CCD探测器表面上会产生一个光斑,光斑质心位置取决于微透镜区域前的波前倾斜。如果入射光波是平面波,产生的光斑呈规则状排列,这时的光斑称为参考光斑,如图 1所示。如果入射光波含有像差,产生的光斑就会产生偏离,这时的光斑称为实际光斑。
H-S传感器工作原理示意图如图 2所示,当实际入射波与参考平面波之间在y轴上存在夹角αy时,实际光斑与参考光斑在y轴上产生的偏移为Δy,用波前相位表示,则测量得到的实际波前与参考波前之间光斑的偏移量与局部波前斜率的关系可以表达为
$$ ~\frac{\partial }{\partial y}W\left( x, y \right)=~\frac{\Delta y}{{{f}_{L}}}~\text{tan}{{\alpha }_{y}}~ $$ (1) 同上述原理,在x轴方向上,光斑的偏移量与局部波前斜率的关系可以表达为
$$ \frac{\partial }{\partial x}W\left( x, y \right)=~\frac{\Delta x}{{{f}_{L}}}=\text{tan}{{\alpha }_{x}} $$ (2) 式中fL为微透镜与CCD探测器之间的距离,通常是微透镜的焦距。
由于Zernike多项式在单位圆内具有正交和归一化性质,使得其在波前重构中具有广泛的应用,测得的波前斜率可以复原成Zernike多项式的各阶系数[5-6],用模式法重构得到的镜片波前像差表示为
$$ W\left( x, y \right)=\sum\limits_{k=1}^{n}{{{c}_{k}}{{z}_{k}}(x, y)}\text{ }~ $$ (3) 1.2 波前像差的扩束-缩束测量方法
由于激光传感器发射的激光光斑直径和H-S波前传感器接收口径均较小,分别选用扩束系统和缩束系统搭建测量光路,使得激光传感器发射的激光光束经过扩束系统后出射的光束直径与待测渐进多焦点镜片直径相配合,出射缩束系统后的光束直径与哈特曼-夏克波前传感器接收口径相配合。
设计的渐进多焦点镜片波前像差测量原理如图 3所示,其中L0是准直镜,L1、L2和L3组成可变焦扩束系统,L4是待测渐进多焦点镜片,L5是缩束镜。激光传感器发射的波面经过准直、扩束后覆盖待测渐进多焦点镜片的中心区域,波面透射待测渐进多焦点镜片后再经过缩束镜入射哈特曼波前传感器。
Taylor多项式在表示光学系统函数上有着重要的应用,波前像差可以用Taylor多项式展开,代表离焦项的Taylor多项式系数可以转化为传统屈光度参数中的球镜度数[7-8],即有关系式:
$$ S={{W}_{4}}+{{W}_{6}}-\frac{2\text{ }\sqrt{\left[ {{\left( {{W}_{6}}-{{W}_{4}} \right)}^{2}}+W_{5}^{2} \right]}}{2}\text{ }~ $$ (4) 式中:S表示传统屈光度参数中的球镜度数,单位为m-1;W4、W5和W6为Taylor多项式的系数。
由于Zernike多项式的正交归一化及系数便于与初级像差转换等一系列优点,现今主要用Zernike多项式表示波前像差,Taylor多项式系数可与Zernike多项式系数之间相互转换[9]。
屈光度参数中的球镜度数S与Zernike多项式系数的关系为
$$ S=-\frac{2}{{{R}^{2}}}(2{{C}_{4}}-6{{C}_{12}}-\sqrt{C_{3}^{2}+C_{5}^{2}}~) $$ (5) 式中:C4、C5、C6和C12为Zernike多项式系数;R为瞳孔半径。
2 镜片的波前像差测量实验及结果分析
按照设计的渐进多焦点镜片波前像差测量系统光路搭建的实验装置如图 4所示。测量实验选取直径70 mm、屈光度参数为BASE-1.00D+ADD1.50D的外渐进多焦点镜片,调节位于精密导轨上的H-S波前传感器与缩束镜间的距离为157 mm。开始测量后,波长为655 nm的单模光纤耦合输出激光传感器发射光斑直径为2.2 mm的光束,光束经过准直后入射扩束比为10:1的扩束系统。经过扩束系统后的平行光束照射该片渐进多焦点镜片的中央直径为22 mm的圆形区域,接着出射光束经过焦距为175 mm的缩束镜后被入瞳直径为3.5 mm的H-S波前传感器接收检测。
实验测得的渐进多焦点镜片的波前像差如图 5所示,测得的镜片波前像差的Zernike多项式表述中前四阶系数如表 1所示。从图 5和表 1中可以发现,镜片的波前像差主要由平移项、X及Y向倾斜项、0°及45°向像散项和离焦项组成,其余项对镜片像差影响较小。将各阶系数代入(4)式,即能得到渐进多焦点镜片波前像差的Zernike多项式表述。
表 1 Zernike多项式前四阶系数Table 1. First four order coefficients of Zernike polynomial序列号 阶 频 系数 类型 1 0 0 7.795 波面平移 2 1 -1 -1-- Y向倾斜 2.7 3 1 1 -1.365 X向倾斜 4 2 -2 -0.161 45°向像散 5 2 0 -0.239 离焦 6 2 2 -0.036 0°向像散 7 3 -3 -0.011 Y向三叶草 8 3 -1 -0.004 X向彗差 9 3 1 0.01 Y向彗差 10 3 3 -0.005 X向三叶草 11 4 -4 -0.001 Y向四频像差 12 4 -2 -0.001 Y向次级像散 13 4 0 0.01 三阶球差 14 4 2 -0.007 X向次级像散 15 4 4 0.001 X向四频像差 为了验证实验测量结果的准确性,设计对比试验,将镜片波前像差Zernike表述中的离焦项转换为球镜度后与传统方法测量得到的屈光度参数中的球镜度进行对比。H-S波前传感器测量得到镜片的波前像差Zernike表述中离焦项如图 6所示。将离焦项系数代入公式(9)得到镜片每个区域的球镜度,然后利用Matlab进行插值拟合,得到渐进多焦点镜片中间区域的球镜度分布如图 7所示。在渐进多焦点镜片的视远区中心点,镜片的球镜度约为-1.0 D,在视近区中心点,镜片的球镜度约为0.50 D。利用条纹偏折法测量该片渐进多焦点镜片[10-11],得到整片渐进多焦点镜片的球镜度分布图如图 8所示,在视远区中心点,镜片的球镜度为-1.1 D,在视近区中心点,镜片的球镜度为0.49 D。
采用两种不同的测量方法测量同一块渐进多焦点镜片,从图 7和图 8可以看出,两种检测结果得到渐进多焦点镜片渐变区直径为22 mm的圆形区域内的球镜度均是从约0.50 D递减到约为-1.0 D,整体渐变趋势基本保持一致。在视远区与视近区的中心点,两种方法测量得到的球镜度数接近,说明渐进多焦点镜片波前像差的扩束测量方法得到的测量结果是可行的。
3 结论
本文根据哈德曼-夏克波前传感器的测量原理,提出了一种采用扩束-缩束系统实现渐进多焦点镜片波前像差的测量方法,进行了球镜度测量计算公式的理论推导,通过实验检测得到了渐进多焦点镜片中央直径为22 mm的圆形区域内的波前像差,并将波前像差Zernike多项式表述中的离焦项转换为球镜度后与条纹偏折法测量的结果进行对比。实验结果表明, 渐进多焦点镜片波前像差的扩束测量方法可以高效测量渐进多焦点镜片的波前像差和球镜度,原理简单且实验简便快捷。
-
表 1 4种网络架构的mIoU
Table 1 mIoU for 4 network architectures
Method Train set Test set PointNet 87.43 85.94 DSTN-PointNet 87.56 86.72 DMLP-PointNet 89.75 88.59 Ours 90.47 89.64 表 2 消融实验
Table 2 Ablation experiment
Method Accuracy Recall F1 score PointNet 0.80 0.75 0.77 + DenseNet-STN and DenseNet-MLP 0.82 0.78 0.80 + Add connection replacing
Concat connection0.85 0.81 0.83 + THAM 0.88 0.85 0.86 表 3 3个分割网络的IoU
Table 3 IoU for three segmentation networks
Method mIoU aero cap bag chair earphone knife table rocket PointNet 87.35 88.56 85.32 90.16 89.76 70.34 85.89 88.35 72.63 PointNet++ 88.17 90.63 86.45 89.26 90.72 72.82 87.54 89.69 74.06 Ours 89.46 91.34 89.15 90.84 93.85 75.76 90.26 89.10 77.35 续表 Method laptop lamp mug motorbike pistol guitar skateboard car PointNet 95.26 80.42 95.86 80.74 93.82 94.15 89.94 86.38 PointNet++ 96.42 86.26 95.43 86.08 94.69 94.89 90.03 85.76 Ours 95.96 85.43 95.22 85.87 94.02 93.96 90.15 93.04 表 4 在点云分割任务中的DenseNet-PointNet网络复杂度
Table 4 Computational complexity of DenseNet-PointNet network in point cloud segmentation task
Method Params/M FLOPs/M Train time/s Infer time/s PointNet 3.53 445 0.52±0.01 0.03±0.00 PointNet++ 12.26 1 694 1.23±0.02 0.08±0.00 Ours 6.42 862 0.84±0.01 0.05±0.00 -
[1] WU B, ZHOU X, ZHAO S, et al. Squeezesegv2: improved model structure and unsupervised domain adaptation for road-object segmentation from a lidar point cloud[C]//2019 International Conference on Robotics and Automation (ICRA). New York: IEEE, 2019: 4376-4382.
[2] LIU S, WANG Y, YANG X, et al. Deep learning in medical ultrasound analysis: a review[J]. Engineering, 2019, 5(2): 261-275. doi: 10.1016/j.eng.2018.11.020
[3] TCHAPMI L, CHOY C, ARMENI I, et al. Segcloud: semantic segmentation of 3d point clouds[C]//2017 International Conference on 3D Vision (3DV). New York: IEEE, 2017: 537-547.
[4] HU S M, CAI J X, LAI Y K. Semantic labeling and instance segmentation of 3D point clouds using patch context analysis and multiscale processing[J]. IEEE Transactions on Visualization and Computer Graphics, 2018, 26(7): 2485-2498.
[5] KALOGERAKIS E, HERTZMANN A, SINGH K. Learning 3D mesh segmentation and labeling[J]. ACM Transactions on Graphics (TOG), 2010, 29 (4) : 102: 1-12.
[6] WANG P S, LIU Y, GUO Y X, et al. O-CNN: octree-based convolutional neural networks for 3d shape analysis[J]. ACM Transactions on Graphics (TOG), 2017, 36(4): 1-11.
[7] CAO Z, HUANG Q, KARTHIK R. 3D object classification via spherical projections[C]//2017 International Conference on 3D Vision (3DV). New York: IEEE, 2017: 566-574.
[8] QI C R, SU H, MO K, et al. Pointnet: deep learning on point sets for 3d classification and segmentation[C]//Proceedings of the IEEE Conference On Computer Vision and Pattern Recognition. New York: IEEE, 2017: 652-660.
[9] DENG H, BIRDAL T, ILIC S. Ppfnet: global context aware local features for robust 3d point matching[C]//Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition. New York: IEEE, 2018: 195-205.
[10] JIANG M, WU Y, ZHAO T, et al. Pointsift: a sift-like network module for 3d point cloud semantic segmentation[EB/OL]. (2018-07-02)[2023-08-31]. http://arxiv.org/abs/1807.00652v1.
[11] QI C R, YI L, SU H, et al. Pointnet++: Deep hierarchical feature learning on point sets in a metric space[J]. Advances in Neural Information Processing Systems, 2017, 30: 1745976.
[12] HE K, ZHANG X, REN S, et al. Deep residual learning for image recognition[C]//Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition. New York: IEEE, 2016: 770-778.
[13] HUANG G, LIU Z, VAN D M L, et al. Densely connected convolutional networks[C]//Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition. New York: IEEE, 2017: 4700-4708.
[14] LEE C Y, XIE S, GALLAGHER P, et al. Deeply-supervised nets[C]//Artificial Intelligence and Statistics. [S. l. ]: PMLR, 2015: 562-570.
-
期刊类型引用(1)
1. 禹静,蒋威炜,沈小燕. 自由曲面镜片波前像差扩束-缩束拼接技术. 光子学报. 2019(08): 160-169 . 百度学术
其他类型引用(1)