Load classification method and device based on coarse clustering and support vector data description
By using the clusters determined by coarse clustering as the initial categories of the support vector data description model, the problem of low load classification efficiency in existing technologies is solved, and efficient and accurate load classification is achieved.
Patent Information
- Application Number
- CN202511818068.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-12-04
- Publication Date
- 2026-03-06
AI Technical Summary
Existing support vector data description models are inefficient in load classification, especially in multi-class problems where the initial splitting method needs to be changed multiple times, affecting classification efficiency.
Using the clusters determined by coarse clustering as the initial categories for the support vector data description model provides high-quality initial category partitioning, reduces adjustments during training, and improves training efficiency.
It significantly improves the training efficiency of support vector data description models, enhances the accuracy and robustness of load classification, and enables rapid training and automatic discovery of new load types.
Smart Images

Figure CN121614946A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of power load classification technology, and specifically to a load classification method and apparatus based on coarse clustering and support vector data description. Background Technology
[0002] Load identification and aggregation technology (load classification) is an important foundation for realizing refined management of electricity consumption on the user side and promoting the development of smart grids.
[0003] In existing technologies, clustering algorithms are commonly used to cluster workloads to determine their respective categories. Support Vector Domain Description (SVM) is a frequently used clustering algorithm; however, during training, especially for multi-class problems, this algorithm requires accurate initial classification of the multiple classes. Otherwise, to improve classification accuracy, the initial classification method needs to be changed multiple times, and training is performed for each class separately. This affects the efficiency of the classification process. Summary of the Invention
[0004] The purpose of this invention is to provide a load classification method and apparatus based on coarse clustering and support vector data description. By using the clusters determined by coarse clustering as the initial categories for training the support vector data description model, the training efficiency of the support vector data description model is improved, and the problem of low load classification efficiency in existing support vector data description model algorithms is solved.
[0005] This invention is achieved through the following technical solution:
[0006] The first aspect of this application provides a load classification method based on coarse clustering and support vector data description, including:
[0007] The time-series data of the load to be classified is obtained, and a feature vector of the load to be classified is formed based on the time-series data; the time-series data includes multi-dimensional data characterizing the electricity consumption characteristics of the load.
[0008] The feature vector is input into a pre-trained support vector data description model to obtain the load type output by the support vector data description model; during training, the support vector data description model uses the clusters determined by coarse clustering of the load samples as the initial categories.
[0009] In one feasible implementation, the method further includes: inputting the feature vector into a pre-trained support vector data description model, causing the support vector data description model to perform:
[0010] Calculate the relative distances between the feature vectors and the centers of the spheres for each category determined by the pre-trained support vector data description model;
[0011] Based on the relationship between the minimum value of each relative distance and the preset threshold, the load type of the load to be classified is output.
[0012] In one feasible implementation, the step of outputting the load type of the load to be classified based on the relationship between the minimum value of the relative distance and a preset threshold includes:
[0013] If the minimum value is not greater than a preset threshold, then the load to be classified belongs to the category of the sphere center corresponding to the minimum value;
[0014] If the minimum value is greater than the preset threshold, then the payload to be classified does not belong to the existing category of the pre-trained support vector data description model.
[0015] In one feasible implementation, if the minimum value is greater than the preset threshold, the method further includes:
[0016] The load to be classified is used as an initial category, and the support vector data description model is retrained.
[0017] In one feasible implementation, the method further includes: training the support vector data description model, specifically including:
[0018] Obtain each initial cluster obtained by coarse clustering, and use each initial cluster as a training set;
[0019] In each iteration of training, for each training set, the following steps are performed: solve the preset objective function to determine a sphere; maximize the number of samples within the clusters that the sphere can enclose, and minimize the radius of the sphere as the optimization objective of the objective function;
[0020] For each sample in each training set, calculate the relative distance from that sample to each sphere center;
[0021] The category to which the center of the sphere corresponds to the minimum value among the relative distances is used as the category label of the sample, and the sample is classified into that category;
[0022] Determine the migration rate of each sample in this iteration; if the migration rate is less than the preset migration rate threshold or reaches the preset number of iterations, end the iteration and obtain the trained support vector data description model.
[0023] In one feasible implementation, the coarse clustering determines the initial number of clusters based on the cluster profile coefficient; specifically, the number of clusters corresponding to the maximum average profile coefficient of the samples is used as the initial number of clusters.
[0024] In one feasible implementation, the feature vector includes timing features formed based on the timing data, statistical features determined by statistical analysis of the timing data, and electrical features calculated based on the timing data.
[0025] A second aspect of this application provides a load classification apparatus based on coarse clustering and support vector data description, comprising:
[0026] A data acquisition unit is used to acquire time-series data of the load to be classified, and to form a feature vector of the load to be classified based on the time-series data; the time-series data includes multi-dimensional data characterizing the electricity consumption characteristics of the load;
[0027] The load classification unit is used to input the feature vector into the pre-trained support vector data description model to obtain the load type output by the support vector data description model; during training, the support vector data description model uses the clusters determined by coarse clustering of the load samples as the initial categories.
[0028] A third aspect of this application provides an electronic device, including: a processor, a memory, and a program or instructions stored in the memory and executable on the processor, wherein the program or instructions, when executed by the processor, implement the steps of the above-described method.
[0029] A fourth aspect of this application provides a storage medium, comprising: storing a program or instructions on the storage medium, wherein the program or instructions, when executed by a processor, implement the steps of the above-described method.
[0030] Compared with the prior art, the present invention has the following advantages and beneficial effects:
[0031] In this embodiment, the clusters determined by coarse clustering are used as the initial categories for training the support vector data description model. By providing high-quality initial category classification to the support vector data description model through coarse clustering of samples, the support vector data description model can be trained quickly without changing the initial categories, thereby improving the training efficiency of the support vector data description model and solving the problem of low classification efficiency of existing support vector data description model algorithms. Attached Figure Description
[0032] To more clearly illustrate the technical solutions of the exemplary embodiments of the present invention, the accompanying drawings used in the embodiments will be briefly described below. It should be understood that the following drawings only show some embodiments of the present invention and should not be considered as a limitation of the scope. For those skilled in the art, other related drawings can be obtained based on these drawings without creative effort. In the drawings:
[0033] Figure 1A flowchart illustrating a load classification method based on coarse clustering and support vector data description provided in this application embodiment;
[0034] Figure 2 This is a flowchart illustrating a specific implementation of a load classification method based on coarse clustering and support vector data description, provided in an embodiment of this application.
[0035] Figure 3 A schematic diagram of a load classification device based on coarse clustering and support vector data description provided in this application embodiment;
[0036] Figure 4 This is a schematic diagram of the structure of a computing device provided in an embodiment of this application. Detailed Implementation
[0037] To make the objectives, technical solutions, and advantages of this invention clearer, the invention will be further described in detail below with reference to embodiments and accompanying drawings. The illustrative embodiments and descriptions of this invention are for explanation only and are not intended to limit the invention. All other embodiments obtained by those skilled in the art based on the embodiments in this application without creative effort are within the scope of protection of this application.
[0038] As will be known to those skilled in the art, with the development of technology and the emergence of new scenarios, the technical solutions provided in the embodiments of this application are also applicable to similar technical problems.
[0039] The terms “comprising” and “having”, and any variations thereof, in the specification, claims, and accompanying drawings of this application are intended to cover non-exclusive inclusion, so that a process, method, system, product, or apparatus that comprises a series of elements is not necessarily limited to those elements, but may include other elements not expressly listed or inherent to such process, method, product, or apparatus.
[0040] Example 1
[0041] Embodiment 1 of this application provides a load classification method based on coarse clustering and support vector data description, in order to solve the problem of low load classification efficiency of existing support vector data description model algorithms.
[0042] The subject executing this method can be any computing device capable of implementing the method, such as a server, mobile phone, personal computer, smart wearable device, smart robot, etc.
[0043] Furthermore, the embodiments of this application do not limit the execution order of different steps. When using the method provided in the embodiments of this application, the execution order of different steps can be adjusted according to actual needs.
[0044] For ease of description, the following uses a load classification device based on coarse clustering and support vector data description as the execution subject of this method to provide a detailed description of the method provided in this application embodiment.
[0045] like Figure 1 The diagram shown is a flowchart illustrating a specific implementation of a load classification method based on coarse clustering and support vector data description provided in this application, including the following steps 11-12:
[0046] Step 11: Obtain the time series data of the load to be classified, and form a feature vector of the load to be classified based on the time series data.
[0047] Time-series load data is collected from at least one of the following data sources: load management system, smart meter, electricity consumption information collection system, and dedicated transformer acquisition terminal.
[0048] The time-series data includes multi-dimensional data characterizing the load's electricity consumption characteristics, specifically including the load's voltage time-series data (such as voltage time-series curves), current time-series data (such as current time-series curves), and power time-series data (such as active power time-series curves).
[0049] The time series of voltage RMS values collected from the data source is represented as follows: ;
[0050] The time series of RMS current values collected from the data source is represented as follows: ;
[0051] The time series of active power RMS values collected from the data source is represented as follows: ;
[0052] Where T is the number of sampling points in one period, for example, for a daily load curve with a 15-minute interval, T=96.
[0053] The acquired time-series data is preprocessed, including data cleaning and normalization.
[0054] Data cleaning includes handling missing data, zero values, or negative values caused by communication interruptions. This is done using linear interpolation or filling methods based on previous or subsequent time points.
[0055] Normalization includes: to eliminate the influence of different absolute load magnitudes, maximum-minimum normalization or Z-score standardization is used, so that loads with different capacities but similar operating modes can be clustered together in the feature space.
[0056] The feature vector includes timing features formed based on the timing data, statistical features determined by statistical analysis of the timing data, and electrical features calculated based on the timing data.
[0057] The determination of time series features can be achieved by using all or the main components of the normalized P(t) and I(t) (the components with more than 95% variance can be retained after dimensionality reduction by principal component analysis (PCA)) as time series features.
[0058] Statistical characteristics include the mean, standard deviation, skewness, peak value, load factor, and peak-to-valley difference rate calculated based on the active power curve.
[0059] The load factor LF is calculated as follows: Peak-valley difference rate The calculation is as follows ; This represents the power mean in the common power curve. Indicates peak power. This represents the valley power.
[0060] Electrical characteristics include average power factor, current-start characteristics (such as the ratio of starting current to steady-state current), and an estimate of the total harmonic distortion rate of the current.
[0061] The aforementioned time-series characteristics, statistical characteristics, and electrical characteristics are represented as a single... 3D feature vector , Indicates load.
[0062] During training, all the loads collected constitute the sample set. .
[0063] Step 12: Input the feature vector into the pre-trained support vector data description model to obtain the load type output by the support vector data description model.
[0064] After inputting the feature vectors into the pre-trained support vector data description model, the support vector data description model performs the following steps 1201-1202:
[0065] Step 1201: Calculate the relative distances between the feature vectors and the centers of the spheres for each category determined by the pre-trained support vector data description model. ;
[0066] The relative distance is calculated as follows: Where k represents the category identifier (or the center of the sphere identifier). A mapping function representing the high-dimensional feature space of the load. This represents the center of the ball in the k-th category. This represents the radius of the sphere belonging to the k-th category.
[0067] Step 1202: Based on the relationship between the minimum value of each relative distance and the preset threshold, output the load type of the load to be classified.
[0068] If the minimum value is not greater than a preset threshold (which may be a lenient threshold as described below), then the payload to be classified belongs to the category of the sphere center corresponding to the minimum value; if the minimum value is greater than the preset threshold, then the payload to be classified does not belong to the existing category of the pre-trained support vector data description model.
[0069] Furthermore, when the minimum value is greater than the preset threshold, the load to be classified is used as an initial category, and the support vector data description model is retrained.
[0070] Specifically: Based on the relationship between the minimum value of each relative distance and a preset threshold, the following three judgment rules are included:
[0071] Rule 1 (Strict Match): If This indicates that the load falls within the boundary of an existing category and should be directly assigned to that category.
[0072] Rule 2 (Loose Match): If (θ is a lenient threshold, usually taken as 1.2~1.5), indicating that although the load is outside the boundary, it is very close and is likely to belong to this category. For aggregation purposes, it is classified into the closest category.
[0073] Rule 3 (New Category): If It was identified as a new type of load. The system automatically created a new category K+1 for it and assigned it a specific name. Use the initial training set to train the (K+1)th SVDD model and update the model library.
[0074] The training process of the support vector data description model specifically includes the following steps: Steps 1211-1215:
[0075] Step 1211: Obtain the initial clusters obtained from coarse clustering. Each of the initial clusters is used as a training set;
[0076] All samples contained in each initial cluster As a positive sample training set.
[0077] A Gaussian radial basis function (RBF) kernel is selected to process the feature vectors of the samples to determine the high-dimensional feature space mapping function of the samples; the Gaussian RBF kernel function can be expressed as: ,in For kernel parameters.
[0078] Step 1212: In each iteration of training, for each training set, perform the following: solve the preset objective function to determine a sphere; maximize the number of samples within the cluster that the sphere can enclose, and minimize the radius of the sphere as the optimization objective of the objective function.
[0079] The objective function is expressed as: Where R is the radius of the sphere and C is the penalty parameter. Let be a relaxation factor; the objective function is to minimize the radius of the sphere while ensuring that the sphere can encompass most samples within the cluster. This is used to obtain the center of the sphere for each category. and radius .
[0080] After one round of training, save the model parameters for each category: center of sphere. ,radius Support vector sets (Key sample supporting the spherical boundary).
[0081] Step 1213: For each sample in each training set, calculate the relative distance from the sample to each sphere center;
[0082] For each sample in the sample set X Calculate its relative distance to all K sphere centers:
[0083] ;
[0084] K=1,2,...,K The actual calculations are performed using kernel functions, so there is no need to know them explicitly.
[0085] Step 1214: Take the category to which the center of the sphere corresponding to the minimum value among the relative distances belongs as the category label of the sample, and classify the sample into the category to form a new cluster.
[0086] Assign a new label to this sample:
[0087]
[0088] That is, even if a sample is originally in cluster A, it will be assigned to cluster B if it is "closer" to the center of cluster B (relative to the radius).
[0089] For each sample in the training set, the resulting new clusters are divided. .
[0090] For each new cluster Retrain the SVDD model to obtain the updated sphere center. and radius .
[0091] Step 1215: Determine the mobility of each sample in this iteration. If the mobility is less than the preset mobility threshold or the preset number of iterations is reached, the iteration ends and the trained support vector data description model is obtained.
[0092] Mobility threshold The value can be 0.01.
[0093] During the training process described above, through iterative iteration, misclassified samples in the initial clustering can be automatically identified and corrected, making the class division and boundary description continuously approach the optimal, and significantly reducing the sensitivity of the method to the quality of the initial clustering.
[0094] During training, the support vector data description model described above uses the clusters determined by coarse clustering of the load samples as the initial categories.
[0095] Coarse clustering can be performed using the K-means algorithm. The number of clusters K in coarse clustering is determined by the silhouette coefficient. Specifically, different values of K (from 2 to n1, where n1 is the number of typical load types in the region) are tried sequentially. For each K value, clustering is performed and the average silhouette coefficient of all samples is calculated. The K value that maximizes the average silhouette coefficient is selected as the optimal number of clusters.
[0096] The specific process of performing K-means clustering includes: initializing the centroids using the classic K-means algorithm to reduce sensitivity to initial values; and iteratively dividing the sample set X into K clusters. Each sample is assigned an initial cluster label, and the center of each cluster is recorded.
[0097] like Figure 2 As shown, a specific implementation of the method provided in this embodiment includes steps S1-S5, covering the entire process from model training to model inference, wherein steps S1-S4 are the training process and step S5 is the inference process.
[0098] Step S1, Multivariate load feature extraction and preprocessing: This includes acquiring multivariate time-series data of multiple loads, preprocessing the time-series data, and forming a feature vector for each load.
[0099] Step S2, K-means coarse clustering: Using each load from step S1 as a sample, perform K-means clustering to form K clusters.
[0100] Step S3: Train the Support Vector Data Description (SVDD) model for each initial cluster: Use the K clusters determined by coarse clustering as the initial clusters for the SVDD model to train the SVDD model.
[0101] Step S4, iterative verification and optimization during the SVDD model training process, includes sub-steps S4.1-S4.2.
[0102] Sub-step S4.1: Calculate relative distances and redistribute samples; calculate the relative distances from each sample to the center of each category, determine the category to which each sample belongs based on the minimum value among the relative distances, and redistribute samples so that each sample is within the category to which the center of the sphere corresponding to the minimum value belongs.
[0103] Sub-step 4.2, Update SVDD model: Updating the SVDD model actually involves updating the center and radius of the spheres corresponding to each category in the SVDD model.
[0104] When the iteration condition is met, the iteration ends, and the trained support vector data description model is obtained.
[0105] Step S5, Online Identification and Aggregation of New Loads: Input the feature vector of the new load into the trained support vector data description model to obtain the category to which the new load belongs, as output by the support vector data description model.
[0106] In this implementation, the fast and automatic clustering capability of K-means is used to provide high-quality initial class division for SVDD, overcoming the difficulties of SVDD in multi-class initialization; at the same time, the accurate boundary description capability of SVDD is used to correct the coarse boundary of K-means, improving the accuracy and robustness of classification.
[0107] The SVDD model in this embodiment possesses strong adaptability and scalability: it can start working without requiring a large amount of labeled data and can automatically discover hidden load categories in the data. Through the S5 decision rules, the system can flexibly handle new loads and automatically identify and create new load types, possessing the ability to learn and evolve online.
[0108] The classification results are accurate and highly interpretable: SVDD provides clear mathematical boundaries (hyperspheres) for each type of load, making the criteria for "same type of load" clear and quantifiable, avoiding the arbitrariness of manually setting thresholds, and resulting in high reliability and interpretability of the classification results.
[0109] To verify the effectiveness of the classification method in this embodiment, the following description is provided in conjunction with specific, non-limiting examples.
[0110] Scenario: In a power distribution network in a certain district of Chengdu, 500 commercial users are randomly selected for load characteristic analysis and aggregation in preparation for the implementation of a demand response project.
[0111] Implementation process:
[0112] S1: Data Preparation and Feature Extraction
[0113] Collect U(t), I(t), and P(t) data for all users (load) over the past 30 days, at 96 points per day (15-minute intervals).
[0114] For each user, data from a randomly selected normal workday is used for calculation.
[0115] Feature vector construction (20 dimensions in total):
[0116] Morphological features (8 dimensions): PCA was used to reduce the dimensionality of P(t) and I(t), and 4 principal components were retained for each.
[0117] Statistical characteristics (6 dimensions): mean μP, standard deviation σP, deviation γP, peak value κP, load rate LF, peak-to-valley ratio PVRμP of P(t).
[0118] Electrical characteristics (6 dimensions): average power factor, daily average current, maximum / minimum current ratio, and 3 harmonic characteristics (estimated).
[0119] S2: K-means coarse clustering:
[0120] The silhouette coefficient was calculated for K from 2 to 15, and it was found that the silhouette coefficient was the largest (0.63) when K=8.
[0121] K-means++ clustering was performed, initially dividing the 500 users into 8 clusters. The size of each cluster ranged from 35 to 85.
[0122] S3: Construct the initial SVDD model:
[0123] SVDD models were trained for each of the eight clusters mentioned above. The parameters C=0.95 and γ=0.05 were determined through grid search.
[0124] After training, the proportion of samples in each SVDD sphere (i.e., classification accuracy) was statistically analyzed, and the average was approximately 88%.
[0125] S4: Iterative Validation and Optimization
[0126] First iteration: Based on 8 initial SVDD models, 500 samples were reassigned. The class of 70 samples (14%) changed. The 8 SVDD models were then updated.
[0127] Second iteration: Based on the new model, 25 samples (5%) were reassigned. The model was then updated.
[0128] Third iteration: The number of samples was redistributed to 10 (2%).
[0129] Fourth iteration: Only 3 samples (0.6%) changed their categories, which is lower than the set convergence threshold ϵ = 1%, and the iteration stopped.
[0130] Result: The final clustering silhouette coefficient increased from 0.63 to 0.79. Eight distinct load aggregation groups were formed, and after manual verification, their typical characteristics are shown in the following table:
[0131] S5: Online identification of new loads:
[0132] A newly connected load (cold chain warehouse) is connected to the power grid.
[0133] After extracting its features, the relative distances between it and the 8 groups were calculated, and the results are:
[0134] [1.32, 1.45, 1.78, 1.21, 1.05, 1.91, 1.66, 1.55].
[0135] Application of the decision rule:
[0136] 1) The minimum relative distance dmin = 1.05 (corresponding to aggregation group 5: 24-hour convenience store / data center).
[0137] 2) dmin = 1.05 satisfies 1.0 < dmin ≤ θ (θ = 1.2), so Rule 2 (loose matching) is triggered.
[0138] 3) The system classifies the cold chain warehouse into aggregation group 5. After analysis, because the 24-hour operating refrigeration equipment has similarities with the continuous load pattern of the data center in the curve, this aggregation result is acceptable in engineering.
[0139] If a small workshop with night production is connected, its minimum relative distance is 1.85, which is greater than θ, then Rule 3 will be triggered, and the system will create a new load category aggregation group 9 for it.
[0140] This embodiment shows that the method of the present invention can automatically and accurately classify commercial loads, and significantly improve the rationality of aggregation through iterative optimization. Compared with the traditional K-means method, the internal consistency (silhouette coefficient) of its aggregation result has increased by 25%, laying a reliable data foundation for the subsequent implementation of grouped demand response.
[0141] In summary, the embodiments of this application use the clusters determined by coarse clustering as the initial categories for training the support vector data description model. By providing high-quality initial category classification to the support vector data description model through coarse clustering of samples, the support vector data description model can be trained quickly without changing the initial categories, thereby improving the training efficiency of the support vector data description model and solving the problem of low classification efficiency of existing support vector data description model algorithms.
[0142] Example 2
[0143] To address the problem of low load classification efficiency in existing support vector data description model algorithms, and based on the same inventive concept as Embodiment 1, this application also provides a load classification device based on coarse clustering and support vector data description.
[0144] A schematic diagram of the specific structure of the device is shown below. Figure 3 As shown, it includes the following functional units 31-32:
[0145] The data acquisition unit 31 is used to acquire time-series data of the load to be classified, and to form a feature vector of the load to be classified based on the time-series data; the time-series data includes multi-dimensional data characterizing the electricity consumption characteristics of the load.
[0146] The data acquisition unit is specifically used to: perform statistical analysis on the time-series data based on the time-series characteristics formed by the time-series data to determine the statistical characteristics, and calculate the electrical characteristics based on the time-series data to determine the characteristic vector of the load.
[0147] The load classification unit 32 is used to input the feature vector into the pre-trained support vector data description model to obtain the load type output by the support vector data description model; during training, the support vector data description model uses the clusters determined by coarse clustering of the load samples as the initial categories.
[0148] The load classification unit is specifically used to: calculate the relative distances between the feature vector and the centers of each category determined by the pre-trained support vector data description model; and output the load type of the load to be classified based on the relationship between the minimum value of each relative distance and a preset threshold.
[0149] Specifically, based on the relationship between the minimum value of the relative distance and a preset threshold, the load type of the load to be classified is output, including: if the minimum value is not greater than the preset threshold, then the load to be classified belongs to the category where the center of the sphere corresponding to the minimum value is located; if the minimum value is greater than the preset threshold, then the load to be classified does not belong to the existing category of the pre-trained support vector data description model.
[0150] If the minimum value is greater than the preset threshold, the load classification unit is further configured to:
[0151] The load to be classified is used as an initial category, and the support vector data description model is retrained.
[0152] The load classification device in this embodiment further includes a model training unit, which is specifically used to: train the support vector data description model, specifically including:
[0153] Obtain each initial cluster obtained by coarse clustering, and use each initial cluster as a training set;
[0154] In each iteration of training, for each training set, the following steps are performed: solve the preset objective function to determine a sphere; maximize the number of samples within the clusters that the sphere can enclose, and minimize the radius of the sphere as the optimization objective of the objective function;
[0155] For each sample in each training set, calculate the relative distance from that sample to each sphere center;
[0156] The category to which the center of the sphere corresponds to the minimum value among the relative distances is used as the category label of the sample, and the sample is classified into that category;
[0157] Determine the migration rate of each sample in this iteration; if the migration rate is less than the preset migration rate threshold or reaches the preset number of iterations, end the iteration and obtain the trained support vector data description model.
[0158] The coarse clustering determines the initial number of clusters based on the cluster profile coefficient; specifically, the number of clusters corresponding to the maximum average profile coefficient of the samples is used as the initial number of clusters.
[0159] In this embodiment, the clusters determined by coarse clustering are used as the initial categories for training the support vector data description model. By providing high-quality initial category classification to the support vector data description model through coarse clustering of samples, the support vector data description model can be trained quickly without changing the initial categories, thereby improving the training efficiency of the support vector data description model and solving the problem of low classification efficiency of existing support vector data description model algorithms.
[0160] Based on the same inventive concept as the foregoing embodiments of this application, this application also provides a computing device.
[0161] like Figure 4As shown, the computing device includes a memory 41 and a processor 42. The memory 41 can be configured to store various other data to support operation on the electronic device. Examples of such data include instructions for any application or method used to operate on the electronic device. The memory 41 can be implemented by any type of volatile or non-volatile storage device or a combination thereof, such as static random access memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic storage, flash memory, magnetic disk, or optical disk.
[0162] The processor 42, coupled to the memory 41, is used to execute the computer program stored in the memory 41 for performing a load classification method based on coarse clustering and support vector data description as described in the foregoing embodiments.
[0163] When the processor 42 executes the computer program to perform a load classification method based on coarse clustering and support vector data description, the clusters determined by coarse clustering are used as the initial categories for training the support vector data description model. By providing high-quality initial category partitioning to the support vector data description model through coarse clustering of samples, the support vector data description model can be trained quickly without changing the initial categories, thereby improving the training efficiency of the support vector data description model and solving the problem of low load classification efficiency in existing support vector data description model algorithms.
[0164] When the processor 42 executes the computer program in the memory 41, in addition to the functions described above, it can also perform other functions, as detailed in the descriptions of the preceding embodiments.
[0165] Furthermore, such as Figure 4 As shown, the computing device also includes other components such as a display 44, a communication component 43, a power supply component 45, and an audio component 46. Figure 4 The diagram only shows some components and does not mean that the computing device includes only these components. Figure 4 The components shown.
[0166] Accordingly, embodiments of this application also provide a computer-readable storage medium storing a computer program, which, when executed by a computer, can implement the methods provided in the above embodiments.
[0167] The device embodiments described above are merely illustrative. The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the modules can be selected to achieve the purpose of this embodiment according to actual needs. Those skilled in the art can understand and implement this without any creative effort.
[0168] Through the above description of the embodiments, those skilled in the art can clearly understand that each embodiment can be implemented by means of software plus necessary general-purpose hardware platforms, and of course, it can also be implemented by hardware. Based on this understanding, the above technical solutions, in essence or the part that contributes to the prior art, can be embodied in the form of a software product. This computer software product can be stored in a computer-readable storage medium, such as ROM / RAM, magnetic disk, optical disk, etc., and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute the methods described in various embodiments or some parts of the embodiments.
[0169] The specific embodiments described above further illustrate the purpose, technical solution, and beneficial effects of the present invention. It should be understood that the above description is only a specific embodiment of the present invention and is not intended to limit the scope of protection of the present invention. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of the present invention should be included within the scope of protection of the present invention.
Claims
1. A load classification method based on coarse clustering and support vector data description, characterized by, The method comprises: obtaining time series data of a load to be classified, and forming a feature vector of the load to be classified based on the time series data; the time series data comprises multidimensional data representing power consumption characteristics of the load; inputting the feature vector into a pre-trained support vector data description model to obtain a load type output by the support vector data description model; during training of the support vector data description model, a cluster determined by coarse clustering of load samples is used as an initial category.
2. The method of claim 1, wherein, The method further comprises inputting the feature vector into the pre-trained support vector data description model, so that the support vector data description model performs: calculating respective relative distances of the feature vector to respective ball centers of categories determined by the pre-trained support vector data description model; based on a size relationship between a minimum value in the respective relative distances and a preset threshold, outputting a load type of the load to be classified.
3. The method of claim 2, wherein, The outputting of the load type of the load to be classified based on the size relationship between the minimum value in the respective relative distances and the preset threshold comprises: if the minimum value is not greater than the preset threshold, the load to be classified belongs to a category in which the ball center corresponding to the minimum value is located; if the minimum value is greater than the preset threshold, the load to be classified does not belong to an existing category of the pre-trained support vector data description model.
4. The method of claim 3, wherein, If the minimum value is greater than the preset threshold, the method further comprises: retraining the support vector data description model by taking the load to be classified as an initial category.
5. The method of claim 1, wherein, The method further comprises training the support vector data description model, specifically comprising: obtaining respective initial cluster groups obtained by coarse clustering, and taking each initial cluster group as a training set; in each iteration training, for each training set, performing: solving a preset objective function to determine a ball; maximizing a number of samples in a cluster group wrapped by the ball and minimizing a ball radius as an optimization objective of the objective function; for each sample in each training set, calculating respective relative distances of the sample to respective ball centers; taking a category to which a ball center corresponding to a minimum value in the respective relative distances belongs as a category label of the sample, and dividing the sample into the category; determining a migration rate of each sample in the current iteration; if the migration rate is less than a preset migration rate threshold or a preset number of iterations is reached, ending the iteration to obtain a trained support vector data description model.
6. The method of claim 1, wherein, The coarse clustering determines an initial number of clusters based on a cluster silhouette coefficient; specifically, when an average silhouette coefficient of samples is maximum, a number of cluster groups corresponding to the maximum is taken as the initial number of clusters.
7. The method of claim 1, wherein, The feature vector comprises time series features formed based on the time series data, statistical features determined by statistical analysis of the time series data, and electrical features calculated based on the time series data.
8. A load classification apparatus based on coarse clustering and support vector data description, characterized by, The method comprises: a data acquisition unit configured to obtain time series data of a load to be classified, and form a feature vector of the load to be classified based on the time series data; the time series data comprises multidimensional data representing power consumption characteristics of the load; The load classification unit is configured to input the feature vector into a pre-trained support vector data description model to obtain a load type output by the support vector data description model; and the support vector data description model is configured to take a cluster determined by coarse clustering of load samples as an initial class during training.
9. An electronic device, comprising: The computer program product comprises: A processor, a memory, and a program or instructions stored on the memory and executable on the processor, the program or instructions being executed by the processor to implement the steps of the method of any one of claims 1-7.
10. A storage medium, characterized by The computer program product comprises: The storage medium stores a program or instructions, the program or instructions being executed by a processor to implement the steps of the method of any one of claims 1-7.