Scoring method and device of to-be-evaluated sample, storage medium and electronic device
Through data preprocessing and factor analysis of photovoltaic projects, key indicators are screened and sample scores are calculated, and the problem of difficult to define subjective and objective fuzzy indicators in photovoltaic project evaluation is solved, and a comprehensive and objective evaluation of photovoltaic projects is achieved.
Patent Information
- Application Number
- CN202411374744.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-09-29
- Publication Date
- 2025-01-14
AI Technical Summary
In the evaluation process of photovoltaic projects, subjective ambiguity and objective ambiguity indicators are difficult to classify and define, resulting in the inaccurate evaluation results.
By obtaining the first sample data of the photovoltaic project, performing data preprocessing and factor analysis, screening out the key second evaluation indicators, calculating sample scores, and using factor analysis method to extract the main factor as a comprehensive evaluation indicator.
While maintaining the original characteristics of the data, the main factors are extracted through factor analysis to achieve a comprehensive and objective evaluation of photovoltaic projects, and solve the problem of inaccurate evaluation results.
Smart Images

Figure CN119313186A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of computers, and more specifically, to a scoring method and device for evaluating samples, a storage medium, and an electronic device. Background Art
[0002] As an important component of renewable clean energy, photovoltaic power generation has made significant progress in technology maturity and commercial application in recent years, demonstrating extremely high cost-effectiveness and resource utilization efficiency. At present, photovoltaic projects have large investment scales and high technical requirements, and all aspects of the project, such as site selection, design, construction, and operation and maintenance, face complex and changing challenges. In the process of constructing a photovoltaic project evaluation model, it is necessary to accurately identify and comprehensively deal with the many factors that affect the success of the project to ensure the scientificity, accuracy, and feasibility of the evaluation model. Among these factors, there are some indicators that have both subjective ambiguity and objective ambiguity. Although these indicators are difficult to classify and define, they are crucial for project evaluation, which leads to inaccurate project evaluation results.
[0003] Regarding the relevant technologies, photovoltaic projects have indicators that are both subjectively ambiguous and objectively ambiguous, which are difficult to classify and define during the project evaluation process, resulting in inaccurate project evaluation results. No effective solution has been proposed so far.
[0004] Therefore, it is necessary to improve the related technology to overcome the above-mentioned defects in the related technology. Summary of the invention
[0005] The embodiments of the present application provide a scoring method and device, a storage medium and an electronic device for a sample to be evaluated, so as to at least solve the problem in the related art that photovoltaic projects have indicators with both subjective ambiguity and objective ambiguity, which are difficult to classify and define during the project evaluation process, resulting in inaccurate project evaluation results.
[0006] According to one aspect of an embodiment of the present application, a scoring method for samples to be evaluated is provided, including: obtaining first sample data of n samples to be evaluated according to m first evaluation indicators to obtain n first sample data, wherein m and n are both positive integers; performing data preprocessing on the n first sample data to obtain n second sample data; performing factor analysis on the m first evaluation indicators to screen out k second evaluation indicators from the m first evaluation indicators, wherein k is a positive integer; and calculating sample scores of the n samples to be evaluated according to the k second evaluation indicators and the n second sample data, respectively.
[0007] In an exemplary embodiment, data preprocessing is performed on the n first sample data to obtain n second sample data, including: performing positive processing on the n first sample data according to the m first evaluation indicators, converting the m first sub-sample data in each first sample data into extremely large indicators, and obtaining n third sample data; and standardizing the n third sample data according to the m first evaluation indicators to obtain the n second sample data.
[0008] In an exemplary embodiment, before performing data preprocessing on the n first sample data to obtain n second sample data, the method further includes: performing a KMO test on the n first sample data to obtain a first test result, wherein the KMO test is used to determine the degree of discreteness of the n first sample data; when the first test result is greater than a first preset threshold, performing a Bartlett sphericity test on the n first sample data to obtain a second test result, wherein the Bartlett sphericity test is used to determine the degree of correlation between the m first evaluation indicators; when the second test result is less than a second preset threshold, determining that the n first sample data meet a factor analysis standard, wherein the factor analysis standard is used to determine whether the m first evaluation indicators can be factor analyzed.
[0009] In an exemplary embodiment, factor analysis is performed on the m first evaluation indicators to select k second evaluation indicators from the m first evaluation indicators, including: generating a correlation coefficient matrix R=(r ij ) n×m , where r ij is the correlation coefficient between the ith first evaluation index and the jth evaluation index in the m first evaluation indexes, where j is a positive integer; the first characteristic roots of the m first evaluation indexes are calculated according to the correlation coefficient matrix to obtain m first characteristic roots; the m first characteristic roots and the m first evaluation indexes are sorted in descending order to obtain m second characteristic roots and m third evaluation indexes, and the formula Calculate the variance explanation rate α of the m third evaluation indicators in turn i , where α i is the variance explanation rate of the i-th third evaluation index among the m third evaluation indexes, λ i is the i-th second characteristic root among the m second characteristic roots, where i is a positive integer; and the k second evaluation indicators are selected from the m third evaluation indicators according to the second characteristic root and the variance explanation rate.
[0010] In an exemplary embodiment, before respectively calculating the sample scores of the n samples to be evaluated according to the k second evaluation indicators and the n second sample data, the method further includes: calculating the first eigenvectors of the m third evaluation indicators according to the correlation coefficient matrix to obtain m first eigenvectors; generating a first factor loading matrix according to the m first eigenvectors and the m second eigenroots Among them, β m is the mth first eigenvector; performing matrix extraction on the first factor loading matrix according to the k second evaluation indicators to obtain a second factor loading matrix, and rotating the second factor loading matrix through an orthogonal matrix to obtain a third factor loading matrix; constructing a factor model according to the m second sub-sample data in each second sample data and the third factor loading matrix The m second sub-sample data correspond to the m third evaluation indicators one by one, x i is the i-th second sub-sample data among the m second sub-sample data, b mk is the element located at the mth row and kth column in the third factor loading matrix.
[0011] In an exemplary embodiment, the sample scores of the n samples to be evaluated are calculated according to the k second evaluation indicators and the n second sample data, including: calculating the factor scores F of the k second evaluation indicators according to the factor model j =b j1 x 1 +...+b jm x m ,j=1,2,...,k, where F j is the factor score of the jth second evaluation indicator among the k second evaluation indicators; and the sample scores of the n samples to be evaluated are calculated according to the k factor scores and the variance explanation rates of the k second evaluation indicators. Wherein, F is the sample fraction, and α is the cumulative variance contribution rate of the k variance explanation rates.
[0012] According to another aspect of an embodiment of the present application, a scoring device for samples to be evaluated is also provided, including: an acquisition module, used to acquire first sample data of n samples to be evaluated according to m first evaluation indicators, to obtain n first sample data, wherein m and n are both positive integers; a preprocessing module, used to perform data preprocessing on the n first sample data, to obtain n second sample data; a factor analysis module, used to perform factor analysis on the m first evaluation indicators, to screen out k second evaluation indicators from the m first evaluation indicators, wherein k is a positive integer; and a scoring module, used to calculate the sample scores of the n samples to be evaluated according to the k second evaluation indicators and the n second sample data.
[0013] According to another aspect of the embodiments of the present application, a computer-readable storage medium is provided, in which a computer program is stored, wherein the computer program is configured to execute the above-mentioned scoring method for the sample to be evaluated when running.
[0014] According to another aspect of an embodiment of the present application, an electronic device is also provided, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the scoring method for the sample to be evaluated through the computer program.
[0015] According to another aspect of the embodiments of the present application, a computer program product is provided, including a computer program, and when the computer program is executed by a processor, the steps of the method described in each embodiment of the present application are implemented.
[0016] Through this application, each evaluation index of the photovoltaic project is first clarified, and then the first sample data of n photovoltaic projects (samples to be evaluated) are obtained according to these first evaluation indexes; the n first sample data are first preprocessed to obtain n second sample data; then the m first evaluation indexes are factor analyzed to screen out the key k second evaluation indexes from the m first evaluation indexes; finally, the sample scores of the n samples to be evaluated are respectively calculated according to the k second evaluation indexes and the n second sample data to complete the scoring of the samples to be evaluated; by adopting the above scheme, the main factors are extracted as new indicators for comprehensive evaluation by using the factor analysis method while maintaining the original characteristics of the data, so as to conduct a comprehensive and objective evaluation of the photovoltaic project; thus, the problem in the related technology that the photovoltaic project has both subjective ambiguity and objective ambiguity indicators, which is difficult to classify and define in the project evaluation process, resulting in inaccurate project evaluation results, is solved. BRIEF DESCRIPTION OF THE DRAWINGS
[0017] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present application and, together with the description, serve to explain the principles of the present application.
[0018] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, for ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative labor.
[0019] Figure 1 It is a hardware structure block diagram of a computer terminal of a scoring method for a sample to be evaluated according to an embodiment of the present application;
[0020] Figure 2 is a flow chart of a scoring method for a sample to be evaluated according to an embodiment of the present application;
[0021] Figure 3 It is a flow chart of an optional comprehensive evaluation method of photovoltaic projects based on factor analysis according to an embodiment of the present application;
[0022] Figure 4 It is a structural block diagram of a scoring device for a sample to be evaluated according to an embodiment of the present application. DETAILED DESCRIPTION
[0023] In order to enable those skilled in the art to better understand the present application, the technical solutions in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work should fall within the scope of protection of this application.
[0024] It should be noted that the terms "first", "second", etc. in the specification and claims of the present application and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the data used in this way can be interchangeable where appropriate, so that the embodiments of the present application described herein can be implemented in an order other than those illustrated or described herein. In addition, the terms "including" and "having" and any of their variations are intended to cover non-exclusive inclusions, for example, a process, method, system, product or device comprising a series of steps or units is not necessarily limited to those steps or units clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.
[0025] The method embodiments provided in the embodiments of the present application can be executed in a computer terminal or a similar computing device. Taking running on a computer terminal as an example, Figure 11 is a hardware structure block diagram of a computer terminal for a scoring method of a sample to be evaluated according to an embodiment of the present application. Figure 1 As shown, the computer terminal may include one or more ( Figure 1 Only one is shown in the figure) a processor 102 (the processor 102 may include but is not limited to a processing device such as a microprocessor (Central Processing Unit, MCU) or a programmable logic device (Field Programmable Gate Array, FPGA)) and a memory 104 for storing data, wherein the above-mentioned computer terminal may also include a transmission device 106 and an input and output device 108 for communication functions. It can be understood by those skilled in the art that Figure 1 The structure shown is only for illustration and does not limit the structure of the above-mentioned computer terminal. Figure 1 More or fewer components as shown, or with Figure 1 Different configurations shown.
[0026] The memory 104 can be used to store computer programs, for example, software programs and modules of application software, such as the computer program corresponding to the scoring method of the sample to be evaluated in the embodiment of the present application. The processor 102 executes various functional applications and data processing by running the computer program stored in the memory 104, that is, to implement the above method. The memory 104 may include a high-speed random access memory, and may also include a non-volatile memory, such as one or more magnetic storage devices, flash memory, or other non-volatile solid-state memory. In some examples, the memory 104 may further include a memory remotely arranged relative to the processor 102, and these remote memories can be connected to the computer terminal via a network. Examples of the above-mentioned network include, but are not limited to, the Internet, an intranet, a local area network, a mobile communication network, and combinations thereof.
[0027] A wireless network provided by a communication provider of a computer terminal. In one example, the transmission device 106 includes a network adapter (Network Interface Controller, referred to as NIC), which can be connected to other network devices through a base station so as to communicate with the Internet. In one example, the transmission device 106 can be a radio frequency (Radio Frequency, referred to as RF) module, which is used to communicate with the Internet wirelessly.
[0028] In this embodiment, a scoring method for a sample to be evaluated is provided. Figure 2 is a flow chart of a scoring method for a sample to be evaluated according to an embodiment of the present application, such as Figure 2 As shown, the process includes the following steps S202-S208:
[0029] Step S202: obtaining first sample data of n samples to be evaluated according to m first evaluation indicators to obtain n first sample data, where m and n are both positive integers;
[0030] Optionally, the m first evaluation indicators may include: payback period, internal rate of return, total investment rate of return, annual grid-connected power generation, equivalent full-load hours, total fossil energy savings, comprehensive benefits to the industry, meeting the growth and absorption of electricity demand, management system, risk resistance, technical equipment complexity and other indicators, and may also include other evaluation indicators, which are not restricted in this application.
[0031] Step S204: performing data preprocessing on the n first sample data to obtain n second sample data;
[0032] Step S206: performing factor analysis on the m first evaluation indicators, and selecting k second evaluation indicators from the m first evaluation indicators, where k is a positive integer;
[0033] Step S208: Calculate the sample scores of the n samples to be evaluated respectively according to the k second evaluation indicators and the n second sample data.
[0034] Through the above steps, the various evaluation indicators of the photovoltaic project are first clarified, and then the first sample data of n photovoltaic projects (samples to be evaluated) are obtained according to these first evaluation indicators; the n first sample data are first preprocessed to obtain n second sample data; then the m first evaluation indicators are factor analyzed to screen out the key k second evaluation indicators from the m first evaluation indicators; finally, the sample scores of the n samples to be evaluated are calculated according to the k second evaluation indicators and the n second sample data, and the scoring of the samples to be evaluated is completed; by adopting the above scheme, the main factors are extracted as new indicators for comprehensive evaluation by using the factor analysis method while maintaining the original characteristics of the data, so as to conduct a comprehensive and objective evaluation of the photovoltaic project; and thus the problem in the related technology that the indicators of the photovoltaic project have both subjective ambiguity and objective ambiguity, which are difficult to classify and define in the project evaluation process, resulting in inaccurate project evaluation results, is solved.
[0035] In an exemplary embodiment, data preprocessing is performed on the n first sample data to obtain n second sample data, including: performing positive processing on the n first sample data according to the m first evaluation indicators, converting the m first sub-sample data in each first sample data into extremely large indicators, and obtaining n third sample data; and standardizing the n third sample data according to the m first evaluation indicators to obtain the n second sample data.
[0036] The preprocessing of raw data includes two processes: forward processing and standardization. First, according to the formula The extremely small and extremely large indicators are processed positively, that is, all types of indicators are converted into extremely large indicators. In the formula, x represents the indicator to be processed, x max Represents the maximum value in the indicator data, x min Represents the minimum value in the indicator data. For standardization, Z-score standardization can be used to process the data: In the formula, is the average value, S td is the standard deviation.
[0037] Optionally, before performing data preprocessing on the n first sample data to obtain n second sample data, the method further includes: performing a KMO test on the n first sample data to obtain a first test result, wherein the KMO test is used to determine the degree of discreteness of the n first sample data; when the first test result is greater than a first preset threshold, performing a Bartlett's sphericity test on the n first sample data to obtain a second test result, wherein the Bartlett's sphericity test is used to determine the degree of correlation between the m first evaluation indicators; when the second test result is less than a second preset threshold, determining that the n first sample data meet a factor analysis standard, wherein the factor analysis standard is used to determine whether the m first evaluation indicators can be factor analyzed.
[0038] Before preprocessing the data, the original data needs to be tested to determine whether the original data is suitable for factor analysis. The KMO test can measure the degree of dispersion of the entire set of data, and its value is between 0 and 1. The larger the KMO value, the closer it is to 1, the stronger the correlation between the data; the smaller the KMO value, the closer it is to 0, the weaker the correlation between the data. Generally speaking, a KMO measurement value greater than 0.5 (i.e., the first preset threshold mentioned above) means that the data is suitable for factor analysis. Bartlett's sphericity test can test the degree of correlation between variables. When its significance is lower than 0.05 (i.e., the second preset threshold mentioned above), it means that the data meets the criteria for factor analysis.
[0039] It should be noted that the above-mentioned values are only used as examples and can be set to other values as required in actual applications. For example, the first preset threshold can also be set to 0.6, 0.7, etc., and this application does not impose any restrictions on this.
[0040] Optionally, factor analysis is performed on the m first evaluation indicators to select k second evaluation indicators from the m first evaluation indicators, including: generating a correlation coefficient matrix R=(r ij ) n×m, where r ij is the correlation coefficient between the ith first evaluation index and the jth evaluation index in the m first evaluation indexes, where j is a positive integer; the first characteristic roots of the m first evaluation indexes are calculated according to the correlation coefficient matrix to obtain m first characteristic roots; the m first characteristic roots and the m first evaluation indexes are sorted in descending order to obtain m second characteristic roots and m third evaluation indexes, and the formula Calculate the variance explanation rate α of the m third evaluation indicators in turn i , where α i is the variance explanation rate of the i-th third evaluation index among the m third evaluation indexes, λ i is the i-th second characteristic root among the m second characteristic roots, where i is a positive integer; and the k second evaluation indicators are selected from the m third evaluation indicators according to the second characteristic root and the variance explanation rate.
[0041] In the process of factor analysis, the correlation coefficient matrix R after the original data preprocessing is first calculated. ij ) n×m , where r ij is the correlation coefficient between the i-th indicator and the j-th indicator; calculate the characteristic root λ of the correlation coefficient matrix 1 ,λ 2 ,...,λ m (i.e., the m first characteristic roots); sort the factors according to the values of the characteristic roots, and calculate the factor variance explanation rate (i.e., the above variance explanation rate) α i . In the formula, λ i is the characteristic root, and m is the number of factors. The larger the variance explanation rate, the more information the factor contains. The number of main factors (i.e., the second evaluation index mentioned above) k is determined according to the value of the factor characteristic root and the value of the cumulative variance explanation rate. Generally, the factors with characteristic roots greater than 1 and cumulative variance contribution rates exceeding 80% are taken as the extracted common factors.
[0042] It should be noted that each factor (the third evaluation indicator) has a variance explanation rate. After sorting from large to small, the cumulative variance contribution rate is the sum of the first k variance explanation rates.
[0043] Optionally, before respectively calculating the sample scores of the n samples to be evaluated according to the k second evaluation indicators and the n second sample data, the method further includes: calculating the first eigenvectors of the m third evaluation indicators according to the correlation coefficient matrix to obtain m first eigenvectors; generating a first factor loading matrix according to the m first eigenvectors and the m second eigenroots Among them, β mis the mth first eigenvector; performing matrix extraction on the first factor loading matrix according to the k second evaluation indicators to obtain a second factor loading matrix, and rotating the second factor loading matrix through an orthogonal matrix to obtain a third factor loading matrix; constructing a factor model according to the m second sub-sample data in each second sample data and the third factor loading matrix The m second sub-sample data correspond to the m third evaluation indicators one by one, x i is the i-th second sub-sample data among the m second sub-sample data, b mk is the element located at the mth row and kth column in the third factor loading matrix.
[0044] On the other hand, it is also necessary to calculate the eigenvectors of the correlation coefficient matrix (i.e., the m first eigenvectors mentioned above) β 1 ,β 2 ,...,β m , where β j =(β 1j ,β 2j ,...,β nj ) T , and then use the m first eigenvectors and m second eigenroots to calculate the elementary loading matrix (i.e. the first factor loading matrix mentioned above) The factor loading matrix is extracted based on the k common factors (second evaluation indicators) to obtain the second factor loading matrix. At the same time, the extracted second factor loading matrix is rotated to obtain (in, is the extracted second factor loading matrix, T is an orthogonal matrix), and the third factor loading matrix B is obtained; the factor model is constructed using the m second sub-sample data of a single sample to be evaluated and the third factor loading matrix
[0045] Optionally, calculating the sample scores of the n samples to be evaluated respectively according to the k second evaluation indicators and the n second sample data includes: calculating the factor scores F of the k second evaluation indicators according to the factor model. j =b j1 x 1 +...+b jm x m ,j=1,2,...,k, where F j is the factor score of the jth second evaluation indicator among the k second evaluation indicators; and the sample scores of the n samples to be evaluated are calculated according to the k factor scores and the variance explanation rates of the k second evaluation indicators. Wherein, F is the sample fraction, and α is the cumulative variance contribution rate of the k variance explanation rates.
[0046] Finally, the factor score of each factor (the second evaluation indicator) is calculated according to the factor model; then the comprehensive factor score formula is used to calculate the comprehensive score of each sample (i.e., the sample score): Among them, α is the cumulative variance contribution rate of these k variance explanation rates.
[0047] Through the scoring method of the sample to be evaluated proposed in this application, the dimensionality reduction processing can be performed on many evaluation indicators in the photovoltaic project, and the redundant information between the variables can be removed, so as to extract the key factor (second evaluation indicator) that can represent the whole project as a new evaluation indicator. By extracting the key factors, the comprehensive performance of the photovoltaic project can be comprehensively and objectively reflected, providing strong decision-making support for project managers.
[0048] In an optional embodiment, the present application embodiment provides an optional photovoltaic project comprehensive evaluation method based on factor analysis, the process is as follows: Figure 3 As shown, the following steps are included:
[0049] Step 1: Build an indicator system:
[0050] An indicator system is constructed, including 11 indicators, namely: payback period, internal rate of return, total investment rate of return, annual grid-connected power generation, equivalent full-load hours, total fossil energy savings, comprehensive benefits to the industry, meeting the growth and absorption of electricity demand, management system, risk resistance, and complexity of technical equipment.
[0051] Step 2: Build the original data (i.e., the n first sample data mentioned above), where n is the number of samples to be evaluated, m is the number of evaluation indicators in the indicator system, and X ij (i=1,2,…,n;j=1,2,…,m) is the variable value of the jth evaluation index of the i-th sample to be evaluated.
[0052] Step 3: Check the original data:
[0053] First, the KMO test and Bartlett's sphericity test are used to determine whether the original data is suitable for factor analysis. The KMO test can measure the degree of dispersion of the entire set of data, and its value is between 0 and 1. The larger the KMO value, the closer it is to 1, the stronger the correlation between the data; the smaller the KMO value, the closer it is to 0, the weaker the correlation between the data. Generally speaking, a KMO value greater than 0.5 means that the data is suitable for factor analysis. Bartlett's sphericity test can test the degree of correlation between variables. When its significance is less than 0.05, it means that the data meets the criteria for factor analysis.
[0054] Step 4: Raw data preprocessing:
[0055] (1) Positive processing: According to the following formula, the extremely small indicators and extremely large indicators are positively processed, that is, all types of indicators are converted into extremely large indicators: In the formula, x represents the indicator to be processed, x max Represents the maximum value in the indicator data, x min Represents the minimum value in the indicator data
[0056] (2) Standardization: Standardize the data and use Z-score standardization to process the data. In the formula, is the average value, S t d is the standard deviation.
[0057] Step 5: Conduct factor analysis:
[0058] Calculate the correlation coefficient matrix R after raw data preprocessing = (r ij ) n×m , where r ij is the correlation coefficient between the i-th indicator and the j-th indicator. Calculate the characteristic root λ of the correlation coefficient matrix 1 ,λ 2 ,...,λ m and the eigenvector β 1, β 2 ,...,β m , where β j =(β 1j ,β 2j ,...,β nj ) T . Calculate the elementary load matrix
[0059] Sort the factors according to the values of the characteristic roots and calculate the factor variance explanation rate α i : In the formula, λ i is the characteristic root, and m is the number of factors. The larger the variance explanation rate, the more information the factor contains. The number of main factors k is determined according to the value of the factor characteristic root and the value of the cumulative variance explanation rate. Generally, the factors with characteristic roots greater than 1 and cumulative variance explanation rates exceeding 80% are taken as the extracted common factors.
[0060] The factor loading matrix is extracted based on the k common factors extracted, and the extracted factor loading matrix is rotated to obtain (in, is the extracted factor loading matrix, T is an orthogonal matrix), and the factor model is constructed as follows:
[0061]
[0062] Step 6: Calculate the comprehensive score:
[0063] Calculate factor scores based on the factor model: F j =b j1 x 1 +...+b jm x m ,j=1,2,...,k;
[0064] According to the comprehensive factor score formula, the comprehensive score of each sample (i.e., sample score) can be calculated: In the formula, α is the cumulative variance contribution rate.
[0065] Through the description of the above implementation methods, those skilled in the art can clearly understand that the method according to the above embodiment can be implemented by means of software plus a necessary general hardware platform, and of course by hardware, but in many cases the former is a better implementation method. Based on such an understanding, the technical solution of the present application, or the part that contributes to the prior art, can be embodied in the form of a software product, which is stored in a storage medium (such as ROM / RAM, magnetic disk, optical disk), and includes a number of instructions for a terminal device (which can be a mobile phone, computer, server, or network device, etc.) to execute the methods of each embodiment of the present application.
[0066] In this embodiment, a scoring device for samples to be evaluated is also provided, which is used to implement the above embodiments and preferred implementation modes, and will not be repeated hereafter. As used below, the term "module" can be a combination of software and / or hardware that implements a predetermined function. Although the devices described in the following embodiments are preferably implemented in software, the implementation of hardware, or a combination of software and hardware, is also possible and conceivable.
[0067] Figure 4 : is a structural block diagram of a scoring device for a sample to be evaluated according to an embodiment of the present application, the device comprising:
[0068] An acquisition module 42 is used to acquire first sample data of n samples to be evaluated according to m first evaluation indicators to obtain n first sample data, wherein m and n are both positive integers;
[0069] A preprocessing module 44 is used to perform data preprocessing on the n first sample data to obtain n second sample data;
[0070] A factor analysis module 46 is used to perform factor analysis on the m first evaluation indicators, and select k second evaluation indicators from the m first evaluation indicators, where k is a positive integer;
[0071] The scoring module 48 is used to calculate the sample scores of the n samples to be evaluated according to the k second evaluation indicators and the n second sample data.
[0072] Through the above-mentioned device, each evaluation index of the photovoltaic project is firstly clarified, and then the first sample data of n photovoltaic projects (samples to be evaluated) are obtained according to these first evaluation indexes; the n first sample data are firstly preprocessed to obtain n second sample data; then the m first evaluation indexes are factor analyzed, and the key k second evaluation indexes are screened out from the m first evaluation indexes; finally, the sample scores of the n samples to be evaluated are respectively calculated according to the k second evaluation indexes and the n second sample data, so as to complete the scoring of the samples to be evaluated; by adopting the above-mentioned scheme, the main factors are extracted as new indicators of comprehensive evaluation by using the factor analysis method while maintaining the original characteristics of the data, so as to conduct a comprehensive and objective evaluation of the photovoltaic project; thus, the problem in the related technology that the indicators of the photovoltaic project have both subjective ambiguity and objective ambiguity, which are difficult to be classified and defined in the project evaluation process, resulting in inaccurate project evaluation results, is solved.
[0073] Optionally, the preprocessing module 44 is also used to perform positive processing on the n first sample data according to the m first evaluation indicators, convert the m first sub-sample data in each first sample data into extremely large indicators, and obtain n third sample data; perform standardization processing on the n third sample data according to the m first evaluation indicators, and obtain the n second sample data.
[0074] The preprocessing of raw data includes two processes: forward processing and standardization. First, according to the formula The extremely small and extremely large indicators are processed positively, that is, all types of indicators are converted into extremely large indicators. In the formula, x represents the indicator to be processed, x max Represents the maximum value in the indicator data, x min Represents the minimum value in the indicator data. For standardization, Z-score standardization can be used to process the data: In the formula, is the average value, S t d is the standard deviation.
[0075] Optionally, the preprocessing module 44 is further used to perform a KMO test on the n first sample data to obtain a first test result, wherein the KMO test is used to determine the degree of discreteness of the n first sample data; when the first test result is greater than a first preset threshold, perform a Bartlett sphericity test on the n first sample data to obtain a second test result, wherein the Bartlett sphericity test is used to determine the degree of correlation between the m first evaluation indicators; when the second test result is less than a second preset threshold, determine that the n first sample data meet the factor analysis standard, wherein the factor analysis standard is used to determine whether the m first evaluation indicators can be factor analyzed.
[0076] Before preprocessing the data, the original data needs to be tested to determine whether the original data is suitable for factor analysis. The KMO test can measure the degree of dispersion of the entire set of data, and its value is between 0 and 1. The larger the KMO value, the closer it is to 1, the stronger the correlation between the data; the smaller the KMO value, the closer it is to 0, the weaker the correlation between the data. Generally speaking, a KMO measurement value greater than 0.5 (i.e., the first preset threshold mentioned above) means that the data is suitable for factor analysis. Bartlett's sphericity test can test the degree of correlation between variables. When its significance is lower than 0.05 (i.e., the second preset threshold mentioned above), it means that the data meets the criteria for factor analysis.
[0077] It should be noted that the above-mentioned values are only used as examples and can be set to other values as required in actual applications. For example, the first preset threshold can also be set to 0.6, 0.7, etc., and this application does not impose any restrictions on this.
[0078] Optionally, the factor analysis module 46 is further configured to generate a correlation coefficient matrix R=(r ij ) n×m , where r ij is the correlation coefficient between the ith first evaluation index and the jth evaluation index in the m first evaluation indexes, where j is a positive integer; the first characteristic roots of the m first evaluation indexes are calculated according to the correlation coefficient matrix to obtain m first characteristic roots; the m first characteristic roots and the m first evaluation indexes are sorted in descending order to obtain m second characteristic roots and m third evaluation indexes, and the formula Calculate the variance explanation rate α of the m third evaluation indicators in turn i , where α i is the variance explanation rate of the i-th third evaluation index among the m third evaluation indexes, λ iis the i-th second characteristic root among the m second characteristic roots, where i is a positive integer; and the k second evaluation indicators are selected from the m third evaluation indicators according to the second characteristic root and the variance explanation rate.
[0079] In the process of factor analysis, the correlation coefficient matrix R after the original data preprocessing is first calculated. ij ) n×m , where r ij is the correlation coefficient between the i-th indicator and the j-th indicator; calculate the characteristic root λ of the correlation coefficient matrix 1 ,λ 2 ,...,λ m (i.e., the m first characteristic roots); sort the factors according to the values of the characteristic roots, and calculate the factor variance explanation rate (i.e., the above variance explanation rate) α i . In the formula, λ i is the characteristic root, and m is the number of factors. The larger the variance explanation rate, the more information the factor contains. The number of main factors (i.e., the second evaluation index mentioned above) k is determined according to the value of the factor characteristic root and the value of the cumulative variance explanation rate. Generally, the factors with characteristic roots greater than 1 and cumulative variance contribution rates exceeding 80% are taken as the extracted common factors.
[0080] It should be noted that each factor (the third evaluation indicator) has a variance explanation rate. After sorting from large to small, the cumulative variance contribution rate is the sum of the first k variance explanation rates.
[0081] Optionally, the scoring module 48 is further configured to calculate the first eigenvectors of the m third evaluation indicators according to the correlation coefficient matrix to obtain m first eigenvectors; and generate a first factor loading matrix according to the m first eigenvectors and the m second eigenroots. Among them, β m is the mth first eigenvector; performing matrix extraction on the first factor loading matrix according to the k second evaluation indicators to obtain a second factor loading matrix, and rotating the second factor loading matrix through an orthogonal matrix to obtain a third factor loading matrix; constructing a factor model according to the m second sub-sample data in each second sample data and the third factor loading matrix The m second sub-sample data correspond to the m third evaluation indicators one by one, x i is the i-th second sub-sample data among the m second sub-sample data, b mk is the element located at the mth row and kth column in the third factor loading matrix.
[0082] On the other hand, it is also necessary to calculate the eigenvectors of the correlation coefficient matrix (i.e., the m first eigenvectors mentioned above) β 1,β 2 ,...,β m , where β j =(β 1j, β 2j ,...,β nj ) T , and then use the m first eigenvectors and m second eigenroots to calculate the elementary loading matrix (i.e. the first factor loading matrix mentioned above) The factor loading matrix is extracted based on the k common factors (second evaluation indicators) to obtain the second factor loading matrix. At the same time, the extracted second factor loading matrix is rotated to obtain (in, is the extracted second factor loading matrix, T is an orthogonal matrix), and the third factor loading matrix B is obtained; the factor model is constructed using the m second sub-sample data of a single sample to be evaluated and the third factor loading matrix
[0083] Optionally, the scoring module 48 is further configured to calculate the factor scores F of the k second evaluation indicators according to the factor model. j =b j1 x 1 +...+b jm x m ,j=1,2,...,k, where F j is the factor score of the jth second evaluation indicator among the k second evaluation indicators; and the sample scores of the n samples to be evaluated are calculated according to the k factor scores and the variance explanation rates of the k second evaluation indicators. Wherein, F is the sample fraction, and α is the cumulative variance contribution rate of the k variance explanation rates.
[0084] Finally, the factor score of each factor (the second evaluation indicator) is calculated according to the factor model; then the comprehensive factor score formula is used to calculate the comprehensive score of each sample (i.e., the sample score): Among them, α is the cumulative variance contribution rate of these k variance explanation rates.
[0085] An embodiment of the present application further provides a computer-readable storage medium, in which a computer program is stored, wherein the computer program is configured to execute the steps of any of the above method embodiments when running.
[0086] Optionally, in this embodiment, the storage medium may be configured to store a computer program for performing the following steps:
[0087] S1, obtaining first sample data of n samples to be evaluated according to m first evaluation indicators, to obtain n first sample data, wherein m and n are both positive integers;
[0088] S2, performing data preprocessing on the n first sample data to obtain n second sample data;
[0089] S3, performing factor analysis on the m first evaluation indicators, and selecting k second evaluation indicators from the m first evaluation indicators, where k is a positive integer;
[0090] S4, calculating sample scores of the n samples to be evaluated respectively according to the k second evaluation indicators and the n second sample data.
[0091] In an exemplary embodiment, the computer-readable storage medium may include, but is not limited to, various media that can store computer programs, such as a USB flash drive, a read-only memory (ROM), a random access memory (RAM), a mobile hard disk, a magnetic disk or an optical disk.
[0092] For specific examples in this embodiment, reference may be made to the examples described in the above embodiments and exemplary implementation modes, and this embodiment will not be described in detail herein.
[0093] An embodiment of the present application further provides an electronic device, including a memory and a processor, wherein a computer program is stored in the memory, and the processor is configured to run the computer program to execute the steps in any one of the above method embodiments.
[0094] Optionally, in this embodiment, the processor may be configured to perform the following steps through a computer program:
[0095] S1, obtaining first sample data of n samples to be evaluated according to m first evaluation indicators, to obtain n first sample data, wherein m and n are both positive integers;
[0096] S2, performing data preprocessing on the n first sample data to obtain n second sample data;
[0097] S3, performing factor analysis on the m first evaluation indicators, and selecting k second evaluation indicators from the m first evaluation indicators, where k is a positive integer;
[0098] S4, calculating sample scores of the n samples to be evaluated respectively according to the k second evaluation indicators and the n second sample data.
[0099] In an exemplary embodiment, the electronic device may further include a transmission device and an input / output device, wherein the transmission device is connected to the processor, and the input / output device is connected to the processor.
[0100] An embodiment of the present application further provides a computer program product, comprising a non-volatile computer-readable storage medium, wherein the non-volatile computer-readable storage medium stores a computer program product, and when the computer program is executed by a processor, the steps of the method described in each embodiment of the present application are implemented.
[0101] Optionally, in this embodiment, the above computer program may be configured to implement the following steps when executed by a processor:
[0102] S1, obtaining first sample data of n samples to be evaluated according to m first evaluation indicators, to obtain n first sample data, wherein m and n are both positive integers;
[0103] S2, performing data preprocessing on the n first sample data to obtain n second sample data;
[0104] S3, performing factor analysis on the m first evaluation indicators, and selecting k second evaluation indicators from the m first evaluation indicators, where k is a positive integer;
[0105] S4, calculating sample scores of the n samples to be evaluated respectively according to the k second evaluation indicators and the n second sample data.
[0106] For specific examples in this embodiment, reference may be made to the examples described in the above embodiments and exemplary implementation modes, and this embodiment will not be described in detail herein.
[0107] Obviously, those skilled in the art should understand that the above modules or steps of the present application can be implemented by a general computing device, they can be concentrated on a single computing device, or distributed on a network composed of multiple computing devices, they can be implemented by a program code executable by a computing device, so that they can be stored in a storage device and executed by the computing device, and in some cases, the steps shown or described can be executed in a different order from that herein, or they can be made into individual integrated circuit modules, or multiple modules or steps therein can be made into a single integrated circuit module for implementation. Thus, the present application is not limited to any specific combination of hardware and software.
[0108] The above is only a preferred implementation of the present application. It should be pointed out that for ordinary technicians in this technical field, several improvements and modifications can be made without departing from the principles of the present application. These improvements and modifications should also be regarded as the scope of protection of the present application.
Claims
1. A scoring method for samples to be evaluated, characterized in that: include: Obtain first sample data of n samples to be evaluated according to m first evaluation indicators to obtain n first sample data, where m and n are both positive integers; Performing data preprocessing on the n first sample data to obtain n second sample data; Performing factor analysis on the m first evaluation indicators, and selecting k second evaluation indicators from the m first evaluation indicators, where k is a positive integer; The sample scores of the n samples to be evaluated are respectively calculated according to the k second evaluation indicators and the n second sample data.
2. The method according to claim 1, characterized in that Performing data preprocessing on the n first sample data to obtain n second sample data includes: According to the m first evaluation indicators, the n first sample data are respectively forward processed, and the m first sub-sample data in each first sample data are converted into extremely large indicators to obtain n third sample data; The n third sample data are respectively standardized according to the m first evaluation indicators to obtain the n second sample data.
3. The method according to claim 2, characterized in that Before performing data preprocessing on the n first sample data to obtain n second sample data, the method further includes: Performing a KMO test on the n first sample data to obtain a first test result, wherein the KMO test is used to determine the degree of dispersion of the n first sample data; In the case where the first test result is greater than the first preset threshold, performing a Bartlett sphericity test on the n first sample data to obtain a second test result, wherein the Bartlett sphericity test is used to determine the degree of correlation between the m first evaluation indicators; When the second test result is less than a second preset threshold, it is determined that the n first sample data meet the factor analysis standard, wherein the factor analysis standard is used to determine whether the m first evaluation indicators can be subjected to factor analysis.
4. The method according to claim 1, characterized in that Performing factor analysis on the m first evaluation indicators, and selecting k second evaluation indicators from the m first evaluation indicators, including: Generate a correlation coefficient matrix R based on the m first evaluation indicators ij ) n×m , where r ij is the correlation coefficient between the ith first evaluation indicator and the jth evaluation indicator among the m first evaluation indicators, where j is a positive integer; Calculate the first characteristic roots of the m first evaluation indicators according to the correlation coefficient matrix to obtain m first characteristic roots; The m first characteristic roots and the m first evaluation indicators are sorted in descending order according to the m first characteristic roots to obtain m second characteristic roots and m third evaluation indicators, and the formula is used to calculate the m second characteristic roots and the m third evaluation indicators. Calculate the variance explanation rate α of the m third evaluation indicators in turn i , where α i is the variance explanation rate of the i-th third evaluation index among the m third evaluation indexes, λ i is the i-th second characteristic root among the m second characteristic roots, where i is a positive integer; The k second evaluation indicators are selected from the m third evaluation indicators according to the second characteristic root and the variance explanation rate.
5. The method according to claim 4, characterized in that Before respectively calculating the sample scores of the n samples to be evaluated according to the k second evaluation indicators and the n second sample data, the method further includes: Calculate the first eigenvectors of the m third evaluation indicators according to the correlation coefficient matrix to obtain m first eigenvectors; Generate a first factor loading matrix according to the m first eigenvectors and the m second eigenroots Among them, β m is the mth first eigenvector; Performing matrix extraction on the first factor loading matrix according to the k second evaluation indicators to obtain a second factor loading matrix, and rotating the second factor loading matrix through an orthogonal matrix to obtain a third factor loading matrix; A factor model is constructed based on the m second sub-sample data in each second sample data and the third factor loading matrix The m second sub-sample data correspond to the m third evaluation indicators one by one, x i is the i-th second sub-sample data among the m second sub-sample data, b mk is the element located at the mth row and kth column in the third factor loading matrix.
6. The method according to claim 5, characterized in that Calculating sample scores of the n samples to be evaluated respectively according to the k second evaluation indicators and the n second sample data, including: The factor scores F of the k second evaluation indicators are calculated according to the factor model. j =b j1 x1+...+b jm x m ,j=1,2,...,k, where F j is the factor score of the jth second evaluation indicator among the k second evaluation indicators; Calculate the sample scores of the n samples to be evaluated based on the k factor scores and the variance explanation rates of the k second evaluation indicators Wherein, F is the sample fraction, and α is the cumulative variance contribution rate of the k variance explanation rates.
7. A scoring device for samples to be evaluated, characterized in that: include: An acquisition module is used to acquire first sample data of n samples to be evaluated according to m first evaluation indicators to obtain n first sample data, wherein m and n are both positive integers; A preprocessing module, used for performing data preprocessing on the n first sample data to obtain n second sample data; A factor analysis module, used to perform factor analysis on the m first evaluation indicators, and select k second evaluation indicators from the m first evaluation indicators, where k is a positive integer; The scoring module is used to calculate the sample scores of the n samples to be evaluated according to the k second evaluation indicators and the n second sample data.
8. A computer-readable storage medium, characterized in that: The computer-readable storage medium includes a stored program, wherein the program executes the method according to any one of claims 1 to 6 when executed.
9. An electronic device comprising a memory and a processor, characterized in that: A computer program is stored in the memory, and the processor is configured to execute the method according to any one of claims 1 to 6 through the computer program.
10. A computer program product, comprising a computer program, characterized in that When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 6 are implemented.