CN-121999232-A - Tunnel water inrush measurement method based on multi-view fusion and optical flow field calculation
Abstract
A tunnel water burst measuring method based on multi-view fusion and optical flow field calculation relates to the technical field of image recognition, and comprises the steps of shooting a tunnel face water burst video, performing image frame extraction on the obtained video, preprocessing a frame image, establishing a tunnel face image dataset, marking and data enhancement on the preprocessed image, training a U-Net semantic segmentation model to recognize a water burst area image in the image dataset, calculating adjacent frame pixel displacement fields in the water burst area image by adopting a RAFT optical flow model, extracting a multi-view effective flow velocity vector field, merging the multi-view effective flow velocity vector field, and calculating water burst quantity of the face.
Inventors
- XU BINGXUE
- XIA QIANG
- XU ZHENGXUAN
- MAO BANGYAN
- DENG JIAN
- HOU ZEYU
- XU YUYAO
- Cao Canyang
Assignees
- 成都理工大学
Dates
- Publication Date
- 20260508
- Application Date
- 20260410
Claims (9)
- 1. The tunnel water burst measuring method based on multi-view fusion and optical flow field calculation is characterized by comprising the following steps of: S1, shooting a multi-view video of water inrush of a tunnel face; s2, performing image frame extraction on the obtained video, preprocessing the frame extracted image, and establishing a tunnel face image data set; s3, marking and data enhancement are carried out on the preprocessed image, and a U-Net semantic segmentation model is trained to identify an image of a water inrush region in an image dataset; S4, calculating pixel displacement fields of adjacent frames in the image of the water inrush area in the image by adopting a RAFT optical flow model, and extracting a multi-view effective flow velocity vector field; and S5, merging the multi-view effective flow velocity vector fields, and calculating to obtain the water inflow of the face.
- 2. The tunnel water burst measurement method based on multi-view fusion and optical flow field calculation of claim 1, wherein the multi-view water burst video is synchronously shot by a three-view camera, the video type is conventional image video and/or infrared imaging video, the resolution of the conventional image video is not lower than 1024×1024, and the video frame rate is not lower than 30fps.
- 3. The tunnel water inrush measurement method based on multi-view fusion and optical flow field calculation of claim 2, wherein the arrangement positions of the three-view cameras are respectively a position of a right opposite face of the water outflow of the tunnel face, a position of an included angle of 45 degrees between a shooting axis and a main axis of the water outflow of the tunnel face, a position of an included angle of 90 degrees between the shooting axis and the main axis of the water outflow of the tunnel face, and the distance between the cameras and the tunnel face is 10m.
- 4. The tunnel water inrush measurement method based on multi-view fusion and optical flow field calculation of claim 1, wherein the specific steps of frame extraction and preprocessing in step S2 are that OpenCV is adopted to read the frame rate and total frame number of video, video images are extracted frame by frame to form an original image sequence, and gaussian filtering noise reduction, smoothing, sharpening, normalization and size alignment are performed on the original image sequence to obtain a tunnel face water inrush image dataset.
- 5. The method for measuring the water inrush of the tunnel based on multi-view fusion and optical flow field calculation of claim 4, wherein the specific steps of step S3 are as follows: S31, labeling pictures in a water inrush image dataset of a tunnel face, obtaining a labeling file of the water inrush region, and converting labeling batches into semantic segmentation masks corresponding to the original images one by one; Step S32, carrying out synchronous data enhancement on the image and the mask to obtain an image-mask data set; s33, establishing a U-Net semantic segmentation model, wherein the model is input into a tunnel face water inrush image with normalized and aligned size, and the model is output into a single-channel water inrush probability map with the same size as the input; step S34, reading data in the 'image-mask' data set as a training set and a verification set to train a U-Net semantic segmentation model, and deriving a model weight file as a segmentation model of the tunnel water inrush scene after training is completed; and step S35, inputting the image which is not used for training in the image data set obtained in the step S2 into a trained U-Net model to obtain a pixel level water inrush probability map, thresholding the segmentation probability map, and screening through morphology and connected domains to obtain a water inrush binary mask.
- 6. The method for tunnel water inrush measurement based on multi-view fusion and optical flow field calculation of claim 5, wherein the training set, the verification set and the test set are in a ratio of 7:2:1 in the training process in step S34.
- 7. The method for measuring the water inrush of the tunnel based on multi-view fusion and optical flow field calculation of claim 5, wherein the specific steps of step S5 are as follows: Step S51, mapping the multi-view effective flow velocity vector field to the same reference plane according to camera calibration parameters based on the gushing water semantic segmentation mask obtained in the step S31 and the multi-view effective flow velocity vector field obtained in the step S4, and obtaining a speed field and a mask of each view on the reference plane; step S52, calculating a multi-view normalized scaling factor of each pixel, wherein the multi-view normalized scaling factor is represented by the following formula: wherein i, j and k respectively represent the ith, j and k viewing angles; Representing the normalized scaling factor of pixel x at the ith viewing angle; Representing the unnormalized contribution degree of the pixel x to the fusion result under the ith view angle; the pixel x of the ith view angle on the reference plane obtained in the step S3 is the probability confidence coefficient of water inrush, k i represents the absolute value of the cosine value of the normal included angle between the line of sight of the view angle i and the reference plane, and alpha and beta represent weight coefficients, wherein alpha is [1,2], and beta is [0.5,1.5]; Step S53, calculating a fusion speed field according to pixel weighted summation in the water inrush area segmented by the U-Net, wherein the calculation formula of the fusion speed field is shown as follows: in the formula, A reference plane velocity field representing a viewing angle i; S54, setting a hydraulic control surface in a water burst area segmented by U-Net, calculating the normal speed of a section, and performing discrete integration according to the water burst type to obtain the instantaneous water burst quantity; The method for calculating the normal speed of the section is shown as the following formula: Wherein V n (x) represents the section normal velocity of the hydraulic control surface, n represents the normal unit vector of the hydraulic control surface; The water burst type comprises bulk water and strand water, and the calculation method of the instantaneous water burst amount of the bulk water is shown as follows: Wherein Q 1 represents the instantaneous water inflow of the bulk water, h (x) represents the water film thickness measured by a side view camera, S ref represents the pixel-physical scale; The calculation method of the instantaneous water inflow of the strand-shaped water is shown as follows: wherein Q 2 represents the instantaneous water inflow of the strand-like water; Mean normal velocity on the cross section, and A the circular cross-sectional area of the gush of water spray.
- 8. The method for measuring water gushing in a tunnel according to claim 7, wherein in step S51, the reference plane is a tunnel face in which water gushing occurs.
- 9. The method for tunnel water inrush measurement based on multi-view fusion and optical flow field calculation of claim 7, wherein in step S4, robust filtering and smoothing of abnormal vectors are required, and the method comprises removing extreme outlier magnitude and applying And (5) median filtering.
Description
Tunnel water inrush measurement method based on multi-view fusion and optical flow field calculation Technical Field The invention relates to the technical field of image recognition, in particular to a tunnel water inrush measurement method based on multi-view fusion and optical flow field calculation. Background In the tunnel construction stage, the tunnel face gushing water has obvious influence on engineering safety and structural stability. Traditional water inflow monitoring mainly relies on manual observation and measurement, is low in efficiency and limited in precision, and has potential safety hazards that personnel approach the face to operate. In recent years, partial researches try to realize non-contact flow calculation by using methods such as video processing, optical flow analysis or particle image velocimetry, and the like, but the method still has the limitations that firstly, single-view acquired information is insufficient and the spatial characteristics of water burst are difficult to comprehensively reflect, secondly, the traditional optical flow algorithm has poor robustness under low texture and complex background, the flow velocity estimation error is large, and thirdly, most methods stay on a flow field visual layer and cannot be effectively combined with actual water burst measurement of a tunnel face. In view of this, a comprehensive method with multi-view observation, automatic segmentation recognition and high-precision flow measurement and calculation is needed to realize non-contact, automatic and fine measurement and calculation of the water inflow of tunnel face, and provide technical support for tunnel construction and operation safety monitoring. Disclosure of Invention In view of the above, the invention provides a tunnel water inrush measurement method based on multi-view fusion and optical flow field calculation, which utilizes a deep learning segmentation model to realize automatic extraction of water inrush areas, and combines an advanced optical flow field calculation model to accurately invert the water flow speed, thereby realizing non-contact, high-precision and automatic measurement and calculation of water inrush of tunnel face, improving measurement efficiency and safety, and solving the problems mentioned in the background art. In order to solve at least one technical problem, the technical scheme provided by the invention is that a tunnel water inrush measurement method based on multi-view fusion and optical flow field calculation comprises the following steps: S1, shooting multi-view video of a tunnel face; s2, performing image frame extraction on the obtained video, preprocessing the frame extracted image, and establishing a tunnel face image data set; S3, labeling the water burst image in the data set, and training a U-Net semantic segmentation model to identify the water burst area image in the image data set; s4, calculating pixel displacement fields of adjacent frames in the image of the water inrush region by adopting a RAFT optical flow model, and extracting a multi-view effective flow velocity vector field; and S5, merging the multi-view effective flow velocity vector fields, and calculating to obtain the water inflow of the face. The invention has the technical effects that: According to the invention, the multi-view imaging is adopted to divide the water inrush area at the pixel level by adopting U-Net, the speed is measured by using the RAFT optical flow restrained by the mask, the speed is unified to the reference plane, the weight fusion is carried out according to the division confidence degree and the included angle between the sight line and the tunnel face, objective, continuous and non-contact measurement and calculation of the water inrush amount of the tunnel face are realized by combining the calibration parameters and the pixel-physical scale, the influence of complex working conditions such as insufficient illumination, reflection, local shielding and the like in a tunnel can be overcome, and the accuracy and the stability of the result are improved. Drawings In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings that are needed in the embodiments will be briefly described below, it being understood that the following drawings only illustrate some examples of the present invention and therefore should not be considered as limiting the scope, and other related drawings may be obtained according to these drawings without inventive effort for a person skilled in the art. FIG. 1 is an overall flow chart of the present invention; FIG. 2 is a diagram of an experimental apparatus of the present example; FIG. 3 is a diagram of a binarized image of a water inrush probability map obtained by inputting a U-Net model in an embodiment of the present invention. Detailed Description The present invention will be described in further detail with reference to examples and drawings. For th