CN109978140A - Neural network training method, device, readable storage medium storing program for executing and computer equipment - Google Patents

Neural network training method, device, readable storage medium storing program for executing and computer equipment Download PDF

Info

Publication number
CN109978140A
CN109978140A CN201910238685.6A CN201910238685A CN109978140A CN 109978140 A CN109978140 A CN 109978140A CN 201910238685 A CN201910238685 A CN 201910238685A CN 109978140 A CN109978140 A CN 109978140A
Authority
CN
China
Prior art keywords
network
model parameter
model
feature field
field
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.)
Granted
Application number
CN201910238685.6A
Other languages
Chinese (zh)
Other versions
CN109978140B (en
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.)
Tencent Technology Shenzhen Co Ltd
Original Assignee
Tencent Technology Shenzhen 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 Tencent Technology Shenzhen Co Ltd filed Critical Tencent Technology Shenzhen Co Ltd
Priority to CN201910238685.6A priority Critical patent/CN109978140B/en
Publication of CN109978140A publication Critical patent/CN109978140A/en
Application granted granted Critical
Publication of CN109978140B publication Critical patent/CN109978140B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

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
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/06Physical realisation, i.e. hardware implementation of neural networks, neurons or parts of neurons
    • G06N3/063Physical realisation, i.e. hardware implementation of neural networks, neurons or parts of neurons using electronic means
    • 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)
  • Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • Health & Medical Sciences (AREA)
  • Life Sciences & Earth Sciences (AREA)
  • Biomedical Technology (AREA)
  • Biophysics (AREA)
  • Evolutionary Computation (AREA)
  • Computational Linguistics (AREA)
  • Data Mining & Analysis (AREA)
  • Artificial Intelligence (AREA)
  • General Health & Medical Sciences (AREA)
  • Molecular Biology (AREA)
  • Computing Systems (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Mathematical Physics (AREA)
  • Software Systems (AREA)
  • Neurology (AREA)
  • Image Analysis (AREA)

Abstract

This application involves a kind of neural network training method, device, computer readable storage medium and computer equipments, this method comprises: obtaining nervus opticus network model, the first network layer of nervus opticus network model includes multiple feature fields, there are corresponding model parameter, model parameter is the input parameter for the second network layer connecting with first network layer in each feature field;Third network layer corresponding with first network layer is obtained from first nerves network model, first nerves network model has reached convergence;It obtains in third network layer with feature field identical in first network layer, obtains the corresponding model parameter in identical feature field and obtain reserving model parameter;Using reserving model parameter as the model parameter in the matched feature field of nervus opticus network model;Input training sample to nervus opticus network model is trained, until meeting the condition of convergence, obtains target nerve network model.Scheme provided by the present application can be improved the training effectiveness of neural network model.

Description

Neural network training method, device, readable storage medium storing program for executing and computer equipment
Technical field
It, can more particularly to a kind of neural network training method, device, computer this application involves field of computer technology Read storage medium and computer equipment.
Background technique
The data that the training of deep learning neural network model takes a long time in the prior art, model can just reach receipts It holds back, and if the feature of input sample changes, such as newly-increased feature or deletion feature, current deep learning neural network Model then needs all to abandon the full connection layer parameter for having had trained some time originally, causes deep learning neural network mould The type training time is long, the low problem of training effectiveness.
Summary of the invention
Based on this, it is necessary to which in view of the above technical problems, providing a kind of neural network training method, device, computer can The training of neural network model can be reduced when the feature of training sample changes by reading storage medium and computer equipment Time improves the training effectiveness of neural network model.
A kind of neural network training method, this method comprises:
Nervus opticus network model is obtained, the first network layer of nervus opticus network model includes multiple feature fields, respectively There are corresponding model parameter, model parameter is the input ginseng for the second network layer connecting with first network layer in a feature field Number;
Third network layer corresponding with first network layer is obtained from first nerves network model, first nerves network model is Reached convergence;
It obtains in third network layer with feature field identical in first network layer, it is corresponding to obtain identical feature field Model parameter obtains reserving model parameter;
Using reserving model parameter as the model parameter in the matched feature field of nervus opticus network model;
Input training sample to nervus opticus network model is trained, until meeting the condition of convergence, obtains target nerve Network model.
A kind of neural metwork training device, the device include:
Neural network model obtains module, for obtaining nervus opticus network model, the first of nervus opticus network model Network layer includes multiple feature fields, and each feature field there are corresponding model parameter, model parameter is and first network layer The input parameter of second network layer of connection;
Network layer obtains module, for obtaining third network corresponding with first network layer from first nerves network model Layer, first nerves network model have reached convergence;
Feature field obtains module and obtains for obtaining in third network layer with feature field identical in first network layer The corresponding model parameter in identical feature field is taken to obtain reserving model parameter;
Model parameter processing module, for using reserving model parameter as the matched feature field of nervus opticus network model Model parameter;
Nervus opticus network model training module is trained for inputting training sample to nervus opticus network model, Until meeting the condition of convergence, target nerve network model is obtained.
A kind of computer equipment can be run on a memory and on a processor including memory, processor and storage Computer program, the processor perform the steps of when executing program
Nervus opticus network model is obtained, the first network layer of nervus opticus network model includes multiple feature fields, respectively There are corresponding model parameter, model parameter is the input ginseng for the second network layer connecting with first network layer in a feature field Number;
Third network layer corresponding with first network layer is obtained from first nerves network model, first nerves network model is Reached convergence;
It obtains in third network layer with feature field identical in first network layer, it is corresponding to obtain identical feature field Model parameter obtains reserving model parameter;
Using reserving model parameter as the model parameter in the matched feature field of nervus opticus network model;
Input training sample to nervus opticus network model is trained, until meeting the condition of convergence, obtains target nerve Network model.
A kind of computer readable storage medium is stored thereon with computer program, when computer program is executed by processor, So that processor executes following steps:
Nervus opticus network model is obtained, the first network layer of nervus opticus network model includes multiple feature fields, respectively There are corresponding model parameter, model parameter is the input ginseng for the second network layer connecting with first network layer in a feature field Number;
Third network layer corresponding with first network layer is obtained from first nerves network model, first nerves network model is Reached convergence;
It obtains in third network layer with feature field identical in first network layer, it is corresponding to obtain identical feature field Model parameter obtains reserving model parameter;
Using reserving model parameter as the model parameter in the matched feature field of nervus opticus network model;
Input training sample to nervus opticus network model is trained, until meeting the condition of convergence, obtains target nerve Network model.
Above-mentioned neural network training method, device, computer readable storage medium and computer equipment obtain nervus opticus Network model, the first network layer of nervus opticus network model include multiple feature fields, and there are corresponding in each feature field Model parameter, model parameter are the input parameter for the second network layer connecting with first network layer;From first nerves network model Third network layer corresponding with first network layer is obtained, first nerves network model has reached convergence;Obtain third network layer In with feature field identical in first network layer, obtain the corresponding model parameter in identical feature field and obtain reserving model ginseng Number;Using reserving model parameter as the model parameter in the matched feature field of nervus opticus network model;Input training sample extremely Nervus opticus network model is trained, until meeting the condition of convergence, obtains target nerve network model.
It, then can basis when nervus opticus network model is changed compared to the training sample of first nerves network model Relationship between the feature field of nervus opticus network model and the feature field of first nerves network model, nervus opticus network The corresponding model parameter in feature field of model reservation part first nerves network model.Due to first nerves network model Convergence is reached, therefore nervus opticus network model remains the corresponding model in feature field of part first nerves network model Parameter can reduce the training time of neural network model, improve the training effectiveness of neural network model.
Detailed description of the invention
Fig. 1 is the applied environment figure of neural network training method in one embodiment;
Fig. 2 is the flow diagram of neural network training method in one embodiment;
Fig. 2A is the structural schematic diagram of nervus opticus network model in one embodiment;
Fig. 3 is the stream obtained in third network layer with identical feature field step in first network layer in one embodiment Journey schematic diagram;
Fig. 4 is in one embodiment using reserving model parameter as the mould in the matched feature field of nervus opticus network model The flow diagram of shape parameter step;
Fig. 5 is the flow diagram of the second relation table obtaining step in one embodiment;
Fig. 6 is the flow diagram of the first relation table obtaining step in one embodiment;
Fig. 7 is the flow diagram of neural network training method in another embodiment;
Fig. 8 is the flow diagram of neural network training method in another embodiment;
Fig. 8 A is that the relation table of the corresponding model parameter in each feature field shows in first network layer in one embodiment It is intended to;
Fig. 8 B is the knot of the corresponding model parameter mean allocation in each feature field in first network layer in one embodiment Structure schematic diagram;
Fig. 9 A is the interface schematic diagram that first nerves network model recommends information in one embodiment;
Fig. 9 B is the interface schematic diagram that nervus opticus network model recommends information in one embodiment;
Fig. 9 is the structural block diagram of neural metwork training device in one embodiment;
Figure 10 is the structural block diagram that feature field obtains module in one embodiment;
Figure 11 is the structural block diagram of model parameter processing module in one embodiment;
Figure 12 is the structural block diagram of neural metwork training device in another embodiment;
Figure 13 is the structural block diagram of computer equipment in one embodiment.
Specific embodiment
It is with reference to the accompanying drawings and embodiments, right in order to which the objects, technical solutions and advantages of the application are more clearly understood The application is further elaborated.It should be appreciated that specific embodiment described herein is only used to explain the application, and It is not used in restriction the application.
Fig. 1 is the applied environment figure of neural network training method in one embodiment.Referring to Fig.1, the neural metwork training Method is applied to neural metwork training system.The neural metwork training system includes terminal 110 and server 120.110 He of terminal Server 120 passes through network connection.Terminal 110 specifically can be terminal console or mobile terminal, and mobile terminal specifically can be with hand At least one of machine, tablet computer, laptop etc..Server 120 can use independent server either multiple clothes The server cluster of business device composition is realized.
Specifically, server 120 obtains nervus opticus network model, and the first network layer of nervus opticus network model includes Multiple feature fields, there are corresponding model parameter, model parameter is second connect with first network layer in each feature field The input parameter of network layer;Third network layer corresponding with first network layer, first nerves are obtained from first nerves network model Network model has reached convergence;It obtains in third network layer with feature field identical in first network layer, obtains identical The corresponding model parameter in feature field obtains reserving model parameter;It is matched reserving model parameter as nervus opticus network model Feature field model parameter;Input training sample to nervus opticus network model is trained, until meet the condition of convergence, Obtain target nerve network model.Further, obtained target nerve network model can be sent to terminal by server 120 110 use.
As shown in Fig. 2, in one embodiment, providing a kind of neural network training method.The present embodiment is mainly with this Method is applied to the server 120 in above-mentioned Fig. 1 to illustrate.Referring to Fig. 2, the neural network training method specifically include as Lower step:
Step 202, nervus opticus network model is obtained, the first network layer of nervus opticus network model includes multiple features Field, there are corresponding model parameter, model parameter is the second network layer connecting with first network layer in each feature field Input parameter.
Wherein, nervus opticus network model here is the neural network model for being trained, and can be depth mind Through network DNN, artificial neural network ANN etc., nervus opticus network model includes but is not limited to first network layer and the second network Layer, first network layer are connect with the second network layer, input layer of the output layer of first network layer as the second network layer.Wherein One network layer includes multiple first sub-networks, and the second network layer includes multiple second sub-networks.First network layer includes multiple spies Sign field, feature field refer to feature representative in a particular field, and the feature field of different field is different. Feature field can carry out what domain features extracted by the first network layer of nervus opticus network model, specifically can be Input sample is input to nervus opticus network model, nervus opticus network model carries out input sample by first network layer Domain features extract, and obtain the feature field of different field.Wherein, a input sample includes multiple fields information, can be passed through The first network layer of nervus opticus network model carries out feature extraction to the every field information in input sample, obtains corresponding Feature field.
Wherein, the first network layer of nervus opticus network model includes multiple feature fields, each feature field presence pair The model parameter answered, model parameter refer to each in each sub-network structure in the first network layer of nervus opticus network model Parameter.Wherein, model parameter can voluntarily be learnt by the input sample of nervus opticus network model, can be according to feature field Change and changes.Once the feature field of nervus opticus network model is changed, changed feature field is corresponding Model parameter is also with changing.Wherein, the input layer due to the output layer of first network layer as the second network layer, The corresponding model parameter in each feature field is and the second network layer input parameter.
In one embodiment, as shown in Figure 2 A, the structure that Fig. 2A shows one embodiment nervus opticus network model is shown It is intended to.The nervus opticus network model that Fig. 2A shows is that deep learning neural network model DNN, DNN include vector layer and full connection Layer, wherein vector layer is first network layer, and full articulamentum is the second network layer.The deep learning neural network model of Fig. 2A it is defeated Enter sample and includes three fields, respectively field 1, field 2 and field 3, and vector layer includes primary vector sub-network With secondary vector sub-network, primary vector sub-network is the input network of vector layer, to field 1, field 2 and field 3 Domain features carry out preliminary judgement, if being indicated with 1 occurs in feature, being indicated with 0 does not occur in feature, then passes through primary vector again Weight between sub-network and secondary vector sub-network calculates separately to obtain field 1, field 2 and the corresponding spy of field 3 Sign field, such as 1 corresponding V0 and V1 of field, 3 corresponding V0 and V1 of field 2 corresponding V0 and V1, field.Secondary vector Output layer of the sub-network as vector layer exports each feature field.And secondary vector sub-network is as full articulamentum simultaneously Input layer, therefore each feature field is the input data of full articulamentum.Wherein full articulamentum is in addition to including secondary vector subnet Network further includes that the first full connection sub-network, the second full connection sub-network and third connect sub-network entirely.Wherein, in Fig. 2A Two to each line between the full connection sub-network of quantum network and first be the corresponding model parameter in each feature field.
Step 204, third network layer corresponding with first network layer, first nerves net are obtained from first nerves network model Network model has reached convergence.
Wherein, first nerves network model here is to have reached convergent neural network model, first nerves network Model can be identical with the network structure of nervus opticus network model, but first nerves network model be have reached it is convergent, And nervus opticus network model is not trained.There is first with nervus opticus network model in first nerves network model The corresponding third network layer of network layer, and there is the 4th network layer corresponding with the second network layer of nervus opticus network model. Wherein, the third network layer of first nerves network model is compared in the feature field of the first network layer of nervus opticus network model Feature field be it is changed, can be and increase feature field, or delete feature field etc..
In one embodiment, first nerves network model includes third network layer and the 4th network layer, first nerves net Network model and nervus opticus network model can be identical network structure, the third network layer of first nerves network model and The first network layer of two neural network models is corresponding, the 4th network layer and nervus opticus network mould of first nerves network model Second network layer of type is corresponding.
Step 206, it obtains in third network layer with feature field identical in first network layer, obtains identical feature neck The corresponding model parameter in domain obtains reserving model parameter.
Wherein, since first nerves network has third network corresponding with the first network layer of nervus opticus network model Layer, therefore the third network layer of first nerves network includes multiple feature fields, all there is corresponding model in each feature field Parameter.According to each feature field in each feature field of first network layer and third network layer, identical feature neck is obtained Domain.Since each feature field all has corresponding model parameter, first nerves net is obtained according to identical feature field The corresponding model parameter of network model, the model parameter that will acquire is as reserving model parameter, i.e. acquisition first nerves network mould The corresponding model parameter in identical feature field in type, the model parameter that will acquire is as reserving model parameter.Wherein, first The feature field of neural network model and nervus opticus network model can be identical, but identical feature field is in different minds It is different through network model.
Specifically, it obtains in third network layer with feature field identical in first network layer, specifically can be acquisition the Each feature field of one network layer and each feature field of third network layer, obtain identical feature field by comparing, Identical feature field corresponding model parameter in first nerves network model is further obtained again, the model ginseng that will acquire Number is used as reserving model parameter.
Step 208, using reserving model parameter as the model parameter in the matched feature field of nervus opticus network model.
Specifically, after obtaining reserving model parameter, using the reserving model parameter of first nerves network model as second The model parameter in the matched feature field of neural network model.It specifically can be, first according to reserving model parameter in first nerves The corresponding feature field of network model, reserving model parameter are the first nets in the corresponding feature field of first nerves network model The same characteristic features field of network layers and third network layer.Identical feature field is obtained again in the corresponding mould of nervus opticus network model Shape parameter matrix finally fills the matrix value of reserving model parameter into corresponding model parameter matrix.
Step 210, input training sample to nervus opticus network model is trained, until meeting the condition of convergence, is obtained Target nerve network model.
Wherein, using reserving model parameter as the model parameter in the matched feature field of nervus opticus network model after, And the model parameter in the not matched feature field of nervus opticus network model carries out random initial assignment, obtains initial nervus opticus Network model.Further, model training is carried out to initial nervus opticus network model.It specifically can be, training sample made For the input data of initial nervus opticus network model, nervus opticus network model constantly voluntarily learns according to training sample, adjusts The corresponding model parameter in feature field of whole random initial assignment obtains target nerve network model until meeting the condition of convergence. Wherein, in the training process of initial nervus opticus network model, initial nervus opticus network model is only adjusted in learning process The corresponding model parameter in feature field of whole random initial assignment, and for the matched feature field of first nerves network model Model parameter without adjustment, be fixed.To reduce the training time of nervus opticus network model, so that second Neural network reaches the condition of convergence as early as possible.
Above-mentioned neural network training method obtains nervus opticus network model, the first network of nervus opticus network model Layer includes multiple feature fields, and there are corresponding model parameter, model parameter is to connect with first network layer in each feature field The second network layer input parameter;Third network layer corresponding with first network layer is obtained from first nerves network model, the One neural network model has reached convergence;It obtains in third network layer with feature field identical in first network layer, obtains The corresponding model parameter in identical feature field obtains reserving model parameter;Using reserving model parameter as nervus opticus network mould The model parameter in the matched feature field of type;Input training sample to nervus opticus network model is trained, and is received until meeting Condition is held back, target nerve network model is obtained.
It, then can basis when nervus opticus network model is changed compared to the training sample of first nerves network model Relationship between the feature field of nervus opticus network model and the feature field of first nerves network model, nervus opticus network The corresponding model parameter in feature field of model reservation part first nerves network model.Due to first nerves network model Convergence is reached, therefore nervus opticus network model remains the corresponding model in feature field of part first nerves network model Parameter can reduce the training time of neural network model, improve the training effectiveness of neural network model.
In one embodiment, it is led as shown in figure 3, obtaining in third network layer with feature identical in first network layer Domain, comprising:
Step 302, each feature field in third network layer is obtained.
Step 304, each feature field in first network layer is obtained.
Step 306, each feature field in third network layer and each feature field in first network layer are carried out Compare, obtains identical feature field.
Specifically, since the first network layer of nervus opticus network model includes multiple feature fields, similarly first is refreshing Third network layer through network model also includes multiple feature fields, obtains each feature field of first network layer and obtains the Each feature field of two network layers.Further, each feature field and the first network layer of third network layer be will acquire In each feature field be compared, to obtain identical feature field.For example, obtaining the feature field of third network layer For gender, age, user id, the feature field of first network layer is age, user id, article id and article theme.Pass through The feature field of three network layers and the feature field of first network layer are compared, and obtaining identical feature field is age and user id。
In one embodiment, as shown in figure 4, using reserving model parameter as the matched feature of nervus opticus network model The model parameter in field, comprising:
Step 402, obtain first network layer in each feature field and corresponding model parameter the first relation table, first Relation table includes corresponding first field designation in each feature field and the first field designation corresponding first in first network layer Model parameter matrix, the first model parameter matrix include multiple first model parameter submatrixs.
Wherein, the first relation table is each feature field and corresponding in the first network layer by nervus opticus network model The mapping table of model parameter composition, can be one-to-many relationship, such as a feature field corresponds to multiple model parameters. Wherein, in the first relation table, each feature field of first network layer uses corresponding feature field designation, i.e. the first relationship Table includes corresponding first field designation in each feature field of first network layer and the corresponding first model ginseng of the first field designation Matrix number.Here the first field designation is for each feature field of unique identification first network layer.
Specifically, corresponding first field designation is distributed to each feature field of first network layer in advance, further according to each The relationship in a feature field and corresponding first model parameter matrix forms the first field designation and corresponding first model parameter The relationship of matrix finally obtains the first relation table.Wherein, a feature field can correspond to multiple sub- squares of first model parameter Battle array, the number of the first model parameter submatrix specifically can be true according to the vector dimension in the feature field of nervus opticus network model It is fixed.Finally, storing the first obtained relation table into server.
For example, each feature field of first network layer is age, gender, user id, in advance to each of first network layer Corresponding fisrt feature field designation is distributed in a feature field, such as age, gender, the corresponding fisrt feature field designation of user id Respectively 0,1,2.And there are corresponding first model parameter submatrixs in each feature field, such as age corresponding 2 the first models Parameter submatrix, respectively W1-11 and W1-12, therefore age corresponding first field designation 0 is established in the first relation table, Relationship between age corresponding first model parameter submatrix W1-11 and W1-12.
Step 404, obtain third network layer in each feature field and corresponding model parameter the second relation table, second Relation table includes corresponding second field designation in each feature field and the second field designation corresponding second in third network layer Model parameter matrix, the second model parameter matrix include multiple second model parameter submatrixs.
Wherein, the second relation table is each feature field and corresponding in the third network layer by first nerves network model The mapping table of model parameter composition, can be one-to-many relationship, such as a feature field corresponds to multiple model parameters. Wherein, in the second relation table, each feature field of third network layer uses corresponding feature field designation, i.e. the second relationship Table includes corresponding second field designation in each feature field of third network layer and the corresponding second model ginseng of the second field designation Matrix number.Here the second field designation is for each feature field of unique identification third network layer.
Specifically, corresponding second field designation is distributed to each feature field of third network layer in advance, further according to each The relationship in a feature field and corresponding second model parameter matrix forms the second field designation and corresponding second model parameter The relationship of matrix finally obtains the second relation table.Wherein, a feature field can correspond to multiple sub- squares of second model parameter Battle array, the number of the second model parameter submatrix specifically can be true according to the vector dimension in the feature field of first nerves network model It is fixed.Finally, storing the second obtained relation table into server.
Step 406, when the first field designation in the second relation table there are when identical second field designation, by the second neck Domain identifier is identified as target domain.
Specifically, the first relation table and the second relation table got is traversed, can be first in the first relation table Foundation of the field designation as traversal traverses the first relation table and the second relation table according to the first field designation.Specifically it can be, Judge the first field designation in the first relation table whether in the second relation table there are identical second field designation, if The first field designation in one relation table, there are identical second field designation, illustrates in nervus opticus net in the second relation table There are identical feature fields in first nerves network model in first field designation corresponding feature field in network model.
Specifically, when the first field designation in the first relation table, there are identical second field marks in the second relation table When knowledge, then identified the second field designation as target domain.
In one embodiment, there is no identical second field designation in the second relation table when the first field designation When, random assignment is carried out to the matrix value of the corresponding first object model parameter matrix of the first field designation.
Specifically, when the first field designation in the first relation table does not have identical second field in the second relation table When mark, illustrate the corresponding feature field of first field designation relative to the feature field of first nerves network model be variation Feature field, in first nerves network model be not present corresponding feature field.Therefore, in the second relation table not There are the first field designations of identical second field designation, can be to the corresponding first object model parameter of the first field designation The matrix value of matrix carries out random initializtion assignment.Wherein, random initializtion assignment can be the number generated using normal distribution To initialize.
Step 408, target domain is obtained in the second relation table identify corresponding second objective model parameter matrix.
Step 410, the matrix value of the second objective model parameter matrix is filled into the first mesh corresponding to the first field designation It marks in model parameter matrix.
Specifically, after identifying the second field designation as target domain, since the second relation table includes third network Corresponding second field designation in each feature field and the corresponding second model parameter matrix of the second field designation in layer, therefore can Corresponding second objective model parameter matrix is obtained in the second relation table according to target domain mark.Finally, by the second target The corresponding matrix value of model parameter matrix is filled into the corresponding first object model parameter matrix of the first field designation.Namely It says, the matrix value of the model parameter matrix of first nerves network model is moved into nervus opticus network model correspondingly In model parameter matrix, if feature identical with nervus opticus network model field is not present in first nerves network model, Random assignment is carried out to the matrix value of the model parameter matrix in feature field different in nervus opticus network model.
In one embodiment, as shown in figure 5, obtaining each feature field and corresponding model parameter in third network layer The second relation table, the second relation table includes corresponding second field designation in each feature field and the second neck in third network layer The corresponding second model parameter matrix of domain identifier, the second model parameter matrix include multiple second model parameter submatrixs, comprising:
Step 502, raw to feature field each in third network layer according to the first default feature field designation allocation rule At corresponding second feature field designation.
Wherein, the first default feature field designation allocation rule is used to distribute each feature field in third network layer The rule of corresponding second feature field designation.First default feature field designation allocation rule can be according to business demand or Person's application scenarios are configured.Specifically, due to the output sub-network in the third network layer for first nerves network model For, it is that can not perceive input to be made of the feature field in how many a fields, so output in third network layer Network, which needs to follow certain rule, can just find corresponding relationship.It therefore, can be according to the first default feature field designation Allocation rule generates corresponding second feature field designation to feature field each in third network layer.For example, first nerves net The third network layer of network model includes age, gender, these three the feature fields user id, then is marked according to the first default feature field Knowing allocation rule is that generate corresponding second feature field designation be 1,2,3 by age, gender, user id.
Step 504, according to the first default matrix identification allocation rule to each second model in the second model parameter matrix Parameter submatrix distributes corresponding second model parameter submatrix mark, and the number of the second model parameter submatrix mark is basis What the vector dimension in the feature field of first nerves network determined.
Wherein, the first default matrix identification allocation rule is used for each second model parameter in the second model parameter matrix Submatrix distributes the rule of corresponding second parameter submatrix mark, can be determining according to practical business demand or business scenario It arrives.And the number of the second parameter submatrix mark is determined according to the vector dimension in the feature field of first nerves network, such as The vector dimension number in the feature field of first nerves network is 2, illustrates the corresponding 2 sub- squares of the second model parameter in this feature field Battle array, then according to the first default matrix identification allocation rule to each second model parameter submatrix in the second model parameter matrix point It is identified with corresponding second model parameter submatrix.For example, being age, property according to the first default feature field designation allocation rule Not, it is 1,2,3 that user id, which generates corresponding second feature field designation, and age, gender, user id are 2 the corresponding Two model parameter submatrixs then distribute corresponding second model parameter for 1 corresponding 2 the second model parameter submatrix of age Matrix identification is 0,1.
Step 506, the relationship for establishing second feature field designation and corresponding second model parameter submatrix mark, forms Second relation table.
Specifically, the corresponding second feature field designation in each feature field and corresponding the in obtaining third network layer After two model parameter submatrixs mark, according to the relationship that second feature field designation and corresponding model parameter submatrix identify, Form the second relation table.For example, corresponding second feature field designation is distributed for all feature fields of third network layer, such as All feature fields of third network layer are the age, gender, user id, then respectively age, gender, and user id is distributed pair respectively The second feature field designation answered is 1,2,3, and since the vector dimension in feature field is 2, then the feature summation in each field The vector for obtaining 2 dimensions is the feature field in the field, wherein being joined according to the first default matrix identification allocation rule to the second model Each second model parameter submatrix distributes corresponding second model parameter submatrix mark in matrix number, such as the age corresponding the Two model parameter submatrixs are identified as 0,1, and the corresponding second model parameter submatrix of gender is identified as 2,3, and user id is corresponding Second model parameter submatrix is identified as 4,5.Finally, establishing second feature field designation and corresponding second parameter submatrix mark The relationship of knowledge, such as the relationship of second feature field designation 1 and the second model parameter submatrix mark 0,1.
In one embodiment, as shown in fig. 6, obtaining each feature field and corresponding model parameter in first network layer The first relation table, the first relation table includes corresponding first field designation in each feature field and the first neck in first network layer The corresponding first model parameter matrix of domain identifier, the first model parameter matrix include multiple first model parameter submatrixs, comprising:
Step 602, feature identical with third network layer field in first network layer is obtained, identical feature field is obtained Corresponding second feature field designation, using second feature field designation as keeping characteristics field designation.
Wherein, each feature field the allocated corresponding second in the third network layer of first nerves network model is special Field designation is levied, therefore corresponding spy is distributed in each feature field in the first network layer to nervus opticus network model When levying field designation, the corresponding feature field designation of first network layer and third network layer same characteristic features field can be retained, i.e., In first network layer, retain the corresponding feature field designation in identical with third network layer feature field.Specifically, first is obtained Feature identical with third network layer field in network layer specifically can be each feature field of first network layer and third Each feature field of network layer is compared, and obtains identical feature field.It obtains and corresponds to further according to identical feature field Second feature field designation, the second feature field designation that finally will acquire is as keeping characteristics field designation.
Step 604, remaining feature field in first network layer is obtained, according to the second default feature field designation distribution rule Then remaining corresponding feature field designation is generated for remaining feature field.
Wherein, remaining feature field refers to that the feature in first network layer other than identical feature field is led here Domain obtains remaining feature field in first network layer.According to the second default feature field designation allocation rule to the first net Remaining feature field in network layers generates remaining corresponding feature field designation.Wherein, the second default feature field designation point It is for distributing corresponding spy to remaining feature field in first network layer other than identical feature field with rule Levy the rule of field designation.Second default feature field designation allocation rule can be according to business demand or application scenarios into Row setting.
For example, the third network layer of first nerves network model includes age, gender, these three the feature fields user id, It is then age, gender, the corresponding second feature field mark of user id generation according to the first default feature field designation allocation rule Know is 1,2,3.The first network layer of nervus opticus network model includes age, user id, article id and article theme, according to The feature field of the first network layer of the third network layer and nervus opticus network model of one neural network model is compared, and is obtained It is age and user id to identical feature field, then retains the second feature field of age and user id in third network layer Mark 1 and 3.Then further according to the second default feature field designation allocation rule to remaining feature field article id and article master Topic distributes corresponding feature field designation, since sex character field has been deleted in nervus opticus network model, Then the corresponding second feature field mark 2 of gender is no longer carried out using then by article id and the corresponding feature field of article theme It is 4 and 5 that mark, which distributes corresponding feature field designation,.Then the feature field age of the first network layer in nervus opticus network, User id, article id and the corresponding feature field designation of article theme are 1,3,4,5.
Step 606, according to the second default matrix identification allocation rule to each first model in the first model parameter matrix Parameter submatrix distributes corresponding first model parameter submatrix mark, and the number of the first model parameter submatrix mark is basis What the vector dimension in the feature field of nervus opticus network model determined.
Wherein, the second default matrix identification allocation rule is used for each first model parameter in the first model parameter matrix Submatrix distributes the rule of corresponding first model parameter submatrix mark, can be true according to practical business demand or business scenario Surely it obtains.And the number of the first model parameter submatrix mark is true according to the vector dimension in the feature field of nervus opticus network Fixed, if the vector dimension number in the feature field of nervus opticus network is 2, illustrate corresponding 2 the second models in this feature field Parameter submatrix, then according to the second default matrix identification allocation rule to each first model parameter in the first model parameter matrix Submatrix distributes corresponding first model parameter submatrix mark.Such as, the feature neck of the first network layer in nervus opticus network Domain age, user id, article id and the corresponding feature field designation of article theme are 1,3,4,5, and each feature field is distinguished Corresponding 2 the first model parameter submatrixs, then 1 corresponding 2 the first model parameter submatrix of age distributes corresponding first mould Shape parameter submatrix is identified as 0,1, and 3 corresponding 2 the first model parameter submatrixs of user id distribute corresponding first model ginseng Number submatrix is identified as 2,3, and 4 corresponding 2 the first model parameter submatrixs of article id distribute corresponding first model parameter Matrix identification is 4,5, and 5 corresponding 2 the first model parameter submatrixs of article theme distribute the corresponding sub- square of first model parameter Battle array is identified as 6,7.
Step 608, keeping characteristics field designation and corresponding first parameter submatrix mark, remaining feature field mark are established Know the relationship with corresponding first parameter submatrix mark, forms the first relation table.
Specifically, the corresponding fisrt feature field designation in each feature field and corresponding the in obtaining first network layer After one model parameter submatrix mark, according to keeping characteristics field designation and corresponding first parameter submatrix mark, remaining spy The relationship for levying field designation and corresponding first parameter submatrix mark, forms the first relation table.For example, first network layer is all Feature field be age, user id, article id and article theme, age, user id, article id and article theme respectively correspond Feature field designation be 1,3,4,5.And each feature field respectively corresponds 2 the first model parameter submatrixs, then the age 1 is right 2 the first model parameter submatrixs answered distribute corresponding first model parameter submatrix and are identified as 0,1, and user id 3 is corresponding 2 the first model parameter submatrixs distribute corresponding first model parameter submatrix and are identified as 2,3, and article id 4 corresponding 2 First model parameter submatrix distributes corresponding first model parameter submatrix and is identified as 4,5, article theme 5 corresponding 2 the One model parameter submatrix distributes corresponding first model parameter submatrix and is identified as 6,7.Finally, establishing in the first relation table The relationship of one feature field designation and corresponding first model parameter submatrix mark, such as fisrt feature field designation 1 and first Model parameter submatrix identifies 0,1 relationship, and fisrt feature field designation 3 and the first model parameter submatrix identify 2,3 pass System etc..
In one embodiment, as shown in fig. 7, neural network training method further include:
Step 702, configuration file is obtained, the mark of setting heat load in configuration file.
Step 704, the hot load request of neural network is generated by acting on the operation triggering of the mark of heat load.
Step 706, nervus opticus network model is obtained according to the hot load request of neural network.
Specifically, the information configured to neural network is needed when configuration file is neural metwork training, in configuration text The mark of setting heat load in part, heat load here refer to that neural network model is pre-loaded trained before on startup Good model, then new data is begun to use to be trained.It is provided with the mark of heat load in configuration file, is to need When obtaining nervus opticus network model, mind can be generated by the operation triggering of the mark of the heat load acted in configuration file Through network boom load request.Finally, obtaining nervus opticus network model according to the hot load request of neural network.Wherein, it acts on The operation of the mark of heat load in configuration file can be clicking operation or voice operating or the scheduled time be arranged, When reach the scheduled time can automatic trigger generate etc..
In one embodiment, as shown in figure 8, neural network training method further include:
Step 802, the targeted subnet network in nervus opticus network model with the input network connection of the second network layer is obtained Sub-network number of nodes.
Specifically, the input network of the second network layer of nervus opticus network model is the output network of first network layer, That is the second network layer and first network layer share the same sub-network.Obtain nervus opticus network in the second network layer Input network connection the corresponding sub-network node of targeted subnet network.As shown in Figure 2 A, the second of nervus opticus network model The input network of network layer is the output network of first network layer, i.e. v0 and the network where v1 are the input net of the second network layer Network, while being the output network of first network layer.It and is input with the targeted subnet network of the input network connection of the second network layer Next layer network of network, network layer of the targeted subnet network as where n1, n2, n3 and n4 in Fig. 2A.Finally, obtaining target again The sub-network number of nodes of sub-network.The sub-network number of nodes of targeted subnet network as shown in Figure 2 A includes 4 network nodes.
Step 804, the number of storage server is determined according to sub-network number of nodes.
Step 806, according to the number of storage server by the corresponding model parameter in feature each in first network layer field Mean allocation is into each storage server.
Wherein, due to needing the corresponding model in each feature field in the first network layer by nervus opticus network model Parametric distribution is stored to different servers, it is therefore desirable to the number of storage server is determined according to sub-network number of nodes. Wherein it is determined that the method for determination of the number of storage server can customize, it is customized to can be the mean value of sub-network number of nodes It is 4 as the number of storage server, such as sub-network number of nodes, then the number of storage server is 2.
Further, the corresponding model in feature each in first network layer field is joined according to the number of storage server Number mean allocation is into each storage server.As shown in Figure 8 A, Fig. 8 A shows each in first network layer in one embodiment The schematic diagram of the relation table of the corresponding model parameter in feature field, n1, n2, n3, n4 in Fig. 8 A are sub-network interstitial content, are closed It is the relationship that table describes each feature field and corresponding model parameter in first network layer.If feature field a is in sub-network The corresponding model parameter of node n1 is W1_11 and W1_12.Finally, will be each in first network layer by the number of storage server The corresponding model parameter mean allocation in feature field is into each storage server.Such as, by the corresponding model parameter point of n1 and n2 It is assigned in storage server a, and the corresponding model parameter of n3 and n4 is distributed into storage server b.As shown in Figure 8 B, Fig. 8 B The structural schematic diagram of the corresponding model parameter mean allocation in each feature field in first network layer is shown in one embodiment.Figure The corresponding model parameter of n1 and n2 in 8B is distributed into storage server a, and by the corresponding model parameter of n3 and n4 distribute to In storage server b.
In one embodiment, feature field is user information, at least one of text information, audio/video information, user Information is at least one of user's static information, user's multidate information, and text information is text attribute information, text and user At least one of interactive information.
Wherein, user information here refers to information related to user, and text information refers to the heart relevant to text, And audio/video information refers to information relevant to audio-video.Wherein, user information includes that user's static information and user's dynamic are believed At least one of breath, user's static information refers to customer attribute information, such as gender, age, and user's multidate information refers to The changed user related information of meeting, such as user name.And text information is text attribute information, text interacts letter with user At least one of breath.Text attribute information refers to information relevant to text attribute, such as article id.And text and user hand over Mutual information refers to the relevant information that generation is interacted between text and user, such as article theme.
In a specific embodiment, a kind of neural network training method is provided, this method specifically includes following step It is rapid:
1, configuration file is obtained, the mark of setting heat load in configuration file.
2, the hot load request of neural network is generated by acting on the operation triggering of the mark of heat load.
3, nervus opticus network model is obtained according to the hot load request of neural network.
4, nervus opticus network model is obtained, the first network layer of nervus opticus network model includes multiple feature fields, There are corresponding model parameter, model parameter is the input ginseng for the second network layer connecting with first network layer in each feature field Number.
5, third network layer corresponding with first network layer, first nerves network model are obtained from first nerves network model Have reached convergence.
6, obtain third network layer in feature field identical in first network layer.
Each feature field in 6-1, acquisition third network layer.
Each feature field in 6-2, acquisition first network layer.
6-3, each feature field in third network layer and each feature field in first network layer are compared, Obtain identical feature field.
7, the corresponding model parameter in the identical feature field of acquisition obtains reserving model parameter.
8, using reserving model parameter as the model parameter in the matched feature field of nervus opticus network model.
8-1, the first relation table for obtaining each feature field and corresponding model parameter in first network layer, the first relationship Table includes corresponding first field designation in each feature field and corresponding first model of the first field designation in first network layer Parameter matrix, the first model parameter matrix include multiple first model parameter submatrixs.
8-1-1, feature field each in third network layer is generated according to the first default feature field designation allocation rule Corresponding second feature field designation.
8-1-2, the second model each in the second model parameter matrix is joined according to the first default matrix identification allocation rule Number submatrixs distribute corresponding second model parameter submatrix mark, and the number of the second model parameter submatrix mark is according to the What the vector dimension in the feature field of one neural network determined.
8-1-3, the relationship for establishing second feature field designation and corresponding second model parameter submatrix mark, form the Two relation tables.
8-2, the second relation table for obtaining each feature field and corresponding model parameter in third network layer, the second relationship Table includes corresponding second field designation in each feature field and corresponding second model of the second field designation in third network layer Parameter matrix, the second model parameter matrix include multiple second model parameter submatrixs.
8-2-1, feature identical with third network layer field in first network layer is obtained, obtains identical feature field pair The second feature field designation answered, using second feature field designation as keeping characteristics field designation.
8-2-2, remaining feature field in first network layer is obtained, according to the second default feature field designation allocation rule Remaining corresponding feature field designation is generated for remaining feature field.
8-2-3, the first model each in the first model parameter matrix is joined according to the second default matrix identification allocation rule Number submatrixs distribute corresponding first model parameter submatrix mark, and the number of the first model parameter submatrix mark is according to the What the vector dimension in the feature field of two neural network models determined.
8-2-4, keeping characteristics field designation and corresponding first model parameter submatrix mark, remaining feature field are established The relationship of mark and corresponding first model parameter submatrix mark, forms the first relation table.
8-3, when the first field designation in the second relation table there are when identical second field designation, the second field is marked Know and is identified as target domain.
8-4, the corresponding second objective model parameter matrix of target domain mark is obtained in the second relation table.
8-5, the matrix value of the second objective model parameter matrix is filled into first object mould corresponding to the first field designation In shape parameter matrix.
8-6, when not there is no identical second field designation in the second relation table in the first field designation, to the first field The matrix value for identifying corresponding first object model parameter matrix carries out random assignment.
9, input training sample to nervus opticus network model is trained, until meeting the condition of convergence, obtains target mind Through network model.
10, the subnet in nervus opticus network model with the targeted subnet network of the input network connection of the second network layer is obtained Network number of nodes.
11, the number of storage server is determined according to sub-network number of nodes.
12, according to the number of storage server by the corresponding model parameter average mark in feature each in first network layer field It is assigned in each storage server.
In a practical application business scenario, first nerves network model is to have reached convergent neural network mould Type, first nerves network model are recommended in application scenarios for information, and user's Interest Measure can be predicted in first nerves network model User's high information interested is recommended the homepage to terminal browser to show, as shown in Figure 9 A by high information.Fig. 9 A shows Out in one embodiment first nerves network model recommend information interface schematic diagram.
Once the feature field in first nerves network model input sample is changed, information recommendation is also become Change, therefore for the accuracy that information is recommended, then not only needs to upgrade neural network model, but also the information finally recommended also is sent out Variation is given birth to.Therefore, it is necessary to upgrade to first nerves network model.
Specifically, nervus opticus network model, the network of nervus opticus network model and first nerves network model are obtained Structure can be it is identical, the model parameter of nervus opticus network model be all it is not set, can be according to first nerves network mould The relationship in the feature field in the feature field and nervus opticus network model of type, by the feature field pair of first nerves network model The model parameter answered is moved to one by one in the corresponding model parameter matrix of nervus opticus network model.And for nervus opticus network The corresponding model parameter in emerging feature field then carries out random assignment in model.It is so, remain first nerves network The department pattern parameter of model, and first nerves network model is to have reached convergent, therefore nervus opticus network model is only Need to train the department pattern parameter of random assignment, to reduce the training time of neural network model and promote nervus opticus Network model is rapidly achieved convergence.
Further, have reached the high information of user's Interest Measure that convergent nervus opticus network model predicts with The result of first nerves network model prediction is not identical, the accuracy ratio for the information that nervus opticus network model predicts The accuracy for the information that first nerves network model predicts is high, and the information that nervus opticus network model predicts User's Interest Measure it is higher than the user's Interest Measure for the information that first nerves network model predicts.Nervus opticus network Model prediction result can be as shown in Figure 9 B, and Fig. 9 B shows nervus opticus network model in one embodiment and the interface of information is recommended to show It is intended to.
It should be understood that although each step in above-mentioned flow chart is successively shown according to the instruction of arrow, this A little steps are not that the inevitable sequence according to arrow instruction successively executes.Unless expressly state otherwise herein, these steps It executes there is no the limitation of stringent sequence, these steps can execute in other order.Moreover, in above-mentioned flow chart at least A part of step may include that perhaps these sub-steps of multiple stages or stage are not necessarily in same a period of time to multiple sub-steps Quarter executes completion, but can execute at different times, the execution in these sub-steps or stage be sequentially also not necessarily according to Secondary progress, but in turn or can replace at least part of the sub-step or stage of other steps or other steps Ground executes.
In one embodiment, as shown in figure 9, providing a kind of neural metwork training device 900, which includes:
Neural network model obtains module 902, for obtaining nervus opticus network model, the of nervus opticus network model One network layer includes multiple feature fields, and there are corresponding model parameter, model parameter is and first network in each feature field The input parameter of second network layer of layer connection.
Network layer obtains module 904, for obtaining third net corresponding with first network layer from first nerves network model Network layers, first nerves network model have reached convergence.
Feature field obtain module 906, for obtain in third network layer with feature field identical in first network layer, It obtains the corresponding model parameter in identical feature field and obtains reserving model parameter.
Model parameter processing module 908, for using reserving model parameter as the matched feature of nervus opticus network model The model parameter in field.
Nervus opticus network model training module 910 is instructed for inputting training sample to nervus opticus network model Practice, until meeting the condition of convergence, obtains target nerve network model.
In one embodiment, as shown in Figure 10, acquisition module 906 in feature field includes:
Fisrt feature field acquiring unit 906a, for obtaining each feature field in third network layer.
Second feature field acquiring unit 906b, for obtaining each feature field in first network layer.
Feature field comparing unit 906c, for will be in each feature field and first network layer in third network layer Each feature field is compared, and obtains identical feature field.
In one embodiment, as shown in figure 11, model parameter processing module 908 includes:
First relation table acquiring unit 908a, for obtaining each feature field and corresponding model ginseng in first network layer The first several relation tables, the first relation table include corresponding first field designation in each feature field and first in first network layer The corresponding first model parameter matrix of field designation, the first model parameter matrix include multiple first model parameter submatrixs.
Second relation table acquiring unit 908b, for obtaining each feature field and corresponding model ginseng in third network layer The second several relation tables, the second relation table include corresponding second field designation in each feature field and second in third network layer The corresponding second model parameter matrix of field designation, the second model parameter matrix include multiple second model parameter submatrixs.
Relation table processing unit 908c, for there are identical second fields in the second relation table when the first field designation When mark, identified the second field designation as target domain.
Objective model parameter matrix acquiring unit 908d, it is corresponding for obtaining target domain mark in the second relation table Second objective model parameter matrix.
Matrix value fills unit 908e is marked for filling the matrix value of the second objective model parameter matrix to the first field Know in corresponding first object model parameter matrix.
In one embodiment, model parameter processing module 908 is also used to when the first field designation is in the second relation table When there is no identical second field designation, to the matrix value of the corresponding first object model parameter matrix of the first field designation into Row random assignment.
In one embodiment, the second relation table acquiring unit 908b is also used to according to the first default feature field designation point Corresponding second feature field designation is generated to feature field each in third network layer with rule;According to the first default matrix mark Know allocation rule and distributes corresponding second model parameter to the second model parameter submatrix each in the second model parameter matrix The number of matrix identification, the second model parameter submatrix mark is true according to the vector dimension in the feature field of first nerves network Fixed;The relationship for establishing second feature field designation and corresponding second parameter submatrix mark, forms the second relation table.
In one embodiment, the first relation table acquiring unit 908a is also used to obtain in first network layer and third network The identical feature field of layer obtains the corresponding second feature field designation in identical feature field, by second feature field designation As keeping characteristics field designation;Remaining feature field in first network layer is obtained, according to the second default feature field designation Allocation rule is that remaining feature field generates remaining corresponding feature field designation;According to the second default matrix identification distribution rule It then distributes corresponding first parameter submatrix to the first model parameter submatrix each in the first model parameter matrix to identify, first The number of parameter submatrix mark is determined according to the vector dimension in the feature field of nervus opticus network model;It establishes and retains Feature field designation and corresponding first parameter submatrix mark, remaining feature field designation and corresponding first parameter submatrix The relationship of mark forms the first relation table.
In one embodiment, as shown in figure 12, the neural metwork training device 900 further include:
Configuration file obtains module 912, for obtaining configuration file, the mark of setting heat load in configuration file.
The hot load request generation module 914 of neural network, the operation triggering life for the mark by acting on heat load At the hot load request of neural network.
Neural network model obtains module 902 and is also used to obtain nervus opticus network mould according to the hot load request of neural network Type.
In one embodiment, which is also used to obtain in nervus opticus network and the second net The sub-network number of nodes of the targeted subnet network of the input network connection of network layers;Storage server is determined according to sub-network number of nodes Number;According to the number of storage server by the corresponding model parameter mean allocation in feature each in first network layer field to each In a storage server.
Figure 13 shows the internal structure chart of computer equipment in one embodiment.The computer equipment specifically can be figure Server 120 in 1.As shown in figure 13, it includes being connected by system bus which, which includes the computer equipment, Processor, memory, network interface, input unit.Wherein, memory includes non-volatile memory medium and built-in storage.It should The non-volatile memory medium of computer equipment is stored with operating system, can also be stored with computer program, the computer program When being executed by processor, processor may make to realize neural network training method.Computer can also be stored in the built-in storage Program when the computer program is executed by processor, may make processor to execute neural network training method.Computer equipment Input unit can be the touch layer covered on display screen, be also possible to the key being arranged on computer equipment shell, trace ball Or Trackpad, it can also be external keyboard, Trackpad or mouse etc..
It will be understood by those skilled in the art that structure shown in Figure 13, only part relevant to application scheme The block diagram of structure, does not constitute the restriction for the computer equipment being applied thereon to application scheme, and specific computer is set Standby may include perhaps combining certain components or with different component layouts than more or fewer components as shown in the figure.
In one embodiment, neural metwork training device provided by the present application can be implemented as a kind of computer program Form, computer program can be run in computer equipment as shown in fig. 13 that.Group can be stored in the memory of computer equipment At each program module of the neural metwork training device, for example, neural network model shown in Fig. 9 obtains module, network layer Obtain module, feature field obtains module, model parameter processing module and nervus opticus network model training module.Each program The computer program of module composition makes processor execute the neural network of each embodiment of the application described in this specification Step in training method.
For example, computer equipment shown in Figure 13 can pass through the nerve in neural metwork training device as shown in Figure 9 Network model obtains module and executes acquisition nervus opticus network model, and the first network layer of nervus opticus network model includes multiple Feature field, there are corresponding model parameter, model parameter is the second network connecting with first network layer in each feature field The input parameter of layer.Network layer obtains module and executes third net corresponding with first network layer from the acquisition of first nerves network model Network layers, first nerves network model have reached convergence.Feature field, which obtains module and executes, to be obtained in third network layer with first Identical feature field in network layer obtains the corresponding model parameter in identical feature field and obtains reserving model parameter.Model Parameter processing module is executed using reserving model parameter as the model parameter in the matched feature field of nervus opticus network model.The Two neural network model training modules execute input training sample to nervus opticus network model and are trained, until meeting convergence Condition obtains target nerve network model.
In one embodiment, a kind of computer equipment, including memory and processor are provided, memory is stored with meter Calculation machine program, when computer program is executed by processor, so that the step of processor executes above-mentioned neural network training method.This The step of locating neural network training method can be the step in the neural network training method of above-mentioned each embodiment.
In one embodiment, a kind of computer readable storage medium is provided, computer program, computer journey are stored with When sequence is executed by processor, so that the step of processor executes above-mentioned neural network training method.Neural metwork training side herein The step of method, can be the step in the neural network training method of above-mentioned each embodiment.
Those of ordinary skill in the art will appreciate that realizing all or part of the process in above-described embodiment method, being can be with Relevant hardware is instructed to complete by computer program, the program can be stored in a non-volatile computer and can be read In storage medium, the program is when being executed, it may include such as the process of the embodiment of above-mentioned each method.Wherein, provided herein Each embodiment used in any reference to memory, storage, database or other media, may each comprise non-volatile And/or volatile memory.Nonvolatile memory may include that read-only memory (ROM), programming ROM (PROM), electricity can be compiled Journey ROM (EPROM), electrically erasable ROM (EEPROM) or flash memory.Volatile memory may include random access memory (RAM) or external cache.By way of illustration and not limitation, RAM is available in many forms, such as static state RAM (SRAM), dynamic ram (DRAM), synchronous dram (SDRAM), double data rate sdram (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronization link (Synchlink) DRAM (SLDRAM), memory bus (Rambus) directly RAM (RDRAM), straight Connect memory bus dynamic ram (DRDRAM) and memory bus dynamic ram (RDRAM) etc..
Each technical characteristic of above embodiments can be combined arbitrarily, for simplicity of description, not to above-described embodiment In each technical characteristic it is all possible combination be all described, as long as however, the combination of these technical characteristics be not present lance Shield all should be considered as described in this specification.
The several embodiments of the application above described embodiment only expresses, the description thereof is more specific and detailed, but simultaneously The limitation to the application the scope of the patents therefore cannot be interpreted as.It should be pointed out that for those of ordinary skill in the art For, without departing from the concept of this application, various modifications and improvements can be made, these belong to the guarantor of the application Protect range.Therefore, the scope of protection shall be subject to the appended claims for the application patent.

Claims (15)

1. a kind of neural network training method, comprising:
Nervus opticus network model is obtained, the first network layer of the nervus opticus network model includes multiple feature fields, respectively There are corresponding model parameter, the model parameter is the second network layer connecting with the first network layer in a feature field Input parameter;
Third network layer corresponding with the first network layer, the first nerves network mould are obtained from first nerves network model Type has reached convergence;
It obtains in the third network layer with identical feature field in the first network layer, obtains the identical feature neck The corresponding model parameter in domain obtains reserving model parameter;
Using the reserving model parameter as the model parameter in the matched feature field of the nervus opticus network model;
Input training sample to the nervus opticus network model is trained, until meeting the condition of convergence, obtains target nerve Network model.
2. the method according to claim 1, wherein it is described obtain in the third network layer with first net Identical feature field in network layers, comprising:
Obtain each feature field in the third network layer;
Obtain each feature field in the first network layer;
Each feature field in each feature field and the first network layer in the third network layer is compared, Obtain identical feature field.
3. the method according to claim 1, wherein described using the reserving model parameter as second mind Model parameter through the matched feature field of network model, comprising:
Obtain first relation table in each feature field and corresponding model parameter in the first network layer, first relationship Table include in the first network layer each corresponding first field designation in feature field and first field designation it is corresponding First model parameter matrix, the first model parameter matrix include multiple first model parameter submatrixs;
Obtain second relation table in each feature field and corresponding model parameter in the third network layer, second relationship Table include in the third network layer each corresponding second field designation in feature field and second field designation it is corresponding Second model parameter matrix, the second model parameter matrix include multiple second model parameter submatrixs;
When first field designation in second relation table there are when identical second field designation, described second is led Domain identifier is identified as target domain;
The target domain is obtained in second relation table identifies corresponding second objective model parameter matrix;
The matrix value of the second objective model parameter matrix is filled into first object mould corresponding to first field designation In shape parameter matrix.
4. according to the method described in claim 3, it is characterized in that, the method also includes:
When first field designation does not have identical second field designation in second relation table, to described first The matrix value of the corresponding first object model parameter matrix of field designation carries out random assignment.
5. according to the method described in claim 3, it is characterized in that, described obtain each feature field in the third network layer With the second relation table of corresponding model parameter, second relation table includes each feature field pair in the third network layer The second field designation and the corresponding second model parameter matrix of second field designation answered, the second model parameter matrix Including multiple second model parameter submatrixs, comprising:
Feature field each in the third network layer is generated according to the first default feature field designation allocation rule corresponding Second feature field designation;
According to the first default matrix identification allocation rule to the sub- square of the second model parameter each in the second model parameter matrix Battle array distributes corresponding second model parameter submatrix mark, and the number of the second model parameter submatrix mark is according to What the vector dimension in the feature field of first nerves network determined;
The relationship for establishing the second feature field designation and corresponding second model parameter submatrix mark, forms described second Relation table.
6. according to the method described in claim 4, it is characterized in that, described obtain each feature field in the first network layer With the first relation table of corresponding model parameter, first relation table includes each feature field pair in the first network layer The first field designation and the corresponding first model parameter matrix of first field designation answered, the first model parameter matrix Including multiple first model parameter submatrixs, comprising:
Feature field identical with the third network layer in the first network layer is obtained, the identical feature field is obtained Corresponding second feature field designation, using the second feature field designation as keeping characteristics field designation;
Remaining feature field in the first network layer is obtained, is described according to the second default feature field designation allocation rule Remaining feature field generates remaining corresponding feature field designation;
According to the second default matrix identification allocation rule to the sub- square of the first model parameter each in the first model parameter matrix Battle array distributes corresponding first model parameter submatrix mark, and the number of the first model parameter submatrix mark is according to What the vector dimension in the feature field of nervus opticus network model determined;
Establish the keeping characteristics field designation and corresponding first model parameter submatrix mark, remaining described feature field mark Know the relationship with corresponding first model parameter submatrix mark, forms the first relation table.
7. the method according to claim 1, wherein the method also includes:
Configuration file is obtained, the mark of setting heat load in the configuration file;
Operation triggering by acting on the mark of the heat load generates the hot load request of neural network;
The nervus opticus network model is obtained according to the hot load request of the neural network.
8. the method according to claim 1, wherein the method also includes:
Obtain the son in the nervus opticus network model with the targeted subnet network of the input network connection of second network layer Number of network node;
The number of storage server is determined according to the sub-network number of nodes;
The corresponding model parameter in feature field each in the first network layer is averaged according to the number of the storage server Distribution is into each storage server.
9. the method according to claim 1, wherein the feature field is user information, text information, sound view At least one of frequency information, the user information are at least one of user's static information, user's multidate information, the text Information is at least one of text attribute information, text and customer interaction information.
10. a kind of neural metwork training device, which is characterized in that described device includes:
Neural network model obtains module, for obtaining nervus opticus network model, the first of the nervus opticus network model Network layer includes multiple feature fields, and there are corresponding model parameter, the model parameter is and described the in each feature field The input parameter of second network layer of one network layer connection;
Network layer obtains module, for obtaining third network corresponding with the first network layer from first nerves network model Layer, the first nerves network model have reached convergence;
Feature field obtains module, leads for obtaining in the third network layer with feature identical in the first network layer Domain obtains the corresponding model parameter in the identical feature field and obtains reserving model parameter;
Model parameter processing module, for using the reserving model parameter as the matched feature of nervus opticus network model The model parameter in field;
Nervus opticus network model training module is trained for inputting training sample to the nervus opticus network model, Until meeting the condition of convergence, target nerve network model is obtained.
11. device according to claim 10, which is characterized in that the feature field obtains module and includes:
Fisrt feature field acquiring unit, for obtaining each feature field in the third network layer;
Second feature field acquiring unit, for obtaining each feature field in the first network layer;
Feature field comparing unit, for will be in each feature field and the first network layer in the third network layer Each feature field is compared, and obtains identical feature field.
12. device according to claim 10, which is characterized in that the model parameter processing module includes:
First relation table acquiring unit, for obtaining each feature field and corresponding model parameter in the first network layer First relation table, first relation table include in the first network layer corresponding first field designation in each feature field and The corresponding first model parameter matrix of first field designation, the first model parameter matrix include multiple first models ginsengs Number submatrix;
Second relation table acquiring unit, for obtaining each feature field and corresponding model parameter in the third network layer Second relation table, second relation table include in the third network layer corresponding second field designation in each feature field and The corresponding second model parameter matrix of second field designation, the second model parameter matrix include multiple second models ginsengs Number submatrix;
Relation table processing unit, for there are identical second fields in second relation table when first field designation When mark, identified second field designation as target domain;
Objective model parameter matrix acquiring unit, it is corresponding for obtaining the target domain mark in second relation table Second objective model parameter matrix;
Matrix value fills unit is marked for filling the matrix value of the second objective model parameter matrix to first field Know in corresponding first object model parameter matrix.
13. the apparatus according to claim 1, which is characterized in that described device further include:
Configuration file obtains module, for obtaining configuration file, the mark of setting heat load in the configuration file;
The hot load request generation module of neural network, for generating mind by the operation triggering for the mark for acting on the heat load Through network boom load request;
The neural network model obtains module and is also used to obtain the nervus opticus according to the hot load request of the neural network Network model.
14. a kind of computer readable storage medium is stored with computer program, when the computer program is executed by processor, So that the processor is executed such as the step of any one of claims 1 to 9 the method.
15. a kind of computer equipment, including memory and processor, the memory is stored with computer program, the calculating When machine program is executed by the processor, so that the processor executes the step such as any one of claims 1 to 9 the method Suddenly.
CN201910238685.6A 2019-03-27 2019-03-27 Neural network training method and device, readable storage medium and computer equipment Active CN109978140B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910238685.6A CN109978140B (en) 2019-03-27 2019-03-27 Neural network training method and device, readable storage medium and computer equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910238685.6A CN109978140B (en) 2019-03-27 2019-03-27 Neural network training method and device, readable storage medium and computer equipment

Publications (2)

Publication Number Publication Date
CN109978140A true CN109978140A (en) 2019-07-05
CN109978140B CN109978140B (en) 2021-02-26

Family

ID=67080971

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910238685.6A Active CN109978140B (en) 2019-03-27 2019-03-27 Neural network training method and device, readable storage medium and computer equipment

Country Status (1)

Country Link
CN (1) CN109978140B (en)

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110347838A (en) * 2019-07-17 2019-10-18 成都医云科技有限公司 Model training method and device are examined by Xian Shang department point
CN110827078A (en) * 2019-11-04 2020-02-21 上海喜马拉雅科技有限公司 Information recommendation method, device, equipment and storage medium
CN111444731A (en) * 2020-06-15 2020-07-24 深圳市友杰智新科技有限公司 Model training method and device and computer equipment
CN112132281A (en) * 2020-09-29 2020-12-25 腾讯科技(深圳)有限公司 Model training method, device, server and medium based on artificial intelligence
CN112819152A (en) * 2020-08-14 2021-05-18 腾讯科技(深圳)有限公司 Neural network training method and device
CN113408638A (en) * 2021-06-30 2021-09-17 北京百度网讯科技有限公司 Model training method, device, equipment and computer storage medium

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104978601A (en) * 2015-06-26 2015-10-14 深圳市腾讯计算机系统有限公司 Neural network model training system and method
CN107688493A (en) * 2016-08-05 2018-02-13 阿里巴巴集团控股有限公司 Train the method, apparatus and system of deep neural network
CN108491928A (en) * 2018-03-29 2018-09-04 腾讯科技(深圳)有限公司 Model parameter training method, device, server and storage medium
CN109034397A (en) * 2018-08-10 2018-12-18 腾讯科技(深圳)有限公司 Model training method, device, computer equipment and storage medium
CN109146064A (en) * 2018-09-05 2019-01-04 腾讯科技(深圳)有限公司 Neural network training method, device, computer equipment and storage medium
CN109409507A (en) * 2018-10-31 2019-03-01 上海鹰瞳医疗科技有限公司 Neural network construction method and equipment

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104978601A (en) * 2015-06-26 2015-10-14 深圳市腾讯计算机系统有限公司 Neural network model training system and method
CN107688493A (en) * 2016-08-05 2018-02-13 阿里巴巴集团控股有限公司 Train the method, apparatus and system of deep neural network
CN108491928A (en) * 2018-03-29 2018-09-04 腾讯科技(深圳)有限公司 Model parameter training method, device, server and storage medium
CN109034397A (en) * 2018-08-10 2018-12-18 腾讯科技(深圳)有限公司 Model training method, device, computer equipment and storage medium
CN109146064A (en) * 2018-09-05 2019-01-04 腾讯科技(深圳)有限公司 Neural network training method, device, computer equipment and storage medium
CN109409507A (en) * 2018-10-31 2019-03-01 上海鹰瞳医疗科技有限公司 Neural network construction method and equipment

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
HAMIDREZA RASHIDY KANAN等: "Reduction of Neural Network Training Time Using an Adaptive Fuzzy Approach in Real Time Applications", 《INTERNATIONAL JOURNAL OFINFORMATION AND ELECTRONICS ENGINEERING》 *
范青: "卷积神经网络中减少训练样本时间方法研究", 《电脑知识与技术》 *

Cited By (11)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110347838A (en) * 2019-07-17 2019-10-18 成都医云科技有限公司 Model training method and device are examined by Xian Shang department point
CN110347838B (en) * 2019-07-17 2021-09-03 成都医云科技有限公司 Online department triage model training method and device
CN110827078A (en) * 2019-11-04 2020-02-21 上海喜马拉雅科技有限公司 Information recommendation method, device, equipment and storage medium
CN110827078B (en) * 2019-11-04 2024-04-05 上海喜马拉雅科技有限公司 Information recommendation method, device, equipment and storage medium
CN111444731A (en) * 2020-06-15 2020-07-24 深圳市友杰智新科技有限公司 Model training method and device and computer equipment
CN111444731B (en) * 2020-06-15 2020-11-03 深圳市友杰智新科技有限公司 Model training method and device and computer equipment
CN112819152A (en) * 2020-08-14 2021-05-18 腾讯科技(深圳)有限公司 Neural network training method and device
CN112819152B (en) * 2020-08-14 2024-03-01 腾讯科技(深圳)有限公司 Neural network training method and device
CN112132281A (en) * 2020-09-29 2020-12-25 腾讯科技(深圳)有限公司 Model training method, device, server and medium based on artificial intelligence
CN112132281B (en) * 2020-09-29 2024-04-26 腾讯科技(深圳)有限公司 Model training method, device, server and medium based on artificial intelligence
CN113408638A (en) * 2021-06-30 2021-09-17 北京百度网讯科技有限公司 Model training method, device, equipment and computer storage medium

Also Published As

Publication number Publication date
CN109978140B (en) 2021-02-26

Similar Documents

Publication Publication Date Title
CN109978140A (en) Neural network training method, device, readable storage medium storing program for executing and computer equipment
CN109902708B (en) Recommendation model training method and related device
CN110363243A (en) The appraisal procedure and device of disaggregated model
Vernon et al. Modeling first impressions from highly variable facial images
CN111340237B (en) Data processing and model running method, device and computer equipment
Lao et al. I map4: An open source toolbox for the statistical fixation mapping of eye movement data with linear mixed modeling
CN112330685B (en) Image segmentation model training method, image segmentation device and electronic equipment
CN108833382A (en) Network information detection method, device, storage medium and computer equipment
CN109325216A (en) Questionnaire generation method, device, computer equipment and storage medium
CN110378372A (en) Diagram data recognition methods, device, computer equipment and storage medium
CN109919304A (en) Neural network searching method, device, readable storage medium storing program for executing and computer equipment
CN110008455A (en) Table edit method, apparatus, computer equipment and storage medium
CN110363086A (en) Diagram data recognition methods, device, computer equipment and storage medium
CN108804548A (en) Test data querying method, device, computer equipment and storage medium
CN108469975A (en) Control display methods, device, computer equipment and storage medium
CN107622008A (en) The traversal method and device of a kind of five application page
CN110413512A (en) AB test method, device, computer equipment and storage medium
CN111008522A (en) Automatic article writing method and device, computer equipment and storage medium
CN112231558A (en) Online learning mining method and online learning system
CN110321467A (en) Airport engineering project information methods of exhibiting, device, system, equipment and medium
Ciavolino et al. High-order PLS path model for multi-group analysis: the prosumership service quality model
CN110942202B (en) Emergency exercise deduction method, computer storage medium and electronic equipment
Lai et al. Identifying multiple change points in a linear mixed effects model
CN112288868A (en) Intelligent building Internet of things object simulation method and system
CN111354463A (en) Human health measuring method, device, computer 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
GR01 Patent grant
GR01 Patent grant