A training method, application method, device and equipment for a pulsar search model
By adjusting the parameters of the pulsar search model and using edge sampling strategies, filtering pulsar training samples from unlabeled target domain data, solving the problem of model misalignment in different data feature spaces, improving prediction accuracy and reducing labeling costs.
Patent Information
- Application Number
- CN202210720105.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-06-23
- Publication Date
- 2025-08-29
- Estimated Expiration
- 2042-06-23
AI Technical Summary
The existing pulsar search models have misalignment between different data feature spaces, resulting in reduced generalization ability and insufficient prediction accuracy. The generalization ability of the model is insufficient when the data volume is small, and the cost of manual labeling of data is high.
Adjust the pulsar search model parameters by classifying edge loss values, and combined with the domain adaptation technology of transfer learning, use edge sampling strategies to filter the target pulsar training samples from unlabeled target domain data for annotation, expand the training sample data set to avoid positive and negative samples imbalance.
The resolution and prediction accuracy of the pulsar search model are improved, and the time and labor cost of manually labeling data is reduced.
Smart Images

Figure CN115130570B_ABST
Abstract
Description
Technical Field
[0001] The embodiments of the present application relate to the technical field of pulsar data processing, and in particular to a training method, application method, apparatus, and device for a pulsar search model. Background Art
[0002] China's "Sky Eye," the Five-hundred-meter Aperture Spherical Radio Telescope (FAST), is the world's largest and most sensitive single-aperture radio telescope. One of its primary scientific objectives is to "fish" pulsars from the vast sea of stars. FAST uses a drift-scan method to survey the sky, receiving faint signals from hundreds of millions or even billions of light-years away. Through signal preprocessing, it generates tens of millions of pulsar candidates daily and searches for pulsar signals within this massive data set.
[0003] As pulsar searches progress, a large number of unlabeled pulsar candidate signals will be generated. In addition, the PICS public pulsar dataset contains multiple verified pulsar data and multiple noise data.
[0004] However, due to differences in data partitioning strategies and equipment for pulsar searches, there are certain data distribution differences between the public pulsar dataset and the FAST survey data. As a result, the current pulsar detection technology does not take into account the misalignment between different data feature spaces, and modeling is performed under limited or small data volumes. This results in reduced generalization ability and insufficient diversity of the constructed pulsar search model, thereby reducing the prediction accuracy of the pulsar search model. Summary of the Invention
[0005] The embodiments of the present application provide a training method, application method, apparatus and equipment for a pulsar search model, which is used to adjust the parameters of the pulsar search model by classifying the edge loss value, thereby enhancing the classification capability of the pulsar search model. At the same time, the domain adaptation technology of transfer learning is combined to screen out target pulsar training samples based on the edge sampling strategy, annotate them and add them to the training sample data set. This can avoid the imbalance of positive and negative samples in the training sample data set, and achieve the expansion of the training sample data set, thereby making the pulsar search model have stronger resolution capability, improving the prediction accuracy of the pulsar search model, mining more pulsar data, and greatly reducing the time and labor costs of manually annotating data.
[0006] On the one hand, an embodiment of the present application provides a training method for a pulsar search model, including:
[0007] Inputting a pulsar training sample dataset into a pulsar search model, and outputting a positive sample category prediction value and a negative sample category prediction value corresponding to each pulsar training sample in the pulsar training sample dataset through the pulsar search model, wherein the pulsar training sample dataset is derived from the first target domain data and the source domain data carrying the sample category labels;
[0008] The loss is calculated based on the positive sample category prediction value, the negative sample category prediction value and the sample category label to obtain the classification edge loss value;
[0009] Adjust the parameters of the pulsar search model based on the classification edge loss value to obtain an intermediate pulsar search model;
[0010] Based on the edge sampling strategy of active domain adaptation, target pulsar training samples are sampled from the unlabeled second target domain data, where the difference between the positive sample class prediction value and the negative sample class prediction value corresponding to the target pulsar training sample is less than the sampling threshold;
[0011] Label each target pulsar training sample, and add each labeled target pulsar training sample to the training sample dataset to obtain the pulsar extended training sample dataset;
[0012] The steps of inputting the pulsar extended training sample dataset into the intermediate pulsar search model, calculating the loss, adjusting the parameters, sampling the target pulsar training samples, and obtaining the pulsar extended training sample dataset are iteratively repeated until the convergence condition is met and the target pulsar search model is obtained.
[0013] On the other hand, the present application provides an application method of a pulsar search model, comprising:
[0014] Obtain the pulsar data to be searched;
[0015] Input the pulsar data to be searched into the target pulsar search model, and output the positive sample category target prediction value and the negative sample category target prediction value corresponding to the pulsar data to be searched through the target pulsar search model;
[0016] If the target prediction value of the positive sample category is greater than the target prediction value of the negative sample category, the pulsar data to be searched will be used as the positive sample target data to be reviewed;
[0017] Send the target data of the positive samples to be reviewed to the target review department for review, and receive the review results fed back by the target review department;
[0018] If the audit result is a positive sample category, the pulsar data to be searched is determined to be the newly discovered target pulsar data.
[0019] Another aspect of the present application provides a training device for a pulsar search model, comprising:
[0020] an acquisition unit, configured to input a pulsar training sample dataset into a pulsar search model, and output, through the pulsar search model, a positive sample category prediction value and a negative sample category prediction value corresponding to each pulsar training sample in the pulsar training sample dataset, wherein the pulsar training sample dataset is derived from first target domain data and source domain data carrying sample category labels;
[0021] A processing unit, configured to calculate a loss based on the positive sample category prediction value, the negative sample category prediction value, and the sample category label to obtain a classification marginal loss value;
[0022] The processing unit is further used to adjust the parameters of the pulsar search model based on the classification edge loss value to obtain an intermediate pulsar search model;
[0023] The processing unit is further configured to sample target pulsar training samples from unlabeled second target domain data based on an edge sampling strategy of active domain adaptation;
[0024] The processing unit is further configured to label each target pulsar training sample and add each labeled target pulsar training sample to the training sample dataset to obtain an extended pulsar training sample dataset;
[0025] A determination unit is used to iteratively and repeatedly execute the steps of inputting the pulsar extended training sample data set into the intermediate pulsar search model, calculating the loss, adjusting the parameters, sampling the target pulsar training samples, and obtaining the pulsar extended training sample data set until the convergence condition is met and the target pulsar search model is obtained.
[0026] In one possible design, in an implementation of another aspect of the embodiment of the present application, the processing unit may be specifically configured to:
[0027] Inputting the second target domain data into the intermediate pulsar search model, and outputting the positive sample category candidate prediction value and the negative sample category candidate prediction value corresponding to each candidate pulsar sample in the second target domain data through the intermediate pulsar search model;
[0028] Based on the edge sampling strategy of active domain adaptation, the positive sample category candidate prediction value and the negative sample category candidate prediction value, the target pulsar training samples are sampled from the candidate pulsar samples of the second target domain data.
[0029] In one possible design, in an implementation of another aspect of the embodiment of the present application, the processing unit may be specifically configured to:
[0030] Perform marginal normalization on the candidate prediction values of the positive sample category to obtain the marginal positive sample score;
[0031] Perform marginal normalization on the candidate prediction values of the negative sample class to obtain the marginal negative sample score;
[0032] Based on the marginal positive sample scores and the marginal negative sample scores, target pulsar training samples are sampled from the candidate pulsar samples in the second target domain data.
[0033] In one possible design, in an implementation of another aspect of the embodiment of the present application,
[0034] The processing unit is further configured to calculate a candidate classification edge loss value based on the positive sample class candidate prediction value and the negative sample class candidate prediction value;
[0035] The processing unit can be used to:
[0036] Calculate the edge sampling score based on the edge positive sample score and the edge negative sample score;
[0037] Based on the gradient direction of the edge sampling score and the gradient direction of the candidate classification edge loss value, target pulsar training samples are sampled from the candidate pulsar samples of the second target domain data.
[0038] In one possible design, in an implementation of another aspect of the embodiment of the present application, the processing unit may be specifically configured to:
[0039] Calculate the similarity between the gradient direction of the candidate classification edge loss value and the gradient direction of the edge sampling score to obtain a similarity score;
[0040] Based on the edge sampling score and the similarity score, the edge direction correction score of each candidate pulsar sample is calculated;
[0041] Candidate pulsar samples whose edge direction correction scores meet the sampling threshold range are sampled from the second target domain data as target pulsar training samples.
[0042] In one possible design, in an implementation of another aspect of the embodiment of the present application, the processing unit may be specifically configured to:
[0043] Based on the positive-negative sample ratio, each target pulsar training sample is labeled to obtain a labeled target pulsar training positive sample set and a target pulsar training negative sample set;
[0044] The labeled target pulsar training positive sample set and target pulsar training negative sample set are added to the training sample dataset to obtain the pulsar extended training sample dataset.
[0045] In one possible design, in an implementation of another aspect of the embodiment of the present application, the acquisition unit may be specifically configured to:
[0046] The pulsar search model is used to extract features from each pulsar training sample in the pulsar training sample data set to obtain sample features corresponding to each pulsar training sample;
[0047] Perform classification prediction on each sample feature to obtain the two-dimensional category vector corresponding to each sample feature;
[0048] Based on the two-dimensional category vector corresponding to each sample feature, the positive sample category prediction value and the negative sample category prediction value corresponding to each pulsar training sample are obtained.
[0049] On the other hand, the present application provides an application device of a pulsar search model, comprising:
[0050] An acquisition unit, used for acquiring pulsar data to be searched;
[0051] The acquisition unit is further used to input the pulsar data to be searched into the target pulsar search model, and output the positive sample category target prediction value and the negative sample category target prediction value corresponding to the pulsar data to be searched through the target pulsar search model;
[0052] a determination unit, configured to use the pulsar data to be searched as positive sample target data to be reviewed if the positive sample category target prediction value is greater than the negative sample category target prediction value;
[0053] The processing unit is used to send the positive sample target data to be reviewed to the target review department for review and receive the review results fed back by the target review department;
[0054] The determination unit is further configured to determine that the pulsar data to be searched is newly discovered target pulsar data if the audit result is a positive sample category.
[0055] Another aspect of the present application provides a computer device, comprising: a memory, a processor, and a bus system;
[0056] Wherein, the memory is used to store programs;
[0057] The processor is used to implement the above-mentioned methods when executing the program in the memory;
[0058] The bus system is used to connect the memory and the processor so that the memory and the processor can communicate with each other.
[0059] Another aspect of the present application provides a computer-readable storage medium, wherein instructions are stored in the computer-readable storage medium. When the computer-readable storage medium is run on a computer, the computer is enabled to execute the above-mentioned methods.
[0060] It can be seen from the above technical solutions that the embodiments of the present application have the following beneficial effects:
[0061] The pulsar search model outputs positive sample category prediction values and negative sample category prediction values, calculates the classification edge loss value based on the positive sample category prediction value, the negative sample category prediction value and the sample category label, and adjusts the parameters of the pulsar search model based on the classification edge loss value to obtain an intermediate pulsar search model. At the same time, based on the edge sampling strategy, target pulsar training samples are sampled, each target pulsar training sample is labeled, and each labeled target pulsar training sample is added to the training sample data set to obtain a pulsar extended training sample data set. The steps of inputting the pulsar extended training sample data set into the intermediate pulsar search model, loss calculation, parameter adjustment, sampling the target pulsar training samples and obtaining the pulsar extended training sample data set are iteratively repeated until the convergence condition is met to obtain the target pulsar search model. Through the above method, the parameters of the pulsar search model can be adjusted by the classification edge loss value, and the classification ability of the pulsar search model can be enhanced. At the same time, combined with the domain adaptation technology of transfer learning, based on the edge sampling strategy, the target pulsar training samples with the largest amount of information for the model and the suspected samples that cannot be clearly labeled are screened out from the unlabeled second target domain data, and are labeled and added to the training sample dataset. This can avoid the imbalance of positive and negative samples in the training sample dataset and achieve the expansion of the training sample dataset. Then, the pulsar extended training sample dataset is used to iteratively and repeatedly screen the target pulsar training samples and optimize the pulsar search model, which helps the pulsar search model learn new pulsar feature information, thereby making the pulsar search model have stronger resolution ability, improving the prediction accuracy of the pulsar search model, mining more pulsar data, and greatly reducing the time cost and labor cost of manually labeling data. BRIEF DESCRIPTION OF THE DRAWINGS
[0062] Figure 1 This is a schematic diagram of the architecture of the pulsar data control system in an embodiment of the present application;
[0063] Figure 2 This is a flow chart of an embodiment of a training method for a pulsar search model in an embodiment of the present application;
[0064] Figure 3 This is a flow chart of another embodiment of the training method of the pulsar search model in the embodiment of the present application;
[0065] Figure 4 This is a flow chart of another embodiment of the training method of the pulsar search model in the embodiment of the present application;
[0066] Figure 5This is a flow chart of another embodiment of the training method of the pulsar search model in the embodiment of the present application;
[0067] Figure 6 This is a flow chart of another embodiment of the training method of the pulsar search model in the embodiment of the present application;
[0068] Figure 7 This is a flow chart of another embodiment of the training method of the pulsar search model in the embodiment of the present application;
[0069] Figure 8 This is a flow chart of another embodiment of the training method of the pulsar search model in the embodiment of the present application;
[0070] Figure 9 This is a flow chart of another embodiment of the method for applying the pulsar search model in the embodiment of the present application;
[0071] Figure 10 This is a schematic diagram of a principle framework of the training method of the pulsar search model in the embodiment of the present application;
[0072] Figure 11 1 is a schematic diagram of a positive sample signal of a pulsar candidate in the training method of the pulsar search model in an embodiment of the present application;
[0073] Figure 12 1 is a schematic diagram of a negative sample signal of a pulsar candidate in the training method of the pulsar search model in an embodiment of the present application;
[0074] Figure 13 Schematic diagram of the correlation relationship between different modal signals of a pulsar candidate in the training method of the pulsar search model in an embodiment of the present application;
[0075] Figure 14 1 is a schematic diagram of a gradient direction correction of the training method of the pulsar search model in an embodiment of the present application;
[0076] Figure 15 This is a schematic diagram of an embodiment of a training device for a pulsar search model in an embodiment of the present application;
[0077] Figure 16 This is a schematic diagram of an embodiment of an application device of a pulsar search model in an embodiment of the present application;
[0078] Figure 17 It is a schematic diagram of an embodiment of a computer device in an embodiment of the present application. DETAILED DESCRIPTION
[0079] The embodiments of the present application provide a training method, application method, apparatus and equipment for a pulsar search model, which is used to adjust the parameters of the pulsar search model by classifying the edge loss value, thereby enhancing the classification capability of the pulsar search model. At the same time, the domain adaptation technology of transfer learning is combined to screen out target pulsar training samples based on the edge sampling strategy, annotate them and add them to the training sample data set. This can avoid the imbalance of positive and negative samples in the training sample data set, and achieve the expansion of the training sample data set, thereby making the pulsar search model have stronger resolution capability, improving the prediction accuracy of the pulsar search model, mining more pulsar data, and greatly reducing the time and labor costs of manually annotating data.
[0080] The terms "first", "second", "third", "fourth", etc. (if any) in the specification and claims of the present application and the drawings are used to distinguish similar objects and are not necessarily used to describe a specific order or sequential order. It should be understood that the data used in this way can be interchangeable where appropriate, so that the embodiments of the present application described herein can, for example, be implemented in an order other than those illustrated or described herein. In addition, the terms "including" and "corresponding to" and any variations thereof are intended to cover non-exclusive inclusions, for example, a process, method, system, product or device that includes a series of steps or units is not necessarily limited to those steps or units clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.
[0081] To facilitate understanding, some terms or concepts involved in the embodiments of this application are first explained.
[0082] 1. Active Learning
[0083] Active learning is used to evaluate unlabeled samples, selecting and labeling samples that the model believes contain the largest amount of data. These samples are then used to expand the original training set to improve model performance. To score the information content of the labeled samples, active learning often requires designing a query function to rank and select each unlabeled sample. Typically, the query function is determined by an uncertainty measure such as entropy, margin, or minimum confidence. Some active learning methods are often accompanied by carefully designed training processes, such as introducing variational autoencoders to train classifiers or rankers. In addition, other studies start with the coverage of the unlabeled samples and select data to achieve maximum diversity in sample categories.
[0084] 2. Active Domain Adaptation
[0085] AADA is one of the earliest studies to apply active learning techniques to domain adaptation. It employs a discriminator with cross-domain adversarial learning to construct a sample query function. For example, it considers the design of major deviations and design series for training objectives and rules to measure the uncertainty and domain bias of target domain samples, and further proposes a random selection strategy to enhance sample diversity. Alternatively, it incorporates the diversity and uncertainty of target data into a unified clustering framework by designing an entropy-weighted clustering algorithm.
[0086] It is understandable that in the specific implementation of this application, related data such as sample reaction data sets are involved. When the above embodiments of this application are applied to specific products or technologies, user permission or consent is required, and the collection, use and processing of relevant data must comply with relevant laws, regulations and standards of relevant countries and regions.
[0087] It can be understood that the training method of the pulsar search model disclosed in the present application specifically relates to the Intelligent Vehicle Infrastructure Cooperative Systems (IVICS), and the Intelligent Vehicle Infrastructure Cooperative Systems are further introduced below. The Intelligent Vehicle Infrastructure Cooperative System, referred to as the IVICS, is a development direction of the Intelligent Transportation System (ITS). The VIS adopts advanced wireless communication and new generation Internet technologies to implement all-round dynamic real-time information interaction between vehicles and roads, and carries out active vehicle safety control and road collaborative management based on the collection and integration of dynamic traffic information in all time and space, fully realizing the effective coordination of people, vehicles and roads, ensuring traffic safety, and improving traffic efficiency, thereby forming a safe, efficient and environmentally friendly road traffic system.
[0088] It is understandable that the training method of the pulsar search model disclosed in this application also involves artificial intelligence (AI) technology, which is further introduced below. Artificial intelligence is the theory, method, technology and application system that uses digital computers or machines controlled by digital computers to simulate, extend and expand human intelligence, perceive the environment, acquire knowledge and use knowledge to obtain the best results. In other words, artificial intelligence is a comprehensive technology in computer science that attempts to understand the essence of intelligence and produce a new type of intelligent machine that can respond in a similar way to human intelligence. Artificial intelligence is to study the design principles and implementation methods of various intelligent machines, so that machines have the functions of perception, reasoning and decision-making.
[0089] Artificial intelligence (AI) technology is a comprehensive discipline encompassing a wide range of fields, encompassing both hardware and software technologies. Foundational AI technologies generally include sensors, specialized AI chips, cloud computing, distributed storage, big data processing, operating / interaction systems, and mechatronics. AI software technologies primarily encompass computer vision, speech processing, natural language processing, and machine learning / deep learning.
[0090] Secondly, natural language processing (NLP) is a key area in computer science and artificial intelligence. It studies the theories and methods that enable effective communication between humans and computers using natural language. Natural language processing (NLP) integrates linguistics, computer science, and mathematics. Therefore, research in this field involves natural language—the language we use in everyday life—and is closely linked to the study of linguistics. Natural language processing technologies typically include text processing, semantic understanding, machine translation, robotic question answering, and knowledge graphs.
[0091] Secondly, machine learning (ML) is a multidisciplinary field that encompasses probability theory, statistics, approximation theory, convex analysis, and algorithmic complexity theory. It specifically studies how computers can simulate or implement human learning behaviors to acquire new knowledge or skills and reorganize existing knowledge structures to continuously improve their performance. Machine learning is at the core of artificial intelligence and the fundamental way to make computers intelligent. Its applications span all areas of AI. Machine learning and deep learning typically include techniques such as artificial neural networks, belief networks, reinforcement learning, transfer learning, inductive learning, and self-learning.
[0092] With the research and advancement of artificial intelligence technology, artificial intelligence technology has been studied and applied in many fields, such as common smart homes, smart wearable devices, virtual assistants, smart speakers, smart marketing, unmanned driving, autonomous driving, drones, robots, smart medical care, smart customer service, etc. It is believed that with the development of technology, artificial intelligence technology will be applied in more fields and play an increasingly important role.
[0093] It should be understood that the training method of the pulsar search model provided in this application can be applied to various scenarios, including but not limited to artificial intelligence, maps, smart transportation, cloud technology, satellite science, etc., and is used to complete the mining and prediction of pulsars by training the pulsar search model, so as to be applied to scenarios such as intelligent navigation, scientific verification or discovery, or intelligent retrieval.
[0094] In order to solve the above problems, this application proposes a training method for a pulsar search model. Figure 1 The reaction data control system shown is shown in Figure 1 , Figure 1 This is a schematic diagram of the architecture of the reaction data control system in the embodiment of the present application. Figure 1 As shown, the server obtains the training sample data set provided by the terminal device, outputs the positive sample category prediction value and the negative sample category prediction value through the pulsar search model, calculates the classification edge loss value based on the positive sample category prediction value, the negative sample category prediction value and the sample category label, and adjusts the parameters of the pulsar search model based on the classification edge loss value to obtain the intermediate pulsar search model. At the same time, based on the edge sampling strategy, the target pulsar training samples are sampled, each target pulsar training sample is labeled, and each labeled target pulsar training sample is added to the training sample data set to obtain the pulsar extended training sample data set, and the steps of inputting the pulsar extended training sample data set into the intermediate pulsar search model, loss calculation, parameter adjustment, sampling the target pulsar training samples and obtaining the pulsar extended training sample data set are iteratively repeated until the convergence condition is met to obtain the target pulsar search model. Through the above method, the parameters of the pulsar search model can be adjusted by the classification edge loss value, and the classification ability of the pulsar search model can be enhanced. At the same time, combined with the domain adaptation technology of transfer learning, based on the edge sampling strategy, the target pulsar training samples with the largest amount of information for the model and the suspected samples that cannot be clearly labeled are screened out from the unlabeled second target domain data, and are labeled and added to the training sample dataset. This can avoid the imbalance of positive and negative samples in the training sample dataset and achieve the expansion of the training sample dataset. Then, the pulsar extended training sample dataset is used to iteratively and repeatedly screen the target pulsar training samples and optimize the pulsar search model, which helps the pulsar search model learn new pulsar feature information, thereby making the pulsar search model have stronger resolution ability, improving the prediction accuracy of the pulsar search model, mining more pulsar data, and greatly reducing the time cost and labor cost of manually labeling data.
[0095] It is understandable that Figure 1 Only one type of terminal device is shown in the figure. In actual scenarios, more types of terminal devices may participate in the data processing process. Terminal devices include but are not limited to mobile phones, computers, intelligent voice interaction devices, smart home appliances, car terminals, etc. The specific number and type of terminal devices depend on the actual scenario and are not limited here. Figure 1 One server is shown in the figure, but in actual scenarios, multiple servers may also be involved, especially in scenarios of multi-model training interaction. The number of servers depends on the actual scenario and is not limited here.
[0096] It should be noted that in this embodiment, the server can be an independent physical server, a server cluster or distributed system composed of multiple physical servers, or a cloud server that provides basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communications, middleware services, domain name services, security services, content delivery networks (CDNs), and big data and artificial intelligence platforms. Terminal devices and servers can be directly or indirectly connected via wired or wireless communication, and terminal devices and servers can be connected to form a blockchain network, which is not limited in this application.
[0097] Combined with the above introduction, the following will introduce the training method of the pulsar search model in this application. Please refer to Figure 2 In one embodiment of the present application, a method for training a pulsar search model includes:
[0098] In step S101, a pulsar training sample dataset is input into a pulsar search model, and the pulsar search model outputs a positive sample category prediction value and a negative sample category prediction value corresponding to each pulsar training sample in the pulsar training sample dataset, wherein the pulsar training sample dataset is derived from first target domain data and source domain data carrying sample category labels;
[0099] In this embodiment, as the pulsar search proceeds, a large number of pulsar candidate signals without labeled information will be generated. Therefore, in order to be able to mine more meaningful pulsars from the pulsar candidate signals and enrich the pulsar-related scientific knowledge base, this embodiment can perform multiple rounds of training on the pulsar search model based on the pre-collected pulsar training sample data set, so that the pulsar search model can better learn the pulsar feature information, that is, the pulsar training sample data set is input into the pulsar search model, and the pulsar search model outputs the positive sample category prediction value and the negative sample category prediction value corresponding to each pulsar training sample in the pulsar training sample data set.
[0100] The pulsar training sample dataset is derived from the first target domain data and source domain data that carry sample category labels. Figure 13 As shown in the figure, each pulsar candidate signal contains three important signal features: time-phase distribution diagram, frequency-phase distribution diagram and DM curve, so each pulsar training sample is composed of Figure 13 The two images in the dashed box are the time-phase distribution diagram and frequency-phase distribution diagram of the candidate signal. Among them, a positive sample signal of a pulsar candidate can be specifically expressed as follows Figure 11 The two images in the dashed boxes are the spliced images of the candidate signal's time-phase distribution and frequency-phase distribution. It can be clearly observed from the figure that the time-phase distribution has a straight line that gradually enters and exits, while the frequency-phase distribution has a clear straight line that runs through the entire signal. A pulsar candidate negative sample signal can be specifically expressed as follows: Figure 12 The two dashed-line images, i.e., the image obtained by stitching together the candidate signal's time-phase distribution and frequency-phase distribution, do not meet either of the two conditions above (i.e., the time-phase distribution has a straight line that gradually fades in and out, while the frequency-phase distribution has a clear straight line that runs through it), or if the peak of the DM curve below appears at zero, then the candidate signal is a negative pulsar candidate signal. Sample class labels include positive and negative class labels.
[0101] The pulsar search model's backbone network can be ResNet50, but other backbone networks are also possible, with no specific restrictions. The residual connections in the ResNet architecture preserve input feature details, preventing this important information from being lost during dimensionality transformation. Therefore, choosing ResNet50 not only helps prevent the pulsar search model from overfitting the source domain dataset's distribution due to limited data, but also fully preserves the source domain data, enabling the pulsar search model to better generalize to target domain data.
[0102] The source domain data is the PICS public dataset with positive and negative labels (i.e., sample category labels), which can be recorded as the source domain D s ={(x s ,y s )}, where x s represents the pulsar training samples from the source domain data, y s is the pulsar training sample x s The first target domain data is the FAST survey data with sample category labels.
[0103] Specifically, a pulsar search model is trained with a pre-collected pulsar training sample data set, and feature extraction is performed on each pulsar training sample in the pulsar training sample data set through the pulsar search model to obtain sample features corresponding to each pulsar training sample, and classification prediction is performed on each sample feature to obtain a two-dimensional category vector corresponding to each sample feature. Then, based on the two-dimensional category vector corresponding to each sample feature, the positive sample category prediction value and the negative sample category prediction value corresponding to each pulsar training sample can be obtained.
[0104] In step S102, a loss is calculated based on the positive sample category prediction value, the negative sample category prediction value, and the sample category label to obtain a classification edge loss value;
[0105] In this embodiment, after obtaining the positive sample category prediction value and the negative sample category prediction value, loss calculation can be performed based on the target loss function, the positive sample category prediction value, the negative sample category prediction value and the sample category label to obtain the classification edge loss value, so that the parameters of the pulsar search model can be adjusted based on the classification edge loss value in the future, so that the pulsar search model can better learn the pulsar feature information, thereby improving the prediction ability of the pulsar search model, and thus improving the prediction accuracy of the pulsar search model to a certain extent.
[0106] Specifically, if Figure 10 As shown on the left, during the training process, by maximizing the difference between the logit of the sample label and other logits, the pulsar training samples that accurately distinguish the sample categories can be pushed away from the decision boundary, while those pulsar training samples that the pulsar search model cannot distinguish the sample categories will still be around the decision boundary after the training. Therefore, in order to reduce the tendency of the pulsar search model to favor the source domain data and to make full use of the data information of the source domain data, difficult samples (hard samples) can be used from the source domain data to construct the training target, because these samples themselves only contain a small amount of domain deviation information, but at the same time they are very important for the pulsar search model to construct the decision boundary. Therefore, the classification edge loss function of the following formulas (1) and (2) can be used to supervise the network to further enhance the classification ability of the pulsar search model through the cross entropy loss:
[0107]
[0108]
[0109] Among them, L margin(x,y) Represents the classification edge loss value; [mc(g(x)) y +c(g(x)) i ] + That is [z] + represents the truncation operation of max(0,z); g and c represent the feature extractor and classifier respectively, that is, g(x) represents the sample feature corresponding to each pulsar training sample, c(g(x)) y and c(g(x)) i They are used to represent the predicted values corresponding to different sample categories, namely the positive sample category prediction value and the negative sample category prediction value; m is a hyperparameter used to control the difficulty of the sample.
[0110] It can be understood that from the above formulas (1) and (2), the pulsar training samples can only generate gradients that contribute to the network when the true label prediction value and the other category prediction value (i.e., the positive sample category prediction value and the negative sample category prediction value) are very close. Therefore, the pulsar search model will not be dominated by redundant pulsar training samples (such as source domain samples) and will more easily transfer data information in the source domain data to the target domain data. On the other hand, since the classification edge loss will significantly increase the distance between different category clusters, the pulsar search model will pay more attention to samples with smaller gaps in different category prediction values in the target domain data. Therefore, the correction term α is added. i This can help the pulsar search model generate more reasonable gradients for pulsar training samples of different difficulty levels, so that the pulsar search model will focus more on samples that are difficult to classify (i.e., pulsar training samples that cannot accurately distinguish the sample category) and generate larger gradients, thereby pushing the pulsar training samples away from the corresponding category cluster. In addition, this embodiment can also add a regularization term at the end of the above formula (1) to constrain the pulsar search model so that the pulsar search model always predicts a high score for the true value class.
[0111] In step S103, the parameters of the pulsar search model are adjusted based on the classification edge loss value to obtain an intermediate pulsar search model;
[0112] Specifically, after obtaining the classification edge loss value, the parameters of the pulsar search model can be adjusted based on the classification edge loss value. Specifically, back propagation can be used, and other methods can also be used. There is no specific restriction here, until the parameters tend to be stable and the pulsar search model converges, so as to obtain an intermediate pulsar search model optimized based on the batch of pulsar training sample data sets.
[0113] In step S104, based on the edge sampling strategy of active domain adaptation, target pulsar training samples are sampled from the unlabeled second target domain data, wherein the difference between the positive sample category prediction value and the negative sample category prediction value corresponding to the target pulsar training samples is less than a sampling threshold;
[0114] In this embodiment, after obtaining the optimized intermediate pulsar search model, the target pulsar training samples with the largest target domain information can be sampled from the unlabeled second target domain data through the intermediate pulsar search model based on the edge sampling strategy of active domain adaptation, so that the pulsar training sample data set can be enriched based on the sampled target pulsar training samples.
[0115] Specifically, if Figure 10 As shown on the right, after obtaining the optimized intermediate pulsar search model, in order to cooperate with the training process, the following can be done: Figure 10 In the data screening stage shown on the right, the intermediate pulsar search model is generalized to the target domain and scores the unlabeled pulsar training samples of the second target domain data based on the edge sampling strategy of active domain adaptation. Then, based on the scores of the unlabeled pulsar training samples, target pulsar training samples are sampled from the unlabeled second target domain data (e.g. Figure 10 The pulsar training samples are selected in the dashed box shown on the right).
[0116] In step S105, each target pulsar training sample is labeled, and each labeled target pulsar training sample is added to the training sample dataset to obtain a pulsar extended training sample dataset;
[0117] In this embodiment, after obtaining the target pulsar training samples, each target pulsar training sample can be labeled so that each target pulsar training sample corresponds to a sample category label. Then, each labeled target pulsar training sample can be added to the training sample dataset to better enrich the pulsar training sample dataset, so as to obtain the pulsar extended training sample dataset and increase the sample diversity, so that the intermediate pulsar search model can be trained based on the pulsar extended training sample dataset in the future, so that the intermediate pulsar search model can better learn new pulsar feature information from the pulsar extended training sample dataset, so as to improve the classification prediction ability of the intermediate pulsar search model, thereby improving the prediction accuracy of the intermediate pulsar search model to a certain extent.
[0118] Specifically, after obtaining target pulsar training samples, each target pulsar training sample can be labeled. Specifically, the obtained target pulsar training samples can be randomly labeled based on a preset positive and negative sample category ratio. Alternatively, the obtained target pulsar training samples can be sent to relevant departments, and the relevant department staff can label the corresponding target pulsar training samples according to their needs. Other labeling methods can also be used, which are not specifically limited here. Furthermore, each labeled target pulsar training sample can be added to the training sample dataset to further enrich the pulsar training sample dataset, thereby obtaining an extended pulsar training sample dataset and increasing sample diversity for subsequent model training.
[0119] In step S106, the steps of inputting the pulsar extended training sample data set into the intermediate pulsar search model, calculating the loss, adjusting the parameters, sampling the target pulsar training samples, and obtaining the pulsar extended training sample data set are iteratively repeated until the convergence condition is met and the target pulsar search model is obtained.
[0120] Specifically, after obtaining the pulsar extended training sample data set, the operations of inputting the pulsar extended training sample data set into the intermediate pulsar search model, loss calculation, parameter adjustment, sampling target pulsar training samples, and obtaining the pulsar extended training sample data set can be repeatedly iterated. When the intermediate pulsar search model is obtained in each round of optimization, the target pulsar training samples with the largest amount of target domain information can be sampled from the unlabeled second target domain data through the intermediate pulsar search model based on the edge sampling strategy of active domain adaptation to expand the pulsar training samples until the convergence conditions are met to obtain the target pulsar search model.
[0121] Furthermore, experiments have shown that the experimental results are shown in Table 1 below. Table 1 shows the effect of iterating the pulsar search model using different sampling methods in the pulsar search task. It can be clearly seen that when random sampling is used, the recall rate of the pulsar search model decreases and the false alarm rate increases after this iteration. If the data screening strategy based on active learning in this embodiment is adopted, the overall recall rate of the pulsar search model can be improved, and the false alarm rate can be significantly reduced:
[0122] Table 1
[0123] Origin Random Entropy Margin Kcenter Recall 0.9718 0.9647 0.9722 0.9593 0.9567 False alarm rate 0.049167 0.050603 0.04832 0.05026 0.04814
[0124] Furthermore, experiments have shown that this embodiment can be verified based on a public data set, where the experimental indicator is the accuracy Acc. The verification results are shown in Table 2 below:
[0125] Table 2
[0126] Office-Home Office-31 Random 0.679 0.867 Ours 0.731 0.920
[0127] In an embodiment of the present application, a training method for a pulsar search model is provided. Through the above-mentioned method, the parameters of the pulsar search model can be adjusted by the classification edge loss value, and the classification ability of the pulsar search model can be enhanced. At the same time, combined with the domain adaptation technology of transfer learning, based on the edge sampling strategy, the target pulsar training samples with the largest amount of information for the model and the suspected samples that cannot be clearly labeled are screened from the unlabeled second target domain data, and are labeled and added to the training sample data set. This can avoid the imbalance of positive and negative samples in the training sample data set and achieve the expansion of the training sample data set. Then, the pulsar extended training sample data set is used to iteratively and repeatedly screen the target pulsar training samples and optimize the pulsar search model, which helps the pulsar search model learn new pulsar feature information, thereby making the pulsar search model have stronger resolution ability, improving the prediction accuracy of the pulsar search model, mining more pulsar data, and greatly reducing the time cost and labor cost of manually labeling data.
[0128] Optionally, in the above Figure 2 On the basis of the corresponding embodiment, in another optional embodiment of the training method of the pulsar search model provided in the embodiment of the present application, as Figure 3 As shown, step S104 samples target pulsar training samples from unlabeled second target domain data based on the edge sampling strategy of active domain adaptation, including:
[0129] In step S301, the second target domain data is input into the intermediate pulsar search model, and the intermediate pulsar search model outputs the positive sample category candidate prediction value and the negative sample category candidate prediction value corresponding to each candidate pulsar sample in the second target domain data;
[0130] In step S302 , target pulsar training samples are sampled from candidate pulsar samples of the second target domain data based on the edge sampling strategy of active domain adaptation, the positive sample category candidate prediction values, and the negative sample category candidate prediction values.
[0131] In this embodiment, after obtaining the optimized intermediate pulsar search model, the second target domain data is input into the intermediate pulsar search model, and the intermediate pulsar search model outputs the positive sample category candidate prediction value and the negative sample category candidate prediction value corresponding to each candidate pulsar sample in the second target domain data. Based on the edge sampling strategy of active domain adaptation, the positive sample category candidate prediction value and the negative sample category candidate prediction value, the target pulsar training sample with the largest target domain information is screened out from the candidate pulsar samples of the second target domain data, so that the pulsar training sample data set can be enriched based on the sampled target pulsar training samples in the future.
[0132] Among them, the second target domain data is the FAST survey data that is not labeled with sample category labels, which can be recorded as the target domain D t ={(x t )}, where x t Represents candidate pulsar training samples derived from the second target domain data.
[0133] Specifically, if Figure 10 As shown on the right, after obtaining the optimized intermediate pulsar search model, in order to cooperate with the training process, the following can be done: Figure 10 In the data screening phase shown on the right, the intermediate pulsar search model is generalized to the target domain, the second target domain data is input into the intermediate pulsar search model, and each candidate pulsar sample x in the second target domain data is output through the intermediate pulsar search model. t The corresponding positive sample category candidate prediction value and the negative sample category candidate prediction value can then be normalized to obtain the marginal positive sample score, and the negative sample category candidate prediction value can be normalized to obtain the marginal negative sample score. Then, based on the marginal positive sample score and the marginal negative sample score, the target pulsar training sample (such as Figure 10 The pulsar training samples are selected in the dashed box shown on the right).
[0134] Optionally, in the above Figure 3 On the basis of the corresponding embodiment, in another optional embodiment of the training method of the pulsar search model provided in the embodiment of the present application, as Figure 4 As shown, step S302 samples target pulsar training samples from candidate pulsar samples in the second target domain data based on the edge sampling strategy of active domain adaptation, the positive sample category candidate prediction value, and the negative sample category candidate prediction value, including:
[0135] In step S401, marginal normalization processing is performed on the positive sample category candidate prediction value to obtain a marginal positive sample score;
[0136] In step S402, marginal normalization processing is performed on the negative sample category candidate prediction value to obtain a marginal negative sample score;
[0137] In step S403 , target pulsar training samples are sampled from the candidate pulsar samples in the second target domain data based on the marginal positive sample scores and the marginal negative sample scores.
[0138] In this embodiment, after obtaining the optimized intermediate pulsar search model, the second target domain data is input into the intermediate pulsar search model, and the intermediate pulsar search model outputs the positive sample category candidate prediction value and the negative sample category candidate prediction value corresponding to each candidate pulsar sample in the second target domain data. Then, the positive sample category candidate prediction value can be marginally normalized to obtain the marginal positive sample score, and the negative sample category candidate prediction value can be marginally normalized to obtain the marginal negative sample score. Based on the marginal positive sample score and the marginal negative sample score, the target pulsar training sample with the largest target domain information can be better screened out from the unlabeled second target domain data, so that the pulsar training sample data set can be enriched based on the sampled target pulsar training samples.
[0139] Specifically, the second target domain data is input into the intermediate pulsar search model, and each candidate pulsar sample x in the second target domain data is output by the intermediate pulsar search model. t The corresponding positive sample category candidate prediction value and negative sample category candidate prediction value.
[0140] Furthermore, the following formula (3) can be used to perform marginal normalization on the candidate prediction values of the positive sample category to obtain the marginal positive sample score, and to perform marginal normalization on the candidate prediction values of the negative sample category to obtain the marginal negative sample score:
[0141] p=softmax(c(g(x t ))) (3);
[0142] Among them, x t is each candidate pulsar sample in the second target domain data; g and c represent the feature extractor and classifier respectively, that is, g(x t ) represents the sample features corresponding to each candidate pulsar training sample, c(g(x t )) is a two-dimensional vector that represents the predicted values corresponding to different sample categories based on different dimensions, that is, the predicted values of the positive sample category and the negative sample category; when c(g(x t )) is the positive sample category prediction value, the corresponding p is used to represent the marginal positive sample score. Similarly, when c(g(x t )) is the predicted value of the negative sample category, and the corresponding p is used to represent the marginal negative sample score.
[0143] For example, suppose the positive sample category prediction value c(g(x t )) is 0.6. After edge normalization processing using formula (3), the edge positive sample score p is 0.7. Assuming that the negative sample category prediction value c(g(xt )) is 0.4. After edge normalization processing using formula (3), the edge negative sample score p is 0.3.
[0144] Furthermore, since the smaller the gap between the predicted values of different sample categories corresponding to a candidate pulsar training sample (that is, the smaller the gap between the candidate predicted values of the positive sample category and the candidate predicted values of the negative sample category), it can be understood that the candidate pulsar training sample is a sample of the sample category that the intermediate pulsar search model cannot distinguish or is difficult to distinguish accurately. These samples can generate gradients that contribute to the network. Therefore, samples with smaller gaps between the predicted values of different sample categories are more likely to be selected as target pulsar training samples (such as Figure 10 The pulsar training samples selected in the dotted box on the right are shown), so based on the marginal positive sample scores and marginal negative sample scores, target pulsar training samples with small gaps between the prediction values of different sample categories can be screened out from the unlabeled second target domain data (such as Figure 10 Specifically, the edge sampling score can be calculated using the following formula (4) to represent the gap between the prediction values of different sample categories:
[0145]
[0146] Among them, Q m (x t ) represents the edge sampling score, 1 * and 2 * are the indices indicating the maximum and second maximum values of the classification results, i.e. Used to indicate the score corresponding to the sample category with the largest value. Used to indicate the score corresponding to another sample category with a small value, for example, when When used to represent marginal positive sample scores, It is used to represent the marginal negative sample score. It can be understood that, according to the above formula (4), the smaller the gap between the prediction values of different sample categories, the higher the marginal sampling score, and the more likely the candidate pulsar training sample corresponding to the marginal sampling score is to be selected as the target pulsar training sample.
[0147] Optionally, in the above Figure 4 On the basis of the corresponding embodiment, in another optional embodiment of the training method of the pulsar search model provided in the embodiment of the present application, as Figure 5 As shown, before step S403 samples the target pulsar training sample from the candidate pulsar samples of the second target domain data based on the marginal positive sample score and the marginal negative sample score, the method further includes: step S501, and step S403 includes: steps S502 to S503;
[0148] In step S501, a candidate classification edge loss value is calculated based on the positive sample class candidate prediction value and the negative sample class candidate prediction value;
[0149] In step S502, the edge sampling score is calculated based on the edge positive sample score and the edge negative sample score;
[0150] In step S503 , target pulsar training samples are sampled from the candidate pulsar samples of the second target domain data based on the gradient direction of the edge sampling score and the gradient direction of the candidate classification edge loss value.
[0151] In this embodiment, in the process of training the intermediate pulsar search model, Figure 14 As shown on the left, if the deviation angle between the gradient direction of the edge sampling score of the selected target pulsar training sample and the gradient direction of the candidate classification edge loss value is too large (such as Figure 14 When there is an obtuse angle between the gradient direction of the edge sampling score and the gradient direction of its candidate classification edge loss value shown on the left), it is easy for the intermediate pulsar search model to be optimized based on different gradients to be inconsistent, resulting in the intermediate pulsar search model being unable to produce a positive optimization effect. Therefore, this embodiment considers the importance of different data from the perspective of edge sampling and the gradient direction of the loss function to help the model better screen out target pulsar training samples that can enable the model to produce a positive optimization effect. Therefore, the candidate classification edge loss value can be calculated based on the positive sample category candidate prediction value and the negative sample category candidate prediction value, and the edge sampling score can be calculated based on the edge positive sample score and the edge negative sample score. Then, based on the gradient direction of the edge sampling score and the gradient direction of the candidate classification edge loss value, the target pulsar training sample with the largest target domain information can be better screened out from the unlabeled second target domain data, so that the pulsar training sample data set can be enriched based on the sampled target pulsar training samples.
[0152] Specifically, after obtaining the positive sample category candidate prediction value and the negative sample category candidate prediction value corresponding to each candidate pulsar training sample, the candidate classification edge loss value can be calculated based on the positive sample category candidate prediction value and the negative sample category candidate prediction value using the following formula (5) combined with the above formulas (1) and (2):
[0153]
[0154] Among them, L margin (x t ,1 * ) represents the candidate pulsar training sample x t Hypothesized sample class label 1 *(assuming it is a positive sample category label) the corresponding classification edge loss value; L margin (x t ,2 * ) represents the candidate pulsar training sample x t Hypothesized sample category label 2 * (If it is assumed to be a negative sample class label) the corresponding classification edge loss value; Represents the output sample feature g(x t ), Used to represent sample category label 1 * The corresponding weight parameters, Used to represent sample category label 2 * The corresponding weight parameter.
[0155] Furthermore, the above formula (4) can be used to calculate the edge sampling score Q based on the edge positive sample score and the edge negative sample score m (x t ).
[0156] Furthermore, based on the gradient direction of the edge sampling score and the gradient direction of the candidate classification edge loss value, the gradient direction of the edge sampling score and the gradient direction of the candidate classification edge loss value can be screened out from the candidate pulsar samples of the second target domain data, and the gradient direction of the edge sampling score and the gradient direction of the candidate classification edge loss value show similar directions in the feature space (such as Figure 14 The angle between the gradient direction of the edge sampling score and the gradient direction of the candidate classification edge loss value is acute, showing similar directions) for the target pulsar training samples shown on the right.
[0157] Optionally, in the above Figure 5 On the basis of the corresponding embodiment, in another optional embodiment of the training method of the pulsar search model provided in the embodiment of the present application, as Figure 6 As shown, step S503 samples target pulsar training samples from the candidate pulsar samples of the second target domain data based on the gradient direction of the edge sampling score and the gradient direction of the candidate classification edge loss value, including:
[0158] In step S601, the similarity between the gradient direction of the candidate classification edge loss value and the gradient direction of the edge sampling score is calculated to obtain a similarity score;
[0159] In step S602, based on the edge sampling score and the similarity score, the edge direction correction score of each candidate pulsar sample is calculated;
[0160] In step S603, candidate pulsar samples whose edge direction correction scores meet the sampling threshold range are sampled from the second target domain data as target pulsar training samples.
[0161] In this embodiment, since the smaller the deviation angle between the gradient direction of the edge sampling score and the gradient direction of the candidate classification edge loss value, that is, the more similar the directions displayed by the gradient direction of the edge sampling score and the gradient direction of the candidate classification edge loss value in the feature space are, it is beneficial for the model to produce a positive optimization effect. Therefore, after the edge sampling score and the candidate classification edge loss value, the similarity between the gradient direction of the candidate classification edge loss value and the gradient direction of the edge sampling score can be calculated to obtain the similarity score, and based on the edge sampling score and the similarity score, the edge direction correction score of each candidate pulsar sample is calculated. Then, the candidate pulsar samples whose edge direction correction scores meet the sampling threshold range can be sampled from the second target domain data as target pulsar training samples.
[0162] Specifically, after the edge sampling score and the candidate classification edge loss value are calculated, the following formula (6) can be used in combination with the above formula (5) to calculate the similarity between the gradient direction of the candidate classification edge loss value and the gradient direction of the edge sampling score to obtain the similarity score, and based on the edge sampling score and the similarity score, calculate the edge direction correction score of each candidate pulsar sample:
[0163]
[0164] in, represents the edge direction correction score; Q m (x t ) represents the edge sampling score; Candidate classification margin loss value, That is, <·,·> represents the cosine similarity between the two vectors of edge sampling score and candidate classification edge loss value, that is, the similarity score; λ is a hyperparameter.
[0165] Furthermore, from the above formula (6), it can be seen that the larger the similarity score, that is, the more similar the gradient direction of the edge sampling score and the gradient direction of the candidate classification edge loss value are in the feature space, the larger the edge direction correction score is. Therefore, the candidate pulsar samples whose sampling edge direction correction scores fall within the sampling threshold range can be screened from the second target domain data as target pulsar training samples, where the sampling threshold range is set according to actual application requirements, such as (1,2), and is not specifically limited here.
[0166] For example, Figure 14 The edge direction correction score shown on the left is If the sample does not fall within the sampling threshold range (1, 2), that is, the angle between the gradient direction of the edge sampling score and the gradient direction of the candidate classification edge loss value is an obtuse angle, and the directions displayed in the feature space are not similar, then the corresponding candidate pulsar training sample cannot be selected as the candidate pulsar training sample.
[0167] For example, Figure 14 The edge direction correction score shown on the right is It belongs to the sampling threshold range (1, 2), that is, the angle between the gradient direction of the edge sampling score and the gradient direction of the candidate classification edge loss value is acute, and the directions displayed in the feature space are similar, then the corresponding candidate pulsar training samples can be selected as candidate pulsar training samples.
[0168] Optionally, in the above Figure 2 On the basis of the corresponding embodiment, in another optional embodiment of the training method of the pulsar search model provided in the embodiment of the present application, as Figure 7 As shown, step S105 labels each target pulsar training sample and adds each labeled target pulsar training sample to the training sample dataset to obtain a pulsar extended training sample dataset, including:
[0169] In step S701, each target pulsar training sample is labeled based on the positive-negative sample ratio to obtain a labeled target pulsar training positive sample set and a target pulsar training negative sample set;
[0170] In step S702, the labeled target pulsar training positive sample set and the target pulsar training negative sample set are added to the training sample dataset to obtain the pulsar extended training sample dataset.
[0171] Specifically, after obtaining the target pulsar training samples, each target pulsar training sample can be labeled. Specifically, based on a preset positive-negative sample ratio, the obtained target pulsar training samples can be randomly labeled by category to obtain a labeled target pulsar training positive sample set and a target pulsar training negative sample set. Alternatively, the obtained target pulsar training samples can be sent to relevant departments, and the relevant department staff can obtain the target pulsar training samples according to needs and label them by category to obtain a labeled target pulsar training positive sample set and a target pulsar training negative sample set. Other labeling methods can also be used, which are not specifically limited here.
[0172] Furthermore, the labeled target pulsar training positive sample set and the target pulsar training negative sample set can be added to the training sample dataset to better enrich the pulsar training sample dataset, so as to obtain the pulsar extended training sample dataset and increase the sample diversity for subsequent model training.
[0173] Optionally, in the above Figure 2 On the basis of the corresponding embodiment, in another optional embodiment of the training method of the pulsar search model provided in the embodiment of the present application, as Figure 8 As shown, step S101 inputs the pulsar training sample data set into the pulsar search model, and outputs the positive sample category prediction value and the negative sample category prediction value corresponding to each pulsar training sample in the pulsar training sample data set through the pulsar search model, including:
[0174] In step S801, feature extraction is performed on each pulsar training sample in the pulsar training sample data set using a pulsar search model to obtain sample features corresponding to each pulsar training sample;
[0175] In step S802, classification prediction is performed on each sample feature to obtain a two-dimensional category vector corresponding to each sample feature;
[0176] In step S803 , based on the two-dimensional category vector corresponding to each sample feature, a positive sample category prediction value and a negative sample category prediction value corresponding to each pulsar training sample are obtained.
[0177] Specifically, after obtaining the pulsar training sample data set, the feature extractor g of the pulsar search model can be used to perform feature extraction on each pulsar training sample in the pulsar training sample data set to obtain the sample feature g(x) corresponding to each pulsar training sample.
[0178] Furthermore, the sample features g(x) corresponding to each pulsar training sample can be input into the classifier c of the pulsar search model, and the classifier c can be used to predict the category of the sample features g(x) to obtain the category two-dimensional vector corresponding to each sample feature. Then, based on the sample category label, the category prediction score c(g(x)) corresponding to each sample feature can be obtained. y and c(g(x)) i , that is, the positive sample category prediction value and the negative sample category prediction value.
[0179] The following is an introduction to the application of the pulsar search model in this application. Figure 9 In one embodiment of the present application, a method for applying the pulsar search model includes:
[0180] In step S901, the pulsar data to be searched is obtained;
[0181] In step S902, the pulsar data to be searched is input into the target pulsar search model, and the target pulsar search model outputs the positive sample category target prediction value and the negative sample category target prediction value corresponding to the pulsar data to be searched;
[0182] In step S903, if the positive sample category target prediction value is greater than the negative sample category target prediction value, the pulsar data to be searched is used as the positive sample target data to be reviewed;
[0183] In step S904, the positive sample target data to be reviewed is sent to the target review department for review, and the review result fed back by the target review department is received;
[0184] In step S905 , if the audit result is a positive sample category, the pulsar data to be searched is determined to be newly discovered target pulsar data.
[0185] Specifically, when a pulsar data to be searched is received from a target object (such as a research staff member), the acquired pulsar data to be searched can be input into a trained target pulsar search model, and the target pulsar search model outputs the positive sample category target prediction value and the negative sample category target prediction value corresponding to the pulsar data to be searched.
[0186] Furthermore, the positive sample category target prediction value and the negative sample category target prediction value can be compared. If the positive sample category target prediction value is smaller than the negative sample category target prediction value, it can be understood that the pulsar data to be searched may be a meaningless pulsar. Conversely, if the positive sample category target prediction value is larger than the negative sample category target prediction value, it can be understood that the pulsar data to be searched is very likely to be a newly discovered meaningful pulsar. The pulsar data to be searched can then be used as positive sample target data to be reviewed and sent to the target review department for review. If the review result received from the target review department is a positive sample category, it can be determined that the pulsar data to be searched is newly discovered target pulsar data. The newly discovered target pulsar data can be added to the knowledge base to enrich and expand the knowledge base, which will help to mine more pulsars.
[0187] The following is a detailed description of the training device for the pulsar search model in this application. Figure 15 , Figure 15 This is a schematic diagram of an embodiment of a pulsar search model training device in an embodiment of the present application. The pulsar search model training device 20 includes:
[0188] An acquisition unit 201 is configured to input a pulsar training sample dataset into a pulsar search model, and output, through the pulsar search model, a positive sample category prediction value and a negative sample category prediction value corresponding to each pulsar training sample in the pulsar training sample dataset, wherein the pulsar training sample dataset is derived from first target domain data and source domain data carrying sample category labels;
[0189] A processing unit 202 is configured to calculate a loss based on the positive sample category prediction value, the negative sample category prediction value, and the sample category label to obtain a classification margin loss value;
[0190] The processing unit 202 is further configured to adjust parameters of the pulsar search model based on the classification edge loss value to obtain an intermediate pulsar search model;
[0191] The processing unit 202 is further configured to sample target pulsar training samples from the unlabeled second target domain data based on an edge sampling strategy of active domain adaptation;
[0192] The processing unit 202 is further configured to label each target pulsar training sample and add each labeled target pulsar training sample to the training sample dataset to obtain an extended pulsar training sample dataset;
[0193] The determination unit 203 is used to iteratively and repeatedly execute the steps of inputting the pulsar extended training sample data set into the intermediate pulsar search model, calculating the loss, adjusting the parameters, sampling the target pulsar training samples, and obtaining the pulsar extended training sample data set until the convergence condition is met and the target pulsar search model is obtained.
[0194] Optionally, in the above Figure 15 On the basis of the corresponding embodiment, in another embodiment of the training device for the pulsar search model provided by the embodiment of the present application, the processing unit 202 can be specifically configured to:
[0195] Inputting the second target domain data into the intermediate pulsar search model, and outputting the positive sample category candidate prediction value and the negative sample category candidate prediction value corresponding to each candidate pulsar sample in the second target domain data through the intermediate pulsar search model;
[0196] Based on the edge sampling strategy of active domain adaptation, the positive sample category candidate prediction value and the negative sample category candidate prediction value, the target pulsar training samples are sampled from the candidate pulsar samples of the second target domain data.
[0197] Optionally, in the above Figure 15 On the basis of the corresponding embodiment, in another embodiment of the training device for the pulsar search model provided by the embodiment of the present application, the processing unit 202 can be specifically configured to:
[0198] Perform marginal normalization on the candidate prediction values of the positive sample category to obtain the marginal positive sample score;
[0199] Perform marginal normalization on the candidate prediction values of the negative sample class to obtain the marginal negative sample score;
[0200] Based on the marginal positive sample scores and the marginal negative sample scores, target pulsar training samples are sampled from the candidate pulsar samples in the second target domain data.
[0201] Optionally, in the above Figure 15 On the basis of the corresponding embodiment, in another embodiment of the training device for the pulsar search model provided in the embodiment of the present application,
[0202] The processing unit 202 is further configured to calculate a candidate classification margin loss value based on the positive sample class candidate prediction value and the negative sample class candidate prediction value;
[0203] The processing unit 202 may be specifically configured to:
[0204] Calculate the edge sampling score based on the edge positive sample score and the edge negative sample score;
[0205] Based on the gradient direction of the edge sampling score and the gradient direction of the candidate classification edge loss value, target pulsar training samples are sampled from the candidate pulsar samples of the second target domain data.
[0206] Optionally, in the above Figure 15 On the basis of the corresponding embodiment, in another embodiment of the training device for the pulsar search model provided by the embodiment of the present application, the processing unit 202 can be specifically configured to:
[0207] Calculate the similarity between the gradient direction of the candidate classification edge loss value and the gradient direction of the edge sampling score to obtain a similarity score;
[0208] Based on the edge sampling score and the similarity score, the edge direction correction score of each candidate pulsar sample is calculated;
[0209] Candidate pulsar samples whose edge direction correction scores meet the sampling threshold range are sampled from the second target domain data as target pulsar training samples.
[0210] Optionally, in the above Figure 15 On the basis of the corresponding embodiment, in another embodiment of the training device for the pulsar search model provided by the embodiment of the present application, the processing unit 202 can be specifically configured to:
[0211] Based on the positive-negative sample ratio, each target pulsar training sample is labeled to obtain a labeled target pulsar training positive sample set and a target pulsar training negative sample set;
[0212] The labeled target pulsar training positive sample set and target pulsar training negative sample set are added to the training sample dataset to obtain the pulsar extended training sample dataset.
[0213] Optionally, in the above Figure 15 On the basis of the corresponding embodiment, in another embodiment of the training device for the pulsar search model provided by the embodiment of the present application, the acquisition unit 201 can be specifically used to:
[0214] The pulsar search model is used to extract features from each pulsar training sample in the pulsar training sample data set to obtain sample features corresponding to each pulsar training sample;
[0215] Perform classification prediction on each sample feature to obtain the two-dimensional category vector corresponding to each sample feature;
[0216] Based on the two-dimensional category vector corresponding to each sample feature, the positive sample category prediction value and the negative sample category prediction value corresponding to each pulsar training sample are obtained.
[0217] The following is a detailed description of the application device of the pulsar search model in this application. Figure 16 , Figure 16 This is a schematic diagram of an embodiment of an application device of a pulsar search model in an embodiment of the present application. The training device 30 of the pulsar search model includes:
[0218] An acquisition unit 301 is used to acquire pulsar data to be searched;
[0219] The acquisition unit 301 is further configured to input the pulsar data to be searched into the target pulsar search model, and output the positive sample category target prediction value and the negative sample category target prediction value corresponding to the pulsar data to be searched through the target pulsar search model;
[0220] A determination unit 302 is configured to use the pulsar data to be searched as positive sample target data to be reviewed if the positive sample category target prediction value is greater than the negative sample category target prediction value;
[0221] Processing unit 303 is used to send the positive sample target data to be reviewed to the target review department for review, and receive the review results fed back by the target review department;
[0222] The determination unit 302 is further configured to determine that the pulsar data to be searched is a newly discovered target pulsar if the audit result is a positive sample category.
[0223] On the other hand, the present application provides another schematic diagram of a computer device, such as Figure 17 As shown, Figure 173 is a schematic diagram of the structure of a computer device provided in an embodiment of the present application. The computer device 300 may have relatively large differences due to different configurations or performances, and may include one or more central processing units (CPU) 310 (for example, one or more processors) and a memory 320, and one or more storage media 330 (for example, one or more mass storage devices) storing application programs 331 or data 332. Among them, the memory 320 and the storage medium 330 can be temporary storage or permanent storage. The program stored in the storage medium 330 may include one or more modules (not shown in the figure), and each module may include a series of instruction operations in the computer device 300. Furthermore, the central processing unit 310 can be configured to communicate with the storage medium 330 to execute a series of instruction operations in the storage medium 330 on the computer device 300.
[0224] The computer device 300 may also include one or more power supplies 340, one or more wired or wireless network interfaces 350, one or more input and output interfaces 360, and / or one or more operating systems 333, such as Windows Server 2003 or Windows Server 2003R. TM , Mac OS X TM , Unix TM ,Linux TM , FreeBSD TM etc.
[0225] The computer device 300 is also used to perform the following Figures 2 to 8 The steps in the corresponding embodiments, and the execution of Figure 9 The steps in the corresponding embodiments.
[0226] Another aspect of the present application provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the following Figures 2 to 8 The steps in the method described in the illustrated embodiment, and the execution of the method as shown in FIG. Figure 9 The steps in the method described in the corresponding embodiment.
[0227] Another aspect of the present application provides a computer program product comprising a computer program, which, when executed by a processor, implements the following Figures 2 to 8 The steps in the method described in the illustrated embodiment, and the execution of the method as shown in FIG. Figure 9 The steps in the method described in the corresponding embodiment.
[0228] Those skilled in the art will clearly understand that, for the convenience and brevity of description, the specific working processes of the systems, devices and units described above can refer to the corresponding processes in the aforementioned method embodiments and will not be repeated here.
[0229] In the several embodiments provided in this application, it should be understood that the disclosed systems, devices and methods can be implemented in other ways. For example, the device embodiments described above are merely schematic. For example, the division of the units is merely a logical function division. In actual implementation, there may be other division methods, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be an indirect coupling or communication connection through some interfaces, devices or units, which can be electrical, mechanical or other forms.
[0230] The units described as separate components may or may not be physically separate, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed across multiple network units. Some or all of these units may be selected to achieve the purpose of this embodiment according to actual needs.
[0231] In addition, the functional units in the various embodiments of the present application may be integrated into a single processing unit, or each unit may exist physically separately, or two or more units may be integrated into a single unit. The aforementioned integrated units may be implemented in the form of hardware or software functional units.
[0232] If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present application is essentially or the part that contributes to the prior art or all or part of the technical solution can be embodied in the form of a software product, and the computer software product is stored in a storage medium, including a number of instructions for enabling a computer device (which can be a personal computer, a server, or a network device, etc.) to execute all or part of the steps of the method described in each embodiment of the present application. The aforementioned storage medium includes: various media that can store program codes, such as a USB flash drive, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk.
Claims
1. A training method for a pulsar search model, characterized in that: include: Inputting a pulsar training sample dataset into a pulsar search model, and outputting a positive sample category prediction value and a negative sample category prediction value corresponding to each pulsar training sample in the pulsar training sample dataset through the pulsar search model, wherein the pulsar training sample dataset is derived from first target domain data and source domain data carrying sample category labels; the pulsar training sample is an image obtained by splicing a time-phase distribution map and a frequency-phase distribution map of a pulsar candidate signal; A loss calculation is performed based on the positive sample category prediction value, the negative sample category prediction value, and the sample category label to obtain a classification edge loss value, specifically comprising: calculating a correction term based on a hyperparameter, the positive sample category prediction value, and the negative sample category prediction value; the hyperparameter is used to control the difficulty of the sample; the correction term is used to make samples that are difficult to classify produce a larger gradient; a truncation operation is determined based on the hyperparameter, the positive sample category prediction value, and the negative sample category prediction value; and a loss calculation is performed based on the correction term, the truncation operation, and the positive sample category prediction value to obtain a classification edge loss value; Adjusting parameters of the pulsar search model based on the classification edge loss value to obtain an intermediate pulsar search model; Inputting unlabeled second target domain data into the intermediate pulsar search model, and outputting a positive sample category candidate prediction value and a negative sample category candidate prediction value corresponding to each candidate pulsar sample in the second target domain data through the intermediate pulsar search model; Performing softmax normalization on the candidate prediction value of the positive sample category to obtain a marginal positive sample score; Performing softmax normalization on the candidate prediction value of the negative sample category to obtain a marginal negative sample score; Calculating an edge sampling score based on the edge positive sample score and the edge negative sample score; Calculating a candidate classification edge loss value based on the positive sample class candidate prediction value and the negative sample class candidate prediction value; Based on the gradient direction of the edge sampling score and the gradient direction of the candidate classification edge loss value, and the edge sampling strategy of active domain adaptation, sampling a target pulsar training sample from the candidate pulsar samples of the second target domain data, wherein the difference between the positive sample class prediction value and the negative sample class prediction value corresponding to the target pulsar training sample is less than a sampling threshold; Labeling each target pulsar training sample, and adding each labeled target pulsar training sample to the training sample dataset to obtain a pulsar extended training sample dataset; The steps of inputting the pulsar extended training sample dataset into the intermediate pulsar search model, the loss calculation, the parameter adjustment, the sampling of target pulsar training samples, and obtaining the pulsar extended training sample dataset are iteratively repeated until a convergence condition is met, thereby obtaining a target pulsar search model.
2. The method according to claim 1, characterized in that The method of sampling target pulsar training samples from candidate pulsar samples in the second target domain data based on the gradient direction of the edge sampling score and the gradient direction of the candidate classification edge loss value, and the edge sampling strategy of active domain adaptation, includes: Calculating the similarity between the gradient direction of the candidate classification edge loss value and the gradient direction of the edge sampling score to obtain a similarity score; Calculating an edge direction correction score for each candidate pulsar sample based on the edge sampling score and the similarity score; Candidate pulsar samples whose edge direction correction scores meet a sampling threshold range are sampled from the second target domain data as the target pulsar training samples.
3. The method according to claim 1, characterized in that The step of labeling each target pulsar training sample and adding each labeled target pulsar training sample to the training sample dataset to obtain a pulsar extended training sample dataset includes: Based on the positive-negative sample ratio, each target pulsar training sample is labeled to obtain a labeled target pulsar training positive sample set and a target pulsar training negative sample set; The labeled target pulsar training positive sample set and the target pulsar training negative sample set are added to the training sample dataset to obtain the pulsar extended training sample dataset.
4. The method according to claim 1, wherein The step of inputting the pulsar training sample dataset into the pulsar search model and outputting, through the pulsar search model, a positive sample category prediction value and a negative sample category prediction value corresponding to each pulsar training sample in the pulsar training sample dataset includes: Performing feature extraction on each pulsar training sample in the pulsar training sample data set using the pulsar search model to obtain sample features corresponding to each pulsar training sample; Performing classification prediction on each of the sample features to obtain a two-dimensional category vector corresponding to each of the sample features; Based on the category two-dimensional vector corresponding to each sample feature, the positive sample category prediction value and the negative sample category prediction value corresponding to each pulsar training sample are obtained.
5. A method for applying a pulsar search model, characterized in that: include: Get the pulsar data to be searched; Inputting the pulsar data to be searched into the target pulsar search model according to any one of claims 1 to 4, and outputting the positive sample category target prediction value and the negative sample category target prediction value corresponding to the pulsar data to be searched through the target pulsar search model; If the positive sample category target prediction value is greater than the negative sample category target prediction value, the pulsar data to be searched is used as the positive sample target data to be reviewed; Send the positive sample target data to be reviewed to the target review department for review, and receive the review results fed back by the target review department; If the audit result is a positive sample category, it is determined that the pulsar data to be searched is newly discovered target pulsar data.
6. A training device for a pulsar search model, characterized in that: include: An acquisition unit is configured to input a pulsar training sample dataset into a pulsar search model, and output, through the pulsar search model, a positive sample category prediction value and a negative sample category prediction value corresponding to each pulsar training sample in the pulsar training sample dataset, wherein the pulsar training sample dataset is derived from first target domain data and source domain data carrying sample category labels; and the pulsar training sample is an image obtained by splicing a time-phase distribution map and a frequency-phase distribution map of a pulsar candidate signal; a processing unit, configured to perform loss calculation based on the positive sample class prediction value, the negative sample class prediction value, and the sample class label to obtain a classification marginal loss value, specifically comprising: calculating a correction term based on a hyperparameter, the positive sample class prediction value, and the negative sample class prediction value; the hyperparameter is used to control the difficulty of the sample; the correction term is used to generate a larger gradient for samples that are difficult to classify; determining a truncation operation based on the hyperparameter, the positive sample class prediction value, and the negative sample class prediction value; and performing loss calculation based on the correction term, the truncation operation, and the positive sample class prediction value to obtain a classification marginal loss value; The processing unit is further configured to adjust parameters of the pulsar search model based on the classification edge loss value to obtain an intermediate pulsar search model; The processing unit is further configured to input unlabeled second target domain data into the intermediate pulsar search model, and output a positive sample category candidate prediction value and a negative sample category candidate prediction value corresponding to each candidate pulsar sample in the second target domain data through the intermediate pulsar search model; perform softmax normalization processing on the positive sample category candidate prediction value to obtain a marginal positive sample score; perform softmax normalization processing on the negative sample category candidate prediction value to obtain a marginal negative sample score; calculate a marginal sampling score based on the marginal positive sample score and the marginal negative sample score; calculate a candidate classification marginal loss value based on the positive sample category candidate prediction value and the negative sample category candidate prediction value; sample a target pulsar training sample from the candidate pulsar samples of the second target domain data based on the gradient direction of the marginal sampling score and the gradient direction of the candidate classification marginal loss value, and an edge sampling strategy of active domain adaptation, wherein the difference between the positive sample category prediction value and the negative sample category prediction value corresponding to the target pulsar training sample is less than a sampling threshold; The processing unit is further configured to label each target pulsar training sample, and add each labeled target pulsar training sample to the training sample dataset to obtain an extended pulsar training sample dataset; A determination unit is used to iteratively and repeatedly execute the steps of inputting the pulsar extended training sample data set into the intermediate pulsar search model, the loss calculation, the parameter adjustment, the sampling of target pulsar training samples, and obtaining the pulsar extended training sample data set until a convergence condition is met to obtain a target pulsar search model.
7. The device according to claim 6, characterized in that The processing unit is specifically configured to: Calculating the similarity between the gradient direction of the candidate classification edge loss value and the gradient direction of the edge sampling score to obtain a similarity score; Calculating an edge direction correction score for each candidate pulsar sample based on the edge sampling score and the similarity score; Candidate pulsar samples whose edge direction correction scores meet a sampling threshold range are sampled from the second target domain data as the target pulsar training samples.
8. The device according to claim 6, characterized in that The processing unit is specifically configured to: Based on the positive-negative sample ratio, each target pulsar training sample is labeled to obtain a labeled target pulsar training positive sample set and a target pulsar training negative sample set; The labeled target pulsar training positive sample set and the target pulsar training negative sample set are added to the training sample dataset to obtain the pulsar extended training sample dataset.
9. The device according to claim 6, characterized in that The acquisition unit is specifically configured to: Performing feature extraction on each pulsar training sample in the pulsar training sample data set using the pulsar search model to obtain sample features corresponding to each pulsar training sample; Performing classification prediction on each of the sample features to obtain a two-dimensional category vector corresponding to each of the sample features; Based on the category two-dimensional vector corresponding to each sample feature, the positive sample category prediction value and the negative sample category prediction value corresponding to each pulsar training sample are obtained.
10. An application device for a pulsar search model, characterized in that: include: An acquisition unit, used for acquiring pulsar data to be searched; The acquisition unit is further configured to input the pulsar data to be searched into a target pulsar search model according to any one of claims 1 to 4, and output a positive sample category target prediction value and a negative sample category target prediction value corresponding to the pulsar data to be searched through the target pulsar search model; a determining unit, configured to use the pulsar data to be searched as positive sample target data to be reviewed if the positive sample category target prediction value is greater than the negative sample category target prediction value; A processing unit, configured to send the positive sample target data to be reviewed to a target review department for review, and receive the review result fed back by the target review department; The determining unit is further configured to determine that the pulsar data to be searched is newly discovered target pulsar data if the audit result is a positive sample category.
11. A computer device comprising a memory, a processor and a bus system, wherein the memory stores a computer program, wherein: When the processor executes the computer program, the processor implements the steps of the method according to any one of claims 1 to 4, and implements the steps of the method according to claim 5; The bus system is used to connect the memory and the processor so that the memory and the processor can communicate with each other.
12. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 4 and the steps of the method according to claim 5 are implemented.
13. A computer program product comprising a computer program, characterized in that When the computer program is executed by a processor, the computer program implements the steps of the method according to any one of claims 1 to 4 and the method according to claim 5.
Citation Information
Patent Citations
Candidate recognition of pulsar based on convolution neural network
CN109508746A
Pulsar search method based on transfer learning lightweight neural network
CN111985615A
Training data processing method and device and storage medium
CN114332984A