Oversampling multi-cluster fusion data prediction method, device, equipment and medium
By adopting the oversampled multi-cluster fusion method in student achievement prediction, the problem of data category imbalance is solved, and the prediction ability and overall prediction performance of a few categories are improved.
Patent Information
- Application Number
- CN202510142384.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-02-10
- Publication Date
- 2025-03-11
- Estimated Expiration
- Not applicable · inactive patent
AI Technical Summary
In the existing student achievement prediction methods, the category distribution of student achievement data is uneven, which leads to the model biasing towards the majority category when predicting, ignoring the minority category, and having a low overall accuracy rate, especially in identifying minority categories.
The data prediction method of oversampled multi-cluster fusion is adopted. By clustering a few types of data with different clustering algorithms, clustering center data is generated and added to the data set. The improved DPC clustering algorithm (IF-SNNDPC) is used for clustering, the oversampling number of each subcluster is calculated, and the sample number of a few categories is increased through centroid oversampling technology. Finally, the processed data is input into the pre-trained XGBoost model for prediction.
By increasing the sample size of a few categories, the problem of imbalance in the sample data category during the training process is solved, the prediction ability of a few categories is improved, and the prediction performance and generalization ability of the model are improved.
Smart Images

Figure CN119598231A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of data prediction technology, and in particular to a data prediction method, device, equipment and medium for oversampling multi-cluster fusion. Background Art
[0002] At present, the student performance prediction method generally predicts student performance by building a model. First, it is necessary to collect various data related to student performance and preprocess these data. Then, the processed data is divided into a training set and a test set, and the training set is used to train the model. Finally, the test set is used to evaluate the prediction effect of the model.
[0003] However, the category distribution in the actual student score data set is usually unbalanced. For example, only 10% of the students may have excellent grades, 50% of the students may have good grades, 30% may have passed grades, and 10% may have failed grades. This imbalance makes the existing models tend to favor the majority category when predicting, thereby ignoring the minority category. In response to the problem of category imbalance, most traditional student score prediction models are unable to effectively deal with this problem, resulting in low overall accuracy, especially poor performance in identifying minority categories. At present, the methods for dealing with imbalanced problems at the data level are not specifically designed for the field of student score prediction, so it is difficult to significantly improve the prediction accuracy.
[0004] In view of this, the applicant filed this application after studying the existing technology. Summary of the invention
[0005] The present invention aims to provide a data prediction method, device, equipment and medium of oversampling multi-cluster fusion to solve the problem of imbalance of student performance data in existing student performance prediction methods, thereby improving the prediction accuracy of student performance prediction models.
[0006] In order to solve the above technical problems, the present invention is implemented through the following technical solutions: A data prediction method of oversampling multi-clustering fusion, comprising: S1, obtaining an original data set, and dividing it into minority class data and majority class data after preprocessing; wherein the original data set includes student scores; S2, clustering the minority class data using several different clustering algorithms, and adding the generated cluster center data to the minority class data; S3, performing IF-SNNDPC clustering on the minority class data after adding the cluster center to obtain multiple subclusters, and calculating the oversampling number of each subcluster; wherein, the IF-SNNDPC is an improved DPC clustering algorithm, which reconstructs the similarity measurement formula in the DPC clustering algorithm through the gravity formula, and calculates the local density of the data points by combining the shared neighbor information and the distance between the data points; S4, in each subcluster, according to the oversampling number of the subcluster, the centroid between two randomly selected non-cluster center points and the cluster center is calculated, and the calculated centroid is added as a new sample to the minority class data until the number of samples required by the corresponding subcluster is met, thereby obtaining the final minority class data; S5, combining the final minority class data with the majority class data and inputting them into the pre-trained XGBoost model to obtain predicted data.
[0007] Preferably, the different clustering algorithms include a GMM clustering algorithm and a k-means clustering algorithm.
[0008] Preferably, the IF-SNNDPC clustering reconstructs the similarity measurement formula in the DPC clustering through the gravity formula, and its expression is: ; ; ; ; Among them, F represents analog gravity; k represents a constant; Represents sample data points The local density of Represents sample data points The local density of Represents sample data points , The number of shared neighbors between ; , Represents sample data points , With shared neighbors The distance and; ; Represents sample data points , The similarity between them; P represents the sample data point , The set of shared neighbors of Represents sample data points , The distance between pairs of points.
[0009] Preferably, the calculation formula for the oversampling number of each sub-cluster is: ; in, Indicates the first The number of clusters to oversample; Indicates the number of samples of the majority class set; Indicates The number of original samples in the cluster; Represents the number of existing samples of class c.
[0010] Preferably, the pre-trained XGBoost model is obtained by the following steps: Divide the preprocessed sample data set into a training set and a test set; The training set is divided into minority class training data and majority class training data, and the minority class training data is subjected to oversampling multi-clustering fusion processing from steps S2 to S4 to obtain final minority class training data; The final minority class training data and the majority class training data are used to train the XGBoost model using a fold cross validation method to obtain a trained XGBoost model; The trained XGBoost model is evaluated using a test set, and when the evaluation result meets the preset standard, the final XGBoost model, i.e., the pre-trained XGBoost model, is obtained.
[0011] The present invention also provides a data prediction device for oversampling multi-cluster fusion, comprising: A preprocessing unit is used to obtain an original data set, and after preprocessing, divide it into minority class data and majority class data; wherein the original data set includes student scores; A multi-clustering unit, used to cluster the minority class data using several different clustering algorithms, and add the generated cluster center data to the minority class data; An IF-SNNDPC clustering unit is used to perform IF-SNNDPC clustering on the minority class data after adding the cluster center to obtain multiple subclusters, and calculate the oversampling number of each subcluster; wherein the IF-SNNDPC is an improved DPC clustering algorithm, which reconstructs the similarity measurement formula in the DPC clustering algorithm through the gravitational formula, and calculates the local density of the data points by combining the shared neighbor information and the distance between the data points; An oversampling unit is used to calculate the centroid between two randomly selected non-cluster center points and the cluster center in each subcluster according to the oversampling number of the subcluster, and add the calculated centroid as a new sample to the minority class data until the number of samples required by the corresponding subcluster is met, thereby obtaining the final minority class data; The output unit is used to combine the final minority class data with the majority class data and input them into the pre-trained XGBoost model to obtain the predicted score.
[0012] The present invention also provides an oversampling multi-cluster fusion data prediction device, comprising a processor and a memory, wherein the memory stores a computer program, and the computer program can be executed by the processor to implement the oversampling multi-cluster fusion data prediction method as described above.
[0013] The present invention also provides a computer-readable storage medium, on which computer-readable instructions are stored. When the computer-readable instructions are executed by a processor of a device where the computer-readable storage medium is located, the above-mentioned oversampling multi-cluster fusion data prediction method is implemented.
[0014] In summary, compared with the prior art, the present invention has the following beneficial effects: The present invention adopts a clustering framework of oversampling multiple clustering algorithms (abbreviated as MCD-CSMOTE, Multipleclustering and DPC – Center SMOTE), first clusters each minority class with different clustering algorithms, adds the cluster centers generated by these clustering methods as minority class samples to the original data set, and then uses center oversampling for each cluster after clustering, that is, selects two points, the cluster center and other non-cluster centers within the cluster, calculates the centroid of these three points to produce a new sample and adds it to the sample data. By adopting the oversampling technology of the present invention, the number of samples of the minority class can be increased, thereby solving the problem of imbalanced sample data categories during the training process of the model, thereby improving the prediction ability of the minority class and enhancing the prediction performance of the model.
[0015] In addition, oversampling not only helps to improve the accuracy and generalization ability of the prediction model, but also enhances the model's ability to learn data on multi-dimensional features (such as study time, attendance rate, family background, etc.), thereby more accurately capturing the various influencing factors behind student performance, providing more reliable support for student performance prediction, and thus providing a strong data basis for intelligent decision-making in the field of education. BRIEF DESCRIPTION OF THE DRAWINGS In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings required for use in the embodiments will be briefly introduced below. It should be understood that the following drawings only show certain embodiments of the present invention and therefore should not be regarded as limiting the scope. For ordinary technicians in this field, other related drawings can be obtained based on these drawings without paying creative work.
[0016] Figure 1A schematic diagram of a data prediction method of oversampling multi-cluster fusion provided in Example 1.
[0017] Figure 2 A framework diagram of a data prediction method of oversampling multi-cluster fusion provided in Example 1.
[0018] Figure 3 A schematic diagram of shared neighbors provided in Example 1.
[0019] Figure 4 A schematic diagram of an oversampling multi-cluster fusion data prediction device provided in Example 2.
[0020] The present invention is further described in detail below in conjunction with the accompanying drawings and specific embodiments. DETAILED DESCRIPTION
[0021] In order to make the purpose, technical solutions and advantages of the embodiments of the present invention clearer, the technical solutions in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without making creative work are within the scope of protection of the present invention. Therefore, the following detailed description of the embodiments of the present invention provided in the drawings is not intended to limit the scope of the invention claimed for protection, but merely represents the selected embodiments of the present invention. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without making creative work are within the scope of protection of the present invention.
[0022] Embodiment 1 Embodiment 1 of the present invention provides a data prediction method for oversampling multi-cluster fusion, which can be implemented by an oversampling multi-cluster fusion data prediction device (hereinafter referred to as a construction device), and in particular, executed by one or more processors in the construction device.
[0023] In this embodiment, the construction device may be an electronic device equipped with a processor, the processor having a computer program of the oversampling multi-cluster fusion data prediction method and the computer program can be executed, such as a computer, a smart phone, a smart tablet, a workstation, etc., which is not limited here.
[0024] In this embodiment, oversampling refers to increasing the number of samplings of minority class examples in the training set to reduce class imbalance, such as SMOTE (Synthetic Minority Oversampling Technique). SMOTE is an interpolation-based oversampling technique used to deal with the problem of imbalanced data sets. The corresponding undersampling is to reduce the number of samplings of majority class examples.
[0025] like Figure 1 As shown, a data prediction method of oversampling multi-cluster fusion includes steps S1 to S5.
[0026] S1, obtaining the original data set, and dividing it into minority class data and majority class data after preprocessing; wherein the original data set includes student scores.
[0027] In this embodiment, data related to student scores can be collected or an official public data set can be directly used as the original data set; then, after pre-processing such as data cleaning, data change, and data partitioning, the data can be divided into minority data and majority data. Minority data, such as low-segment scores and high-segment scores; majority data, such as passing scores, etc. The original data set of the present invention can also use data of other unbalanced categories, and after the prediction model is trained by the method of the present invention, it can be used for data prediction.
[0028] S2, clustering the minority class data using several different clustering algorithms, and adding the generated cluster center data to the minority class data.
[0029] Furthermore, the different clustering algorithms include GMM clustering algorithm, k-means clustering algorithm, DPC clustering algorithm, etc., which are not limited here. In this embodiment, one or more clustering algorithms can be selected to cluster the data according to actual conditions, and the obtained cluster centers are added to the sample data to increase the amount of sample data.
[0030] In this embodiment, GMM: Gaussian Mixture Model, GMM is a probability model used to represent that a data set is composed of multiple Gaussian distribution components. GMM introduces latent variables to indicate which cluster the data belongs to, and uses the maximum expectation algorithm (EM algorithm) for parameter estimation. In GMM, each component is a Gaussian distribution, and the entire model is the weighted sum of these Gaussian distributions.
[0031] K-Means clustering is one of the most commonly used clustering algorithms. It minimizes the centroid of each cluster and the sum of squares of the data points within the cluster through iterative optimization. Its goal is to minimize the within-cluster sum of squares (WCSS), which is the sum of the squares of the distance from each point to the center of its cluster.
[0032] DPC: Density Peaks Clustering, DPC is a clustering algorithm based on density peaks, which can automatically find cluster centers and achieve efficient clustering of data of any shape. The DPC algorithm is based on two assumptions: the density of the cluster center should be relatively large, and the cluster center should be far away from points with greater density. The algorithm calculates the local density and relative distance of each point, and then selects points with larger density and relative distance as cluster centers. Finally, data points that are not cluster centers are classified to the nearest cluster center.
[0033] like Figure 2 As shown, this embodiment selects GMM clustering and k-means clustering as the clustering framework algorithm in this step, and then adds the data of the two cluster centers generated by GMM clustering and k-means clustering to the minority class data.
[0034] S3, performing IF-SNNDPC clustering on the minority class data after adding the cluster center to obtain multiple subclusters, and calculating the oversampling number of each subcluster; wherein, the IF-SNNDPC is an improved DPC clustering algorithm, which reconstructs the similarity measurement formula in the DPC clustering algorithm through the gravitational formula, and calculates the local density of the data points by combining the shared neighbor information and the distance between the data points.
[0035] The IF-SNNDPC clustering reconstructs the similarity measurement formula in the DPC clustering through the gravity formula, and its expression is: Gravity formula: ; Among them, F represents analog gravity. The concept of "gravity" here is analogical and does not represent the actual physical force. This formula refers to the standard gravity formula. Similarly, the sample has no mass, and we use the local density of the sample instead of the mass; k represents a constant; Represents sample data points The local density of Represents sample data points The local density of Represents sample data points , The distance between pairs of points.
[0036] In physics, gravity is related to the mass of two objects and the distance between them. Similarly, in DPC clustering, we can think of “mass” as the “density” of data points, and “distance” as the actual distance between data points.
[0037] use and Constructing sample data points , The relationship between: ; ; Thus a new similarity formula is constructed: ; in, Represents sample data points , The number of shared neighbors between Figure 3 Schematic diagram of shared neighbors shown); , Represents sample data points , With shared neighbors The distance and; ; Represents sample data points , The similarity between them; P represents the sample data point , The set of shared neighbors.
[0038] After IF-SNNDPC clustering, the oversampling number of each subcluster is calculated using the formula: ; This formula means that in the cth In a cluster, the number of oversampling required for the cluster is related to the number of original samples in the cluster and the number of generated samples required for the class. Indicates the first The number of clusters to oversample; Represents the number of majority class samples set; Indicates The number of original samples in the cluster; Represents the number of existing samples of class c.
[0039] In this embodiment, by calculating the oversampling amount of each sub-cluster, the data balance between the sub-clusters can be evaluated, so as to adjust the sampling strategy and reduce the risk of overfitting.
[0040] S4, in each subcluster, according to the oversampling number of the subcluster, calculate the centroid between two randomly selected non-cluster center points and the cluster center, and add the calculated centroid as a new sample to the minority class data until the number of samples required by the corresponding subcluster is met, thereby obtaining the final minority class data.
[0041] In the DPC algorithm, cluster centers are determined by the local density of data points and their minimum distance to higher density points. Non-cluster center points are data points other than cluster centers.
[0042] The centroid of a cluster is the average value of all data points in the cluster. In this embodiment, the sampling strategy of each subcluster is obtained according to the oversampling amount of the subcluster, and the midpoint between the two selected non-cluster center points and the cluster center is calculated, that is, the centroid of the line segment, and then the centroid is added to the minority class data until the data of the subcluster meets the requirements, and then the next subcluster is oversampled to obtain the final minority class data.
[0043] S5, combining the final minority class data with the majority class data and inputting them into the pre-trained XGBoost model to obtain predicted data.
[0044] Furthermore, the pre-trained XGBoost model is obtained by the following steps: Divide the preprocessed sample data set into a training set and a test set; The training set is divided into minority class training data and majority class training data, and the minority class training data is subjected to the oversampling multi-clustering fusion process of steps S2 to S4 to obtain final minority class training data; The final minority class training data and the majority class training data are used to train the XGBoost model using a fold cross validation method to obtain a trained XGBoost model; The trained XGBoost model is evaluated using a test set, and when the evaluation result meets the preset standard, the final XGBoost model, i.e., the pre-trained XGBoost model, is obtained.
[0045] The newly acquired imbalanced data set is predicted using the pre-trained XGBoost model, and the prediction results are output.
[0046] In this embodiment, XGBoost: eXtreme Gradient Boosting is an efficient gradient boosting algorithm for tasks such as classification, regression, and sorting. It is based on the decision tree model and builds a strong classifier by integrating multiple weak classifiers. XGBoost adds a new decision tree in each iteration to correct the error of the previous model, and prevents overfitting through techniques such as regularization and scaling. At the same time, it also supports parallel processing and distributed computing to improve training speed and efficiency.
[0047] In another preferred embodiment, the method of the present invention is experimented with a data set from a secondary school mathematics course and a Portuguese course, which can be obtained from the machine learning database of the University of California, Los Angeles. The data set contains a series of variables, such as academic performance, demographic information, social background data, and school-specific characteristics, which help to more fully understand the various factors that affect student performance. The data set of the mathematics course (data set 1) contains 395 samples, while the data set of the Portuguese course (data set 2) contains 649 samples. In both data sets, there are 32 attributes related to educational information and one attribute corresponding to the final grade Grade. In order to facilitate a deeper understanding of the composition and characteristics of the data set, a detailed statistical overview is listed as shown in Table 1. Since the set grade value is between 0 and 20 (such as G1, G2, G3 in Table 1), the classification of the final grade Grade is determined by the following thresholds: (1) If the value is less than 10, it is considered a failure; (2) If the value is between 10 (inclusive) and 12, it is qualified; (3) If the value is between 12 (inclusive) and 14 (inclusive), it is considered satisfactory; (4) If the value is between 14 (inclusive) and 16 (inclusive), it is considered good; (5) Values of 16 and above are considered excellent.
[0048] Table 1 Statistical characteristics of the UCI student achievement dataset
[0049]
[0050]
[0051] After dividing the processed student score data set into a training set and a test set, a 5-fold cross validation was used. The specific steps are to divide the data set into 5 subsets. In each iteration, one subset is selected as the test set to verify the model performance, and the remaining 4 subsets are used as training sets for model training. This process is repeated 5 times, and the training set and test set are replaced each time. Finally, the average of the 5 results is used as the comprehensive performance evaluation of the model.
[0052] Through this experiment, it can be found that the oversampling method of the present invention solves the imbalance problem of student performance data at the data level, effectively improves the prediction ability of the XGBoost model for minority class data, thereby improving the overall prediction performance.
[0053] Experimental results show that the model using the method of the present invention not only helps to improve the accuracy and generalization ability of the prediction model, but also enhances the model's ability to learn multi-dimensional feature data (such as study time, attendance rate, family background, etc.), thereby more accurately capturing the various influencing factors behind student performance, providing more reliable support for student performance prediction, and further providing a strong data basis for intelligent decision-making in the field of education.
[0054] In summary, compared with the prior art, the present invention has the following beneficial effects: By adopting the oversampling technology of the present invention, the number of samples of minority categories can be increased, thereby solving the problem of imbalance in sample data categories during model training, thereby improving the prediction ability of minority categories and enhancing the prediction performance of the model.
[0055] Embodiment 2 like Figure 4 As shown, the second embodiment of the present invention further provides a data prediction device for oversampling multi-cluster fusion, comprising: A preprocessing unit is used to obtain an original data set, and after preprocessing, divide it into minority class data and majority class data; wherein the original data set includes student scores; A multi-clustering unit, used to cluster the minority class data using several different clustering algorithms, and add the generated cluster center data to the minority class data; An IF-SNNDPC clustering unit is used to perform IF-SNNDPC clustering on the minority class data after adding the cluster center to obtain multiple subclusters, and calculate the oversampling number of each subcluster; wherein the IF-SNNDPC is an improved DPC clustering algorithm, which reconstructs the similarity measurement formula in the DPC clustering algorithm through the gravitational formula, and calculates the local density of the data points by combining the shared neighbor information and the distance between the data points; An oversampling unit is used to calculate the centroid between two randomly selected non-cluster center points and the cluster center in each subcluster according to the oversampling number of the subcluster, and add the calculated centroid as a new sample to the minority class data until the number of samples required by the corresponding subcluster is met, thereby obtaining the final minority class data; The output unit is used to combine the final minority class data with the majority class data and input them into the pre-trained XGBoost model to obtain the predicted score.
[0056] Embodiment 3 The third embodiment of the present invention also provides a data prediction device for oversampling multi-cluster fusion, which includes a memory and a processor, wherein the memory stores a computer program, and the computer program can be executed by the processor to implement the data prediction method for oversampling multi-cluster fusion as described above.
[0057] Embodiment 4 The fourth embodiment of the present invention also provides a computer-readable storage medium, on which computer-readable instructions are stored. When the computer-readable instructions are executed by a processor of a device where the computer-readable storage medium is located, the data prediction method for oversampling multi-cluster fusion as described above is implemented.
[0058] In several embodiments provided in the embodiments of the present invention, it should be understood that the disclosed apparatus and method can also be implemented in other ways. The apparatus and method embodiments described above are merely schematic. For example, the flowcharts in the accompanying drawings show the possible architecture, functions and operations of the apparatus, method and computer program product according to multiple embodiments of the present invention. In this regard, each box in the flowchart or block diagram can represent a module, a program segment or a part of a code, and the module, program segment or a part of the code contains one or more executable instructions for implementing the specified logical function. It should also be noted that in some alternative implementations, the functions marked in the box can also occur in a different order from the order marked in the accompanying drawings. For example, two consecutive boxes can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each box in the block diagram and / or flow chart, and the combination of boxes in the block diagram and / or flow chart can be implemented with a dedicated hardware-based system that performs a specified function or action, or can be implemented with a combination of dedicated hardware and computer instructions.
[0059] In addition, the functional modules in the various embodiments of the present invention may be integrated together to form an independent part, or each module may exist independently, or two or more modules may be integrated to form an independent part.
[0060] If the function is implemented in the form of a software function module 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 invention is essentially or the part that contributes to the prior art or the part of the technical solution can be embodied in the form of a software product, which is stored in a storage medium and includes several instructions to enable a computer device (which can be a personal computer, an electronic device, or a network device, etc.) to perform all or part of the steps of the method described in each embodiment of the present invention. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), disk or optical disk and other media that can store program code. It should be noted that in this article, the term "include", "include" or any other variant thereof is intended to cover non-exclusive inclusion, so that the process, method, article or device including a series of elements includes not only those elements, but also includes other elements that are not explicitly listed, or also includes elements inherent to such process, method, article or device. Without more constraints, an element defined by the phrase "comprising a..." does not exclude the existence of other identical elements in the process, method, article or apparatus comprising the element.
[0061] The terms used in the embodiments of the present invention are only for the purpose of describing specific embodiments, and are not intended to limit the present invention. The singular forms "a", "said" and "the" used in the embodiments of the present invention and the appended claims are also intended to include plural forms, unless the context clearly indicates other meanings.
[0062] It should be understood that the term "and / or" used in this article is only a description of the association relationship of associated objects, indicating that there can be three relationships. For example, A and / or B can represent: A exists alone, A and B exist at the same time, and B exists alone. In addition, the character " / " in this article generally indicates that the associated objects before and after are in an "or" relationship.
[0063] The word "if" as used herein may be interpreted as "at the time of" or "when" or "in response to determining" or "in response to detecting", depending on the context. Similarly, the phrases "if it is determined" or "if (stated condition or event) is detected" may be interpreted as "when it is determined" or "in response to determining" or "when detecting (stated condition or event)" or "in response to detecting (stated condition or event)", depending on the context.
[0064] The "first\second" mentioned in the embodiments is only to distinguish similar objects, and does not represent a specific order for the objects. It is understandable that the "first\second" can be interchanged with the specific order or sequence where permitted. It should be understood that the objects distinguished by "first\second" can be interchanged where appropriate, so that the embodiments described herein can be implemented in an order other than those illustrated or described herein.
[0065] The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. For those skilled in the art, the present invention may have various modifications and variations. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present invention shall be included in the protection scope of the present invention.
Claims
1. A data prediction method based on oversampling multi-clustering fusion for student performance prediction, characterized in that: include: S1, obtaining an original data set, and dividing it into minority class data and majority class data after preprocessing; wherein the original data set includes student scores; S2, clustering the minority class data using several different clustering algorithms, and adding the generated cluster center data to the minority class data; S3, performing IF-SNNDPC clustering on the minority class data after adding the cluster center to obtain multiple subclusters, and calculating the oversampling number of each subcluster; wherein, the IF-SNNDPC is an improved DPC clustering algorithm, which reconstructs the similarity measurement formula in the DPC clustering algorithm through the gravity formula, and calculates the local density of the data points by combining the shared neighbor information and the distance between the data points; S4, in each subcluster, according to the oversampling number of the subcluster, the centroid between two randomly selected non-cluster center points and the cluster center is calculated, and the calculated centroid is added as a new sample to the minority class data until the number of samples required by the corresponding subcluster is met, thereby obtaining the final minority class data; S5, combining the final minority class data with the majority class data and inputting them into the pre-trained XGBoost model to obtain predicted data.
2. The data prediction method of oversampling multi-clustering fusion according to claim 1 is characterized in that ,The different clustering algorithms include GMM clustering algorithm and k-means clustering algorithm.
3. The data prediction method of oversampling multi-clustering fusion according to claim 1 is characterized in that ,The IF-SNNDPC clustering reconstructs the similarity measurement formula in DPC clustering through the gravity formula, and its expression is: ; ; ; ; Among them, F represents analog gravity; k represents a constant; Represents sample data points The local density of Represents sample data points The local density of Represents sample data points , The number of shared neighbors between ; , Represents sample data points , With shared neighbors The distance and; ; Represents sample data points , The similarity between them; P represents the sample data point , The set of shared neighbors of Represents sample data points , The distance between pairs of points.
4. The data prediction method of oversampling multi-clustering fusion according to claim 1 is characterized in that ,The calculation formula for the number of oversampling of each sub-cluster is: ; in, Indicates the first The number of clusters to oversample; Represents the number of majority class samples set; Indicates The number of original samples in the cluster; Represents the number of existing samples of class c.
5. The data prediction method of oversampling multi-clustering fusion according to claim 1 is characterized in that ,The pre-trained XGBoost model is obtained by the following steps: Divide the preprocessed sample data set into a training set and a test set; The training set is divided into minority class training data and majority class training data, and the minority class training data is subjected to oversampling multi-clustering fusion processing from steps S2 to S4 to obtain final minority class training data; The final minority class training data and the majority class training data are used to train the XGBoost model using a fold cross validation method to obtain a trained XGBoost model; The trained XGBoost model is evaluated using a test set, and when the evaluation result meets the preset standard, the final XGBoost model, i.e., the pre-trained XGBoost model, is obtained.
6. An oversampling multi-clustering fusion data prediction device for student performance prediction, characterized in that: include: A preprocessing unit is used to obtain an original data set, and after preprocessing, divide it into minority class data and majority class data; wherein the original data set includes student scores; A multi-clustering unit, used to cluster the minority class data using several different clustering algorithms, and add the generated cluster center data to the minority class data; An IF-SNNDPC clustering unit is used to perform IF-SNNDPC clustering on the minority class data after adding the cluster center to obtain multiple subclusters, and calculate the oversampling number of each subcluster; wherein the IF-SNNDPC is an improved DPC clustering algorithm, which reconstructs the similarity measurement formula in the DPC clustering algorithm through the gravitational formula, and calculates the local density of the data points by combining the shared neighbor information and the distance between the data points; An oversampling unit is used to calculate the centroid between two randomly selected non-cluster center points and the cluster center in each subcluster according to the oversampling number of the subcluster, and add the calculated centroid as a new sample to the minority class data until the number of samples required by the corresponding subcluster is met, thereby obtaining the final minority class data; The output unit is used to combine the final minority class data with the majority class data and input them into the pre-trained XGBoost model to obtain the predicted score.
7. A data prediction device for oversampling multi-cluster fusion, characterized in that: It includes a processor and a memory, wherein the memory stores a computer program, and the computer program can be executed by the processor to implement an oversampling multi-cluster fusion data prediction method as described in any one of claims 1-5.
8. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores computer-readable instructions, and when the computer-readable instructions are executed by a processor of a device where the computer-readable storage medium is located, the method for predicting data using oversampling multi-cluster fusion as described in any one of claims 1 to 5 is implemented.