CN112926629B - Super-parameter determination method, device, deep reinforcement learning framework, medium and equipment - Google Patents
Super-parameter determination method, device, deep reinforcement learning framework, medium and equipment Download PDFInfo
- Publication number
- CN112926629B CN112926629B CN202110129788.6A CN202110129788A CN112926629B CN 112926629 B CN112926629 B CN 112926629B CN 202110129788 A CN202110129788 A CN 202110129788A CN 112926629 B CN112926629 B CN 112926629B
- Authority
- CN
- China
- Prior art keywords
- value
- target
- parameter
- area
- sampling
- 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.)
- Active
Links
- 238000000034 method Methods 0.000 title claims abstract description 69
- 230000002787 reinforcement Effects 0.000 title claims abstract description 28
- 238000005070 sampling Methods 0.000 claims abstract description 144
- 230000003993 interaction Effects 0.000 claims abstract description 71
- 230000009471 action Effects 0.000 claims description 37
- 238000012549 training Methods 0.000 claims description 19
- 238000005457 optimization Methods 0.000 claims description 18
- 238000012545 processing Methods 0.000 claims description 18
- 230000008569 process Effects 0.000 claims description 17
- 238000004590 computer program Methods 0.000 claims description 16
- 238000009877 rendering Methods 0.000 claims 2
- 230000002452 interceptive effect Effects 0.000 abstract description 5
- 230000006870 function Effects 0.000 description 20
- 230000001186 cumulative effect Effects 0.000 description 14
- 238000010586 diagram Methods 0.000 description 7
- 230000007613 environmental effect Effects 0.000 description 7
- 238000004891 communication Methods 0.000 description 6
- 230000003287 optical effect Effects 0.000 description 5
- 238000013473 artificial intelligence Methods 0.000 description 4
- 230000002829 reductive effect Effects 0.000 description 4
- 238000004364 calculation method Methods 0.000 description 3
- 238000013528 artificial neural network Methods 0.000 description 2
- 230000008859 change Effects 0.000 description 2
- 238000013135 deep learning Methods 0.000 description 2
- 238000005516 engineering process Methods 0.000 description 2
- 230000000670 limiting effect Effects 0.000 description 2
- 239000013307 optical fiber Substances 0.000 description 2
- 230000000644 propagated effect Effects 0.000 description 2
- 239000004065 semiconductor Substances 0.000 description 2
- 239000003795 chemical substances by application Substances 0.000 description 1
- 230000001351 cycling effect Effects 0.000 description 1
- 230000003247 decreasing effect Effects 0.000 description 1
- 238000011161 development Methods 0.000 description 1
- 238000011156 evaluation Methods 0.000 description 1
- 238000000605 extraction Methods 0.000 description 1
- 239000000835 fiber Substances 0.000 description 1
- 239000004973 liquid crystal related substance Substances 0.000 description 1
- 238000010801 machine learning Methods 0.000 description 1
- 238000013507 mapping Methods 0.000 description 1
- 238000003062 neural network model Methods 0.000 description 1
- 238000010606 normalization Methods 0.000 description 1
- 230000008447 perception Effects 0.000 description 1
- 230000002441 reversible effect Effects 0.000 description 1
- 238000012546 transfer Methods 0.000 description 1
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F18/00—Pattern recognition
- G06F18/20—Analysing
- G06F18/21—Design or setup of recognition systems or techniques; Extraction of features in feature space; Blind source separation
- G06F18/214—Generating training patterns; Bootstrap methods, e.g. bagging or boosting
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06N—COMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
- G06N20/00—Machine learning
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06N—COMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
- G06N3/00—Computing arrangements based on biological models
- G06N3/02—Neural networks
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Physics & Mathematics (AREA)
- Data Mining & Analysis (AREA)
- Software Systems (AREA)
- Artificial Intelligence (AREA)
- General Physics & Mathematics (AREA)
- General Engineering & Computer Science (AREA)
- Evolutionary Computation (AREA)
- Computer Vision & Pattern Recognition (AREA)
- Life Sciences & Earth Sciences (AREA)
- Mathematical Physics (AREA)
- Computing Systems (AREA)
- Medical Informatics (AREA)
- Evolutionary Biology (AREA)
- Bioinformatics & Cheminformatics (AREA)
- Bioinformatics & Computational Biology (AREA)
- Health & Medical Sciences (AREA)
- Biomedical Technology (AREA)
- Biophysics (AREA)
- Computational Linguistics (AREA)
- General Health & Medical Sciences (AREA)
- Molecular Biology (AREA)
- Image Analysis (AREA)
- Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
Abstract
The present disclosure relates to a super parameter determination method, apparatus, deep reinforcement learning framework, medium and device, the method comprising: acquiring a sampling sample corresponding to the sampling value under the sampling value of the target super parameter of the target model; generating an interaction sample corresponding to the target super-parameter according to the sampling sample, wherein the interaction sample comprises the sampling value and the optimized characteristic parameter corresponding to the target model; updating the state value corresponding to the target super-parameter according to the interactive sample, wherein the parameter space of the target super-parameter is discretized into a plurality of valued areas; determining a target area from a plurality of value areas according to the state value corresponding to the updated target hyper-parameters; and determining the target value of the target hyper-parameter according to the target area. Therefore, the value of the super parameter of the model can be accurately set, and the phenomenon that the target model cannot converge or the convergence speed is too slow due to unsuitable super parameter setting value due to the limitation of artificial experience is avoided.
Description
Technical Field
The present disclosure relates to the field of computers, and in particular, to a method and apparatus for determining super parameters, a deep reinforcement learning framework, a medium, and a device.
Background
The development of random computer technology, various large models and complex machine learning models gradually start to be applied. The calculation is needed in the model through a large number of parameters, so that the model can meet the requirements of users. Some parameters in the model may be optimized by training the model, such as weights in the neural network model, while some parameters may not be optimized by training the model, such parameters being super-parameters of the model, such as the number of hidden layers in the neural network. The super-parameters are used for adjusting the training process of the model, are usually set manually by a worker based on experience, and do not directly participate in the training process of the model and cannot be updated in the training process of the model. The setting of the super parameters has great influence on the iteration times, convergence efficiency and the like of model training.
Disclosure of Invention
This summary is provided to introduce a selection of concepts in a simplified form that are further described below in the detailed description. This summary is not intended to identify key features or essential features of the claimed subject matter, nor is it intended to be used to limit the scope of the claimed subject matter.
In a first aspect, the present disclosure provides a method of determining a hyper-parameter, the method comprising:
acquiring a sampling sample corresponding to a sampling value under the sampling value of a target super parameter of a target model;
generating an interaction sample corresponding to the target super-parameter according to the sampling sample, wherein the interaction sample comprises the sampling value and an optimization characteristic parameter corresponding to the target model;
updating the state value corresponding to the target super-parameter according to the interaction sample, wherein the parameter space of the target super-parameter is discretized into a plurality of valued areas;
determining a target area from the plurality of valued areas according to the updated state value corresponding to the target super parameter;
and determining the target value of the target hyper-parameter according to the target area.
In a second aspect, the present disclosure provides a hyper-parameter determination apparatus, the apparatus comprising:
the acquisition module is used for acquiring a sampling sample corresponding to the sampling value under the sampling value of the target super parameter of the target model;
the generation module is used for generating an interaction sample corresponding to the target super-parameter according to the sampling sample, wherein the interaction sample comprises the sampling value and an optimization characteristic parameter corresponding to the target model;
The updating module is used for updating the state value corresponding to the target super-parameter according to the interaction sample, wherein the parameter space of the target super-parameter is discretized into a plurality of valued areas;
the first determining module is used for determining a target area from the plurality of valued areas according to the updated state value corresponding to the target super parameter;
and the second determining module is used for determining the target value of the target super-parameter according to the target area.
In a third aspect, a deep reinforcement learning framework is provided, where the value of the super parameter in the deep reinforcement learning framework is determined based on the super parameter determining method in the first aspect.
In a fourth aspect, there is provided a computer readable medium having stored thereon a computer program which, when executed by a processing device, implements the steps of the method of the first aspect.
In a fifth aspect, there is provided an electronic device comprising:
a storage device having a computer program stored thereon;
processing means for executing said computer program in said storage means to carry out the steps of the method of the first aspect.
Therefore, in the technical scheme, the parameter space of the target super-parameter is discretized into a plurality of value areas, so that the value of the target super-parameter can be determined based on the sampling sample corresponding to the target model using the target super-parameter and the optimized characteristic parameter of the target model. Therefore, through the technical scheme, on one hand, the value of the super parameter of the model can be accurately set, and the phenomenon that the target model cannot converge or the convergence speed is too slow due to unsuitable super parameter setting value due to the limitation of artificial experience is avoided. On the other hand, the value of the target super-parameter is determined through the sampling sample of the target model and the optimized characteristic parameter, so that the matching degree of the target super-parameter and the actual application scene of the target model is improved while the accuracy of the target super-parameter value is ensured, meanwhile, the target value is determined based on the optimized characteristic parameter of the target model, and the target area is determined based on the condition that the optimized characteristic parameter is better when the target value is determined, so that the training efficiency of the target model is effectively improved, the iteration times of training the target model are reduced to a certain extent, and the convergence efficiency of the target model is improved.
Additional features and advantages of the present disclosure will be set forth in the detailed description which follows.
Drawings
The above and other features, advantages, and aspects of embodiments of the present disclosure will become more apparent by reference to the following detailed description when taken in conjunction with the accompanying drawings. The same or similar reference numbers will be used throughout the drawings to refer to the same or like elements. It should be understood that the figures are schematic and that elements and components are not necessarily drawn to scale. In the drawings:
FIG. 1 is a flow chart of a method of determining a hyper-parameter, provided in accordance with an embodiment of the present disclosure;
FIG. 2 is a flow chart of an exemplary implementation of updating state values corresponding to target hyper-parameters according to interaction samples provided in accordance with one embodiment of the present disclosure;
FIG. 3 is a flow chart of an exemplary implementation of determining a target region from a plurality of value regions based on status values corresponding to updated target hyper-parameters provided by one embodiment of the present disclosure;
FIG. 4 is a block diagram of a hyper-parameter determination apparatus provided in accordance with one embodiment of the disclosure;
fig. 5 shows a schematic structural diagram of an electronic device suitable for use in implementing embodiments of the present disclosure.
Detailed Description
Embodiments of the present disclosure will be described in more detail below with reference to the accompanying drawings. While certain embodiments of the present disclosure have been shown in the accompanying drawings, it is to be understood that the present disclosure may be embodied in various forms and should not be construed as limited to the embodiments set forth herein, but are provided to provide a more thorough and complete understanding of the present disclosure. It should be understood that the drawings and embodiments of the present disclosure are for illustration purposes only and are not intended to limit the scope of the present disclosure.
It should be understood that the various steps recited in the method embodiments of the present disclosure may be performed in a different order and/or performed in parallel. Furthermore, method embodiments may include additional steps and/or omit performing the illustrated steps. The scope of the present disclosure is not limited in this respect.
The term "including" and variations thereof as used herein are intended to be open-ended, i.e., including, but not limited to. The term "based on" is based at least in part on. The term "one embodiment" means "at least one embodiment"; the term "another embodiment" means "at least one additional embodiment"; the term "some embodiments" means "at least some embodiments. Related definitions of other terms will be given in the description below.
It should be noted that the terms "first," "second," and the like in this disclosure are merely used to distinguish between different devices, modules, or units and are not used to define an order or interdependence of functions performed by the devices, modules, or units.
It should be noted that references to "one", "a plurality" and "a plurality" in this disclosure are intended to be illustrative rather than limiting, and those of ordinary skill in the art will appreciate that "one or more" is intended to be understood as "one or more" unless the context clearly indicates otherwise.
The names of messages or information interacted between the various devices in the embodiments of the present disclosure are for illustrative purposes only and are not intended to limit the scope of such messages or information.
Fig. 1 is a flowchart of a method for determining a super parameter according to an embodiment of the disclosure, where the method may include:
in step 11, a sample corresponding to the sample value is obtained under the sample value of the target hyper-parameter of the target model.
The target model may be a deep reinforcement learning model, for example. The deep reinforcement learning model combines the perception capability of deep learning and the decision capability of reinforcement learning, and obtains a high-dimensional observation through agent interaction with the environment at each moment, and perceives the observation by using a deep learning method to obtain a specific state characteristic representation of the observation; the cost function (state value function) and the cost function (action value function) of the state-action pair of each state can then be evaluated based on the expected return, and the decision strategy is promoted based on the two cost functions, and is used for mapping the current state into the corresponding decision action; the environment will react to this decision action and get the next view. By continually cycling through the above processes, an optimal strategy is achieved that achieves the goal, which is, for example, the maximum cumulative return.
Therefore, in the application scenario, the sampling sample is an interaction sequence obtained by sampling in the process of interaction between a virtual object and a virtual environment, wherein the virtual object is controlled based on the deep reinforcement learning model, the interaction sequence comprises a plurality of sampling data under the sampling value, and each sampling data comprises an environment state of the virtual environment, a decision action of the execution of the virtual object under the environment state determined by the deep reinforcement learning model, and a return value corresponding to the decision action.
The virtual environment may be a virtual scene environment generated by a computer, for example, the virtual environment may be a game scene, and the multimedia data for interaction with a user is illustratively rendered and displayed as the game scene, the virtual environment provides a multimedia virtual world, the user can control actions of virtual objects through controls on an operation interface, or directly control the virtual objects operable in the virtual environment, and observe objects, characters, scenery and the like in the virtual environment from the view angle of the virtual objects, and interact with other virtual objects in the virtual environment through the virtual objects and the like. As another example, the virtual environment may also include other virtual objects in the scene, and so on. The virtual object may be an avatar in the virtual environment for simulating a user, which may be a human avatar or other animal avatar, etc.
As an example, the virtual object may perform a decision action in the first state of the virtual environment, and then after the virtual object performs the decision action, the virtual environment may react to the decision action to obtain the second state of the virtual environment and perform a return value corresponding to the decision action. When the virtual object is sampled in the process of interacting with the virtual environment, the first state, the decision action, the second state and the return value can be used as sampling data corresponding to the sampling time, and if not otherwise described, the environmental state in the sampling data in the embodiment of the disclosure is the first state in the sampling data. In a complete interaction process, the sampled data according to the sequence of the sampling time is formed into an interaction sequence. When sampling is performed, an image of a virtual environment corresponding to the sampling time can be acquired, so that feature extraction can be performed on the image to obtain the first state. After the virtual object performs the decision action, sampling an image of the acquired virtual environment and extracting features of the image to obtain a second state. The return value may be a change of a score value corresponding to the virtual object after the decision action is executed, or may be a change of a virtual life bar, etc., which may be set according to an actual use scenario, which is not limited in the present disclosure.
In step 12, an interaction sample corresponding to the target super parameter is generated according to the sampling sample, wherein the interaction sample comprises the sampling value and the optimized characteristic parameter corresponding to the target model.
The optimization feature parameter may be a cumulative return corresponding to the interaction sequence. As an example, the cumulative return may be a sum of return values for each decision action included in the interaction sequence. As another example, the more distant a decision action from a current decision action has less impact on the current decision action, the cumulative return may be a cumulative sum of products of return values of each decision action in the interaction sequence and decay coefficients corresponding to the decision action, where the decay coefficients corresponding to the decision actions decrease in a first-to-last order of the decision actions, for example:
G t =R t+1 +γR t+2 +γ 2 R t+3 +…+γ n-1 R t+n
=R t+1 +γ(R t+2 +γR t+3 +…+γ n-2 R t+n )
=R t+1 +γG t+1
wherein R is i The return value for the decision action at time i, gamma for the decay factor, and n for the number of sample data in the interaction sequence after time t to the end of the interaction.
Thus, in another embodiment, from the last decision action of the interaction sequence, its return value may be multiplied by the decay value and added to the return value of the previous decision action until added to the return value of the first decision action in the interaction sequence, resulting in the cumulative return. Wherein the attenuation value can be set according to the actual use scenario.
In step 13, updating the state value corresponding to the target hyper-parameter according to the interaction sample, wherein the parameter space of the target hyper-parameter is discretized into a plurality of valued areas.
Where in the art, the expected cumulative return for any policy pi can be estimated for that policy when the model is known, a state value function is typically used to evaluate the value of a state, where the value of a state can be expressed by the value of all actions in that state, i.e., based on the expected cumulative return available for state s, where the cumulative return obeys a distribution, and the expected value of the cumulative return at the state is defined as the state value function V(s):
V π (s)=E π [G t |S t =s]
i.e. the state S at time t under policy pi t When the value is s, the accumulated return G t The expected value at s. In this embodiment, the state value of all the valued areas in state s can be evaluated based on the state value function. The determination method of the cumulative report is described in detail above, and will not be described herein.
In the deep reinforcement learning model, the calculation of the state value function may be implemented through a neural network. Therefore, the environmental state in the sampled data can be input into the state value function network, so that the output value of the state value function network, namely, the state value of the state value function corresponding to the environmental state, can be obtained.
As an example, the parameter space of the target superparameter is discretized into a plurality of valued areas, and the state value corresponding to the target superparameter may be used to characterize the cumulative return brought by the target superparameter being further selected from the valued areas based on the policy in the state that the value of the target superparameter is the sampled value. For example, in the present disclosure, the state value corresponding to the target hyper-parameter may be determined by means of iterative update, that is, the state value corresponding to the target hyper-parameter is iteratively updated according to the sampled value corresponding to the interaction sample.
As an example, the number of the value-taking regions corresponding to the parameter space may be predetermined, and then the parameter space of the target super parameter may be uniformly divided to obtain a plurality of value-taking regions. If the parameter space of the target hyper-parameter is [0,9], and the parameter space is divided into 9 value areas, the value range corresponding to the value area A1 is [0,1 ], the value range corresponding to the value area A2 is [1,2 ], the value ranges corresponding to other value areas are the same, and so on, which are not described in detail herein. The state value corresponding to the target hyper-parameter can be represented by a vector, namely, the state value corresponding to each of the 9 valued areas is a dimension value in the vector.
In step 14, a target area is determined from the plurality of valued areas according to the state value corresponding to the updated target hyper-parameter.
In the step, the accumulated return of each value-taking area of the target super-parameter can be accurately evaluated according to the state value corresponding to the target super-parameter determined by the sampling sample of the target model, so that the target area for determining the value of the target super-parameter can be selected according to the evaluation result, the accuracy of the value of the target super-parameter is ensured, and the consistency of the value of the target super-parameter and the actual application process of the target model is ensured.
In step 15, a target value of the target super parameter is determined according to the target area.
As an embodiment, uniformly distributed sampling is performed in a value range corresponding to the target area, and a value obtained by sampling is determined as the target value.
Therefore, in the technical scheme, the parameter space of the target super-parameter is discretized into a plurality of value areas, so that the value of the target super-parameter can be determined based on the sampling sample corresponding to the target model using the target super-parameter and the optimized characteristic parameter of the target model. Therefore, through the technical scheme, on one hand, the value of the super parameter of the model can be accurately set, and the phenomenon that the target model cannot converge or the convergence speed is too slow due to unsuitable super parameter setting value due to the limitation of artificial experience is avoided. On the other hand, the value of the target super-parameter is determined through the sampling sample of the target model and the optimized characteristic parameter, so that the matching degree of the target super-parameter and the actual application scene of the target model is improved while the accuracy of the target super-parameter value is ensured, meanwhile, the target value is determined based on the optimized characteristic parameter of the target model, and the target area is determined based on the condition that the optimized characteristic parameter is better when the target value is determined, so that the training efficiency of the target model is effectively improved, the iteration times of training the target model are reduced to a certain extent, and the convergence efficiency of the target model is improved.
As described above, the virtual environment may be a game environment, and then the virtual object and the virtual environment may be sampled to obtain interaction data, and the deep reinforcement learning model may determine the value of the super parameter in the deep reinforcement learning model based on the above manner during the training process, so that the deep reinforcement learning model may obtain a greater return when determining the decision action of the virtual object, ensure the accuracy of the decision action of the virtual object, improve the accuracy of virtual character control, and also reduce the data amount and manpower required during the training process.
In one possible embodiment, the method may further comprise:
taking the target value as a new sampling value, and re-executing the step of obtaining the interactive sample corresponding to the target super-parameter under the sampling value of the target super-parameter of the target model until the step of determining the target value of the target super-parameter according to the target area is completed.
In this embodiment, after determining the target value of the target superparameter, the value of the target superparameter in the target model may be updated to the target value, so that steps 11 to 15 may be re-executed to further determine whether the target value is accurate for the interactive sample of the target superparameter under the target value, thereby implementing dynamic adjustment of the target superparameter value, and optimizing the optimized feature parameter corresponding to the target model, further improving the accuracy of the target superparameter value, and simultaneously ensuring convergence and accuracy of the target model, and improving training efficiency of the target model.
In one possible embodiment, in step 13, an exemplary implementation of updating the state value corresponding to the target hyper-parameter according to the interaction sample is as follows, as shown in fig. 2, and the step may include:
in step 21, a sampling area to which the sampling value belongs is determined according to the sampling value.
For example, the value-taking area to which the sampling value belongs may be determined based on the range length corresponding to each value-taking area, and the subscript i of the value-taking area to which the sampling value belongs may be determined by the following formula:
i=(min(max(x,l),r)-l)//acc
wherein x is used for representing the sampling value; l is used to represent the left boundary of the parameter space; r is used to represent the right boundary of the parameter space; the// is used to represent integer division symbols; acc is used to represent the range length of the valued area.
In step 22, the value area to be updated is determined according to the value area to which the sampling value belongs.
As an example, the value-taking area to which the sampling value belongs may be directly determined as the value-taking area to be updated; as another example, a value-taking area to which the sampling value belongs and a value-taking area within a preset range adjacent to the value-taking area to which the sampling value belongs may be determined as the value-taking area to be updated. The preset range may be the number information of the value-taking area, and the adjacent preset range may be used to represent the sum of the preset range on the left side of the current value-taking area and the preset range on the right side of the current value-taking area. For example, if the determined value area to which the sampling value belongs is A2 and the preset range is one value area, the value area A2, one value area A1 located on the left side of the value area A2, and one value area A3 located on the right side of the value area A3 may be determined as the value areas to be updated.
In step 23, the state value of the value area to be updated is updated according to the optimized feature parameters.
In this embodiment, the relationship between the sampled value and the parameter space may determine the value area to be updated corresponding to the sampled value, so that the state value of the value area to be updated may be updated, and the corresponding state values of other value areas except for the value area to be updated need not be updated, so that the accuracy of the state value corresponding to the target super parameter may be ensured, and data support may be provided for the subsequent accurate selection of the target area.
In a possible embodiment, the value area to which the sampling value belongs is determined as the value area to be updated, and in step 23, the state value of the value area to be updated may be updated according to the optimized feature parameter by the following formula:
wherein T is used to represent the optimization feature parameter, and T may be G if the optimization feature parameter is a cumulative return, i.e. the cumulative return is optimized in an increasing direction during optimization t If the optimized characteristic parameter is the targetError rate error of the model, i.e. the error rate is optimized in a decreasing direction when optimizing, then T may be-error; k(s) is used for indicating the hit times of the value-taking area s to be updated, namely, the times that the value of the target super parameter corresponding to the sampling sample belongs to the value-taking area s to be updated, V(s) is used for indicating the current state value of the value-taking area s to be updated, and V'(s) is used for indicating the state value of the value-taking area s to be updated after being updated.
In another possible embodiment, as in the above embodiment, the value-taking area to which the sampling value belongs and the value-taking area within a preset range adjacent to the value-taking area to which the sampling value belongs are determined as the value-taking area to be updated. Accordingly, in step 23, an exemplary implementation of updating the state value of the value area to be updated according to the optimized feature parameter is as follows, and the step may include:
and respectively updating the state value of each value area to be updated according to the optimized characteristic parameters and the state value of each value area to be updated.
For example, the state value V after the j-th value area to be updated is updated can be determined by the following formula j ’:
The width is used for representing the number of the value areas in the preset range; v (V) j The state value is used for representing the j-th value area to be updated; lr is used to represent the learning rate for status value update; i is used to represent the subscript of the value region to which the sample value belongs. As described above, the width is 1, the determined sampling value belongs to the value area A2, i.e. i=2, j may be 1,2,3, and the state values of the value areas A1, A2, A3 may be updated according to the state values of the value areas A1, A2, A3, respectively, so as to obtain V 1 ’、V 2 ’、V 3 ’。
In this embodiment, when updating the state value corresponding to the target hyper-parameter, the mutual influence between adjacent value-taking areas is considered, and the state value of the value-taking area to which the first value-taking area belongs and the state value of the adjacent value-taking area can be updated at the same time, so that errors caused by inaccurate calculation of a single value-taking area can be effectively avoided, and the influence on optimization of the target model is avoided.
In one possible implementation manner, in step 14, according to the state value corresponding to the updated target hyper-parameter, an exemplary implementation manner of determining the target area from the multiple valued areas is as follows, as shown in fig. 3, and the step may include:
in step 31, a target score of each value area is determined according to the state value corresponding to the updated target hyper-parameter, where the target score is used to characterize the reliability of selecting the value area.
In a possible embodiment, an exemplary implementation manner of determining the target score of each value area according to the updated state value corresponding to the target hyper-parameter is as follows, and the step may include:
and in the updated state value corresponding to the target super-parameter, determining, for each value-taking area, an average value of the state values of the value-taking areas in a preset range adjacent to the value-taking area as a value score of the value-taking area, and determining the value score as a target score.
For example, as described above, the state value of the region to be updated may be updated in step 13 to implement the update of the state value corresponding to the target hyper-parameter. Illustratively, the state value corresponding to the updated target hyper-parameter is expressed as { V } 1 ’,V 2 ’,…,V N ' where N is the total number of valued areas.
Accordingly, the value score S of the value region i (i=1, 2, …, N) can be determined by the following formula i :
In order to improve efficiency of the superparameter value determination, when the number of the interaction samples reaches a preset threshold, a step of updating the state value corresponding to the target superparameter according to the interaction samples may be performed for each interaction sample, where the target superparameter corresponding to each interaction sample is valued in different valued areas. The state value corresponding to the target hyper-parameter can be updated based on a plurality of interaction samples at the same time, and the updating mode based on each interaction sample is the same as that described above, and is not repeated here.
In this embodiment, after the state value corresponding to the target hyper-parameter is updated, the score corresponding to each value-taking area may be recalculated, and meanwhile, when the target score of the value-taking area is determined, the value score of the value-taking area may be determined by combining the state values of the adjacent value-taking areas, so that the accuracy of the score of each value-taking area may be ensured, and meanwhile, smooth correlation between the scores of a plurality of value-taking areas may be ensured, and accurate data support may be provided for determining the target area.
In another possible embodiment, an exemplary implementation manner of determining the target score of each value area according to the updated state value corresponding to the target hyper-parameter is as follows, and the step may include:
and determining the average value of the state values of the value areas in a preset range adjacent to the value area as the value score of the value area for each value area in the updated state value corresponding to the target super-parameter. Wherein the manner in which the value score is determined is detailed above.
And then, determining the target score of each value area according to the value score of the value area and the hit times of the value area aiming at each value area.
For example, the target Score of the value region i may be determined by the following formula i :
Wherein c is a preset constant for adjusting the influence of hit times on the target score, and Mi is the hit times of the value area i.
As described above, in the embodiment of the present disclosure, the state value of the value-taking area may be determined by the iterative updating manner, the state value of each value-taking area is initially 0, and for each value-taking area, after the value-taking area to be updated is determined according to the sampling value of the target super parameter, the state values of the corresponding value-taking areas to be updated are updated, and the state values of the other value-taking areas except for the value-taking area to be updated are kept unchanged. Thus, in this embodiment, in order to increase the diversity of target region selection in the initial training process, the number of hits of the value region needs to be considered at the same time when determining the score of the value region, so as to reduce the influence degree of the value of the history hit on the selection of the target region. According to the method, in the process, as the interactive samples are increased, the state value corresponding to the target superparameter is more accurate, and as the hit times are increased, the influence of the hit times on the target score is gradually reduced, so that the diversity and the exploration space of target area selection can be improved in the initial learning stage, the accuracy of the determined target value is improved to a certain extent, the overlarge influence of random samples in the initial state is avoided, and when the state value is accurate, the influence of the hit times on the target area selection is reduced, and the forward optimization adjustment of the target area selection on the optimized characteristic parameters is ensured.
In another embodiment, the target Score of the valued area i may be determined by the following formula i :
Wherein μ ({ V) j '} j=1,2,...,(r-l)//acc ) Sum sigma ({ V) j '} j=1,2,...,(r-l)//acc ) Respectively are provided withAnd (3) representing the mean value and standard deviation corresponding to the state value of each updated value area, namely carrying out normalization processing on the value score of each value area through the formula so as to balance the influence of the value score and hit times on the target score.
Turning back to fig. 3, in step 32, a target region is determined from the plurality of value regions based on the target score for each value region.
In one possible embodiment, the step of determining the target area from the plurality of value areas according to the target score of each value area may include:
and determining the value area with the maximum target score as the target area.
In the embodiment of the disclosure, the value area with the largest target score can be directly selected as the target area, so that effective adjustment of the target value determined from the target area on optimization of the target model can be effectively ensured, and the efficiency of optimization of the target model is improved.
In another possible embodiment, the step of determining the target area from the plurality of value areas according to the target score of each value area may include:
And carrying out softmax processing on target scores corresponding to the multiple value areas to obtain probability distribution formed by probability information of the multiple value areas, sampling the multiple value areas according to the probability distribution, and determining the value areas obtained by sampling as the target areas.
In this embodiment, in order to further improve the diversity of target hyper-parameter value exploration, the state value of each value region may be mapped based on a softmax function, so as to map the state value to a value in a range of 0-1, and the value is used as probability information of the value region, so as to obtain probability distribution of the multiple value regions. When sampling is performed based on probability distribution, the sampling possibility exists in the value-taking area with smaller probability information, so that the sampling possibility exists in a plurality of value-taking areas to a certain extent, the problem that the determined target area is the parameter which enables the feature optimization parameter to be in the local optimum is avoided, the training of the target model is prevented from being stopped due to the fact that the training of the target model reaches the local optimum, and the accuracy and the robustness of the training of the target model can be guaranteed.
The disclosure also provides a deep reinforcement learning framework, wherein the value of the super parameter in the deep reinforcement learning framework is determined based on the super parameter determination method. By way of example, the game artificial intelligence can be trained based on the deep reinforcement learning framework, so that through the technical scheme, the accuracy of the determined decision of the game artificial intelligence can be ensured, the decision making capability of the game artificial intelligence is improved when the game artificial intelligence interacts with a user, and the user interaction experience is improved.
The present disclosure also provides a super parameter determining apparatus, as shown in fig. 4, the apparatus 10 includes:
the acquisition module 100 is configured to acquire a sample corresponding to a sampling value of a target super parameter of a target model under the sampling value;
the generating module 200 is configured to generate an interaction sample corresponding to the target super parameter according to the sampling sample, where the interaction sample includes the sampling value and an optimized feature parameter corresponding to the target model;
the updating module 300 is configured to update the state value corresponding to the target hyper-parameter according to the interaction sample, where the parameter space of the target hyper-parameter is discretized into a plurality of valued areas;
a first determining module 400, configured to determine a target area from the multiple valued areas according to the updated state value corresponding to the target hyper-parameter;
and the second determining module 500 is configured to determine a target value of the target super parameter according to the target area.
Optionally, the apparatus further comprises:
the trigger module is used for taking the target value as a new sampling value, triggering the acquisition module to acquire a sampling sample corresponding to the sampling value under the sampling value of the target super-parameter of the target model, generating an interaction sample corresponding to the target super-parameter by the generation module according to the sampling sample, updating the state value corresponding to the target super-parameter by the updating module according to the interaction sample, determining a target area from the plurality of value areas by the first determination module according to the updated state value corresponding to the target super-parameter, and determining the target value of the target super-parameter by the second determination module according to the target area until the training of the target model is completed.
Optionally, the updating module includes:
the first determining submodule is used for determining a value area to which the sampling value belongs according to the sampling value;
the second determining submodule is used for determining a value area to be updated according to the value area to which the sampling value belongs;
and the updating sub-module is used for updating the state value of the value area to be updated according to the optimized characteristic parameters.
Optionally, the second determining submodule includes:
a third determining submodule, configured to determine, as the value-taking area to be updated, a value-taking area to which the sampling value-taking area belongs and a value-taking area in a preset range adjacent to the value-taking area to which the sampling value-taking area belongs;
the updating sub-module is used for updating the state value of each value area to be updated according to the optimized characteristic parameters and the state value of each value area to be updated.
Optionally, the first determining module includes:
a fourth determining submodule, configured to determine a target score of each value area according to the updated state value corresponding to the target hyper-parameter;
and a fifth determining submodule, configured to determine a target area from the plurality of value areas according to the target score of each value area.
Optionally, the fourth determining submodule includes:
a sixth determining submodule, configured to determine, for each of the value areas, an average value of the state values of the value areas in a preset range adjacent to the value area as a value score of the value area, in the state values corresponding to the updated target super-parameter;
a seventh determining submodule, configured to determine, for each of the value areas, a target score of the value area according to a value score of the value area and a hit number of the value area.
Optionally, the fifth determining submodule includes:
an eighth determining submodule, configured to determine a value area with a maximum target score as the target area; or alternatively
And a ninth determining submodule, configured to perform softmax processing on the target scores of the multiple value areas, obtain probability distribution formed by probability information of each value area, sample the multiple value areas according to the probability distribution, and determine the value area obtained by sampling as the target area.
Optionally, the target model is a deep reinforcement learning model, the sampling sample is an interaction sequence obtained by sampling in the process that a virtual object interacts with a virtual environment, the virtual object is controlled based on the deep reinforcement learning model, the interaction sequence includes a plurality of sampling data under the sampling value, each sampling data includes an environmental state of the virtual environment, a decision action of execution of the virtual object determined by the deep reinforcement learning model under the environmental state, and a return value corresponding to the decision action, and the optimized feature parameter is an accumulated return corresponding to the interaction sequence.
Referring now to fig. 5, a schematic diagram of an electronic device 600 suitable for use in implementing embodiments of the present disclosure is shown. The terminal devices in the embodiments of the present disclosure may include, but are not limited to, mobile terminals such as mobile phones, notebook computers, digital broadcast receivers, PDAs (personal digital assistants), PADs (tablet computers), PMPs (portable multimedia players), in-vehicle terminals (e.g., in-vehicle navigation terminals), and the like, and stationary terminals such as digital TVs, desktop computers, and the like. The electronic device shown in fig. 5 is merely an example and should not be construed to limit the functionality and scope of use of the disclosed embodiments.
As shown in fig. 5, the electronic device 600 may include a processing means (e.g., a central processing unit, a graphics processor, etc.) 601, which may perform various appropriate actions and processes according to a program stored in a Read Only Memory (ROM) 602 or a program loaded from a storage means 608 into a Random Access Memory (RAM) 603. In the RAM 603, various programs and data required for the operation of the electronic apparatus 600 are also stored. The processing device 601, the ROM 602, and the RAM 603 are connected to each other through a bus 604. An input/output (I/O) interface 605 is also connected to bus 604.
In general, the following devices may be connected to the I/O interface 605: input devices 606 including, for example, a touch screen, touchpad, keyboard, mouse, camera, microphone, accelerometer, gyroscope, and the like; an output device 607 including, for example, a Liquid Crystal Display (LCD), a speaker, a vibrator, and the like; storage 608 including, for example, magnetic tape, hard disk, etc.; and a communication device 609. The communication means 609 may allow the electronic device 600 to communicate with other devices wirelessly or by wire to exchange data. While fig. 5 shows an electronic device 600 having various means, it is to be understood that not all of the illustrated means are required to be implemented or provided. More or fewer devices may be implemented or provided instead.
In particular, according to embodiments of the present disclosure, the processes described above with reference to flowcharts may be implemented as computer software programs. For example, embodiments of the present disclosure include a computer program product comprising a computer program embodied on a non-transitory computer readable medium, the computer program comprising program code for performing the method shown in the flow chart. In such an embodiment, the computer program may be downloaded and installed from a network via communication means 609, or from storage means 608, or from ROM 602. The above-described functions defined in the methods of the embodiments of the present disclosure are performed when the computer program is executed by the processing device 601.
It should be noted that the computer readable medium described in the present disclosure may be a computer readable signal medium or a computer readable storage medium, or any combination of the two. The computer readable storage medium can be, for example, but not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or a combination of any of the foregoing. More specific examples of the computer-readable storage medium may include, but are not limited to: an electrical connection having one or more wires, a portable computer diskette, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing. In the context of this disclosure, a computer-readable storage medium may be any tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device. In the present disclosure, however, the computer-readable signal medium may include a data signal propagated in baseband or as part of a carrier wave, with the computer-readable program code embodied therein. Such a propagated data signal may take any of a variety of forms, including, but not limited to, electro-magnetic, optical, or any suitable combination of the foregoing. A computer readable signal medium may also be any computer readable medium that is not a computer readable storage medium and that can communicate, propagate, or transport a program for use by or in connection with an instruction execution system, apparatus, or device. Program code embodied on a computer readable medium may be transmitted using any appropriate medium, including but not limited to: electrical wires, fiber optic cables, RF (radio frequency), and the like, or any suitable combination of the foregoing.
In some implementations, the clients, servers may communicate using any currently known or future developed network protocol, such as HTTP (HyperText Transfer Protocol ), and may be interconnected with any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include a local area network ("LAN"), a wide area network ("WAN"), the internet (e.g., the internet), and peer-to-peer networks (e.g., ad hoc peer-to-peer networks), as well as any currently known or future developed networks.
The computer readable medium may be contained in the electronic device; or may exist alone without being incorporated into the electronic device.
The computer readable medium carries one or more programs which, when executed by the electronic device, cause the electronic device to: acquiring a sampling sample corresponding to a sampling value under the sampling value of a target super parameter of a target model; generating an interaction sample corresponding to the target super-parameter according to the sampling sample, wherein the interaction sample comprises the sampling value and an optimization characteristic parameter corresponding to the target model; updating the state value corresponding to the target super-parameter according to the interaction sample, wherein the parameter space of the target super-parameter is discretized into a plurality of valued areas; determining a target area from the plurality of valued areas according to the updated state value corresponding to the target super parameter; and determining the target value of the target hyper-parameter according to the target area.
Computer program code for carrying out operations of the present disclosure may be written in one or more programming languages, including, but not limited to, an object oriented programming language such as Java, smalltalk, C ++ and conventional procedural programming languages, such as the "C" programming language or similar programming languages. The program code may execute entirely on the user's computer, partly on the user's computer, as a stand-alone software package, partly on the user's computer and partly on a remote computer or entirely on the remote computer or server. In the case of a remote computer, the remote computer may be connected to the user's computer through any kind of network, including a Local Area Network (LAN) or a Wide Area Network (WAN), or may be connected to an external computer (for example, through the Internet using an Internet service provider).
The flowcharts and block diagrams in the figures illustrate the architecture, functionality, and operation of possible implementations of systems, methods and computer program products according to various embodiments of the present disclosure. In this regard, each block in the flowchart or block diagrams may represent a module, segment, or portion of code, which comprises one or more executable instructions for implementing the specified logical function(s). It should also be noted that, in some alternative implementations, the functions noted in the block may occur out of the order noted in the figures. For example, two blocks shown in succession may, in fact, be executed substantially concurrently, or the blocks may sometimes be executed in the reverse order, depending upon the functionality involved. It will also be noted that each block of the block diagrams and/or flowchart illustration, and combinations of blocks in the block diagrams and/or flowchart illustration, can be implemented by special purpose hardware-based systems which perform the specified functions or acts, or combinations of special purpose hardware and computer instructions.
The modules described in the embodiments of the present disclosure may be implemented in software or hardware. The name of a module is not limited to this module, and for example, the acquisition module may also be described as "a module that acquires a sample corresponding to a sampling value of a target hyper-parameter of a target model" under the sampling value.
The functions described above herein may be performed, at least in part, by one or more hardware logic components. For example, without limitation, exemplary types of hardware logic components that may be used include: a Field Programmable Gate Array (FPGA), an Application Specific Integrated Circuit (ASIC), an Application Specific Standard Product (ASSP), a system on a chip (SOC), a Complex Programmable Logic Device (CPLD), and the like.
In the context of this disclosure, a machine-readable medium may be a tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device. The machine-readable medium may be a machine-readable signal medium or a machine-readable storage medium. The machine-readable medium may include, but is not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any suitable combination of the foregoing. More specific examples of a machine-readable storage medium would include an electrical connection based on one or more wires, a portable computer diskette, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.
According to one or more embodiments of the present disclosure, example 1 provides a hyper-parameter determination method, wherein the method comprises:
acquiring a sampling sample corresponding to a sampling value under the sampling value of a target super parameter of a target model;
generating an interaction sample corresponding to the target super-parameter according to the sampling sample, wherein the interaction sample comprises the sampling value and an optimization characteristic parameter corresponding to the target model;
updating the state value corresponding to the target super-parameter according to the interaction sample, wherein the parameter space of the target super-parameter is discretized into a plurality of valued areas;
determining a target area from the plurality of valued areas according to the updated state value corresponding to the target super parameter;
and determining the target value of the target hyper-parameter according to the target area.
According to one or more embodiments of the present disclosure, example 2 provides the method of example 1, wherein the method further comprises:
taking the target value as a new sampling value, and re-executing the step of obtaining the interactive sample corresponding to the target super-parameter under the sampling value of the target super-parameter of the target model until the step of determining the target value of the target super-parameter according to the target area is completed.
According to one or more embodiments of the present disclosure, example 3 provides the method of example 1, wherein the updating, according to the interaction sample, the state value corresponding to the target hyper-parameter includes:
determining a value area to which the sampling value belongs according to the sampling value;
determining a value area to be updated according to the value area to which the sampling value belongs;
and updating the state value of the value area to be updated according to the optimized characteristic parameters.
According to one or more embodiments of the present disclosure, example 4 provides the method of example 3, wherein the determining the value area to be updated according to the value area to which the sampling value belongs includes:
determining a value-taking area to which the sampling value belongs and a value-taking area in a preset range adjacent to the value-taking area to which the sampling value belongs as the value-taking area to be updated;
the updating the state value of the to-be-updated value area according to the optimized characteristic parameters comprises the following steps:
and respectively updating the state value of each value area to be updated according to the optimized characteristic parameters and the state value of each value area to be updated.
According to one or more embodiments of the present disclosure, example 5 provides the method of example 1, wherein the determining, according to the updated state value corresponding to the target hyper-parameter, the target area from the plurality of valued areas includes:
determining the target score of each value area according to the updated state value corresponding to the target hyper-parameter;
and determining a target area from the plurality of value areas according to the target score of each value area.
According to one or more embodiments of the present disclosure, example 6 provides the method of example 5, wherein the determining the target score of each of the valued areas according to the updated state value corresponding to the target hyper-parameter includes:
in the updated state value corresponding to the target super-parameter, determining, for each value-taking area, an average value of the state values of the value-taking areas in a preset range adjacent to the value-taking area as a value score of the value-taking area;
and determining the target score of each value area according to the value score of the value area and the hit times of the value area aiming at each value area.
According to one or more embodiments of the present disclosure, example 7 provides the method of example 5, wherein the determining a target region from the plurality of value regions according to the target score of each of the value regions comprises:
determining a value area with the maximum target score as the target area;
or alternatively
And carrying out softmax processing on the target scores of the plurality of value areas to obtain probability distribution formed by probability information of each value area, sampling the plurality of value areas according to the probability distribution, and determining the value area obtained by sampling as the target area.
According to one or more embodiments of the present disclosure, example 8 provides the method of example 1, wherein the target model is a deep reinforcement learning model, the sampling sample is an interaction sequence obtained by sampling during interaction of a virtual object with a virtual environment, wherein the virtual object is controlled based on the deep reinforcement learning model, the interaction sequence includes a plurality of sampling data under the sampling value, each of the sampling data includes an environmental state of the virtual environment, a decision action of execution of the virtual object under the environmental state determined by the deep reinforcement learning model, and a return value corresponding to the decision action, and the optimized feature parameter is an accumulated return corresponding to the interaction sequence.
According to one or more embodiments of the present disclosure, example 9 provides a super parameter determination apparatus, wherein the apparatus comprises:
the acquisition module is used for acquiring a sampling sample corresponding to the sampling value under the sampling value of the target super parameter of the target model;
the generation module is used for generating an interaction sample corresponding to the target super-parameter according to the sampling sample, wherein the interaction sample comprises the sampling value and an optimization characteristic parameter corresponding to the target model;
the updating module is used for updating the state value corresponding to the target super-parameter according to the interaction sample, wherein the parameter space of the target super-parameter is discretized into a plurality of valued areas;
the first determining module is used for determining a target area from the plurality of valued areas according to the updated state value corresponding to the target super parameter;
and the second determining module is used for determining the target value of the target super-parameter according to the target area.
In accordance with one or more embodiments of the present disclosure, example 10 provides a deep reinforcement learning framework in which the values of the superparameters are determined based on the superparameter determining method of any one of examples 1-8.
According to one or more embodiments of the present disclosure, example 11 provides a computer-readable medium having stored thereon a computer program which, when executed by a processing device, implements the steps of the method of any of examples 1-8.
Example 12 provides an electronic device according to one or more embodiments of the present disclosure, comprising:
a storage device having a computer program stored thereon;
processing means for executing the computer program in the storage means to implement the steps of the method of any one of examples 1-8.
The foregoing description is only of the preferred embodiments of the present disclosure and description of the principles of the technology being employed. It will be appreciated by persons skilled in the art that the scope of the disclosure referred to in this disclosure is not limited to the specific combinations of features described above, but also covers other embodiments which may be formed by any combination of features described above or equivalents thereof without departing from the spirit of the disclosure. Such as those described above, are mutually substituted with the technical features having similar functions disclosed in the present disclosure (but not limited thereto).
Moreover, although operations are depicted in a particular order, this should not be understood as requiring that such operations be performed in the particular order shown or in sequential order. In certain circumstances, multitasking and parallel processing may be advantageous. Likewise, while several specific implementation details are included in the above discussion, these should not be construed as limiting the scope of the present disclosure. Certain features that are described in the context of separate embodiments can also be implemented in combination in a single embodiment. Conversely, various features that are described in the context of a single embodiment can also be implemented in multiple embodiments separately or in any suitable subcombination.
Although the subject matter has been described in language specific to structural features and/or methodological acts, it is to be understood that the subject matter defined in the appended claims is not necessarily limited to the specific features or acts described above. Rather, the specific features and acts described above are example forms of implementing the claims. The specific manner in which the various modules perform the operations in the apparatus of the above embodiments have been described in detail in connection with the embodiments of the method, and will not be described in detail herein.
Claims (12)
1. A method of determining a hyper-parameter, the method comprising:
acquiring a sampling sample corresponding to a sampling value under the sampling value of a target super parameter of a target model, wherein the sampling sample is an interaction sequence obtained by sampling in the process of interacting a virtual object with a virtual environment, the virtual environment is used for representing a virtual scene environment generated by rendering multimedia data for interacting with a user, the virtual object is controlled based on the target model, the interaction sequence comprises a plurality of sampling data under the sampling value, each sampling data comprises an environment state of the virtual environment, a decision action of executing the virtual object under the environment state determined by the target model and a return value corresponding to the decision action;
Generating an interaction sample corresponding to the target super-parameter according to the sampling sample, wherein the interaction sample comprises the sampling value and an optimization characteristic parameter corresponding to the target model, and the optimization characteristic parameter is accumulated return corresponding to the interaction sequence;
updating the state value corresponding to the target super-parameter according to the interaction sample, wherein the parameter space of the target super-parameter is discretized into a plurality of valued areas;
determining a target area from the plurality of valued areas according to the updated state value corresponding to the target super parameter;
and determining the target value of the target hyper-parameter according to the target area.
2. The method according to claim 1, wherein the method further comprises:
taking the target value as a new sampling value, and re-executing the step of obtaining a sampling sample corresponding to the sampling value under the sampling value of the target super-parameter of the target model until the step of determining the target value of the target super-parameter according to the target area is completed, until the training of the target model is completed.
3. The method according to claim 1, wherein updating the state value corresponding to the target hyper-parameter according to the interaction sample comprises:
Determining a value area to which the sampling value belongs according to the sampling value;
determining a value area to be updated according to the value area to which the sampling value belongs;
and updating the state value of the value area to be updated according to the optimized characteristic parameters.
4. A method according to claim 3, wherein the determining the region to be updated according to the region to which the sample value belongs comprises:
determining a value-taking area to which the sampling value belongs and a value-taking area in a preset range adjacent to the value-taking area to which the sampling value belongs as the value-taking area to be updated;
the updating the state value of the to-be-updated value area according to the optimized characteristic parameters comprises the following steps:
and respectively updating the state value of each value area to be updated according to the optimized characteristic parameters and the state value of each value area to be updated.
5. The method according to claim 1, wherein determining the target area from the plurality of valued areas according to the updated state value corresponding to the target hyper-parameter comprises:
determining the target score of each value area according to the updated state value corresponding to the target hyper-parameter;
And determining a target area from the plurality of value areas according to the target score of each value area.
6. The method according to claim 5, wherein determining the target score of each of the valued areas according to the updated state value corresponding to the target hyper-parameter comprises:
in the updated state value corresponding to the target super-parameter, determining, for each value-taking area, an average value of the state values of the value-taking areas in a preset range adjacent to the value-taking area as a value score of the value-taking area;
and determining the target score of each value area according to the value score of the value area and the hit times of the value area aiming at each value area.
7. The method of claim 5, wherein determining a target region from the plurality of target regions based on the target score for each of the target regions comprises:
determining a value area with the maximum target score as the target area;
or alternatively
And carrying out softmax processing on the target scores of the plurality of value areas to obtain probability distribution formed by probability information of each value area, sampling the plurality of value areas according to the probability distribution, and determining the value area obtained by sampling as the target area.
8. The method of claim 1, wherein the target model is a deep reinforcement learning model.
9. A hyper-parameter determination apparatus, the apparatus comprising:
the system comprises an acquisition module, a processing module and a processing module, wherein the acquisition module is used for acquiring a sampling sample corresponding to a sampling value under the sampling value of a target super parameter of a target model, the sampling sample is an interaction sequence obtained by sampling in the process of interacting a virtual object with a virtual environment, the virtual environment is used for representing a virtual scene environment generated by rendering multimedia data for interacting with a user, the virtual object is controlled based on the target model, the interaction sequence comprises a plurality of sampling data under the sampling value, each sampling data comprises an environment state of the virtual environment, a decision action of executing the virtual object under the environment state determined by the target model and a return value corresponding to the decision action;
the generation module is used for generating an interaction sample corresponding to the target super-parameter according to the sampling sample, wherein the interaction sample comprises the sampling value and an optimization characteristic parameter corresponding to the target model, and the optimization characteristic parameter is accumulated return corresponding to the interaction sequence;
The updating module is used for updating the state value corresponding to the target super-parameter according to the interaction sample, wherein the parameter space of the target super-parameter is discretized into a plurality of valued areas;
the first determining module is used for determining a target area from the plurality of valued areas according to the updated state value corresponding to the target super parameter;
and the second determining module is used for determining the target value of the target super-parameter according to the target area.
10. A deep reinforcement learning method, wherein the value of the super parameter in the deep reinforcement learning method is determined based on the super parameter determination method according to any one of claims 1 to 8.
11. A computer readable medium on which a computer program is stored, characterized in that the program, when being executed by a processing device, carries out the steps of the method according to any one of claims 1-8.
12. An electronic device, comprising:
a storage device having a computer program stored thereon;
processing means for executing said computer program in said storage means to carry out the steps of the method according to any one of claims 1-8.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202110129788.6A CN112926629B (en) | 2021-01-29 | 2021-01-29 | Super-parameter determination method, device, deep reinforcement learning framework, medium and equipment |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202110129788.6A CN112926629B (en) | 2021-01-29 | 2021-01-29 | Super-parameter determination method, device, deep reinforcement learning framework, medium and equipment |
Publications (2)
Publication Number | Publication Date |
---|---|
CN112926629A CN112926629A (en) | 2021-06-08 |
CN112926629B true CN112926629B (en) | 2024-04-02 |
Family
ID=76168816
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202110129788.6A Active CN112926629B (en) | 2021-01-29 | 2021-01-29 | Super-parameter determination method, device, deep reinforcement learning framework, medium and equipment |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN112926629B (en) |
Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN109711548A (en) * | 2018-12-26 | 2019-05-03 | 歌尔股份有限公司 | Choosing method, application method, device and the electronic equipment of hyper parameter |
JP2019087096A (en) * | 2017-11-08 | 2019-06-06 | 本田技研工業株式会社 | Action determination system and automatic driving control device |
CN110659738A (en) * | 2019-09-12 | 2020-01-07 | 苏州浪潮智能科技有限公司 | Method and device for adjusting hyper-parameters and computer readable storage medium |
CN111260762A (en) * | 2020-01-19 | 2020-06-09 | 腾讯科技(深圳)有限公司 | Animation implementation method and device, electronic equipment and storage medium |
KR20200105365A (en) * | 2019-06-05 | 2020-09-07 | 아이덴티파이 주식회사 | Method for reinforcement learning using virtual environment generated by deep learning |
Family Cites Families (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US11616813B2 (en) * | 2018-08-31 | 2023-03-28 | Microsoft Technology Licensing, Llc | Secure exploration for reinforcement learning |
-
2021
- 2021-01-29 CN CN202110129788.6A patent/CN112926629B/en active Active
Patent Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2019087096A (en) * | 2017-11-08 | 2019-06-06 | 本田技研工業株式会社 | Action determination system and automatic driving control device |
CN109711548A (en) * | 2018-12-26 | 2019-05-03 | 歌尔股份有限公司 | Choosing method, application method, device and the electronic equipment of hyper parameter |
KR20200105365A (en) * | 2019-06-05 | 2020-09-07 | 아이덴티파이 주식회사 | Method for reinforcement learning using virtual environment generated by deep learning |
CN110659738A (en) * | 2019-09-12 | 2020-01-07 | 苏州浪潮智能科技有限公司 | Method and device for adjusting hyper-parameters and computer readable storage medium |
CN111260762A (en) * | 2020-01-19 | 2020-06-09 | 腾讯科技(深圳)有限公司 | Animation implementation method and device, electronic equipment and storage medium |
Non-Patent Citations (1)
Title |
---|
采用双经验回放池的噪声流双延迟深度确定性策略梯度算法;王垚儒;李俊;;武汉科技大学学报(02) * |
Also Published As
Publication number | Publication date |
---|---|
CN112926629A (en) | 2021-06-08 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN112766497B (en) | Training method, device, medium and equipment for deep reinforcement learning model | |
CN110413812B (en) | Neural network model training method and device, electronic equipment and storage medium | |
CN113052253B (en) | Super-parameter determination method, device, deep reinforcement learning framework, medium and equipment | |
CN113177888A (en) | Hyper-resolution restoration network model generation method, image hyper-resolution restoration method and device | |
CN113190872B (en) | Data protection method, network structure training method, device, medium and equipment | |
CN112926628B (en) | Action value determining method and device, learning framework, medium and equipment | |
CN112949850B (en) | Super-parameter determination method, device, deep reinforcement learning framework, medium and equipment | |
CN110555861A (en) | optical flow calculation method and device and electronic equipment | |
CN112926629B (en) | Super-parameter determination method, device, deep reinforcement learning framework, medium and equipment | |
CN113052312B (en) | Training method and device of deep reinforcement learning model, medium and electronic equipment | |
CN113052252B (en) | Super-parameter determination method, device, deep reinforcement learning framework, medium and equipment | |
CN117351299A (en) | Image generation and model training method, device, equipment and storage medium | |
CN113052248B (en) | Super-parameter determination method, device, deep reinforcement learning framework, medium and equipment | |
CN112926735B (en) | Method, device, framework, medium and equipment for updating deep reinforcement learning model | |
CN112766190B (en) | Method and device for generating countermeasure sample, storage medium and electronic equipment | |
CN116188251A (en) | Model construction method, virtual image generation method, device, equipment and medium | |
CN115879525A (en) | Neural network model quantification method and device, storage medium and electronic device | |
CN111738415B (en) | Model synchronous updating method and device and electronic equipment | |
CN111582456B (en) | Method, apparatus, device and medium for generating network model information | |
CN112465717B (en) | Face image processing model training method, device, electronic equipment and medium | |
CN111443806A (en) | Interactive task control method and device, electronic equipment and storage medium | |
US20240371092A1 (en) | Method, apparatus and electronic device for hand three-dimensional reconstruction | |
CN112395826B (en) | Text special effect processing method and device | |
CN116688490A (en) | Scene feature extraction method and device, medium and electronic equipment | |
CN117648241A (en) | Special effect model processing method and device, electronic equipment, storage medium and product |
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 |