Day and night cross-domain vehicle re-identification methods, devices, systems, and storage media
By employing a network framework that combines style-aware domain normalization, dynamic illumination-aware structure enhancement, and cross-domain adaptive feature fusion, the problem of daytime and nighttime imaging condition differences in cross-domain vehicle re-identification is solved, achieving high-precision and low-cost daytime and nighttime vehicle recognition, which is suitable for intelligent transportation and city-level video surveillance.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- HUAZHONG UNIV OF SCI & TECH
- Filing Date
- 2026-04-03
- Publication Date
- 2026-06-30
AI Technical Summary
Existing technologies are unable to effectively mitigate the differences in imaging conditions between day and night, severe light interference, and structural feature degradation in cross-domain vehicle re-identification, leading to a decline in recognition performance. Furthermore, they rely on infrared equipment, which is costly and involves complex data collection and labeling.
A network framework that combines style-aware domain normalization, dynamic illumination-aware structure enhancement, and cross-domain adaptive feature fusion is adopted. Multi-level features are extracted through deep convolutional neural networks, and combined with multi-loss joint optimization and self-distillation constraint mechanism, to achieve cross-domain vehicle identity consistency discrimination between day and night.
Without relying on infrared equipment, it significantly improves the accuracy of vehicle re-identification at night, reduces deployment costs, enhances cross-domain generalization ability and recognition performance, and is suitable for intelligent transportation and city-level video surveillance systems.
Smart Images

Figure CN122313409A_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the field of intelligent transportation technology, specifically relating to a day-night cross-domain vehicle re-identification method, device, system, and storage medium. Background Technology
[0002] Vehicle Re-Identification (Vehicle Re-ID) refers to the process of retrieving images of target vehicles with the same identity as a given query vehicle from a large-scale vehicle image database within a distributed monitoring network composed of multiple cameras. It is one of the core technologies in intelligent transportation systems, smart cities, and public safety video surveillance. This technology can be widely applied in practical scenarios such as vehicle trajectory tracking, traffic violation evidence collection, key vehicle control, and road traffic efficiency assessment, and is of great significance for improving the intelligence and precision of urban traffic management.
[0003] Early research on single-modal (visible light) vehicle re-identification mainly focused on global appearance feature learning and metric learning. Some attribute-based studies utilize deep neural networks to integrate additional labeled vehicle attribute information, such as color, model, and manufacturer, to achieve joint learning of vehicle identity feature representations. Zhao et al. constructed a novel vehicle dataset, VAC21, based on the single-stage detection algorithm SSD, which contains 21 structural attributes. This method filters regions of interest through detector output and then extracts feature information related to vehicle identity. Liu et al.'s DRDL method uses a bi-branch convolutional neural network to map the original vehicle image to Euclidean space, effectively distinguishing vehicles with similar appearances. To address the significant appearance changes of vehicles under different viewpoints, Wang et al. proposed a viewpoint-invariant feature embedding mechanism. This method groups vehicle keypoints and orientations to perform region segmentation and alignment of vehicle images, thereby obtaining more robust features to perspective transformations. Furthermore, Zhou et al. designed two end-to-end deep learning architectures: spatially connected ConvNet and CNN-LSTM bidirectional loops. By integrating the advantages of the two architectures, they effectively capture the correlation between different viewpoints and support inference for missing viewpoints. While these global feature learning methods have demonstrated good performance, they still have limited discriminative power when distinguishing subtle differences between vehicles of the same type.
[0004] Despite significant progress in single-modal vehicle re-identification technology in visible light scenarios, the growing demand for all-weather monitoring in real-world intelligent transportation systems makes cross-modal vehicle re-identification, especially visible infrared (VI) re-identification, a critical challenge that urgently needs to be addressed.
[0005] Building upon research in multispectral pedestrian re-identification, some studies have explored the integration of RGB images from visible light cameras with near-infrared images from infrared cameras to address the limitations of visible light imaging in low-light environments at night. Li et al. pioneered visible-near-infrared multispectral vehicle re-identification. They not only constructed the first multimodal vehicle re-identification dataset, RGBN300 (including visible and near-infrared images), but also extended it to the RGBNT100 dataset, which includes thermal infrared images. Furthermore, they proposed a heterogeneous collaborative perceptual multi-stream convolutional network (HAMNet) to achieve end-to-end fusion of different spectral features. Kamenou et al. introduced an adversarial domain alignment model, which reduces the distribution gap between visible and infrared modes by learning a shared modal feature space and incorporating a domain discriminator. Guo et al. combined generative adversarial networks with attention mechanisms to address the problem of modal data imbalance. Their method integrates cross-modal infrared and visible data to enhance diversity while utilizing attention to highlight discriminative cross-modal features. He et al. proposed a progressive graph fusion network that integrates multimodal features (including visible and infrared data) using a staged strategy, while dynamically adjusting modal weights using graph attention to improve the representation of fine-grained details. Liu et al. developed a modal cross-graph sampling model that uses graph structures to capture the correlation between visible and infrared modalities and dynamically models the global and local feature interactions between modalities through graph node sampling.
[0006] Given the high cost of near-infrared and thermal infrared cameras, large-scale deployment in urban transportation networks remains impractical. Furthermore, the collection and annotation of multimodal data requires significant human resources, often resulting in incomplete or missing data. Meanwhile, most existing vehicle re-identification frameworks heavily rely on fully labeled datasets for model training. To address this challenge, researchers have turned their attention to cross-domain vehicle re-identification.
[0007] The core of these methods lies in learning discriminative, domain-invariant features by aligning the global feature distributions of the source and target domains. For example, Peng et al. proposed the DAN framework, which employs a two-branch adversarial network architecture. An image transformation module is used to map source domain image styles to the target domain, eliminating dependence on spatiotemporal labels and attribute information. Wei et al. introduced a Domain-Specific Representation (TDSR) network based on a Transformer architecture, combining learnable domain encoding mechanisms tailored to both the source and target domains. This guides the model to focus on domain-specific details, such as resolution differences and lighting conditions. Furthermore, a contrastive clustering loss (CCL) is introduced to optimize the feature distribution at the cluster level, improving intra-cluster compactness. Zhang et al. proposed AIVR-Net, an attribute-invariant representation network built within a two-branch learning framework. One branch preserves global and attribute features, while the other branch uses a feature suppression module to remove attribute-specific information, enhancing cross-domain discriminative capabilities. Kuang et al. designed a joint deentanglement method at the image and feature levels: at the image level, a variational autoencoder reconstructs the original image, extracts identity-related features, and suppresses confounding factors such as background and lighting; at the feature level, a bi-branch classification network improves the discrimination performance by orthogonalizing identity-related features and identity-independent features.
[0008] While existing cross-domain vehicle re-identification methods have made significant progress in minimizing inter-domain differences, most methods overemphasize global feature alignment. They often neglect the crucial role of structural information in cross-domain matching and the impact of style variations between domains. To address these issues, there is an urgent need to propose a novel cross-domain vehicle re-identification method that can simultaneously consider style adaptation and structural modeling to improve its practical application performance in complex traffic scenarios. Summary of the Invention
[0009] To address the problems existing in the prior art, this invention provides a day-night cross-domain vehicle re-identification method, device, system, and storage medium. It addresses issues in real-world intelligent transportation scenarios, such as significant differences in imaging conditions between day and night, severe light interference, obvious degradation of structural features, and inconsistent cross-domain feature distribution. It achieves high-precision day-night vehicle re-identification without relying on infrared equipment, balancing recognition performance and deployment costs, and is suitable for intelligent transportation, public safety, and city-level video surveillance systems.
[0010] To achieve the above objectives, the present invention provides the following solution: A day-night cross-domain vehicle re-identification method includes: Step S1: Based on the original vehicle image data, obtain multi-scale vehicle feature maps through a feature extraction network; Step S2: Based on the multi-scale vehicle feature maps, construct a vehicle re-identification network that integrates style perception domain normalization, dynamic illumination perception structure enhancement, and cross-domain adaptive feature fusion. Step S3: Based on the vehicle re-identification network, achieve cross-domain vehicle identity consistency determination between day and night through multi-loss joint optimization and self-distillation constraint mechanism.
[0011] In step S1, by constructing day and night dual-domain vehicle data input, a deep convolutional neural network is used to extract multi-level feature representations.
[0012] In step S2, a style perception domain normalization module is designed to enhance style diversity in the shallow layers of the network and retain domain-specific statistical characteristics in the deep layers. A dynamic illumination perception structure enhancement module is introduced to adaptively suppress strong light areas and dark areas at night and enhance vehicle structure contour information through multi-scale pixel gradients. At the same time, a cross-domain adaptive feature fusion module is designed to construct an explicit spatial correspondence between day and night vehicle features and achieve accurate cross-domain feature alignment.
[0013] The present invention also provides a day-night cross-domain vehicle re-identification device, comprising: The first processing module is used to obtain multi-scale vehicle feature maps based on the original vehicle image data through a feature extraction network; The second processing module is used to construct a vehicle re-identification network that integrates style perception domain normalization, dynamic illumination perception structure enhancement, and cross-domain adaptive feature fusion based on multi-scale vehicle feature maps. The third processing module is used to achieve cross-domain vehicle identity consistency determination based on the vehicle re-identification network through multi-loss joint optimization and self-distillation constraint mechanism.
[0014] As a preferred approach, the first processing module constructs dual-domain vehicle data input for both day and night and utilizes a deep convolutional neural network to extract multi-level feature representations.
[0015] Preferably, the second processing module includes: The first processing unit is used to design a style-aware domain normalization module, which enhances style diversity in the shallow layers of the network and preserves domain-specific statistical characteristics in the deep layers of the network. The second processing unit is used to introduce a dynamic illumination sensing structure enhancement module to adaptively suppress strong light areas and dark areas at night, and to enhance the vehicle structure contour information through multi-scale pixel gradients. The third processing unit is used to design a cross-domain adaptive feature fusion module, construct an explicit spatial correspondence between day and night vehicle features, and achieve accurate cross-domain feature alignment.
[0016] The present invention also provides a day and night cross-domain vehicle re-identification system, comprising: a memory and a processor, wherein the memory stores a computer program executed by the processor, and the computer program executes a day and night cross-domain vehicle re-identification method when executed by the processor.
[0017] The present invention also provides a storage medium storing a computer program, which executes a day-night cross-domain vehicle re-identification method when running.
[0018] This invention constructs a vehicle re-identification network framework that integrates style-aware domain normalization, dynamic illumination-aware structure enhancement, and cross-domain adaptive feature fusion. The method first constructs dual-domain vehicle data input for day and night, and extracts multi-level feature representations using a deep convolutional neural network. Second, a style-aware domain normalization module is designed to enhance style diversity in the shallow layers of the network and preserve domain-specific statistical characteristics in the deeper layers. Furthermore, a dynamic illumination-aware structure enhancement module is introduced to adaptively suppress strong light and dark areas at night, and to enhance vehicle structural contour information through multi-scale pixel gradients. Simultaneously, a cross-domain adaptive feature fusion module is designed to construct an explicit spatial correspondence between day and night vehicle features, achieving accurate cross-domain feature alignment. Finally, cross-domain vehicle identity consistency is achieved through multi-loss joint optimization and a self-distillation constraint mechanism. This method achieves high-precision day and night vehicle re-identification without relying on infrared equipment, balancing recognition performance and deployment costs, and is suitable for intelligent transportation, public safety, and city-level video surveillance systems. Compared with existing technologies, the beneficial effects of this invention are: (1) Low deployment cost and strong engineering adaptability. In the process of vehicle re-identification, this invention only relies on day and night vehicle image data acquired by ordinary visible light camera equipment for model training and inference. It does not require the introduction of high-cost imaging equipment such as near-infrared or thermal infrared, nor does it rely on complex multimodal data acquisition and annotation processes, which effectively reduces the system deployment and maintenance costs. At the same time, through cross-domain feature learning and style adaptive modeling, the accuracy of nighttime vehicle re-identification is significantly improved without increasing hardware costs, which has good engineering application value.
[0019] (2) Strong cross-domain generalization ability and significantly improved day and night recognition performance. This invention introduces style-aware domain normalization and cross-domain adaptive feature fusion mechanism to fully explore the intrinsic correlation information between daytime and nighttime vehicle images during training, effectively alleviating the feature distribution shift problem caused by the difference in day and night imaging conditions. As the scale of cross-domain training samples increases, the model can continuously improve its cross-domain feature alignment ability, not only stably recognizing the same vehicle under daytime and nighttime conditions, but also maintaining a high recognition accuracy under complex lighting changes and cross-scene conditions.
[0020] (3) Strong structural discrimination capability and stable and reliable recognition results. This invention enhances the modeling capability of vehicle geometric contours and structural information through a dynamic illumination perception structure enhancement module, reducing the impact of strong light, dark areas and noise interference at night on feature extraction. At the same time, combined with a self-distillation constraint mechanism, it guides nighttime features to align with the stable feature space during the day, enabling the model to maintain stable re-recognition performance under complex environment and noise interference conditions, effectively reducing the false matching rate and improving the reliability and robustness of cross-domain vehicle matching results. Attached Figure Description
[0021] To more clearly illustrate the technical solution of the present invention, the drawings used in the embodiments are briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0022] Figure 1 This is a flowchart of the day-night cross-domain vehicle re-identification method according to an embodiment of the present invention; Figure 2 This is a schematic diagram of the day-night cross-domain vehicle re-identification task in an embodiment of the present invention; Figure 3 This is an overall framework diagram of the SSCL model in this embodiment of the invention; Figure 4 This is a structural diagram of the internal structure of the dynamic lighting sensing structure enhancement module in the embodiment of the invention; Figure 5 This is a diagram showing the internal structure of the cross-domain adaptive feature fusion module in an embodiment of the invention. Figure 6 is a bar chart comparing the core metrics (mAP, Rank-1, Rank-5) of the present invention and existing technologies (AGW, DEEN, SSDViT, DNDM, etc.) on the DN-348 and DN-Wild datasets, where: Figure 6(a) is a schematic diagram of the mAP index comparison on the DN-348 dataset; Figure 6(b) is a schematic diagram showing the comparison of mAP metrics on the DN-Wild dataset; Figure 6(c) is a schematic diagram of the Rank-1 metric comparison on the DN-348 dataset; Figure 6(d) is a schematic diagram of the Rank-1 metric comparison on the DN-Wild dataset; Figure 6(e) is a schematic diagram of the Rank-5 metric comparison on the DN-348 dataset; Figure 6(f) is a schematic diagram of the Rank-5 metric comparison on the DN-Wild dataset. Detailed Implementation
[0023] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.
[0024] To make the above-mentioned objects, features and advantages of the present invention more apparent and understandable, the present invention will be further described in detail below with reference to the accompanying drawings and specific embodiments.
[0025] Example 1 The following section first explains the technical terms and related definitions involved in this invention: Cross-domain vehicle re-identification during day and night: refers to the technical process of matching and identifying vehicle images collected in different imaging domains, such as daytime and nighttime, under the condition of relying solely on visible light camera equipment, in order to determine whether they belong to the same vehicle. Its core difficulty lies in the feature distribution shift caused by differences in lighting, style, and imaging quality.
[0026] Style differences refer to the statistical characteristics of vehicle images at different times or under different imaging conditions, caused by factors such as changes in light intensity, color distribution, and contrast. This is one of the main reasons for the decline in cross-domain vehicle re-identification performance.
[0027] Structural features refer to the geometric contours, edge distribution, and spatial layout information of a vehicle in an image. Compared to appearance texture features, they are more stable to changes in illumination and are an important criterion for cross-domain vehicle re-identification.
[0028] Style-aware domain normalization: This invention proposes a feature normalization mechanism that achieves adaptive modeling of style differences between daytime and nighttime vehicle images by mixing and modeling feature statistics from different domains during the training phase, thereby improving the model's cross-domain generalization ability.
[0029] Dynamic Illumination-Aware Structure Enhancement: A feature enhancement strategy designed for nighttime vehicle images. By explicitly modeling the distribution of bright and dark areas, it enhances the extraction capability of vehicle geometric structure information and reduces the interference of complex lighting conditions on feature representation.
[0030] Cross-domain adaptive feature fusion: A feature fusion mechanism for explicitly modeling the correspondence between daytime and nighttime vehicle feature spaces. Through adaptive matching and attention weighting, it achieves accurate alignment of daytime and nighttime vehicle features.
[0031] Self-distillation constraint: A feature constraint strategy during the training phase that uses daytime vehicle features as a stable reference to guide nighttime vehicle features to align with a unified discriminative feature space, thereby improving the stability and robustness of cross-domain vehicle re-identification.
[0032] Multi-scale features: Feature representations extracted from different levels of the backbone network are used to simultaneously characterize the local details and global semantic structure of the vehicle.
[0033] To address the key issues existing in current day-night cross-domain vehicle re-identification technologies, the main solutions proposed in this invention are as follows: Regarding the first key technical point—how to mitigate the significant style differences between daytime and nighttime vehicle images when relying solely on visible light imaging equipment—this invention designs a style-aware domain normalization module. Through hybrid modeling and adaptive normalization of feature statistics from different domains, it enhances the model's adaptability to lighting changes while maintaining semantic consistency. Regarding the second key technical point—how to improve the accuracy of nighttime vehicle re-identification without introducing high-cost hardware—this invention introduces a dynamic illumination-aware structure enhancement module. This module strengthens the modeling of geometric contours and structural information in nighttime vehicle images, reducing the impact of complex lighting conditions such as strong light and dark areas on the feature extraction process. Regarding the third key technical point—how to improve the stability and matching accuracy of cross-domain vehicle feature alignment—this invention constructs a cross-domain adaptive feature fusion mechanism. By explicitly modeling the spatial correspondence between daytime and nighttime vehicle features, it achieves accurate alignment and fusion of cross-domain features. Regarding the fourth key technical issue, namely how to fully explore the potential valuable information between daytime and nighttime features during model training and use it for model optimization, this invention introduces a self-distillation constraint mechanism. By utilizing the stability of daytime vehicle features, it guides nighttime features toward a unified discriminative feature space, thereby improving the training stability and cross-domain generalization ability of the model.
[0034] like Figure 2 As shown, the main task of this invention is to alleviate the inter-domain differences in vehicle images during the day and night in the feature embedding space, and to achieve accurate matching and recognition of the same vehicle identity under different imaging conditions.
[0035] like Figure 3As shown, the overall framework of this invention mainly consists of two parts: a style-structure collaborative feature learning network and cross-domain discriminative optimization. Specifically, the style-structure collaborative feature learning network includes a backbone feature extraction network, a style-aware domain normalization module (SADN), a dynamic illumination-aware structure enhancement module (DISE), and a cross-domain adaptive feature fusion module (CDAFF), used for multi-scale feature extraction, style difference modeling, and structural information enhancement of vehicle images during daytime and nighttime. The cross-domain discriminative optimization includes a global average pooling unit, a classification loss function, a triplet loss function, and a self-distillation constraint loss, used for discriminative constraints and consistency optimization of cross-domain vehicle features. To drive the model to learn shared discriminative representations of vehicle features in both daytime and nighttime domains simultaneously during training, this invention designs a collaborative learning mechanism based on joint optimization of style constraints, structure enhancement, and self-distillation. Through the combined effect of domain loss, metric loss, and distillation loss, it guides vehicle features under different imaging conditions to gradually align to a unified embedding space, ultimately obtaining stable and discriminative vehicle feature representations across day and night conditions.
[0036] like Figure 4 As shown, this invention provides a specific implementation process for a dynamic illumination-sensing structure enhancement module. Specifically, nighttime vehicle images first obtain nighttime feature representations at the corresponding scale through a feature extraction network. These features are then concatenated with a mask generated from the image, and a mapping operation is performed to generate self-learning weights. These self-learning weights are used to characterize the distribution of bright and dark areas in the nighttime scene, guiding the subsequent feature enhancement process. Subsequently, element-wise multiplication and subtraction operations are used to suppress unstructured interference information in the nighttime features, while highlighting structurally relevant regions such as vehicle outlines and edges. After the above operations, enhanced features are obtained. Then, multi-scale pixel-wise gradient extraction of vehicle structural information yields a structural descriptor, which is further enhanced by element-wise multiplication and addition operations. The introduction of this module enables the model to stably extract discriminative vehicle structural features even under complex nighttime illumination conditions, thereby improving the robustness of cross-day / night vehicle re-identification.
[0037] like Figure 5As shown, this invention presents the overall processing flow of the style-aware domain normalization module. Specifically, daytime and nighttime vehicle images obtain corresponding feature maps through a shared feature extraction network. Taking daytime features as an example, a set of cross-domain adaptive convolutional kernels is dynamically constructed using daytime vehicle features. These online convolutional kernels are then applied to the nighttime feature maps, and a similarity matrix is obtained through convolution operations. Based on this similarity matrix, the corresponding mapping related to the query image can be obtained along the channel dimension. This mechanism emphasizes the local features most relevant to the query. It not only employs an adaptive matching strategy but also generates corresponding weight matrices by identifying attention regions in different domains. This process enhances cross-domain feature interaction and significantly improves matching accuracy in complex scenes.
[0038] like Figure 1 As shown, the day-night cross-domain vehicle re-identification method based on style-structure co-learning proposed in this invention includes the following steps: (1) Design a vehicle re-identification backbone network and construct a day and night dual-domain input. (1.1) Constructing a day and night dual-domain input sample set: in, and These represent image samples of the same vehicle collected under daytime and nighttime conditions, respectively. For the corresponding vehicle identification tag Domain labels are used to distinguish between daytime and nighttime samples, thus providing supervision information for subsequent cross-domain feature modeling. (1.2) Extracting multi-scale features using a backbone network: in, This represents the feature extraction mapping function for the s-th residual stage. The vehicle features obtained at the corresponding scale and in the corresponding domain are shown, which are used to simultaneously characterize local texture information and high-level semantic structure information.
[0039] (1.3) During model training, since lower layers contain richer spatial and visual features, domain classification loss is introduced during training to constrain the parameters of these lower layers and improve the model's ability to distinguish cross-domain categories. The domain classification loss is defined as follows: in, This represents a fully connected layer used for domain category classification. This represents the Softmax function used to normalize the prediction results. This indicates the actual label. It is a standard cross-entropy loss function that quantifies the difference between the predicted label and the true label based on the model's final probability distribution.
[0040] (1.4) For the parameter constraints of the subsequent stages of the backbone network, a joint optimization is performed using labeled smooth cross-entropy loss and triplet loss. The loss function is defined as follows: in This represents the fully connected layer used for vehicle identity prediction. A tag indicating the true identity of the vehicle. This represents the cross-entropy loss after label smoothing.
[0041] The definition of triplet loss is as follows: in and Let represent the Euclidean distances between the anchor point and the positive sample, and between the anchor point and the negative sample in the i-th triplet, respectively. The parameter m is the residual of the triplet loss, which constrains the minimum distance difference between the positive and negative samples.
[0042] (1.5) To guide nighttime features to focus on identity-related information and reduce cross-domain feature differences between day and night, a self-distillation loss function is introduced. The daytime feature branch acts as the teacher model, and the nighttime feature branch acts as the student model, guiding the alignment of the nighttime feature space with the daytime feature space. The soft-label self-distillation loss based on KL divergence is defined as: In the formula, P represents the probability distribution of cross-domain features calculated using the Softmax function. KL represents the Kullback-Leibler divergence function. By minimizing the KL divergence, the night-domain feature distribution is encouraged to approximate the day-domain feature distribution. In addition to the soft label loss, a feature-level self-distillation loss based on mean squared error (MSE) is introduced: In the formula, W is the characteristic dimension, and the final self-distillation loss can be expressed as: (2) Construct a style-aware domain normalization module and adopt differentiated normalization strategies at different network depths to reduce cross-domain style bias while retaining distinctive features.
[0043] (2.1) First, calculate the mean and standard deviation of each channel in the entire batch as follows: Where B represents the batch size, and H and W represent the height and width of the feature map, respectively.
[0044] (2.2) For each feature instance A new batch is constructed by randomly selecting B / 2 samples from the opposite domain. The mean and standard deviation of this new batch are then calculated. in This represents the mixture coefficients sampled from the Beta distribution, and the features are then normalized and scaled using the corresponding mixture statistics: (2.3) A domain-specific normalization strategy is employed in the later stages of the network. A set of parameters is used for normalization when processing daytime images, while another set is used for nighttime images. The normalization process is defined as follows: (3) Construct a dynamic lighting perception structure enhancement module to enhance vehicle features by effectively separating structural information from the light, and further enhance structural details by combining multi-scale, pixel-by-pixel gradient information.
[0045] (3.1) First, the RGB image from the night domain is converted into a luminance map, where , and This represents the pixel value of the image in its respective channel. The brightness conversion process is as follows: (3.2) Gaussian filtering is applied to the initially calculated brightness map. Gaussian filtering effectively suppresses high-frequency noise while maintaining the overall brightness distribution, thereby enhancing the robustness of threshold-based segmentation. Specifically: in This represents a two-dimensional convolution operation. This represents a two-dimensional Gaussian kernel.
[0046] (3.3) Based on the generated luminance map, regions with luminance values exceeding a predefined fixed threshold are identified as bright light regions, and regions with luminance values below the fixed threshold are classified as dark regions. Using this criterion, a corresponding binary mask M is generated, and a learnable final mask is generated using this mask as follows: in This represents a tensor concatenation operation that connects the vehicle feature tensor to the mask along the channel dimension. FC (Fully Connected) is a fully connected layer used to compress the channel dimension. BN and ReLU represent batch normalization and activation functions, respectively.
[0047] (3.3) The vehicle-related features obtained after decoupling from strong light and dark environment interference are as follows: (3.4) At multiple spatial scales Define pixel-wise gradient features Each scale corresponds to a size of The local window is designed to capture structural information at different granular levels, where The formula for calculating pixel-wise gradient features is as follows: Where x represents the pixel position on the feature map, and c represents the channel index. This represents the adjacent positions within a local region surrounding each pixel x. The size of this region is... ,in .
[0048] (3.5) To further enhance structural representation, a feature weighting operation is introduced, which integrates fine-grained local gradients into a compact structural descriptor, thereby facilitating the learning of vehicle geometric features: (3.6) This structure descriptor is then used as auxiliary input to enhance the original appearance representation: (4) Construct a cross-domain adaptive feature fusion module to dynamically generate convolution kernels based on the features of the query image and use these kernels to adaptively match the features of the image library.
[0049] (4.1) First, a set of cross-domain adaptive convolutional kernels is dynamically constructed from the daytime feature map and the nighttime feature map. This is applied to each channel of the daytime and nighttime feature maps to ensure consistent feature scaling. Then, a size of [size missing] is extracted from each spatial location of the query feature map. The local block is reconstructed into a dimension of The convolution kernel is denoted by c, where c is the number of input channels and hw is the number of output channels corresponding to the spatial location.
[0050] (4.2) The cross-domain adaptive kernel generated by the dynamic construction mechanism is applied to the nighttime feature map through convolution to obtain a dimension of The similarity matrix is used to obtain the response mapping. Based on this similarity matrix, global max pooling is performed along the channel dimension. For response mapping First, normalize it as follows: in It is a very small constant used to prevent division by 0.
[0051] (4.3) Based on the above weights, the corresponding spatial features in the daytime image can be selectively enhanced. Similarly, the response map obtained from the daytime image can be used to enhance the nighttime features using a similar method. The specific operation process is as follows: Figure 6 is a bar chart comparing the core metrics (mAP, Rank-1, Rank-5) of the present invention and existing technologies (AGW, DEEN, SSDViT, DNDM, etc.) on the DN-348 and DN-Wild datasets, where: Figure 6(a) is a schematic diagram of the mAP metric comparison on the DN-348 dataset; Figure 6(b) is a schematic diagram of the mAP metric comparison on the DN-Wild dataset; Figure 6(c) is a schematic diagram of the Rank-1 metric comparison on the DN-348 dataset; Figure 6(d) is a schematic diagram of the Rank-1 metric comparison on the DN-Wild dataset; Figure 6(e) is a schematic diagram of the Rank-5 metric comparison on the DN-348 dataset; Figure 6(f) is a schematic diagram of the Rank-5 metric comparison on the DN-Wild dataset. Figure 6 demonstrates the versatility of the method of this invention under different imaging conditions and application scenarios. Despite the influence of factors such as differences in imaging between day and night, changes in cross-domain feature distribution, and different training sample sizes, the day-night cross-domain vehicle re-identification method proposed in this invention can still maintain relatively stable recognition performance, indicating that the method has good robustness to changes in illumination, style differences, and data distribution shifts.
[0052] Example 2 The present invention also provides a day-night cross-domain vehicle re-identification device, comprising: The first processing module is used to obtain multi-scale vehicle feature maps based on the original vehicle image data through a feature extraction network; The second processing module is used to construct a vehicle re-identification network that integrates style perception domain normalization, dynamic illumination perception structure enhancement, and cross-domain adaptive feature fusion based on multi-scale vehicle feature maps. The third processing module is used to achieve cross-domain vehicle identity consistency determination based on the vehicle re-identification network through multi-loss joint optimization and self-distillation constraint mechanism.
[0053] As one embodiment of the present invention, the first processing module constructs day and night dual-domain vehicle data input and uses a deep convolutional neural network to extract multi-level feature representations.
[0054] As one embodiment of the present invention, the second processing module includes: The first processing unit is used to design a style-aware domain normalization module, which enhances style diversity in the shallow layers of the network and preserves domain-specific statistical characteristics in the deep layers of the network. The second processing unit is used to introduce a dynamic illumination sensing structure enhancement module to adaptively suppress strong light areas and dark areas at night, and to enhance the vehicle structure contour information through multi-scale pixel gradients. The third processing unit is used to design a cross-domain adaptive feature fusion module, construct an explicit spatial correspondence between day and night vehicle features, and achieve accurate cross-domain feature alignment.
[0055] Example 3 The present invention also provides a day and night cross-domain vehicle re-identification system, comprising: a memory and a processor, wherein the memory stores a computer program executed by the processor, and the computer program executes a day and night cross-domain vehicle re-identification method when executed by the processor.
[0056] Example 4 The present invention also provides a storage medium storing a computer program, which executes a day-night cross-domain vehicle re-identification method when running.
[0057] The embodiments described above are merely preferred embodiments of the present invention and are not intended to limit the scope of the present invention. Various modifications and improvements made by those skilled in the art to the technical solutions of the present invention without departing from the spirit of the present invention should fall within the protection scope defined by the claims of the present invention.
Claims
1. A method for cross-domain vehicle re-identification during day and night, characterized in that, include: Step S1: Based on the original vehicle image data, obtain multi-scale vehicle feature maps through a feature extraction network; Step S2: Based on the multi-scale vehicle feature map, construct a vehicle re-identification network that integrates style perception domain normalization, dynamic illumination perception structure enhancement, and cross-domain adaptive feature fusion. Step S3: Based on the vehicle re-identification network, achieve cross-domain vehicle identity consistency determination between day and night through multi-loss joint optimization and self-distillation constraint mechanism.
2. The day-night cross-domain vehicle re-identification method as described in claim 1, characterized in that, In step S1, by constructing day and night dual-domain vehicle data input, a deep convolutional neural network is used to extract multi-level feature representations.
3. The day-night cross-domain vehicle re-identification method as described in claim 2, characterized in that, In step S2, a style perception domain normalization module is designed to enhance style diversity in the shallow layers of the network and retain domain-specific statistical characteristics in the deep layers. A dynamic illumination perception structure enhancement module is introduced to adaptively suppress strong light areas and dark areas at night and enhance vehicle structure contour information through multi-scale pixel gradients. At the same time, a cross-domain adaptive feature fusion module is designed to construct an explicit spatial correspondence between day and night vehicle features and achieve accurate cross-domain feature alignment.
4. A day-night cross-domain vehicle re-identification device, characterized in that, include: The first processing module is used to obtain multi-scale vehicle feature maps based on the original vehicle image data through a feature extraction network; The second processing module is used to construct a vehicle re-identification network that integrates style perception domain normalization, dynamic illumination perception structure enhancement, and cross-domain adaptive feature fusion based on multi-scale vehicle feature maps. The third processing module is used to achieve cross-domain vehicle identity consistency determination based on the vehicle re-identification network through multi-loss joint optimization and self-distillation constraint mechanism.
5. The day and night cross-domain vehicle re-identification device as described in claim 4, characterized in that, The first processing module constructs dual-domain vehicle data input for both day and night, and uses a deep convolutional neural network to extract multi-level feature representations.
6. The day and night cross-domain vehicle re-identification device as described in claim 5, characterized in that, The second processing module includes: The first processing unit is used to design a style-aware domain normalization module, which enhances style diversity in the shallow layers of the network and preserves domain-specific statistical characteristics in the deep layers of the network. The second processing unit is used to introduce a dynamic illumination sensing structure enhancement module to adaptively suppress strong light areas and dark areas at night, and to enhance the vehicle structure contour information through multi-scale pixel gradients. The third processing unit is used to design a cross-domain adaptive feature fusion module, construct an explicit spatial correspondence between day and night vehicle features, and achieve accurate cross-domain feature alignment.
7. A day-night cross-domain vehicle re-identification system, characterized in that, include: A memory and a processor, wherein the memory stores a computer program executed by the processor, the computer program performing the day-night cross-domain vehicle re-identification method as described in any one of claims 1-3 when executed by the processor.
8. A storage medium, characterized in that, The storage medium stores a computer program that, when executed, performs the day-night cross-domain vehicle re-identification method as described in any one of claims 1-3.