Trackside image enhancement method
Through the low-light image enhancement method based on deep learning algorithms, the problem of low image brightness and poor contrast in the urban rail train operating environment is solved, the image quality is improved, and the accuracy and efficiency of train status monitoring and fault diagnosis are improved. Promotes the intelligent operation of urban rail transit.
Patent Information
- Application Number
- CN202411068830.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-08-06
- Publication Date
- 2024-09-06
- Estimated Expiration
- Not applicable · inactive patent
AI Technical Summary
The poor lighting conditions in the operating environment of urban rail trains result in low brightness, poor contrast and loss of details in the image data collected by the trackside image detection system, which affects the usability of the images and the development of subsequent advanced machine vision tasks.
A low-light image enhancement method based on a deep learning algorithm is adopted, including a dual-channel image restoration unit, a feature fusion module based on the 2D-DCT algorithm and an image generation network, and a dual-loop strategy is used to achieve bidirectional mapping of low-light images and normal brightness images, improving Image brightness, contrast and clarity.
Significantly improve the quality and usability of images, improve the accuracy and efficiency of train status monitoring and fault diagnosis, reduce operation and maintenance costs, improve the intelligence level and adaptability of urban rail transit systems, and promote safety, reliability and intelligence operations.
Smart Images

Figure CN118608407A
Abstract
Description
Technical Field
[0001] The invention belongs to the technical field of trackside image processing, and in particular relates to a trackside image enhancement method. Background Art
[0002] The operating environment of urban rail trains usually has poor lighting conditions, which leads to problems such as low brightness, poor contrast and loss of details in the image data collected by the trackside image detection system. As a result, the visual information in the image cannot be effectively utilized, further restricting the implementation of subsequent advanced machine vision tasks such as vehicle body image segmentation and component fault detection.
[0003] The traditional light source supplementation method is limited by the trackside equipment configuration requirements and manual experience, and the image restoration effect is poor and the practical applicability is poor. Therefore, studying the image quality enhancement method of train operation in low-light scenes and restoring high-quality images of normal brightness from low-light monitoring images is important for monitoring and analyzing the train operation status. Summary of the invention
[0004] The purpose of the present invention is to provide a trackside image enhancement method to effectively solve the problem that the image data collected by the trackside image detection system in a low-light environment cannot be effectively utilized due to low brightness, poor contrast and loss of details.
[0005] In order to solve the above technical problems, the technical solution adopted by the present invention is: a trackside image enhancement method, comprising the following steps: S1, relying on the trackside equipment of the train trackside image detection system in the urban rail transit system to obtain the train running image with a light intensity ranging from 0.1 to 10 lux.
[0006] S2. Preprocessing the train running images collected in step S1, including image compression and data set division.
[0007] S3. Establish a low-light image enhancement model based on a deep learning algorithm, wherein the low-light image enhancement model includes three parts: a dual-channel image restoration unit, a feature fusion module based on a 2D-DCT algorithm, and an image generation network.
[0008] S4. Input the train running image preprocessed in step S2 into the low-light image enhancement model, and train and test the low-light image enhancement model.
[0009] S5. According to the learning result of the low-light image enhancement model in step S4, adjust the network structure and parameter settings of the low-light image enhancement model to make the final image enhancement result more accurate, and save the final low-light image enhancement model.
[0010] Furthermore, in step S3, a double-loop strategy is adopted to realize bidirectional mapping between the low-light image and the normal-brightness image by stacking an image generation operation and an image degradation operation, wherein the low-light in the low-light image refers to a light intensity in the range of 0.1 to 10 lux.
[0011] The bidirectional mapping operation is expressed as: , , where represents a low-light image, represents a normal brightness image, Indicates the highlight area, Indicates the low light range, represents the forward enhancement module, represents a reverse degradation module; the forward enhancement module and the reverse degradation module both perform feature extraction and reconstruction operations of the train running image.
[0012] Furthermore, in step S3, the dual-channel image restoration unit is used to enhance the image quality of the low-light image. The dual-channel image restoration unit is composed of a global perception module, a local perception module and a feature fusion module. The global perception module is used to process the global dependency of pixels in the image, the local perception module is used to learn the image content, and the feature fusion module is used to enable the perception results of the global perception module and the local perception module to realize the interactive operation of feature information at different scales. The local perception module is designed by combining a multi-scale channel attention mechanism with a pixel attention mechanism.
[0013] Further, in step S3, the feature fusion module based on the 2D-DCT algorithm is used to reduce the feature loss of the output information of the global perception module and the local perception module during information interaction. The 2D-DCT algorithm formula is expressed as: ,in, and Represent the height and span of the feature map respectively, Indicates obtaining random values from the span values of multiple feature maps. Indicates obtaining random values from the height values of multiple feature maps. It is The span of feature maps, It is The height of the feature map, , , is the pixel value of the feature map in the spatial domain, It is the value of the feature map in the frequency domain after transformation.
[0014] For an input feature map of a specific size, the 2D-DCT algorithm generates a coefficient matrix of the same size. In the feature fusion module, the two branches, the global perception module and the local perception module, respectively use the 2D-DCT algorithm to map the feature map from the spatial domain to the high-dimensional frequency domain and generate a coefficient matrix. and , as the weight of feature interaction; at the same time, the output features of the two branches are concatenated and compressed to generate a fusion feature, and an overall coefficient matrix is generated through the 2D-DCT algorithm ; In the feature interaction process, through and The operation is to share knowledge, that is, one branch obtains its missing information from another branch through the coefficient matrix. The formula is: , , ,in, and are the output results of the global perception module and the local perception module, and It is the updated result generated by applying the 2D-DCT algorithm to the output results of the original global perception module and local perception module. and Used to control the contribution of different branches in the feature fusion process. Represents the final output result of the feature fusion module.
[0015] Furthermore, in step S4, peak signal-to-noise ratio, structural similarity index and LPIPS are selected as evaluation indicators of image visual effects.
[0016] The peak signal-to-noise ratio is based on the root mean square error function and is calculated as: MSE= 1 HW ∑ i=1 H ∑ j=1 W [ I H (i,j)- I ̃ H (i,j) ] 2 , ,in, represents the brightness image generated by the low-light image enhancement model, represents the pixel extreme value in the image, represents the root mean square error, and Represent the height and span of the image respectively, Indicates peak signal-to-noise ratio.
[0017] The structural similarity index comprehensively measures the image quality from three aspects: image brightness, structure and contrast. : ,in, and are the standard deviations of the normal brightness image and the brightness image generated by the low-light image enhancement model, is an image and The covariance between and They are images and The standard deviation of brightness, and are constants added to avoid the denominator being zero and are all set to 0.0001.
[0018] Furthermore, in step S1, the trackside equipment includes an equipment start-up activation device, an intermediate control circuit, an image acquisition device, a trackside sensing antenna and a track vibration sensor.
[0019] Compared with the prior art, the beneficial technical effect of the present invention is that the present invention successfully solves a series of challenges encountered by trackside image detection in urban rail transit systems under low-light conditions, such as insufficient image brightness, low contrast, and missing detail information. By automatically learning and extracting key features in the image, the present invention can significantly improve the quality of the image, including comprehensive enhancement of brightness, contrast, and clarity, thereby greatly improving the usability and visual effect of the image. It not only improves the accuracy and efficiency of train status monitoring and fault diagnosis, and reduces operation and maintenance costs, but also improves the intelligence level and adaptability of the urban rail transit system. Furthermore, the present invention is of great significance to promoting the safe, reliable and intelligent operation of urban rail transit, helps to improve the maintenance efficiency of the entire urban rail transit system and reduce downtime, and further promotes the healthy and sustainable development of urban rail transit. BRIEF DESCRIPTION OF THE DRAWINGS
[0020] Figure 1 It is the original low-light train running image.
[0021] Figure 2 The Retinex method is used to Figure 1 Restoration results of low-light train running images.
[0022] Figure 3 The SCI method is used to Figure 1 Restoration results of low-light train running images.
[0023] Figure 4 The URetinex method is used to Figure 1Restoration results of low-light train running images.
[0024] Figure 5 The ZeroDCE method is used to Figure 1 Restoration results of low-light train running images.
[0025] Figure 6 The NeRCo method is used to Figure 1 Restoration results of low-light train running images.
[0026] Figure 7 The EnlightenGAN method is used to Figure 1 Restoration results of low-light train running images.
[0027] Figure 8 The low-light image enhancement model of Example 1 is used for Figure 1 Restoration results of low-light train running images.
[0028] Fig. 9 The loss function changes of the enhancement module for different methods, where the illustrations highlight the detailed changes in the loss in the later training stages.
[0029] Fig.10 is the change of the overall network loss function for different methods, where the illustrations highlight the detailed changes in the loss in the later training stages. DETAILED DESCRIPTION
[0030] Embodiment 1: A method for enhancing a trackside image comprises the following steps: S1, obtaining a low-light (light intensity within the range of 0.1 to 10 lux) train running image by using the trackside equipment of a train trackside image detection system in an urban rail transit system.
[0031] The trackside equipment includes an equipment start-up activation device, an intermediate control circuit, an image acquisition device, a trackside sensing antenna and a track vibration sensor. When the train runs to a certain distance in front of the image acquisition device, the trackside sensing antenna will receive the same frequency signal emitted by the train's onboard antenna, and control the image acquisition device to start working. The track vibration sensor is mainly used to collect rail vibration signals. When the train approaches, when the rail vibration signal is enhanced to reach or even exceed the threshold, a pulse signal will be generated to connect the intermediate control circuit to issue a device start-up command. In order to facilitate the staff to start the remote control device, a remote control switch is also designed in this embodiment. Indoor staff can issue a start or shutdown command on the indoor terminal computer, and the command is transmitted to the remote control switch through the optical cable for manual control of changes in the device status.
[0032] As the train enters the predetermined monitoring area of the image acquisition device, the trackside sensing antenna and vibration sensor are dynamically activated. These sensors monitor specific pulse and vibration thresholds in real time to detect the presence of the train. Once these parameters exceed the preset threshold, the system triggers the high-speed digital camera to start working. The high-speed digital camera is responsible for high-resolution image acquisition of the bottom and side of the train. The acquired image is transmitted to the image quality compensator via an optical cable, where brightness correction and image content recovery processing are performed through software algorithms. This process aims to eliminate the impact of ambient light changes on image quality and ensure that the clarity of image data meets the standards required for subsequent analysis. The quality-compensated image data is then transmitted to the intermediate data switch, which is responsible for the temporary storage and management of image data. The intermediate data switch is further connected to the central device server via an optical cable and is responsible for centralized transmission of image data to the back-end server. The central device server dispatches multiple terminal fault detection computers to analyze and process the image data. These terminal fault detection computers use highly optimized image processing algorithms to perform status analysis and fault detection on key train components, and achieve early warning of potential faults by accurately extracting and comparing image features. After completing data collection in the monitoring area, when the train leaves and the signal value detected by the sensing antenna and vibration sensor falls below the set threshold, the control circuit of the image acquisition device will automatically cut off the power supply of the high-speed digital camera and end the image acquisition process. This mechanism ensures the operating efficiency of the system, minimizes energy consumption, and avoids excessive use of equipment. In this way, the image acquisition device provides a real-time, automated monitoring method for the train operation status, enhancing the maintenance and safety management of the railway network.
[0033] The data of the simulation experiment in this embodiment comes from the B train depot of the A subway line, and the trackside equipment is used to collect data of the train body structure in the low-light scene on the side of the track. The collected image data size is 1080*1920, and the total number of images is 3000.
[0034] S2. Preprocessing the low-light train running images collected in step S1, including image compression and data set division.
[0035] During the experiment, 2200 images were used as training data, and the remaining 800 images of trackside trains were used as test data. In order to speed up the experiment, all images were compressed and uniformly adjusted to 600*400.
[0036] S3. Establish a low-light image enhancement model based on a deep learning algorithm, wherein the low-light image enhancement model includes three parts: a dual-channel image restoration unit, a feature fusion module based on a 2D-DCT algorithm, and an image generation network.
[0037] In rail transit systems, it is difficult to collect paired data under different lighting conditions in the same scene due to the train running status and environmental changes, which restricts the scene applicability of the low-light restoration method based on supervised learning. Therefore, this embodiment adopts a double-loop strategy to achieve bidirectional mapping between low-light images and normal-brightness images by stacking image generation operations and image degradation operations, solving the problem of mismatch between low-light images and normal-brightness images during low-light image restoration network training.
[0038] The bidirectional mapping operation is expressed as: , , where represents a low-light image, represents a normal brightness image, Indicates the highlight area, Indicates the low light range, represents the forward enhancement module, Represents the reverse degradation module.
[0039] The forward enhancement process is used to restore the low-light image to a normal-brightness image; the reverse degradation process considers degrading the normal-brightness image to obtain the low-light image. When the input is a low-light image, a forward enhancement module is first used to convert the low-quality image of the track edge from the low-light domain to the high-light domain, and then a reverse degradation is used to map it back to the low-light domain. When the input is a normal-brightness image, the operation is the opposite.
[0040] The two loops jointly optimize the learning ability of the image generation network through the network loss function, solve the problem of the image generation network's dependence on the paired data set, and improve the algorithm's learning ability for normal brightness images and low-light images in different scenes.
[0041] Both the forward enhancement module and the reverse degradation module perform feature extraction and reconstruction operations on the train running image. In the feature extraction part, the Resnet module with a residual connection structure is used to downsample the image and map the image features to a high-dimensional space. Then, the image features are sent to the two perception branches (global perception module and local perception module) of the dual-channel image restoration unit for image brightness enhancement and detail restoration. The results of different branch processing will interact through the feature fusion unit and be input into the feature reconstruction layer (TLR) composed of a deconvolution layer, a linear normalization layer, and an activation function for feature dimensionality reduction and image generation operations.
[0042] In order to correct potential color deviation and overexposure problems in the image quality enhancement task of trackside low-light monitoring, this embodiment defines the low-light restoration process as a feature reweighting mechanism. Specifically, this mechanism enhances the robustness of the image generation network in extracting and utilizing features under different lighting environments by increasing the weights of key features of the vehicle image under various lighting conditions, while suppressing non-critical features that are prone to losing information in lighting changes, thereby improving the performance of visual tasks. This embodiment completes the image quality enhancement of low-light images by designing a dual-channel image restoration unit.
[0043] The dual-channel image restoration unit is composed of a global perception module, a local perception module, and a feature fusion module. The global perception module is used to process the global dependencies of pixels in the image, while the local perception module focuses on learning the specific content in the image. The feature fusion module is used to enable the perception results of the global perception module and the local perception module to achieve interactive operations of feature information at different scales. Through the method of global and local feature perception, the learning content of the image generation network will be more targeted, ensuring the restoration quality of low-light images.
[0044] (1) Global perception module.
[0045] In order to utilize the widely distributed contextual information in the image and enable the image generation network to distinguish the differences between adjacent pixels, this embodiment uses the global attention method to design a global perception module (GAB). GAB first accepts the feature map from the convolution operation, marked as , and performs point-by-point convolution operations on Perform dimensionality reduction operation and obtain , and Three new feature subgraphs. Next, Reshape and transpose to adapt to matrix multiplication operations; at the same time, and has also been reshaped, with the spatial dimension ( and ) is compressed into a single dimension to facilitate the application of the attention mechanism. and remodeled Matrix multiplication is performed and a softmax activation function is used to generate perceptual scores. These scores reflect the importance of each spatial position, thereby guiding the image generation network to focus on areas that remain rich in information under lighting changes. These perceptual scores are then used to reshape the Finally, the weighted feature map is reshaped into a feature map with spatial dimensions to produce the final spatial illumination attention feature map. .
[0046] (2) Local perception module.
[0047] This embodiment adopts a method combining multi-scale channel attention mechanism (MSCAM) and pixel attention mechanism (PAM) to design the local perception module. At the same time, in order to reduce the complexity of training, the channel split operation (Channel Split) is used in the feature extraction stage. First, feature mapping is performed through a convolution layer with a convolution kernel size of 1*1. After the mapping result is divided into channels, the features are dispersed into four groups, and the number of channels is reduced to 1 / 4 of the original, which can improve the efficiency and quality of feature extraction. In order to fully mine the texture and structure information, the four feature groups are set with receptive fields of different sizes, that is, different numbers of 3*3 convolution layers, to retrieve the information in the feature branches, and the progressive fusion method is used to merge the information under the same receptive field to achieve full interaction of information.
[0048] (I) Multi-scale channel attention mechanism.
[0049] Considering that the channel segmentation operation weakens the channel correlation between feature groups to a certain extent, this embodiment adopts a multi-scale channel attention mechanism (MSCAM) to guide the intermediate results after splicing to complete feature aggregation and reduce channel correlation loss. MSCAM has two branches. The global average pooling (GAP) branch is used to integrate spatial information, and then this information is processed by the convolution layer to capture dependencies; the branch without GAP focuses on the multi-scale details in the input. The outputs of the two branches are fused by element-by-element addition, and the Leaky ReLU activation function is used to generate feature weights. The generated feature weights are multiplied by the original input to dynamically calibrate the feature response of each channel, so as to more effectively learn local fine-grained features. MSCAM is expressed as: , , , ,in, represents the global average pooling operation, Represents a 3*3 convolution operation, Represents a 1*1 convolution operation, and Corresponding to the output of the two branches of the MSCAM unit, represents the activation function, represents the weight matrix generated by summing the output results of the two branches and applying the activation function, represents matrix multiplication, represents the input of the MSCAM unit, Represents the final output result of the MSCAM unit.
[0050] (II) Pixel Attention Mechanism.
[0051] Through MSCAM, the image generation network can obtain rich channel features that contain multiple representations of the image. However, these features may not be sufficient to fully solve the problem of reconstructing local details of the image, especially in cases of poor image quality (such as low lighting conditions).
[0052] The pixel attention mechanism (PAM) further strengthens the attention of the image generation network to local areas on this basis. By assigning weights to each pixel to emphasize or suppress certain local features, it helps to better reconstruct image details such as edges, textures, etc. PAM accepts a four-dimensional feature (B×C×H×W) as input , the feature map is first processed by a convolutional layer, which is responsible for capturing spatial features. Subsequently, the feature map passes through the ReLU activation function to generate an attention map ranging from 0 to 1 to characterize the importance of each pixel. The attention map is multiplied element by element with the original feature map to give higher weights to key pixels in the final feature representation. Finally, the feature map after the dot multiplication operation passes through a convolutional layer again, outputting the adjusted feature map (F'(B×C×H×W)), enhancing the sensitivity of the image generation network to the image content.
[0053] The working principle of PAM can be formulated as: , , , ,in, and Represent the operation results of the two branches respectively. Represents a 1*1 convolution operation, Represents a 3*3 convolution operation, is the activation function; Represents the weight generated by applying the activation function to the calculation result of branch one; Indicates the final calculation result of the entire PAM unit.
[0054] (3) Feature fusion module.
[0055] The global information obtained by the global perception module (GAB) contains low-frequency components such as structure and brightness distribution, while the local information generated by the local perception module (LAB) stores high-frequency components such as color and texture. In order to facilitate subsequent image reconstruction, the outputs of the two branches (i.e., the global perception module and the local perception module) need to be fused. Usually, weighted summation, channel splicing and compression, and attention mechanisms are used to achieve information interaction between different branches. In order to reduce the feature loss of the output information of the global perception module and the local perception module during information interaction, this embodiment proposes a feature fusion module (FFB) based on a 2D-DCT algorithm.
[0056] FFB makes full use of the decomposition capability of the 2D-DCT algorithm in the frequency domain to achieve complementary learning of local details and global structural features in the feature map, and uses the weighted summation method to achieve feature fusion for the interactive information, thereby improving the restoration quality of low-light images. The 2D-DCT algorithm is shown in the formula: ,in, and Represent the height and span of the feature map respectively, Indicates obtaining random values from the span values of multiple feature maps. Indicates obtaining random values from the height values of multiple feature maps. It is The span of feature maps, It is The height of the feature map, , , is the pixel value of the feature map in the spatial domain, It is the value of the feature map in the frequency domain after transformation.
[0057] For an input feature map of a specific size, the 2D-DCT algorithm generates a coefficient matrix of the same size. In the feature fusion module, the two branches, the global perception module and the local perception module, respectively use the 2D-DCT algorithm to map the feature map from the spatial domain to the high-dimensional frequency domain and generate a coefficient matrix. and , as the weight of feature interaction; at the same time, the output features of the two branches are concatenated and compressed to generate a fusion feature, and an overall coefficient matrix is generated through the 2D-DCT algorithm ; In the feature interaction process, through and The operation is to share knowledge, that is, one branch obtains its missing information from another branch through the coefficient matrix. The formula is: , , ,in, and are the output results of the global perception module and the local perception module, and It is the updated result generated by applying the 2D-DCT algorithm to the output results of the original global perception module and local perception module. and Used to control the contribution of different branches in the feature fusion process. Represents the final output result of the feature fusion module.
[0058] S4. Input the train running image preprocessed in step S2 into the low-light image enhancement model, and train and test the low-light image enhancement model.
[0059] The low-light image enhancement model of this embodiment is built on an experimental workstation based on the pytorch framework. The workstation has 64GB of RAM, equipped with an Intel Xeon Platinum 8160 processor with a main frequency of 2.10GHz, a GPU using two NVIDIA GeForce RTX 4090 graphics cards, and an operating system of Windows 10 Professional Edition. In terms of network parameter setting, in order to speed up the image processing speed of the low-light image enhancement model, a compression method is used to reduce the image size to 600*400. The Adam optimizer is used as the optimization algorithm in network training, and the learning rate parameter is set to 2e-4. The hyperparameters in the network are as follows: , , and Set them to 5, 10, 0.5 and 0.5 respectively.
[0060] In order to quantitatively analyze the restored image, this embodiment selects the peak signal-to-noise ratio (PSNR), structural similarity index (SSIM) and LPIPS as evaluation indicators of image visual effects. In the calculation process, the normal brightness image is marked as , the brightness image generated by the low-light image enhancement model is marked as .
[0061] (1) The peak signal-to-noise ratio is based on the root mean square error function and is calculated as follows: MSE= 1 HW ∑ i=1 H ∑ j=1 W [ I H (i,j)- I ̃ H (i,j) ] 2 , ,in, represents the brightness image generated by the low-light image enhancement model, represents the pixel extreme value in the image, represents the root mean square error, and Represent the height and span of the image respectively, Indicates peak signal-to-noise ratio.
[0062] (2) The structural similarity index comprehensively measures image quality from three aspects: image brightness, structure, and contrast, providing a method that is closer to the perception of the human visual system. The formula for the structural similarity index is: ,in, and are the standard deviations of the normal brightness image and the brightness image generated by the low-light image enhancement model, is an image and The covariance between and They are images and The standard deviation of brightness, and are constants added to avoid the denominator being zero and are all set to 0.0001.
[0063] (3) This embodiment uses LPIPS to evaluate the image restoration effect, extracts high-level features of the image through deep learning models (such as VGG, AlexNet, etc.), and then uses Euclidean distance in these feature spaces to calculate the difference between images. Use a pre-trained deep learning model (such as VGG) to extract features from the image. This embodiment selects the first = 15 layers to extract features.
[0064] For images and , respectively in The features extracted by the layer are expressed as and The Euclidean distance is used to calculate the difference between the two images in the layer features. The formula is as follows: ,in, is an image and In the The difference measure on the layer features, and They are Layer The eigenvalues on the feature map, Indicates The number of features in the layer.
[0065] S5. According to the learning result of the low-light image enhancement model in step S4, adjust the network structure and parameter settings of the low-light image enhancement model to make the final image enhancement result more accurate, and save the final low-light image enhancement model.
[0066] S6, according to the low-light image enhancement model obtained in step S5 and the restored trackside train image, the result analysis and verification are performed. Finally, the generated result after image enhancement will be wirelessly transmitted to the terminal detection computer of the operation and maintenance center via optical cable for subsequent operation status analysis and fault detection.
[0067] Test Example 1: This test example designs a trackside monitoring image enhancement experiment in a low-light scene, and designs two schemes, subjective visual evaluation and objective indicator evaluation, for result analysis based on the training process and training results. In order to further quantitatively analyze the effectiveness of the trackside image enhancement method proposed in Example 1, three advanced supervised learning methods, Retinex, URetinex and SCI, and three unsupervised learning methods, ZeroDCE, EnlightenGAN and NeRCo, were selected as the control group.
[0068] (1) Subjective visual evaluation.
[0069] like Figure 1-Figure 8 As shown, Figure 1 is the original low-light train running image, Figure 2-Figure 8 The results of low-light image restoration using various methods are shown in Table 2. After comparison, it is found that Figure 4 and Figure 6 As shown in Figure 2, NeRCo and URetinex are relatively good at color preservation, but they perform poorly in brightness enhancement and detail recovery, especially in dark area information recovery. Figure 2 and Figure 5 As shown in , although the Retinex and ZeroDCE methods can effectively improve the brightness of the image, they are often accompanied by problems in color distortion and detail retention, resulting in a decrease in the naturalness of the image. Figure 3 and Figure 7 As shown in the figure, the SCI and EnlightenGAN methods attempt to find a balance between brightness enhancement and color adjustment, but still face problems such as increased noise and poor color consistency, especially showing limitations in processing in low-brightness areas and high-contrast scenes.
[0070] When evaluating the quality of image restoration, the traditional RGB color space is intuitive, but the strong coupling of its constituent channels is not suitable for independently evaluating changes in brightness and color information. Therefore, in order to deeply analyze the impact of the low-light image enhancement algorithm on image color restoration and brightness enhancement, this test case chooses to convert the enhanced image to the HSV color space for evaluation. The advantage of the HSV color space is that it can separate color information (hue and saturation) from brightness information, which is closer to the way the human visual system perceives brightness and color.
[0071] According to the pixel distribution of saturation space in the HSV domain of the low-light train running images restored by different low-light image enhancement methods, it can be seen that the ZeroDCE method has too wide distribution in the brightness space, which may lead to loss of details. Although the URetinex method has more concentrated colors at certain saturation levels, it is slightly insufficient in color diversity. The Retinex and SCI methods show a narrow distribution in the hue space, indicating that the diversity of color restoration is limited. Although the NeRCo and EnlightenGAN methods perform well in color dynamic range, the sharp peaks in the brightness space suggest that the brightness enhancement may be excessive. The low-light image enhancement model proposed in Example 1 shows significant visual advantages in the histogram analysis of the HSV color space. In the hue space, the image generated by the low-light image enhancement model proposed in Example 1 shows a more uniform distribution and avoids color deviation, indicating the naturalness and accuracy of the low-light image enhancement model proposed in the present invention in color restoration. In the saturation space, the image generated by the low-light image enhancement model proposed in Example 1 shows a wider saturation distribution than the original image, reflecting its advantage in enhancing color richness. In the brightness space, the low-light image enhancement model proposed in Example 1 is shown to be effective in improving image brightness and maintaining details. The contrast is significantly improved, while the brightness gradient remains natural, highlighting the layering of the image.
[0072] (2) Objective indicator evaluation.
[0073] This test case uses an ablation experiment to verify the effectiveness of the dual-channel feature recovery unit (DCRU) and observe the changes in the loss function during training. The network structure configuration is shown in Table 1.
[0074] Table 1 Network structure configuration .
[0075] In the ablation experiment, the basic method uses a simple U-shaped network structure as the image enhancement module, while the method in Example 1 uses a U-shaped network structure with a nested DCRU. The horizontal axis of the loss function curve represents the number of model training times, and the vertical axis represents the loss function value. The loss function of the enhancement module changes as shown in the figure. Fig. 9 As shown. In the initial training stage, the loss values of both methods were high, but dropped rapidly. The loss reduction rate of the method provided in Example 1 was faster than that of the basic method, indicating that it was more efficient in the initial learning process. In the mid-term training stage, the downward trend of the loss value gradually stabilized. The method provided in Example 1 always showed lower loss values and less fluctuation, showing superior stability and convergence speed. In contrast, the basic method showed some fluctuations, indicating that there was instability during this period. In the final training stage, the loss values of the two methods tended to stabilize. The method provided in Example 1 maintained a significantly lower loss level. Fig. 9 The illustration in highlights the detailed changes in the loss in the later training stages (epochs 80 to 95), further emphasizing the stability and low loss values of the method proposed in Example 1.
[0076] After analyzing the changes in the loss function of the enhancement module, it is necessary to analyze the changes in the overall network loss function to comprehensively evaluate the training effect of the low-light image enhancement model. Fig.10 As shown, the overall loss function reflects the performance of the network structure design and training strategy. In the initial training stage, the overall loss of the network designed in Example 1 decreases rapidly, indicating that its efficiency is higher in the early stage of training. In contrast, the basic method decreases slowly, showing that its learning efficiency is lower than that of the network designed in Example 1. During the training process, the downward trend of the loss value gradually stabilizes. In the final training stage, the overall loss value tends to stabilize. The network designed in Example 1 maintains a significantly lower loss level than the basic method.
[0077] This test case calculates the performance index on the low-light train running image dataset, and uses the average method to calculate the index results of all images as the performance measurement standard of each low-light image enhancement method. The calculation results are shown in Table 2.
[0078] Table 2 Objective evaluation of the performance of various low-light image enhancement methods .
[0079] In the control group, the NeRCo method has the best PSNR index of 24.17, while the EnlightenGAN method has the best performance in SSIM and LPIPS, reaching 0.88 and 0.07. The method proposed in Example 1 is optimal in each index, with the three indexes of 27.9, 0.96 and 0.12 respectively, reflecting that the image restored by the low-light image enhancement model proposed in Example 1 has less loss and higher robustness in overall structure and details such as color and texture. Through comprehensive analysis and comparison, the outstanding performance of the present invention in the task of restoring low-light images of urban rail trains is demonstrated.
[0080] Of course, the above description is not a limitation of the present invention, and the present invention is not limited to the above examples. Changes, modifications, additions or substitutions made by technicians in this technical field within the essential scope of the present invention should also fall within the protection scope of the present invention.
Claims
1. A method for enhancing a trackside image, characterized in that: The following steps are involved: S1. Relying on the trackside equipment of the train trackside image detection system in the urban rail transit system to obtain train running images with a light intensity ranging from 0.1 to 10 lux; S2, performing preprocessing operations on the train running images collected in step S1, including image compression and data set division; S3. Establish a low-light image enhancement model based on a deep learning algorithm, wherein the low-light image enhancement model includes three parts: a dual-channel image restoration unit, a feature fusion module based on a 2D-DCT algorithm, and an image generation network; S4, inputting the train running image preprocessed in step S2 into the low-light image enhancement model, and training and testing the low-light image enhancement model; S5. According to the learning result of the low-light image enhancement model in step S4, adjust the network structure and parameter settings of the low-light image enhancement model to make the final image enhancement result more accurate, and save the final low-light image enhancement model.
2. The trackside image enhancement method according to claim 1, characterized in that: In step S3, a double loop strategy is adopted to realize bidirectional mapping between a low-light image and a normal-brightness image by stacking an image generation operation and an image degradation operation, wherein the low-light image refers to an image with a light intensity in the range of 0.1 to 10 lux; The bidirectional mapping operation is expressed as: , , where represents a low-light image, represents a normal brightness image, Indicates the highlight area, Indicates the low light range, represents the forward enhancement module, represents a reverse degradation module; the forward enhancement module and the reverse degradation module both perform feature extraction and reconstruction operations of the train running image.
3. The method for enhancing the trackside image according to claim 2, characterized in that: In step S3, the dual-channel image restoration unit is used to enhance the image quality of the low-light image. The dual-channel image restoration unit is composed of a global perception module, a local perception module and a feature fusion module. The global perception module is used to process the global dependency of pixels in the image, the local perception module is used to learn the image content, and the feature fusion module is used to enable the perception results of the global perception module and the local perception module to realize the interactive operation of feature information at different scales; The local perception module is designed by combining a multi-scale channel attention mechanism and a pixel attention mechanism.
4. The method for enhancing the trackside image according to claim 3, characterized in that: In step S3, the feature fusion module based on the 2D-DCT algorithm is used to reduce the feature loss of the output information of the global perception module and the local perception module during information interaction. The 2D-DCT algorithm formula is expressed as: ,in, and Represent the height and span of the feature map respectively, Indicates obtaining random values from the span values of multiple feature maps. Indicates obtaining random values from the height values of multiple feature maps. It is The span of feature maps, It is The height of the feature map, , , is the pixel value of the feature map in the spatial domain, It is the value of the feature map in the frequency domain after transformation; For an input feature map of a specific size, the 2D-DCT algorithm generates a coefficient matrix of the same size. In the feature fusion module, the two branches, the global perception module and the local perception module, respectively use the 2D-DCT algorithm to map the feature map from the spatial domain to the high-dimensional frequency domain and generate a coefficient matrix. and , as the weight of feature interaction; at the same time, the output features of the two branches are concatenated and compressed to generate a fusion feature, and an overall coefficient matrix is generated through the 2D-DCT algorithm ; In the process of feature interaction, through and The operation is to share knowledge, that is, one branch obtains its missing information from another branch through the coefficient matrix. The formula is: , , ,in, and are the output results of the global perception module and the local perception module, and It is the updated result generated by applying the 2D-DCT algorithm to the output results of the original global perception module and local perception module. and Used to control the contribution of different branches in the feature fusion process. Represents the final output result of the feature fusion module.
5. The method for enhancing the trackside image according to claim 4, characterized in that: In step S4, peak signal-to-noise ratio, structural similarity index and LPIPS are selected as evaluation indicators of image visual effects; The peak signal-to-noise ratio is based on the root mean square error function and is calculated as: , ,in, represents the brightness image generated by the low-light image enhancement model, represents the pixel extreme value in the image, represents the root mean square error, represents the peak signal-to-noise ratio; The structural similarity index comprehensively measures the image quality from three aspects: image brightness, structure and contrast. : ,in, and are the standard deviations of the normal brightness image and the brightness image generated by the low-light image enhancement model, is an image and The covariance between and They are images and The standard deviation of brightness, and are constants added to avoid the denominator being zero and are all set to 0.0001.
6. The method for enhancing the trackside image according to claim 5, characterized in that: In step S1, the trackside equipment includes an equipment start-up activation device, an intermediate control circuit, an image acquisition device, a trackside sensing antenna and a track vibration sensor.
Citation Information
Patent Citations
Auxiliary system for monitoring safety of region between platform safety door and vehicle door and realization method of auxiliary system
CN104691559A
Deep perceptual image enhancement
US20240062530A1
Cited By
Surface defect detection method based on channel enhancement and feature reconstruction
CN120298374A
