A method and device for intelligently repairing low-quality images of tunnel faces
Image quality classification is performed through convolutional neural network, and light enhancement and super-resolution repair are combined with EnlightenGAN and BSRGAN models, which solves the problems of insufficient lighting and compression distortion of tunnel palm surface images, significantly improves image quality, and improves the analytical accuracy of geological information.
Patent Information
- Application Number
- CN202411086751.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-08-08
- Publication Date
- 2025-05-02
- Estimated Expiration
- 2044-08-08
AI Technical Summary
When collecting the image of the palm surface of the tunnel, there are often problems of uneven light and insufficient brightness. During the transmission process, the resolution decreases and details are lost due to compression, which affects the accurate analysis of geological information.
The DenseNet121 network based on convolutional neural network is used for image quality classification, and the EnlightenGAN and BSRGAN models are used for lighting enhancement and super-resolution repair respectively, automatically repairing low-quality images and improving the clarity and integrity of the images.
It significantly improves the quality of the tunnel palm surface image, improves the analytical accuracy of geological information, improves the efficiency of image processing and the convenience of data management, and ensures high quality and high availability of image data.
Smart Images

Figure CN119048400B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of tunnel engineering, and in particular to a method and device for intelligently repairing low-quality images of a tunnel face, which is used for automatically repairing various low-quality images taken at a tunnel construction site, thereby improving the accuracy of analyzing geological information. Background Art
[0002] With the advancement of artificial intelligence technology and the expansion of its application scope, its application in the field of civil engineering, especially in tunnel engineering, is becoming more and more extensive. Intelligent analysis of tunnel face images is becoming a key technology in intelligent tunnel construction. Using computer vision technology instead of traditional human eye observation can more efficiently and accurately analyze the geological information inside the tunnel. However, the special environmental conditions of tunnel engineering, such as insufficient light and image distortion during compression and transmission, pose a great challenge to image quality.
[0003] There is a lack of natural light inside the tunnel, and the construction site mainly relies on artificial fill lights for lighting. However, due to the fact that the layout of the fill lights is often not completely uniform and the complexity of the internal environment of the tunnel, the tunnel face image often has problems of uneven lighting and insufficient brightness during acquisition. This not only affects the visual quality of the image, but also directly affects the accuracy of subsequent geological information analysis. Insufficient lighting will make the color and structural characteristics of the rock and soil in the image unclear, which in turn affects the determination of the rock type and weathering degree.
[0004] With the development of information technology, a large number of tunnel face images collected at the tunnel construction site need to be transmitted through the network. In order to improve transmission efficiency, these images are usually compressed, which inevitably leads to a decrease in image resolution and loss of details. The color and pixel distribution in the tunnel face image are crucial for analyzing geological information. Once the image is distorted, it may lead to the inability to accurately identify important geological information, such as the width of the crack, the particle size of the rock and other subtle differences.
[0005] At present, most of the processing of low-quality images of tunnel faces is simple removal or manual repair, which is not only inefficient, but also limited by the professional skills and experience of operators. In addition, simply removing low-quality images will lead to a large amount of potentially useful geological information being ignored, thus affecting the decision-making and safety assessment of the entire project.
[0006] Therefore, how to effectively and intelligently repair low-quality tunnel face images in the tunnel to ensure image quality and accurate transmission of geological information has become a technical problem that urgently needs to be solved in tunnel engineering. Solving this problem can not only improve the safety and efficiency of tunnel construction, but also provide more scientific data support for tunnel engineering. Summary of the invention
[0007] The purpose of the present invention is to overcome the problem of insufficient illumination in the process of tunnel face image shooting and the problem of compression distortion in the transmission and storage process existing in the prior art, and to provide a method and device for intelligent repair of low-quality images of tunnel face to ensure that the collected tunnel face images have higher clarity and integrity, thereby improving the accuracy of geological information analysis.
[0008] In order to achieve the above-mentioned object of the invention, the present invention provides the following technical solutions:
[0009] S1, obtaining tunnel face images;
[0010] S2, classifying the image quality of the tunnel face image, comprising the following steps:
[0011] S21, using the DenseNet121 network based on the convolutional neural network to process and classify the tunnel face image to obtain a preliminary image classification result; and classifying the tunnel face image into high-quality images, low-resolution images, low-light images, and other types of images; the high-quality images are images whose resolution and light intensity meet preset standards; the preset standards are based on the resolution and light intensity of the images;
[0012] S22, evaluating the preliminary image classification results using the F1 score and confusion matrix;
[0013] S3, performing iterative image restoration processing on the low-quality image described in S21; automatically performing illumination enhancement on the low-light image using the EnlightenGAN model, and performing super-resolution processing on the low-resolution image using the BSRGAN model; classifying the low-quality image that meets the preset standard after iterative restoration as the high-quality image; and classifying the low-quality image that fails to meet the preset standard as other types of images;
[0014] S4. According to the image restoration result of S3, the high-quality image is stored, and the other types of images are eliminated.
[0015] The technical solution of the present invention can significantly improve the quality of tunnel face images through intelligent lighting adjustment and efficient image restoration algorithms. In addition, automated image quality classification and optimized storage strategies greatly improve the efficiency of image processing and the convenience of data management. These technical features work together to ensure the high quality and high availability of image data, provide reliable data support for tunnel construction safety, and improve the accuracy of geological information analysis.
[0016] Compared with the prior art, the present invention has the following beneficial effects:
[0017] 1. Automated image quality restoration: This invention provides an automated solution to restore low-quality tunnel face images. By using advanced convolutional neural network models, the system can automatically identify image quality issues and apply corresponding restoration techniques without manual intervention, greatly improving processing efficiency.
[0018] 2. Intelligent image quality classification: Using the DenseNet121 intelligent classification model, this system can accurately classify the quality of tunnel face images, automatically distinguish high-quality images, low-resolution images, low-light images, etc., and adopt corresponding repair strategies for different problems.
[0019] 3. Effective solution to lighting problems: EnlightenGAN lighting enhancement model solves the common problem of insufficient lighting in tunnel construction environments. This model is particularly suitable for images taken under low-light conditions and can significantly improve the visibility and quality of images.
[0020] 4. Improvement of image degradation problem: Through the BSRGAN super-resolution restoration model, the present invention can improve the quality degradation problem that may occur during image storage and transmission, especially for images with reduced resolution. This ensures that the details of the image are preserved and restored, and improves the overall quality of the image.
[0021] 5. Improve the reliability and feasibility of geological information analysis: High-quality images are the key to effective geological analysis and judgment. By improving the quality of tunnel face images, this system enhances the ability to analyze geological information and provides more reliable and accurate data support for tunnel safety detection and evaluation.
[0022] In general, the present invention not only improves the automation of image processing by integrating multiple intelligent technologies and models, but also significantly improves the quality of tunnel face images, effectively supporting the safety management and quality control of tunnel construction. These improvements significantly improve the efficiency of capturing and storing tunnel face images, providing a solid technical foundation for construction safety and accurate geological assessment. BRIEF DESCRIPTION OF THE DRAWINGS
[0023] Figure 1 Flowchart of the tunnel face image processing algorithm
[0024] Markings in the figure: 11-image acquisition module, 12-image quality classification module, 13-image restoration module, 14-image storage module.
[0025] Figure 2 This is a schematic diagram of the tunnel face image processing process.
[0026] Figure 3 Schematic diagram of confusion matrix verification for image quality classification model
[0027] Figure 4 Schematic diagram of F1 scores of each category of image quality classification model
[0028] Figure 5 This is a schematic diagram of the structure of the tunnel face image intelligent repair system.
[0029] Figure 6 Examples of images of different types of tunnel faces
[0030] Markings in the figure: (a) high-quality image; (b) low-light image; (c) low-resolution image; (d) other types of images - tunnel face occlusion; (e) other types of images - incomplete tunnel face; (f) other types of images - tunnel face spray-mix coverage.
[0031] Figure 7 Inpainting example for low-resolution images
[0032] Markings in the figure: (a) original Figure 1 ; (b) Super-resolution reconstruction Figure 1 ; (c) original Figure 2 ; (d) Super-resolution reconstruction Figure 2 (e) original Figure 3 ; (f) Super-resolution reconstruction Figure 3 (g) original Figure 4 ; (h) Super-resolution reconstruction Figure 4 ;(i)original Figure 5 ; (j) Super-resolution reconstruction Figure 5 .
[0033] Figure 8 Enhancement example for low light images
[0034] Markings in the figure: (a) original Figure 6 (b) original Figure 6 - Light enhancement; (c) Figure 7 ; (d) original Figure 7 - Light enhancement; (e) Figure 8 ; (f) Original image 8 - light enhancement; (g) Original image 9; (h) Original image 9 - light enhancement; (i) Original image 10; (j) Original image 10 - light enhancement. DETAILED DESCRIPTION
[0035] The present invention is further described in detail below in conjunction with test examples and specific implementation methods. However, this should not be understood as the scope of the above subject matter of the present invention being limited to the following embodiments, and all technologies realized based on the content of the present invention belong to the scope of the present invention.
[0036] Example 1
[0037] This embodiment provides a detailed application method of a tunnel face image intelligent restoration system, which aims to improve the quality of images collected at the tunnel construction site through an automated process, thereby improving the efficiency and safety of engineering monitoring.
[0038] S1. Image acquisition
[0039] First, an image acquisition system with a high-resolution camera is deployed at the tunnel construction site, and the system automatically acquires tunnel face images. These images capture the current construction status of the tunnel, including conditions of different lighting and viewing angles.
[0040] S2. Image quality classification
[0041] The acquired tunnel face images are then input into the image quality classification system. The system initially classifies the images into high-quality images, low-quality images, and other types of images; low-quality images are further classified into low-resolution images and low-light images. Among them, high-quality images refer to images that meet specific preset standards, are unobstructed, and can directly allow construction personnel to conduct comprehensive geological information analysis, such as lithology, degree of weathering, degree of integrity, surrounding rock grade, etc. High-quality images should show clear details and suitable lighting conditions, without obvious noise or distortion, and the colors should be natural and balanced. The preset standards further include:
[0042] (1) Resolution: The resolution of an image should reach or exceed a certain pixel density to ensure that the image is detailed and clearly visible.
[0043] (2) Light intensity: The light intensity of the image should be balanced, without overexposed or dark areas, ensuring that all important image areas can be clearly identified.
[0044] The low-resolution images do not meet the requirements in terms of pixel density or clarity. The low-light images affect the visual effect due to insufficient light. The other types of images include but are not limited to incomplete images, occlusions, or pollution. After iterative image restoration, the low-quality images that cannot meet the preset standards are also classified as other types of images. If the image is judged as other types of images by the classification model, it is directly discarded without additional processing.
[0045] S21, DenseNet121 network processing
[0046] The DenseNet121 convolutional neural network is used, which is pre-trained to process and classify tunnel face images. The network extracts image features through multi-layer convolution and pooling operations, and outputs image classification results such as high quality, low resolution, low light, etc. through a fully connected layer.
[0047] S22. Performance Evaluation
[0048] The classification results of the DenseNet121 network are evaluated, using the F1 score and confusion matrix as the main evaluation tools. This step helps confirm the accuracy of the classification and the reliability of the model, ensuring the effectiveness of subsequent processing steps.
[0049] S23. Final classification
[0050] Based on the preliminary classification results and performance evaluation data, the images are finally classified as high-quality images, low-resolution images, low-light images, or other types of images. This classification determines the subsequent image restoration strategy.
[0051] S3. Image restoration processing
[0052] According to the classification results of S2, take corresponding image restoration measures:
[0053] For low-light images, the EnlightenGAN model is used for lighting enhancement to automatically adjust the brightness and contrast of the image and improve the visibility of the image.
[0054] For low-resolution images, the BSRGAN model is used for super-resolution processing, and deep learning technology is used to improve the pixel density and detail clarity of the image.
[0055] After the above processing, the repaired image will be evaluated again for quality.
[0056] S4, image storage and elimination
[0057] Based on the repair results and re-quality assessment of S3, images that meet high quality standards will be stored for subsequent engineering analysis and monitoring records. At the same time, images that fail to meet high quality standards will be removed from the system to optimize storage resources and improve data availability.
[0058] Through the system and method described in this embodiment, the tunnel face image intelligent repair system can effectively improve the overall quality of tunnel construction images, provide accurate and reliable visual data for the engineering team, and support the improvement of construction safety and efficiency.
[0059] Example 2
[0060] The algorithm flow chart is as follows Figure 1 As shown, the whole process of intelligent repair of low-quality images of tunnel face is demonstrated. Figure 1 Each step from image acquisition to final restoration is described in detail, including the automatic classification of images, the application of different restoration models to deal with different types of quality issues, and the storage optimization process of the restored images.
[0061] S1. Image acquisition
[0062] The initial acquisition work is carried out by capturing images of the tunnel face at the tunnel construction site. This step can be integrated into a smartphone or digital camera to automatically capture images using the advanced capture functions of these devices. In order to cover different environmental conditions, four types of images are captured: high-quality images, low-resolution images, low-light images, and other types of images. During the capture process, fill lights may be used to ensure image quality, and focus and lighting may be adjusted for specific situations, such as turning off fill lights for low-light shooting, or taking low-resolution images that are not fully focused when the lights are turned off. The captured images are not stored immediately, but are directly transferred to the image quality classification module for further processing.
[0063] S2. Image quality classification
[0064] The acquired tunnel face images are then input into the image quality classification system, which initially classifies the images into high-quality images, low-quality images, and other types of images; low-quality images are further classified into low-resolution images and low-light images. Among them, high-quality images refer to images that meet specific preset standards, are unobstructed, and can directly allow construction personnel to conduct comprehensive geological information analysis, such as lithology, degree of weathering, degree of integrity, surrounding rock grade, etc. High-quality images should show clear details and suitable lighting conditions, without obvious noise or distortion, and the colors should be natural and balanced. The preset standards further include:
[0065] (1) Resolution: The resolution of an image should reach or exceed a certain pixel density to ensure that the image is detailed and clearly visible.
[0066] (2) Light intensity: The light intensity of the image should be balanced, without overexposed or dark areas, ensuring that all important image areas can be clearly identified.
[0067] The low-resolution images do not meet the requirements in terms of pixel density or clarity. The low-light images affect the visual effect due to insufficient light. The other types of images include but are not limited to incomplete images, occlusions or pollution. After iterative image restoration, the low-quality images that cannot meet the preset standards are also classified as other types of images. If the image is judged as an image of other types by the classification model, it is directly eliminated without additional processing. This classification strategy enables subsequent image restoration work to solve specific problems more specifically and improve restoration efficiency and image quality.
[0068] S21. Use of DenseNet convolutional neural network
[0069] The image quality classification model uses a trained DenseNet121 convolutional neural network to automatically identify and classify tunnel face images. These images are classified as high quality, low resolution, low light, or other classes.
[0070] DenseNet121 performs convolution operations, pooling operations, full connection operations, and ReLu activation, as shown in formulas (1) to (4). Finally, the convolution value is flattened into a vector of a specific length (the length is the same as the number of predicted image quality categories of the model, which is 4 here). The vector is input into the Softmax function for classification prediction to obtain the predicted probability of each category, as shown in formula (5).
[0071]
[0072] in, represents the pixel value at depth k at position (i, j) in the convolutional layer input feature map, Represents the pixel value at depth p at position (i+m, j+n) in the input data, represents the weight value of the depth p at position (m, n) in the convolution kernel and the depth k on the output feature map, b k represents the bias term with a depth of k on the output feature map, and f represents the convolution kernel size
[0073]
[0074] Among them, g represents the pooling function (such as maximum pooling and average pooling, etc.), Represents the input tensor All values within the pooling window.
[0075]
[0076] in, represents the output of the fully connected layer, W represents the weight matrix, and b represents the bias term.
[0077] Y s =max(0,M) (4)
[0078] in, represents the output of the activation function, and M represents the input.
[0079]
[0080] Where j is a subscript variable to be summed. c represents the predicted probability vector of the cth category, e z c represents the output score of the model for the cth category.
[0081] Image quality is classified according to the predicted label value, and then the index value at the maximum probability in the predicted probability vector is found as the predicted label value of the category, and the category corresponding to the face image quality corresponding to the predicted label value is matched. When the image is input into the image quality classification module, it is first classified:
[0082] (1) When the predicted label value is 0, it is classified as a high-quality image and is transferred to the image storage module for retention.
[0083] (2) When the predicted label value is 1, it is classified as a low-resolution image and is transferred to the image restoration module for super-resolution restoration using the BSRGAN model.
[0084] (3) When the predicted label value is 2, it is classified as a low-light image and is transferred to the image restoration module for illumination enhancement restoration using the EnlightenGAN model.
[0085] (4) If the image is both a low-light image and a low-resolution image, it is transferred to the image restoration module, where light enhancement restoration is first performed, and then low-resolution image super-resolution restoration is performed, and finally a restored high-quality image is output.
[0086] (5) When the predicted label value is 3, it is classified as other images. Images other than high-quality images, low-resolution images, and low-light images are classified as other images.
[0087] Figure 4 Examples of images of tunnel faces of different types. The image quality classification model also processes images stored on the local device and receives and processes images inpainted by the image inpainting model. In addition, this model selects high-quality images and low-light images to construct a low-light image dataset, and selects high-quality images and low-resolution images to construct a low-resolution image dataset.
[0088] S22. Verification and evaluation of image quality classification results
[0089] S221, verified by mixing matrix
[0090] The confusion matrix is a tool used to evaluate the performance of a classification model. It summarizes how the model's predictions compare to the actual results and contains four important elements:
[0091] (1) True Positive (TP): The number of samples correctly predicted by the model as positive. For example, the model correctly classifies a sample as a high-quality image when it is actually a high-quality image.
[0092] (2) False Positive (FP): The number of samples that the model incorrectly predicts as positive. For example, the model incorrectly classifies a sample that is actually a low-quality image as a high-quality image.
[0093] (3) False Negative (FN): The number of samples that the model incorrectly predicts as negative. For example, the model incorrectly classifies a sample that is actually a high-quality image as a low-quality image.
[0094] (4) True Negative (TN): The number of samples that the model correctly predicts as negative. For example, the model correctly classifies a sample as a low-quality image when it is actually a low-quality image.
[0095] Confusion matrices are often used to show the relationship between actual categories and model predicted categories in classification tasks. Figure 3 The following is a diagram of the confusion matrix verification of the image quality classification model, which is used to evaluate the performance of the image quality classification model. It is known that the image categories corresponding to different predicted label values are defined in S22. Figure 3 In the figure, the horizontal axis (actual classification) and the vertical axis (predicted classification) represent the model prediction results and the actual classification. The values on the diagonal (190, 182, 178, 286) represent the number of correct classifications, that is, the sum of the true positive and true negative classes.
[0096] For high-quality images (category 0), the model was able to accurately identify 190 of them and did not misclassify any high-quality images into other categories, indicating that the recognition of high-quality images is very accurate.
[0097] For low-resolution images (category 1) and low-light images (category 2), the model also showed high accuracy, with 182 correct classifications for category 1 and 178 correct classifications for category 2, with only a few classification errors (such as one image from category 2 being misclassified as a high-quality image).
[0098] For other class images (category 3), the model identified 286 correct instances and only 2 were misclassified as low-light images, which also indicates good classification performance.
[0099] The values on the off-diagonal lines indicate misclassifications. The model slightly misclassifies low-light images, with one low-light image being misclassified as a high-quality image and two other class images being misclassified as low-light images. This misclassification may indicate that the model has challenges handling lighting-related features, or that these particular instances are similar in feature representation to high-quality or low-light images.
[0100] The hybrid matrix method demonstrated the excellent performance of the image classification model in tunnel face image quality classification, accurately identifying various types of images and effectively distinguishing high-quality, low-resolution, low-light and other types of images, proving its efficiency and reliability in handling complex classification problems.
[0101] S222, evaluated by F1 score
[0102] In the image quality classification process, the F1 score is used as the main evaluation indicator. It combines the precision rate (Precision) and the recall rate (Recall) to provide an indicator for comprehensively evaluating the performance of the classification model. The F1 score is an indicator for comprehensively evaluating the performance of the classification model, especially for class-imbalanced data sets. It combines the model's precision rate (Precision) and recall rate (Recall), where the precision rate is the proportion of samples that are actually positive in all samples predicted to be positive. The calculation formula is:
[0103]
[0104] The recall rate is the proportion of samples that are correctly predicted as positive among all samples that are actually positive. The calculation formula is:
[0105]
[0106] The F1 score is the harmonic mean of precision and recall, and its formula is as follows:
[0107]
[0108] Among them, Precision represents precision, Recall represents recall, TP represents true positive, FP represents false positive, and FN represents false negative. The F1 score ranges from 0 to 1, and the higher the value, the better the performance of the model. It is particularly useful when evaluating models because it takes into account the impact of both false positives and false negatives, providing a more comprehensive performance measure.
[0109] Figure 4 It shows the F1 scores of different categories of images in the quality classification task. The columns in the figure represent:
[0110] High-quality images: The F1 score is 0.995, indicating that the model exhibits extremely high precision and recall when classifying high-quality images.
[0111] Low-light images: The F1 score is 0.997, which shows that the model performs very well in identifying and classifying low-light images, and almost perfectly balances precision and recall.
[0112] Low-resolution images: The F1 score is 0.989, which is slightly lower than the other two categories, but still shows the high efficiency of the model in processing low-resolution images.
[0113] Other categories: The F1 score is 0.991, indicating that the model maintains high accuracy when classifying other types of images that are difficult to clearly define.
[0114] Overall, this figure shows that the image quality classification model performs very well on all considered categories. This emphasizes the effectiveness and reliability of the model in processing tunnel face images under different lighting and quality conditions.
[0115] S3. Image restoration
[0116] The image restoration model is the core technical implementation part of the system, responsible for intelligently restoring images identified as low quality. Two different generative adversarial networks are used to handle different types of image defects. Examples of low-resolution image restoration include Figure 5 , low light image enhancement examples such as Figure 6 shown.
[0117] Through convolution operation, pooling operation, full connection operation, ReLu activation, as shown in formulas (6) to (9), the distribution of each pixel is finally obtained through the Sigmoid function, as shown in formula (10).
[0118]
[0119] in, represents the pixel value at depth k at position (i, j) in the convolutional layer input feature map, Represents the pixel value at depth p at position (i+m, j+n) in the input data, represents the weight value of the depth p at position (m, n) in the convolution kernel and the depth k on the output feature map, b k represents the bias term with a depth of k on the output feature map, and f represents the convolution kernel size
[0120]
[0121] Among them, g represents the pooling function (such as maximum pooling and average pooling, etc.), Represents the input tensor All values within the pooling window.
[0122]
[0123] in, represents the output of the fully connected layer, W represents the weight matrix, and b represents the bias term.
[0124]
[0125] in, represents the output of the activation function, and M represents the input.
[0126]
[0127] Where z is the input value, σ z Is the pixel value output by the model, and its value is between 0 and 1. z Represents the normalized pixel distribution of the image after the model is restored. It is for image restoration, not for image classification. Different images have different outputs after restoration, so all pixel values output by the model must be retained, and further automatically calculated into RGB pixels between 0-255 through the pixel distribution. Because the pixel distribution of the original image is high and low, the pixel distribution of the restored image is also high and low, so that the differences in color, brightness, etc. can be reflected.
[0128] (1) Processing low-light images: Use the EnlightenGAN model to perform low-light enhancement restoration. EnlightenGAN is an efficient and unsupervised generative adversarial network that can be trained without low-normal light image pairs, so that it can well learn the state of tunnel face images under different lighting conditions, thereby performing low-light enhancement restoration.
[0129] (2) Processing low-resolution images: Use the BSRGAN model for super-resolution restoration. BSEGAN is a generative adversarial network that restores the low-resolution situation of photos in the real world to the greatest extent possible by randomly mixing low resolution, downsampling, and noise degradation, thereby achieving super-resolution restoration.
[0130] S4, Image Storage
[0131] The decision on whether to store an image is based on the classification result provided by the DenseNet121 image quality classification model. The retention or elimination of images is automatic and depends on the evaluation of the model. The model has been trained to effectively identify different quality levels of tunnel face images. If the model identifies the image as high quality, it is retained; otherwise, the non-high quality image is processed and re-evaluated by the image repair module. Before the image is confirmed as high quality by DenseNet121, the repair and evaluation process will be continuously cycled until it is confirmed as high quality or the iteration limit is reached. This module ensures that only images that meet the quality requirements are retained, optimizing the use of storage resources and ensuring the efficiency and effectiveness of the tunnel safety monitoring system.
[0132] This method uses the synergy of multiple models to achieve intelligent repair of low-quality images of the tunnel face and improve image quality.
[0133] S5. Model Integration
[0134] After the model training is completed, a comprehensive performance evaluation is conducted on each model to test its effectiveness and wide applicability in processing actual tunnel face images. The three models with the best performance (image quality classification model, low-light enhancement model, and super-resolution restoration model) are selected and integrated to build a unified intelligent restoration system for low-quality tunnel face images. The system automatically manages the entire process from image acquisition to classification, restoration, and storage, ensuring that each processing step is efficient and seamlessly connected.
[0135] The system operates as follows: When an image is uploaded to the system, the image quality classification unit first accurately classifies the image type. For low-light images, the system automatically transfers them to the low-light enhancement unit for light enhancement processing; for low-resolution images, they are transferred to the super-resolution restoration unit for clarity restoration; if the image has both low-light and low-resolution problems, the system first processes it in the low-light enhancement unit, then sends the image to the super-resolution restoration unit for deep restoration, and finally outputs the restored high-quality image.
[0136] Through the above methods, the system can effectively identify and repair quality problems of tunnel face images, greatly improving the accuracy and reliability of construction site safety monitoring.
[0137] Example 3
[0138] This embodiment describes a device for executing a method for intelligently repairing low-quality images of a tunnel face, and its system structure is as follows: Figure 3 The device shown in the figure is composed of four main modules. The image acquisition module transmits the collected tunnel face images to the image classification module. The image classification module transmits the classified images to the image repair module. After the image repair module repairs the images with different quality problems, the images that meet the repair requirements are transmitted to the image storage module. The images that fail to meet the repair requirements are transmitted to the image classification module again for image quality problem judgment and then image repair. After iterative operations, images that still do not meet the quality requirements will be eliminated.
[0139] The structure of the tunnel face image intelligent repair system is as follows: Figure 3 As shown, the following is an introduction to the four main modules:
[0140] Image acquisition module (11):
[0141] The module is equipped with a highly sensitive image sensor and an adaptive light adjustment system that can automatically adjust the shooting parameters under the changing light conditions inside the tunnel to optimize the image capture quality. The module also includes an autofocus system to ensure clear images even in the complex environment of the tunnel.
[0142] Image quality classification module (12):
[0143] This module integrates the DenseNet121 network based on convolutional neural network, which is pre-trained to recognize and classify images of different qualities. This module automatically processes data from the image acquisition module and can recognize high-quality images, low-resolution images, low-light images and other types of images in real time.
[0144] Image restoration module (13), this module is divided into two sub-modules:
[0145] (1) Low-light enhancement submodule: Using EnlightenGAN technology, it specifically performs light enhancement on images captured under low-light conditions to improve image visibility and details.
[0146] (2) Super-resolution restoration submodule: BSRGAN technology is used to process low-resolution images and the clarity and details of the image are enhanced through algorithms to achieve higher resolution.
[0147] Image storage module (14):
[0148] The image storage module automatically retains or removes images based on the evaluation results of the DenseNet121 image quality classification model. The model is trained to accurately identify tunnel face images of different quality levels. Images identified as high quality are directly retained, while non-high quality images are sent back to the image restoration module for processing and re-evaluation. This process will be repeated until the image is evaluated as high quality. This module ensures that only images that meet quality standards are retained, thereby optimizing storage resources and improving the efficiency and effectiveness of the tunnel safety monitoring system.
[0149] The system device is controlled by at least one central processor and is equipped with a memory connected to the processor. The memory stores an operating system and application code that implements the functions of the above modules. The system also includes necessary input and output devices and network interfaces to support remote access and data transmission. The system device can be deployed in the control center of the tunnel construction site and communicate with the image acquisition module through a wired or wireless network.
[0150] Through the device and method described in this embodiment, the intelligent repair system for low-quality images of tunnel faces can effectively improve the quality of tunnel construction images, thereby improving the efficiency and safety of engineering monitoring.
[0151] The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. Any modifications, equivalent substitutions and improvements made within the spirit and principles of the present invention should be included in the protection scope of the present invention.
Claims
1. A method for intelligently repairing low-quality images of tunnel faces, characterized in that: The following steps are involved: S1, obtaining tunnel face images; S2, classifying the image quality of the tunnel face image, comprising the following steps: S21, using the DenseNet121 network based on a convolutional neural network to process and classify the tunnel face image to obtain a preliminary image classification result; and classifying the tunnel face image into high-quality images, low-resolution images, low-light images, and other types of images; the high-quality images are images that meet preset standards; the preset standards are based on the resolution and light intensity of the images; S22, evaluating the preliminary image classification results using the F1 score and confusion matrix; S3, performing iterative image restoration processing on the low-quality image described in S21; automatically performing illumination enhancement on the low-light image using the EnlightenGAN model, and performing super-resolution processing on the low-resolution image using the BSRGAN model; classifying the low-quality image that meets the preset standard after iterative restoration as the high-quality image; and classifying the low-quality image that fails to meet the preset standard as other types of images; S4. According to the image restoration result of S3, the high-quality image is stored, and the other types of images are eliminated.
2. According to claim 1, a method for intelligently repairing low-quality images of a tunnel face is characterized in that: S21 includes the following steps: 1) Use the DenseNet121 model of the convolutional neural network to automatically classify images. The convolution operation formula is: in, represents the pixel value at depth k at position (i, j) in the convolutional layer input feature map, Represents the pixel value at depth p at position (i+m, j+n) in the input data, represents the weight value of the depth p at position (m, n) in the convolution kernel and the depth k on the output feature map, b k represents the bias term with a depth of k on the output feature map, and f represents the convolution kernel size; 2) Perform pooling operation on the result obtained by convolution operation, Among them, g represents the pooling function, Represents the input tensor All values within the pooling window; 3) Apply the ReLU activation function to process the output of each layer of the network, and calculate the probability distribution of various functions through the fully connected layer and the Softmax function to determine the image quality category. in, represents the output of the fully connected layer, and Wx represents a tensor The weight matrix of , b represents the bias term; represents the output of the activation function, M represents the input; j is a subscript variable for summation, p c represents the predicted probability of the cth category, e z c represents the output score of the model for the cth category; 4) The index value at the maximum probability in the predicted probability vector is the predicted label value of the category, matching the category corresponding to the palm face image quality corresponding to the predicted label value.
3. The method for intelligently repairing low-quality images of a tunnel face according to claim 2 is characterized in that: Step S22 further includes using a confusion matrix to evaluate the performance of the image quality classification model, wherein the confusion matrix records in detail the comparison between the model prediction results and the actual results, including true positives, false positives, false negatives, and true negatives.
4. The method for intelligently repairing low-quality images of a tunnel face according to claim 2 is characterized in that: Step S22 includes using the F1 score to evaluate the performance of the image quality classification model, where the F1 score is calculated based on the harmonic mean of precision and recall, and the calculation formula is: Among them, Precision represents the precision, Recall represents the recall, TP represents the true positive, FP represents the false positive, and FN represents the false negative.
5. A method for intelligently repairing low-quality images of a tunnel face according to any one of claims 2 to 4, characterized in that: The EnlightenGAN model and the BSRGAN model used in the image restoration process described in S3 both go through convolution operations, pooling operations, full connection operations, and ReLu activation steps; finally, the distribution of each pixel is obtained through the Sigmoid function, and the formula is as follows: Where Z is the input value, σ z is the pixel value output by the model, σ z The value is between 0 and 1.
6. The method for intelligently repairing low-quality images of a tunnel face according to claim 1, characterized in that: When the image is repaired in S3, if the image is both a low-light image and a low-resolution image, it will be transmitted to the image repair module, firstly the light enhancement repair is performed, then the low-resolution image super-resolution repair is performed, and finally the repaired high-quality image is output.
7. The method for intelligently repairing low-quality images of a tunnel face according to claim 1, characterized in that: S4 includes the following steps: 1) Use the convolutional neural network DenseNet121 to automatically evaluate the quality of tunnel face images to identify whether the images meet high quality standards; 2) According to the evaluation results of the DenseNet121 model, the image is retained or removed: if the image is evaluated as high quality, it is retained; if the image is evaluated as low quality, it is sent back to the image restoration module for further restoration processing; 3) Re-evaluate the restored image, and continue this cycle until the image is evaluated as high quality or reaches a predetermined number of iterations, and finally only store images that meet the quality standards.
8. A device for repairing low-quality images of tunnel faces, characterized in that: The device includes: An image acquisition module, which is equipped with a high-sensitivity image sensor and an adaptive light adjustment system, is used to automatically adjust shooting parameters in the tunnel to optimize image capture quality, and includes an autofocus system to ensure clear images in the complex environment of the tunnel; The image quality classification module integrates the DenseNet121 model based on convolutional neural network, which is pre-trained for real-time recognition and classification of images from the image acquisition module, and classifies images into high-quality images, low-resolution images, low-light images, and other categories of images; The image restoration module includes two submodules: the low-light enhancement submodule and the super-resolution restoration submodule, which use EnlightenGAN and BSRGAN technologies to restore low-light and low-resolution images respectively; The image storage module automatically retains or removes images based on the evaluation results of DenseNet121. Non-high-quality images are repaired and re-evaluated in a cycle until they are confirmed to be high-quality or the iteration limit is reached.
9. The device for repairing low-quality images of a tunnel face according to claim 8, characterized in that: The device also includes at least one processor and a memory communicatively connected to the at least one processor; the memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor to implement the functions of image acquisition, image quality classification, image restoration and image storage described in claim 1.
Citation Information
Patent Citations
Method, system and equipment for repairing old portrait photo and storage medium
CN116823653A
Intelligent identification method, device and equipment for lithology of tunnel face and medium
CN118334505A