A small sample radiation source identification method based on contrast alignment and bayesian fine tuning
By using temporal confusion enhancement and contrastive self-supervised training structure, and leveraging weighted contrastive alignment loss and Bayesian classifier, the problems of insufficient feature discrimination ability and low robustness in small sample radiation source identification are solved, achieving efficient radiation source identification in noisy environments.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- DALIAN MARITIME UNIVERSITY
- Filing Date
- 2026-03-25
- Publication Date
- 2026-07-03
Smart Images

Figure CN122333151A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of radiation source identification technology, specifically to a small-sample radiation source identification method based on contrast alignment and Bayesian fine-tuning. Background Technology
[0002] With the rapid development of wireless communication technology, communication security issues have become increasingly prominent. The open broadcast nature of wireless channels makes traditional communication links vulnerable to spoofing attacks and illegal eavesdropping, seriously threatening the security of communication systems. Specific Emitter Identification (SEI), a passive physical layer authentication technology based on Radio Frequency Fingerprint (RFF), accurately distinguishes different radiator devices by analyzing the differences in transmitter hardware characteristics contained in wireless signals. This technology plays an important role in scenarios such as illegal device detection, communication anti-counterfeiting, and data confidentiality, and is one of the key technologies for building a secure communication system. However, in non-cooperative scenarios, due to the difficulty in obtaining device identification tags, the scarcity of labeled data, and the limited scope of the scenarios, the SEI task faces the challenge of small sample sizes. Traditional supervised learning methods rely on a large amount of labeled data, which is prone to overfitting under small sample conditions, leading to a decrease in model generalization ability and affecting the accuracy of device identification.
[0003] Currently, researchers have introduced self-supervised learning methods to address the problem of identifying specific radiation sources with small sample sizes. These methods learn general feature representations from unlabeled data by designing auxiliary tasks, and then fine-tune the model using a small amount of labeled data to reduce reliance on labeled data. However, existing methods typically focus only on feature alignment or feature comparison, failing to effectively coordinate the optimization of intra-class compactness and inter-class separability of features. This results in insufficient discriminative power of pre-trained features in downstream tasks. Furthermore, existing methods exhibit poor robustness to data noise and variations in sample distribution, making it difficult to effectively mitigate overfitting and limiting their practical application in complex electromagnetic environments. Therefore, how to learn more discriminative and consistent RF fingerprint features during self-supervised pre-training and improve model robustness during fine-tuning has become a crucial problem that urgently needs to be solved in the identification of specific radiation sources with small sample sizes. Summary of the Invention
[0004] To address the aforementioned technical problems of insufficient feature discrimination ability, low robustness in the fine-tuning stage, and significant overfitting, this invention provides a small-sample radiation source identification method based on contrastive alignment and Bayesian fine-tuning. This invention primarily utilizes temporal confusion enhancement and contrastive self-supervised training structures in the pre-training stage, updates the feature extractor using weighted contrastive alignment loss, and maps different radiation source device labels using a Bayesian classifier. This accelerates feature convergence, reduces reliance on large amounts of labeled data during training, and enhances robustness in noisy and interference environments.
[0005] The technical means employed in this invention are as follows:
[0006] A method for identifying small-sample radiation sources based on contrast alignment and Bayesian fine-tuning includes the following steps: The raw radio frequency signal is acquired, the raw radio frequency signal is preprocessed, and the preprocessed raw radio frequency signal is divided into an unlabeled dataset, a labeled dataset, and a test set. The unlabeled data is augmented in the first and second ways. The first augmented view and the second augmented view are passed through the first feature extractor and the second feature extractor, respectively. A weighted contrast alignment loss is calculated based on the output of the first feature extractor and the output of the second feature extractor. The weighted contrast alignment loss is used in the second extractor. Then, the momentum of the first extractor is updated to obtain the pre-trained second feature extractor. The labeled dataset is passed sequentially through a third feature extractor and a Bayesian classifier. The third feature extractor is obtained by transfer learning from the pre-trained second feature extractor. The Bayesian classifier is built based on MC-Dropout. The Bayesian classifier outputs predicted labels. The cross-entropy loss is calculated using the predicted labels and the original labels. The cross-entropy loss can minimize the difference between the predicted labels and the original labels. The cross-entropy loss is fed back to the third feature extractor. The test set is sequentially input into the third feature extractor and the Bayesian classifier to obtain the radiation source identification results.
[0007] Further, the preprocessing of the original radio frequency signal includes: The I component in the original radio frequency signal is taken as the real part of the complex signal, and the Q component is taken as the imaginary part of the complex signal. IQ dual-channel components are constructed based on the real and imaginary parts of the complex signal; A radio frequency (RF) IQ sequence is constructed based on the IQ dual-channel components, and the RF IQ sequence is normalized to obtain the preprocessed original RF signal.
[0008] Furthermore, the first enhancement includes: Gaussian white noise is added to the input signal, and the signal after noise is added is randomly divided into several segments and time-series rearranged to obtain the first enhanced view. The second enhancement includes: By introducing rotation and flipping into the input signal and applying a phase-controlled perturbation, a second enhanced view is obtained.
[0009] Furthermore, the first feature extractor and the second feature extractor have the same structure. The first feature extractor includes an RFF feature extractor and a projection head. The RFF feature extractor includes an encoder with 9 complex-valued convolutional layers and 1 fully connected layer. The second feature extractor optimizes the parameters of the first feature extractor using the exponential moving average method.
[0010] Furthermore, the calculation process of the weighted contrast alignment loss includes: The outputs of the first feature extractor and the second feature extractor are normalized respectively. Calculate the mean squared error loss of the outputs of the first feature extractor after normalization and the outputs of the second feature extractor after normalization; Calculate the contrast loss between the outputs of the first feature extractor and the outputs of the second feature extractor. The formula for calculating the contrast loss is as follows:
[0011] in, To compare the losses, This represents the total number of unlabeled data samples. For the first i The output of the second feature extractor after normalization. For the first i The output of the first feature extractor after normalization. For the first j The output of the first feature extractor after normalization. For the first j The output of the second feature extractor after normalization. Temperature coefficient; A weighted contrast alignment loss is constructed using mean squared error loss and contrast loss. The formula for calculating the weighted contrast alignment loss is as follows:
[0012] in, To weight the alignment loss, For adjustable weight parameters, This represents the mean square error loss.
[0013] Furthermore, the Bayesian classifier includes several parallel inference modules, each including a connected Dropout layer and a fully connected layer. The label prediction result is obtained by using the output of the third feature extractor from each inference module, and the mean of the label prediction results is calculated as the predicted label.
[0014] Furthermore, the formula for calculating the cross-entropy loss is as follows: ; in, For cross-entropy loss, The number of samples in the labeled data. For the original tag, For predicted labels.
[0015] Compared with the prior art, the present invention has the following advantages: This invention employs a temporal confusion enhancement and symmetric contrastive training structure design in its few-sample radiation source identification method based on contrastive alignment and Bayesian fine-tuning, which accelerates feature convergence. Simultaneously, it utilizes weighted contrastive alignment loss to enhance the intra-class compactness and inter-class separability of features, eliminating reliance on large amounts of labeled data. Finally, a Bayesian classifier is used to map different radiation source device labels while enhancing the model's robustness in noisy and interference environments. Furthermore, this method can directly process complex radio frequency signals, making it suitable for various non-cooperative communication scenarios such as the Internet of Things and drones, and possesses significant engineering application value.
[0016] Based on the above reasons, this invention can be widely applied in fields such as radiation source identification. Attached Figure Description
[0017] To more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0018] Figure 1 This is a technical roadmap for the small-sample radiation source identification method based on contrast alignment and Bayesian fine-tuning of the present invention.
[0019] Figure 2 This is a flowchart of the small-sample radiation source identification system based on contrast alignment and Bayesian fine-tuning according to the present invention.
[0020] Figure 3 This is a two-dimensional feature distribution map plotted to illustrate the influence of hyperparameter α in the weighted comparison alignment module of this invention.
[0021] Figure 4This is a three-dimensional visual representation of the robustness of the model of the present invention and existing methods under different numbers of labeled samples.
[0022] Figure 5 This is a spatial distribution map of radio frequency fingerprint features extracted by the feature extractor after fine-tuning the present invention and existing methods.
[0023] Figure 6 This is a line graph comparing the recognition accuracy of the present invention and existing methods under different numbers of labeled samples. Detailed Implementation
[0024] To enable those skilled in the art to better understand the present invention, the technical solutions of the present invention will be clearly and completely described below with reference to the accompanying drawings of the embodiments of the present invention. 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 should fall within the scope of protection of the present invention.
[0025] It should be noted that the terms "first," "second," etc., in the specification, claims, and accompanying drawings of this invention are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. It should be understood that such data can be interchanged where appropriate so that the embodiments of the invention described herein can be implemented in orders other than those illustrated or described herein. Furthermore, the terms "comprising" and "having," and any variations thereof, are intended to cover a non-exclusive inclusion; for example, a process, method, system, product, or apparatus that comprises a series of steps or units is not necessarily limited to those steps or units explicitly listed, but may include other steps or units not explicitly listed or inherent to such processes, methods, products, or apparatus.
[0026] like Figure 1 As shown, this invention provides a small-sample radiation source identification method based on contrast alignment and Bayesian fine-tuning, comprising the following steps: S1. Acquire the raw radio frequency signal, preprocess the raw radio frequency signal, and divide the preprocessed raw radio frequency signal into an unlabeled dataset, a labeled dataset, and a test set.
[0027] This invention uses an open-source broadcast-based automatic dependent surveillance dataset as an implementation example. This dataset contains radio frequency signals from 530 different aircraft, with each signal sample being complex I / Q dual-channel data at a sampling rate of 50 MS / s.
[0028] The signal preprocessing steps are as follows: The first step is to take the I component of the original radio frequency signal as the real part of the complex signal and the Q component as the imaginary part of the complex signal.
[0029] The second step is to construct the IQ dual-channel components based on the real and imaginary parts of the complex signal.
[0030] The third step is to construct a radio frequency (RF) IQ sequence based on the IQ dual-channel components and normalize the RF IQ sequence to obtain the preprocessed original RF signal.
[0031] The principles of signal partitioning are as follows: Unlabeled datasets (auxiliary datasets) D au ): 90 types of aircraft signals were selected, with 100 samples in each type, for a total of 9,000 unlabeled samples, which were used for the pre-training stage. The samples were divided into training set and validation set in a 9:1 ratio. The training set was used for parameter updates, and the validation set was used for threshold discrimination to determine whether or not to store parameters.
[0032] Labeled dataset (fine-tuned dataset) D fs From the remaining transmitters, select 10 classes, and extract {5, 10, 15, 20, 25, 30} samples from each class as support sets for training during the fine-tuning phase.
[0033] Test set: 100 unseen samples are drawn from each of the above 10 categories for performance evaluation.
[0034] Each sample is normalized, and each sample is cropped or padded to a fixed dimension of 4800×2.
[0035] S2. Perform first enhancement and second enhancement on the unlabeled data. Pass the first enhanced view and the second enhanced view through the first feature extractor and the second feature extractor, respectively. Calculate the weighted contrast alignment loss based on the output of the first feature extractor and the output of the second feature extractor. Apply the weighted contrast alignment loss to the second extractor. Then, perform momentum update on the first extractor to obtain the pre-trained second feature extractor.
[0036] For untagged radio frequency sequences x a Two complementary data augmentation strategies are implemented to generate two different augmented views, improving the model's adaptability to signal distortion and noise: The first enhancement includes: adding Gaussian white noise to the input signal, randomly dividing the noise-added signal into several segments and performing time-series rearrangement to obtain the enhanced view. v 2. (in) x a Adding Gaussian white noise to it yields Then The image is randomly segmented into eight equal-length segments and then rearranged temporally to generate a view, thereby enhancing the model's learning of time-independent RF fingerprint features. The second enhancement includes: introducing rotation and flipping into the input signal and applying a phase-controlled perturbation to obtain the enhanced view. v 1. (Based on the idea of "feature-versus-relaxation") x a By applying controllable phase perturbations to simulate signal distortion in real channels, a view is generated, enhancing the model's robustness to non-ideal channels. A symmetrical contrastive learning architecture is employed to learn discriminative and consistent RF fingerprint feature representations. Views v1 and v2 are input into the online network and the target network, respectively, and the corresponding outputs are... , The first feature extractor (target network) and the second feature extractor (online network) have the same structure. The first feature extractor includes an RFF feature extractor and a projection head. The first feature extractor is optimized using the exponential moving average method based on its existing parameters and the parameters of the second feature extractor.
[0037] The online network and the target network have identical structures, both including an RFF feature extractor and a projection head. The RFF feature extractor comprises nine complex-valued convolutional layers and one fully connected layer, capable of directly processing I / Q sequences to extract high-dimensional RF fingerprint features. The projection head maps high-dimensional features to a low-dimensional space, reducing computational complexity. Additionally, the target network parameters... From online network parameters using exponential moving average θ Update to ensure the stability of the training process:
[0038] in, A given momentum coefficient close to 1 is used for smooth updates, which determines the update rate of the target network.
[0039] The weighted contrastive alignment loss during the pre-training phase is calculated, and the result is fed forward to optimize the feature space structure, thereby updating the feature extractor parameters. By calculating the weighted contrastive alignment loss, the intra-class compactness and inter-class separability of features are balanced, thus optimizing the RFF feature extractor.
[0040] The calculation process for weighted contrast alignment loss includes: The first step is to normalize the outputs of the first feature extractor and the second feature extractor respectively.
[0041] The second step involves calculating the mean squared error loss of the outputs of the normalized first feature extractor and the normalized second feature extractor to achieve intra-class feature alignment. The formula for calculating the mean squared error loss is:
[0042] in, This represents the mean square error loss.
[0043] The third step is to calculate the contrast loss between the outputs of the first and second feature extractors to promote inter-class separation. The formula for calculating the contrast loss is as follows:
[0044] in, To compare the losses, This represents the total number of unlabeled data samples. For the first i The output of the first feature extractor after normalization. For the first i The output of the second feature extractor after normalization. For the first j The output of the second feature extractor after normalization. For the first j The output of the first feature extractor after normalization. This is the temperature coefficient.
[0045] Step 4: Construct a weighted contrast alignment loss using the mean squared error loss and the contrast loss. The formula for calculating the weighted contrast alignment loss is as follows:
[0046] in, To weight the alignment loss, These are adjustable weight parameters used to balance feature discriminativity and consistency, such as... Figure 3 As shown, the present invention is aimed at A comparative experiment was conducted, and ultimately... Set it to 0.2.
[0047] The loss result is fed back to the feature extractor of the online network to update the feature extractor parameters. When the relative decrease rate of the validation loss is lower than 0.001 for 10 consecutive rounds, the model is considered to have converged and updates are stopped.
[0048] S3. The labeled dataset is passed sequentially through a third feature extractor and a Bayesian classifier. The third feature extractor is obtained by transfer learning from the pre-trained second feature extractor. The Bayesian classifier is built based on MC-Dropout. The Bayesian classifier outputs the predicted label. The cross-entropy loss is calculated using the predicted label and the original label. The cross-entropy loss can minimize the difference between the predicted label and the original label. The cross-entropy loss is fed back to the third feature extractor.
[0049] The pre-trained RFF feature extractor is migrated to the fine-tuning stage, directly reusing the general radio frequency fingerprint feature extraction capability learned from pre-training, avoiding the overfitting problem caused by training from scratch, and reducing the dependence on a small amount of labeled data.
[0050] Furthermore, the Bayesian classifier includes several parallel inference modules, each consisting of a connected Dropout layer and a fully connected layer. The label prediction result is obtained by using the output of the third feature extractor from each inference module, and the mean of the label prediction results is calculated as the predicted label.
[0051] In a preferred embodiment of the present invention, 20 parallel and independent inference processes are executed. During each inference process, the features are randomly masked to conceal some features, generating 20 sets of label prediction results. The mean of the 20 sets of inference results is calculated as the final prediction result. Quantification model uncertainty Using cross-entropy loss, the difference between the predicted label and the original label is minimized, and the parameters of the RFF feature extractor and classifier are optimized simultaneously. ; in, For cross-entropy loss, The number of samples in the labeled data. For the original tag, For predicted labels.
[0052] The convergence threshold for the model during the fine-tuning phase is the relative improvement threshold δ of the validation loss. val =0.001, when the improvement of the validation loss is lower than this threshold for 10 consecutive rounds, training stops and the final RFF extractor and classifier parameters are saved.
[0053] S4. Input the test set into the third feature extractor and the Bayesian classifier in sequence to obtain the radiation source identification results.
[0054] For practical radiation source identification tasks, the I / Q sequence of the device to be identified is extracted and input into the fine-tuned RFF feature extractor and MC-Dropout classifier to obtain the classification result.
[0055] Example 1 This embodiment includes a small-sample radiation source identification system based on contrast alignment and Bayesian fine-tuning, which is implemented based on the above-mentioned small-sample radiation source identification method based on contrast alignment and Bayesian fine-tuning. The system includes the following modules: Signal acquisition module: used to acquire radio frequency IQ signals.
[0056] Radio frequency signal preprocessing module: Performs data enhancement on the acquired I / Q sequence signals.
[0057] Feature Extractor Module: The RFF feature extractor obtained by the small sample radiation source identification method based on contrast alignment and Bayesian fine-tuning described above extracts unique and stable radio frequency fingerprint features.
[0058] Recognition and Classification Module: The MC-Dropout classifier, obtained by the small sample radiation source recognition method based on contrast alignment and Bayesian fine-tuning, is used to classify the fingerprint features to be tested and output the results.
[0059] Radio frequency fingerprint database module: Stores standard fingerprint feature templates and device association information from different radiation sources as a reference benchmark for matching and identification.
[0060] Radiation source device authentication module: The classification results are matched with the standard templates in the radio frequency fingerprint database using cosine similarity. If the similarity is ≥0.9, it is determined to be a legitimate device; otherwise, it is determined to be a counterfeit device and an alarm is triggered.
[0061] Example 2 This embodiment provides a method for verifying the effectiveness of a small-sample radiation source identification method based on contrast alignment and Bayesian fine-tuning. Figure 4-6 The analysis results are presented in three dimensions: model robustness, feature extraction capability, and recognition performance. Among them, the robustness score... definition:
[0062] in, , These represent the standard deviation and mean of the results, respectively. A lower value indicates better robustness.
[0063] Detailed analysis, Figure 4 This demonstrates that the robustness score of the method of this invention is lower than other techniques using smaller sample sizes with 10-shot, 20-shot, and 30-shot fine-tuning samples, indicating that the model of this invention is more stable. Simultaneously, combined with... Figure 5 The feature space visualization results show that, compared with other methods, in the feature space mapped by the method of this invention, there are obvious spatial intervals between samples of different categories, and samples of the same category are compactly aggregated into independent clusters with clear boundaries, further demonstrating the strong discriminative power of the feature representation of this method. From Figure 6 As can be seen, the method of the present invention has a higher recognition accuracy than other methods in the small sample scenario of {5, 10, 15, 20, 25, 30}, demonstrating superior overall performance.
[0064] The sequence numbers of the above embodiments of the present invention are for descriptive purposes only and do not represent the superiority or inferiority of the embodiments.
[0065] In the above embodiments of the present invention, the descriptions of each embodiment have different focuses. For parts not described in detail in a certain embodiment, please refer to the relevant descriptions of other embodiments.
[0066] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, and not to limit them; although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some or all of the technical features; and these modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the scope of the technical solutions of the embodiments of the present invention.
Claims
1. A small sample radiation source identification method based on contrast alignment and Bayesian fine-tuning, characterized in that, Includes the following steps: The raw radio frequency signal is acquired, the raw radio frequency signal is preprocessed, and the preprocessed raw radio frequency signal is divided into an unlabeled dataset, a labeled dataset, and a test set. The unlabeled data is augmented in the first and second ways. The first augmented view and the second augmented view are passed through the first feature extractor and the second feature extractor, respectively. A weighted contrast alignment loss is calculated based on the output of the first feature extractor and the output of the second feature extractor. The weighted contrast alignment loss is used in the second extractor. Then, the momentum of the first extractor is updated to obtain the pre-trained second feature extractor. The labeled dataset is passed sequentially through a third feature extractor and a Bayesian classifier. The third feature extractor is obtained by transfer learning from the pre-trained second feature extractor. The Bayesian classifier is built based on MC-Dropout. The Bayesian classifier outputs predicted labels. The cross-entropy loss is calculated using the predicted labels and the original labels. The cross-entropy loss can minimize the difference between the predicted labels and the original labels. The cross-entropy loss is fed back to the third feature extractor. The test set is sequentially input into the third feature extractor and the Bayesian classifier to obtain the radiation source identification results.
2. The small-sample radiation source identification method based on contrast alignment and Bayesian fine-tuning according to claim 1, characterized in that, The preprocessing of the original radio frequency signal includes: The I component in the original radio frequency signal is taken as the real part of the complex signal, and the Q component is taken as the imaginary part of the complex signal. IQ dual-channel components are constructed based on the real and imaginary parts of the complex signal; A radio frequency (RF) IQ sequence is constructed based on the IQ dual-channel components, and the RF IQ sequence is normalized to obtain the preprocessed original RF signal.
3. The small-sample radiation source identification method based on contrast alignment and Bayesian fine-tuning according to claim 1, characterized in that, The first enhancement includes: Gaussian white noise is added to the input signal, and the signal after noise is added is randomly divided into several segments and time-series rearranged to obtain the first enhanced view. The second enhancement includes: By introducing rotation and flipping into the input signal and applying a phase-controlled perturbation, a second enhanced view is obtained.
4. The small-sample radiation source identification method based on contrast alignment and Bayesian fine-tuning according to claim 1, characterized in that, The first feature extractor and the second feature extractor have the same structure. The first feature extractor includes an RFF feature extractor and a projection head. The RFF feature extractor includes an encoder with 9 complex-valued convolutional layers and 1 fully connected layer. The second feature extractor optimizes the parameters of the first feature extractor using the exponential moving average method.
5. The small-sample radiation source identification method based on contrast alignment and Bayesian fine-tuning according to claim 1, characterized in that, The calculation process of the weighted contrast alignment loss includes: The outputs of the first feature extractor and the second feature extractor are normalized respectively. Calculate the mean squared error loss of the outputs of the first feature extractor after normalization and the outputs of the second feature extractor after normalization; Calculate the contrast loss between the outputs of the first feature extractor and the outputs of the second feature extractor. The formula for calculating the contrast loss is as follows: in, To compare the losses, This represents the total number of unlabeled data samples. For the first i The output of the second feature extractor after normalization. For the first i The output of the first feature extractor after normalization. For the first j The output of the first feature extractor after normalization. For the first j The output of the second feature extractor after normalization. Temperature coefficient; A weighted contrast alignment loss is constructed using mean squared error loss and contrast loss. The formula for calculating the weighted contrast alignment loss is as follows: in, To weight the alignment loss, For adjustable weight parameters, This represents the mean square error loss.
6. The small-sample radiation source identification method based on contrast alignment and Bayesian fine-tuning according to claim 1, characterized in that, The Bayesian classifier includes several parallel inference modules, each including a connected Dropout layer and a fully connected layer. Each inference module uses the output of the third feature extractor to predict the label, and the mean of the predicted label is calculated as the predicted label.
7. The small-sample radiation source identification method based on contrast alignment and Bayesian fine-tuning according to claim 1, characterized in that, The formula for calculating the cross-entropy loss is: ; in, For cross-entropy loss, The number of samples in the labeled data. For the original tag, For predicted labels.