Camera Calibration Using Cross-Section Waterline Orientation for Video-based Flow Measurement
-
摘要: 针对现有基于直接线性变化法(DLT)的图像法测流技术依赖于地面控制点,存在效率低、风险高、宽断面天然河流操作难度大等问题,该文提出一种基于断面水边线定向的摄像机姿态角标定方法(CSWO)。该方法将标定过程分解为实验室内参标定和现场外参标定两步,其中后者又被划分为摄像机定位和定向两个环节。定向环节中首先在摄像机安装时将光轴与断面方向对齐,使方位角置零。然后利用无畸变图像中人工标注的平直断面水边线的斜率计算出横滚角。接下来通过计算水边线与图像纵轴交点作为其亚像素像方坐标。最后依据透视投影成像模型,联合水位与插值断面高程求得的物方坐标解算出俯仰角。该方法应用于时空图像测速法(STIV),实现了200 m宽河流的免像控表面流速测量。结果表明:起点距的最大绝对误差为0.59 m,最大相对误差为0.45%,表面流速的最大相对误差小于6.3%。Abstract: The image-based water flow measurement technology based on the Direct Linear Transformation (DLT) method relies on ground control points, and has problems such as low efficiency, high risk, and difficult operation in natural rivers with wide sections. A camera attitude angle calibration method based on Cross-Section Waterline Orientation (CSWO) is proposed. In this method, the calibration process is divided into two steps: laboratory calibration and field calibration, and the latter is divided into camera positioning and orientation. In the orientation step, the optical axis is required to be aligned with the cross-section when the camera is installed, so that the azimuth angle is set to zero. The roll angle is calculated by the slope of the straight waterline marked manually in the undistorted image. Then the sub-pixel image coordinate of the intersection point between the waterline and the vertical axis of the image is calculated. Finally, the pitch angle is calculated according to the perspective projection imaging model combined with the object coordinates obtained by the water level and the interpolated elevation of cross-section. This method has been applied to Space-Time Image Velocimetry (STIV) to measure the image-free surface velocity of a river with a width of 200 m. The results show that the maximum absolute error of starting distance is 0.59 m, the maximum relative error is 0.45%, and the maximum relative error of surface velocity is less than 6.3%.
-
表 1 内参矩阵和畸变参数
$ m $(pixel) $ n $(pixel) $ {f_x} $(pixel) $ {f_y} $(pixel) $ {C_x} $(pixel) $ {C_y} $(pixel) $ {k_1} $ $ {k_2} $ $ {p_1} $ $ {p_2} $ 标定结果 3840 2160 2876.507 2884.631 1947.382 1043.743 –0.407 0.001 0.001 –0.001 表 2 各水位级下俯仰角、横滚角标定结果对比
测次 日期 时间 场景 水位级 水位(m) $ R\left(x_{1}, y_{1}\right) $ $ R_{2}\left(x_{2}, y_{2}\right) $ 俯仰角(°) 横滚角(°) 1 210407 15:00 晴 低 985.34 (990, 443) (2071, 435) 20.16 0.42 2 210204 10:30 晴 986.19 (982, 445) (2125, 441) 19.70 0.20 3 210416 20:05 夜 986.34 (984, 439) (2127, 433) 19.79 0.30 4 210416 20:10 夜 986.34 (984, 439) (2125, 431) 19.81 0.40 5 201118 10:30 阴 986.37 (960, 437) (2151, 429) 19.84 0.39 6 201118 10:35 阴 986.37 (966, 437) (2143, 431) 19.81 0.29 7 210415 14:18 晴 986.37 (984, 437) (2141, 427) 19.87 0.50 8 210318 9:00 阴 986.40 (978, 437) (2027, 427) 19.88 0.55 9 210414 13:00 晴 986.42 (984, 437) (2141, 431) 19.79 0.30 10 210408 14:00 晴 986.42 (1006, 439) (2079, 429) 19.82 0.53 11 210408 16:00 晴 986.62 (974, 437) (2187, 431) 19.79 0.28 12 210316 9:00 阴 986.90 (978, 427) (2143, 419) 19.81 0.39 13 210223 11:00 晴 987.03 (982, 423) (2095, 415) 19.84 0.41 14 220704 9:35 阴 中 993.80 (1100, 257) (2057, 255) 19.91 0.12 15 220704 9:20 阴 993.84 (1096, 257) (2073, 255) 19.89 0.12 16 220704 9:26 阴 993.85 (1092, 257) (2071, 255) 19.89 0.12 17 200821 10:00 阴 高 997.96 (1008, 206) (1824, 202) 19.88 0.28 表 3 DSO法和CSWO法实验结果
测次 水位(m) 起点距真值(m) 绝对误差(m) 相对误差(%) DSO CSWO DSO CSWO 1 985.34 55.00 0.29 0.02 0.22 0.02 2 986.19 90.00 0.64 0.12 0.51 0.09 3 986.34 65.00 0.24 0.18 0.18 0.14 4 986.34 90.00 0.81 0.02 0.62 0.01 5 986.37 55.00 0.13 0.17 0.10 0.13 6 986.37 65.00 0.64 0.23 0.50 0.18 7 986.37 90.00 0.79 0.01 0.61 0.01 8 986.40 120.00 1.64 0.27 1.27 0.21 9 986.42 65.00 0.34 0.09 0.26 0.07 10 986.42 105.00 0.94 0.13 0.72 0.10 11 986.62 135.00 1.18 0.59 0.90 0.45 12 986.90 65.00 0.26 0.28 0.19 0.21 13 987.03 90.00 0.72 0.19 0.55 0.15 14 993.80 90.00 0.97 0.29 0.57 0.17 15 993.84 55.00 0.42 0.05 0.25 0.03 16 993.85 65.00 0.66 0.00 0.39 0.00 17 997.96 55.00 0.31 0.28 0.17 0.15 -
[1] LE COZ J, HAUET A, PIERREFEU G, et al. Performance of Image-based Velocimetry (LSPIV) applied to flash-flood discharge measurements in mediterranean rivers[J]. Journal of Hydrology, 2010, 394(1/2): 42–52. doi: 10.1016/j.jhydrol.2010.05.049. [2] FUJITA I, WATANABE H, and TSUBAKI R. Development of a non-intrusive and efficient flow monitoring technique: The Space-Time Image Velocimetry (STIV)[J]. International Journal of River Basin Management, 2007, 5(2): 105–114. doi: 10.1080/15715124.2007.9635310. [3] TAURO F, TOSI F, MATTOCCIA S, et al. Optical Tracking Velocimetry (OTV): Leveraging optical flow and trajectory-based filtering for surface streamflow observations[J]. Remote Sensing, 2018, 10(12): 2010. doi: 10.3390/rs10122010. [4] 张振, 徐枫, 王鑫, 等. 河流水面成像测速研究进展[J]. 仪器仪表学报, 2015, 36(7): 1441–1450. doi: 10.19650/j.cnki.cjsi.2015.07.001.ZHANG Zhen, XU Feng, WANG Xin, et al. Research progress on river surface imaging velocimetry[J]. Chinese Journal of Scientific Instrument, 2015, 36(7): 1441–1450. doi: 10.19650/j.cnki.cjsi.2015.07.001. [5] 蒋海军. 大视场条件下的摄像机标定方法研究[D]. [硕士论文], 国防科技大学, 2017. doi: 10.27052/d.cnki.gzjgu.2017.000625.JIANG Haijun. Research on camera calibration method in large field of view[D]. [Master dissertation], National University of Defense Technology, 2017. doi: 10.27052/d.cnki.gzjgu.2017.000625. [6] 张振, 徐枫, 沈洁, 等. 基于变高单应的单目视觉平面测量方法[J]. 仪器仪表学报, 2014, 35(8): 1860–1868. doi: 10.19650/j.cnki.cjsi.2014.08.025.ZHANG Zhen, XU Feng, SHEN Jie, et al. Plane measurement method with monocular vision based on variable-height homography[J]. Chinese Journal of Scientific Instrument, 2014, 35(8): 1860–1868. doi: 10.19650/j.cnki.cjsi.2014.08.025. [7] 杨聃, 邵广俊, 胡伟飞, 等. 基于图像的河流表面测速研究综述[J]. 浙江大学学报:工学版, 2021, 55(9): 1752–1763. doi: 10.3785/j.issn.1008-973X.2021.09.017.YANG Dan, SHAO Guangjun, HU Weifei, et al. Review of image-based river surface velocimetry research[J]. Journal of Zhejiang University:Engineering Science, 2021, 55(9): 1752–1763. doi: 10.3785/j.issn.1008-973X.2021.09.017. [8] AL-MAMARI M M, KANTOUSH S A, KOBAYASHI S, et al. Real-time measurement of flash-flood in a Wadi area by LSPIV and STIV[J]. Hydrology, 2019, 6(1): 27. doi: 10.3390/hydrology6010027. [9] 曹列凯, DETERT M, 李丹勋. 基于无人机的长河段表面流场测量系统与应用[J]. 清华大学学报:自然科学版, 2022, 62(12): 1922–1929. doi: 10.16511/j.cnki.qhdxxb.2022.21.012.CAO Liekai, DETERT M, and LI Danxun. Airborne image velocimetry system and its application to measure the surface flow fields of long river reaches[J]. Journal of Tsinghua University:Science and Technology, 2022, 62(12): 1922–1929. doi: 10.16511/j.cnki.qhdxxb.2022.21.012. [10] TSAI R. A versatile camera calibration technique for high-accuracy 3D machine vision metrology using off-the-shelf TV cameras and lenses[J]. IEEE Journal on Robotics and Automation, 1987, 3(4): 323–344. doi: 10.1109/JRA.1987.1087109. [11] HOLLAND K T, HOLMAN R A, LIPPMANN T C, et al. Practical use of video imagery in nearshore oceanographic field studies[J]. IEEE Journal of Oceanic Engineering, 1997, 22(1): 81–92. doi: 10.1109/48.557542. [12] BECHLE A J, WU C H, LIU Wencheng, et al. Development and application of an automated river-estuary discharge imaging system[J]. Journal of Hydraulic Engineering, 2012, 138(4): 327–339. doi: 10.1061/(ASCE)HY.1943-7900.0000521. [13] HUANG Weiche, YOUNG C C, and LIU Wencheng. Application of an automated discharge imaging system and LSPIV during typhoon events in Taiwan[J]. Water, 2018, 10(3): 280. doi: 10.20944/preprints201802.0089.v1. [14] COSTA F A L and MITISHITA E A. An approach to improve direct sensor orientation using the integration of photogrammetric and lidar datasets[J]. International Journal of Remote Sensing, 2019, 40(14): 5651–5672. doi: 10.1080/01431161.2019.1580794. [15] ZHANG Zhen, ZHAO Lijun, LIU Boyuan, et al. Free-surface velocity measurement using direct sensor orientation-based STIV[J]. Micromachines, 2022, 13(8): 1167. doi: 10.3390/mi13081167. [16] LIU Wencheng and HUANG Weiche. Development of a three-axis accelerometer and Large-Scale Particle Image Velocimetry (LSPIV) to enhance surface velocity measurements in rivers[J]. Computers & Geosciences, 2021, 155: 104866. doi: 10.1016/j.cageo.2021.104866. [17] 张振, 吕莉, 石爱业, 等. 基于物像尺度变换的河流水面流场定标方法[J]. 仪器仪表学报, 2017, 38(9): 2273–2281. doi: 10.19650/j.cnki.cjsi.2017.09.023.ZHANG Zhen, LV Li, SHI Aiye, et al. River surface flow field calibration method based on object-image scaling[J]. Chinese Journal of Scientific Instrument, 2017, 38(9): 2273–2281. doi: 10.19650/j.cnki.cjsi.2017.09.023. [18] TSUBAKI R. On the texture angle detection used in Space-Time Image Velocimetry (STIV)[J]. Water Resources Research, 2017, 53(12): 10908–10914. doi: 10.1002/2017WR021913. [19] FUJITA I, KOSAKA Y, and YOROZUYA A. Tracking of river surface features by space time imageing[C]. The 15th International Symposium on Flow Visualization, Minsk, Belarus, 2012: 25–28. [20] ZHANG Zhen, ZHOU Yang, LIU Haiyun, et al. Visual measurement of water level under complex illumination conditions[J]. Sensors, 2019, 19(19): 4141. doi: 10.3390/s19194141. [21] 王慧斌, 董伟, 张振, 等. 基于时空图像频谱的时均流场重建方法[J]. 仪器仪表学报, 2015, 36(3): 623–631. doi: 10.19650/j.cnki.cjsi.2015.03.018.WANG Huibin, DONG Wei, ZHANG Zhen, et al. Time-averaged flow field reconstruction method based on spectrum of spatio-temporal image[J]. Chinese Journal of Scientific Instrument, 2015, 36(3): 623–631. doi: 10.19650/j.cnki.cjsi.2015.03.018. [22] ZHANG Zhengyou. A flexible new technique for camera calibration[J]. IEEE Transactions on Pattern Analysis and Machine Intelligence, 2000, 22(11): 1330–1334. doi: 10.1109/34.888718. [23] FUJITA I, NOTOYA Y, TANI K, et al. Efficient and accurate estimation of water surface velocity in STIV[J]. Environmental Fluid Mechanics, 2019, 19(5): 1363–1378. doi: 10.1007/s10652-018-9651-3. [24] 赵浩源, 陈华, 刘维高, 等. 基于河流表面时空图像识别的测流方法[J]. 水资源研究, 2020, 9(1): 1–11. doi: 10.12677/JWRR.2020.91001.ZHAO Haoyuan, CHEN Hua, LIU Weigao, et al. Application of flow measurement method based on space-time image recognition of river surface[J]. Journal of Water Resources Research, 2020, 9(1): 1–11. doi: 10.12677/JWRR.2020.91001.