A binary classification prediction method for solar flares based on support vector machine

Through the support vector machine machine learning method, a binary classification prediction model of solar flare observation data was constructed, which solved the accuracy problem of solar flare forecasting in the existing technology and achieved a high accuracy rate. Forecasting and more appropriate forecasting models.

CN113902053BActive Publication Date: 2025-01-07JIANGSU UNIV OF SCI & TECH
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202111055807.1
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-09-09
Publication Date
2025-01-07
Estimated Expiration
2041-09-09

AI Technical Summary

Technical Problem

The existing solar flare forecasting technology is difficult to accurately predict the behavior of solar flares, which affects space weather forecasts and human understanding of the inner laws of the sun.

Method used

Using a machine learning method based on support vector machine, the binary prediction model of solar flare observation data is constructed by preprocessing, feature selection and model training of solar flare observation data, and the decision-making boundary is made using Spearman's level correlation coefficient and SVM kernel function. confirmation and prediction.

Benefits of technology

A high accuracy prediction of solar flare behavior is achieved, a more complete data preprocessing method is provided, to prevent experimental errors, and the deep connection between features is explored, which improves the accuracy and reliability of the forecast model.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN113902053B_ABST
    Figure CN113902053B_ABST
Patent Text Reader

Abstract

The present invention discloses a solar flare binary classification prediction method based on support vector machine, which includes preprocessing data of an experimental model to construct a data set; determining the Spearman rank correlation coefficient and obtaining the difference formula between ranks; analyzing and testing the training features of machine learning, performing feature selection on the experimental model samples, and verifying the connection between the features through the Spearman rank correlation coefficient; using SVM to find the decision boundary and selecting the SVM kernel function; deriving the SVM calculation principle; using SVM to perform prediction processing on the data and generate prediction results; and judging the prediction results. The present invention constructs a solar flare activity behavior prediction model with a machine learning algorithm as the core, extracts features of solar flare observation data and preprocesses them, models and optimizes the preprocessed data, and finally achieves a prediction of solar flare behavior with a high accuracy rate.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of solar flare prediction, and in particular to a solar flare binary classification prediction method based on a support vector machine. Background Art

[0002] The sun is not a completely static sphere. It has active cycles and static cycles. One of the most obvious forms of solar activity is solar flares. The huge kinetic energy and thermal energy brought by solar flares can have a huge impact on the earth's space environment.

[0003] When a solar flare erupts, it releases a lot of radiation and high-energy particles. These by-products will have a severe impact on the Earth's space environment. Solar flares are an important part of the space weather forecast model. When the radiation and high-energy particles of a flare appear near the Earth, the atmospheric molecules will be greatly affected, and the ionosphere in the atmosphere will be damaged by radiation, thereby losing the ability to reflect radio waves, seriously affecting people's communication activities in daily life. When the high-energy particle flow emitted by the flare reaches the upper atmosphere, it will collide with the gas particles in the upper atmosphere, and the Earth's magnetic field will be disturbed, which will also seriously affect the Earth's space environment and the research work of researchers. Studying and improving the function of solar flare prediction is not only an important way to correctly predict space weather and ensure the research of human space activities, but also an important part of revealing the internal laws of the sun and improving human understanding of the sun. Therefore, it is necessary to design a solar flare binary classification prediction method based on support vector machine. Summary of the invention

[0004] The purpose of the present invention is to overcome the shortcomings of the prior art. In order to accurately predict the behavior of solar flares, a solar flare binary classification prediction method based on support vector machine is provided, and a solar flare spatial prediction model based on machine learning is proposed. The model uses a large amount of solar flare observation data as samples, and through modeling of training sets and effect verification of test sets, it better realizes the prediction of solar flare movement.

[0005] In order to achieve the above object, the technical solution adopted by the present invention is:

[0006] A solar flare binary classification prediction method based on support vector machine includes the following steps:

[0007] Step (A), preprocessing the experimental model and constructing a data set;

[0008] Step (B), determination of Spearman's rank correlation coefficient and obtaining the formula for the difference between ranks;

[0009] Step (C), analyzing and testing the training features of machine learning, performing feature selection on the experimental model samples, and verifying the relationship between the features through the Spearman rank correlation coefficient;

[0010] Step (D), using SVM to find the decision boundary and select the SVM kernel function;

[0011] Step (E), deriving the SVM calculation principle;

[0012] Step (F), using SVM to perform prediction processing on the data and generate prediction results;

[0013] In step (G), the prediction result is judged and a skill score is calculated to determine how it compares to a given benchmark.

[0014] The aforementioned solar flare binary classification prediction method based on support vector machine, step (A), preprocessing the experimental model data to construct a data set, wherein the preprocessing method is to group the overall data according to the active area number, and the data source is the SHARPS data sequence published by SDO / HMI and the X-ray flare event data observed by the GOES satellite, and the specific steps of constructing the data set are as follows:

[0015] Step (A1) is to eliminate the data first. Since the special observation data is located at the regional boundary and covers several regions, such data should be eliminated.

[0016] In step (A2), the region number attribute of each picture in the original data is extracted as an array, and a 2 / 8 split method is adopted, that is, 8 parts of the data are used as training sets, and 2 parts of the data are used as test sets for the final test model performance. The region number array is shuffled using the shuffle method, and then the proportional multiplication method is used to assign 8 of them to the training set and 2 to the training set. This process is repeated 10 times, and 10 sets of machine learning experimental data sets with both training sets and test sets are obtained.

[0017] The aforementioned solar flare binary classification prediction method based on support vector machine, step (B), determination of the Spearman rank correlation coefficient, and obtaining the difference formula between the ranks, the specific steps are as follows:

[0018] Step (B1), determination of the Spearman rank correlation coefficient. The Spearman rank correlation coefficient is an important indicator in statistics. The letter ρ represents this coefficient. The Spearman correlation coefficient is also known as the level correlation. It is a special form of product difference correlation. It is a method for studying the correlation between two variables based on level data. It can be calculated according to the difference between the number of pairs of levels in two columns of paired levels. For the sample, the m original data of the sample are converted into level data. The correlation coefficient ρ is shown in formula (1).

[0019]

[0020] There are two variables, X and Y, with N elements in each variable. The i-th element of the two variables is represented by X i , Y i Represents; the sorted set x, y of X, Y, element x i ,y i X i Rank in X and Y i Rank in Y; x i With y i The corresponding subtractions result in a sorted difference set d; that is, the Spearman rank correlation coefficient between variables X and Y is calculated from x and y, which is calculated from the sorted difference set d;

[0021] Step (B2) is to obtain the formula for the difference between the grades. In terms of overall data, the original data will examine its relative position in the overall data and obtain the corresponding grades. However, in actual research applications, the connection between variables is not important. ρ is calculated by simplifying the calculation steps, and the difference between the grades is obtained as shown in formula (2).

[0022]

[0023] The aforementioned solar flare binary classification prediction method based on support vector machine, step (C), analyzes and tests the training features of machine learning, then performs feature selection on the experimental model samples, and verifies the connection between the features through the Spearman rank correlation coefficient. The specific steps are as follows:

[0024] Step (C1) is to analyze and test the training features of machine learning, understand the correlation between features, and explore their impact on the model. This requires relevant mathematical methods to complete this task. The specific steps of the mathematical method are as follows:

[0025] Step (C11), the X-rays of the flare have 5 levels of classification from low to high, namely A, B, C, M, and X, where C is a small flare, M and X are large flares, A and B are no flares, and then A and B are collectively referred to as N-level flares, and represent samples without flare occurrence;

[0026] Step (C12), in order to facilitate the training of the final data, label conversion is first performed, and C, M, and X are marked as 1, and N is marked as 0, which represents whether a flare occurs;

[0027] Step (C13), extracting 10 data features related to flare detection from the data, and normalizing the data to map each feature into a decimal in the range of 0-1;

[0028] Step (C14), 10 features were processed using univariate feature selection;

[0029] Step (C2), feature selection is performed on the experimental model samples. In machine learning, data processing is particularly important, so the processing and analysis of data features is of utmost importance. Feature selection is also called feature subset selection, which is a process of reducing the dimension of data. The specific feature selection method used is the classification task f_classif method in SelectBest. The first data set of 10 data sets is used, and the features are sorted by scoring the importance of the features, and the specified K features with the highest scores are retained. In order to prevent errors and better experimental features, the feature scoring function of random forest is used to compare and verify with the SelectBest method;

[0030] Step (C3) verifies the connection between features through the Spearman rank correlation coefficient. The Spearman coefficient is used to detect the correlation between the target feature and the result, thereby revealing the degree of linear correlation between each feature. It is an important means to effectively reduce the dimension and deeply analyze the internal correlation between features and results in later experiments. In the data preprocessing step, it is necessary to apply the Spearman coefficient to analyze the connection between features, and obtain the relationship between the 10 features and the results, and apply the influence of the features in the final result on the prediction result through the correlation between the 10 features.

[0031] The aforementioned solar flare binary classification prediction method based on support vector machine, step (D), uses SVM to find the decision boundary and selects the SVM kernel function, where SVM represents support vector machine, and its algorithm idea is to map data to a higher-dimensional space, find a hyperplane in the high-dimensional space to divide the data into two categories, in order to improve the generalization ability of the algorithm, the segmentation caused by its hyperplane needs to maximize the interval, and the specific steps of using SVM to find the decision boundary and select the SVM kernel function are as follows,

[0032] Step (D1) uses SVM to find the decision boundary. The goal of SVM is to find the middle point in a set of data based on the different features, and make judgments and classifications based on this middle point, that is, one side of the middle point is one category and the other side is another category. This middle point is called the decision boundary. The decision boundary is a line or a plane. The specific steps of using SVM to find the decision boundary are as follows:

[0033] Step (D11), the establishment of a hyperplane. Grouping data requires a high-dimensional segmentation boundary, and the data are points on the same plane. At this time, a line is needed to divide the data into two parts. The relative point of this line is a high-dimensional boundary, that is, a hyperplane;

[0034] Step (D12), margin maximization, this step is to improve the generalization ability of the model. When the distance between the hyperplane found in the first step and the data closest to it on both sides reaches the limit it can reach, the classification effect is the best;

[0035] Step (D2) selects the SVM kernel function. To find a hyperplane in a high-dimensional space, it is not necessary to calculate the new coordinates of each point in the high-dimensional space. It is only necessary to calculate the relative distance of each pair of points. Therefore, it is necessary to use a kernel function. The kernel function uses mathematical methods to map any two points in the original dimensional space to the distance in the target high-dimensional space. In SVM, the kernel function is one of several pre-set methods. It is only necessary to consider how to process and express the data and design it into the SVM calculation principle.

[0036] The aforementioned solar flare binary classification prediction method based on support vector machine, step (E), derives the SVM calculation principle. The core idea of ​​SVM is to maximize the interval from the support vector to the classification hyperplane. The subsequent derivations will be based on this core idea, and determining the objective function and constraints of the model is the main method to solve machine learning problems. Subsequently, the model is optimized under the objective function and constraints. The SVM calculation principle is divided into soft interval maximization, Lagrangian duality, optimization problem solving, kernel function and sequence minimum optimization. The specific steps are as follows:

[0037] Step (E1), soft margin maximization, soft margin maximization is to add slack variables to the objective function to maximize the support vector to classification hyperplane interval, the specific steps are as follows,

[0038] Step (E11) requires the distance formula from the sample point x to the hyperplane (w, b). Let d be the distance from the sample point to the hyperplane (w, b). The distance d is as shown in formula (3).

[0039]

[0040] The formula of the hyperplane is shown in formula (4):

[0041] w·x+b=0 (4)

[0042] In this way, the interval from the sample point x to the hyperplane (w, b) is as shown in formula (5),

[0043]

[0044] Among them, γ i Represents the interval from sample point x to the hyperplane (w, b); x i Represents the i-th data, y i Indicates the value of the dependent variable corresponding to the i-th data, and the value of the dependent variable is ±1; when x i When correctly classified, y i The value of has the same sign as w*x+b, and the geometric interval is positive; when x i When misclassified, y i The value of has a different sign from the value of w*x+b, and the geometric interval is negative;

[0045] Step (E12), define the smallest geometric interval as shown in formula (6),

[0046] γ=minγ i (6)

[0047] Among them, the objective function of the interval maximization problem can be obtained from formula (6), and as shown in formula (7),

[0048] maxγ (7)

[0049] And follow the constraints as shown in formula (8),

[0050]

[0051] Then make the transformation as shown in formula (9):

[0052]

[0053] Then the objective function is transformed into formula (10):

[0054]

[0055] And the corresponding constraint condition becomes as shown in formula (11),

[0056]

[0057] And make the transformation as shown in formula (12),

[0058]

[0059] The objective function and constraint conditions are shown in formula (13) and formula (14) respectively.

[0060]

[0061] sty i (w′·x i +b′)≥1 (14);

[0062] Step (E13), since the multiples of (w,b) will not affect the hyperplane formula, as shown in formula (15),

[0063] w′=w,b′=b (15)

[0064] By transforming formula (15), the objective function and constraints of the interval maximization problem are shown in formula (16) and formula (17), respectively.

[0065]

[0066] sty i (w·x i +b)≥1 (17);

[0067] Step (E14), there are often some singular points in the data, which do not satisfy the constraints of formula (17). In order to make the singular points satisfy the constraints, slack variables are introduced into the calculation of sample points, and the constraints become as shown in formula (18),

[0068]

[0069] Among them, ε i represents the slack variable;

[0070] Step (E15), add slack variables to the constraint conditions so that the singular point satisfies the condition greater than or equal to 1, then the corresponding target variable becomes as shown in formula (19),

[0071]

[0072] Among them, C is the penalty parameter;

[0073] Step (E2), applying the Lagrangian multiplier to solve the convex quadratic optimization problem. The Lagrangian function integrates the objective function and the constraints, and can solve the maximum value problem of the objective function. The obtained Lagrangian function is shown in formula (20) and formula (21).

[0074]

[0075]

[0076] Among them, α i and u i Respectively represent the value of the objective function, and the original optimization problem is transformed into formula (22):

[0077]

[0078] It is not easy to solve the original optimization problem by formula (22). By using Lagrange duality, the original optimization problem is transformed into a dual problem. The optimal solution of the original problem is obtained by solving the dual problem. The dual problem of the original optimization problem is shown in formula (23):

[0079]

[0080] The beneficial effects of the present invention are:

[0081] (1) The present invention constructs a solar flare activity behavior prediction model with a machine learning algorithm as the core, extracts features from solar flare observation data and preprocesses them, models and optimizes the preprocessed data, and ultimately achieves a high accuracy prediction of solar flare behavior.

[0082] (2) The present invention proposes a more complete data preprocessing method, which uses a data segmentation method based on the classification of solar flare activity areas, eliminates data that does not meet regional requirements through data cleaning, and establishes training sets and test sets through normalization and feature selection.

[0083] (3) In order to explore a more suitable forecasting model and prevent unexpected errors in the experiment, the present invention used 10 groups of data for comparison. The model has obvious breakthroughs compared with existing research results.

[0084] (4) During the experiment, the present invention tested the special impact of the deep connection between features on the results, and after discovering the unexpected and regular line trend in the feature elimination line graph, the Spearman coefficient was used to study the linear relationship between the features. The regularity expressed by the line graph makes the next step of research instructive. BRIEF DESCRIPTION OF THE DRAWINGS

[0085] Figure 1 This is a feature selection algorithm framework diagram of a solar flare binary classification prediction method based on a support vector machine of the present invention;

[0086] Figure 2 It is a schematic diagram of the linear distribution of characteristic relationships of the present invention;

[0087] Figure 3 is a schematic diagram of the decision boundary of the present invention;

[0088] Figure 4are schematic diagrams of two hyperplane examples of the present invention;

[0089] Figure 5 It is a schematic diagram of the linear inseparable problem of the present invention;

[0090] Figure 6 It is a schematic diagram of the value symbols of the sample data of the present invention with respect to w*x+b;

[0091] Figure 7 It is a schematic diagram of the Outlier singular point of the present invention;

[0092] Figure 8 Schematic diagram of the hypersurface separation of positive and negative samples of the present invention;

[0093] Fig. 9 It is a schematic diagram of the TSS and HSS average value indicators of the support vector machine of the present invention. DETAILED DESCRIPTION

[0094] The present invention will be further described below in conjunction with the accompanying drawings.

[0095] A solar flare binary classification prediction method based on support vector machine of the present invention comprises the following steps:

[0096] Step (A) is to preprocess the experimental model and construct a data set. The preprocessing method is to group the overall data according to the active area number. The data source is the SHARPS data sequence published by SDO / HMI and the X-ray flare event data observed by the GOES satellite. The specific steps for constructing the data set are as follows:

[0097] Among them, in order to establish a suitable model and correctly predict data, it is necessary to reasonably process the disordered data in advance and generate orderly and formatted excellent data according to the experimental requirements; preprocessing is the first step in establishing the experimental model, and it is also the most critical step that cannot be missed. The quality of data preprocessing will undoubtedly directly affect the final result of the experiment; SDO is a satellite launched by NASA. The satellite is equipped with a helioseismic and magnetic imager (HMI) to observe the magnetic field changes in the photosphere. The data can be viewed at JSOC; the SHAPRs data sequence is based on the published SDO / HMI data sequence. This sequence draws images of the solar active area and automatically records the magnetic field information of the observation area;

[0098] Step (A1) is to eliminate the data first. Since the special observation data is located at the regional boundary and covers several regions, such data should be eliminated.

[0099] Among them, compared with the huge amount of overall data, eliminating data will not cause any impact;

[0100] In step (A2), the region number attribute of each picture in the original data is extracted as an array, and a 2 / 8 split method is adopted, that is, 8 parts of the data are used as training sets, and 2 parts of the data are used as test sets for the final test model performance. The region number array is shuffled using the shuffle method, and then the proportional multiplication method is used to assign 8 of them to the training set and 2 to the training set. This process is repeated 10 times, and 10 sets of machine learning experimental data sets with both training sets and test sets are obtained.

[0101] Among them, 10 sets of machine learning experimental data sets with both training sets and test sets are shown in Table 1.

[0102] Table 1 Flare levels and number of active regions in 10 datasets

[0103]

[0104] Step (B), determination of the Spearman rank correlation coefficient and obtaining the formula for the difference between ranks, the specific steps are as follows:

[0105] Among them, the Spearman rank correlation coefficient is an important non-parametric indicator for evaluating dependency. The Spearman coefficient examines monotonicity and uses a monotonic equation to evaluate the dependency of two variables. The dependency between two variables is expressed through a linear relationship. When the Spearman correlation coefficient is positive, the variables are positively correlated, and one variable increases according to the linear degree as the other variable increases. When the Spearman correlation coefficient is negative, the variables are negatively correlated, and one variable decreases according to the linear degree as the other variable increases.

[0106] Step (B1), determination of the Spearman rank correlation coefficient. The Spearman rank correlation coefficient is an important indicator in statistics. The letter ρ represents this coefficient. The Spearman correlation coefficient is also known as the level correlation. It is a special form of product difference correlation. It is a method for studying the correlation between two variables based on level data. It can be calculated according to the difference between the number of pairs of levels in two columns of paired levels. For the sample, the m original data of the sample are converted into level data. The correlation coefficient ρ is shown in formula (1).

[0107]

[0108] There are two variables, X and Y, with N elements in each variable. The i-th element of the two variables is represented by X i , Y i Represents; the sorted set x, y of X, Y, element x i ,y i X i Rank in X and Y iRank in Y; x i With y i The corresponding subtractions result in a sorted difference set d; that is, the Spearman rank correlation coefficient between variables X and Y is calculated from x and y, which is calculated from the sorted difference set d;

[0109] The reason why it is called a special form of product-moment correlation is that its requirements on data conditions are not as strict as those of the product-moment correlation coefficient. As long as the observed values ​​of the data are paired rank assessments, or rank data converted from continuous variable observations, Spearman rank correlation can be used for research regardless of other attributes of the data.

[0110] Step (B2) is to obtain the formula for the difference between the grades. In terms of overall data, the original data will examine its relative position in the overall data and obtain the corresponding grades. However, in actual research applications, the connection between variables is not important. ρ is calculated by simplifying the calculation steps, and the difference between the grades is obtained as shown in formula (2).

[0111]

[0112] Step (C) is to analyze and test the training features of machine learning, select features for the experimental model samples, and verify the relationship between features through the Spearman rank correlation coefficient. The specific steps are as follows:

[0113] Step (C1) is to analyze and test the training features of machine learning, understand the correlation between features, and explore their impact on the model. This requires relevant mathematical methods to complete this task. The specific steps of the mathematical method are as follows:

[0114] Step (C11), the X-rays of the flare have 5 levels of classification from low to high, namely A, B, C, M, and X, where C is a small flare, M and X are large flares, A and B are no flares, and then A and B are collectively referred to as N-level flares, and represent samples without flare occurrence;

[0115] Step (C12), in order to facilitate the training of the final data, label conversion is first performed, and C, M, and X are marked as 1, and N is marked as 0, which represents whether a flare occurs;

[0116] Step (C13), extracting 10 data features related to flare detection from the data, and normalizing the data to map each feature into a decimal in the range of 0-1;

[0117] Step (C14), 10 features were processed using univariate feature selection;

[0118] Step (C2), feature selection is performed on the experimental model samples. In machine learning, data processing is particularly important, so the processing and analysis of data features is of utmost importance. Feature selection is also called feature subset selection, which is a process of reducing the dimension of data. The specific feature selection method used is the classification task f_classif method in SelectBest. The first data set of 10 data sets is used, and the features are sorted by scoring the importance of the features, and the specified K features with the highest scores are retained. In order to prevent errors and better experimental features, the feature scoring function of random forest is used to compare and verify with the SelectBest method;

[0119] Among them, the principle is as follows Figure 1 As shown, for a large amount of training data, there may be many features that affect the results, but only some of them have effective effects. Feature selection is to judge the importance of features by comparing the correlation between features and results. Most of the time, using some important features to train the model is better than using all features to train the model. It can save time and eliminate some potential interference. Using reasonable feature selection is an indispensable step. A good training model requires an excellent training sample, which is an important part of determining the launch of research work;

[0120] Among them, the feature sorting results are shown in Table 2 and Table 3, and the linear distribution of feature relationships is shown in Figure 2 As shown;

[0121] Table 2 RandomForest and SelectBest scoring

[0122]

[0123] Table 3 Feature importance in descending order

[0124]

[0125] Step (C3) verifies the connection between features through the Spearman rank correlation coefficient. The Spearman coefficient is used to detect the correlation between the target feature and the result, thereby revealing the degree of linear correlation between each feature. It is an important means to effectively reduce the dimension and deeply analyze the internal correlation between features and results in later experiments. In the data preprocessing step, it is necessary to apply the Spearman coefficient to analyze the connection between features, and obtain the relationship between the 10 features and the results, and apply the influence of the features in the final result on the prediction result through the correlation between the 10 features.

[0126] Among them, the relationship between the ten features and the results is shown in Table 4. The table reveals the potential connection between the features and provides an important reference for the feature analysis after the experiment. The final results of the experiment prove that after feature selection, the influence of the features measured by the machine learning algorithm on the results is not as linear as the theory shows, but has other deep influences as shown by the Spearman coefficient.

[0127] Table 4 Spearman coefficient

[0128]

[0129] Next table

[0130]

[0131]

[0132] Step (D) is to find the decision boundary through SVM and select the SVM kernel function. SVM stands for support vector machine. Its algorithm idea is to map the data to a higher-dimensional space and find a hyperplane in the high-dimensional space to divide the data into two categories. In order to improve the generalization ability of the algorithm, the segmentation caused by the hyperplane needs to maximize the interval. The specific steps of using SVM to find the decision boundary and select the SVM kernel function are as follows:

[0133] Step (D1) uses SVM to find the decision boundary. The goal of SVM is to find the middle point in a set of data based on the different features, and make judgments and classifications based on this middle point, that is, one side of the middle point is one category and the other side is another category. This middle point is called the decision boundary. The decision boundary is a line or a plane. The specific steps of using SVM to find the decision boundary are as follows:

[0134] The decision boundary is Figure 3 As shown in the figure, a set of training data will be divided into two clear parts by the decision boundary; to predict new data points, the algorithm only needs to use the decision boundary to identify which part of the boundary the data is located in;

[0135] Step (D11), the establishment of a hyperplane. Grouping data requires a high-dimensional segmentation boundary, and the data are points on the same plane. At this time, a line is needed to divide the data into two parts. The relative point of this line is a high-dimensional boundary, that is, a hyperplane;

[0136] Among them, Figure 4 As shown;

[0137] Step (D12), margin maximization, this step is to improve the generalization ability of the model. When the distance between the hyperplane found in the first step and the data closest to it on both sides reaches the limit it can reach, the classification effect is the best;

[0138] Among them, the decision boundary that meets the above conditions has a fairly good generalization effect;

[0139] Step (D2), select the SVM kernel function. To find a hyperplane in a high-dimensional space, it is not necessary to calculate the new coordinates of each point in the high-dimensional space, but only to calculate the relative distance of each pair of points. Therefore, a kernel function is needed. The kernel function uses mathematical methods to map any two points in the original dimensional space to the distance in the target high-dimensional space. In SVM, the kernel function is a certain set of methods. It is only necessary to consider how to process and express the data and design it into the SVM calculation principle.

[0140] Among them, according to the idea of ​​maximizing the interval from the support vector to the classification hyperplane, the best SVM classification model can be obtained in theory, but in fact, the classification accuracy of the SVM classification model is not high in most cases; this is mainly due to factors such as unsatisfactory data preprocessing, too little data, wrong feature value selection, unoptimized algorithm model parameters, and failure to select appropriate kernel functions;

[0141] The advantages of SVM are: it can solve linear inseparable problems well, such as Figure 5 As shown in the figure, these two types of data points cannot be segmented using hyperplanes, but can be segmented using hypersurfaces; the classification hyperplane is divided based on a small number of support vectors, and the algorithm has low complexity for large-scale data;

[0142] The disadvantages of SVM are: the SVM algorithm is suitable for binary classification problems, and custom functions are required for multi-classification problems; it only supports discrete data; and it is necessary to convert categorical data into discrete data during the data preprocessing stage.

[0143] Step (E) derives the SVM calculation principle. The core idea of ​​SVM is to maximize the interval from the support vector to the classification hyperplane. All subsequent derivations will be based on this core idea. Determining the objective function and constraints of the model is the main method to solve machine learning problems. Then, the model is optimized under the objective function and constraints. The SVM calculation principle is divided into soft margin maximization, Lagrange duality, optimization problem solving, kernel function and sequence minimum optimization. The specific steps are as follows:

[0144] Step (E1), soft margin maximization, soft margin maximization is to add slack variables to the objective function to maximize the support vector to classification hyperplane interval, the specific steps are as follows,

[0145] Step (E11) requires the distance formula from the sample point x to the hyperplane (w, b). Let d be the distance from the sample point to the hyperplane (w, b). The distance d is as shown in formula (3).

[0146]

[0147] The formula of the hyperplane is shown in formula (4):

[0148] w·x+b=0 (4)

[0149] In this way, the interval from the sample point x to the hyperplane (w, b) is as shown in formula (5),

[0150]

[0151] Among them, γ i Represents the interval from sample point x to the hyperplane (w, b); x i Represents the i-th data, y i Indicates the value of the dependent variable corresponding to the i-th data, and the value of the dependent variable is ±1; when x i When correctly classified, y i The value of has the same sign as w*x+b, and the geometric interval is positive; when x i When misclassified, y i The value of has a different sign from that of w*x+b, and the geometric interval is negative; Figure 6 As shown;

[0152] Step (E12), define the smallest geometric interval as shown in formula (6),

[0153] γ=minγ i (6)

[0154] Among them, the objective function of the interval maximization problem can be obtained from formula (6), and as shown in formula (7),

[0155] maxγ (7)

[0156] And follow the constraints as shown in formula (8),

[0157]

[0158] Then make the transformation as shown in formula (9):

[0159]

[0160] Then the objective function is transformed into formula (10):

[0161]

[0162] And the corresponding constraint condition becomes as shown in formula (11),

[0163]

[0164] And make the transformation as shown in formula (12),

[0165]

[0166] The objective function and constraint conditions are shown in formula (13) and formula (14) respectively.

[0167]

[0168] sty i (w′·x i +b′)≥1 (14);

[0169] Step (E13), since the multiples of (w,b) will not affect the hyperplane formula, as shown in formula (15),

[0170] w′=w,b′=b (15)

[0171] By transforming formula (15), the objective function and constraints of the interval maximization problem are shown in formula (16) and formula (17), respectively.

[0172]

[0173] sty i (w·x i +b)≥1 (17);

[0174] Step (E14), there are often some singular points in the data, which do not satisfy the constraints of formula (17). In order to make the singular points satisfy the constraints, slack variables are introduced into the calculation of sample points, and the constraints become as shown in formula (18),

[0175]

[0176] Among them, ε i represents a slack variable; Figure 7 As shown;

[0177] Step (E15), add slack variables to the constraint conditions so that the singular point satisfies the condition greater than or equal to 1, then the corresponding target variable becomes as shown in formula (19),

[0178]

[0179] Among them, C is the penalty parameter; the penalty coefficient makes the objective function minimum, that is, the geometric interval is maximized, and the minimum relaxation variable can be obtained;

[0180] Step (E2), applying the Lagrangian multiplier to solve the convex quadratic optimization problem. The Lagrangian function integrates the objective function and the constraints, and can solve the maximum value problem of the objective function. The obtained Lagrangian function is shown in formula (20) and formula (21).

[0181]

[0182]

[0183] Among them, α i and u i Respectively represent the value of the objective function, and the original optimization problem is transformed into formula (22):

[0184]

[0185] It is not easy to solve the original optimization problem by formula (22). By using Lagrange duality, the original optimization problem is transformed into a dual problem. The optimal solution of the original problem is obtained by solving the dual problem. The dual problem of the original optimization problem is shown in formula (23):

[0186]

[0187] Step (E3), solving the optimization problem, through soft margin maximization and Lagrangian duality, the objective function and constraints can be converted into the problem of maximizing and minimizing the Lagrangian function. For the convenience of solving, the minimization problem of the Lagrangian function is solved first. The specific steps are as follows:

[0188] Step (E31), calculate partial derivatives of the three variables to obtain formula (24),

[0189]

[0190] Step (E32), substituting the partial derivative function obtained by the derivation into the Lagrangian function to obtain formula (25),

[0191]

[0192] Step (E33), substitute formula (25) into the minimax Lagrangian function, as shown in formula (26),

[0193]

[0194] Step (E34), convert the maximum into the minimum to obtain formula (27)

[0195]

[0196] Step (E4), kernel function, hyperplane cannot solve the linear inseparable problem. To solve this kind of problem, the hyperplane can be replaced by a hypersurface. The hypersurface can be used to divide the data into two categories. The specific steps are as follows:

[0197] Step (E41), the commonly defined surface formula is shown in formula (28),

[0198]

[0199] Among them, k represents the correlation coefficient of the surface, such as Figure 8 As shown;

[0200] Step (E42), mapping to the new coordinates as shown in formula (29),

[0201]

[0202] Among them, z represents the mapped coordinate;

[0203] Step (E43), the hypersurface under the hyperplane coordinates, as shown in formula (30),

[0204] k′1z1+k′2z2+k′3z3+k′4z4+k′5z5+k′6=0 (30);

[0205] Step (E44), through coordinate transformation, the linear inseparable problem in two-dimensional space is transformed into a linear separable problem in five-dimensional space, and the inner product under the new coordinates after mapping is obtained, as shown in formula (31)

[0206]

[0207] Among them, p and q represent the new coordinate system respectively;

[0208] Step (E45), there is a kernel function as shown in formula (32),

[0209]

[0210] We can get formula (33):

[0211]

[0212] Step (E45), the kernel function maps the low-dimensional space to the high-dimensional space and calculates the inner product of the high-dimensional space. Formula (27) contains the inner product operation of the independent variable. By using the kernel function to map the low-dimensional space to the high-dimensional space and completing the inner product operation of the high-dimensional space, the objective function and the constraint conditions are transformed into the formula (34).

[0213]

[0214] Step (E5), sequence minimum optimization, as shown in formula (34), the optimization problem is transformed into an objective function and two constraints. Sequence minimum optimization is to solve the optimal objective function under the constraints. The specific steps are as follows:

[0215] In step (E51), two independent variables are selected as α1 and α2, and the objective function and constraint conditions are transformed into formula (35) and formula (36),

[0216]

[0217]

[0218] Step (E52), through the constraint condition, replace α1 in the objective function with α2, then the objective function only contains α2, and the partial derivative of the objective function with respect to α2 is taken to make it equal to 0,

[0219]

[0220] The untrimmed value of α2 is obtained as shown in formula (38):

[0221]

[0222] Using constraint 2, α2 is pruned as shown in formula (39):

[0223]

[0224] Step (E53), from formula (39), we can get formula (40),

[0225]

[0226] There are two cases. When y1 is equal to y2, we have formula (41) and formula (42).

[0227]

[0228]

[0229] When y1 is not equal to y2, we have formula (43) and formula (44),

[0230]

[0231]

[0232] After pruning, the value of α2 is shown in formula (45):

[0233]

[0234] Step (E54), in formula (45), from the relationship between α2 and α1, formula (46) is obtained.

[0235]

[0236] When the updated value of α1 satisfies 0 < α1 < C, b1 is updated as shown in formula (47).

[0237]

[0238] When the updated value of α2 satisfies 0 < α1 < C, as shown in formula (48).

[0239]

[0240] Step (E54), when the updated values of α1 and α2 simultaneously satisfy Constraint 2, then b takes b1; otherwise, b takes the midpoint of b1 and b2, and α1 is derived by violating the KKT condition, as shown in formula (49).

[0241]

[0242] And in order to make each change as large as possible, α2 selects the maximum step size, as shown in formula (50).

[0243] |E1 - E2| (50)

[0244] Where E is the absolute value of the difference between the true value and the predicted value. The SVM continuously selects a pair of αs. When the maximum number of iterations of the model is reached or all αs no longer change, the operation of the SVM classification model ends.

[0245] Step (F), the SVM is used to perform prediction processing on the data and generate a prediction result. The SVM is a binary classification model that divides the data into one class and other classes by finding a hyperplane. The process of the SVM performing prediction processing on the data sequentially includes normalizing the sample data, mapping the samples using a kernel function, optimizing the hyperparameters using cross - validation and grid - search, training the model with the optimal parameters, and testing and obtaining the prediction result.

[0246] Among them, the SVM algorithm of sklearn is adopted, and the specific parameter settings are shown in Table 5.

[0247] Table 5 Parameter Settings of SVM

[0248]

[0249] Step (G) determines the prediction result and determines how it compares with the given benchmark by calculating the skill score. The specific steps are as follows:

[0250] Step (G1), judging the prediction results, wherein the judged values ​​include the event of correctly predicting the occurrence of the flare as a true positive TP, the event of correctly predicting the occurrence of the flare as a true negative TN, the event of incorrectly predicting the occurrence of the flare as a false positive FP, and the event of incorrectly predicting the occurrence of the flare as a false negative FN, and then setting the evaluation index according to the four values, and the specific steps of setting the evaluation index are as follows,

[0251] Step (G11), precision, describes the proportion of correctly predicted flare events among all predicted flare events, as shown in formula (51),

[0252]

[0253] Step (G12), recall, the ability of the classifier to find all positive examples, as shown in formula (52),

[0254]

[0255] Step (G13), accuracy, the proportion of all correctly predicted events to all events, is an important indicator for objectively evaluating the predictive ability of the classifier.

[0256]

[0257] Step (G2) is to calculate the skill score to determine how it compares to a given benchmark. For flare prediction, the widely used skill score indicators include HSS and TSS. The specific steps are as follows:

[0258] Step (G21), HSS, where P = TP + FN is the total number of positive samples, N = TN + FP is the total number of negative samples, and the range of HSS is between negative infinity and 1. It measures the improvement of the prediction, rather than always predicting that a flare will not occur, as shown in formula (54).

[0259]

[0260] Among them, a higher score indicates a better prediction, and a negative score indicates a worse performance in predicting no flare;

[0261] Step (G22), TSS, TSS is the difference between recall and false alarm rate. Any misclassification, whether positive or negative examples, will reduce this score accordingly, as shown in formula (55),

[0262]

[0263] Among them, the TSS indicator has a considerable degree of fairness, and even in unequal experiments, the indicator will not be greatly affected.

[0264] The following describes the use effect of a solar flare binary classification prediction method based on a support vector machine of the present invention. In this embodiment, 10 groups of 10-dimensional training set and test set data are substituted to establish a model and conduct training and testing. The prediction ability of the model finally obtained is shown in Table 6:

[0265] Table 6 Results

[0266]

[0267] The prediction ability of the SVM model is almost the same as the previous random forest model prediction ability evaluation index, and has the same application value. The similar prediction ability also indirectly indicates the correctness of the data preprocessing part;

[0268] Fig. 9 The numerical line distribution after gradually removing the "low impact rate" feature is shown. Table 7 lists the specific values ​​of the line chart:

[0269] Table 7 Line chart value list

[0270]

[0271] In summary, the present invention is a two-classification prediction method for solar flares based on support vector machines. First, a solar flare activity behavior prediction model is constructed with a machine learning algorithm as the core, and the preprocessed data is modeled and optimized by feature extraction and preprocessing of solar flare observation data, and finally a high accuracy prediction of solar flare behavior is achieved; a more complete data preprocessing method is also proposed, which uses a data segmentation method based on the classification of solar flare activity areas, excludes data that does not meet regional requirements through data cleaning, and establishes training sets and test sets through normalization, feature selection and other methods; and in order to explore a more suitable prediction model and prevent unexpected errors in the experiment, 10 groups of data were used for comparison. The model has obvious breakthroughs compared with existing research results. During the experiment, the special influence of the deep connection between the features on the results was tested, and after discovering the unexpected and regular line trend in the feature elimination line graph, the Spearman coefficient was used to study the linear relationship between the features. The regularity expressed by the line graph makes the next step of research instructive.

[0272] The above shows and describes the basic principles, main features and advantages of the present invention. It should be understood by those skilled in the art that the present invention is not limited to the above embodiments. The above embodiments and descriptions are only for explaining the principles of the present invention. Without departing from the spirit and scope of the present invention, the present invention may have various changes and improvements, which fall within the scope of the present invention to be protected. The scope of protection of the present invention is defined by the attached claims and their equivalents.

Claims

1. A solar flare binary classification prediction method based on support vector machine, characterized by: The following steps are included: Step (A), preprocessing the experimental model and constructing a data set; Step (B), determine the Spearman rank correlation coefficient and obtain the difference formula between the ranks. The specific steps are as follows: Step (B1), determination of the Spearman rank correlation coefficient. The Spearman rank correlation coefficient is the Spearman correlation coefficient, which is represented by the letter ρ. For the sample, the m original data of the sample are converted into rank data. The correlation coefficient ρ is shown in formula (1). There are two variables, X and Y, with N elements in each variable. The i-th element of the two variables is represented by X i , Y i Represents; the sorted set x, y of X, Y, element x i ,y i X i Rank in X and Y i Rank in Y; x i With y i The corresponding subtractions are used to obtain a sorted difference set d; that is, the Spearman rank correlation coefficient between variables X and Y is obtained by calculating the sorted difference set d of x and y; Step (B2) is to obtain the formula for the difference between the grades. In terms of overall data, the original data will examine its relative position in the overall data and obtain the corresponding grades. However, in actual research applications, the connection between variables is not important. ρ is calculated by simplifying the calculation steps, and the difference between the grades is obtained as shown in formula (2). Step (C) is to analyze and test the training features of machine learning, select features for the experimental model samples, and verify the relationship between features through the Spearman rank correlation coefficient. The specific steps are as follows: Step (C1) analyzes and tests the training features of machine learning, understands the correlation between features, and explores their impact on the model. The specific steps are as follows: Step (C11), the X-rays of the flare have 5 levels of classification from low to high, namely A, B, C, M, and X, where C is a small flare, M and X are large flares, A and B are no flares, and then A and B are collectively referred to as N-level flares, and represent samples without flare occurrence; Step (C12), in order to facilitate the training of the final data, label conversion is first performed, and C, M, and X are marked as 1, and N is marked as 0, which represents whether a flare occurs; Step (C13), extracting 10 data features related to flare detection from the data, and normalizing the data to map each feature into a decimal in the range of 0-1; Step (C14), 10 features were processed using univariate feature selection; Step (C2), feature selection is performed on the experimental model samples. Feature selection is also called feature subset selection. It is a process of reducing the dimension of data. The specific feature selection method is the classification task f_classif method in SelectBest. The first data set of 10 data sets is used, and the features are sorted by scoring the importance of the features, and the specified K features with the highest scores are retained. At the same time, the feature scoring function of random forest is used to compare and verify with the SelectBest method; Step (C3), verify the connection between features through the Spearman rank correlation coefficient, use the Spearman coefficient to detect the correlation between the target feature and the result, so as to reveal the degree of linear correlation between each feature. In the data preprocessing step, it is necessary to apply the Spearman coefficient to analyze the connection between features, and obtain the relationship between the 10 features and the results, and verify the influence of the features on the prediction results in the final result through the correlation between the 10 features; Step (D) uses SVM to find the decision boundary and selects the SVM kernel function. SVM stands for support vector machine. Its algorithm idea is to map the data to a higher-dimensional space and find a hyperplane in the high-dimensional space to divide the data into two categories. The segmentation caused by the hyperplane needs to maximize the interval. The specific steps of using SVM to find the decision boundary and select the SVM kernel function are as follows: Step (D1) uses SVM to find the decision boundary. The goal of SVM is to find the middle point in a set of data based on the different features, and make judgments and classifications based on this middle point, that is, one side of the middle point is one category and the other side is another category. This middle point is called the decision boundary. The decision boundary is a line or a plane. The specific steps of using SVM to find the decision boundary are as follows: Step (D11), the establishment of a hyperplane. Grouping data requires a high-dimensional segmentation boundary, and the data are points on the same plane. At this time, a line is needed to divide the data into two parts. The relative point of this line is a high-dimensional boundary, that is, a hyperplane; Step (D12), maximize the margin and segment the hyperplane; Step (D2), select the SVM kernel function. To find a hyperplane in a high-dimensional space, you need to use a kernel function. The kernel function uses mathematical methods to map any two points in the original dimensional space to the distance in the target high-dimensional space. In SVM, the kernel function is already set. You only need to consider how to process and express the data and design it into the SVM calculation principle. Step (E), deriving the SVM calculation principle; Step (F), using SVM to perform prediction processing on the data and generate prediction results; Step (G) determines the prediction result and determines how the prediction result compares with a given benchmark by calculating a skill score.

2. The method for predicting solar flares based on a support vector machine according to claim 1, characterized in that: Step (A) is to preprocess the experimental model and construct a data set. The preprocessing method is to group the overall data according to the active area number. The data source is the SHARPS data sequence published by SDO / HMI and the X-ray flare event data observed by the GOES satellite. The specific steps for constructing the data set are as follows: Step (A1), eliminating the data, specifically eliminating the observation data at the regional boundary; In step (A2), the region number attribute of each picture in the original data is extracted as an array, and a 2 / 8 split method is adopted, that is, 8 portions of the data are used as training sets, and 2 portions of the data are used as test sets for the final test model performance. The region number array is shuffled using the shuffle method, and then 8 of them are assigned to the training set and 2 to the test set using the proportional multiplication method. This process is repeated 10 times, and 10 sets of machine learning experimental data sets with both training sets and test sets are obtained.

3. The method for predicting solar flares based on a support vector machine according to claim 2, characterized in that: Step (E) derives the SVM calculation principle, which is divided into soft margin maximization, Lagrange duality, optimization problem solving, kernel function and sequence minimum optimization. The specific steps are as follows: Step (E1), soft margin maximization, soft margin maximization is to add slack variables to the objective function to maximize the support vector to classification hyperplane interval, the specific steps are as follows, Step (E11) requires the distance formula from the sample point x to the hyperplane (w, b). Let d be the distance from the sample point to the hyperplane (w, b). The distance d is as shown in formula (3). The formula of the hyperplane is shown in formula (4): w·x+b=0 (4) In this way, the interval from the sample point x to the hyperplane (w, b) is as shown in formula (5), Among them, γ i Represents the interval from sample point x to the hyperplane (w, b); x i Represents the i-th data, y i Indicates the value of the dependent variable corresponding to the i-th data, and the value of the dependent variable is ±1; when x i When correctly classified, y i The value of has the same sign as w*x+b, and the geometric interval is positive; when x i When misclassified, y i The value of has a different sign from the value of w*x+b, and the geometric interval is negative; Step (E12), define the minimum value in the geometric interval as shown in formula (6), γ=minγ i (6) The objective function of the interval maximization problem can be obtained from formula (6), and as shown in formula (7), maxγ (7) And follow the constraints as shown in formula (8), Then make the transformation as shown in formula (9): Then the objective function is transformed into formula (10): And the corresponding constraint condition becomes as shown in formula (11), And make the transformation as shown in formula (12), The objective function and constraint conditions are shown in formula (13) and formula (14) respectively. s.t.y i (w′·x i +b′)≥1 (14); Step (E13), since the multiples of (w,b) will not affect the hyperplane formula, as shown in formula (15), w′=w,b′=b (15) By transforming formula (15), the objective function and constraints of the interval maximization problem are shown in formula (16) and formula (17), respectively. s.t.y i (w·x i +b)≥1 (17); Step (E14), there are some singular points in the data, which do not satisfy the constraints of formula (17). In order to make the singular points satisfy the constraints, slack variables are introduced into the calculation of sample points, and the constraints become as shown in formula (18), Among them, ε i represents the slack variable; Step (E15), add slack variables to the constraint conditions so that the singular point satisfies the condition greater than or equal to 1, then the corresponding target variable becomes as shown in formula (19), Among them, C is the penalty parameter; Step (E2), applying the Lagrangian multiplier to solve the convex quadratic optimization problem. The Lagrangian function integrates the objective function and the constraints, and can solve the maximum value problem of the objective function. The obtained Lagrangian function is shown in formula (20) and formula (21). Among them, α i and u i Respectively represent the value of the objective function, and the original optimization problem is transformed into the formula (22): It is not easy to solve the original optimization problem by formula (22). By using Lagrange duality, the original optimization problem is transformed into a dual problem. The optimal solution of the original problem is obtained by solving the dual problem. The dual problem of the original optimization problem is shown in formula (23): Step (E3), solving the optimization problem, through soft margin maximization and Lagrangian duality, the objective function and constraints can be converted into the problem of minimizing the Lagrangian function. For the convenience of solving, the minimization problem of the Lagrangian function is solved first. The specific steps are as follows: Step (E31), calculate partial derivatives of the three variables to obtain formula (24), Step (E32), substituting the partial derivative function obtained by the derivation into the Lagrangian function to obtain formula (25), Step (E33), substitute formula (25) into the minimax Lagrangian function, as shown in formula (26), Step (E34), convert the maximum into the minimum to obtain formula (27), Step (E4). The kernel function and the hyperplane cannot solve the linearly inseparable problem. To solve such problems, the hyperplane can be replaced by a hypersurface. Using the hypersurface, the data can be divided into two categories. The specific steps are as follows. Step (E41). The surface formula is shown in Formula (28). Among them, k represents the correlation coefficient of the surface. Step (E42). Mapping to the new coordinates is shown in Formula (29). Among them, z represents the mapped coordinates. Step (E43). The hypersurface in the hyperplane coordinates is shown in Formula (30). k′1z1 + k′2z2 + k′3z3 + k′4z4 + k′5z5 + k′6 = 0 (30). Step (E44). Through coordinate transformation, the linearly inseparable problem in the two-dimensional space is transformed into a linearly separable problem in the five-dimensional space, and the inner product in the new coordinates after mapping is obtained, as shown in Formula (31). Among them, p and q respectively represent the new coordinate systems. Step (E45). The kernel function is shown in Formula (32). Formula (33) can be obtained. Step (E45). The kernel function maps the low dimension to the high-dimensional space and calculates the inner product in the high-dimensional space. Formula (27) contains the inner product operation of the independent variables. By using the kernel function to map the low dimension to the high dimension and complete the inner product operation in the high-dimensional space, the objective function and the constraint conditions are transformed into those shown in Formula (34). Step (E5). Sequential minimal optimization. As shown in Formula (34), the optimization problem is transformed into an objective function and two constraint conditions. Sequential minimal optimization is to solve the optimal objective function under the constraint conditions. The specific steps are as follows. Step (E51). Select two independent variables, which are α1 and α2 respectively. Then the objective function and the constraint conditions are transformed into those shown in Formula (35) and Formula (36). Step (E52). Through the constraint conditions, replace α1 in the objective function with α2. Then the objective function only contains α2. Take the partial derivative of the objective function with respect to α2 and make it equal to 0. The unclipped value of α2 is obtained, as shown in Formula (38). Among them, E is the absolute value of the difference between the true value and the predicted value. Using the second constraint condition, α2 is clipped, as shown in Formula (39). Formula (40) can be obtained from Formula (39). There are two cases. When y1 is equal to y2, there are Formulas (41) and (42). When y1 is not equal to y2, there are Formulas (43) and (44). After clipping, the value of α2 is obtained as shown in Formula (45). Step (E54). In Formula (45), from the relationship between α2 and α1, Formula (46) is obtained. Among them, when the updated value of α1 satisfies 0 < α1 < C, b1 is updated as shown in Formula (47). When the updated value of α2 satisfies 0 < α1 < C, as shown in Formula (48). Step (E54). If the updated values of α1 and α2 simultaneously satisfy the second constraint condition, then b takes b1. Otherwise, b takes the midpoint of b1 and b2, and α1 is derived by violating the KKT condition, as shown in Formula (49). And in order to make each change large, the step size of α2 is maximized, as shown in Formula (50). |E1 - E2| (50) Among them, SVM continuously selects a pair of α, and when the maximum number of model iterations is reached or all α no longer changes, the SVM classification model operation ends.

4. The method for predicting solar flares based on a support vector machine according to claim 3 is characterized in that: Step (F) uses SVM to predict the data and generate prediction results, which includes normalizing the sample data, mapping the samples using kernel functions, optimizing the hyperparameters using cross-validation and grid-search, training the model with the optimal parameters, and testing to obtain the prediction results.

5. The method for predicting solar flares based on support vector machines according to claim 4 is characterized in that: Step (G) determines the prediction result and determines how the prediction result compares with the given benchmark by calculating the skill score. The specific steps are as follows: Step (G1), judging the prediction results, wherein the judged values ​​include the event of correctly predicting the occurrence of the flare as a true positive TP, the event of correctly predicting the occurrence of the flare as a true negative TN, the event of incorrectly predicting the occurrence of the flare as a false positive FP, and the event of incorrectly predicting the occurrence of the flare as a false negative FN. Then, the evaluation index is set according to the four values, and the specific steps of setting the evaluation index are as follows: Step (G11), precision, describes the proportion of correctly predicted flare events among all predicted flare events, as shown in formula (51), Step (G12), recall, the ability of the classifier to find all positive examples, as shown in formula (52), Step (G13), accuracy, the proportion of all correctly predicted events to all events, Step (G2) calculates the skill score to determine how it compares to a given benchmark. For flare prediction, the skill score metrics include HSS and TSS. The specific steps are as follows: Step (G21), HSS, where P = TP + FN is the total number of positive samples, N = TN + FP is the total number of negative samples, and the range of HSS is between negative infinity and 1, as shown in formula (54), Step (G22), TSS, TSS is the difference between the recall rate and the false alarm rate, as shown in formula (55),

Citation Information

Patent Citations

  • Solar radio storm detection method based on support vector machine model

    CN111428794A

  • Solar radio storm intensity judgment method based on SVM multi-classification algorithm

    CN111553393A