CN111914995A - Regularized linear regression generation method and device, electronic equipment and storage medium - Google Patents

Regularized linear regression generation method and device, electronic equipment and storage medium Download PDF

Info

Publication number
CN111914995A
CN111914995A CN202010561790.6A CN202010561790A CN111914995A CN 111914995 A CN111914995 A CN 111914995A CN 202010561790 A CN202010561790 A CN 202010561790A CN 111914995 A CN111914995 A CN 111914995A
Authority
CN
China
Prior art keywords
linear regression
regularized
regularized linear
search space
regression
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202010561790.6A
Other languages
Chinese (zh)
Inventor
希滕
张刚
温圣召
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing Baidu Netcom Science and Technology Co Ltd
Original Assignee
Beijing Baidu Netcom Science and Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Beijing Baidu Netcom Science and Technology Co Ltd filed Critical Beijing Baidu Netcom Science and Technology Co Ltd
Priority to CN202010561790.6A priority Critical patent/CN111914995A/en
Publication of CN111914995A publication Critical patent/CN111914995A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/04Architecture, e.g. interconnection topology
    • G06N3/045Combinations of networks
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/20Analysing
    • G06F18/24Classification techniques
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N20/00Machine learning
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/08Learning methods

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • Data Mining & Analysis (AREA)
  • Artificial Intelligence (AREA)
  • Software Systems (AREA)
  • Evolutionary Computation (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Life Sciences & Earth Sciences (AREA)
  • Mathematical Physics (AREA)
  • Computing Systems (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Health & Medical Sciences (AREA)
  • Biomedical Technology (AREA)
  • Biophysics (AREA)
  • Computational Linguistics (AREA)
  • General Health & Medical Sciences (AREA)
  • Molecular Biology (AREA)
  • Evolutionary Biology (AREA)
  • Bioinformatics & Computational Biology (AREA)
  • Bioinformatics & Cheminformatics (AREA)
  • Medical Informatics (AREA)
  • Data Exchanges In Wide-Area Networks (AREA)

Abstract

The application discloses a regularized linear regression generation method and device, electronic equipment and a storage medium, relates to the field of artificial intelligence technology and deep learning, and can be applied to image processing. The specific scheme is as follows: generating a linear regression search space, generating a regularized linear regression to be trained according to the linear regression search space, training the regularized linear regression to be trained, evaluating the performance, and performing iterative update on the regularized linear regression to be trained when the evaluation result does not meet the grading requirement until the evaluation result meets the grading requirement or the iterative update times of the regularized linear regression to be trained reach the preset iterative times. According to the method and the device, automatic generation of the regularized linear regression is achieved, automatic search is conducted in a linear regression search space to generate the regularized linear regression, regularization items of features in the regularized linear regression are independent, the obtained regularized linear regression has optimized regularization constraint, and the performance of a regularized linear regression model can be guaranteed.

Description

Regularized linear regression generation method and device, electronic equipment and storage medium
Technical Field
Embodiments of the present application relate generally to the field of computer technology, and more particularly, to the fields of artificial intelligence techniques and deep learning, applicable to image processing.
Background
Deep learning is a new field in machine learning research, and aims to establish a neural network simulating human brain for analysis learning. In recent years, deep learning techniques have been successful in many aspects of artificial intelligence technology research such as computer vision, speech recognition, and natural language processing.
In the deep learning technology, the quality of an Artificial Neural Network (ANN) structure has a very important influence on the effect of a final model. Manually designing a network topology requires a designer to have rich experience and need to try many times, explosive combinations are generated when the number of parameters is large, and the feasibility of a method for generating a network structure by using a conventional random Search algorithm is low, so that a Neural Architecture Search (NAS) technology gradually becomes a research hotspot in the field of deep learning.
Disclosure of Invention
The application provides a regularized linear regression generation method and device, electronic equipment and a storage medium.
According to a first aspect, there is provided a regularized linear regression generation method, comprising:
acquiring a training set and a verification set, and dividing the training set and the verification set into K training subsets and K verification subsets, wherein K is a positive integer;
generating a linear regression search space, and generating a regularized linear regression to be trained according to the linear regression search space;
training the regularized linear regression to be trained according to the K training subsets to generate K regularized linear regression models;
evaluating the K regularized linear regression models using the K validation subsets, respectively, to generate score values for the K regularized linear regression models; and
and carrying out N times of iterative updating on the regularized linear regression to be trained according to the score values of the K regularized linear regression models until the score values of the K regularized linear regression models meet the score requirement or N reaches the preset iteration times, wherein N is a positive integer.
According to a second aspect, there is provided a regularized linear regression generation apparatus, including:
the system comprises an acquisition module, a verification module and a verification module, wherein the acquisition module is used for acquiring a training set and a verification set and dividing the training set and the verification set into K training subsets and K verification subsets, and K is a positive integer;
the first generation module is used for generating a linear regression search space;
the second generation module is used for generating the regularized linear regression to be trained according to the linear regression search space;
the training module is used for training the regularized linear regression to be trained according to the K training subsets to generate K regularized linear regression models;
a validation module to evaluate the K regularized linear regression models using the K validation subsets, respectively, to generate score values for the K regularized linear regression models; and
and the updating module is used for carrying out N times of iterative updating on the regularized linear regression to be trained according to the score values of the K regularized linear regression models until the score values of the K regularized linear regression models meet the score requirement or N reaches the preset iteration times, wherein N is a positive integer.
According to a third aspect, there is provided an electronic device comprising:
at least one processor; and
a memory communicatively coupled to the at least one processor; wherein the content of the first and second substances,
the memory stores instructions executable by the at least one processor to enable the at least one processor to perform a regularized linear regression generation method as described in the first aspect.
According to a fourth aspect, there is provided a non-transitory computer readable storage medium having stored thereon computer instructions for causing the computer to perform the regularized linear regression generation method of the first aspect.
The regularized linear regression generation method, device, electronic equipment and storage medium provided by the application have the following beneficial effects:
by generating the linear regression search space and automatically searching in the linear regression search space to generate the regularized linear regression, the automatic generation of the regularized linear regression is realized, the regularization items of all dimensional features in the generated regularized linear regression are independent, and the same regularization item does not need to act on all parameters of the model, so that the obtained regularized linear regression has optimized regularization constraint, the performance of the regularized linear regression model can be ensured, and the robustness of the regularized linear regression model is improved.
It should be understood that the statements in this section do not necessarily identify key or critical features of the embodiments of the present disclosure, nor do they limit the scope of the present disclosure. Other features of the present disclosure will become apparent from the following description.
Drawings
The drawings are included to provide a better understanding of the present solution and are not intended to limit the present application. Wherein:
FIG. 1 is a schematic flow diagram of a regularized linear regression generation method according to a first embodiment of the present application;
FIG. 2 is a schematic flow diagram of a regularized linear regression generation method according to a second embodiment of the present application;
FIG. 3 is a schematic flow diagram of a regularized linear regression generation method according to a third embodiment of the present application;
FIG. 4 is a schematic flow diagram of a regularized linear regression generation method according to a fourth embodiment of the present application;
FIG. 5 is a schematic structural diagram of a regularized linear regression generation apparatus according to a fifth embodiment of the present application;
FIG. 6 is a schematic structural diagram of a regularized linear regression generation apparatus according to a sixth embodiment of the present application;
FIG. 7 is a schematic structural diagram of a regularized linear regression generation apparatus according to a seventh embodiment of the present application;
FIG. 8 is a schematic structural diagram of a regularized linear regression generation apparatus according to an eighth embodiment of the present application;
FIG. 9 is a block diagram of an electronic device for implementing a regularized linear regression generation method of an embodiment of the present application.
Detailed Description
The following description of the exemplary embodiments of the present application, taken in conjunction with the accompanying drawings, includes various details of the embodiments of the application for the understanding of the same, which are to be considered exemplary only. Accordingly, those of ordinary skill in the art will recognize that various changes and modifications of the embodiments described herein can be made without departing from the scope and spirit of the present application. Also, descriptions of well-known functions and constructions are omitted in the following description for clarity and conciseness.
The regularized linear regression generation method, apparatus, electronic device, and storage medium of the present application are described below with reference to the accompanying drawings.
In machine learning, variable selection is an important problem that multivariate linear regression cannot be avoided, and the quality of the step directly influences the model effect. Linear regression, as a statistical learning algorithm, also suffers from the problem of overfitting. To avoid overfitting, a regularized linear regression model can be used to prevent overfitting by adding a constraint term to the parameters (i.e., regularization term) after the cost function of the model.
Ridge regression and Least Absolute convergence and Selection Operator regression (LASSO) are the two most popular linear regression regularization methods at present. Wherein ridge regression is the sum of the absolute values of all the parameters; LASSO regression is the sum of the squares of all the parameters added. Ridge regression and LASSO regression are special biased estimation regression methods for collinear data analysis, and by abandoning unbiased property of least square method, partial information is lost, precision is reduced, and regression coefficients which are more practical and reliable are expected to be obtained.
It can be seen that in the prior art, regularization linear regression based on ridge regression and regularization linear regression based on LASSO regression have regularization terms that act on all parameters of the model, and thus severely limit the performance of the model.
In view of the above problems, the present application discloses a regularized linear regression generation method, which generates a regularized linear regression to be trained according to a linear regression search space by generating the linear regression search space, and then training the generated regularized linear regression to be trained by utilizing the obtained K training subsets to obtain K regularized linear regression models, and the performance evaluation is carried out on the K regularized linear regression models by respectively using the obtained K verification sets to obtain the scoring values of the K regularized linear regression models, when the score values of the K regularized linear regression models do not meet the scoring requirements and do not reach the preset iteration times, and carrying out iterative updating on the regularized linear regression to be trained until the score values of the K regularized linear regression models meet the scoring requirement or the iteration number N reaches the preset iteration number, thereby realizing the automatic generation of the regularized linear regression. According to the scheme, coefficients of all dimensional features in a linear regression search space are independent and irrelevant, different regularization terms can act on all the features respectively, and therefore the regularization linear regression is generated by automatically searching in the linear regression search space, so that in the generated regularization linear regression, the regularization terms of all the dimensional features are independent, the same regularization term does not need to act on all parameters of a model, the obtained regularization linear regression has optimized regularization constraints, the performance of the regularization linear regression model can be guaranteed, and the robustness of the regularization linear regression model is improved.
Fig. 1 is a flowchart illustrating a regularized linear regression generation method according to a first embodiment of the present application, where the method may be executed by the regularized linear regression generation apparatus provided in the present application, or may be executed by an electronic device provided in the present application, where the electronic device may include, but is not limited to, a terminal device such as a desktop computer, a tablet computer, and the like, or may be a server. The following is an example of a regularized linear regression generation method provided by the present application being executed by a regularized linear regression generation apparatus provided by the present application to explain the present application, and is not intended to limit the present application.
As shown in fig. 1, the regularized linear regression generation method may include the following steps:
step 101, a training set and a validation set are obtained, and the training set and the validation set are divided into K training subsets and K validation subsets, wherein K is a positive integer.
For different tasks, in the embodiment of the present application, training sets and validation sets may be obtained from different types of sample sets. The training set is used for model training, and the verification set is used for evaluating how the trained model performs, namely testing the performance of the trained model.
For example, for image processing tasks such as a classification task, a target detection task, a face detection task, and the like, a large number of image samples may be acquired from a public image dataset as a training set and a verification set, where the public image dataset may be, for example, an ImageNet dataset, a PASCAL VOC dataset, a Labelme dataset, and the like, and the acquired image samples in the verification set are different from the image samples in the training set, so as to ensure the performance and robustness of the regularized linear regression model obtained by training.
For another example, for a speech recognition task, a large number of speech samples may be acquired from an open-source speech data set as a training set and a verification set, where the open-source speech data set may be, for example, a chinese data set, an english data set, and the like, and the acquired speech data in the verification set is different from the speech data in the training set, so as to ensure performance and robustness of a normalized linear regression model obtained by training.
For example, taking the example of obtaining an image sample from the ImageNet data set as a training set and a validation set, a sample set including a large number of image samples may be obtained from the ImageNet data set, and then the sample set may be divided into the validation set and the training set according to a preset allocation ratio. For example, the preset allocation ratio of the training set to the verification set in the sample set is 8:2, that is, 80% of the image samples in the sample set are used as the training set, and the remaining 20% of the image samples in the sample set are used as the verification set, and then the obtained sample set is divided into the training set and the verification set according to the ratio of 8: 2.
In this embodiment, after the training set and the verification set are obtained, the training set and the verification set may be divided, the training set is divided into K training subsets, and the verification set is divided into K verification subsets, where K is a positive integer.
For example, when the training set and the verification set are divided, the training set may be randomly divided into K parts to obtain K training subsets, and the number of sample images included in each training subset may be the same or different; for the division of the verification set, the verification set may also be randomly divided into K parts to obtain K verification subsets, and the number of sample images included in each verification subset may be the same or different.
It should be noted that, in this embodiment, the number of the training subsets and the verification subsets obtained by division is the same, for example, the training set is divided into 5 training subsets, and similarly, the verification set is also divided into 5 verification subsets, each training subset corresponds to one verification subset, so that the performance of the regularized linear regression model obtained by training according to the training subsets is tested by using the verification subsets in the following.
In a possible implementation manner of the embodiment of the application, in order to obtain K training subsets and K verification subsets, an obtained sample set may be first divided into K parts to obtain K sample subsets, and then, for each verification subset, the sample subsets are divided into the training subsets and the verification subsets according to a preset distribution ratio (for example, 8: 2) of the training set and the verification set, and finally, K training subsets and K verification subsets are obtained, where each training subset corresponds to one verification subset.
And 102, generating a linear regression search space, and generating a regularized linear regression to be trained according to the linear regression search space.
In this embodiment, a design rule of the linear regression search space may be designed in advance, and then the linear regression search space is generated according to the design rule.
For example, the design rule of the linear regression search space may agree on the type of regularized linear regression, such as ridge regression, LASSO regression, etc., and agree in the linear regression search space, the ridge regression and the LASSO regression may respectively occur or may occur simultaneously, and the regularized linear regression in the agreed search space takes the feature as the minimum granularity, and the coefficients of the features in each dimension are independent.
According to the design rule, a linear regression search space meeting the conditions agreed by the design rule can be generated, the linear regression search space contains all the possibilities of the generated regularized linear regression, namely, the linear regression search space is a set of all the possible regularized linear regressions, the scheme of the application can find the regularized linear regression with better regularization constraint from all the possible regularized linear regressions by searching in the linear regression search space, and because the coefficients of all the dimensional features in the linear regression search space are independent, in the found regularized linear regression, the regularization term is independently acted on the feature parameters of the model, the same regularization term is not acted on all the parameters of the model, so that the condition that the performance of the model is limited due to the action of the regularization term on all the parameters of the model in the prior art can be avoided, and obtaining the optimized regular coefficient, and further obtaining the regularized linear regression with better performance.
In this embodiment, after the linear regression search space is generated, the regularized linear regression to be trained may be generated according to the linear regression search space. As mentioned above, the linear regression search space contains all the possibilities of the generated regularized linear regression, so that one regularized linear regression can be randomly generated from the search space and the randomly generated regularized linear regression can be used as the regularized linear regression to be trained.
In order to obtain a simple regularized linear regression whose performance meets the condition, when the regularized linear regression to be trained is generated according to the linear regression search space, a regularized linear regression including the least regularization terms may be randomly generated as the regularized linear regression to be trained, for example, in the regularized linear regression to be trained obtained for the first time, the regularization term only acts on one characteristic parameter of the model.
It should be noted that, the execution sequence of steps 101 to 102 is not sequential, and the two steps may be executed sequentially or simultaneously, and this application only uses the execution of step 102 after step 101 as an example to explain this application, and this application should not be taken as a limitation.
And 103, training the regularized linear regression to be trained according to the K training subsets to generate K regularized linear regression models.
In this embodiment, after the regularized linear regression to be trained is generated, the regularized linear regression to be trained may be trained according to the obtained K training subsets, so as to generate K regularized linear regression models.
When each training subset is used for training the regularized linear regression to be trained, sample data (such as image samples and voice data) contained in the training subsets are used as input of the regularized linear regression to be trained, a labeling result of the sample data is used as output of the regularized linear regression to be trained, parameters of the regularized linear regression to be trained are continuously updated in an iterative mode, finally, a group of model parameters which enable the value of the loss function to be the minimum on the training subsets are found, the training is finished, and the regularized linear regression model corresponding to the training subsets is obtained.
It can be understood that the K regularized linear regression models are obtained by respectively training the same model structure, namely the regularized linear regression to be trained, by using K different training subsets, and the K regularized linear regression models obtained by training are different in parameters due to the different training subsets.
In a possible implementation manner of the embodiment of the application, before the regularized linear regression to be trained is trained, the regularized linear regression to be trained may be initialized, for example, parameters of the regularized linear regression to be trained are initialized, and after the initialization is completed, the regularized linear regression to be trained is trained by using the K training subsets.
And step 104, evaluating the K regularized linear regression models respectively by using the K verification subsets to generate the score values of the K regularized linear regression models.
In this embodiment, after the K training subsets are used to train the regularized linear regression to be trained to obtain the corresponding K regularized linear regression models, for each regularized linear regression model, a verification subset corresponding to the training subset used when the regularized linear regression model is obtained through training may be used to perform performance test on the regularized linear regression model to generate a evaluation value of the regularized linear regression model, each regularized linear regression model is sequentially tested to finally obtain the score values of the K regularized linear regression models, and K score values are obtained in total.
And 105, performing N times of iterative updating on the regularized linear regression to be trained according to the score values of the K regularized linear regression models until the score values of the K regularized linear regression models meet the score requirement or N reaches the preset iteration times, wherein N is a positive integer.
The scoring requirement and the preset iteration number can be preset. For example, the scoring requirement may be set to have the minimum value of the K scoring values not less than 90%, or the scoring requirement may also be set to have the mean value of the K scoring values not less than 90%, and so on; the preset number of iterations may be set to 30, 40, etc., for example.
In this embodiment, after the score values of the K regularized linear regression models are obtained, whether iterative update is required to be performed on the regularized linear regression to be trained may be determined according to the obtained K score values, and when iterative update is required to be continued, iterative update is performed on the regularized linear regression to be trained.
In order to prevent infinite searching in the linear regression search space, a preset iteration number can be preset, and when the iteration update number of the regularized linear regression to be trained reaches the preset iteration number, even if the currently acquired score values of the K regularized linear regression models do not meet the scoring requirement, the regularized linear regression to be trained is not subjected to iteration update.
That is, in the present embodiment, after K score values of the regularized linear regression model are obtained, whether the obtained score values meet the scoring requirements can be judged firstly, for example, the scoring requirements are that the minimum value of the K score values is not less than 90%, when the minimum value of the K score values is less than 90%, the scoring requirements are judged not to be met, that is, the performance of the current regularized linear regression still does not meet the requirement, on the basis of the regularized linear regression to be trained which has been subjected to the iteration update for N times, and performing the (N + 1) th iterative update on the regularized linear regression to be trained after the N iterative updates, wherein at the moment, before iterative updating is carried out on the regularized linear regression to be trained, whether the current iteration number N reaches a preset iteration number is judged, and if N is smaller than the preset iteration number, iterative updating operation is carried out on the regularized linear regression to be trained.
Wherein N is a positive integer.
It should be noted that N is the number of times of iterative update of the regularized linear regression to be trained, for the regularized linear regression to be trained generated for the first time, after K training subsets are used for training to obtain K regularized linear regression models and K verification subsets are used for evaluation to obtain K score values, if the K score values do not meet the score requirement, the regularized linear regression to be trained needs to be updated for the first time, that is, N is equal to 1; if the regularized linear regression to be trained after the iterative update still does not meet the scoring requirement, the regularized linear regression to be trained after the iterative update needs to be iteratively updated again, wherein N is equal to 2, and so on, the iteration number N of the regularized linear regression to be trained when the regularized linear regression to be trained needs to be iteratively updated each time can be determined.
In this embodiment, the regularized linear regression to be trained is iteratively updated, which may be adjusting the type of the regularization term in the regularized linear regression to be trained, the coefficient value of the regularization term, the number of the feature parameters acted by the regularization term, and the like.
Further, the regularized linear regression to be trained after the iterative update is trained according to K training subsets to generate K regularized linear regression models, the K regularized linear regression models are evaluated by using K verification subsets to generate score values of the K regularized linear regression models, and the regularized linear regression to be trained after the iterative update is iteratively updated again according to the score values. That is to say, for the regularized linear regression to be trained after iterative update, the above steps 103 to 105 are repeatedly executed until the score values of the K regularized linear regression models meet the scoring requirement or the iterative update times N reach the preset iteration times, and then the search is finished to obtain the regularized linear regression to be finally generated.
The regularized linear regression generation method of the embodiment includes the steps of obtaining a training set and a validation set, dividing the training set and the validation set into K training subsets and K validation subsets, generating a linear regression search space, generating regularized linear regression to be trained according to the linear regression search space, training a regularized linear regression tree to be trained according to the K training subsets to generate K regularized linear regression models, evaluating the K regularized linear regression models by using the K validation subsets respectively to generate score values of the K regularized linear regression models, performing N-time iterative updating on the regularized linear regression to be trained according to the score values of the K regularized linear regression models until the score values of the K regularized linear regression models meet a score requirement or N reaches a preset number of iterations, and accordingly, automatic generation of regularized linear regression is achieved. And the coefficients of all the dimensional features in the linear regression search space are independent and irrelevant, so that the regularization linear regression is generated by automatically searching in the linear regression search space, the regularization items of all the dimensional features in the generated regularization linear regression are independent, and the same regularization item does not need to act on all parameters of the model, so that the obtained regularization linear regression has optimized regularization constraint, the performance of the regularization linear regression model can be ensured, and the robustness of the regularization linear regression model is improved.
In a possible implementation manner of the embodiment of the application, when the training set and the validation set are divided into K training subsets and K validation subsets, the training set and the validation set may be divided into K training subsets and K validation subsets by a K-fold cross division algorithm.
The K-fold cross division algorithm is to divide all data sets into K parts, one of the K parts is taken as a verification subset repeatedly every time, and the other K-1 parts are taken as training subsets to be used for training a model, so that K groups of combinations of the training subsets and the verification subsets are obtained.
For example, assuming that K is 5, in this embodiment, all data included in the training set and the verification set are randomly divided into K parts, each part of data is numbered as 1,2,3,4, and 5, and the combinations of the training subset and the verification subset obtained by the division are as follows:
(1)1,2,3,4 as a training subset and 5 as a verification subset;
(2)1,2,3,5 as a training subset and 4 as a verification subset;
(3)1,2,4,5 as a training subset and 3 as a verification subset;
(4)1,3,4,5 as a training subset and 2 as a verification subset;
(5)2,3,4,5 as training subset and 1 as verification subset.
It can be seen that after 5-fold cross-partition algorithm partition, 5 training subsets and 5 verification subsets corresponding to the training subsets are obtained.
The K-fold cross division algorithm randomly divides data into K parts, one part is selected as a verification subset without repeating every time, and the remaining K-1 parts are selected as verification subsets, so that the training set and the verification set are divided into K training subsets and K verification subsets according to the K-fold cross division algorithm, the randomness of the training subsets and the verification subsets is guaranteed, the accuracy of an evaluation result can be improved according to a regularized linear regression model obtained by training the training subsets and through the verification subset evaluation, and the performance and the robustness of the finally obtained regularized linear regression model are improved.
In order to more clearly describe a specific implementation process of generating the regularized linear regression to be trained according to the linear regression search space in the foregoing embodiment, the following description is made in detail with reference to fig. 2.
FIG. 2 is a schematic flow diagram of a regularized linear regression generation method according to a second embodiment of the present application. As shown in fig. 2, on the basis of the embodiment shown in fig. 1, in step 102, generating a regularized linear regression to be trained according to a linear regression search space may include the following steps:
step 201, generating a regularized linear regression sequence generator according to a linear regression search space.
Step 202, generating a regularized linear regression sequence according to the regularized linear regression sequence generator.
And step 203, generating the regularized linear regression to be trained according to the regularized linear regression sequence and the linear regression search space.
As mentioned above, the linear regression search space is generated according to the preset design rule, which defines all the possibilities, and is the set of all the possibilities. Therefore, in this embodiment, the regularized linear regression sequence generator may be initialized according to the linear regression search space to generate the regularized linear regression sequence generator.
The regularized linear regression sequence generator can be initialized randomly, each possibility in the linear regression search space corresponds to an initialization result, initialization is randomly performed according to the linear regression search space, and the regularized linear regression sequence generator can be obtained randomly.
The regularized linear regression sequence generator is capable of generating a regularized linear regression sequence, which is a model that uniquely corresponds to a likelihood with a set of sequences, i.e., the regularized linear regression sequence generator generates a uniquely corresponding regularized linear regression sequence.
The regularized linear regression sequence can represent regularization items selected during modeling of the regularized linear regression and characteristic parameters of functions of the regularized linear regression sequence, and the regularized linear regression to be trained can be generated according to the regularized linear regression sequence and the linear regression search space.
By way of example, assume that a regularized linear regression sequence generator can directly generate a sequence such as [13,22,56]]In the linear regression search space, 13 denotes the pair feature parameter θ1Acting on LASSO regression term (regularization)Coefficient of lambda1) And 22 denotes a pair of characteristic parameters theta2Action ridge regression term (regular coefficient is lambda)2) And 56 denotes a pair of characteristic parameters theta5Action ridge regression term (regular coefficient is lambda)3) Then, according to the regularized linear regression sequence and the linear regression search space, the feature parameter theta in the regularized linear regression to be trained generated according to the linear regression search space can be determined1Coefficient of action λ1For the characteristic parameter θ2Coefficient of action λ2Ridge regression term of (a) to the feature parameter θ5Coefficient of action λ3The ridge regression term of (1).
In order to optimize the regularized linear regression sequence generated by the regularized linear regression sequence generator, each possibility included in the linear regression search space may be encoded so as to express the regularized linear regression sequence, and after the regularized linear regression sequence generator generates the regularized linear regression sequence, the regularized linear regression sequence is decoded according to the linear regression search space to obtain the corresponding regularized linear regression to be trained. For example, for each possibility in the linear regression search space, encoding may be performed from 1, the regularized linear regression sequence generated by the regularized linear regression sequence generator is encoded data, for example, 1 is much simpler than data such as the sequence [13,22,56], and then the regularized linear regression sequence is decoded according to the encoding for each possibility in the linear regression search space, so as to obtain the regularized term corresponding to the regularized linear regression sequence and the feature parameters of the regularized term, and then the regularized linear regression to be trained is obtained by using the feature parameters. For example, if a code corresponding to one possible modeling [13,22,56] in the linear regression search space is 5, after the regularized linear regression sequence 5 is obtained, decoding is performed according to the linear regression search space, so that a modeling combination scheme [551,666,321,222] can be determined, and further, the regularized linear regression to be trained is generated according to regularization terms, regularization coefficients and action characteristic parameters corresponding to 13,22 and 56, respectively.
According to the regularized linear regression generation method, the regularized linear regression sequence generator is generated according to the linear regression search space, the regularized linear regression sequence is generated according to the regularized linear regression sequence generator, and the regularized linear regression to be trained is generated according to the regularized linear regression sequence and the linear regression search space, so that the regularized linear regression to be trained is automatically searched from the linear regression search space, and the randomness of the regularized linear regression to be trained is ensured.
FIG. 3 is a schematic flow diagram of a regularized linear regression generation method according to a third embodiment of the present application. Based on the embodiment shown in FIG. 2, step 105 may include the following steps as shown in FIG. 3
Step 301, obtaining K scoring values of K regularized linear regression models, respectively.
Step 302, generating an average score value according to the K score values of the K regularized linear regression models.
In this embodiment, for any one of the K regularized linear regression models, the verification subset corresponding to the training subset is used for evaluation, and the corresponding score value is obtained. For K regularized linear regression models, K scoring values can be obtained. Then, an average score value of the K score values may be calculated based on the K score values.
And 303, if the average score value is smaller than the scoring requirement and the current iteration number N is smaller than the preset iteration number, further updating the regularized linear regression sequence generator.
And 304, updating the regularized linear regression to be trained through the updated regularized linear regression sequence generator.
As an example, the scoring requirement may be a preset performance criteria threshold, such as setting the performance criteria threshold to 90%. In this example, when the average score value of the K score values is smaller than the preset performance standard threshold, it is determined that the average score value does not satisfy the scoring requirement, at this time, it is further determined whether the current iteration number N is smaller than the preset iteration number, and if the current iteration number N is smaller than the preset iteration number, the regularized linear regression sequence generator is further updated.
In the embodiment of the present application, the regularized linear regression sequence generator may be a neural network module, or may also be an evolutionary algorithm module. The regularized linear regression sequence generator may be updated in different ways for different modules.
As one possible implementation, when the regularized linear regression sequence generator is a neural network module, the regularized linear regression sequence generator may be updated by a back propagation algorithm.
As a possible implementation, when the regularized linear regression sequence generator is an evolutionary algorithm module, the regularized linear regression sequence generator may be updated by a population update algorithm.
In this embodiment, when the regularized linear regression sequence generator is a neural network module, the regularized linear regression sequence generator is updated through a back propagation algorithm, and when the regularized linear regression sequence generator is an evolutionary algorithm module, the regularized linear regression sequence generator is updated through a population update algorithm.
And then, after the regularized linear regression sequence generator is updated, the regularized linear regression to be trained can be updated through the updated regularized linear regression sequence generator. As described above, the regularized linear regression sequence generator generates a unique corresponding regularized linear regression sequence, and after the regularized linear regression sequence generator is updated, the regularized linear regression sequence generated according to the regularized linear regression sequence generator also changes, so that the regularized linear regression to be trained, which is generated according to the regularized linear regression sequence and the linear regression search space, is also updated accordingly.
The regularized linear regression generation method of this embodiment generates an average score value according to K score values of K regularized linear regression models by respectively obtaining the K score values of the K regularized linear regression models, and further updates the regularized linear regression sequence generator when the average score value is smaller than a score requirement and the current iteration number N is smaller than a preset iteration number, and further updates the regularized linear regression to be trained by the updated regularized linear regression sequence generator, thereby realizing that whether the regularized linear regression to be trained is updated according to the average score value of the regularized linear regression model on the premise that the iteration number does not reach the preset iteration number, realizing that the regularized linear regression model which does not meet the score requirement is iteratively updated to ensure that the regularized linear regression which meets the score requirement is obtained as much as possible, the method provides conditions for generating the regularized linear regression model with good performance and robustness.
In order to more clearly describe a specific implementation process of generating the linear regression search space in the foregoing embodiment, the following description is made in detail with reference to fig. 4.
Fig. 4 is a schematic flowchart of a regularized linear regression generation method according to a fourth embodiment of the present application, and as shown in fig. 4, on the basis of the embodiment shown in fig. 1, in step 102, a linear regression search space is generated, which may be implemented by the following steps:
step 401, a ridge regression term and/or a minimum absolute value convergence and selection operator LASSO regression term required by the linear regression search space is obtained.
In this embodiment, the ridge regression term or the LASSO regression term may be separately applied to the feature parameters of the regularized linear regression model, or the ridge regression term and the LASSO regression term may be applied to the feature parameters of the regularized linear regression model together, and the linear regression search space includes the above two cases to enrich the linear regression search space, so that the generated linear regression search space includes all possibilities.
Step 402, features are obtained as minimum granularity of ridge regression terms and LASSO regression terms required for a linear regression search space.
In this embodiment, when the linear regression search space is generated, both the ridge regression term and the LASSO regression term in the linear regression search space use the features as the minimum granularity, that is, both the ridge regression term and the LASSO regression term in the linear regression search space act on the feature parameters of the regularized linear regression model.
In step 403, the coefficients of each feature required by the linear regression search space are obtained, wherein the coefficients of the features of different dimensions are uncorrelated.
In this embodiment, when a linear regression search space is generated, for each feature parameter in a regularized linear regression model to be generated, a corresponding coefficient, that is, a regularization coefficient is preset, where coefficients of features of different dimensions are irrelevant, and regularization coefficients corresponding to different features may be the same or different. By setting the coefficients of different characteristics to be irrelevant, the same regularization item does not need to act on all characteristic parameters of the regularized linear regression model, so that the limitation on the performance of the model can be removed, the searched regularization coefficient is better, and the obtained regularized linear regression has good robustness.
Step 404, a linear regression search space is constructed according to the ridge regression term and/or the LASSO regression term, the features and the coefficient of each feature.
In this embodiment, after the ridge regression term and/or the LASSO regression term, the feature, and the coefficient of each feature are obtained, a linear regression search space may be constructed according to the ridge regression term and/or the LASSO regression term, the feature, and the coefficient of each feature, and the linear regression search space may generate any regularized linear regression that satisfies the above conditions. And constructing the generated linear regression search space, wherein the linear regression search space comprises all possibilities that the coefficients of the ridge regression term act on the features independently, all possibilities that the coefficients of the LASSO regression term act on the features independently, and all possibilities that the coefficients of the ridge regression term and the coefficients of the LASSO regression term act on different features together.
Wherein, the coefficients of the ridge regression term or the coefficients of the LASSO regression term act on all possibilities of the features separately, including all possibilities of one canonical coefficient (the coefficients of the ridge regression term or the coefficients of the LASSO regression term) acting on any one feature, all possibilities of one canonical coefficient acting on at least two different features, and all possibilities of at least two different canonical coefficients acting on at least two different features; the coefficients of the ridge regression term and the coefficients of the LASSO regression term jointly act on all possibilities of different features, including the fact that the coefficients of at least one ridge regression term act on at least one feature and the coefficients of at least one LASSO regression term act on all possibilities of at least one feature, in which case the coefficients of the ridge regression term and the coefficients of the LASSO regression term may be the same or different, and the sum of the number of features acted on by the coefficients of the ridge regression term and the number of features acted on by the LASSO regression term is not greater than the total number of features. Therefore, the generated linear regression search space contains all possibilities that the regularization terms act on the characteristic parameters, and the regularization terms do not need to act on all the characteristic parameters in the searched regularized linear regression because the linear regression search space contains the condition that a large number of regularization terms do not act on all the characteristic parameters, so that the limitation on the performance of the regularized linear regression model is avoided.
In the regularized linear regression generation method of the embodiment, a linear regression search space is constructed according to the ridge regression term and/or LASSO regression term required by the acquired linear regression search space, the features and the coefficient of each feature, so that a foundation is laid for generating the regularized linear regression through automatic search, and the regularized terms do not need to act on all the features in the linear regression search space by setting the coefficients of the features with different dimensions to be irrelevant, so that the limit on the performance of the regularized linear regression model is avoided, the optimized constraint regularization is favorably obtained, and the performance and the robustness of the regularized linear regression are improved. In addition, the early NAS does not limit the search space, even seven, eight and hundred graphics processors are required during searching, and a converged model can be obtained after training for one month, so that more hardware devices are required, and the search speed is slow; in the method, the linear regression search space is generated, the linear regression search space is searched to generate the regularized linear regression, variables of the optimization problem are defined in the linear regression search space, and the variable scale determines the difficulty and the search time of the search algorithm, so that the search is performed by defining the reasonable linear regression search space, the search speed and efficiency can be increased, the use of hardware equipment is reduced, and the hardware cost is saved.
The scheme provided by the application can be applied to image processing. For example, when the input of the regularized linear regression is the features extracted by the deep learning network, the scheme provided by the application can be applied to tasks such as a classification task, a target detection task, a face human key point detection task and the like in image processing. The regularized linear regression generated by the scheme provided by the application has better performance and robustness, so that when tasks such as a classification task, a target detection task, a face detection task and the like are completed by utilizing the regularized linear regression, the accuracy of task processing can be improved, the accuracy of classification can be improved for the classification task, and the accuracy of a target detection result can be improved for the target detection task.
According to an embodiment of the present application, the present application further provides a regularized linear regression generation apparatus.
Fig. 5 is a schematic structural diagram of a regularized linear regression generation apparatus according to a fifth embodiment of the present application. As shown in fig. 5, the regularized linear regression generating device 50 includes: an acquisition module 510, a first generation module 520, a second generation module 530, a training module 540, a verification module 550, and an update module 560.
The obtaining module 510 is configured to obtain a training set and a validation set, and divide the training set and the validation set into K training subsets and K validation subsets, where K is a positive integer.
In a possible implementation manner of the embodiment of the present application, the obtaining module 510 divides the training set and the verification set into K training subsets and K verification subsets by using a K-fold cross-partition algorithm.
A first generating module 520 for generating a linear regression search space.
And a second generating module 530, configured to generate a regularized linear regression to be trained according to the linear regression search space.
And a training module 540, configured to train the regularized linear regression to be trained according to the K training subsets to generate K regularized linear regression models.
A verification module 550, configured to evaluate the K regularized linear regression models using the K verification subsets, respectively, to generate score values of the K regularized linear regression models.
And the updating module 560 is configured to perform N iterative updates on the regularized linear regression to be trained according to the score values of the K regularized linear regression models until the score values of the K regularized linear regression models meet the score requirement or N reaches a preset iteration number, where N is a positive integer.
In a possible implementation manner of the embodiment of the present application, as shown in fig. 6, on the basis of the embodiment shown in fig. 5, the second generating module 530 includes:
a first generating unit 531, configured to generate a regularized linear regression sequence generator according to the linear regression search space;
a second generating unit 532, configured to generate a regularized linear regression sequence according to the regularized linear regression sequence generator; and
a third generating unit 533, configured to generate the regularized linear regression to be trained according to the regularized linear regression sequence and the linear regression search space.
In a possible implementation manner of the embodiment of the present application, as shown in fig. 7, on the basis of the embodiment shown in fig. 6, the updating module 560 includes:
a score value obtaining unit 561, configured to obtain K score values of the K regularized linear regression models, respectively;
a calculating unit 562, configured to generate an average score value according to the K score values of the K regularized linear regression models;
a first updating unit 563 configured to further update the regularized linear regression sequence generator if the average score value is smaller than the scoring requirement, or the current iteration number N is smaller than the preset iteration number;
in a possible implementation manner of the embodiment of the application, the regularized linear regression sequence generator is a neural network module or an evolutionary algorithm module, and the first updating unit 563 updates the regularized linear regression sequence generator by using a back propagation algorithm when the regularized linear regression sequence generator is the neural network module; and updating the regularized linear regression sequence generator through a population updating algorithm when the regularized linear regression sequence generator is the evolutionary algorithm module.
A second updating unit 564, configured to update the regularized linear regression to be trained through the regularized linear regression sequence generator after updating.
In a possible implementation manner of the embodiment of the present application, as shown in fig. 8, on the basis of the embodiment shown in fig. 5, the first generating module 520 includes:
a first obtaining unit 521, configured to obtain a ridge regression term and/or a minimum absolute value convergence and selection operator LASSO regression term required by the linear regression search space;
a second obtaining unit 522, configured to obtain features as minimum granularities of the ridge regression term and the LASSO regression term required for the linear regression search space;
a third obtaining unit 523, configured to obtain a coefficient of each feature required by the linear regression search space, where coefficients of features of different dimensions are not related; and
a construction unit 524, configured to construct the linear regression search space according to the ridge regression term and/or the LASSO regression term, and the features and the coefficient of each feature.
It should be noted that the foregoing explanation of the embodiment of the regularized linear regression generation method is also applicable to the regularized linear regression generation apparatus of the embodiment, and the implementation principle thereof is similar, and is not repeated here.
The regularized linear regression generation device of the embodiment of the application generates a regularized linear regression to be trained according to a linear regression search space by obtaining a training set and a validation set and dividing the training set and the validation set into K training subsets and K validation subsets and generating the linear regression to be trained according to the linear regression search space, then trains a regularized linear regression tree to be trained according to the K training subsets to generate K regularized linear regression models, evaluates the K regularized linear regression models by using the K validation subsets respectively to generate score values of the K regularized linear regression models, carries out N times of iterative updating on the regularized linear regression to be trained according to the score values of the K regularized linear regression models until the score values of the K regularized linear regression models meet the score requirements or N reaches a preset iteration number, thereby, automatic generation of regularized linear regression is achieved. And the coefficients of all the dimensional features in the linear regression search space are independent and irrelevant, so that the regularization linear regression is generated by automatically searching in the linear regression search space, the regularization items of all the dimensional features in the generated regularization linear regression are independent, and the same regularization item does not need to act on all parameters of the model, so that the obtained regularization linear regression has optimized regularization constraint, the performance of the regularization linear regression model can be ensured, and the robustness of the regularization linear regression model is improved.
According to an embodiment of the present application, an electronic device and a readable storage medium are also provided.
Fig. 9 is a block diagram of an electronic device for implementing the regularized linear regression generation method according to the embodiment of the present application. Electronic devices are intended to represent various forms of digital computers, such as laptops, desktops, workstations, personal digital assistants, servers, blade servers, mainframes, and other appropriate computers. The electronic device may also represent various forms of mobile devices, such as personal digital processing, cellular phones, smart phones, wearable devices, and other similar computing devices. The components shown herein, their connections and relationships, and their functions, are meant to be examples only, and are not meant to limit implementations of the present application that are described and/or claimed herein.
As shown in fig. 9, the electronic apparatus includes: one or more processors 701, a memory 702, and interfaces for connecting the various components, including a high-speed interface and a low-speed interface. The various components are interconnected using different buses and may be mounted on a common motherboard or in other manners as desired. The processor may process instructions for execution within the electronic device, including instructions stored in or on the memory to display graphical information of a GUI on an external input/output apparatus (such as a display device coupled to the interface). In other embodiments, multiple processors and/or multiple buses may be used, along with multiple memories and multiple memories, as desired. Also, multiple electronic devices may be connected, with each device providing portions of the necessary operations (e.g., as a server array, a group of blade servers, or a multi-processor system). In fig. 9, one processor 701 is taken as an example.
The memory 702 is a non-transitory computer readable storage medium as provided herein. Wherein the memory stores instructions executable by at least one processor to cause the at least one processor to perform the regularized linear regression generation method provided herein. The non-transitory computer readable storage medium of the present application stores computer instructions for causing a computer to perform the regularized linear regression generation method provided herein.
The memory 702, which is a non-transitory computer readable storage medium, may be used to store non-transitory software programs, non-transitory computer executable programs, and modules, such as program instructions/modules corresponding to the regularized linear regression generation method in the embodiments of the present application (e.g., the obtaining module 510, the first generation module 520, the second generation module 530, the training module 540, the verification module 550, and the update module 560 shown in fig. 5). The processor 701 executes various functional applications of the server and data processing by running non-transitory software programs, instructions, and modules stored in the memory 702, that is, implements the regularized linear regression generation method in the above method embodiments.
The memory 702 may include a storage program area and a storage data area, wherein the storage program area may store an operating system, an application program required for at least one function; the storage data area may store data created from use of an electronic device that performs a regularized linear regression generation method, and the like. Further, the memory 702 may include high speed random access memory, and may also include non-transitory memory, such as at least one magnetic disk storage device, flash memory device, or other non-transitory solid state storage device. In some embodiments, the memory 702 optionally includes memory located remotely from the processor 701, and such remote memory may be connected over a network to an electronic device that performs the regularized linear regression generation method. Examples of such networks include, but are not limited to, the internet, intranets, local area networks, mobile communication networks, and combinations thereof.
The electronic device executing the regularized linear regression generation method may further include: an input device 703 and an output device 704. The processor 701, the memory 702, the input device 703 and the output device 704 may be connected by a bus or other means, and fig. 9 illustrates an example of a connection by a bus.
The input device 703 may receive input numeric or character information and generate key signal inputs related to user settings and function control of an electronic device that performs the regularized linear regression generation method, such as a touch screen, a keypad, a mouse, a track pad, a touch pad, a pointer, one or more mouse buttons, a track ball, a joystick, or other input device. The output devices 704 may include a display device, auxiliary lighting devices (e.g., LEDs), and tactile feedback devices (e.g., vibrating motors), among others. The display device may include, but is not limited to, a Liquid Crystal Display (LCD), a Light Emitting Diode (LED) display, and a plasma display. In some implementations, the display device can be a touch screen.
Various implementations of the systems and techniques described here can be realized in digital electronic circuitry, integrated circuitry, application specific ASICs (application specific integrated circuits), computer hardware, firmware, software, and/or combinations thereof. These various embodiments may include: implemented in one or more computer programs that are executable and/or interpretable on a programmable system including at least one programmable processor, which may be special or general purpose, receiving data and instructions from, and transmitting data and instructions to, a storage system, at least one input device, and at least one output device.
These computer programs (also known as programs, software applications, or code) include machine instructions for a programmable processor, and may be implemented using high-level procedural and/or object-oriented programming languages, and/or assembly/machine languages. As used herein, the terms "machine-readable medium" and "computer-readable medium" refer to any computer program product, apparatus, and/or device (e.g., magnetic discs, optical disks, memory, Programmable Logic Devices (PLDs)) used to provide machine instructions and/or data to a programmable processor, including a machine-readable medium that receives machine instructions as a machine-readable signal. The term "machine-readable signal" refers to any signal used to provide machine instructions and/or data to a programmable processor.
To provide for interaction with a user, the systems and techniques described here can be implemented on a computer having: a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to a user; and a keyboard and a pointing device (e.g., a mouse or a trackball) by which a user can provide input to the computer. Other kinds of devices may also be used to provide for interaction with a user; for example, feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user may be received in any form, including acoustic, speech, or tactile input.
The systems and techniques described here can be implemented in a computing system that includes a back-end component (e.g., as a data server), or that includes a middleware component (e.g., an application server), or that includes a front-end component (e.g., a user computer having a graphical user interface or a web browser through which a user can interact with an implementation of the systems and techniques described here), or any combination of such back-end, middleware, or front-end components. The components of the system can be interconnected by any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include: local Area Networks (LANs), Wide Area Networks (WANs), and the Internet.
The computer system may include clients and servers. A client and server are generally remote from each other and typically interact through a communication network. The relationship of client and server arises by virtue of computer programs running on the respective computers and having a client-server relationship to each other.
According to the technical scheme of the embodiment of the application, by acquiring the training set and the verification set and dividing the training set and the verification set into K training subsets and K verification subsets, and generating a linear regression search space, generating a regularized linear regression to be trained according to the linear regression search space, and then, training the regularized linear regression tree to be trained according to the K training subsets to generate K regularized linear regression models, and evaluating the K regularized linear regression models using the K validation subsets, respectively, to generate score values for the K regularized linear regression models, and carrying out N times of iterative updating on the regularized linear regression to be trained according to the score values of the K regularized linear regression models until the score values of the K regularized linear regression models meet the scoring requirement or N reaches the preset iteration times, thereby realizing the automatic generation of the regularized linear regression. And the coefficients of all the dimensional features in the linear regression search space are independent and irrelevant, so that the regularization linear regression is generated by automatically searching in the linear regression search space, the regularization items of all the dimensional features in the generated regularization linear regression are independent, and the same regularization item does not need to act on all parameters of the model, so that the obtained regularization linear regression has optimized regularization constraint, the performance of the regularization linear regression model can be ensured, and the robustness of the regularization linear regression model is improved.
It should be understood that various forms of the flows shown above may be used, with steps reordered, added, or deleted. For example, the steps described in the present application may be executed in parallel, sequentially, or in different orders, and the present invention is not limited thereto as long as the desired results of the technical solutions disclosed in the present application can be achieved.
The above-described embodiments should not be construed as limiting the scope of the present application. It should be understood by those skilled in the art that various modifications, combinations, sub-combinations and substitutions may be made in accordance with design requirements and other factors. Any modification, equivalent replacement, and improvement made within the spirit and principle of the present application shall be included in the protection scope of the present application.

Claims (14)

1. A regularized linear regression generation method, comprising:
acquiring a training set and a verification set, and dividing the training set and the verification set into K training subsets and K verification subsets, wherein K is a positive integer;
generating a linear regression search space, and generating a regularized linear regression to be trained according to the linear regression search space;
training the regularized linear regression to be trained according to the K training subsets to generate K regularized linear regression models;
evaluating the K regularized linear regression models using the K validation subsets, respectively, to generate score values for the K regularized linear regression models; and
and carrying out N times of iterative updating on the regularized linear regression to be trained according to the score values of the K regularized linear regression models until the score values of the K regularized linear regression models meet the score requirement or N reaches the preset iteration times, wherein N is a positive integer.
2. The regularized linear regression generation method as claimed in claim 1, wherein said generating a regularized linear regression to be trained according to the linear regression search space comprises:
generating a regularized linear regression sequence generator according to the linear regression search space;
generating a regularized linear regression sequence according to the regularized linear regression sequence generator; and
and generating the regularized linear regression to be trained according to the regularized linear regression sequence and the linear regression search space.
3. The regularized linear regression generation method according to claim 2, wherein the iteratively updating the regularized linear regression to be trained for N times according to the score values of the K regularized linear regression models includes:
respectively obtaining K scoring values of the K regularized linear regression models;
generating average score values according to the K score values of the K regularized linear regression models;
if the average score value is smaller than the scoring requirement and the current iteration number N is smaller than the preset iteration number, further updating the regularized linear regression sequence generator; and
and updating the regularized linear regression to be trained through the updated regularized linear regression sequence generator.
4. The regularized linear regression generation method of claim 3, wherein the regularized linear regression sequence generator is a neural network module or an evolutionary algorithm module, wherein the further updating of the regularized linear regression sequence generator comprises:
updating the regularized linear regression sequence generator by a back propagation algorithm when the regularized linear regression sequence generator is the neural network module;
and when the regularized linear regression sequence generator is the evolutionary algorithm module, updating the regularized linear regression sequence generator through a population updating algorithm.
5. The regularized linear regression generation method of claim 1, wherein the generating a linear regression search space comprises:
acquiring a ridge regression term and/or a minimum absolute value convergence and selection operator LASSO regression term required by the linear regression search space;
obtaining features as minimum granularity of the ridge regression term and the LASSO regression term required for the linear regression search space;
obtaining coefficients of each feature required by the linear regression search space, wherein the coefficients of features of different dimensions are uncorrelated; and
constructing the linear regression search space according to the ridge regression term and/or the LASSO regression term, the features and the coefficient of each feature.
6. The regularized linear regression generation method of claim 1, wherein the dividing the training set and the validation set into K training subsets and K validation subsets comprises:
and dividing the training set and the verification set into K training subsets and K verification subsets by a K-fold cross division algorithm.
7. A regularized linear regression generation apparatus comprising:
the system comprises an acquisition module, a verification module and a verification module, wherein the acquisition module is used for acquiring a training set and a verification set and dividing the training set and the verification set into K training subsets and K verification subsets, and K is a positive integer;
the first generation module is used for generating a linear regression search space;
the second generation module is used for generating the regularized linear regression to be trained according to the linear regression search space;
the training module is used for training the regularized linear regression to be trained according to the K training subsets to generate K regularized linear regression models;
a validation module to evaluate the K regularized linear regression models using the K validation subsets, respectively, to generate score values for the K regularized linear regression models; and
and the updating module is used for carrying out N times of iterative updating on the regularized linear regression to be trained according to the score values of the K regularized linear regression models until the score values of the K regularized linear regression models meet the score requirement or N reaches the preset iteration times, wherein N is a positive integer.
8. The regularized linear regression generation apparatus as recited in claim 7, wherein the second generation module comprises:
a first generating unit, configured to generate a regularized linear regression sequence generator according to the linear regression search space;
a second generating unit, configured to generate a regularized linear regression sequence according to the regularized linear regression sequence generator; and
and the third generating unit is used for generating the regularized linear regression to be trained according to the regularized linear regression sequence and the linear regression search space.
9. The regularized linear regression generation apparatus as recited in claim 8, wherein the update module comprises:
a score value obtaining unit, configured to obtain K score values of the K regularized linear regression models, respectively;
the calculation unit is used for generating average score values according to the K score values of the K regularized linear regression models;
the first updating unit is used for further updating the regularized linear regression sequence generator if the average score value is smaller than the scoring requirement and the current iteration number N is smaller than the preset iteration number; and
and the second updating unit is used for updating the regularized linear regression to be trained through the regularized linear regression sequence generator after updating.
10. The regularized linear regression generation apparatus as claimed in claim 9, wherein the regularized linear regression sequence generator is a neural network module or an evolutionary algorithm module, and the first updating unit updates the regularized linear regression sequence generator by a back propagation algorithm when the regularized linear regression sequence generator is the neural network module; and updating the regularized linear regression sequence generator through a population updating algorithm when the regularized linear regression sequence generator is the evolutionary algorithm module.
11. The regularized linear regression generation apparatus as recited in claim 7, wherein the first generation module comprises:
a first obtaining unit, configured to obtain a ridge regression term and/or a minimum absolute value convergence and selection operator LASSO regression term required by the linear regression search space;
a second obtaining unit configured to obtain a feature as a minimum granularity of the ridge regression term and the LASSO regression term required for the linear regression search space;
a third obtaining unit, configured to obtain a coefficient of each feature required by the linear regression search space, where coefficients of features of different dimensions are uncorrelated; and
a construction unit, configured to construct the linear regression search space according to the ridge regression term and/or the LASSO regression term, and the features and the coefficient of each feature.
12. The regularized linear regression generation apparatus of claim 7, wherein the acquisition module divides the training set and the validation set into K training subsets and K validation subsets by a K-fold cross-partition algorithm.
13. An electronic device, comprising:
at least one processor; and
a memory communicatively coupled to the at least one processor; wherein the content of the first and second substances,
the memory stores instructions executable by the at least one processor to enable the at least one processor to perform the regularized linear regression generation method of any one of claims 1 to 6.
14. A non-transitory computer readable storage medium having stored thereon computer instructions for causing the computer to perform the regularized linear regression generation method of any one of claims 1 to 6.
CN202010561790.6A 2020-06-18 2020-06-18 Regularized linear regression generation method and device, electronic equipment and storage medium Pending CN111914995A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010561790.6A CN111914995A (en) 2020-06-18 2020-06-18 Regularized linear regression generation method and device, electronic equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010561790.6A CN111914995A (en) 2020-06-18 2020-06-18 Regularized linear regression generation method and device, electronic equipment and storage medium

Publications (1)

Publication Number Publication Date
CN111914995A true CN111914995A (en) 2020-11-10

Family

ID=73237925

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010561790.6A Pending CN111914995A (en) 2020-06-18 2020-06-18 Regularized linear regression generation method and device, electronic equipment and storage medium

Country Status (1)

Country Link
CN (1) CN111914995A (en)

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20160358104A1 (en) * 2015-06-02 2016-12-08 Nec Laboratories America, Inc. Annealed Sparsity Via Adaptive and Dynamic Shrinking
CN107220217A (en) * 2017-05-31 2017-09-29 北京京东尚科信息技术有限公司 Characteristic coefficient training method and device that logic-based is returned
EP3321831A1 (en) * 2016-11-14 2018-05-16 Carl Zeiss Vision International GmbH Device for determining predicted subjective refraction data or predicted subjective correction data and computer program
CN108877947A (en) * 2018-06-01 2018-11-23 重庆大学 Depth sample learning method based on iteration mean cluster
CN109214470A (en) * 2018-10-25 2019-01-15 中国人民解放军国防科技大学 Image visibility detection method based on coding network fine adjustment
CN110363810A (en) * 2019-06-14 2019-10-22 北京百度网讯科技有限公司 Establish the method, apparatus, equipment and computer storage medium of image detection model

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20160358104A1 (en) * 2015-06-02 2016-12-08 Nec Laboratories America, Inc. Annealed Sparsity Via Adaptive and Dynamic Shrinking
EP3321831A1 (en) * 2016-11-14 2018-05-16 Carl Zeiss Vision International GmbH Device for determining predicted subjective refraction data or predicted subjective correction data and computer program
CN107220217A (en) * 2017-05-31 2017-09-29 北京京东尚科信息技术有限公司 Characteristic coefficient training method and device that logic-based is returned
CN108877947A (en) * 2018-06-01 2018-11-23 重庆大学 Depth sample learning method based on iteration mean cluster
CN109214470A (en) * 2018-10-25 2019-01-15 中国人民解放军国防科技大学 Image visibility detection method based on coding network fine adjustment
CN110363810A (en) * 2019-06-14 2019-10-22 北京百度网讯科技有限公司 Establish the method, apparatus, equipment and computer storage medium of image detection model

Non-Patent Citations (3)

* Cited by examiner, † Cited by third party
Title
ZHOU, ZY 等: "Regularization incremental extreme learning machine with random reduced kernel for regression", NEUROCOMPUTING, 31 December 2018 (2018-12-31) *
朱劲夫;刘明哲;赵成强;苏世熙;: "正则化在逻辑回归与神经网络中的应用研究", 信息技术, no. 07, 25 July 2016 (2016-07-25) *
王定成;赵友志;陈北京;陆一;: "多输出数据依赖核支持向量回归快速学习算法", 计算机应用, no. 03, 10 March 2017 (2017-03-10) *

Similar Documents

Publication Publication Date Title
CN111950254B (en) Word feature extraction method, device and equipment for searching samples and storage medium
CN111639710A (en) Image recognition model training method, device, equipment and storage medium
KR102615957B1 (en) Point cloud data processing method, apparatus, electronic device and computer readable storage medium
CN111967256B (en) Event relation generation method and device, electronic equipment and storage medium
CN111737996B (en) Method, device, equipment and storage medium for obtaining word vector based on language model
CN111667057B (en) Method and apparatus for searching model structures
CN111667056B (en) Method and apparatus for searching model structures
CN111914994B (en) Generation method and device of multi-layer perceptron, electronic equipment and storage medium
CN111582479B (en) Distillation method and device for neural network model
CN111708876B (en) Method and device for generating information
CN111582454B (en) Method and device for generating neural network model
CN110795569B (en) Method, device and equipment for generating vector representation of knowledge graph
CN111859982B (en) Language model training method and device, electronic equipment and readable storage medium
CN111477251B (en) Model evaluation method and device and electronic equipment
CN111274407B (en) Method and device for calculating triplet confidence in knowledge graph
JP2021197159A (en) Method for pre-training graph neural network, program, and device
CN113723278B (en) Training method and device for form information extraction model
CN111967569A (en) Neural network structure generation method and device, storage medium and electronic equipment
CN110675954A (en) Information processing method and device, electronic equipment and storage medium
CN111639753A (en) Method, apparatus, device and storage medium for training a hyper-network
CN111738418A (en) Training method and device for hyper network
CN114492788A (en) Method and device for training deep learning model, electronic equipment and storage medium
CN112380104A (en) User attribute identification method and device, electronic equipment and storage medium
CN111914884A (en) Gradient descent tree generation method and device, electronic equipment and storage medium
CN111914880A (en) Decision tree generation method and device, electronic equipment and storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination