Parameter optimization method, electronic device, storage medium and chip
By generating Pareto curves to determine parameter configurations that meet user needs, the problem of low parameter optimization efficiency in the existing technology is solved and efficient parameter optimization is achieved.
Patent Information
- Application Number
- CN202410405834.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-04-07
- Publication Date
- 2024-09-20
- Estimated Expiration
- 2044-04-07
AI Technical Summary
The existing technology is inefficient in the parameter optimization process and requires testing all feasible parameter combinations one by one, resulting in low processing efficiency.
By obtaining the initial data set, using optimization algorithms to process each sample, generate a Pareto curve, determine the parameter configuration that meets user needs, and avoid testing one by one.
The efficiency and accuracy of the parameter optimization method are improved, the calculation process is simplified, and resources are saved.
Smart Images

Figure CN118093199B
Abstract
Description
Technical Field
[0001] The present application relates to the field of data processing technology, and more specifically, to a parameter optimization method, electronic device, storage medium and chip. Background Art
[0002] Before running an application, the electronic device needs to configure some system configuration parameters (for example, parameters that affect the operating frequency of the electronic device's central processing unit (CPU) and parameters that affect task core selection, etc.). Afterwards, the electronic device can run the application according to the pre-configured system configuration parameters.
[0003] If the parameter values of the above configuration parameters are not configured properly, the application's running effect (for example, performance and power consumption) will be poor, resulting in a poor user experience. In some scenarios, due to the large number of configuration parameters to be optimized and the large number of optimization targets, in order to find the optimal parameter configuration that meets the user's optimization target requirements, it is necessary to conduct experimental tests on all possible parameter combinations one by one. Afterwards, the optimal parameter configuration that meets the user's optimization target requirements is selected from a large number of experimental test results. This process has the problem of low processing efficiency.
[0004] Therefore, how to improve the efficiency of parameter optimization methods has become a problem that needs to be solved urgently. Summary of the invention
[0005] The present application provides a parameter optimization method, an electronic device, a storage medium and a chip, which can improve the efficiency of the parameter optimization method.
[0006] In a first aspect, a parameter optimization method is provided, which is applied to a first electronic device, the method comprising: obtaining an initial data set, wherein the initial data set comprises at least one sample, each sample in the at least one sample comprises M first parameter values corresponding to M configuration parameters one by one and N first result values corresponding to N optimization targets one by one, the first result value of each optimization target is obtained when the M configuration parameters are configured as the M first parameter values, and M and N are positive integers greater than 1; for each optimization target, processing at least one sample according to an optimization algorithm to obtain an objective function of each optimization target, so as to obtain N objective functions corresponding to the N optimization targets one by one, wherein each optimization target The objective function represents a function with M configuration parameters as independent variables and each optimization objective as a dependent variable; based on the N objective functions, a Pareto curve is generated, wherein the Pareto curve is used to represent multiple groups of mapping relationships between the N optimization objectives under multiple groups of parameter values determined based on the N objective functions, and there is a group of mapping relationships between the N optimization objectives under a group of parameter values; based on the Pareto curve and the N result range values that correspond one-to-one to the N optimization objectives that meet the requirements, M second parameter values that correspond one-to-one to the M configuration parameters are obtained, wherein, when the M configuration parameters are configured as the M second parameter values, the result value of each of the N optimization objectives is within the result range value of each optimization objective.
[0007] Each of the at least one sample includes M first parameter values corresponding to the M configuration parameters and N first result values corresponding to the N optimization targets. In other words, each of the at least one sample includes a set of parameter values and a set of result values, wherein the set of parameter values includes the M first parameter values corresponding to the M configuration parameters, and the set of result values includes the N first result values corresponding to the N optimization targets.
[0008] The N result range values corresponding to the N optimization targets that meet the requirements are the result range values expected by the user for each of the N optimization targets. In other words, the user has an expected result range value for the result value of each optimization target. When the result value of each optimization target meets the user's expectation of a result range value for each optimization target, the result value of each optimization target can meet the user's requirements for each optimization target. There is no specific limitation on the number of result values included in each result range value. For example, one result range value among the N result range values may include only one result value, and another result range value among the N result range values may also include multiple different result values.
[0009] In the above technical solution, the first electronic device processes at least one sample in the initial data set based on the optimization algorithm to obtain M second parameter values of the M configuration parameters associated with the at least one sample. When the M configuration parameters are configured as the M second parameter values, the result value of each optimization target in the N optimization targets can meet the user's needs. Compared with the need to test all possible parameter combinations one by one in the traditional technology, the parameter optimization method based on the optimization algorithm provided by the present application does not need to test all possible parameter combinations one by one, which can improve the efficiency of the parameter optimization method. In addition, after obtaining the objective function of each optimization target based on the optimization algorithm provided by the present application, the first electronic device further obtains the Pareto curves of all objective functions (i.e., N objective functions) of all optimization targets (i.e., N optimization targets) and the N result range values corresponding to the N optimization targets that meet the needs, and determines the M second parameter values corresponding to the M configuration parameters that meet the user's needs. The processing process is simple and the amount of calculation is small, which can further improve the efficiency of the parameter optimization method.
[0010] In a possible implementation, for each optimization target, at least one sample is processed according to the optimization algorithm to obtain the objective function of each optimization target, including: for each optimization target, at least one sample is iteratively processed K times according to the optimization algorithm to obtain the objective function of each optimization target, wherein K is a positive integer; the i-th iteration processing in the K iteration processing includes: based on Gaussian process regression, fitting the i-th data set of the i-th iteration to obtain the i-th initial function of the i-th iteration, wherein i is a positive integer not exceeding K, when i is equal to 1, the i-th data set is the initial data set; when i is an integer greater than 1 and less than or equal to K, the i-th data set includes the i-1-th iteration. all samples in the i-1th data set and the i-1th sample of the i-1th iteration; based on the i-th acquisition function obtained by the i-th initial function, the i-th sample of the i-th iteration is obtained, wherein the function value of the i-th acquisition function is maximum when the M parameter values of the M configuration parameters are the parameter values of the M configuration parameters included in the i-th sample, and the i-th data set does not include the i-th sample; based on Gaussian process regression, according to the i-th sample, the i-th initial function is updated to obtain the i-th prediction function outputted by the i-th iteration, wherein when i is a positive integer less than K, the i-th prediction function is the initial prediction function of the i+1th iteration; when i is equal to K, the i-th prediction function is the objective function of each optimization objective.
[0011] In the above technical solution, the first electronic device performs K iterations on the historical information of the sample (i.e., at least one sample) according to the optimization algorithm, thereby obtaining N objective functions corresponding to the N optimization targets one by one. This iterative processing method can improve the accuracy of the objective function of each optimization target, thereby facilitating the improvement of the accuracy of the parameter optimization result. During the i-th (i.e., each) iteration, the first electronic device obtains a new sample of the i-th iteration (i.e., the i-th sample) based on the i-th acquisition function obtained by the i-th initial function. This new sample of the i-th iteration selected based on the historical data (i.e., the i-th data set) and the posterior probability (i.e., the i-th initial function) is more accurate, and can effectively reduce the number of iterations, thereby facilitating the improvement of the efficiency of the parameter optimization method.
[0012] In another possible implementation, after updating the initial function of the i-th iteration according to the i-th sample based on Gaussian process regression to obtain the i-th prediction function of the i-th iteration output, the method further includes: when a preset iteration stop condition is met, ending the iterative processing, where i is equal to K; when the preset iteration stop condition is not met, performing the i+1th iterative processing, where i is a positive integer less than K.
[0013] The preset iteration stop condition is not specifically limited and can be set according to actual needs. For example, the preset iteration stop condition can be, but is not limited to, at least one of the following conditions: the total duration of the current iteration exceeds the preset total duration of the iteration, the number of current iterations exceeds the preset number of iterations, or the difference between the current iteration result and the previous iteration result is less than a preset threshold.
[0014] In the above technical solution, when the preset iteration stop condition is met, the iteration process can be terminated, which can save computing resources. When the preset iteration stop condition is not met, the next iteration process can be continued, which can improve the accuracy of the iteration process result, thereby facilitating improving the accuracy of the parameter optimization result.
[0015] In another possible implementation, a Pareto curve is generated according to N objective functions, including: obtaining multiple sets of mapping relationships according to the N objective functions, wherein the multiple sets of mapping relationships correspond one-to-one to multiple sets of parameter values of M configuration parameters, each set of parameter values includes the parameter value of each configuration parameter in the M configuration parameters, and each set of mapping relationships is a mapping relationship between N optimization objectives determined based on a corresponding set of parameter values; generating a Pareto curve according to the multiple sets of mapping relationships.
[0016] In the above technical solution, multiple groups of mapping relationships are determined according to N objective functions, and then the Pareto curve is directly generated according to the determined multiple groups of mapping relationships. This implementation process is relatively simple and can improve the efficiency of the parameter optimization method.
[0017] In another possible implementation, based on the Pareto curve and N result range values that correspond one-to-one to N optimization objectives that meet the requirements, M second parameter values that correspond one-to-one to M configuration parameters are obtained, including: selecting a target mapping relationship that matches the N result range values from the Pareto curve, wherein the target mapping relationship represents a mapping relationship between the N second result values that correspond one-to-one to the N optimization objectives, and when the M configuration parameters are configured as M second parameter values, the N result values that correspond one-to-one to the N optimization objectives are N second result values; the second result value of any optimization objective among the N optimization objectives is processed according to the objective function of any optimization objective to obtain M second parameter values.
[0018] In the above technical solution, after selecting the target mapping relationship that matches the N result range values from the Pareto curve, the second result value of any optimization target is substituted into the objective function of any optimization target to obtain M second parameter values. The implementation process is relatively simple and has a small amount of calculation, which can improve the efficiency of the parameter optimization method.
[0019] In another possible implementation, the optimization algorithm is a Bayesian optimization algorithm.
[0020] In the above technical solution, the optimization algorithm adopts the Bayesian optimization algorithm, which can effectively reduce the number of iterations and improve the efficiency of the optimization algorithm, thereby facilitating improving the efficiency of the parameter optimization algorithm.
[0021] In another possible implementation, the M configuration parameters are configuration parameters of N optimization targets that affect the association of the target application in the second electronic device, and obtaining the initial data set includes: obtaining the initial data set from the second electronic device.
[0022] In the above technical solution, the M configuration parameters to be optimized are parameters in the second electronic device. After the first electronic device obtains the initial data set from the second electronic device, it performs parameter optimization processing on the M configuration parameters associated with the initial data set. When the computing power of the first electronic device is higher than that of the second electronic device, this method can improve the efficiency of parameter optimization and is also beneficial to saving computing resources of the second electronic device.
[0023] In another possible implementation, after obtaining M second parameter values corresponding to M configuration parameters in a one-to-one correspondence based on the Pareto curve and N optimization objectives that meet the requirements, the method also includes: sending the M second parameter values to the second electronic device so that the M configuration parameters in the second electronic device are configured as the M second parameter values.
[0024] In the above technical solution, the M configuration parameters to be optimized are parameters in the second electronic device. After the first electronic device obtains the initial data set from the second electronic device, it performs parameter optimization processing on the M configuration parameters associated with the initial data set, and sends the obtained parameter optimization results (i.e., M second parameter values) to the second electronic device. After that, the second electronic device can run the target application associated with the M configuration parameters when the M configuration parameters are configured as the M second parameter values, which can improve the user experience.
[0025] In another possible implementation, the target application is a game application, the M configuration parameters include configuration parameters that affect the operating frequency of the central processing unit of the second electronic device and configuration parameters that affect the task core selection of the second electronic device, and the N optimization targets include the frame rate of the game application and the power consumption of the game application.
[0026] It can be understood that the M configuration parameters in the above example refer to parameters related to the performance and power consumption of the system of the electronic device running the game application, and are not parameters of the game application itself.
[0027] The target application and the M configuration parameters in the above implementation are for illustration only and do not constitute any limitation on the target application and the M configuration parameters applicable to the present application.
[0028] In another possible implementation manner, the method further includes: receiving a parameter optimization instruction, wherein the parameter optimization instruction is used to instruct the first electronic device to perform parameter optimization on M configuration parameters to obtain M second parameter values.
[0029] The above-mentioned initial data set may be a data set obtained by the first electronic device before or after receiving the parameter optimization instruction, and the embodiments of the present application do not specifically limit this. For example, the first electronic device receives the parameter optimization instruction before obtaining the initial data set, and then the first electronic device will wait until the initial data set is obtained before performing parameter optimization processing on the M configuration parameters. For another example, the first electronic device receives the parameter optimization instruction after obtaining the initial data set, and then the first electronic device can immediately perform parameter optimization processing on the M configuration parameters.
[0030] In the above technical solution, the first electronic device will be triggered to perform parameter optimization on M configuration parameters only after receiving the parameter optimization instruction. This method can avoid the first electronic device from performing parameter optimization on M configuration parameters when no parameter optimization instruction is received, thereby saving computing resources.
[0031] In a second aspect, a parameter optimization device is provided, which is applied to a first electronic device, and the parameter optimization device executes any one of the parameter optimization methods in the first aspect.
[0032] In a third aspect, an electronic device is provided, comprising a unit for executing any one of the methods in the first aspect. The device may be a terminal device or a chip in the terminal device. The device may include an input unit and a processing unit.
[0033] When the device is a terminal device, the processing unit may be a processor, and the input unit may be a communication interface; the terminal device may also include a memory, which is used to store computer program code. When the processor executes the computer program code stored in the memory, the terminal device executes any one of the parameter optimization methods in the first aspect.
[0034] When the device is a chip in a terminal device, the processing unit may be a processing unit inside the chip, and the input unit may be an output interface, a pin or a circuit, etc.; the chip may also include a memory, which may be a memory inside the chip (for example, a register, a cache, etc.) or a memory located outside the chip (for example, a read-only memory, a random access memory, etc.); the memory is used to store computer program code, and when the processor executes the computer program code stored in the memory, the chip executes any one of the parameter optimization methods in the first aspect.
[0035] In one possible implementation, a memory is used to store computer program code; a processor executes the computer program code stored in the memory, and when the computer program code stored in the memory is executed, the processor is used to execute any one of the parameter optimization methods in the first aspect.
[0036] In a fourth aspect, a computer-readable storage medium is provided, wherein the computer-readable storage medium stores a computer program code. When the computer program code is executed by a parameter optimization device, the parameter optimization device executes any one of the parameter optimization methods in the first aspect.
[0037] In a fifth aspect, a computer program product is provided, the computer program product comprising: a computer program code, when the computer program code is executed by a parameter optimization device, the parameter optimization device executes any one of the parameter optimization methods in the first aspect.
[0038] It can be understood that the beneficial effects of the second to fifth aspects mentioned above can be found in the relevant description of the first aspect mentioned above, and will not be repeated in detail here.
[0039] It should be understood that the description of technical features, technical solutions, beneficial effects or similar language in this application does not imply that all features and advantages can be realized in any single embodiment. On the contrary, it is understood that the description of features or beneficial effects means that specific technical features, technical solutions or beneficial effects are included in at least one embodiment. Therefore, the description of technical features, technical solutions or beneficial effects in this specification does not necessarily refer to the same embodiment. Furthermore, the technical features, technical solutions and beneficial effects described in the present embodiment can also be combined in any appropriate manner. Those skilled in the art will understand that the embodiment can be realized without one or more specific technical features, technical solutions or beneficial effects of a specific embodiment. In other embodiments, additional technical features and beneficial effects can also be identified in specific embodiments that do not embody all embodiments. BRIEF DESCRIPTION OF THE DRAWINGS
[0040] Figure 1 It is a schematic diagram of an application scenario suitable for the parameter optimization method provided in the embodiment of the present application.
[0041] Figure 2 is the above Figure 1 A schematic diagram of the client structure and the server structure in an application scenario is shown.
[0042] Figure 3 It is a schematic diagram of a parameter optimization method provided in an embodiment of the present application.
[0043] Figure 4 is the above Figure 3 FIG. 4 is a schematic diagram showing the implementation process of step S330 .
[0044] Figure 5 It is a schematic diagram of a Pareto curve provided in an embodiment of the present application.
[0045] Figure 6 It is a schematic diagram of a parameter optimization method provided in an embodiment of the present application.
[0046] Figure 7 is the above Figure 6 FIG. 4 is a schematic diagram of the implementation process related to step S620.
[0047] Figure 8 It is a schematic diagram of a parameter optimization device 800 provided in an embodiment of the present application.
[0048] Fig. 9 It is a schematic diagram of the structure of an electronic device 900 provided in an embodiment of the present application. DETAILED DESCRIPTION
[0049] The following will be combined with the drawings in the embodiments of the present application to clearly and completely describe the technical solutions in the embodiments of the present application. Obviously, the described embodiments are part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of this application.
[0050] First, the application scenario of the parameter optimization method provided by the embodiment of the present application is introduced in conjunction with the accompanying drawings. It should be understood that: Figure 1 The usage scenarios shown are for illustration only and do not constitute any limitation on the scenarios to which the parameter optimization method provided in the embodiments of the present application is applicable.
[0051] Figure 1 Schematic diagram of an application scenario applicable to the parameter optimization method provided in the embodiment of the present application. Figure 1 The illustrated application scenario includes at least one client 120 and at least one server 110 , and the client 120 is connected to the server 110 via a wireless network or a wired network.
[0052] The client 120 is used to run the target application when the M configuration parameters associated with the target application are configured as M first parameter values, and obtain N first result values corresponding to the N optimization targets associated with the target application. Afterwards, the client 120 sends the collected data to the server 110, wherein the data collected by the client 120 includes the M first parameter values corresponding to the M configuration parameters and the N first result values corresponding to the N optimization targets. When the client 120 receives the M second parameter values of the M configuration parameters sent by the server 110, the client 120 can configure the M configuration parameters associated with the target application as the M second parameter values, and run the target application according to the configured M second parameter values.
[0053] In some implementations, the M configuration parameters associated with the target application are parameters related to the performance and power consumption of the system of the client 120 running the target application, and are not parameters of the target application itself. In some implementations, the M configuration parameters associated with the target application in the client 120 may include: parameters affecting the CPU operating frequency of the client 120 and parameters affecting the task core selection of the client 120.
[0054] It can be understood that in the embodiment of the present application, M configuration parameters are configured as M first parameter values, which has the same meaning as M parameter values of M configuration parameters are configured as M first parameter values, and will not be emphasized below.
[0055] For the above target application, the M configuration parameters and the N optimization targets are not specifically limited and can be set according to the actual scenario and user needs. For example, the target application can be, but is not limited to, a game application, the M configuration parameters can include configuration parameters that affect the operating frequency of the CPU of the client 120 and configuration parameters that affect the task core selection of the client 120, the N optimization targets can include the frame rate of the game and the power consumption of the game, and the N first result values include the frame rate value of the game and the power consumption value of the game.
[0056] The client 120 may be at least one of a tablet computer, a wearable device (e.g., a smart watch), a smart phone, a game console, a desktop computer, an e-book reader, an augmented reality (AR) / virtual reality (VR) device, an ultra-mobile personal computer (UMPC), a personal digital assistant (PDA), a vehicle-mounted device, and a laptop computer. It should be understood that Figure 1 The client 120 shown may generally refer to one of a plurality of terminals, or a set of a plurality of terminals.
[0057] For example, Figure 2 Shown above Figure 1 The schematic diagram of the structure of the client 120 is shown in FIG. Figure 2 As shown, the client 120 includes a dynamic parameter configuration module 121 and a data collection module 122 .
[0058] The dynamic parameter configuration module 121 is used to configure parameter values for the M configuration parameters associated with the target application in the client 120. In an example, the dynamic parameter configuration module 121 can configure parameter values for the above-mentioned M configuration parameters in the client 120 according to the parameter values sent by the point selection module 114 in the server 110. The type of configuration parameters associated with the application in the client 120 is not specifically limited. For example, taking the application in the client 120 as a game application as an example, the configuration parameters associated with the application may include but are not limited to one or more of the following parameters: the operating frequency (i.e., frequency point) of the CPU, the number of cores of the CPU, the size of the cache memory (Cache), or the size of the double data rate synchronous dynamic random access memory (DDR SDRAM), etc.
[0059] The data collection module 122 is used to collect information about the application runtime in the client 120, wherein the information may include, but is not limited to, the following information: scene information, load information, configuration information, performance information, and power consumption information. The scene information may include the scene of the application running on the client 120 (for example, the scene may be a game scene or a session scene, etc.), and the physical environment in which the client 120 is located (for example, the temperature and humidity or weather conditions of the current environment, etc.). The load information refers to the load of the client 120, for example, the load information may include the background load and / or background load of the client 120. The configuration information may include the parameter values configured by the client 120 for the configuration parameters of the application. The performance information may include the performance of the application. The power consumption information may include the energy consumption of the application. For example, taking a game application as an example, the performance information may include the frame rate of the game application, and the power consumption information may include the power consumption of the game application.
[0060] The server 110 is used to obtain the data collected by the client 120 as described above from the client 120, and execute the parameter optimization algorithm provided in this application on the acquired data collected by the client 120 to obtain M second parameter values of the M configuration parameters. Afterwards, the server 110 can also send the obtained M second parameter values of the M configuration parameters to the client 120.
[0061] The server 110 may be at least one of a computing device, multiple computing devices, a cloud computing platform, and a virtualization center.
[0062] For example, Figure 2 Shown above Figure 1 The structural diagram of the server 110 is shown in FIG. Figure 2 As shown, the server 110 includes a data collection module 111 , an end determination module 112 , an update module 113 and a point selection module 114 .
[0063] The data collection module 111 is used to obtain an initial data set, wherein the initial data set includes at least one sample, each of the at least one sample includes M first parameter values of M configuration parameters and N first result values corresponding to N optimization targets, and the first result value of each optimization target is obtained when the M configuration parameters are configured as the M first parameter values, and M and N are positive integers greater than 1. Figure 2 As shown, the data collection module 111 located in the server 110 can obtain the initial data set collected by the data collection module 122 in the client 120 by interacting with the client 120 .
[0064] The end determination module 112 is used to determine whether the iteration stop condition is currently met. Specifically, if the preset iteration stop condition is met, the end determination module 112 ends the iteration process and notifies the update module to use the prediction function output by the current iteration as the output function of the optimization algorithm; if the preset iteration stop condition is not met, the end determination module 112 notifies the update module 113 to continue to perform the next iteration process based on the prediction function output by the current iteration.
[0065] The update module 113 is used to execute the update steps in the K-iteration process involved in the parameter optimization algorithm, where K is a positive integer. In one example, the update module 113 is specifically used to update the initial function of the i-th iteration based on the i-th sample based on Gaussian process regression to obtain the i-th prediction function output by the i-th iteration, where i is an integer greater than or equal to 1 and less than or equal to K. Optionally, the update module 113 can also be used to fit the i-th data set of the i-th iteration based on Gaussian process regression to obtain the initial function of the i-th iteration, where i is a positive integer not exceeding K, and when i is equal to 1, the i-th data set is the initial data set; when i is an integer greater than 1 and less than or equal to K, the i-th data set includes all samples in the i-1-th data set of the i-1-th iteration and the i-1-th sample of the i-1-th iteration.
[0066] The point selection module 114 is used to determine the i-th sample of the i-th iteration based on the i-th acquisition function obtained from the initial function of the i-th iteration; and send the obtained M parameter values of the M configuration parameters to the dynamic parameter configuration module 121 of the client 120.
[0067] In one example, the point selection module 114 is specifically used to send the parameter values of the M configuration parameters included in the sample of the i-th iteration in the execution parameter optimization algorithm to the dynamic parameter configuration module 121 of the client 120. In this example, the parameter values of the M configuration parameters included in the sample of the i-th iteration can be sent to multiple clients 120. After the multiple clients 120 have received the parameter values of the M configuration parameters included in the sample of the i-th iteration, each of the multiple clients 120 can configure the M configuration parameters associated with the application to the M parameter values of the M configuration parameters included in the sample of the i-th iteration. After that, the multiple clients 120 can simultaneously run the one application associated with the M configuration parameters in parallel. At the same time, each client 120 can detect and obtain the result values of the N optimization targets at this moment, so as to obtain multiple groups of result values of the N optimization targets included in the sample of the i-th iteration, wherein the multiple groups of result values correspond to the multiple clients 120 one by one, and each group of result values is detected by the corresponding client 120. Finally, the multiple groups of result values can be aggregated to one client 120 among the multiple clients 120, and the one client 120 obtains the average value of each optimization target based on the multiple groups of result values to obtain N average values corresponding to the N optimization targets. Afterwards, the obtained N average values corresponding to the N optimization targets are returned to the server 110 as the N result values corresponding to the N optimization targets included in the sample of the i-th iteration.
[0068] In the test scenario, in the above example, multiple tests are repeatedly performed on a test configuration (i.e., the parameter values of the M configuration parameters included in the sample of the i-th iteration), and the average value of multiple groups of result values obtained from the multiple tests is used as the final result of the test configuration. In this way, the reliability of the test results obtained can be guaranteed, which is beneficial to improving the accuracy of the parameter optimization results.
[0069] In another example, the point selection module 114 specifically sends the M second parameter values of the M configuration parameters to the dynamic parameter configuration module 121 of the client 120, so that the client 120 configures the M configuration parameters as the M second parameter values.
[0070] It should be understood that the above Figure 1 and Figure 2 This is only for illustration and does not constitute any limitation on the application scenarios of the parameter optimization method provided in the embodiments of the present application and the modular structure of the server 110 and the client 120. Figure 1The application scenario shown may also include a greater number of servers 110 and a greater number of clients 120. Optionally, in some examples, the server 110 has the capabilities of the client 120 (e.g., collecting data), and the client 120 has the capabilities of the server 110 (e.g., computing a model). Optionally, in some examples, the client 120 may also include other modules, such as other modules that may be used, but not limited to, to store information collected by the data collection module 122.
[0071] In traditional technologies, in some scenarios where there are a large number of parameters to be optimized and a large number of optimization targets, in order to find the optimal parameter configuration corresponding to the user's optimization target requirements, it is necessary to conduct experimental tests on all feasible parameter combinations one by one. Afterwards, the optimal parameter configuration corresponding to the user's optimization target requirements is selected from a large number of experimental test results, and this process has the problem of low processing efficiency.
[0072] Based on this, an embodiment of the present application provides a parameter optimization method, a first electronic device, a storage medium and a chip. The method includes: obtaining an initial data set including at least one sample, each sample including a set of parameter values of a set of configuration parameters and a set of result values of a set of optimization targets corresponding to the set of parameter values. Then, for each optimization target in a set of optimization targets, at least one sample is processed according to an optimization algorithm to obtain an objective function of each optimization target, thereby obtaining a set of objective functions of a set of optimization targets, wherein the objective function of each optimization target represents a function between a set of configuration parameters and a set of optimization targets. Next, a Pareto curve is generated according to a set of objective functions of a set of optimization targets, and the Pareto curve represents multiple groups of mapping relationships between a set of optimization targets under multiple groups of parameter values corresponding to a set of configuration parameters determined based on a set of objective functions. Finally, the Pareto curve and the user's optimization requirements for a set of optimization targets obtain a set of target parameter values for a set of configuration parameters that can meet the user's requirements.
[0073] In the above method, the first electronic device processes at least one sample in the initial data set based on the optimization algorithm to obtain a set of target parameter values for a set of configuration parameters associated with the at least one sample. When the set of configuration parameters is configured as a set of target parameter values, the result value of each optimization target in a set of target optimization targets can meet user needs. Compared with the traditional technology that requires testing all possible parameter combinations one by one, the parameter optimization method based on the optimization algorithm provided in the present application does not need to test all possible parameter combinations one by one, which can improve the efficiency of the parameter optimization method.
[0074] In addition, after obtaining the objective function of each optimization target based on the optimization algorithm provided by the present application, the first electronic device further obtains a Pareto curve for all objective functions of all optimization targets (i.e., a set of objective functions for a set of optimization targets) and the user's optimization requirements for a set of optimization targets, to obtain a set of target parameter values for a set of configuration parameters that can meet the user's needs. The processing process is simple and has a small amount of calculation, which can further improve the efficiency of the parameter optimization method.
[0075] The parameter optimization method provided in the embodiment of the present application is described in detail below. It should be understood that the execution subject for executing the method in the embodiment of the present application can be an electronic device, or a chip or processor in the electronic device, which is not specifically limited.
[0076] Next, combine Figures 3 to 7 The parameter optimization method provided in the embodiments of the present application is introduced in detail.
[0077] Figure 3 Schematic diagram of a parameter optimization method provided in an embodiment of the present application. The parameter optimization method provided in an embodiment of the present application can be, but is not limited to, the above Figure 1 The server 110 and the client 120 are shown to execute. For example, Figure 3 As shown, taking the execution subject including the server and the client as an example, the parameter optimization method provided in the embodiment of the present application includes steps S310 to S340. Steps S310 to S340 are described in detail below.
[0078] In step S310, the client obtains a set of parameter values 0 for a set of game parameters to be optimized and a set of result values 0 for a set of optimization targets, wherein the set of result values 0 for a set of optimization targets are obtained by running the game with the client configured with the set of parameter values 0.
[0079] In an embodiment of the present application, a set of game parameters refers to multiple configuration parameters associated with a game application, and the multiple configuration parameters refer to parameters related to the performance and power consumption of the system of the electronic device running the game application, which will not be emphasized below. A set of game parameters may include the following parameters: parameters that affect the CPU operating frequency (hereinafter referred to as CPU parameters) and parameters that affect task core selection (hereinafter referred to as core selection parameters). The parameter types of the parameters that affect the CPU operating frequency and the parameter types of the parameters that affect the task core selection are not specifically limited and can be set according to actual conditions. It should be noted that the multiple configuration parameters associated with the above-mentioned game application are not the parameters of the game application itself.
[0080] The number of multiple configuration parameters and the parameter type of each configuration parameter can be flexibly set according to actual conditions and scenarios, and are not specifically limited in the embodiments of the present application. For example, the number of configuration parameters included in a set of game parameters can be 2, 3 or 5, etc.
[0081] As mentioned above, a set of game parameters includes multiple configuration parameters. Therefore, a set of parameter values 0 of the set of game parameters includes multiple parameter values corresponding to the multiple configuration parameters, wherein each parameter value is a parameter value of the corresponding configuration parameter.
[0082] A set of configuration parameters is a set of configuration parameters in the client that affect a set of optimization targets associated with the game application. In other words, a set of optimization targets refers to multiple performance result values associated with the game application detected after the client runs multiple configuration parameters associated with the game application and is configured with multiple parameter values.
[0083] In some game scenarios, a set of game parameters associated with a game application may include CPU parameters (i.e., the parameters affecting the CPU operating frequency as described above) and core selection parameters (i.e., the parameters affecting the task core selection as described above), a set of parameter values 0 of a set of game parameters may include parameter values 0 of CPU parameters and parameter values 0 of core selection parameters, a set of optimization targets associated with a game application may include the frame rate of the game and the power consumption of the game, and a set of result values 0 of a set of optimization targets include the frame rate value 0 of the game and the power consumption value 0 of the game. The frame rate of the game as an optimization target generally refers to the number of times the game screen is updated per second. For example, 60 frames means that the game screen is updated 60 times per second, and 144 frames means that the game screen is updated 144 times per second. The frame rate directly affects the fluency of the game. Generally speaking, the higher the frame rate, the smoother the game screen and the better the user experience. The power consumption of the game as an optimization target generally refers to the maximum power consumption of the entire client when the client runs the game.
[0084] In the above gaming scenario, the user's goal for optimizing the game's frame rate and power consumption is to ensure that the game's frame rate is full (i.e., there is no insufficient computing power, and no frames are dropped due to failure to complete the computing in time), and that the game's power consumption is as low as possible (i.e., the computing power supply is just right, without oversupply).
[0085] Based on this, the game smoothness and power consumption can be adjusted by adjusting multiple configuration parameters associated with the game application (for example, the multiple configuration parameters include the parameters affecting the CPU operating frequency and the parameters affecting the task core selection mentioned above), thereby avoiding inappropriate configuration of the parameter values of the multiple configuration parameters, which may cause the game to freeze when the player is playing the game.
[0086] A set of optimization objectives and a set of game parameters to be optimized may be determined by the client based on the user's input parameters, or may be determined by the client itself based on the device operation status, which is not specifically limited in the embodiments of the present application.
[0087] There is no specific limitation on the manner in which the client obtains a set of parameter values 0 of a set of game parameters to be optimized and a set of result values 0 of the optimization target in the above step S310.
[0088] In one example, a client obtains a set of parameter values 0 for a set of game parameters to be optimized and a set of result values 0 for a set of optimization targets, which may include the following steps: the client obtains multiple sets of game parameter values for the set of game parameters and multiple sets of result values for a set of optimization targets, wherein the multiple sets of game parameter values and the multiple sets of result values correspond one-to-one, and each set of result values is a set of parameter values for the set of game parameters in the client configured as corresponding game parameter values, and the result value of each optimization target in a set of optimization targets obtained after the client runs a game associated with the set of game parameters; for each game parameter, the client determines the average value of multiple parameter values associated with each game parameter in the multiple sets of game parameter values as the parameter value of each game parameter; for each optimization target, the client determines the average value of multiple result values associated with each optimization target in the multiple sets of result values as the result value 0 of each optimization target, so as to obtain a set of result values 0 for a set of optimization targets.
[0089] In the above scheme, the client uses the average value of multiple game parameter values associated with each game parameter as the parameter value of each game parameter, and uses the average value of multiple result values associated with each optimization target as the value of each optimization target. In this way, the reliability of the acquired data can be guaranteed as much as possible, thereby reducing the impact of the data on the final processing results.
[0090] It should be noted that, in the above step S310, the parameters to be optimized include a set of game parameters, and a set of optimization targets include game frame rate and game power consumption, for example, and the present embodiment of the application is not limited to this. That is to say, in other implementations, the set of parameters to be optimized in the above step S310 can also be multiple parameters in other scenarios, and the multiple indicators to be optimized can be corresponding performance indicators in the other scenarios.
[0091] In step S320, the client sends a set of parameter values 0 of a set of game parameters and a set of result values 0 of a set of optimization objectives to the server.
[0092] In the embodiment of the present application, the triggering condition for the client to execute the above step S320 is not specifically limited and can be set according to actual needs. For example, after the client completes the above step S310, the client immediately executes the above step S320. For another example, after the client completes the above step S310 and after a preset time period, the client executes the above step S320. For another example, the server sends a request message to the client at a preset time interval, and the request message is used to request to obtain a set of parameter values of a set of game parameters and a set of result values of a set of optimization targets in the above step S320. After the client receives the request message, the client executes the above step S320.
[0093] In step S330, the server takes the frame rate of the game as the target of Bayesian optimization, a set of parameter values 0 of a set of game parameters and the frame rate value 0 of the game corresponding to the set of parameter values 0 of the set of game parameters as input parameters of Bayesian optimization, performs Bayesian optimization iteration, and obtains function 1 between the frame rate of the game and the set of game parameters.
[0094] Function 1 is a function that takes a set of game parameters as independent variables and the frame rate of the game as dependent variable. That is, the value of the independent variable of Function 1 is a set of parameter values of a set of game parameters, and the value of the dependent variable of Function 1 is the frame rate value of the game.
[0095] In the above step S330, the server uses the frame rate value of the game as the target of Bayesian optimization based on the Bayesian optimization algorithm, and uses a set of parameter values 0 of a set of game parameters and the frame rate value 0 of the game corresponding to the set of parameter values 0 of the set of game parameters as input parameters of the Bayesian optimization. It is necessary to perform K rounds (also called K times) of iterative calculations to obtain a function 1 between the frame rate of the game and the set of game parameters, where K is a positive integer.
[0096] The Bayesian optimization algorithm in the above step S330 optimizes the objective function based on Bayesian statistical theory, which mainly includes Gaussian process (GP) and acquisition function. The objective function can be an unknown function (i.e., the properties of the objective function, such as monotonic properties, etc., cannot be known), that is, it belongs to a "black box". If the finite-dimensional distribution of a random process is a normal distribution, then this random process is called a Gaussian process or a normal process.
[0097] In the embodiment of the present application, the implementation process of the server performing the above step S330 includes: Figure 4 The step S3301 to step S3312 are shown. Below, the above step S330 is described in detail in combination with the step S3301 to step S3312.
[0098] In step S3301, the server determines a set of parameter values 0 of a set of game parameters and a frame rate value 0 of the game corresponding to the set of parameter values 0 of the set of game parameters as sample 0 in the initial data set.
[0099] In the above step S3301, sample 0 in the initial data set includes a set of parameter values 0 of a set of game parameters and a frame rate value 0 of the game corresponding to the set of parameter values 0 of the set of game parameters.
[0100] It should be understood that in the above step S3301, the initial data set includes only one sample 0 as an example for description. Optionally, in other implementations, the initial data set of the above step S3301 may also include multiple samples, each of the multiple samples includes a set of parameter values of a set of game parameters and a corresponding frame rate value of the game (i.e., the frame rate value of the game obtained when the set of game parameters is configured as the set of parameter values). In this implementation, the multiple samples can be obtained by the server from the client. For example, the initial data set may include 2, 3 or 5 samples, etc.
[0101] In step S3302, the server establishes an initial Gaussian probability proxy model based on a Gaussian process and uses sample 0 in the initial data set to obtain an initial objective function 0.
[0102] In the above step S3302, the server establishes an initial Gaussian probability proxy model based on a Gaussian process and using samples in the initial data set. Exemplarily, the following steps may be included: the server obtains the mean of the frame rate value 0 of the game included in sample 0 and the standard deviation of the frame rate value 0 of the game based on the Gaussian process; the server establishes an initial Gaussian probability proxy model based on the mean of the frame rate value 0 of the game included in sample 0, the standard deviation of the frame rate value 0 of the game included in sample 0, and the value range of each game parameter in a set of game parameters.
[0103] The mean of the frame rate value 0 of the game included in the above sample 0 can be considered as an estimated value of the objective function, and the standard deviation of the frame rate value 0 of the game in the above sample 0 quantifies the uncertainty of the estimated value at the specific position. It can be understood that the function formed by the parameter value of a set of game parameters corresponding to the initial Gaussian probability proxy model at each point within the preset value range, and the mean of the frame rate value of the game corresponding to the parameter value of the set of game parameters at each point within the preset value range, can be called the initial objective function 0. It can be understood that the parameter value of the set of game parameters at each point within the preset value range refers to a set of parameter values of a set of game parameters, and the parameter value corresponding to each game parameter in the set of game parameters is within the preset value range.
[0104] It can be understood that the set of game parameters included in the above sample 0 includes multiple configuration parameters, so the above initial Gaussian probability agent model is a high-dimensional and complex probability agent model.
[0105] In the above step S3302, the server establishes a probabilistic proxy model based on a Gaussian process as an example for description. Optionally, the server may also establish a probabilistic proxy model based on a random forest process, which is not specifically limited.
[0106] Based on the Gaussian process and the known sample (i.e., sample 0), the server can estimate the mean and standard deviation of the game frame rate values corresponding to any set of parameter values of the game parameters within the corresponding value range, excluding the set of parameter values of the game parameters corresponding to the known sample.
[0107] In step S3303, the server determines that the next sample 1 includes a set of parameter values 1 of the set of game parameters based on the acquisition function 1 constructed by the initial Gaussian probability proxy model.
[0108] A set of parameter values 1 for a set of game parameters includes a parameter value for each game parameter in the set of game parameters.
[0109] In the above step S3303, the server determines the next sample 1 based on the constructed acquisition function 2, which may include the following steps: the server determines, based on acquisition function 2, that a set of parameter values of the set of game parameters corresponding to the maximum value of acquisition function 2 is a set of parameter values 1; the server determines that the next sample 1 includes a set of parameter values of the set of game parameters as a set of parameter values 1.
[0110] Optionally, before determining that the next sample 1 includes a set of parameter values 1 of the set of game parameters, the server may also execute the step of constructing an acquisition function 1 based on the initial Gaussian probability proxy model. In an embodiment of the present application, the method for constructing an acquisition function based on a Gaussian probability proxy model is not specifically limited and can be implemented based on existing methods.
[0111] Exemplarily, the acquisition function 1 constructed by the server based on the initial Gaussian probability proxy model may include the following steps: the server constructs an acquisition function 1 that satisfies preset conditions based on the posterior probability corresponding to the initial Gaussian probability proxy model, wherein the posterior probability corresponding to the initial Gaussian probability proxy model includes the mean of the frame rate value of the game at each point within a preset value range of a set of game parameters, and the standard deviation of the frame rate value of the game at each point within a preset value range of a set of game parameters. It can be understood that the parameter value of the set of game parameters at each point within the preset value range refers to a set of parameter values of a set of game parameters, and the parameter value corresponding to each game parameter in the set of game parameters is within the preset value range.
[0112] In an embodiment of the present application, the preset conditions that the acquisition function 1 constructed by the server based on the initial Gaussian probability proxy model in the above steps needs to meet may include the following conditions: (1) The value of the acquisition function is smaller at the existing sampling points. Because these points have been explored, calculating the function value at these points is of no use in solving the problem; (2) The value of the acquisition function is larger at points with wider confidence intervals. Because these points have greater uncertainty, they are more worthy of exploration. For example, the confidence interval is a 95% confidence interval of the function value at the sampling point predicted based on the mean and variance of the function value of the sampling point (that is, the result value of each optimization target, such as the frame rate value of the game or the power consumption value of the game); (3) The value of the acquisition function is larger at points where the function mean is larger. Because the mean is an estimate of the function value at the point, these points are more likely to be near extreme points.
[0113] In the above step S3303, the server actively selects the next globally most promising sampling point (i.e., a set of parameter values 1 of the set of game parameters in the next sample 1) by weighing "development" (i.e., seeking to improve the objective function near the current optimal point) and "exploration" (i.e., exploring unknown areas) through the acquisition function (point addition strategy).
[0114] In the embodiment of the present application, the above-mentioned acquisition function is not specifically limited. For example, the acquisition function may be but is not limited to any of the following functions: probability of improvement (PI) acquisition function, expectation improvement (EI) acquisition function, upper confidence bound (UCB) acquisition function, Gaussian process upper confidence bound (GP-UCB) sampling function, or entropy acquisition function.
[0115] In step S3304, the server substitutes a set of parameter values 1 of the set of game parameters into the initial objective function 0 to obtain a frame rate value 1 of the game corresponding to a set of parameter values 1 of the set of game parameters included in the next sample 1.
[0116] In the above step S3304, the server substitutes a set of parameter values 1 of the set of game parameters into the initial objective function 0 to obtain a frame rate value 1 of the game corresponding to the set of parameter values 1 of the set of game parameters, including: the server substitutes a set of parameter values 1 of the set of game parameters into the initial objective function 0, and the output result of the initial objective function 0 is the frame rate value 1 of the game corresponding to the set of parameter values 1 of the set of game parameters, thereby obtaining the frame rate value 1 of the game corresponding to the set of parameter values 1 of the set of game parameters.
[0117] In step S3305 , the server processes the initial Gaussian probability proxy model using the next sample 1 based on the Gaussian process, establishes an updated Gaussian probability proxy model 1 , and obtains the objective function 1 .
[0118] The next sample 1 includes a set of parameter values 1 of the set of game parameters and a frame rate value 1 of the game corresponding to the set of parameter values 1 of the set of game parameters.
[0119] In the above step S3305, the function formed by the parameter value of each point in the preset value range of a set of game parameters corresponding to the updated Gaussian probability proxy model 1 and the average value of the frame rate value of the game corresponding to the parameter value of each point in the preset value range of the set of game parameters can be called the objective function 1. It can be understood that in the present application, the parameter value of each point in the preset value range of the set of game parameters refers to a set of parameter values of a set of game parameters, and the parameter value corresponding to each game parameter in the set of game parameters is within the preset value range.
[0120] It can be understood that the above steps S3302 to S3305 are the first iteration process of the server executing the Bayesian optimization algorithm. The core idea of the Bayesian optimization is to gradually converge to the optimal solution by continuously updating the prior knowledge and observation results. In the Bayesian optimization process, a prior probability model (for example, the Gaussian probability proxy model described above) is established to describe the behavior of the objective function. Then, by continuously observing the value of the objective function (for example, the above objective function 1), the parameters of the probability model are updated to obtain a more accurate posterior probability distribution. In each iteration, the Bayesian optimization will determine the next test point to be evaluated (for example, the above next sample 1) through the algorithm based on the current probability model. The point selection process will use the known optimal solution and conduct a certain degree of exploration, which is conducive to discovering possible unknown optimal points. In this way, Bayesian optimization can gradually approach the optimal solution within a limited number of iterations. Compared with traditional optimization methods (for example, hyperparameter tuning, neural network architecture search, etc.), the Bayesian optimization algorithm does not require specific mathematical modeling of the objective function. Instead, it uses a probabilistic model to approximate the behavior of the objective function. It can effectively solve optimization problems with high testing costs and limited time, making it more suitable for complex practical problems.
[0121] In step S3306, when the iteration end condition is not met at present, the server constructs the acquisition function 2 based on the updated Gaussian probability proxy model 1, and determines that the next sample 2 includes a set of parameter values 2 of the set of game parameters.
[0122] The next sample 2 is different from the next sample 1 mentioned above, that is, the set of parameter values 2 of a set of game parameters included in the next sample 2 is different from the set of parameter values 1 of a set of game parameters included in the next sample 1.
[0123] For example, taking a set of game parameters including parameter A and parameter B, the next sample 1 includes parameter A with a value of 1 and parameter B with a value of 1; the next sample 2 includes parameter A with a value of 1 and parameter B with a value of 2; in this case, it can be considered that the next sample 1 and the next sample 2 are different.
[0124] For example, taking a set of game parameters including parameter A and parameter B, the next sample 1 includes parameter A with a value of 1 and parameter B with a value of 3; the next sample 2 includes parameter A with a value of 2 and parameter B with a value of 4; in this case, it can be considered that the next sample 1 and the next sample 2 are different.
[0125] Optionally, before executing the above step S3306, the server may perform a step of determining whether the iteration stop condition is currently met. In the embodiment of the present application, the method for the server to determine whether the iteration stop condition is currently met is not specifically limited and can be set according to user needs or application scenarios.
[0126] For example, the iteration stop condition may be that the number of current iterations exceeds a preset number of iterations. For another example, the iteration stop condition may be that the time of the current iteration exceeds a preset iteration time. For another example, the iteration stop condition may be that the current iteration result meets user requirements.
[0127] In step S3307, the server obtains a frame rate value 2 of the game corresponding to a set of parameter values 2 of the set of game parameters included in the next sample 2 according to a set of parameter values 2 of the set of game parameters and the objective function 1.
[0128] The next sample 2 includes a set of parameter values 2 of the set of game parameters and a frame rate value 2 of the game corresponding to the set of parameter values 2 of the set of game parameters. The set of parameter values 2 is different from the set of parameter values 1 of the set of game parameters included in the next sample 1 described above. For the same set of game parameters, the two sets of parameter values corresponding to the same set of game parameters are different, which means that for at least one game parameter in the same set of game parameters, the parameter value of the at least one game parameter in the two sets of parameter values is different.
[0129] In the above step S3307, after the server determines a set of parameter values 2 of the set of game parameters included in the next sample 2, the server continues to determine a frame rate value 2 of the game corresponding to the set of parameter values 2 of the set of game parameters.
[0130] Optionally, in some implementations, the server may also obtain the frame rate value of the game corresponding to a set of parameter values 2 of the set of game parameters based on the following method: the server may also send a set of parameter values 2 of the set of game parameters to the client; after the client configures a set of parameter values 2 of the set of game parameters to run the game associated with the set of game parameters, the frame rate value of the game corresponding to a set of parameter values 2 of the set of game parameters is collected; the client sends the collected frame rate value of the game corresponding to a set of parameter values 2 of the set of game parameters to the server, so that the server can obtain the frame rate value of the game corresponding to a set of parameter values 2 of the set of game parameters.
[0131] In order to ensure the reliability of the test results, in the above implementation, the client can also configure the set of parameter values 2 of the set of game parameters to run the game associated with the set of game parameters multiple times to obtain frame rate values of multiple sets of games that correspond to each other, and the frame rate value of the set of games corresponding to each run is the frame rate value of the game corresponding to the set of parameter values 2 of the set of game parameters. Afterwards, the client calculates the average value of the frame rate values of the multiple sets of games, and uses the obtained average value as the frame rate value of the game corresponding to the set of parameter values 2 of the set of game parameters.
[0132] In the above implementation, after the server determines that the next sample 2 includes a set of parameter values 2 of the set of game parameters, the server can send the set of parameter values 2 of the set of game parameters to the client, so that after the client configures a set of game parameters as the set of parameter values 2 of the set of game parameters, the frame rate value 2 of the game corresponding to the set of parameter values 2 of the set of game parameters is obtained through testing.
[0133] In step S3308, the server uses the next sample 2 based on the Gaussian process to process the Gaussian probability proxy model and establishes an updated Gaussian probability proxy model 2 to obtain the objective function 2.
[0134] The function formed by the parameter values of a set of game parameters corresponding to the updated Gaussian probability agent model 2 at each point within the preset value range and the mean of the game frame rate values corresponding to the parameter values of the set of game parameters at each point within the preset value range can be called objective function 2.
[0135] It can be understood that the above steps S3306 to S3308 are the second iteration process of the Bayesian optimization algorithm executed by the server. The principle of the server executing the above steps S3306 to S3308 is the same as the principle of the server executing the above steps S3302 to S3305. For the contents not described in detail here, please refer to the relevant descriptions in the above steps S3302 to S3305.
[0136] In step S3309, when the iteration end condition is not met at present, the server constructs the acquisition function 3 based on the updated Gaussian probability proxy model 2, and determines that the next sample 3 includes a set of parameter values 3 of the set of game parameters.
[0137] A set of parameter values 3 for a set of game parameters includes the parameter value of each game parameter in the set of game parameters. A set of parameter values 3 is different from a set of parameter values 1 for a set of game parameters included in the next sample 1 described above. A set of parameter values 3 is different from a set of parameter values 2 for a set of game parameters included in the next sample 2 described above. For the description of the difference between the two sets of parameter values corresponding to the same set of game parameters, please refer to the description in the above step S3307, which will not be repeated here.
[0138] Optionally, before executing the above step S3309, the server may perform a step of determining whether the iteration stop condition is currently met. In the embodiment of the present application, the method for the server to determine whether the iteration stop condition is currently met is not specifically limited and can be set according to user needs or application scenarios.
[0139] For example, the iteration stop condition may be that the number of current iterations exceeds a preset number of iterations. For another example, the iteration stop condition may be that the time of the current iteration exceeds a preset iteration time. For another example, the iteration stop condition may be that the current iteration result meets user requirements.
[0140] In step S3310, the server obtains a frame rate value 3 of the game corresponding to a set of parameter values 3 of the set of game parameters included in the next sample 3 according to a set of parameter values 3 of the set of game parameters and the objective function 2.
[0141] The next sample 3 includes a set of parameter values 3 of the set of game parameters and a frame rate value 3 of the game corresponding to the set of parameter values 3 of the set of game parameters.
[0142] In step S3311, the server uses the next sample 3 based on the Gaussian process to process the Gaussian probability proxy model and establishes an updated Gaussian probability proxy model 3 to obtain the objective function 3.
[0143] The next sample 3, the next sample 2 and the next sample 1 mentioned above are three different samples, that is, any two sets of parameter values of a set of game parameters included in the next sample 3, a set of parameter values of a set of game parameters included in the next sample 2, and a set of parameter values of a set of game parameters included in the next sample 1 are different. It should be understood that each set of parameter values j includes the parameter values of each game parameter in a set of game parameters, j=1,2,3.
[0144] The function formed by the parameter values of a set of game parameters corresponding to the updated Gaussian probability agent model 3 at each point within the preset value range and the mean of the frame rate values of the game corresponding to the parameter values of the set of game parameters at each point within the preset value range can be called the objective function 3.
[0145] It can be understood that the above steps S3309 to S3311 are the third iteration process of the Bayesian optimization algorithm executed by the server. The principle of the server executing the above steps S3309 to S3311 is the same as the principle of the server executing the above steps S3302 to S3305. For the contents not described in detail here, please refer to the relevant descriptions in the above steps S3302 to S3305.
[0146] In step S3312, the server determines that the iteration end condition is currently met, ends the iteration calculation, and determines the objective function 3 as the function 1 between the game frame rate and the set of game parameters.
[0147] For example, when the server determines that the current iteration time exceeds the preset iteration time, it determines that the iteration end condition is currently met and the iteration calculation is terminated. For another example, when the server determines that the current iteration result (i.e., objective function 3) meets the user's requirements, it determines that the iteration end condition is currently met and the iteration calculation is terminated.
[0148] In the embodiment of the present application, after the server has executed the above steps S3301 to S3312, the above step S330 is completed. It should be noted that in the above steps S3301 to S3312, the server has executed step S330 for 3 iterations. Optionally, the server may also execute step S330 for more (e.g., 5, 20 or 30 times) or less (e.g., 1 time) iterations, which is not specifically limited in the embodiment of the present application.
[0149] In step S340, the server takes the power consumption of the game as the target of Bayesian optimization, a set of parameter values of a set of game parameters and the power consumption values of the game corresponding to the set of parameter values of the set of game parameters as input parameters of Bayesian optimization, performs Bayesian optimization iteration, and obtains function 2 between the power consumption of the game and the set of game parameters.
[0150] Function 2 is a function with a set of game parameters as independent variables and the power consumption of the game as the dependent variable. That is, the value of the independent variable of Function 2 is a set of parameter values of a set of game parameters, and the value of the dependent variable of Function 2 is the power consumption value of the game.
[0151] The set of parameter values of a set of game parameters in the above step S340 is the same set of parameter values as the set of parameter values of a set of game parameters in the above step S330.
[0152] The principle of the server executing step S340 is the same as the principle of the server executing step S330. The difference is that the optimization targets in step S340 and step S330 are different. Specifically, the optimization target of step S340 is the game power consumption, and the optimization target of step S330 is the game frame rate. For the processes not described in detail here, please refer to the relevant description in step S330.
[0153] In step S350, the server generates a Pareto curve according to function 1 and function 2, and determines a set of parameter values of a set of game parameters corresponding to a set of game frame rate values and game power consumption values that meet user needs in the Pareto curve as a set of target parameter values of a set of game parameters.
[0154] In the embodiment of the present application, after the server obtains function 1 and function 2, for a set of parameter values of the set of game parameters, the frame rate value of the game frame rate and the power consumption value of the game power consumption corresponding to the set of parameter values can be obtained.
[0155] In the above step S350, since there are multiple optimization targets (i.e., the game frame rate value and the game power consumption value) for a set of game parameters that need to be decided, in an embodiment of the present application, a set of target parameter values for a set of game parameters that meet the user's requirements for multiple optimization indicators (i.e., the game frame rate and the game power consumption) can be selected based on the Pareto curve.
[0156] For example, the Pareto curve described in step S350 above can be as follows: Figure 5 The curve shown is Figure 5 The number of optimization objectives shown in is 2. Figure 5 Taking the Q1 point in as an example, the value of optimization objective 1 and the value of optimization objective 2 corresponding to the Q1 point are a mapping relationship; Figure 5 Taking point Q2 in the figure as an example, the value of optimization objective 1 and the value of optimization objective 2 corresponding to point Q2 are another mapping relationship.
[0157] In the above step S350, the server generates a Pareto curve according to function 1 and function 2, including: according to function 1 and function 2, multiple groups of mapping relationships are obtained, wherein the multiple groups of mapping relationships correspond one-to-one to the multiple groups of parameter values of M configuration parameters, each group of parameter values includes the parameter value of each configuration parameter in the M configuration parameters, and each group of mapping relationships is a mapping relationship between the frame rate value of the game and the power consumption value of the game determined based on the corresponding set of parameter values; based on the multiple groups of mapping relationships, a Pareto curve is generated.
[0158] The server obtains the Pareto curve based on the two curves, optimizes multiple optimization targets (i.e., the game frame rate value and the game power consumption value) according to user needs, and obtains a set of target parameter values for a set of game parameters that meet the user's needs for multiple optimization targets. The implementation process is relatively simple and can improve processing efficiency.
[0159] In step S360, the server sends a set of target parameter values of a set of game parameters to the client. Correspondingly, the client receives the set of target parameter values of a set of game parameters sent by the server.
[0160] A set of target parameter values includes the parameter value of each game parameter in a set of game parameters. The relationship between a set of target parameter values and the set of parameter values 1, a set of parameter values 2 and a set of parameter values 3 described above is not specifically limited. In other words, a set of target parameter values can be different parameter values from the three sets of parameter values (i.e., a set of parameter values 1, a set of parameter values 2 and a set of parameter values 3), or a set of target parameter values can also be any set of parameter values in the three sets of parameter values (e.g., a set of parameter values 1, a set of parameter values 2 or a set of parameter values 3).
[0161] The conditions for triggering the server to execute the above step S360 are not specifically limited. For example, after the server executes the above step S350 to obtain a set of target parameter values for a set of game parameters, the server automatically and immediately executes the above step S360.
[0162] In step S370, the client updates a set of parameter values of a set of game parameters to a set of target parameter values.
[0163] In the embodiment of the present application, the implementation method of the client updating a set of parameter values of a set of game parameters to a set of target parameter values is not specifically limited. For example, after the client receives a set of target parameter values of a set of game parameters sent from the server, after a preset period of time has passed, the client updates the set of parameter values of a set of game parameters to the set of target parameter values. For another example, after the client receives a set of target parameter values of a set of game parameters sent from the server, it immediately updates the set of parameter values of a set of game parameters to the set of target parameter values.
[0164] Optionally, after the client executes step S370, the client may also run the game associated with the set of game parameters according to the updated set of target parameter values.
[0165] It should be understood that the above Figure 3The parameter optimization method shown is for illustration only and does not constitute any limitation on the parameter optimization method provided in the embodiment of the present application. In the above step S330, the server satisfies the iteration stop condition after executing 2 iterations as an example. Optionally, in other implementations, the server may also determine that the iteration stop condition is currently satisfied after executing 2 or more iterations (for example, 5 or 10 times, etc.).
[0166] In an embodiment of the present application, for each optimization target in a plurality of optimization targets (e.g., a frame rate value of a game and a power consumption value of a game) associated with a plurality of configuration parameters of an application (e.g., a game application), an optimization algorithm is first used to iteratively process the initial data set to obtain an objective function of each optimization target with a plurality of configuration parameters as independent variables and each optimization target as a dependent variable. The processing process determines the next search point based on the information of the previously searched point using the Bayesian optimization algorithm, which can effectively reduce the number of iterations, thereby improving the efficiency of the parameter optimization method and the accuracy of the parameter optimization result. Based on the obtained functions of the plurality of optimization targets (e.g., function 1 and function 2), a Pareto curve for representing a plurality of groups of mapping relationships between the plurality of optimization targets determined based on the plurality of objective functions is obtained, and from the obtained Pareto curve, a plurality of target parameter values of the plurality of configuration parameters that meet the needs of the user are selected. In the processing process, the plurality of target functions of the plurality of optimization targets are intuitively displayed to the user in the form of a curve, and the user selects from the curve a plurality of target parameter values of the plurality of configuration parameters corresponding to the plurality of optimization targets that meet their needs. The processing process has a small amount of calculation, which is conducive to improving the efficiency of the parameter optimization method.
[0167] Figure 6 is a schematic diagram of a parameter optimization method provided in an embodiment of the present application. The parameter optimization method provided in an embodiment of the present application can be performed by an electronic device. It is understood that the electronic device can be implemented as software, or a combination of software and hardware. Exemplarily, the first electronic device in the embodiment of the present application can be, but is not limited to, Figure 1 The server 110 shown, or Fig. 9 The electronic device 900 is shown. Figure 6 As shown, the parameter optimization method provided in the embodiment of the present application includes steps S610 to S640. Steps S610 to S640 are described in detail below.
[0168] In step S610, the first electronic device obtains an initial data set, wherein the initial data set includes at least one sample, each sample in the at least one sample includes M first parameter values corresponding to M configuration parameters and N first result values corresponding to N optimization targets, the first result value of each optimization target is obtained when the M configuration parameters are configured as M first parameter values, and M and N are positive integers greater than 1.
[0169] Each of the at least one sample includes M first parameter values corresponding to the M configuration parameters and N first result values corresponding to the N optimization targets. In other words, each of the at least one sample includes a set of parameter values and a set of result values, wherein the set of parameter values includes the M first parameter values corresponding to the M configuration parameters, and the set of result values includes the N first result values corresponding to the N optimization targets.
[0170] In some implementations, the M configuration parameters are configuration parameters of N optimization targets associated with the target application in the second electronic device, and the first result value of each optimization target is obtained when the M configuration parameters are configured as M first parameter values, which means that when the M configuration parameters are configured as M first parameter values, the result of each optimization target among the N optimization targets is detected after the second electronic device runs the target application.
[0171] It can be understood that the M configuration parameters in the above implementation are parameters related to the performance and power consumption of the system of the second electronic device. In other words, the M configuration parameters in the above implementation are not application parameters of the target application itself.
[0172] There is no specific limitation on the M configuration parameters and the N optimization targets, and they can be set according to the actual scenario. Exemplarily, in some implementations, the M configuration parameters are configuration parameters of the N optimization targets associated with the target application in the second electronic device, the target application is a game application, the M configuration parameters include configuration parameters that affect the operating frequency of the central processor of the second electronic device and configuration parameters that affect the task core selection of the second electronic device, and the N optimization targets include the frame rate of the game application and the power consumption of the game application.
[0173] In the embodiment of the present application, the number of samples included in the initial data set is not specifically limited and can be set according to actual conditions. For example, the initial data set may include one or more samples. Figure 3 In step S3301 of the provided parameter optimization method, a specific example of the parameter optimization method provided in an embodiment of the present application is introduced by taking an example in which an initial data set includes a sample, wherein the sample includes a set of parameter values 0 for a set of game parameters (i.e., an example of the M first parameter values above) and a frame rate value 0 of the game corresponding to the set of parameter values 0 for the set of game parameters (i.e., an example of the first result value of one of the N optimization targets above).
[0174] In the embodiments of the present application, M and N are both positive integers greater than 1, and the relationship between M and N is not specifically limited. In one example, M may be greater than N, for example, M is equal to 3 and N is equal to 2. In another example, M may be less than N, for example, M is equal to 3 and N is equal to 4. In yet another example, M and N are equal, for example, M is equal to 3 and N is equal to 3.
[0175] The method for obtaining the initial data set by the first electronic device in the above step S610 is not specifically limited and can be determined according to actual conditions. In some implementations, the M configuration parameters are configuration parameters of the N optimization targets that affect the association of the target application in the second electronic device, and obtaining the initial data set includes: the first electronic device obtains the initial data set from the second electronic device.
[0176] In the above implementation, the M configuration parameters to be optimized are the numbers in the second electronic device. After the first electronic device obtains the initial data set from the second electronic device, it performs parameter optimization processing on the M configuration parameters associated with the initial data set, and sends the obtained parameter optimization results (i.e., M second parameter values) to the second electronic device. After that, the second electronic device can run the target application associated with the M configuration parameters when the M configuration parameters are configured as the M second parameter values, which can improve the user experience.
[0177] Optionally, in some other implementations, the first electronic device may further perform the following steps: receiving a parameter optimization instruction, wherein the parameter optimization instruction is used to instruct the first electronic device to perform parameter optimization on M configuration parameters to obtain M second parameter values.
[0178] The above-mentioned initial data set may be a data set acquired by the first electronic device before or after receiving the parameter optimization instruction, and this embodiment of the present application does not specifically limit this.
[0179] For example, the first electronic device receives the parameter optimization instruction before acquiring the initial data set, and then the first electronic device will wait until the initial data set is acquired before performing parameter optimization processing on the M configuration parameters. For another example, the first electronic device receives the parameter optimization instruction after acquiring the initial data set, and then the first electronic device can immediately perform parameter optimization processing on the M configuration parameters.
[0180] For example, the initial data set in step S610 may be Figure 3 The initial data set in step S3301 of the parameter optimization method provided, the M configuration parameters in step S610 above can be Figure 3 In the step S310 of the method provided, the M first parameter values may be the above Figure 3The set of parameter values in step S310 provided is 0, and the N optimization results in step S610 above can be Figure 3 In the step S310 of the method provided, the N first result values may be the above Figure 3 A set of result values 0 is provided in step S310.
[0181] In the above implementation, the first electronic device will be triggered to perform parameter optimization on M configuration parameters only after receiving the parameter optimization instruction. This method can avoid the first electronic device from performing parameter optimization on M configuration parameters when no parameter optimization instruction is received, thereby saving computing resources.
[0182] In step S620, the first electronic device processes at least one sample according to the optimization algorithm for each optimization target to obtain the objective function of each optimization target, so as to obtain N objective functions corresponding to the N optimization targets one by one, wherein the objective function of each optimization target represents a function with M configuration parameters as independent variables and each optimization target as a dependent variable.
[0183] The objective function of each optimization target represents a function with M configuration parameters as independent variables and each optimization target as a dependent variable, that is, the objective function of each optimization target represents a function between M configuration parameters and each optimization target.
[0184] In the embodiment of the present application, the M configuration parameters correspond to N optimization targets, and the first electronic device needs to perform the above step S620 for each of the N optimization targets.
[0185] In some implementations, the first electronic device performs the above step S620, that is, for each optimization target, processes at least one sample according to the optimization algorithm to obtain the objective function of each optimization target, including: the first electronic device performs K iterations on at least one sample according to the optimization algorithm for each optimization target to obtain the objective function of each optimization target, where K is a positive integer. It is understood that in this application, the function value of the objective function of each optimization target refers to the result value of each optimization target.
[0186] In the embodiment of the present application, there is no specific limitation on the value of K, which can be set according to actual conditions. For example, K can be, but is not limited to, 1, 3, 5, 10 or 30.
[0187] In some implementations, the optimization algorithm in the above step S620 is a Bayesian optimization algorithm.
[0188] In the above implementation, the first electronic device performs the i-th iteration process in the above K iteration processes, which can refer to Figure 7Steps S621 to S625 are shown, and steps S621 to S625 are introduced below.
[0189] In step S621, the first electronic device fits the i-th data set of the i-th iteration based on Gaussian process regression to obtain the i-th initial function of the i-th iteration, wherein i is a positive integer not exceeding K, and when i is equal to 1, the i-th data set is the initial data set; when i is an integer greater than 1 and less than or equal to K, the i-th data set includes all samples in the i-1th data set of the i-1th iteration and the i-1th sample of the i-1th iteration.
[0190] In some implementations, the first electronic device performs the above-mentioned step S621, that is, the first electronic device fits the i-th data set of the i-th iteration based on Gaussian process regression to obtain the i-th initial function of the i-th iteration, including: the first electronic device fits the i-th data set of the i-th iteration based on Gaussian process regression to establish the i-th initial Gaussian probability proxy model of the i-th iteration; the first electronic device obtains the i-th initial function according to the i-th initial Gaussian probability proxy model.
[0191] The above-mentioned first electronic device fits the i-th data set of the i-th iteration based on Gaussian process regression, and the step of establishing the i-th initial Gaussian probability proxy model of the i-th iteration may exemplarily include the following steps: the first electronic device obtains the mean and standard deviation of the result values of each optimization target in all samples in the i-th data set based on the Gaussian process; the first electronic device establishes the i-th initial Gaussian probability proxy model based on the mean and standard deviation of the result values of each optimization target in all samples in the i-th data set, and the value range of each configuration parameter in the M configuration parameters.
[0192] In the embodiment of the present application, i is a positive integer greater than or equal to 1 and less than or equal to K.
[0193] In one example, when i is equal to 1, the i-th data set is an initial data set. It can be understood that, in this example, the first electronic device performs the first iteration process.
[0194] For example, taking K equal to 3 and i equal to 1 (i.e., the first electronic device performs the first iteration process) as an example, the i-th data set in the above example can be Figure 4 In the initial data set of step S3301 shown in FIG. 1 , the i-th initial function in the above example can be the above Figure 4 The initial objective function 0 in step S3302 is shown. For contents not described in detail here, please refer to the description of step S3302 above.
[0195] In one example, when i is an integer greater than 1 and less than or equal to K, the i-th data set includes all samples in the i-1-th data set of the i-1-th iteration and the i-1-th sample of the i-1-th iteration. It can be understood that in this example, the first electronic device performs an iterative process after the first iteration. For example, the iterative process after the first iteration may be, but is not limited to, a second iterative process, or a third iterative process, etc.
[0196] For example, taking K equal to 3 and i equal to 2 (i.e., the first electronic device performs the second iteration process) as an example, the i-th data set in the above example may include the above Figure 4 All samples in the initial data set in step S3301 shown in FIG. 1 and the next sample 1 obtained by the server executing the first iteration; the i-th initial function in the above example can be the above Figure 4 The objective function 1 in step S3307 shown in the figure, for the contents not described in detail here, please refer to the description of step S3307 above.
[0197] For example, taking K equal to 3 and i equal to 3 (i.e., the first electronic device performs the third iteration process) as an example, the i-th data set in the above example may include the above Figure 4 All samples in the initial data set in step S3301 shown in FIG. 1 , the next sample 1 obtained by the server executing the first iteration, and the next sample 2 obtained by the server executing the second iteration; the i-th initial function in the above example can be the above Figure 4 The objective function 2 in step S3310 shown here, for contents not described in detail here, please refer to the description of step S3310 above.
[0198] In step S622, the first electronic device obtains the i-th sample of the i-th iteration based on the i-th acquisition function obtained by the i-th initial function, wherein the function value of the i-th acquisition function is maximum when the M parameter values of the M configuration parameters are the parameter values of the M configuration parameters included in the i-th sample, and the i-th data set does not include the i-th sample.
[0199] The parameter values of the M configuration parameters included in the above-mentioned i-th sample are also referred to as the M i-th parameter values of the M configuration parameters.
[0200] In the embodiment of the present application, the i-th sample includes M i-th parameter values of M configuration parameters and N i-th result values of N optimization results, wherein the M i-th parameter values include a parameter value of each of the M configuration parameters, the N i-th result values include a result value of each of the N optimization results, and the i-th result value of each optimization target is obtained when the M configuration parameters are configured as the M i-th parameter values. For the same configuration parameter, the parameter values of the same configuration parameter in different samples may be different.
[0201] The function value of the i-th acquisition function is the maximum when the M parameter values of the M configuration parameters are the parameter values of the M configuration parameters included in the i-th sample. For example, when each of the above optimization targets is the frame rate of the game, the function value of the i-th acquisition function is the frame rate value of the game. For another example, when each of the above optimization targets is the power consumption of the game, the function value of the i-th acquisition function is the power consumption value of the game.
[0202] In the embodiment of the present application, the method for the first electronic device to obtain the i-th acquisition function obtained based on the i-th initial function to obtain the i-th sample of the i-th iteration with the above characteristics is not specifically limited. The following introduces two implementation methods provided in the embodiment of the present application.
[0203] Implementation method 1
[0204] In implementation method one, the first electronic device obtains the i-th sample of the i-th iteration based on the i-th acquisition function obtained by the i-th initial function, including: the first electronic device obtains the M i-th parameter values of the M configuration parameters included in the i-th sample of the i-th iteration based on the i-th acquisition function obtained by the i-th initial function; the first electronic device substitutes the M i-th parameter values of the M configuration parameters included in the i-th sample of the i-th iteration into the i-th initial function, and obtains N i-th result values corresponding to the N optimization objectives included in the i-th sample.
[0205] In the first implementation, the N i-th result values corresponding to the N optimization targets in the i-th sample obtained by the first electronic device are obtained by substituting the first electronic device into the i-th initial function of the i-th iteration.
[0206] Implementation method 2
[0207] In the second implementation method, the M configuration parameters are configuration parameters of N optimization targets that affect the association of the target application in the second electronic device, based on which the first electronic device obtains the i-th sample of the i-th iteration based on the i-th acquisition function obtained based on the i-th initial function, including: the first electronic device obtains the M i-th parameter values of the M configuration parameters included in the i-th sample of the i-th iteration based on the i-th acquisition function obtained by the i-th initial function; the first electronic device sends the M i-th parameter values of the M configuration parameters included in the i-th sample of the i-th iteration to the second electronic device so that the M configuration parameters in the second electronic device are configured as the M i-th parameter values; the first electronic device receives the M i-th parameter values from the second electronic device to obtain the i-th sample of the i-th iteration.
[0208] In some test environments, the reliability of a test result is low. Based on this, in the above implementation, after the second electronic device receives M i-th parameter values, it can perform multiple groups of tests, wherein each group of tests refers to configuring the M configuration parameters in the second electronic device to the M i-th parameter values, and the second electronic device runs the target application associated with the M configuration parameters. The test results of each group of tests refer to the N i-th result values corresponding to the N optimization targets obtained after the second electronic device runs the target application based on the configured M i-th parameter values. Afterwards, the i-th result value for each optimization target can be obtained in the following manner: the second electronic device can average the multiple i-th result values of each optimization target in the multiple groups of test results corresponding to the multiple groups of tests, and use the obtained average value as the i-th result value of each optimization target.
[0209] In one example, the number of the second electronic device in the above implementation is one, that is, the above multiple groups of test processes are performed by one electronic device.
[0210] In another example, the number of second electronic devices in the above implementation is multiple, that is, the above multiple groups of test processes are executed in parallel by multiple electronic devices. Afterwards, the test results executed by the multiple second electronic devices can be summarized into one second electronic device, and the one second electronic device calculates the average value of the multiple groups of test results. This parallel processing method is beneficial to improving processing efficiency.
[0211] In the above-mentioned second implementation method, the N i-th result values corresponding one to one to the N optimization targets in the i-th sample obtained by the first electronic device are obtained by the second electronic device (for example, one or more) configuring M configuration parameters based on the M i-th parameter values in the i-th sample and experimentally measuring after running the target application.
[0212] In step S623, the first electronic device updates the i-th initial function based on the i-th sample based on Gaussian process regression to obtain the i-th prediction function outputted by the i-th iteration, wherein when i is a positive integer less than K, the i-th prediction function is the initial prediction function of the i+1-th iteration; when i is equal to K, the i-th prediction function is the objective function of each optimization objective.
[0213] In some implementations, the first electronic device executes the above-mentioned step S623, that is, the first electronic device updates the i-th initial function based on the i-th sample based on Gaussian process regression to obtain the i-th prediction function outputted by the i-th iteration, which may include the following steps: the first electronic device updates the i-th initial function based on the i-th sample based on Gaussian process regression to obtain the i-th target Gaussian probability proxy model of the i-th iteration; the first electronic device obtains the i-th prediction function outputted by the i-th iteration based on the i-th target Gaussian probability proxy model of the i-th iteration.
[0214] Exemplarily, taking K equal to 3 and i equal to 1 as an example, the i-th initial function can be the above Figure 4 The initial objective function 0 in step S3302 shown in FIG. 1 is a function of the first sample 1, and the first sample 2 is a function of the first sample 3, and the first sample 4 is a function of the first sample 5. Figure 4 The next sample 1 in step S3304 shown in FIG. 1 , the i-th target Gaussian probability proxy model can be the above Figure 4 The updated Gaussian probability proxy model 1 in step S3305 shown in FIG. 1 , the i-th prediction function can be the above Figure 4 The objective function 1 in step S3305 is shown. The details described here can be found in the above Figure 4 The first iterative processing process described by steps S3301 to S3305 is shown.
[0215] For example, taking K equal to 3 and i equal to 2 as an example, the i-th initial function can be the above Figure 4 In the objective function 1 of step S3307 shown in FIG. 1 , the i-th sample may be the above Figure 4 The next sample 2 in step S3306 shown in FIG. 1 , the i-th target Gaussian probability proxy model can be the above Figure 4 After the updated Gaussian probability proxy model 2 in step S3308 shown in FIG. 1 , the i-th prediction function may be the above Figure 4 The objective function 2 in step S3308 is shown. The details described here can be found in the above Figure 4 The second iterative processing process described by steps S3306 to S3308 is shown.
[0216] In step S624, the first electronic device determines whether a preset iteration stop condition is currently satisfied.
[0217] The first electronic device executes the above step S624, that is, after the first electronic device updates the i-th initial function based on the i-th sample based on Gaussian process regression and obtains the i-th prediction function outputted by the i-th iteration, it executes the step of determining whether the preset iteration stop condition is currently met.
[0218] In one example, when the first electronic device determines that a preset iteration stop condition is currently met, the iteration process is terminated, where i is equal to K.
[0219] For example, taking K equal to 3 as an example, the above Figure 4 The process of the server ending the iterative calculation in step S3312 shown may be a specific example of the process of the first electronic device ending the iterative processing in the above example.
[0220] In another example, when the first electronic device determines that the preset iteration stop condition is not met, after setting i=i+1, the first electronic device continues the above steps S621 to S623 (that is, the first electronic device performs the i+1th iteration processing), where i is a positive integer less than K.
[0221] For example, taking K equal to 3 and i equal to 1 as an example, the above Figure 4 The server side performing the second iteration process described in steps S3306 to S3308 shown may be a specific example of the first electronic device performing the (i+1)th iteration process in the above example.
[0222] For example, taking K equal to 3 and i equal to 2 as an example, the above Figure 4 The server side performing the third iteration process described in steps S3309 to S3311 shown may be another specific example of the first electronic device performing the (i+1)th iteration process in the above example.
[0223] The above-mentioned preset iteration stop condition is not specifically limited and can be set according to actual needs. For example, the preset iteration stop condition can be, but is not limited to, at least one of the following conditions: the total duration of the current iteration exceeds the preset total duration of the iteration, the current number of iterations exceeds the preset number of iterations, or the difference between the current iteration result and the previous iteration result is less than a preset threshold.
[0224] In the above step S624, the first electronic device can end the iterative processing (i.e., execute the following step S625) when the preset iterative stop condition is met, which can save computing resources. The first electronic device can continue to perform the next iterative processing when the preset iterative stop condition is not met, which can improve the accuracy of the iterative processing result, thereby facilitating the improvement of the accuracy of the parameter optimization result.
[0225] In step S625, the first electronic device ends the iterative process.
[0226] After the first electronic device finishes the iterative processing, the first electronic device continues to execute step S630.
[0227] In step S630, the first electronic device generates a Pareto curve based on N objective functions, wherein the Pareto curve is used to represent multiple groups of mapping relationships between N optimization objectives under multiple groups of parameter values determined based on the N objective functions, and there is a group of mapping relationships between the N optimization objectives under a group of parameter values.
[0228] The above Pareto curve is used to represent multiple sets of mapping relationships between N optimization objectives under multiple sets of parameter values determined based on N objective functions, and there is no specific limitation on the number of multiple sets of parameter values, the value of N, and the value of M. For example, the number of multiple sets of parameter values may be greater than the value of N, and the number of multiple sets of parameter values may be greater than the value of M.
[0229] In some implementations, the first electronic device performs the above-mentioned step S630, that is, the first electronic device generates a Pareto curve according to N objective functions, including: the first electronic device obtains multiple groups of mapping relationships according to the N objective functions, wherein the multiple groups of mapping relationships correspond one-to-one to the multiple groups of parameter values of the M configuration parameters, each group of parameter values includes the parameter value of each configuration parameter in the M configuration parameters, and each group of mapping relationships is a mapping relationship between N optimization objectives determined based on a corresponding group of parameter values; the first electronic device generates a Pareto curve according to the multiple groups of mapping relationships.
[0230] For example, the Pareto curve in the above implementation can be Figure 3 The Pareto curve in step S350 provided, the multiple groups of mapping relationships in the above implementation manner may be the multiple groups of mapping relationships in step S350, and the contents not described in detail here may refer to the description in step S350 above.
[0231] In the embodiment of the present application, N is a positive integer greater than 1, and the value of N can be set according to actual optimization requirements.
[0232] In one example, when N is an integer equal to 2, the Pareto curve in the above implementation is a curve in a two-dimensional coordinate system.
[0233] For example, taking N optimization targets including 2 optimization targets as an example, the Pareto curve obtained after the first electronic device executes the above step S630 can be Figure 3 The Pareto curve in step S350 of the provided parameter optimization method, for contents not described in detail here, refer to the relevant description in step S350 above.
[0234] In another example, when N is an integer greater than 2, the Pareto curve in the above implementation is a curve in a multi-dimensional space coordinate system. For example, when N is equal to 3, the Pareto curve in the above implementation is a curve in a three-dimensional space coordinate system, such as a three-dimensional space coordinate system can be a three-dimensional Cartesian coordinate (X, Y, Z), the X axis represents an optimization target, Y represents another optimization target, and Z represents another optimization target.
[0235] Exemplarily, the N objective functions in step S630 may include the following: Figure 3The function 1 in step S330 of the parameter optimization method provided, and the function 2 in step S340; the Pareto curve in the above step S630 can be the above Figure 3 The Pareto curve in step S350 is provided.
[0236] In the above step S630, the first electronic device determines multiple groups of mapping relationships according to N objective functions, and then directly generates a Pareto curve according to the determined multiple groups of mapping relationships. This implementation process is relatively simple and can improve the efficiency of the parameter optimization method.
[0237] In step S640, the first electronic device obtains M second parameter values corresponding to M configuration parameters based on the Pareto curve and N result range values corresponding to N optimization targets that meet the requirements, wherein when the M configuration parameters are configured as M second parameter values, the result value of each of the N optimization targets is within the result range value of each optimization target.
[0238] The N result range values corresponding to the N optimization targets that meet the requirements are the result range values expected by the user for each of the N optimization targets. In other words, the user has an expected result range value for the result value of each optimization target. When the result value of each optimization target meets the user's expectation of a result range value for each optimization target, the result value of each optimization target can meet the user's requirements for each optimization target. There is no specific limitation on the number of result values included in each result range value. For example, one result range value among the N result range values may include only one result value, and another result range value among the N result range values may also include multiple different result values.
[0239] For example, N optimization targets include optimization target 1 and optimization target 2. The two result range values corresponding to these two optimization targets include result range value 1 and result range value 2, wherein the range of result range value 1 is 2 to 3, and the range of result range value 2 is 4 to 5. Based on this, the value of optimization target 1 expected by the user should be between 2 and 3, and the value of optimization target 2 expected by the user should be between 4 and 5.
[0240] In some implementations, the first electronic device performs the above-mentioned step S640, that is, the first electronic device obtains M second parameter values corresponding to M configuration parameters based on the Pareto curve and N result range values corresponding to N optimization targets that meet the requirements, including: the first electronic device selects a target mapping relationship that matches the N result range values from the Pareto curve, wherein the target mapping relationship represents a mapping relationship between the N second result values corresponding to the N optimization targets, and when the M configuration parameters are configured as M second parameter values, the N result values corresponding to the N optimization targets are N second result values; the first electronic device processes the second result value of any optimization target among the N optimization targets according to the objective function of any optimization target, to obtain M second parameter values.
[0241] For example, the Pareto curve in the above implementation can be Figure 3 The Pareto curve in step S350 provided, the M second parameter values in the above implementation may be a set of target parameter values of a set of game parameters in step S350, and the contents not described in detail here may refer to the description in step S350 above.
[0242] Optionally, in other implementations, after the first electronic device obtains M second parameter values corresponding to M configuration parameters based on the Pareto curve and N result range values that correspond to N requirements, the following operations may be performed: the first electronic device sends the M second parameter values to the second electronic device, so that the M configuration parameters in the second electronic device are configured as the M second parameter values.
[0243] The conditions for triggering the first electronic device to obtain the M second parameter values are not specifically limited. For example, after the first electronic device obtains the M second parameter values, the first electronic device immediately sends the obtained M second parameter values to the second electronic device. For another example, after the first electronic device obtains the M second parameter values and after a preset period of time has passed, the first electronic device sends the obtained M second parameter values to the second electronic device.
[0244] In the above implementation, the M configuration parameters to be optimized are parameters in the second electronic device. After the first electronic device obtains the initial data set from the second electronic device, it performs parameter optimization processing on the M configuration parameters associated with the initial data set, and sends the obtained parameter optimization results (i.e., M second parameter values) to the second electronic device. After that, the second electronic device can run the target application associated with the M configuration parameters when the M configuration parameters are configured as the M second parameter values, which can improve the user experience.
[0245] In the above step S640, after the first electronic device selects a target mapping relationship that matches N result range values from the Pareto curve, it substitutes the second result value of any optimization target into the objective function of any optimization target to obtain M second parameter values. This implementation process is relatively simple and has a small amount of calculation, which can improve the efficiency of the parameter optimization method.
[0246] It should be understood that the above Figure 6 The parameter optimization method shown is for illustration only and does not constitute any limitation to the parameter optimization method provided in this application.
[0247] In an embodiment of the present application, the first electronic device processes at least one sample in the initial data set based on the optimization algorithm to obtain M second parameter values of the M configuration parameters associated with the at least one sample. When the M configuration parameters are configured as the M second parameter values, the result value of each optimization target in the N optimization targets can meet the user's needs. Compared with the need to test all possible parameter combinations one by one in the traditional technology, the parameter optimization method based on the optimization algorithm provided by the present application does not need to test all possible parameter combinations one by one, which can improve the efficiency of the parameter optimization method. In addition, after obtaining the objective function of each optimization target based on the optimization algorithm provided by the present application, the Pareto curves obtained for all objective functions (i.e., N objective functions) of all optimization targets (i.e., N optimization targets) and the N result range values corresponding to the N optimization targets that meet the needs are further determined to determine the M second parameter values corresponding to the M configuration parameters that meet the user's needs. The processing process is simple and the amount of calculation is small, which can further improve the efficiency of the parameter optimization method.
[0248] Combination of the above Figures 1 to 7 , describes in detail the application scenario and parameter optimization method of the parameter optimization method of the embodiment of the present application, and will be combined with Figure 8 and Fig. 9 , describes the device embodiment and electronic device embodiment of the present application in detail. It should be understood that the parameter optimization device and electronic device in the embodiment of the present application can execute the various parameter optimization methods of the aforementioned embodiment of the present application, that is, the specific working process of the following various products can refer to the corresponding process in the aforementioned method embodiment.
[0249] Corresponding to the parameter optimization method provided in the embodiment of the present application, the present application also provides a parameter optimization device.
[0250] Figure 8 is a schematic diagram of a parameter optimization device 800 provided in an embodiment of the present application. For example, Figure 8 The parameter optimization device 800 shown may be applied in a first electronic device, and the parameter optimization device 800 may include a processing unit 810 .
[0251] In a possible implementation, the processing unit 810 is used to: obtain an initial data set, wherein the initial data set includes at least one sample, each sample in the at least one sample includes M first parameter values corresponding to M configuration parameters and N first result values corresponding to N optimization objectives, the first result value of each optimization objective is obtained when the M configuration parameters are configured as the M first parameter values, and M and N are positive integers greater than 1; for each optimization objective, process the at least one sample according to the optimization algorithm to obtain an objective function of each optimization objective, so as to obtain N objective functions corresponding to the N optimization objectives, wherein the objective function of each optimization objective is expressed by the A function with the M configuration parameters as independent variables and each optimization objective as a dependent variable; generating a Pareto curve according to the N objective functions, wherein the Pareto curve is used to represent multiple groups of mapping relationships between the N optimization objectives under multiple groups of parameter values determined based on the N objective functions, and there is a group of mapping relationships between the N optimization objectives under a group of parameter values; based on the Pareto curve and the N result range values corresponding one-to-one to the N optimization objectives that meet the requirements, M second parameter values corresponding one-to-one to the M configuration parameters are obtained, wherein, when the M configuration parameters are configured as the M second parameter values, the result value of each of the N optimization objectives is within the result range value of each optimization objective.
[0252] In another possible implementation, the processing unit 810 is further used to: for each optimization target, perform K iterations on the at least one sample according to the optimization algorithm to obtain the objective function of each optimization target, wherein K is a positive integer; the i-th iteration processing in the K iteration processing includes: based on Gaussian process regression, fitting the i-th data set of the i-th iteration to obtain the i-th initial function of the i-th iteration, wherein i is a positive integer not exceeding K, and when i is equal to 1, the i-th data set is the initial data set; when i is an integer greater than 1 and less than or equal to K, the i-th data set includes all samples in the i-1th data set of the i-1th iteration and the i-th data set. -1 iteration; based on the i-th acquisition function obtained by the i-th initial function, obtain the i-th sample of the i-th iteration, wherein the function value of the i-th acquisition function is maximum when the M parameter values of the M configuration parameters are the parameter values of the M configuration parameters included in the i-th sample, and the i-th data set does not include the i-th sample; based on Gaussian process regression, according to the i-th sample, update the i-th initial function to obtain the i-th prediction function output by the i-th iteration, wherein when i is a positive integer less than K, the i-th prediction function is the initial prediction function of the i+1-th iteration; when i is equal to K, the i-th prediction function is the objective function of each optimization objective.
[0253] In another possible implementation, the processing unit 810 is further used to: when a preset iterative stop condition is met, end the iterative processing, where i is equal to K; when the preset iterative stop condition is not met, perform the i+1th iterative processing, where i is a positive integer less than K.
[0254] In another possible implementation, the processing unit 810 is further used to: obtain the multiple groups of mapping relationships based on the N objective functions, wherein the multiple groups of mapping relationships correspond one-to-one to the multiple groups of parameter values of the M configuration parameters, each group of parameter values includes the parameter value of each configuration parameter in the M configuration parameters, and each group of mapping relationships is a mapping relationship between the N optimization objectives determined based on a corresponding set of parameter values; generate the Pareto curve based on the multiple groups of mapping relationships.
[0255] In another possible implementation, the processing unit 810 is also used to: select a target mapping relationship that matches the N result range values from the Pareto curve, wherein the target mapping relationship represents a mapping relationship between the N second result values that correspond one-to-one to the N optimization targets, and when the M configuration parameters are configured as the M second parameter values, the N result values that correspond one-to-one to the N optimization targets are the N second result values; and process the second result value of any one of the N optimization targets according to the objective function of the any one of the N optimization targets to obtain the M second parameter values.
[0256] In another possible implementation, the optimization algorithm is a Bayesian optimization algorithm.
[0257] In another possible implementation, the M configuration parameters are configuration parameters of the N optimization targets that affect the association of the target application in the second electronic device, and the processing unit 810 is further used to: obtain the initial data set from the second electronic device.
[0258] In another possible implementation, the processing unit 810 is further used to: after obtaining M second parameter values corresponding to the M configuration parameters in a one-to-one manner based on the N result range values corresponding to the N optimization objectives that meet the requirements based on the Pareto curve, the following operations are performed: sending the M second parameter values to the second electronic device so that the M configuration parameters in the second electronic device are configured as the M second parameter values.
[0259] In another possible implementation, the target application is a game application, the M configuration parameters include configuration parameters that affect the operating frequency of the central processing unit of the second electronic device and configuration parameters that affect the task core selection of the second electronic device, and the N optimization targets include the frame rate of the game application and the power consumption of the game application.
[0260] In another possible implementation, the processing unit 810 is further used to: receive a parameter optimization instruction, wherein the parameter optimization instruction is used to instruct the first electronic device to perform parameter optimization on the M configuration parameters to obtain the M second parameter values.
[0261] It should be understood that the processing unit 810 can be used for various steps executed by the electronic device. For specific descriptions, please refer to the relevant descriptions above and will not be repeated here.
[0262] It should be noted that the above parameter optimization device 800 is embodied in the form of a functional unit. The term "unit" here can be implemented in the form of software and / or hardware, and is not specifically limited to this.
[0263] For example, a "unit" may be a software program, a hardware circuit, or a combination of the two that implements the above functions. The hardware circuit may include an application specific integrated circuit (ASIC), an electronic circuit, a processor (such as a shared processor, a dedicated processor, or a group processor, etc.) and a memory for executing one or more software or firmware programs, a combined logic circuit, and / or other suitable components that support the described functions.
[0264] Therefore, the units of each example described in the embodiments of the present application can be implemented by electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professional and technical personnel can use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of the present application.
[0265] Corresponding to the parameter optimization method provided in the embodiment of the present application, the present application also provides an electronic device.
[0266] Fig. 9 Schematic diagram of the structure of an electronic device 900 provided in an embodiment of the present application. The electronic device 900 is used to execute the corresponding steps and / or processes in the above method embodiment.
[0267] The electronic device 900 includes a processor 910, a transceiver 920, a memory 930 and a display screen 940. The processor 910 communicates with the transceiver 920, the memory 930 and the display screen 940 through internal connection paths.
[0268] It is to be understood that the structure illustrated in the embodiment of the present application does not constitute a specific limitation on the electronic device 900. In other embodiments of the present application, the electronic device 900 may include more or fewer components than shown in the figure, or combine some components, or split some components, or arrange the components differently. The components shown in the figure may be implemented in hardware, software, or a combination of software and hardware.
[0269] The processor 910 can implement the functions of the processor 910 in various possible implementations of the electronic device 900. The processor 910 may include one or more processing units, for example: the processor 910 may include an application processor (application processor, AP), a modem processor, a graphics processor (graphics processing unit, GPU), an image signal processor (image signal processor, ISP), a controller, a memory, a video codec, a digital signal processor (digital signal processor, DSP), a baseband processor, and / or a neural-network processing unit (neural-network processing unit, NPU), etc. Among them, different processing units can be independent devices or integrated in one or more processors.
[0270] The controller may be the nerve center and command center of the electronic device 900. The controller may generate an operation control signal according to the instruction operation code and the timing signal to complete the control of fetching and executing instructions.
[0271] The processor 910 is used to perform the following steps: obtaining an initial data set, wherein the initial data set includes at least one sample, each sample in the at least one sample includes M first parameter values corresponding to M configuration parameters and N first result values corresponding to N optimization targets, and the first result value of each optimization target is obtained when the M configuration parameters are configured as the M first parameter values, and M and N are positive integers greater than 1; for each optimization target, processing the at least one sample according to the optimization algorithm to obtain the objective function of each optimization target, so as to obtain N objective functions corresponding to the N optimization targets, wherein the objective function of each optimization target represents the optimization result of the M configuration parameters. A function with a parameter as an independent variable and each optimization objective as a dependent variable; generating a Pareto curve according to the N objective functions, wherein the Pareto curve is used to represent multiple groups of mapping relationships between the N optimization objectives under multiple groups of parameter values determined based on the N objective functions, and there is a group of mapping relationships between the N optimization objectives under a group of parameter values; based on the Pareto curve and the N result range values corresponding one-to-one to the N optimization objectives that meet the requirements, M second parameter values corresponding one-to-one to the M configuration parameters are obtained, wherein, when the M configuration parameters are configured as the M second parameter values, the result value of each of the N optimization objectives is within the result range value of each optimization objective.
[0272] The transceiver 920 is used to execute the step of obtaining the initial data set in the above method embodiment. Figure 3 In the parameter optimization method shown in FIG. 1 , the server obtains the initial data set. For example, Figure 6 In the parameter optimization method shown, the first electronic device acquires an initial data set.
[0273] The memory 930 is used to store instructions, and the processor 910 is used to execute the instructions stored in the memory 930 , or in other words, the processor 910 can call these stored instructions to implement the functions of the processor 910 in the electronic device 900 .
[0274] The memory 930 may be used to store computer executable program codes, which include instructions. The processor 910 executes various functional applications and data processing of the electronic device 900 by running the instructions stored in the memory 930. In other words, when the processor 910 executes the instructions stored in the memory, the processor 910 is used to execute the various steps and / or processes of the method embodiment corresponding to the above electronic device.
[0275] The memory 930 may include a program storage area and a data storage area. The program storage area may store an operating system, an application required for at least one function (such as a sound playback function, an image playback function, etc.), etc. The data storage area may store data created during the use of the electronic device 900 (such as audio data, a phone book, etc.), etc. In addition, the memory 930 may be a volatile memory or a non-volatile memory, or the memory 930 may include both a volatile memory and a non-volatile memory. The non-volatile memory may be a read-only memory (ROM), a programmable read-only memory (PROM), an erasable programmable read-only memory (EPROM), an electrically erasable programmable read-only memory (EEPROM), or a flash memory. The volatile memory may be a random access memory (RAM), which is used as an external cache. By way of example and not limitation, many forms of RAM are available, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate SDRAM (DDR SDRAM), enhanced SDRAM (ESDRAM), synchronous link DRAM (SLDRAM), and direct rambus RAM (DRRAM).
[0276] The electronic device 900 implements the display function through a GPU, a display screen 940, and an application processor. The GPU is a microprocessor for image processing, which connects the display screen 940 and the application processor. The GPU is used to perform mathematical and geometric calculations for graphics rendering. The processor 910 may include one or more GPUs, which execute program instructions to generate or change display information.
[0277] The display screen 940 is used to display images, videos, etc. The display screen 940 includes a display panel. The display panel can be a liquid crystal display (LCD), an organic light-emitting diode (OLED), an active-matrix organic light-emitting diode or an active-matrix organic light-emitting diode (AMOLED), a flexible light-emitting diode (FLED), Miniled, MicroLed, Micro-oLed, a quantum dot light-emitting diode (QLED), etc. In some embodiments, the electronic device 900 may include 1 or S display screens 940, where S is a positive integer greater than 1.
[0278] In the implementation process, each step of the above method can be completed by an integrated logic circuit of hardware in a processor or an instruction in the form of software. The steps of the method disclosed in conjunction with the embodiment of the present application can be directly embodied as a hardware processor for execution, or a combination of hardware and software units in a processor for execution. The software unit can be located in a storage medium mature in the art such as a random access memory, a flash memory, a read-only memory, a programmable read-only memory or an electrically erasable programmable memory, a register, etc. The storage medium is located in a memory, and the processor executes the instructions in the memory, and completes the steps of the above method in conjunction with its hardware. To avoid repetition, it is not described in detail here.
[0279] The embodiment of the present application provides a computer program product, when the computer program product is run on an electronic device, the electronic device executes the technical solution in the above embodiment. Its implementation principle and technical effect are similar to those of the above method-related embodiments, and will not be repeated here.
[0280] The embodiment of the present application provides a readable storage medium, the readable storage medium contains instructions, when the instructions are executed in an electronic device, the electronic device executes the technical solution of the above embodiment. The implementation principle and technical effect are similar, and will not be repeated here.
[0281] The embodiment of the present application provides a chip, the chip is used to execute instructions, when the chip is running, the technical solution in the above embodiment is executed. The implementation principle and technical effect are similar, and will not be repeated here.
[0282] In the above embodiments, it can be implemented in whole or in part by software, hardware, firmware or any combination thereof. When implemented using software, it can be implemented in whole or in part in the form of a computer program product. The computer program product includes one or more computer instructions. When the computer instructions are loaded and executed on a computer, the process or function described in the embodiment of the present application is generated in whole or in part. The computer may be a general-purpose computer, a special-purpose computer, a computer network, or other programmable device. The computer instructions may be stored in a computer-readable storage medium, or transmitted from one computer-readable storage medium to another computer-readable storage medium. For example, the computer instructions may be transmitted from a website site, computer, server or data center by wired (e.g., coaxial cable, optical fiber, digital subscriber line (DSL)) or wireless (e.g., infrared, wireless, microwave, etc.) mode to another website site, computer, server or data center. The computer-readable storage medium may be any available medium that a computer can access or a data storage device such as a server or data center that includes one or more available media integrated. The available medium may be a magnetic medium (eg, a floppy disk, a hard disk, a magnetic tape), an optical medium (eg, a digital video disc (DVD)), or a semiconductor medium (eg, a solid state disk (SSD)).
[0283] It should be understood that the "embodiment" mentioned throughout the specification means that the specific features, structures or characteristics related to the embodiment are included in at least one embodiment of the present application. Therefore, the various embodiments in the entire specification do not necessarily refer to the same embodiment. In addition, these specific features, structures or characteristics can be combined in one or more embodiments in any suitable manner. It should be understood that in various embodiments of the present application, the size of the sequence number of the above-mentioned processes does not mean the order of execution, and the execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiment of the present application.
[0284] It should also be understood that in the present application, "when", "if" and "if" all mean that the UE or base station will take corresponding actions under certain objective circumstances. It is not a time limit, and it does not require the UE or base station to make judgments when implementing it, nor does it mean that there are other limitations.
[0285] A person skilled in the art may understand that the various numerical numbers such as first and second involved in the present application are only used for the convenience of description and are not used to limit the scope of the embodiments of the present application, and also indicate the order of precedence.
[0286] In this application, elements expressed in the singular are intended to mean "one or more" rather than "one and only one", unless otherwise specified. In this application, "at least one" is intended to mean "one or more", and "more than one" is intended to mean "two or more", unless otherwise specified.
[0287] The term "and / or" in this article is merely a description of the association relationship of associated objects, indicating that there may be three relationships. For example, A and / or B can mean: A exists alone, A and B exist at the same time, and B exists alone. A can be singular or plural, and B can be singular or plural.
[0288] In this document, the term "at least one of..." or "at least one of..." means all or any combination of the listed items. For example, "at least one of A, B, and C" may mean: A exists alone, B exists alone, C exists alone, A and B exist at the same time, B and C exist at the same time, and A, B, and C exist at the same time, where A may be singular or plural, B may be singular or plural, and C may be singular or plural.
[0289] Those of ordinary skill in the art will appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professional and technical personnel can use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of this application.
[0290] Those skilled in the art can clearly understand that, for the convenience and brevity of description, the specific working processes of the systems, devices and units described above can refer to the corresponding processes in the aforementioned method embodiments and will not be repeated here.
[0291] In the several embodiments provided in the present application, it should be understood that the disclosed systems, devices and methods can be implemented in other ways. For example, the device embodiments described above are only schematic. For example, the division of the units is only a logical function division. There may be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms.
[0292] The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0293] In addition, each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit.
[0294] If the functions are implemented in the form of software functional units and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present application can be essentially or partly embodied in the form of a software product that contributes to the prior art. The computer software product is stored in a storage medium and includes several instructions for a computer device (which can be a personal computer, server, or network device, etc.) to perform all or part of the steps of the methods described in each embodiment of the present application. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM), random access memory (RAM), disk or optical disk, and other media that can store program codes.
[0295] The same or similar parts between the various embodiments in this application can refer to each other. In the various embodiments in this application, and the various implementation methods / implementation methods / implementation methods in each embodiment, if there is no special explanation and logical conflict, the terms and / or descriptions between different embodiments and the various implementation methods / implementation methods / implementation methods in each embodiment are consistent and can be referenced to each other. The technical features in different embodiments and the various implementation methods / implementation methods / implementation methods in each embodiment can be combined to form new embodiments, implementation methods, implementation methods, or implementation methods according to their inherent logical relationships. The above-described implementation methods of this application do not constitute a limitation on the scope of protection of this application.
[0296] The above is only a specific implementation of the present application, but the protection scope of the present application is not limited thereto. Any technician familiar with the technical field can easily think of changes or substitutions within the technical scope disclosed in the present application, which should be included in the protection scope of the present application. Therefore, the protection scope of the present application should be based on the protection scope of the claims. In short, the above is only a preferred embodiment of the technical solution of the present application, and is not used to limit the protection scope of the present application. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the present application should be included in the protection scope of the present application.
Claims
1. A parameter optimization method, characterized in that: Applied in a first electronic device, the method includes: Acquire an initial data set, wherein the initial data set includes at least one sample, each sample in the at least one sample includes M first parameter values corresponding to M configuration parameters one by one and N first result values corresponding to N optimization targets one by one, the first result value of each optimization target is obtained when the M configuration parameters are configured as the M first parameter values, the M configuration parameters include configuration parameters affecting the operating frequency of a central processing unit of the second electronic device and configuration parameters affecting task core selection of the second electronic device, the N optimization targets include a frame rate of a game application of the second electronic device and power consumption of the game application, and M and N are positive integers greater than 1; For each optimization target, the at least one sample is processed according to the optimization algorithm to obtain an objective function of each optimization target, so as to obtain N objective functions corresponding to the N optimization targets one by one, wherein the objective function of each optimization target represents a function with the M configuration parameters as independent variables and each optimization target as a dependent variable; Generate a Pareto curve according to the N objective functions, wherein the Pareto curve is used to represent multiple groups of mapping relationships between the N optimization objectives under multiple groups of parameter values determined based on the N objective functions, and there is a group of mapping relationships between the N optimization objectives under a group of parameter values; Based on the Pareto curve and the N result range values corresponding one-to-one to the N optimization objectives that meet the requirements, M second parameter values corresponding one-to-one to the M configuration parameters are obtained, wherein, when the M configuration parameters are configured as the M second parameter values, the result value of each optimization objective in the N optimization objectives is within the result range value of each optimization objective; Sending the M second parameter values to the second electronic device, so that the M configuration parameters in the second electronic device are configured as the M second parameter values; The step of processing the at least one sample according to the optimization algorithm for each optimization target to obtain the objective function of each optimization target includes: For each optimization target, performing K iterations on the at least one sample according to the optimization algorithm to obtain an objective function of each optimization target, where K is a positive integer; The i-th iteration process in the K iteration processes includes: Based on Gaussian process regression, fitting the i-th data set of the i-th iteration to obtain the i-th initial function of the i-th iteration, wherein i is a positive integer not exceeding K, and when i is equal to 1, the i-th data set is the initial data set; when i is an integer greater than 1 and less than or equal to K, the i-th data set includes all samples in the i-1-th data set of the i-1-th iteration and the i-1-th sample of the i-1-th iteration; Based on the i-th acquisition function obtained by the i-th initial function, obtaining the i-th sample of the i-th iteration, wherein the function value of the i-th acquisition function is maximum when the M parameter values of the M configuration parameters are the parameter values of the M configuration parameters included in the i-th sample, and the i-th data set does not include the i-th sample; Based on Gaussian process regression, the i-th initial function is updated according to the i-th sample to obtain the i-th prediction function outputted by the i-th iteration, wherein when i is a positive integer less than K, the i-th prediction function is the initial function of the i+1-th iteration; when i is equal to K, the i-th prediction function is the objective function of each optimization objective.
2. The method according to claim 1, characterized in that After the i-th initial function is updated based on the Gaussian process regression according to the i-th sample to obtain the i-th prediction function outputted by the i-th iteration, the method further includes: When the preset iteration stop condition is met, the iteration process is terminated, where i is equal to K; When the preset iteration stop condition is not met, the i+1th iteration process is performed, where i is a positive integer less than K.
3. The method according to claim 1 or 2, characterized in that: Generating a Pareto curve according to the N objective functions includes: According to the N objective functions, the multiple groups of mapping relationships are obtained, wherein the multiple groups of mapping relationships correspond to the multiple groups of parameter values of the M configuration parameters one by one, each group of parameter values includes the parameter value of each configuration parameter in the M configuration parameters, and each group of mapping relationships is a mapping relationship between the N optimization objectives determined based on a corresponding group of parameter values; The Pareto curve is generated according to the multiple groups of mapping relationships.
4. The method according to claim 1 or 2, characterized in that: The N result range values corresponding to the N optimization objectives that meet the requirements based on the Pareto curve are obtained to obtain the M second parameter values corresponding to the M configuration parameters, including: Selecting a target mapping relationship that matches the N result range values from the Pareto curve, wherein the target mapping relationship represents a mapping relationship between the N second result values corresponding one-to-one to the N optimization targets, and when the M configuration parameters are configured as the M second parameter values, the N result values corresponding one-to-one to the N optimization targets are the N second result values; The second result value of any one of the N optimization objectives is processed according to the objective function of the any one of the N optimization objectives to obtain the M second parameter values.
5. The method according to claim 1 or 2, characterized in that: The optimization algorithm is a Bayesian optimization algorithm.
6. The method according to claim 1 or 2, characterized in that: The obtaining of the initial data set comprises: The initial data set is obtained from the second electronic device.
7. The method according to claim 1 or 2, characterized in that: The method further comprises: A parameter optimization instruction is received, wherein the parameter optimization instruction is used to instruct the first electronic device to perform parameter optimization on the M configuration parameters to obtain the M second parameter values.
8. An electronic device, characterized in that: It includes one or more processors and one or more memories; wherein, the one or more memories are coupled to the one or more processors, and the one or more memories are used to store computer programs, and when the one or more processors execute the computer programs, the electronic device executes the parameter optimization method as described in any one of claims 1 to 7.
9. A chip system, the chip system is applied to electronic equipment, the chip system comprises one or more processors, characterized in that: The processor is used to call computer instructions so that the electronic device executes the parameter optimization method according to any one of claims 1 to 7.
10. A computer-readable storage medium comprising a computer program, characterized in that: When the computer program runs on an electronic device, the electronic device executes the parameter optimization method according to any one of claims 1 to 7.
