WO2019062411A1 - Method for managing and controlling background application program, storage medium, and electronic device - Google Patents

Method for managing and controlling background application program, storage medium, and electronic device Download PDF

Info

Publication number
WO2019062411A1
WO2019062411A1 PCT/CN2018/102205 CN2018102205W WO2019062411A1 WO 2019062411 A1 WO2019062411 A1 WO 2019062411A1 CN 2018102205 W CN2018102205 W CN 2018102205W WO 2019062411 A1 WO2019062411 A1 WO 2019062411A1
Authority
WO
WIPO (PCT)
Prior art keywords
background application
electronic device
reference model
sample
preset
Prior art date
Application number
PCT/CN2018/102205
Other languages
French (fr)
Chinese (zh)
Inventor
曾元清
Original Assignee
Oppo广东移动通信有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Oppo广东移动通信有限公司 filed Critical Oppo广东移动通信有限公司
Publication of WO2019062411A1 publication Critical patent/WO2019062411A1/en

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/445Program loading or initiating
    • G06F9/44594Unloading
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/30Monitoring
    • G06F11/34Recording or statistical evaluation of computer activity, e.g. of down time, of input/output operation ; Recording or statistical evaluation of user activity, e.g. usability assessment
    • G06F11/3447Performance evaluation by modeling
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/30Monitoring
    • G06F11/34Recording or statistical evaluation of computer activity, e.g. of down time, of input/output operation ; Recording or statistical evaluation of user activity, e.g. usability assessment
    • G06F11/3452Performance evaluation by statistical analysis
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F2201/00Indexing scheme relating to error detection, to error correction, and to monitoring
    • G06F2201/865Monitoring of software

Definitions

  • the present application belongs to the field of communications technologies, and in particular, to a background application control method, a storage medium, and an electronic device.
  • the application provides a background application control method, a storage medium and an electronic device, which can improve the intelligence and accuracy of the application control.
  • the embodiment of the present application provides a background application control method, which is applied to an electronic device, and the method includes:
  • Obtaining a first sample set of the preset background application acquiring a second sample set of the electronic device, where the samples in the first sample set and the second sample set respectively include the preset background application and the Denoting a plurality of characteristic information of the electronic device;
  • an embodiment of the present application provides a storage medium on which a computer program is stored, and when the computer program runs on a computer, causes the computer to execute the background application control method described above.
  • an embodiment of the present application provides an electronic device, including a processor and a memory, where the memory has a computer program, and the processor invokes the computer program, wherein the processor further performs:
  • Obtaining a first sample set of the preset background application acquiring a second sample set of the electronic device, where the samples in the first sample set and the second sample set respectively include the preset background application and the Denoting a plurality of characteristic information of the electronic device;
  • FIG. 1 is a schematic system diagram of a background application control device according to an embodiment of the present application.
  • FIG. 2 is a schematic diagram of an application scenario of a background application control device according to an embodiment of the present disclosure
  • FIG. 3 is a schematic flowchart of a background application control method according to an embodiment of the present application.
  • FIG. 4 is a schematic diagram of a sample diagram provided by an embodiment of the present application.
  • FIG. 5 is another schematic flowchart of a background application control method according to an embodiment of the present application.
  • FIG. 6 is a schematic diagram of another application scenario of a background application control device according to an embodiment of the present disclosure.
  • FIG. 7 is a schematic structural diagram of a background application control device according to an embodiment of the present application.
  • FIG. 8 is a schematic structural diagram of a part of a reference model according to an embodiment of the present disclosure.
  • FIG. 9 is another schematic structural diagram of a background application control device according to an embodiment of the present application.
  • FIG. 10 is a schematic structural diagram of an electronic device according to an embodiment of the present disclosure.
  • FIG. 11 is another schematic structural diagram of an electronic device according to an embodiment of the present application.
  • the embodiment of the present application provides a background application control method, which is applied to an electronic device, and the method includes:
  • Obtaining a first sample set of the preset background application acquiring a second sample set of the electronic device, where the samples in the first sample set and the second sample set respectively include the preset background application and the Denoting a plurality of characteristic information of the electronic device;
  • the reference model includes two sub-reference models, and the two sub-reference models are convolutional neural network models.
  • the reference model further includes a classifier
  • And inputting the first sample map and the second sample map as the training data into the reference model, and learning, and obtaining the optimized parameters of the reference model after training includes:
  • Training is performed according to the loss value to obtain the optimization parameter.
  • the training according to the loss value specifically includes:
  • Training is performed using a stochastic gradient descent method based on the loss value.
  • the synthesizing the output values of the two sub-reference models into the classifier specifically includes:
  • the output values of the two sub-reference models are combined into the classifier by different weights.
  • the synthesizing the output values of the two sub-reference models into the classifier and obtaining the probability corresponding to the plurality of prediction results specifically includes:
  • Z K is a composite value of the output values of the two sub-reference models
  • C is the number of categories of the prediction result
  • Z j is the j-th composite value
  • the obtaining the loss value according to the plurality of the prediction results and the plurality of the probabilities corresponding thereto specifically includes:
  • the training according to the loss value specifically includes:
  • a plurality of the loss values are obtained, and training is performed based on an average of the plurality of the loss values.
  • the obtaining the loss value according to the plurality of the prediction results and the plurality of the probabilities corresponding thereto specifically includes:
  • C is the number of categories of prediction results
  • y k is the true value
  • E is the average.
  • the acquiring the preset background application and the current plurality of feature information of the electronic device specifically includes:
  • the preset background application and the plurality of feature information of the electronic device are obtained.
  • the acquiring the preset background application and the current plurality of feature information of the electronic device specifically includes:
  • the preset background application and the plurality of feature information of the electronic device are obtained.
  • the electronic device may be a smart phone, a tablet computer, a desktop computer, a notebook computer, or a handheld computer.
  • FIG. 1 is a schematic diagram of a system of a background application control device according to an embodiment of the present application.
  • the background application management device is mainly configured to: obtain a first sample set of the preset background application, and acquire a second sample set of the electronic device, where the samples in the first sample set and the second sample set respectively include a preset background a plurality of feature information of the application and the electronic device; respectively constructing the first sample set and the second sample set into a two-dimensional first sample map and a second sample map; acquiring the reference model, and the first sample map And the second sample map is used as the training data input reference model to learn, obtain the optimized parameters of the trained reference model; obtain the preset background application and the current plurality of feature information of the electronic device, and form the first feature map and the second
  • the feature map generates a prediction result according to the reference model, the optimization parameter, the first feature map, and the second feature map, and then determines, according to the prediction result, whether the preset background application needs to be used, to the preset
  • FIG. 2 is a schematic diagram of an application scenario of a background application control device according to an embodiment of the present application.
  • the background application management device detects that the application running in the background of the electronic device includes a preset background application a, a preset background application b, and a preset background application c; Presetting the reference model A corresponding to the background application a, the reference model B corresponding to the preset background application b, and the reference model C corresponding to the preset background application c; whether the preset background application a needs to be The probability of use is predicted to obtain the probability a', and the probability of whether the preset background application b needs to be used is predicted by the reference model B, and the probability b' is obtained, and the reference model C needs to be used for the preset background application c.
  • the probability is predicted to obtain the probability c′; according to the probability a′, the probability b′ and the probability c′, the preset background application a running in the background, the preset background application b and the preset background application c are controlled, for example The default background application b with the lowest probability is turned off.
  • the embodiment of the present application provides a background application control method, and the execution entity of the background application control method may be a background application control device provided by the embodiment of the present application, or an electronic device integrated with the background application control device, wherein
  • the background application management device can be implemented in hardware or software.
  • the background application management method includes: acquiring a first sample set of the preset background application, and acquiring a second sample set of the electronic device, wherein the samples in the first sample set and the second sample set respectively include a preset background application And a plurality of feature information of the electronic device; respectively constructing the first sample set and the second sample set into a two-dimensional first sample map and a second sample map; acquiring the reference model, and the first sample map and the first sample
  • the two sample map is used as the training data input reference model to learn, obtain the optimized parameters of the trained reference model, obtain the preset background application and the current plurality of feature information of the electronic device, and form the first feature map and the second feature map.
  • FIG. 3 is a schematic flowchart of a background application control method according to an embodiment of the present application.
  • the background application management and control method provided by the embodiment of the present application is applied to an electronic device, and the specific process may be as follows:
  • the sample of the first sample set may include usage information of the preset application
  • the sample of the second sample set may include at least one of status information, time information, and location information of the electronic device.
  • the usage information of the application may include, for example, usage time, background time, application type, application association information, and the like.
  • the status information of the electronic device may include, for example, screen brightness, state of charge, remaining power, WIFI status, and the like.
  • the time information may include, for example, a current time point, a work day, and the like.
  • the location information may include, for example, GPS positioning, base station positioning, WIFI positioning, and the like.
  • a plurality of characteristic information is collected as a sample, and then a first sample set of the preset application and a second sample set of the electronic device are formed.
  • the preset application may be any application installed in the electronic device, such as a communication application, a multimedia application, a game application, a news application, or a shopping application.
  • the sample set may include: a plurality of samples collected according to a preset frequency during a historical time period.
  • the historical time period can be, for example, within the past 15 days, within 7 days, and the like.
  • the preset frequency can be, for example, every 10 minutes, 30 minutes, and the like.
  • the first sample set and the second sample set are respectively constructed into a two-dimensional first sample map and a second sample map.
  • the samples in the first sample set and the second sample set are represented by numerical values, such as the state of charge, which can be represented by 0 or 1 as being uncharged and being charged. For example, if the remaining power can be used to indicate the remaining power with 00-100, or divide the power into 5 levels, use 0-5 to indicate the remaining power of different levels.
  • the first sample map and the second sample map may take a map such as 12 ⁇ 12 pixel points, and each pixel point corresponds to one sample, that is, one feature information. Of course, the sample map can adjust the pixels it includes as needed, such as 10 ⁇ 10, 16 ⁇ 16, 12 ⁇ 16, and the like. The larger the amount of data, the more accurate the subsequent predictions. It should be noted that the pixel point specific performance may be 1 or (0, 1).
  • the acquired plurality of feature information is stored in a two-dimensional mathematical image, similar to a grayscale image, that is, different feature values are recorded at pixel points (x, y).
  • FIG. 4 is a schematic diagram of a second sample diagram provided by an embodiment of the present application.
  • the information may be divided into several types of feature information, for example, the feature information of the electronic device is divided into four types: state information, time information, network information, and location information of the electronic device, and then the four types of feature information are respectively formed into one sub-category.
  • Sample map 3061, then four subsample map 3061 matrices are arranged to form a large second sample map 306.
  • the subsample image 3061 can adopt, for example, 6 ⁇ 6 pixels. If the feature information is insufficient to fill the subsample graph, the position is zero-padded.
  • the four subsample views 3061 form a 12 x 12 large second sample map 306. Both the second sample map 306 and the subsample map 3061 are two-dimensional maps.
  • the first sample image of the background application may also be set by a method similar to the second sample image.
  • the reference model includes two sub-reference models, and the two sub-reference models are convolutional neural network models.
  • the sub-reference model can be a hybrid neural network model, a Gaussian mixture model, or the like.
  • the two sub-reference models are weak learners, and the two weak learners combine to form a strong learner.
  • Integrated learning accomplishes learning tasks by building and combining multiple weak learners.
  • Applying integrated learning to the classification of user behavior characteristics, by combining two independent convolutional neural networks, a strong learner can be built to dig into the user's usage habits. As users use the device for a longer period of time, the training will become more and more complete, and the system prediction will become more accurate.
  • the sub-reference model includes a convolutional layer and a fully connected layer that are sequentially connected, and the reference model also includes a classifier.
  • the reference model mainly includes a network structure part and a network training part, wherein the network structure part includes a convolution layer and a full connection layer connected in sequence.
  • a pooling layer may also be included between the convolutional layer and the fully connected layer.
  • the network structure part of the convolutional neural network model reference model may include a seven-layer network, the first five layers are convolution layers, the convolution kernel size is unified to 3 ⁇ 3, and the sliding step length is unified to 1, due to a small dimension.
  • the pooling layer may not be used, and the latter two layers are fully connected layers, which are 20 neurons and 2 neurons, respectively.
  • the network structure part may further include other layers of convolution layers, such as a 3-layer convolution layer, a 5-layer convolution layer, a 9-layer convolution layer, etc., and may also include a full-connection layer of other layers. Such as a 1-layer fully connected layer, a 3-layer fully connected layer, and the like. It is also possible to increase the pooling layer or not to use the pooling layer.
  • the convolution kernel size can be other sizes, such as 2 x 2. Convolution kernels of different sizes can also be used for different convolutional layers. For example, the first layer convolution layer uses a 3 ⁇ 3 convolution kernel, and the other layer convolution layer uses a 2 ⁇ 2 convolution kernel.
  • the sliding step size can be unified to 2 or other values, or a different sliding step size can be used, such as a sliding step of 2 for the first layer and a sliding step of 1 for the other layers.
  • the network training part includes a classifier, and the classifier can be a Softmax classifier.
  • FIG. 5 is another schematic flowchart of a background application control method according to an embodiment of the present application.
  • the training methods specifically include:
  • the first sample map and the second sample map are respectively input as training data into two sub-reference models.
  • the output values of the two sub-reference models are combined into the input classifier, and the output values of the two sub-reference models can be combined into the input classifier according to different weights.
  • weighting the output values of the two sub-reference models two shallower convolutional neural networks can be used as weak classifiers and then merged into strong classifiers.
  • the specific formula is as follows:
  • Z K APP is the output value of the first sub-reference model
  • Z K Device is the output value of the second sub-reference model
  • the probability of obtaining the prediction result may be based on the first preset formula to synthesize the output values of the two sub-reference models into the input classifier, and obtain a probability corresponding to the plurality of prediction results, wherein the first preset formula is:
  • Z K is the composite value of the output values of the two sub-reference models
  • C is the number of categories of the prediction results
  • obtaining the loss value may obtain a loss value according to the plurality of prediction results and the plurality of probabilities corresponding thereto according to the second preset formula, where the second preset formula is:
  • Training can be performed using a stochastic gradient descent method based on the loss value. Training can also be performed according to the batch gradient descent method or the gradient descent method.
  • Training is performed using the stochastic gradient descent method, and the training can be completed when the loss value is equal to or less than the preset loss value. It is also possible to complete the training when there are no changes in the two or more loss values continuously acquired. Of course, it is also possible to directly set the number of iterations of the random gradient descent method according to the loss value. After the number of iterations is completed, the training is completed. After the training is completed, each parameter of the reference model at this time is obtained, and the each parameter is saved as an optimization parameter, and when the prediction is needed later, the optimization parameter is used for prediction.
  • the obtained loss value may be obtained according to the third preset formula according to the plurality of sets of parameters, and each set of parameters includes a plurality of prediction results and a plurality of probability corresponding to the obtained loss values, wherein the third preset formula is:
  • C is the number of categories of prediction results
  • y k is the true value
  • E is the average.
  • the optimal parameters can be trained in a small batch manner. If the batch size is 128, E in the third preset formula is expressed as the average of 128 loss values.
  • multiple sample sets may be acquired first, and multiple sample sets are constructed into multiple two-dimensional sample images, and then multiple sample images are input as training data into the reference model to obtain multiple loss values, and then multiple loss values are obtained. average of.
  • the current background application If it is necessary to determine whether the current background application is cleanable, obtain a preset background application and a plurality of current feature information of the electronic device, and form a two-dimensional first feature map and a second feature map, and the first feature map and the second feature are obtained.
  • the graph is input to the reference model, and the reference model is calculated based on the optimized parameters to obtain the predicted value. Determine if the default background application needs to be cleaned up.
  • the training process of the reference model can be completed on the server side or on the electronic device side.
  • the training process and the actual prediction process of the reference model are completed on the server side
  • the preset background application and the current multiple feature information of the electronic device may be formed into a feature map and input to the server.
  • the prediction result is sent to the electronic device end, and the electronic device controls the preset background application according to the prediction result.
  • the preset background application and the current plurality of feature information of the electronic device may be formed into the first feature map and the first feature map.
  • the second feature map is input to the electronic device, and after the actual prediction of the electronic device is completed, the electronic device controls the preset background application according to the predicted result.
  • FIG. 6 is a schematic diagram of another application scenario of a background application control device according to an embodiment of the present disclosure.
  • the training process of the reference model is completed on the server side
  • the actual prediction process of the reference model is completed on the electronic device side
  • the optimized reference model needs to be used
  • the preset background application and the plurality of feature information of the electronic device can be formed.
  • the first feature map and the second feature map are input to the electronic device, and after the actual prediction of the electronic device is completed, the electronic device controls the preset background application according to the predicted result.
  • the trained reference model file (model file) can be transplanted to the smart device. If it is necessary to determine whether the current background application can be cleaned up, the current sample image is updated, and the trained reference model file (model file) is input. , the calculation can get the predicted value.
  • the method before acquiring the preset background application and the current plurality of feature information of the electronic device, the method includes:
  • a preset background application is detected to enter the background. If the background is entered, the preset background application and the current plurality of feature information of the electronic device are acquired, and the first feature map and the second feature map are formed. Then, the prediction is performed according to the reference model, the optimization parameter, the first feature map, and the second feature map, and the prediction result is generated, and the preset background application is controlled according to the prediction result.
  • the method before acquiring the preset background application and the current plurality of feature information of the electronic device, the method includes:
  • the preset time is obtained. If the current system time reaches the preset time, the preset background application and the current plurality of feature information of the electronic device are acquired, and the first feature map and the second feature map are formed.
  • the preset time can be a time point in the day, such as 9 am, or several time points in the day, such as 9 am, 6 pm, and the like. It can also be one or several time points in multiple days. Then, the prediction result is generated according to the reference model, the optimization parameter, the first feature map, and the second feature map, and the preset background application is controlled according to the prediction result.
  • the reference model may also include multiple sub-reference models, such as three, five, and the like. Each sub-reference model can input different sample maps, or two or more of them can input the same sample map.
  • the background application control method acquires the second sample set of the electronic device by acquiring the first sample set of the preset background application; and the first sample set and the second sample set are obtained. Constructing a two-dimensional first sample map and a second sample map respectively; and inputting the first sample map and the second sample map as training data into the reference model, and learning, obtaining the optimized parameters of the trained reference model; Setting a plurality of feature information of the background application and the electronic device, and forming a first feature map and a second feature map, and generating a prediction result according to the reference model, the optimization parameter, the first feature map, and the second feature map, and according to the prediction As a result, the default background application is managed.
  • FIG. 7 is a schematic structural diagram of a background application control device according to an embodiment of the present disclosure.
  • the background application management device 300 is applied to an electronic device, and the background application management device 300 includes an obtaining unit 301, a sample map generating unit 302, a training unit 303, and a control unit 304.
  • the obtaining unit 301 is configured to acquire a first sample set of the preset background application, and acquire a second sample set of the electronic device, where the samples in the first sample set and the second sample set respectively include a preset background application. And multiple feature information of the electronic device.
  • the sample of the first sample set may include usage information of the preset background application
  • the sample of the second sample set may include at least one of status information, time information, and location information of the electronic device.
  • the usage information of the application may include, for example, usage time, background time, application type, application association information, and the like.
  • the status information of the electronic device may include, for example, screen brightness, state of charge, remaining power, WIFI status, and the like.
  • the time information may include, for example, a current time period, a work day, and the like.
  • the location information may include, for example, GPS positioning, base station positioning, WIFI positioning, and the like.
  • a plurality of feature information is collected as a sample, and then a first sample set of the preset background application and a second sample set of the electronic device are formed.
  • the default background application may be any application installed in the electronic device, such as a communication application, a multimedia application, a game application, a news application, or a shopping application.
  • the sample set may include a plurality of samples acquired at a preset frequency during a historical time period.
  • the historical time period can be, for example, within the past 15 days, within 7 days, and the like.
  • the preset frequency can be, for example, every 10 minutes, 30 minutes, and the like.
  • the sample map generating unit 302 is configured to respectively construct the first sample set and the second sample set into a two-dimensional first sample map and a second sample map.
  • the samples in the first sample set and the second sample set are represented by numerical values, such as the state of charge, which can be represented by 0 or 1 as being uncharged and being charged. For example, if the remaining power can be used to indicate the remaining power with 00-100, or divide the power into 5 levels, use 0-5 to indicate the remaining power of different levels.
  • the first sample map and the second sample map may take a map such as 12 ⁇ 12 pixel points, and each pixel point corresponds to one sample, that is, one feature information. Of course, the sample map can adjust the pixels it includes as needed, such as 10 ⁇ 10, 16 ⁇ 16, 12 ⁇ 16, and the like. The larger the amount of data, the more accurate the subsequent predictions. It should be noted that the pixel point specific performance may be 1 or (0, 1).
  • the acquired plurality of feature information is stored in a two-dimensional mathematical image, similar to a grayscale image, that is, different feature values are recorded at pixel points (x, y).
  • the information may be divided into several types of feature information, for example, the feature information of the electronic device is divided into four categories: state information, time information, network information, and location information of the electronic device, and then the four types of feature information are respectively formed into one sub-category.
  • the sample map is then set up to form a large second sample map.
  • the subsample image can be used as 6 ⁇ 6 pixels. If the feature information is not enough to fill the subsample graph, the position is zero-filled.
  • the four subsample plots form a 12 x 12 large second sample plot. Both the second sample map and the subsample map are two-dimensional maps.
  • the training unit 303 is configured to acquire a reference model, and input the first sample map and the second sample map as training data into the reference model, and learn to obtain optimized parameters of the trained reference model.
  • the reference model includes two sub-reference models, and the two sub-reference models are convolutional neural network models.
  • the sub-reference model can be a hybrid neural network model, a Gaussian mixture model, or the like.
  • FIG. 8 is a partial structural diagram of a reference model according to an embodiment of the present application.
  • the reference model includes two sub-reference models, and the two sub-reference models are convolutional neural network models.
  • the sub-reference models may be hybrid neural network models, Gaussian mixture models, and the like.
  • the convolutional neural network model includes a convolutional layer 3031 and a fully connected layer 3032 that are sequentially connected, and the reference model further includes a classifier 3033.
  • the reference model mainly includes a network structure part and a network training part, wherein the network structure part includes a convolution layer 3031 and a full connection layer 3032 which are sequentially connected.
  • a pooling layer (not shown) may also be included between the convoluted layer 3031 and the fully connected layer 3032.
  • the first sample map 305 and the second sample map 306 are respectively input as training data into the convolution layer 3031 of the two sub-reference models.
  • the network structure part of the convolutional neural network model reference model may include a seven-layer network, the first five layers are convolutional layers 3031, the convolution kernel size is uniformly 3 ⁇ 3, and the sliding step length is unified to 1, due to the dimension Small, you can not use the pooling layer, the latter two layers are fully connected layers 3032, respectively 20 neurons, 2 neurons.
  • the network structure part may further include other layers of convolution layers, such as a 3-layer convolution layer, a 7-layer convolution layer, a 9-layer convolution layer, etc., and may also include a full-connection layer of other layers. Such as a 1-layer fully connected layer, a 3-layer fully connected layer, and the like. It is also possible to increase the pooling layer or not to use the pooling layer.
  • the convolution kernel size can be other sizes, such as 2 x 2. Convolution kernels of different sizes can also be used for different convolutional layers. For example, the first layer convolution layer uses a 3 ⁇ 3 convolution kernel, and the other layer convolution layer uses a 2 ⁇ 2 convolution kernel.
  • the sliding step size can be unified to 2 or other values, or a different sliding step size can be used, such as a sliding step of 2 for the first layer and a sliding step of 1 for the other layers.
  • the network training portion includes a classifier 3033, and the classifier can be a Softmax classifier.
  • FIG. 9 is another schematic structural diagram of a background application control device according to an embodiment of the present application.
  • the training unit 303 includes two network structure portions, each network structure portion including a convolution layer 3031, a full connection layer 3032, and the training unit further includes a classifier 3033, a loss calculator 3034, and a training subunit 3035.
  • the convolution layer 3031 can be configured to input the first sample map and the second sample map as training data into the convolution layers of the two sub-reference models respectively to obtain a first intermediate value and a second intermediate value.
  • the fully connected layer 3032 can be configured to process the first intermediate value and the second intermediate value to obtain a third intermediate value and a fourth intermediate value.
  • the classifier 3033 can be configured to synthesize the output values of the two sub-reference models into the input classifier and obtain the probability corresponding to the plurality of prediction results.
  • the third intermediate value and the fourth intermediate value are combined into the input classifier to obtain a probability corresponding to the plurality of prediction results.
  • the output values of the two sub-reference models are combined into the input classifier, and the output values of the two sub-reference models can be combined into the input classifier according to different weights.
  • weighting the output values of the two sub-reference models two shallower convolutional neural networks can be used as weak classifiers and then merged into strong classifiers.
  • the specific formula is as follows:
  • Z K APP is the output value of the first sub-reference model
  • Z K Device is the output value of the second sub-reference model
  • the probability of obtaining the prediction result may be based on the first preset formula to synthesize the output values of the two sub-reference models into the input classifier, and obtain a probability corresponding to the plurality of prediction results, wherein the first preset formula is:
  • Z K is a composite value of the output values of the two sub-reference models, that is, a composite value of the third intermediate value and the fourth intermediate value
  • C is the number of categories of the prediction result
  • Z j is the j-th composite value
  • the loss value calculator 3034 can be used to obtain a loss value based on a plurality of prediction results and a plurality of probabilities corresponding thereto.
  • the obtained loss value may be based on the second preset formula, and the loss value is obtained according to the multiple prediction results and the multiple probabilities corresponding thereto, where the second preset formula is:
  • the training sub-unit 3035 can be used to train according to the loss value to obtain optimized parameters.
  • the random gradient descent method can be used for training according to the loss value. Training can also be performed according to the gradient descent method or the batch gradient descent method.
  • Training is performed using the stochastic gradient descent method, and the training can be completed when the loss value is equal to or less than the preset loss value. It is also possible to complete the training when there are no changes in the two or more loss values continuously acquired. Of course, it is also possible to directly set the number of iterations of the random gradient descent method according to the loss value. After the number of iterations is completed, the training is completed. After the training is completed, each parameter of the reference model at this time is obtained, and the each parameter is saved as an optimization parameter, and when the prediction is needed later, the optimization parameter is used for prediction.
  • the obtained loss value may be obtained according to the third preset formula according to the plurality of sets of parameters, and each set of parameters includes a plurality of prediction results and a plurality of probability corresponding to the obtained loss values, wherein the third preset formula is:
  • C is the number of categories of prediction results
  • y k is the true value
  • E is the average.
  • the optimal parameters can be trained in a small batch manner. If the batch size is 128, E in the third preset formula is expressed as the average of 128 loss values.
  • multiple sample sets may be acquired first, and multiple sample sets are constructed into multiple two-dimensional sample images, and then multiple sample images are input as training data into the reference model to obtain multiple loss values, and then multiple loss values are obtained. average of.
  • the control unit 304 is configured to acquire a plurality of feature information of the preset background application and the electronic device, and form a first feature map and a second feature map according to the reference model, the optimization parameter, the first feature map, and the second feature map. , generate prediction results, and control the default background application based on the prediction results.
  • the current background application If it is necessary to determine whether the current background application is cleanable, obtain a preset background application and a plurality of current feature information of the electronic device, and form a two-dimensional first feature map and a second feature map, and the first feature map and the second feature are obtained.
  • the graph is input to the reference model, and the reference model is calculated based on the optimized parameters to obtain the predicted value. Determine if the default background application needs to be cleaned up.
  • the training process of the reference model can be completed on the server side or on the electronic device side.
  • the training process and the actual prediction process of the reference model are completed on the server side
  • the preset background application and the current multiple feature information of the electronic device may be formed into a feature map and input to the server.
  • the prediction result is sent to the electronic device end, and the electronic device controls the preset background application according to the prediction result.
  • the preset background application and the current plurality of feature information of the electronic device may be formed into the first feature map and the first feature map.
  • the second feature map is input to the electronic device, and after the actual prediction of the electronic device is completed, the electronic device controls the preset background application according to the predicted result.
  • control unit 304 is further configured to detect whether the preset background application enters the background, and if the background is entered, acquire the preset background application and the plurality of feature information of the electronic device, and form the first feature. Figure and second feature map. Then, the prediction is performed according to the reference model, the optimization parameter, the first feature map, and the second feature map, and the prediction result is generated, and the preset background application is controlled according to the prediction result.
  • control unit 304 is further configured to acquire a preset time, and if the current system time reaches the preset time, acquire the preset background application and the plurality of feature information of the electronic device, and form the first feature.
  • the preset time can be a time point in the day, such as 9 am, or several time points in the day, such as 9 am, 6 pm, and the like. It can also be one or several time points in multiple days. Then, the prediction result is generated according to the reference model, the optimization parameter, the first feature map, and the second feature map, and the preset background application is controlled according to the prediction result.
  • the reference model may also include multiple sub-reference models, such as three, five, and the like. Each sub-reference model can input different sample maps, or two or more of them can input the same sample map.
  • the background application control device of the embodiment of the present application is applied to an electronic device, and acquires a second sample set of the electronic device by acquiring a first sample set of the preset background application;
  • the second sample set is respectively constructed into a two-dimensional first sample map and a second sample map; the first sample map and the second sample map are input as reference data for training data, and learning is performed to obtain an optimized reference model after training.
  • control the default background application based on the predicted results. It can improve the accuracy of forecasting the default background application, thus improving the intelligence and accuracy of controlling the application entering the background.
  • the background application control device and the background application control method in the above embodiment are in the same concept, and any method provided in the embodiment of the background application management and control method may be run on the background application control device.
  • any method provided in the embodiment of the background application management and control method may be run on the background application control device.
  • details of the implementation process refer to the embodiment of the background application management and control method, which is not described here.
  • the electronic device 400 includes a processor 401 and a memory 402.
  • the processor 401 is electrically connected to the memory 402.
  • the processor 400 is a control center of the electronic device 400 that connects various portions of the entire electronic device using various interfaces and lines, executes the electronic by running or loading a computer program stored in the memory 402, and recalling data stored in the memory 402.
  • the memory 402 can be used to store software programs and modules, and the processor 401 executes various functional applications and data processing by running computer programs and modules stored in the memory 402.
  • the memory 402 can mainly include a storage program area and a storage data area, wherein the storage program area can store an operating system, a computer program required for at least one function (such as a sound playing function, an image playing function, etc.), and the like; the storage data area can be stored according to Data created by the use of electronic devices, etc.
  • memory 402 can include high speed random access memory, and can also include non-volatile memory, such as at least one magnetic disk storage device, flash memory device, or other volatile solid state storage device. Accordingly, memory 402 can also include a memory controller to provide processor 401 access to memory 402.
  • the processor 401 in the electronic device 400 loads the instructions corresponding to the process of one or more computer programs into the memory 402 according to the following process, and is stored in the memory 402 by the processor 401.
  • the computer program thus implements various functions as follows:
  • Obtaining a first sample set of the preset background application acquiring a second sample set of the electronic device; and constructing the first sample set and the second sample set into a two-dimensional first sample map and a second sample map respectively;
  • the first sample map and the second sample map are input as reference data into the reference model, and the optimized parameters of the reference model are obtained after the training;
  • the preset background application and the current plurality of characteristic information of the electronic device are obtained, and the first A feature map and a second feature map generate a prediction result according to the reference model, the optimization parameter, the first feature map, and the second feature map, and control the preset background application according to the prediction result. It can improve the accuracy of forecasting the default background application, thus improving the intelligence and accuracy of controlling the application entering the background.
  • the processor 401 is further configured to:
  • the reference model includes two sub-reference models, and the two sub-reference models are convolutional neural network models.
  • the processor 401 is further configured to:
  • the reference model also includes a classifier
  • the first sample map and the second sample map are respectively input as training data into two sub-reference models
  • Training is performed according to the loss value to obtain optimized parameters.
  • the processor 401 is further configured to:
  • the output values of the two sub-reference models are combined into different input weights.
  • the processor 401 is further configured to:
  • Training is performed using a stochastic gradient descent method based on the loss value.
  • the processor 401 is further configured to:
  • the output values of the two sub-reference models are combined into the input classifier based on the first preset formula, and the probability corresponding to the plurality of prediction results is obtained, wherein the first preset formula is:
  • Z K is the composite value of the output values of the two sub-reference models
  • C is the number of categories of the prediction results
  • Z j is the j-th composite value
  • the processor 401 is further configured to:
  • the processor 401 is further configured to:
  • the processor 401 is further configured to:
  • the loss value is obtained according to the plurality of prediction results and the plurality of probabilities corresponding thereto according to the third preset formula, wherein the third preset formula is:
  • C is the number of categories of prediction results
  • y k is the true value
  • E is the average.
  • the electronic device acquires the second sample set of the electronic device by acquiring the first sample set of the preset background application; and constructs the first sample set and the second sample set respectively.
  • the first sample map and the second sample map are two-dimensional; the first sample map and the second sample map are input as training data into the reference model, and the optimized parameters of the reference model after training are obtained; and the preset background application is obtained.
  • a plurality of feature information of the program and the electronic device, and forming a first feature map and a second feature map, generating a prediction result according to the reference model, the optimization parameter, the first feature map, and the second feature map, and predicting the prediction according to the prediction result Set the background application to manage. It can improve the accuracy of forecasting the default background application, thus improving the intelligence and accuracy of controlling the application entering the background.
  • the electronic device 400 may further include: a display 403, a radio frequency circuit 404, an audio circuit 405, and a power source 406.
  • the display 403, the radio frequency circuit 404, the audio circuit 405, and the power source 406 are electrically connected to the processor 401, respectively.
  • Display 403 can be used to display information entered by a user or information provided to a user, as well as various graphical user interfaces, which can be composed of graphics, text, icons, video, and any combination thereof.
  • the display 403 can include a display panel.
  • the display panel can be configured in the form of a liquid crystal display (LCD), or an organic light-emitting diode (OLED).
  • LCD liquid crystal display
  • OLED organic light-emitting diode
  • the radio frequency circuit 404 can be used to transmit and receive radio frequency signals to establish wireless communication with network devices or other electronic devices through wireless communication, and to transmit and receive signals with network devices or other electronic devices.
  • the audio circuit 405 can be used to provide an audio interface between the user and the electronic device through the speaker and the microphone.
  • Power source 406 can be used to power various components of electronic device 400.
  • the power supply 406 can be logically coupled to the processor 401 through a power management system to enable functions such as managing charging, discharging, and power management through the power management system.
  • the electronic device 400 may further include a camera, a Bluetooth module, and the like, and details are not described herein.
  • the embodiment of the present application further provides a storage medium, where the storage medium stores a computer program, and when the computer program runs on the computer, causes the computer to execute the application management and control method in any of the above embodiments, for example, acquiring a preset background application.
  • a first sample set acquiring a second sample set of the electronic device; respectively constructing the first sample set and the second sample set into a two-dimensional first sample map and a second sample map;
  • the second sample map is used as the training data input reference model to learn, obtain the optimized parameters of the trained reference model; obtain the preset background application and the current plurality of feature information of the electronic device, and form the first feature map and the second
  • the feature map generates a prediction result according to the reference model, the optimization parameter, the first feature map, and the second feature map, and controls the preset background application according to the prediction result.
  • the storage medium may be a magnetic disk, an optical disk, a read only memory (ROM), or a random access memory (RAM).
  • ROM read only memory
  • RAM random access memory
  • a general tester in the field can understand all or part of the process of implementing the background application control method of the embodiment of the present application, and the related program can be controlled by a computer program.
  • the computer program can be stored in a computer readable storage medium, such as in a memory of the electronic device, and executed by at least one processor in the electronic device, and can include, for example, a background application during execution.
  • the storage medium may be a magnetic disk, an optical disk, a read only memory, a random access memory, or the like.
  • each functional module may be integrated into one processing chip, or each module may exist physically separately, or two or more modules may be integrated into one module.
  • the above integrated modules can be implemented in the form of hardware or in the form of software functional modules.
  • An integrated module, if implemented in the form of a software functional module and sold or used as a standalone product, may also be stored in a computer readable storage medium such as a read only memory, a magnetic disk or an optical disk.

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Software Systems (AREA)
  • Computer Hardware Design (AREA)
  • Evolutionary Biology (AREA)
  • Quality & Reliability (AREA)
  • Bioinformatics & Computational Biology (AREA)
  • Life Sciences & Earth Sciences (AREA)
  • Bioinformatics & Cheminformatics (AREA)
  • Probability & Statistics with Applications (AREA)
  • Management, Administration, Business Operations System, And Electronic Commerce (AREA)

Abstract

Disclosed are a method for managing and controlling a background application program, a storage medium, and an electronic device. The method comprises: inputting a first sample image and a second sample image of a pre-set background application program and an electronic device into a reference model for learning, so as to obtain optimized parameters; and acquiring a first feature image and a second feature image of the pre-set background application program and the electronic device, and generating a prediction result according to the reference model, the optimized parameter, the first feature image and the second feature image, so as to manage and control the pre-set background application program.

Description

后台应用程序管控方法、存储介质及电子设备Background application management method, storage medium and electronic device
本申请要求于2017年09月30日提交中国专利局、申请号为201710917794.1、申请名称为“后台应用程序管控方法、装置、存储介质及电子设备”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。This application claims the priority of the Chinese patent application filed on September 30, 2017, the Chinese Patent Office, the application number is 201710917794.1, and the application name is “background application control method, device, storage medium and electronic device”. The citations are incorporated herein by reference.
技术领域Technical field
本申请属于通信技术领域,尤其涉及一种后台应用程序管控方法、存储介质及电子设备。The present application belongs to the field of communications technologies, and in particular, to a background application control method, a storage medium, and an electronic device.
背景技术Background technique
随着电子技术的发展,人们通常在电子设备上安装很多应用程序。当用户在电子设备中打开多个应用程序时,多个应用程序会在电子设备的后台运行。这些后台运行的应用程序会占用电子设备的内存,并且增加功耗。With the development of electronic technology, people often install many applications on electronic devices. When a user opens multiple applications in an electronic device, multiple applications run in the background of the electronic device. These background-running applications consume the memory of the electronic device and increase power consumption.
发明内容Summary of the invention
本申请提供一种后台应用程序管控方法、存储介质及电子设备,能够提升对应用程序进行管控的智能化和准确性。The application provides a background application control method, a storage medium and an electronic device, which can improve the intelligence and accuracy of the application control.
第一方面,本申请实施例提供一种后台应用程序管控方法,应用于电子设备,所述方法包括:In a first aspect, the embodiment of the present application provides a background application control method, which is applied to an electronic device, and the method includes:
获取预设后台应用程序的第一样本集,获取所述电子设备的第二样本集,其中所述第一样本集和第二样本集中的样本分别包括所述预设后台应用程序和所述电子设备的多个特征信息;Obtaining a first sample set of the preset background application, acquiring a second sample set of the electronic device, where the samples in the first sample set and the second sample set respectively include the preset background application and the Denoting a plurality of characteristic information of the electronic device;
将所述第一样本集和所述第二样本集分别构建成二维的第一样本图和第二样本图;Constructing the first sample set and the second sample set into a two-dimensional first sample map and a second sample map, respectively;
获取参考模型,并将所述第一样本图和所述第二样本图作为训练数据输入所述参考模型,进行学习,得到训练后的所述参考模型的优化参数;Obtaining a reference model, and inputting the first sample map and the second sample map as training data into the reference model, performing learning, and obtaining optimized parameters of the reference model after training;
获取所述预设后台应用程序和所述电子设备当前的多个特征信息,并形成第一特征图和第二特征图,根据所述参考模型、所述优化参数、所述第一特征图以及所述第二特征图,生成预测结果,并根据所述预测结果对所述预设后台应用程序进行管控。Acquiring the preset background application and the current plurality of feature information of the electronic device, and forming a first feature map and a second feature map, according to the reference model, the optimization parameter, the first feature map, and The second feature map generates a prediction result, and controls the preset background application according to the prediction result.
第二方面,本申请实施例提供一种存储介质,其上存储有计算机程序,当所述计算机程序在计算机上运行时,使得所述计算机执行上述的后台应用程序管控方法。In a second aspect, an embodiment of the present application provides a storage medium on which a computer program is stored, and when the computer program runs on a computer, causes the computer to execute the background application control method described above.
第三方面,本申请实施例提供一种电子设备,包括处理器和存储器,所述存储器有计算机程序,所述处理器调用所述计算机程序,其中,所述处理器还执行:In a third aspect, an embodiment of the present application provides an electronic device, including a processor and a memory, where the memory has a computer program, and the processor invokes the computer program, wherein the processor further performs:
获取预设后台应用程序的第一样本集,获取所述电子设备的第二样本集,其中所述第一样本集和第二样本集中的样本分别包括所述预设后台应用程序和所述电子设备的多个特征信息;Obtaining a first sample set of the preset background application, acquiring a second sample set of the electronic device, where the samples in the first sample set and the second sample set respectively include the preset background application and the Denoting a plurality of characteristic information of the electronic device;
将所述第一样本集和所述第二样本集分别构建成二维的第一样本图和第二样本图;Constructing the first sample set and the second sample set into a two-dimensional first sample map and a second sample map, respectively;
获取参考模型,并将所述第一样本图和所述第二样本图作为训练数据输入所述参考模型,进行学习,得到训练后的所述参考模型的优化参数;Obtaining a reference model, and inputting the first sample map and the second sample map as training data into the reference model, performing learning, and obtaining optimized parameters of the reference model after training;
获取所述预设后台应用程序和所述电子设备当前的多个特征信息,并形成第一特征图和第二特征图,根据所述参考模型、所述优化参数、所述第一特征图以及所述第二特征图,生成预测结果,并根据所述预测结果对所述预设后台应用程序进行管控。Acquiring the preset background application and the current plurality of feature information of the electronic device, and forming a first feature map and a second feature map, according to the reference model, the optimization parameter, the first feature map, and The second feature map generates a prediction result, and controls the preset background application according to the prediction result.
附图说明DRAWINGS
为了更清楚地说明本申请实施例中的技术方案,下面将对实施例描述中所需要使用的附图作简单地介绍。显而易见地,下面描述中的附图仅仅是本申请的一些实施例,对于本领域技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的附图。In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings used in the description of the embodiments will be briefly described below. Obviously, the drawings in the following description are only some embodiments of the present application, and those skilled in the art can obtain other drawings according to the drawings without any creative work.
图1为本申请实施例提供的后台应用程序管控装置的系统示意图;1 is a schematic system diagram of a background application control device according to an embodiment of the present application;
图2为本申请实施例提供的后台应用程序管控装置的应用场景示意图;FIG. 2 is a schematic diagram of an application scenario of a background application control device according to an embodiment of the present disclosure;
图3为本申请实施例提供的后台应用程序管控方法的流程示意图;FIG. 3 is a schematic flowchart of a background application control method according to an embodiment of the present application;
图4为本申请实施例提供的样本图的示意图;4 is a schematic diagram of a sample diagram provided by an embodiment of the present application;
图5为本申请实施例提供的后台应用程序管控方法的另一流程示意图;FIG. 5 is another schematic flowchart of a background application control method according to an embodiment of the present application;
图6为本申请实施例提供的后台应用程序管控装置的另一应用场景示意图;FIG. 6 is a schematic diagram of another application scenario of a background application control device according to an embodiment of the present disclosure;
图7为本申请实施例提供的后台应用程序管控装置的结构示意图;FIG. 7 is a schematic structural diagram of a background application control device according to an embodiment of the present application;
图8为本申请实施例提供的参考模型的部分结构示意图;FIG. 8 is a schematic structural diagram of a part of a reference model according to an embodiment of the present disclosure;
图9为本申请实施例提供的后台应用程序管控装置的另一结构示意图;FIG. 9 is another schematic structural diagram of a background application control device according to an embodiment of the present application;
图10为本申请实施例提供的电子设备的结构示意图;FIG. 10 is a schematic structural diagram of an electronic device according to an embodiment of the present disclosure;
图11为本申请实施例提供的电子设备的另一结构示意图。FIG. 11 is another schematic structural diagram of an electronic device according to an embodiment of the present application.
具体实施方式Detailed ways
请参照图式,其中相同的组件符号代表相同的组件,本申请的原理是以实施在一适当的运算环境中来举例说明。以下的说明是基于所例示的本申请具体实施例,其不应被视为限制本申请未在此详述的其它具体实施例。Referring to the drawings, wherein like reference numerals represent the same components, the principles of the present application are illustrated by the implementation in a suitable computing environment. The following description is based on the specific embodiments of the present invention as illustrated, and should not be construed as limiting the specific embodiments that are not described herein.
本申请实施例提供一种后台应用程序管控方法,应用于电子设备,所述方法包括:The embodiment of the present application provides a background application control method, which is applied to an electronic device, and the method includes:
获取预设后台应用程序的第一样本集,获取所述电子设备的第二样本集,其中所述第一样本集和第二样本集中的样本分别包括所述预设后台应用程序和所述电子设备的多个特征信息;Obtaining a first sample set of the preset background application, acquiring a second sample set of the electronic device, where the samples in the first sample set and the second sample set respectively include the preset background application and the Denoting a plurality of characteristic information of the electronic device;
将所述第一样本集和所述第二样本集分别构建成二维的第一样本图和第二样本图;Constructing the first sample set and the second sample set into a two-dimensional first sample map and a second sample map, respectively;
获取参考模型,并将所述第一样本图和所述第二样本图作为训练数据输入所述参考模型,进行学习,得到训练后的所述参考模型的优化参数;Obtaining a reference model, and inputting the first sample map and the second sample map as training data into the reference model, performing learning, and obtaining optimized parameters of the reference model after training;
获取所述预设后台应用程序和所述电子设备当前的多个特征信息,并形成第一特征图和第二特征图,根据所述参考模型、所述优化参数、所述第一特征图以及所述第二特征图,生成预测结果,并根据所述预测结果对所述预设后台应用程序进行管控。Acquiring the preset background application and the current plurality of feature information of the electronic device, and forming a first feature map and a second feature map, according to the reference model, the optimization parameter, the first feature map, and The second feature map generates a prediction result, and controls the preset background application according to the prediction result.
在所述的后台应用程序管控方法中,所述参考模型包括两个子参考模型,两个所述子参考模型为卷积神经网络模型。In the background application management method, the reference model includes two sub-reference models, and the two sub-reference models are convolutional neural network models.
在所述的后台应用程序管控方法中,所述参考模型还包括分类器;In the background application management method, the reference model further includes a classifier;
所述将所述第一样本图和第二样本图作为训练数据输入所述参考模型,进行学习,得到训练后的所述参考模型的优化参数具体包括:And inputting the first sample map and the second sample map as the training data into the reference model, and learning, and obtaining the optimized parameters of the reference model after training includes:
将所述第一样本图和第二样本图作为训练数据分别输入两个所述子参考模型;And inputting the first sample map and the second sample map as training data into two of the sub-reference models respectively;
将两个所述子参考模型的输出值合成输入所述分类器,并得到对应多个所述预测结果的概率;Combining output values of two of the sub-reference models into the classifier, and obtaining a probability corresponding to the plurality of prediction results;
根据多个所述预测结果和与其对应的多个所述概率得到损失值;Obtaining a loss value according to the plurality of prediction results and a plurality of the probabilities corresponding thereto;
根据所述损失值进行训练,得到所述优化参数。Training is performed according to the loss value to obtain the optimization parameter.
在所述的后台应用程序管控方法中,所述根据所述损失值进行训练具体包括:In the background application management method, the training according to the loss value specifically includes:
根据所述损失值利用随机梯度下降法进行训练。Training is performed using a stochastic gradient descent method based on the loss value.
在所述的后台应用程序管控方法中,所述将两个所述子参考模型的输出值合成输入所述分类器具体包括:In the background application management method, the synthesizing the output values of the two sub-reference models into the classifier specifically includes:
将两个所述子参考模型的输出值按不同权重合成输入所述分类器。The output values of the two sub-reference models are combined into the classifier by different weights.
在所述的后台应用程序管控方法中,所述将两个所述子参考模型的输出值合成输入所述分类器,并得到对应多个所述预测结果的概率具体包括:In the background application management method, the synthesizing the output values of the two sub-reference models into the classifier and obtaining the probability corresponding to the plurality of prediction results specifically includes:
基于第一预设公式将两个所述子参考模型的输出值合成输入所述分类器,并得到对应多个所述预测结果的概率,其中所述第一预设公式为:Generating an output value of two of the sub-reference models into the classifier based on a first preset formula, and obtaining a probability corresponding to the plurality of prediction results, wherein the first preset formula is:
Figure PCTCN2018102205-appb-000001
Figure PCTCN2018102205-appb-000001
其中,Z K为两个所述子参考模型的输出值的合成值,C为预测结果的类别数,Z j为第j个合成值。 Where Z K is a composite value of the output values of the two sub-reference models, C is the number of categories of the prediction result, and Z j is the j-th composite value.
在所述的后台应用程序管控方法中,所述根据多个所述预测结果和与其对应的多个所述概率得到损失值具体包括:In the background application management method, the obtaining the loss value according to the plurality of the prediction results and the plurality of the probabilities corresponding thereto specifically includes:
基于第二预设公式根据多个所述预测结果和与其对应的多个所述概率得到损失值,其中所述第二预设公式为:And obtaining, according to the second preset formula, a loss value according to the plurality of the prediction results and a plurality of the probabilities corresponding thereto, wherein the second preset formula is:
Figure PCTCN2018102205-appb-000002
Figure PCTCN2018102205-appb-000002
其中C为预测结果的类别数,y k为真实值。 Where C is the number of categories of predictions and y k is the true value.
在所述的后台应用程序管控方法中,所述根据所述损失值进行训练具体包括:In the background application management method, the training according to the loss value specifically includes:
获取多个所述损失值,根据多个所述损失值的平均值进行训练。A plurality of the loss values are obtained, and training is performed based on an average of the plurality of the loss values.
在所述的后台应用程序管控方法中,所述根据多个所述预测结果和与其对应的多个所述概率得到损失值具体包括:In the background application management method, the obtaining the loss value according to the plurality of the prediction results and the plurality of the probabilities corresponding thereto specifically includes:
基于第三预设公式根据多个所述预测结果和与其对应的多个所述概率得到损失值,其中所述第三预设公式为:And obtaining, according to a third preset formula, a loss value according to the plurality of the prediction results and a plurality of the probabilities corresponding thereto, wherein the third preset formula is:
Figure PCTCN2018102205-appb-000003
Figure PCTCN2018102205-appb-000003
其中C为预测结果的类别数,y k为真实值,E为平均值。 Where C is the number of categories of prediction results, y k is the true value, and E is the average.
在所述的后台应用程序管控方法中,所述获取预设后台应用程序和电子设备当前的多 个特征信息具体包括:In the background application management method, the acquiring the preset background application and the current plurality of feature information of the electronic device specifically includes:
获取预设时间;Get the preset time;
若当前系统时间到达预设时间时,则获取预设后台应用程序和电子设备当前的多个特征信息。If the current system time reaches the preset time, the preset background application and the plurality of feature information of the electronic device are obtained.
在所述的后台应用程序管控方法中,所述获取预设后台应用程序和电子设备当前的多个特征信息具体包括:In the background application management method, the acquiring the preset background application and the current plurality of feature information of the electronic device specifically includes:
检测到预设后台应用程序是否进入后台;Detecting whether the default background application enters the background;
若进入后台,则获取预设后台应用程序和电子设备当前的多个特征信息。If the background is entered, the preset background application and the plurality of feature information of the electronic device are obtained.
在相关技术中,对后台的应用程序进行管控时,通常直接根据电子设备的内存占用情况以及各应用程序的优先级,对后台的部分应用程序进行清理,以释放内存。然而有些应用程序对用户很重要、或者用户在短时间内需要再次使用某些应用程序,若在对后进行清理时将这些应用程序清理掉,则用户再次使用这些应用程序时需要电子设备重新加载这些应用程序的进程,需要耗费大量时间及内存资源。其中,该电子设备可以是智能手机、平板电脑、台式电脑、笔记本电脑、或者掌上电脑等设备。In the related art, when the application in the background is controlled, the application in the background is usually cleaned according to the memory usage of the electronic device and the priority of each application to release the memory. However, some applications are important to the user, or the user needs to use some applications again in a short period of time. If these applications are cleaned up after cleaning, users need to reload the electronic devices when they use them again. These application processes take a lot of time and memory resources. The electronic device may be a smart phone, a tablet computer, a desktop computer, a notebook computer, or a handheld computer.
请参阅图1,图1为本申请实施例提供的后台应用程序管控装置的系统示意图。该后台应用程序管控装置主要用于:获取预设后台应用程序的第一样本集,获取电子设备的第二样本集,其中第一样本集和第二样本集中的样本分别包括预设后台应用程序和电子设备的多个特征信息;将第一样本集和第二样本集分别构建成二维的第一样本图和第二样本图;获取参考模型,并将第一样本图和第二样本图作为训练数据输入参考模型,进行学习,得到训练后的参考模型的优化参数;获取预设后台应用程序和电子设备当前的多个特征信息,并形成第一特征图和第二特征图,根据参考模型、优化参数、第一特征图以及当第二特征图进行预测,生成预测结果,然后根据该预测结果判断该预设后台应用程序是否需要被使用,以对预设后台应用程序进行管控,例如关闭、或者冻结等。Please refer to FIG. 1. FIG. 1 is a schematic diagram of a system of a background application control device according to an embodiment of the present application. The background application management device is mainly configured to: obtain a first sample set of the preset background application, and acquire a second sample set of the electronic device, where the samples in the first sample set and the second sample set respectively include a preset background a plurality of feature information of the application and the electronic device; respectively constructing the first sample set and the second sample set into a two-dimensional first sample map and a second sample map; acquiring the reference model, and the first sample map And the second sample map is used as the training data input reference model to learn, obtain the optimized parameters of the trained reference model; obtain the preset background application and the current plurality of feature information of the electronic device, and form the first feature map and the second The feature map generates a prediction result according to the reference model, the optimization parameter, the first feature map, and the second feature map, and then determines, according to the prediction result, whether the preset background application needs to be used, to the preset background application. The program is controlled, such as shutting down, or freezing.
具体的,请参阅图2,图2为本申请实施例提供的后台应用程序管控装置的应用场景示意图。比如,后台应用程序管控装置在接收到管控请求时,检测到在电子设备的后台运行的应用程序包括预设后台应用程序a、预设后台应用程序b以及预设后台应用程序c;然后分别获取预设后台应用程序a对应的参考模型A、预设后台应用程序b对应的参考模型B以及预设后台应用程序c对应的参考模型C;通过参考模型A对预设后台应用程序a是否需要被使用的概率进行预测,得到概率a’,通过参考模型B对预设后台应用程序b是否需要被使用的概率进行预测,得到概率b’,参考模型C对预设后台应用程序c是否需要被使用的概率进行预测,得到概率c’;根据概率a’、概率b’以及概率c’对后台运行的预设后台应用程序a、预设后台应用程序b以及预设后台应用程序c进行管控,例如将概率最低的预设后台应用程序b关闭。Specifically, please refer to FIG. 2 , which is a schematic diagram of an application scenario of a background application control device according to an embodiment of the present application. For example, when receiving the control request, the background application management device detects that the application running in the background of the electronic device includes a preset background application a, a preset background application b, and a preset background application c; Presetting the reference model A corresponding to the background application a, the reference model B corresponding to the preset background application b, and the reference model C corresponding to the preset background application c; whether the preset background application a needs to be The probability of use is predicted to obtain the probability a', and the probability of whether the preset background application b needs to be used is predicted by the reference model B, and the probability b' is obtained, and the reference model C needs to be used for the preset background application c. The probability is predicted to obtain the probability c′; according to the probability a′, the probability b′ and the probability c′, the preset background application a running in the background, the preset background application b and the preset background application c are controlled, for example The default background application b with the lowest probability is turned off.
本申请实施例提供一种后台应用程序管控方法,该后台应用程序管控方法的执行主体可以是本申请实施例提供的后台应用程序管控装置,或者集成了该后台应用程序管控装置的电子设备,其中该后台应用程序管控装置可以采用硬件或者软件的方式实现。The embodiment of the present application provides a background application control method, and the execution entity of the background application control method may be a background application control device provided by the embodiment of the present application, or an electronic device integrated with the background application control device, wherein The background application management device can be implemented in hardware or software.
本申请实施例将从后台应用程序管控装置的角度进行描述,该后台应用程序管控装置具体可以集成在电子设备中。该后台应用程序管控方法包括:获取预设后台应用程序的第 一样本集,获取电子设备的第二样本集,其中第一样本集和第二样本集中的样本分别包括预设后台应用程序和电子设备的多个特征信息;将第一样本集和第二样本集分别构建成二维的第一样本图和第二样本图;获取参考模型,并将第一样本图和第二样本图作为训练数据输入参考模型,进行学习,得到训练后的参考模型的优化参数;获取预设后台应用程序和电子设备当前的多个特征信息,并形成第一特征图和第二特征图,根据参考模型、优化参数、第一特征图以及第二特征图,生成预测结果,并根据预测结果对预设后台应用程序进行管控。The embodiment of the present application will be described from the perspective of a background application control device, and the background application control device may be specifically integrated in an electronic device. The background application management method includes: acquiring a first sample set of the preset background application, and acquiring a second sample set of the electronic device, wherein the samples in the first sample set and the second sample set respectively include a preset background application And a plurality of feature information of the electronic device; respectively constructing the first sample set and the second sample set into a two-dimensional first sample map and a second sample map; acquiring the reference model, and the first sample map and the first sample The two sample map is used as the training data input reference model to learn, obtain the optimized parameters of the trained reference model, obtain the preset background application and the current plurality of feature information of the electronic device, and form the first feature map and the second feature map. And generating a prediction result according to the reference model, the optimization parameter, the first feature map, and the second feature map, and controlling the preset background application according to the prediction result.
请参阅图3,图3为本申请实施例提供的后台应用程序管控方法的流程示意图。本申请实施例提供的后台应用程序管控方法应用于电子设备,具体流程可以如下:Referring to FIG. 3, FIG. 3 is a schematic flowchart of a background application control method according to an embodiment of the present application. The background application management and control method provided by the embodiment of the present application is applied to an electronic device, and the specific process may be as follows:
101,获取预设后台应用程序的第一样本集,获取电子设备的第二样本集,其中第一样本集和第二样本集中的样本分别包括预设后台应用程序和电子设备的多个特征信息。101. Acquire a first sample set of the preset background application, and acquire a second sample set of the electronic device, where the samples in the first sample set and the second sample set respectively include multiple preset background applications and multiple electronic devices. Feature information.
具体的,第一样本集的样本可以包括预设应用程序的使用信息,第二样本集的样本可以包括电子设备的状态信息、时间信息和位置信息等中的至少一项。Specifically, the sample of the first sample set may include usage information of the preset application, and the sample of the second sample set may include at least one of status information, time information, and location information of the electronic device.
其中应用程序的使用信息可以包括如使用时间、后台停留时间、应用程序类型、应用程序关联信息等。电子设备的状态信息可以包括如屏幕亮度、充电状态、剩余电量、WIFI状态等。时间信息可以包括如当前时间点、工作日等。位置信息可以包括如GPS定位、基站定位、WIFI定位等。The usage information of the application may include, for example, usage time, background time, application type, application association information, and the like. The status information of the electronic device may include, for example, screen brightness, state of charge, remaining power, WIFI status, and the like. The time information may include, for example, a current time point, a work day, and the like. The location information may include, for example, GPS positioning, base station positioning, WIFI positioning, and the like.
将多个特性信息作为样本采集,然后形成预设应用程序的第一样本集和电子设备的第二样本集。A plurality of characteristic information is collected as a sample, and then a first sample set of the preset application and a second sample set of the electronic device are formed.
其中,预设应用程序可以是安装在电子设备中的任意应用程序,例如通讯应用程序、多媒体应用程序、游戏应用程序、资讯应用程序、或者购物应用程序等等。The preset application may be any application installed in the electronic device, such as a communication application, a multimedia application, a game application, a news application, or a shopping application.
样本集可以包括:在历史时间段内,按照预设频率采集的多个样本。历史时间段可以是,例如过去15天内、7天一周内等。预设频率可以是,例如每10分钟、30分钟等。The sample set may include: a plurality of samples collected according to a preset frequency during a historical time period. The historical time period can be, for example, within the past 15 days, within 7 days, and the like. The preset frequency can be, for example, every 10 minutes, 30 minutes, and the like.
本申请中的术语“第一”、“第二”等是用于区别不同对象,而不是用于描述特定顺序。The terms "first", "second", and the like in this application are used to distinguish different objects, and are not intended to describe a particular order.
102,将第一样本集和第二样本集分别构建成二维的第一样本图和第二样本图。102. The first sample set and the second sample set are respectively constructed into a two-dimensional first sample map and a second sample map.
将第一样本集和第二样本集中的样本用数值表示,如充电状态可以通过0或1表示未充电和正在充电。如剩余电量可以用00-100表示剩余电量,或者将电量分成5个等级,用0-5分别表示不同等级的剩余电量。第一样本图和第二样本图可以采用如12×12像素点的图,每个像素点对应一个样本,即一个特征信息。当然,样本图根据需要可以调整其包括的像素点,如可以为10×10、16×16、12×16等。数据量越大,后续的预测结果越准确。需要说明的是,像素点具体表现可以为1,也可以为(0,1)。将获取的多个特征信息以二维数学图像的方式存储,类似于灰度图,即在像素点(x,y)记录不同的特征值。The samples in the first sample set and the second sample set are represented by numerical values, such as the state of charge, which can be represented by 0 or 1 as being uncharged and being charged. For example, if the remaining power can be used to indicate the remaining power with 00-100, or divide the power into 5 levels, use 0-5 to indicate the remaining power of different levels. The first sample map and the second sample map may take a map such as 12×12 pixel points, and each pixel point corresponds to one sample, that is, one feature information. Of course, the sample map can adjust the pixels it includes as needed, such as 10×10, 16×16, 12×16, and the like. The larger the amount of data, the more accurate the subsequent predictions. It should be noted that the pixel point specific performance may be 1 or (0, 1). The acquired plurality of feature information is stored in a two-dimensional mathematical image, similar to a grayscale image, that is, different feature values are recorded at pixel points (x, y).
请参阅图4,图4为本申请实施例提供的第二样本图的示意图。根据电子设备的特征信息的种类可以分成几类特征信息,如电子设备的特征信息分成电子设备的状态信息、时间信息、网络信息和位置信息四类,然后将该四类特征信息分别形成一个子样本图3061,接着将四个子样本图3061矩阵设置形成一个大的第二样本图306。其中子样本图3061可以采用如6×6个像素点,如果特征信息不足以填满子样本图,则不足位置补零处理。四个子样本图3061形成一个12×12的大的第二样本图306。第二样本图306和子样本图3061 都为二维的图。Please refer to FIG. 4. FIG. 4 is a schematic diagram of a second sample diagram provided by an embodiment of the present application. According to the type of the feature information of the electronic device, the information may be divided into several types of feature information, for example, the feature information of the electronic device is divided into four types: state information, time information, network information, and location information of the electronic device, and then the four types of feature information are respectively formed into one sub-category. Sample map 3061, then four subsample map 3061 matrices are arranged to form a large second sample map 306. The subsample image 3061 can adopt, for example, 6×6 pixels. If the feature information is insufficient to fill the subsample graph, the position is zero-padded. The four subsample views 3061 form a 12 x 12 large second sample map 306. Both the second sample map 306 and the subsample map 3061 are two-dimensional maps.
需要说明的是,后台应用程序的第一样本图也可以采用类似第二样本图的方法设置。It should be noted that the first sample image of the background application may also be set by a method similar to the second sample image.
103,获取参考模型,并将第一样本图和第二样本图作为训练数据输入参考模型,进行学习,得到训练后的参考模型的优化参数。103. Acquire a reference model, and input the first sample map and the second sample map as training data into the reference model, and learn to obtain optimized parameters of the trained reference model.
其中,参考模型包括两个子参考模型,两个子参考模型为卷积神经网络模型。当然子参考模型可以为混合神经网络模型、高斯混合模型等。两个子参考模型为弱学习器,两个弱学习器结合形成一个强学习器。电子设备的应用对应用户的使用习惯和偏好是存在一定规律的,学习到这些规律对清理后台不使用的应用具有重要意义。集成学习通过构建并结合多个弱学习器来完成学习任务。将集成学习应用到用户行为特征分类上,通过结合两个独立的卷积神经网络,构建一个强学习器,可以挖掘到用户的使用习惯。随着用户使用设备时间变长,训练会愈发充分,系统预测也会愈发准确。The reference model includes two sub-reference models, and the two sub-reference models are convolutional neural network models. Of course, the sub-reference model can be a hybrid neural network model, a Gaussian mixture model, or the like. The two sub-reference models are weak learners, and the two weak learners combine to form a strong learner. There are certain rules in the application of electronic devices corresponding to the user's usage habits and preferences. Learning these rules is of great significance for cleaning up applications that are not used in the background. Integrated learning accomplishes learning tasks by building and combining multiple weak learners. Applying integrated learning to the classification of user behavior characteristics, by combining two independent convolutional neural networks, a strong learner can be built to dig into the user's usage habits. As users use the device for a longer period of time, the training will become more and more complete, and the system prediction will become more accurate.
子参考模型包括依次连接的卷积层和全连接层,参考模型还包括分类器。具体的,该参考模型主要包括网络结构部分和网络训练部分,其中网络结构部分包括依次连接的卷积层和全连接层。卷积层和全连接层之间还可以包括池化层。The sub-reference model includes a convolutional layer and a fully connected layer that are sequentially connected, and the reference model also includes a classifier. Specifically, the reference model mainly includes a network structure part and a network training part, wherein the network structure part includes a convolution layer and a full connection layer connected in sequence. A pooling layer may also be included between the convolutional layer and the fully connected layer.
可选的,卷积神经网络模型参考模型的网络结构部分可以包括七层网络,前五层为卷积层,卷积核大小统一为3×3,滑动步长统一为1,由于维度较小,可以不采用池化层,后两层为全连接层,分别为20个神经元、2个神经元。Optionally, the network structure part of the convolutional neural network model reference model may include a seven-layer network, the first five layers are convolution layers, the convolution kernel size is unified to 3×3, and the sliding step length is unified to 1, due to a small dimension. The pooling layer may not be used, and the latter two layers are fully connected layers, which are 20 neurons and 2 neurons, respectively.
需要说明的是,网络结构部分还可以包括其他层数的卷积层,如3层卷积层、5层卷积层、9层卷积层等,还可以包括其他层数的全连接层,如1层全连接层、3层全连接层等。也可以增加池化层,也可以不采用池化层。卷积核大小可以采用其他大小,如2×2。还可以不同的卷积层采用不同大小的卷积核,如第一层卷积层采用3×3的卷积核,其他层卷积层采用2×2的卷积核。滑动步长可以统一为2或其他值,也可以采用不一样的滑动步长,如第一层滑动步长为2,其他层滑动步长为1等。It should be noted that the network structure part may further include other layers of convolution layers, such as a 3-layer convolution layer, a 5-layer convolution layer, a 9-layer convolution layer, etc., and may also include a full-connection layer of other layers. Such as a 1-layer fully connected layer, a 3-layer fully connected layer, and the like. It is also possible to increase the pooling layer or not to use the pooling layer. The convolution kernel size can be other sizes, such as 2 x 2. Convolution kernels of different sizes can also be used for different convolutional layers. For example, the first layer convolution layer uses a 3×3 convolution kernel, and the other layer convolution layer uses a 2×2 convolution kernel. The sliding step size can be unified to 2 or other values, or a different sliding step size can be used, such as a sliding step of 2 for the first layer and a sliding step of 1 for the other layers.
网络训练部分包括分类器,分类器可以为Softmax分类器。The network training part includes a classifier, and the classifier can be a Softmax classifier.
请一并参阅图5,图5为本申请实施例提供的后台应用程序管控方法的另一流程示意图。训练方法具体包括:Referring to FIG. 5, FIG. 5 is another schematic flowchart of a background application control method according to an embodiment of the present application. The training methods specifically include:
1031,将第一样本图和第二样本图作为训练数据分别输入两个子参考模型。1031. The first sample map and the second sample map are respectively input as training data into two sub-reference models.
1032,将两个子参考模型的输出值合成输入分类器,并得到对应多个预测结果的概率。1032. Synthesize the output values of the two sub-reference models into the input classifier, and obtain a probability corresponding to the plurality of prediction results.
需要说明的是,将两个子参考模型的输出值合成输入分类器,可以为将两个子参考模型的输出值按不同权重合成输入分类器。即将两个子参考模型的输出值加权和,可以将两个较浅层的卷积神经网络作为弱分类器,再合并成强分类器。具体公式如下:It should be noted that the output values of the two sub-reference models are combined into the input classifier, and the output values of the two sub-reference models can be combined into the input classifier according to different weights. By weighting the output values of the two sub-reference models, two shallower convolutional neural networks can be used as weak classifiers and then merged into strong classifiers. The specific formula is as follows:
Z K=Z K APP+λ*Z K DeviceZ K =Z K APP +λ*Z K Device ,
其中,λ为权重,Z K APP为第一子参考模型的输出值,Z K Device为第二子参考模型的输出值。 Where λ is the weight, Z K APP is the output value of the first sub-reference model, and Z K Device is the output value of the second sub-reference model.
在一些实施方式中,得到预测结果的概率可以基于第一预设公式将两个子参考模型的输出值合成输入分类器,并得到对应多个预测结果的概率,其中第一预设公式为:In some embodiments, the probability of obtaining the prediction result may be based on the first preset formula to synthesize the output values of the two sub-reference models into the input classifier, and obtain a probability corresponding to the plurality of prediction results, wherein the first preset formula is:
Figure PCTCN2018102205-appb-000004
Figure PCTCN2018102205-appb-000004
其中,Z K为两个子参考模型的输出值的合成值,C为预测结果的类别数,
Figure PCTCN2018102205-appb-000005
为第j个合成值。
Where Z K is the composite value of the output values of the two sub-reference models, and C is the number of categories of the prediction results,
Figure PCTCN2018102205-appb-000005
Is the jth composite value.
1033,根据多个预测结果和与其对应的多个概率得到损失值。1033. Obtain a loss value according to multiple prediction results and multiple probabilities corresponding thereto.
在一些实施方式中,得到损失值可以基于第二预设公式根据多个预测结果和与其对应的多个概率得到损失值,其中第二预设公式为:In some embodiments, obtaining the loss value may obtain a loss value according to the plurality of prediction results and the plurality of probabilities corresponding thereto according to the second preset formula, where the second preset formula is:
Figure PCTCN2018102205-appb-000006
Figure PCTCN2018102205-appb-000006
其中C为预测结果的类别数,y k为真实值。 Where C is the number of categories of predictions and y k is the true value.
1034,根据损失值进行训练,得到优化参数。1034, training according to the loss value, and obtaining optimized parameters.
可以根据损失值利用随机梯度下降法进行训练。还可以根据批量梯度下降法或梯度下降法进行训练。Training can be performed using a stochastic gradient descent method based on the loss value. Training can also be performed according to the batch gradient descent method or the gradient descent method.
利用随机梯度下降法进行训练,可以当损失值等于或小于预设损失值时,则完成训练。也可以当连续获取的两个或多个损失值没有变化时,则完成训练。当然还可以不根据损失值,直接设定随机梯度下降法的迭代次数,迭代次数完成后,则完成训练。训练完成后,获取此时的参考模型的各个参数,并将该各个参数保存为优化参数,后续需要预测时,使用该优化参数进行预测。Training is performed using the stochastic gradient descent method, and the training can be completed when the loss value is equal to or less than the preset loss value. It is also possible to complete the training when there are no changes in the two or more loss values continuously acquired. Of course, it is also possible to directly set the number of iterations of the random gradient descent method according to the loss value. After the number of iterations is completed, the training is completed. After the training is completed, each parameter of the reference model at this time is obtained, and the each parameter is saved as an optimization parameter, and when the prediction is needed later, the optimization parameter is used for prediction.
进一步的,得到损失值可以基于第三预设公式根据多组参数得到损失值,每组参数包括多个预测结果和与其对应的多个概率得到损失值,其中第三预设公式为:Further, the obtained loss value may be obtained according to the third preset formula according to the plurality of sets of parameters, and each set of parameters includes a plurality of prediction results and a plurality of probability corresponding to the obtained loss values, wherein the third preset formula is:
Figure PCTCN2018102205-appb-000007
Figure PCTCN2018102205-appb-000007
其中C为预测结果的类别数,y k为真实值,E为平均值。 Where C is the number of categories of prediction results, y k is the true value, and E is the average.
其中可以采用小批量的方式训练得到最优参数。如批量大小为128,第三预设公式中的E表示为128个损失值的平均值。Among them, the optimal parameters can be trained in a small batch manner. If the batch size is 128, E in the third preset formula is expressed as the average of 128 loss values.
具体的,可以先获取多个样本集,多个样本集构建成多个二维的样本图,然后将多个样本图作为训练数据输入参考模型,得到多个损失值,然后求多个损失值的平均值。Specifically, multiple sample sets may be acquired first, and multiple sample sets are constructed into multiple two-dimensional sample images, and then multiple sample images are input as training data into the reference model to obtain multiple loss values, and then multiple loss values are obtained. average of.
104,获取预设后台应用程序和电子设备当前的多个特征信息,并形成第一特征图和第二特征图,根据参考模型、优化参数、第一特征图以及第二特征图,生成预测结果,并根据预测结果对预设后台应用程序进行管控。104. Acquire a preset background application and a plurality of feature information of the electronic device, and form a first feature map and a second feature map, and generate a prediction result according to the reference model, the optimization parameter, the first feature map, and the second feature map. And control the default background application based on the predicted results.
若需要判断当前后台应用是否可清理,获取预设后台应用程序和电子设备当前的多个特征信息,并形成二维的第一特征图和第二特征图,将第一特征图和第二特征图输入到参考模型,参考模型根据优化参数计算即可得到预测值。判断预设后台应用程序是否需要清理。If it is necessary to determine whether the current background application is cleanable, obtain a preset background application and a plurality of current feature information of the electronic device, and form a two-dimensional first feature map and a second feature map, and the first feature map and the second feature are obtained. The graph is input to the reference model, and the reference model is calculated based on the optimized parameters to obtain the predicted value. Determine if the default background application needs to be cleaned up.
需要说明的是,参考模型的训练过程可以在服务器端也可以在电子设备端完成。当参 考模型的训练过程、实际预测过程都在服务器端完成时,需要使用优化后的参考模型时,可以将预设后台应用程序和电子设备当前的多个特征信息形成特征图,并输入到服务器,服务器实际预测完成后,将预测结果发送至电子设备端,电子设备再根据预测结果管控该预设后台应用程序。It should be noted that the training process of the reference model can be completed on the server side or on the electronic device side. When the training process and the actual prediction process of the reference model are completed on the server side, when the optimized reference model needs to be used, the preset background application and the current multiple feature information of the electronic device may be formed into a feature map and input to the server. After the actual prediction of the server is completed, the prediction result is sent to the electronic device end, and the electronic device controls the preset background application according to the prediction result.
当参考模型的训练过程、实际预测过程都在电子设备端完成时,需要使用优化后的参考模型时,可以将预设后台应用程序和电子设备当前的多个特征信息形成第一特征图和第二特征图,并输入到电子设备,电子设备实际预测完成后,电子设备根据预测结果管控该预设后台应用程序。When the training process and the actual prediction process of the reference model are completed on the electronic device end, when the optimized reference model needs to be used, the preset background application and the current plurality of feature information of the electronic device may be formed into the first feature map and the first feature map. The second feature map is input to the electronic device, and after the actual prediction of the electronic device is completed, the electronic device controls the preset background application according to the predicted result.
请参阅图6,图6为本申请实施例提供的后台应用程序管控装置的另一应用场景示意图。当参考模型的训练过程在服务器端完成,参考模型的实际预测过程在电子设备端完成时,需要使用优化后的参考模型时,可以将预设后台应用程序和电子设备当前的多个特征信息形成第一特征图和第二特征图,并输入到电子设备,电子设备实际预测完成后,电子设备根据预测结果管控该预设后台应用程序。可选的,可以将训练好的参考模型文件(model文件)移植到智能设备上,若需要判断当前后台应用是否可清理,更新当前的样本图,输入到训练好的参考模型文件(model文件),计算即可得到预测值。Please refer to FIG. 6. FIG. 6 is a schematic diagram of another application scenario of a background application control device according to an embodiment of the present disclosure. When the training process of the reference model is completed on the server side, when the actual prediction process of the reference model is completed on the electronic device side, when the optimized reference model needs to be used, the preset background application and the plurality of feature information of the electronic device can be formed. The first feature map and the second feature map are input to the electronic device, and after the actual prediction of the electronic device is completed, the electronic device controls the preset background application according to the predicted result. Optionally, the trained reference model file (model file) can be transplanted to the smart device. If it is necessary to determine whether the current background application can be cleaned up, the current sample image is updated, and the trained reference model file (model file) is input. , the calculation can get the predicted value.
在一些实施方式中,在获取预设后台应用程序和电子设备当前的多个特征信息之前,包括:In some embodiments, before acquiring the preset background application and the current plurality of feature information of the electronic device, the method includes:
检测到预设后台应用程序是否进入后台,若进入后台,则获取预设后台应用程序和电子设备当前的多个特征信息,并形成第一特征图和第二特征图。然后根据参考模型、优化参数、第一特征图以及第二特征图进行预测,生成预测结果,并根据预测结果对预设后台应用程序进行管控。A preset background application is detected to enter the background. If the background is entered, the preset background application and the current plurality of feature information of the electronic device are acquired, and the first feature map and the second feature map are formed. Then, the prediction is performed according to the reference model, the optimization parameter, the first feature map, and the second feature map, and the prediction result is generated, and the preset background application is controlled according to the prediction result.
在一些实施方式中,在获取预设后台应用程序和电子设备当前的多个特征信息之前,包括:In some embodiments, before acquiring the preset background application and the current plurality of feature information of the electronic device, the method includes:
获取预设时间,若当前系统时间到达预设时间时,则获取预设后台应用程序和电子设备当前的多个特征信息,并形成第一特征图和第二特征图。其中预设时间可以为一天中的一个时间点,如上午9点,也可以为一天中的几个时间点,如上午9点、下午6点等。也可以为多天中的一个或几个时间点。然后根据参考模型、优化参数、第一特征图以及第二特征图生成预测结果,并根据预测结果对预设后台应用程序进行管控。The preset time is obtained. If the current system time reaches the preset time, the preset background application and the current plurality of feature information of the electronic device are acquired, and the first feature map and the second feature map are formed. The preset time can be a time point in the day, such as 9 am, or several time points in the day, such as 9 am, 6 pm, and the like. It can also be one or several time points in multiple days. Then, the prediction result is generated according to the reference model, the optimization parameter, the first feature map, and the second feature map, and the preset background application is controlled according to the prediction result.
需要说明的是,参考模型还可以包括多个子参考模型,如3个、5个等。每个子参考模型可以输入不同的样本图,也可以其中2个或多个输入相同的样本图。It should be noted that the reference model may also include multiple sub-reference models, such as three, five, and the like. Each sub-reference model can input different sample maps, or two or more of them can input the same sample map.
上述所有的技术方案,可以采用任意结合形成本申请的可选实施例,在此不再一一赘述。All of the above technical solutions may be combined to form an optional embodiment of the present application, and will not be further described herein.
电子设备上会同时打开多个应用,处于后台的很多应用一段时间内并不会使用,这些应用若不被清理,占用大量内存且功耗较大。因此准确判断出可以清理的应用对提升用户体验意义重大。传统的基于用户行为习惯判断应用是否可清理的方法存在着预测精度不够的问题。Many applications are open at the same time on the electronic device. Many applications in the background will not be used for a period of time. If these applications are not cleaned up, they consume a lot of memory and consume a lot of power. Therefore, accurately determining the applications that can be cleaned is of great significance for improving the user experience. The traditional method of judging whether an application can be cleaned based on user behavior habits has the problem of insufficient prediction accuracy.
由上述可知,本申请实施例提供的后台应用程序管控方法,通过获取预设后台应用程序的第一样本集,获取电子设备的第二样本集;将第一样本集和第二样本集分别构建成二 维的第一样本图和第二样本图;将第一样本图和第二样本图作为训练数据输入参考模型,进行学习,得到训练后的参考模型的优化参数;获取预设后台应用程序和电子设备当前的多个特征信息,并形成第一特征图和第二特征图,根据参考模型、优化参数、第一特征图以及第二特征图,生成预测结果,并根据预测结果对预设后台应用程序进行管控。可以提高对预设后台应用程序进行预测的准确性,从而提升对进入后台的应用程序进行管控的智能化和准确性。不需要对用户行为做大量特征工程,即不需要选取合适的用户行为,并进行合适的预处理,特征工程的好坏对最终结果影响很大。直接将特性信息输入参考模型即可。It can be seen from the above that the background application control method provided by the embodiment of the present application acquires the second sample set of the electronic device by acquiring the first sample set of the preset background application; and the first sample set and the second sample set are obtained. Constructing a two-dimensional first sample map and a second sample map respectively; and inputting the first sample map and the second sample map as training data into the reference model, and learning, obtaining the optimized parameters of the trained reference model; Setting a plurality of feature information of the background application and the electronic device, and forming a first feature map and a second feature map, and generating a prediction result according to the reference model, the optimization parameter, the first feature map, and the second feature map, and according to the prediction As a result, the default background application is managed. It can improve the accuracy of forecasting the default background application, thus improving the intelligence and accuracy of controlling the application entering the background. There is no need to do a lot of feature engineering for user behavior, that is, there is no need to select appropriate user behaviors and appropriate pre-processing, and the quality of the feature engineering has a great impact on the final result. Simply enter the property information into the reference model.
请参阅图7,图7为本申请实施例提供的后台应用程序管控装置的结构示意图。其中该后台应用程序管控装置300应用于电子设备,该后台应用程序管控装置300包括获取单元301、样本图生成单元302、训练单元303以及管控单元304。Please refer to FIG. 7. FIG. 7 is a schematic structural diagram of a background application control device according to an embodiment of the present disclosure. The background application management device 300 is applied to an electronic device, and the background application management device 300 includes an obtaining unit 301, a sample map generating unit 302, a training unit 303, and a control unit 304.
其中,获取单元301,用于获取预设后台应用程序的第一样本集,获取电子设备的第二样本集,其中第一样本集和第二样本集中的样本分别包括预设后台应用程序和电子设备的多个特征信息。The obtaining unit 301 is configured to acquire a first sample set of the preset background application, and acquire a second sample set of the electronic device, where the samples in the first sample set and the second sample set respectively include a preset background application. And multiple feature information of the electronic device.
具体的,第一样本集的样本可以包括预设后台应用程序的使用信息,第二样本集的样本可以包括电子设备的状态信息、时间信息和位置信息等中的至少一项。Specifically, the sample of the first sample set may include usage information of the preset background application, and the sample of the second sample set may include at least one of status information, time information, and location information of the electronic device.
其中应用程序的使用信息可以包括如使用时间、后台停留时间、应用程序类型、应用程序关联信息等。电子设备的状态信息可以包括如屏幕亮度、充电状态、剩余电量、WIFI状态等。时间信息可以包括如当前时间段、工作日等。位置信息可以包括如GPS定位、基站定位、WIFI定位等。The usage information of the application may include, for example, usage time, background time, application type, application association information, and the like. The status information of the electronic device may include, for example, screen brightness, state of charge, remaining power, WIFI status, and the like. The time information may include, for example, a current time period, a work day, and the like. The location information may include, for example, GPS positioning, base station positioning, WIFI positioning, and the like.
将多个特征信息作为样本采集,然后形成预设后台应用程序的第一样本集和电子设备的第二样本集。A plurality of feature information is collected as a sample, and then a first sample set of the preset background application and a second sample set of the electronic device are formed.
其中,预设后台应用程序可以是安装在电子设备中的任意应用程序,例如通讯应用程序、多媒体应用程序、游戏应用程序、资讯应用程序、或者购物应用程序等等。The default background application may be any application installed in the electronic device, such as a communication application, a multimedia application, a game application, a news application, or a shopping application.
样本集可以包括在历史时间段内,按照预设频率采集的多个样本。历史时间段可以是,例如过去15天内、7天一周内等。预设频率可以是,例如每10分钟、30分钟等。The sample set may include a plurality of samples acquired at a preset frequency during a historical time period. The historical time period can be, for example, within the past 15 days, within 7 days, and the like. The preset frequency can be, for example, every 10 minutes, 30 minutes, and the like.
样本图生成单元302,用于将第一样本集和第二样本集分别构建成二维的第一样本图和第二样本图。The sample map generating unit 302 is configured to respectively construct the first sample set and the second sample set into a two-dimensional first sample map and a second sample map.
将第一样本集和第二样本集中的样本用数值表示,如充电状态可以通过0或1表示未充电和正在充电。如剩余电量可以用00-100表示剩余电量,或者将电量分成5个等级,用0-5分别表示不同等级的剩余电量。第一样本图和第二样本图可以采用如12×12像素点的图,每个像素点对应一个样本,即一个特征信息。当然,样本图根据需要可以调整其包括的像素点,如可以为10×10、16×16、12×16等。数据量越大,后续的预测结果越准确。需要说明的是,像素点具体表现可以为1,也可以为(0,1)。将获取的多个特征信息以二维数学图像的方式存储,类似于灰度图,即在像素点(x,y)记录不同的特征值。The samples in the first sample set and the second sample set are represented by numerical values, such as the state of charge, which can be represented by 0 or 1 as being uncharged and being charged. For example, if the remaining power can be used to indicate the remaining power with 00-100, or divide the power into 5 levels, use 0-5 to indicate the remaining power of different levels. The first sample map and the second sample map may take a map such as 12×12 pixel points, and each pixel point corresponds to one sample, that is, one feature information. Of course, the sample map can adjust the pixels it includes as needed, such as 10×10, 16×16, 12×16, and the like. The larger the amount of data, the more accurate the subsequent predictions. It should be noted that the pixel point specific performance may be 1 or (0, 1). The acquired plurality of feature information is stored in a two-dimensional mathematical image, similar to a grayscale image, that is, different feature values are recorded at pixel points (x, y).
根据子设备的特征信息的种类可以分成几类特征信息,如电子设备的特征信息分成电子设备的状态信息、时间信息、网络信息和位置信息四类,然后将该四类特征信息分别形成一个子样本图,接着将四个子样本图矩阵设置形成一个大的第二样本图。其中子样本图 可以采用如6×6个像素点,如果特征信息不足以填满子样本图,则不足位置补零处理。四个子样本图形成一个12×12的大的第二样本图。第二样本图和子样本图都为二维的图。According to the type of the feature information of the sub-device, the information may be divided into several types of feature information, for example, the feature information of the electronic device is divided into four categories: state information, time information, network information, and location information of the electronic device, and then the four types of feature information are respectively formed into one sub-category. The sample map is then set up to form a large second sample map. The subsample image can be used as 6×6 pixels. If the feature information is not enough to fill the subsample graph, the position is zero-filled. The four subsample plots form a 12 x 12 large second sample plot. Both the second sample map and the subsample map are two-dimensional maps.
训练单元303,用于获取参考模型,并将第一样本图和第二样本图作为训练数据输入参考模型,进行学习,得到训练后的参考模型的优化参数。The training unit 303 is configured to acquire a reference model, and input the first sample map and the second sample map as training data into the reference model, and learn to obtain optimized parameters of the trained reference model.
其中,参考模型包括两个子参考模型,两个子参考模型为卷积神经网络模型。当然子参考模型可以为混合神经网络模型、高斯混合模型等。The reference model includes two sub-reference models, and the two sub-reference models are convolutional neural network models. Of course, the sub-reference model can be a hybrid neural network model, a Gaussian mixture model, or the like.
请一并参阅图8,图8为本申请实施例提供的参考模型的部分结构示意图。具体的,参考模型包括两个子参考模型,两个子参考模型为卷积神经网络模型,当然子参考模型可以为混合神经网络模型、高斯混合模型等。卷积神经网络模型包括依次连接的卷积层3031和全连接层3032,参考模型还包括分类器3033。具体的,该参考模型主要包括网络结构部分和网络训练部分,其中网络结构部分包括依次连接的卷积层3031和全连接层3032。卷积层3031和全连接层3032之间还可以包括池化层(图中未示出)。将第一样本图305和第二样本图306作为训练数据分别输入两个子参考模型的卷积层3031。Please refer to FIG. 8. FIG. 8 is a partial structural diagram of a reference model according to an embodiment of the present application. Specifically, the reference model includes two sub-reference models, and the two sub-reference models are convolutional neural network models. Of course, the sub-reference models may be hybrid neural network models, Gaussian mixture models, and the like. The convolutional neural network model includes a convolutional layer 3031 and a fully connected layer 3032 that are sequentially connected, and the reference model further includes a classifier 3033. Specifically, the reference model mainly includes a network structure part and a network training part, wherein the network structure part includes a convolution layer 3031 and a full connection layer 3032 which are sequentially connected. A pooling layer (not shown) may also be included between the convoluted layer 3031 and the fully connected layer 3032. The first sample map 305 and the second sample map 306 are respectively input as training data into the convolution layer 3031 of the two sub-reference models.
可选的,卷积神经网络模型参考模型的网络结构部分可以包括七层网络,前五层为卷积层3031,卷积核大小统一为3×3,滑动步长统一为1,由于维度较小,可以不采用池化层,后两层为全连接层3032,分别为20个神经元、2个神经元。Optionally, the network structure part of the convolutional neural network model reference model may include a seven-layer network, the first five layers are convolutional layers 3031, the convolution kernel size is uniformly 3×3, and the sliding step length is unified to 1, due to the dimension Small, you can not use the pooling layer, the latter two layers are fully connected layers 3032, respectively 20 neurons, 2 neurons.
需要说明的是,网络结构部分还可以包括其他层数的卷积层,如3层卷积层、7层卷积层、9层卷积层等,还可以包括其他层数的全连接层,如1层全连接层、3层全连接层等。也可以增加池化层,也可以不采用池化层。卷积核大小可以采用其他大小,如2×2。还可以不同的卷积层采用不同大小的卷积核,如第一层卷积层采用3×3的卷积核,其他层卷积层采用2×2的卷积核。滑动步长可以统一为2或其他值,也可以采用不一样的滑动步长,如第一层滑动步长为2,其他层滑动步长为1等。It should be noted that the network structure part may further include other layers of convolution layers, such as a 3-layer convolution layer, a 7-layer convolution layer, a 9-layer convolution layer, etc., and may also include a full-connection layer of other layers. Such as a 1-layer fully connected layer, a 3-layer fully connected layer, and the like. It is also possible to increase the pooling layer or not to use the pooling layer. The convolution kernel size can be other sizes, such as 2 x 2. Convolution kernels of different sizes can also be used for different convolutional layers. For example, the first layer convolution layer uses a 3×3 convolution kernel, and the other layer convolution layer uses a 2×2 convolution kernel. The sliding step size can be unified to 2 or other values, or a different sliding step size can be used, such as a sliding step of 2 for the first layer and a sliding step of 1 for the other layers.
网络训练部分包括分类器3033,分类器可以为Softmax分类器。The network training portion includes a classifier 3033, and the classifier can be a Softmax classifier.
请一并参阅图9,图9为本申请实施例提供的后台应用程序管控装置的另一结构示意图。在一些实施方式中,训练单元303包括两个网络结构部分,每个网络结构部分包括卷积层3031、全连接层3032,训练单元还包括分类器3033、损失计算器3034和训练子单元3035。Referring to FIG. 9 , FIG. 9 is another schematic structural diagram of a background application control device according to an embodiment of the present application. In some embodiments, the training unit 303 includes two network structure portions, each network structure portion including a convolution layer 3031, a full connection layer 3032, and the training unit further includes a classifier 3033, a loss calculator 3034, and a training subunit 3035.
卷积层3031,可以用于将第一样本图和第二样本图作为训练数据分别输入两个子参考模型的卷积层得到第一中间值和第二中间值。The convolution layer 3031 can be configured to input the first sample map and the second sample map as training data into the convolution layers of the two sub-reference models respectively to obtain a first intermediate value and a second intermediate value.
全连接层3032,可以用于将第一中间值和第二中间值处理得到第三中间值和第四中间值。The fully connected layer 3032 can be configured to process the first intermediate value and the second intermediate value to obtain a third intermediate value and a fourth intermediate value.
分类器3033,可以用于将两个子参考模型的输出值合成输入分类器,并得到对应多个预测结果的概率。即将第三中间值和第四中间值合成输入分类器得到对应多个预测结果的概率。The classifier 3033 can be configured to synthesize the output values of the two sub-reference models into the input classifier and obtain the probability corresponding to the plurality of prediction results. The third intermediate value and the fourth intermediate value are combined into the input classifier to obtain a probability corresponding to the plurality of prediction results.
需要说明的是,将两个子参考模型的输出值合成输入分类器,可以为将两个子参考模型的输出值按不同权重合成输入分类器。即将两个子参考模型的输出值加权和,可以将两个较浅层的卷积神经网络作为弱分类器,再合并成强分类器。具体公式如下:It should be noted that the output values of the two sub-reference models are combined into the input classifier, and the output values of the two sub-reference models can be combined into the input classifier according to different weights. By weighting the output values of the two sub-reference models, two shallower convolutional neural networks can be used as weak classifiers and then merged into strong classifiers. The specific formula is as follows:
Z K=Z K APP+λ*Z K DeviceZ K =Z K APP +λ*Z K Device ,
其中,λ为权重,Z K APP为第一子参考模型的输出值,Z K Device为第二子参考模型的输出值。 Where λ is the weight, Z K APP is the output value of the first sub-reference model, and Z K Device is the output value of the second sub-reference model.
在一些实施方式中,得到预测结果的概率可以基于第一预设公式将两个子参考模型的输出值合成输入分类器,并得到对应多个预测结果的概率,其中第一预设公式为:In some embodiments, the probability of obtaining the prediction result may be based on the first preset formula to synthesize the output values of the two sub-reference models into the input classifier, and obtain a probability corresponding to the plurality of prediction results, wherein the first preset formula is:
Figure PCTCN2018102205-appb-000008
Figure PCTCN2018102205-appb-000008
其中,Z K为两个子参考模型的输出值的合成值,即第三中间值和第四中间值的合成值,C为预测结果的类别数,Z j为第j个合成值。 Where Z K is a composite value of the output values of the two sub-reference models, that is, a composite value of the third intermediate value and the fourth intermediate value, C is the number of categories of the prediction result, and Z j is the j-th composite value.
损失值计算器3034,可以用于根据多个预测结果和与其对应的多个概率得到损失值。The loss value calculator 3034 can be used to obtain a loss value based on a plurality of prediction results and a plurality of probabilities corresponding thereto.
其中,得到损失值可以基于第二预设公式根据多个预测结果和与其对应的多个概率得到损失值,其中第二预设公式为:The obtained loss value may be based on the second preset formula, and the loss value is obtained according to the multiple prediction results and the multiple probabilities corresponding thereto, where the second preset formula is:
Figure PCTCN2018102205-appb-000009
Figure PCTCN2018102205-appb-000009
其中C为预测结果的类别数,y k为真实值。 Where C is the number of categories of predictions and y k is the true value.
训练子单元3035,可以用于根据损失值进行训练,得到优化参数。The training sub-unit 3035 can be used to train according to the loss value to obtain optimized parameters.
具体的,可以根据损失值利用随机梯度下降法进行训练。还可以根据梯度下降法或批量梯度下降法进行训练。Specifically, the random gradient descent method can be used for training according to the loss value. Training can also be performed according to the gradient descent method or the batch gradient descent method.
利用随机梯度下降法进行训练,可以当损失值等于或小于预设损失值时,则完成训练。也可以当连续获取的两个或多个损失值没有变化时,则完成训练。当然还可以不根据损失值,直接设定随机梯度下降法的迭代次数,迭代次数完成后,则完成训练。训练完成后,获取此时的参考模型的各个参数,并将该各个参数保存为优化参数,后续需要预测时,使用该优化参数进行预测。Training is performed using the stochastic gradient descent method, and the training can be completed when the loss value is equal to or less than the preset loss value. It is also possible to complete the training when there are no changes in the two or more loss values continuously acquired. Of course, it is also possible to directly set the number of iterations of the random gradient descent method according to the loss value. After the number of iterations is completed, the training is completed. After the training is completed, each parameter of the reference model at this time is obtained, and the each parameter is saved as an optimization parameter, and when the prediction is needed later, the optimization parameter is used for prediction.
进一步的,得到损失值可以基于第三预设公式根据多组参数得到损失值,每组参数包括多个预测结果和与其对应的多个概率得到损失值,其中第三预设公式为:Further, the obtained loss value may be obtained according to the third preset formula according to the plurality of sets of parameters, and each set of parameters includes a plurality of prediction results and a plurality of probability corresponding to the obtained loss values, wherein the third preset formula is:
Figure PCTCN2018102205-appb-000010
Figure PCTCN2018102205-appb-000010
其中C为预测结果的类别数,y k为真实值,E为平均值。 Where C is the number of categories of prediction results, y k is the true value, and E is the average.
其中可以采用小批量的方式训练得到最优参数。如批量大小为128,第三预设公式中的E表示为128个损失值的平均值。Among them, the optimal parameters can be trained in a small batch manner. If the batch size is 128, E in the third preset formula is expressed as the average of 128 loss values.
具体的,可以先获取多个样本集,多个样本集构建成多个二维的样本图,然后将多个样本图作为训练数据输入参考模型,得到多个损失值,然后求多个损失值的平均值。Specifically, multiple sample sets may be acquired first, and multiple sample sets are constructed into multiple two-dimensional sample images, and then multiple sample images are input as training data into the reference model to obtain multiple loss values, and then multiple loss values are obtained. average of.
管控单元304,用于获取预设后台应用程序和电子设备当前的多个特征信息,并形成第一特征图和第二特征图,根据参考模型、优化参数、第一特征图以及第二特征图,生成预测结果,并根据预测结果对预设后台应用程序进行管控。The control unit 304 is configured to acquire a plurality of feature information of the preset background application and the electronic device, and form a first feature map and a second feature map according to the reference model, the optimization parameter, the first feature map, and the second feature map. , generate prediction results, and control the default background application based on the prediction results.
若需要判断当前后台应用是否可清理,获取预设后台应用程序和电子设备当前的多个 特征信息,并形成二维的第一特征图和第二特征图,将第一特征图和第二特征图输入到参考模型,参考模型根据优化参数计算即可得到预测值。判断预设后台应用程序是否需要清理。If it is necessary to determine whether the current background application is cleanable, obtain a preset background application and a plurality of current feature information of the electronic device, and form a two-dimensional first feature map and a second feature map, and the first feature map and the second feature are obtained. The graph is input to the reference model, and the reference model is calculated based on the optimized parameters to obtain the predicted value. Determine if the default background application needs to be cleaned up.
需要说明的是,参考模型的训练过程可以在服务器端也可以在电子设备端完成。当参考模型的训练过程、实际预测过程都在服务器端完成时,需要使用优化后的参考模型时,可以将预设后台应用程序和电子设备当前的多个特征信息形成特征图,并输入到服务器,服务器实际预测完成后,将预测结果发送至电子设备端,电子设备再根据预测结果管控该预设后台应用程序。It should be noted that the training process of the reference model can be completed on the server side or on the electronic device side. When the training process and the actual prediction process of the reference model are completed on the server side, when the optimized reference model needs to be used, the preset background application and the current multiple feature information of the electronic device may be formed into a feature map and input to the server. After the actual prediction of the server is completed, the prediction result is sent to the electronic device end, and the electronic device controls the preset background application according to the prediction result.
当参考模型的训练过程、实际预测过程都在电子设备端完成时,需要使用优化后的参考模型时,可以将预设后台应用程序和电子设备当前的多个特征信息形成第一特征图和第二特征图,并输入到电子设备,电子设备实际预测完成后,电子设备根据预测结果管控该预设后台应用程序。When the training process and the actual prediction process of the reference model are completed on the electronic device end, when the optimized reference model needs to be used, the preset background application and the current plurality of feature information of the electronic device may be formed into the first feature map and the first feature map. The second feature map is input to the electronic device, and after the actual prediction of the electronic device is completed, the electronic device controls the preset background application according to the predicted result.
在一些实施方式中,管控单元304,还用于检测到预设后台应用程序是否进入后台,若进入后台,则获取预设后台应用程序和电子设备当前的多个特征信息,并形成第一特征图和第二特征图。然后根据参考模型、优化参数、第一特征图以及第二特征图进行预测,生成预测结果,并根据预测结果对预设后台应用程序进行管控。In some embodiments, the control unit 304 is further configured to detect whether the preset background application enters the background, and if the background is entered, acquire the preset background application and the plurality of feature information of the electronic device, and form the first feature. Figure and second feature map. Then, the prediction is performed according to the reference model, the optimization parameter, the first feature map, and the second feature map, and the prediction result is generated, and the preset background application is controlled according to the prediction result.
在一些实施方式中,管控单元304,还用于获取预设时间,若当前系统时间到达预设时间时,则获取预设后台应用程序和电子设备当前的多个特征信息,并形成第一特征图和第二特征图。其中预设时间可以为一天中的一个时间点,如上午9点,也可以为一天中的几个时间点,如上午9点、下午6点等。也可以为多天中的一个或几个时间点。然后根据参考模型、优化参数、第一特征图以及第二特征图生成预测结果,并根据预测结果对预设后台应用程序进行管控。In some embodiments, the control unit 304 is further configured to acquire a preset time, and if the current system time reaches the preset time, acquire the preset background application and the plurality of feature information of the electronic device, and form the first feature. Figure and second feature map. The preset time can be a time point in the day, such as 9 am, or several time points in the day, such as 9 am, 6 pm, and the like. It can also be one or several time points in multiple days. Then, the prediction result is generated according to the reference model, the optimization parameter, the first feature map, and the second feature map, and the preset background application is controlled according to the prediction result.
需要说明的是,参考模型还可以包括多个子参考模型,如3个、5个等。每个子参考模型可以输入不同的样本图,也可以其中2个或多个输入相同的样本图。It should be noted that the reference model may also include multiple sub-reference models, such as three, five, and the like. Each sub-reference model can input different sample maps, or two or more of them can input the same sample map.
上述所有的技术方案,可以采用任意结合形成本申请的可选实施例,在此不再一一赘述。All of the above technical solutions may be combined to form an optional embodiment of the present application, and will not be further described herein.
由上述可知,本申请实施例的后台应用程序管控装置,应用于电子设备,通过获取预设后台应用程序的第一样本集,获取电子设备的第二样本集;将第一样本集和第二样本集分别构建成二维的第一样本图和第二样本图;将第一样本图和第二样本图作为训练数据输入参考模型,进行学习,得到训练后的参考模型的优化参数;获取预设后台应用程序和电子设备当前的多个特征信息,并形成第一特征图和第二特征图,根据参考模型、优化参数、第一特征图以及第二特征图,生成预测结果,并根据预测结果对预设后台应用程序进行管控。可以提高对预设后台应用程序进行预测的准确性,从而提升对进入后台的应用程序进行管控的智能化和准确性。It can be seen from the above that the background application control device of the embodiment of the present application is applied to an electronic device, and acquires a second sample set of the electronic device by acquiring a first sample set of the preset background application; The second sample set is respectively constructed into a two-dimensional first sample map and a second sample map; the first sample map and the second sample map are input as reference data for training data, and learning is performed to obtain an optimized reference model after training. Obtaining a plurality of feature information of the preset background application and the electronic device, and forming a first feature map and a second feature map, and generating a prediction result according to the reference model, the optimization parameter, the first feature map, and the second feature map And control the default background application based on the predicted results. It can improve the accuracy of forecasting the default background application, thus improving the intelligence and accuracy of controlling the application entering the background.
本申请实施例中,后台应用程序管控装置与上文实施例中的后台应用程序管控方法属于同一构思,在后台应用程序管控装置上可以运行后台应用程序管控方法实施例中提供的任一方法,其具体实现过程详见后台应用程序管控方法的实施例,此处不再赘述。In the embodiment of the present application, the background application control device and the background application control method in the above embodiment are in the same concept, and any method provided in the embodiment of the background application management and control method may be run on the background application control device. For details of the implementation process, refer to the embodiment of the background application management and control method, which is not described here.
本申请实施例还提供一种电子设备。请参阅图10,电子设备400包括处理器401以及 存储器402。其中,处理器401与存储器402电性连接。An embodiment of the present application further provides an electronic device. Referring to FIG. 10, the electronic device 400 includes a processor 401 and a memory 402. The processor 401 is electrically connected to the memory 402.
处理器400是电子设备400的控制中心,利用各种接口和线路连接整个电子设备的各个部分,通过运行或加载存储在存储器402内的计算机程序,以及调用存储在存储器402内的数据,执行电子设备400的各种功能并处理数据,从而对电子设备400进行整体监控。The processor 400 is a control center of the electronic device 400 that connects various portions of the entire electronic device using various interfaces and lines, executes the electronic by running or loading a computer program stored in the memory 402, and recalling data stored in the memory 402. The various functions of device 400 and processing data to provide overall monitoring of electronic device 400.
存储器402可用于存储软件程序以及模块,处理器401通过运行存储在存储器402的计算机程序以及模块,从而执行各种功能应用以及数据处理。存储器402可主要包括存储程序区和存储数据区,其中,存储程序区可存储操作系统、至少一个功能所需的计算机程序(比如声音播放功能、图像播放功能等)等;存储数据区可存储根据电子设备的使用所创建的数据等。此外,存储器402可以包括高速随机存取存储器,还可以包括非易失性存储器,例如至少一个磁盘存储器件、闪存器件、或其他易失性固态存储器件。相应地,存储器402还可以包括存储器控制器,以提供处理器401对存储器402的访问。The memory 402 can be used to store software programs and modules, and the processor 401 executes various functional applications and data processing by running computer programs and modules stored in the memory 402. The memory 402 can mainly include a storage program area and a storage data area, wherein the storage program area can store an operating system, a computer program required for at least one function (such as a sound playing function, an image playing function, etc.), and the like; the storage data area can be stored according to Data created by the use of electronic devices, etc. Moreover, memory 402 can include high speed random access memory, and can also include non-volatile memory, such as at least one magnetic disk storage device, flash memory device, or other volatile solid state storage device. Accordingly, memory 402 can also include a memory controller to provide processor 401 access to memory 402.
在本申请实施例中,电子设备400中的处理器401会按照如下流程,将一个或一个以上的计算机程序的进程对应的指令加载到存储器402中,并由处理器401运行存储在存储器402中的计算机程序,从而实现各种功能,如下:In the embodiment of the present application, the processor 401 in the electronic device 400 loads the instructions corresponding to the process of one or more computer programs into the memory 402 according to the following process, and is stored in the memory 402 by the processor 401. The computer program thus implements various functions as follows:
获取预设后台应用程序的第一样本集,获取电子设备的第二样本集;将第一样本集和第二样本集分别构建成二维的第一样本图和第二样本图;将第一样本图和第二样本图作为训练数据输入参考模型,进行学习,得到训练后的参考模型的优化参数;获取预设后台应用程序和电子设备当前的多个特征信息,并形成第一特征图和第二特征图,根据参考模型、优化参数、第一特征图以及第二特征图,生成预测结果,并根据预测结果对预设后台应用程序进行管控。可以提高对预设后台应用程序进行预测的准确性,从而提升对进入后台的应用程序进行管控的智能化和准确性。Obtaining a first sample set of the preset background application, acquiring a second sample set of the electronic device; and constructing the first sample set and the second sample set into a two-dimensional first sample map and a second sample map respectively; The first sample map and the second sample map are input as reference data into the reference model, and the optimized parameters of the reference model are obtained after the training; the preset background application and the current plurality of characteristic information of the electronic device are obtained, and the first A feature map and a second feature map generate a prediction result according to the reference model, the optimization parameter, the first feature map, and the second feature map, and control the preset background application according to the prediction result. It can improve the accuracy of forecasting the default background application, thus improving the intelligence and accuracy of controlling the application entering the background.
在一些实施方式中,处理器401还用于执行:In some embodiments, the processor 401 is further configured to:
参考模型包括两个子参考模型,两个子参考模型为卷积神经网络模型。The reference model includes two sub-reference models, and the two sub-reference models are convolutional neural network models.
在一些实施方式中,处理器401还用于执行:In some embodiments, the processor 401 is further configured to:
参考模型还包括分类器;The reference model also includes a classifier;
将第一样本图和第二样本图作为训练数据分别输入两个子参考模型;The first sample map and the second sample map are respectively input as training data into two sub-reference models;
将两个子参考模型的输出值合成输入分类器,并得到对应多个预测结果的概率;Combining the output values of the two sub-reference models into the input classifier, and obtaining the probability corresponding to the plurality of prediction results;
根据多个预测结果和与其对应的多个概率得到损失值;Obtaining a loss value according to a plurality of prediction results and a plurality of probabilities corresponding thereto;
根据损失值进行训练,得到优化参数。Training is performed according to the loss value to obtain optimized parameters.
在一些实施方式中,处理器401还用于执行:In some embodiments, the processor 401 is further configured to:
将两个子参考模型的输出值按不同权重合成输入分类器。The output values of the two sub-reference models are combined into different input weights.
在一些实施方式中,处理器401还用于执行:In some embodiments, the processor 401 is further configured to:
根据损失值利用随机梯度下降法进行训练。Training is performed using a stochastic gradient descent method based on the loss value.
在一些实施方式中,处理器401还用于执行:In some embodiments, the processor 401 is further configured to:
基于第一预设公式将两个子参考模型的输出值合成输入分类器,并得到对应多个预测结果的概率,其中第一预设公式为:The output values of the two sub-reference models are combined into the input classifier based on the first preset formula, and the probability corresponding to the plurality of prediction results is obtained, wherein the first preset formula is:
Figure PCTCN2018102205-appb-000011
Figure PCTCN2018102205-appb-000011
其中,Z K为两个子参考模型的输出值的合成值,C为预测结果的类别数,Z j为第j个合成值。 Where Z K is the composite value of the output values of the two sub-reference models, C is the number of categories of the prediction results, and Z j is the j-th composite value.
在一些实施方式中,处理器401还用于执行:In some embodiments, the processor 401 is further configured to:
基于第二预设公式根据多个预测结果和与其对应的多个概率得到损失值,其中第二预设公式为:And obtaining a loss value according to the plurality of prediction results and the plurality of probabilities corresponding thereto according to the second preset formula, wherein the second preset formula is:
Figure PCTCN2018102205-appb-000012
Figure PCTCN2018102205-appb-000012
其中C为预测结果的类别数,y k为真实值。 Where C is the number of categories of predictions and y k is the true value.
在一些实施方式中,处理器401还用于执行:In some embodiments, the processor 401 is further configured to:
获取多个损失值,根据多个损失值的平均值进行训练。Obtain multiple loss values and train based on the average of multiple loss values.
在一些实施方式中,处理器401还用于执行:In some embodiments, the processor 401 is further configured to:
基于第三预设公式根据多个预测结果和与其对应的多个概率得到损失值,其中第三预设公式为:The loss value is obtained according to the plurality of prediction results and the plurality of probabilities corresponding thereto according to the third preset formula, wherein the third preset formula is:
Figure PCTCN2018102205-appb-000013
Figure PCTCN2018102205-appb-000013
其中C为预测结果的类别数,y k为真实值,E为平均值。 Where C is the number of categories of prediction results, y k is the true value, and E is the average.
由上述可知,本申请实施例提供的电子设备,通过获取预设后台应用程序的第一样本集,获取电子设备的第二样本集;将第一样本集和第二样本集分别构建成二维的第一样本图和第二样本图;将第一样本图和第二样本图作为训练数据输入参考模型,进行学习,得到训练后的参考模型的优化参数;获取预设后台应用程序和电子设备当前的多个特征信息,并形成第一特征图和第二特征图,根据参考模型、优化参数、第一特征图以及第二特征图,生成预测结果,并根据预测结果对预设后台应用程序进行管控。可以提高对预设后台应用程序进行预测的准确性,从而提升对进入后台的应用程序进行管控的智能化和准确性。It can be seen from the above that the electronic device provided by the embodiment of the present application acquires the second sample set of the electronic device by acquiring the first sample set of the preset background application; and constructs the first sample set and the second sample set respectively. The first sample map and the second sample map are two-dimensional; the first sample map and the second sample map are input as training data into the reference model, and the optimized parameters of the reference model after training are obtained; and the preset background application is obtained. a plurality of feature information of the program and the electronic device, and forming a first feature map and a second feature map, generating a prediction result according to the reference model, the optimization parameter, the first feature map, and the second feature map, and predicting the prediction according to the prediction result Set the background application to manage. It can improve the accuracy of forecasting the default background application, thus improving the intelligence and accuracy of controlling the application entering the background.
请一并参阅图11,在一些实施方式中,电子设备400还可以包括:显示器403、射频电路404、音频电路405以及电源406。其中,其中,显示器403、射频电路404、音频电路405以及电源406分别与处理器401电性连接。Referring to FIG. 11 together, in some embodiments, the electronic device 400 may further include: a display 403, a radio frequency circuit 404, an audio circuit 405, and a power source 406. The display 403, the radio frequency circuit 404, the audio circuit 405, and the power source 406 are electrically connected to the processor 401, respectively.
显示器403可以用于显示由用户输入的信息或提供给用户的信息以及各种图形用户接口,这些图形用户接口可以由图形、文本、图标、视频和其任意组合来构成。显示器403可以包括显示面板,在一些实施方式中,可以采用液晶显示器(Liquid Crystal Display,LCD)、或者有机发光二极管(Organic Light-Emitting Diode,OLED)等形式来配置显示面板。 Display 403 can be used to display information entered by a user or information provided to a user, as well as various graphical user interfaces, which can be composed of graphics, text, icons, video, and any combination thereof. The display 403 can include a display panel. In some embodiments, the display panel can be configured in the form of a liquid crystal display (LCD), or an organic light-emitting diode (OLED).
射频电路404可以用于收发射频信号,以通过无线通信与网络设备或其他电子设备建立无线通讯,与网络设备或其他电子设备之间收发信号。The radio frequency circuit 404 can be used to transmit and receive radio frequency signals to establish wireless communication with network devices or other electronic devices through wireless communication, and to transmit and receive signals with network devices or other electronic devices.
音频电路405可以用于通过扬声器、传声器提供用户与电子设备之间的音频接口。The audio circuit 405 can be used to provide an audio interface between the user and the electronic device through the speaker and the microphone.
电源406可以用于给电子设备400的各个部件供电。在一些实施方式中,电源406可以通过电源管理系统与处理器401逻辑相连,从而通过电源管理系统实现管理充电、放电、以及功耗管理等功能。 Power source 406 can be used to power various components of electronic device 400. In some embodiments, the power supply 406 can be logically coupled to the processor 401 through a power management system to enable functions such as managing charging, discharging, and power management through the power management system.
尽管图11中未示出,电子设备400还可以包括摄像头、蓝牙模块等,在此不再赘述。Although not shown in FIG. 11, the electronic device 400 may further include a camera, a Bluetooth module, and the like, and details are not described herein.
本申请实施例还提供一种存储介质,存储介质存储有计算机程序,当计算机程序在计算机上运行时,使得计算机执行上述任一实施例中的应用程序管控方法,比如:获取预设后台应用程序的第一样本集,获取电子设备的第二样本集;将第一样本集和第二样本集分别构建成二维的第一样本图和第二样本图;将第一样本图和第二样本图作为训练数据输入参考模型,进行学习,得到训练后的参考模型的优化参数;获取预设后台应用程序和电子设备当前的多个特征信息,并形成第一特征图和第二特征图,根据参考模型、优化参数、第一特征图以及第二特征图,生成预测结果,并根据预测结果对预设后台应用程序进行管控。The embodiment of the present application further provides a storage medium, where the storage medium stores a computer program, and when the computer program runs on the computer, causes the computer to execute the application management and control method in any of the above embodiments, for example, acquiring a preset background application. a first sample set, acquiring a second sample set of the electronic device; respectively constructing the first sample set and the second sample set into a two-dimensional first sample map and a second sample map; And the second sample map is used as the training data input reference model to learn, obtain the optimized parameters of the trained reference model; obtain the preset background application and the current plurality of feature information of the electronic device, and form the first feature map and the second The feature map generates a prediction result according to the reference model, the optimization parameter, the first feature map, and the second feature map, and controls the preset background application according to the prediction result.
在本申请实施例中,存储介质可以是磁碟、光盘、只读存储器(Read Only Memory,ROM)、或者随机存取记忆体(Random Access Memory,RAM)等。In the embodiment of the present application, the storage medium may be a magnetic disk, an optical disk, a read only memory (ROM), or a random access memory (RAM).
在上述实施例中,对各个实施例的描述都各有侧重,某个实施例中没有详述的部分,可以参见其他实施例的相关描述。In the above embodiments, the descriptions of the various embodiments are different, and the details that are not detailed in a certain embodiment can be referred to the related descriptions of other embodiments.
需要说明的是,对本申请实施例的后台应用程序管控方法而言,本领域普通测试人员可以理解实现本申请实施例后台应用程序管控方法的全部或部分流程,是可以通过计算机程序来控制相关的硬件来完成,计算机程序可存储于一计算机可读取存储介质中,如存储在电子设备的存储器中,并被该电子设备内的至少一个处理器执行,在执行过程中可包括如后台应用程序管控方法的实施例的流程。其中,的存储介质可为磁碟、光盘、只读存储器、随机存取记忆体等。It should be noted that, in the background application management and control method of the embodiment of the present application, a general tester in the field can understand all or part of the process of implementing the background application control method of the embodiment of the present application, and the related program can be controlled by a computer program. The computer program can be stored in a computer readable storage medium, such as in a memory of the electronic device, and executed by at least one processor in the electronic device, and can include, for example, a background application during execution. The flow of an embodiment of a management method. The storage medium may be a magnetic disk, an optical disk, a read only memory, a random access memory, or the like.
对本申请实施例的后台应用程序管控装置而言,其各功能模块可以集成在一个处理芯片中,也可以是各个模块单独物理存在,也可以两个或两个以上模块集成在一个模块中。上述集成的模块既可以采用硬件的形式实现,也可以采用软件功能模块的形式实现。集成的模块如果以软件功能模块的形式实现并作为独立的产品销售或使用时,也可以存储在一个计算机可读取存储介质中,存储介质譬如为只读存储器,磁盘或光盘等。For the background application management device of the embodiment of the present application, each functional module may be integrated into one processing chip, or each module may exist physically separately, or two or more modules may be integrated into one module. The above integrated modules can be implemented in the form of hardware or in the form of software functional modules. An integrated module, if implemented in the form of a software functional module and sold or used as a standalone product, may also be stored in a computer readable storage medium such as a read only memory, a magnetic disk or an optical disk.
以上对本申请实施例所提供的一种后台应用程序管控方法、存储介质及电子设备进行了详细介绍,本文中应用了具体个例对本申请的原理及实施方式进行了阐述,以上实施例的说明只是用于帮助理解本申请的方法及其核心思想;同时,对于本领域的技术人员,依据本申请的思想,在具体实施方式及应用范围上均会有改变之处,综上所述,本说明书内容不应理解为对本申请的限制。The background application control method, the storage medium, and the electronic device provided by the embodiments of the present application are described in detail. The principles and implementation manners of the application are described in the specific examples. The description of the above embodiments is only The method for understanding the present application and its core idea; at the same time, those skilled in the art, according to the idea of the present application, there will be changes in the specific embodiment and the scope of application, in summary, the present specification The content should not be construed as limiting the application.

Claims (20)

  1. 一种后台应用程序管控方法,应用于电子设备,所述方法包括:A background application management method for an electronic device, the method comprising:
    获取预设后台应用程序的第一样本集,获取所述电子设备的第二样本集,其中所述第一样本集和第二样本集中的样本分别包括所述预设后台应用程序和所述电子设备的多个特征信息;Obtaining a first sample set of the preset background application, acquiring a second sample set of the electronic device, where the samples in the first sample set and the second sample set respectively include the preset background application and the Denoting a plurality of characteristic information of the electronic device;
    将所述第一样本集和所述第二样本集分别构建成二维的第一样本图和第二样本图;Constructing the first sample set and the second sample set into a two-dimensional first sample map and a second sample map, respectively;
    获取参考模型,并将所述第一样本图和所述第二样本图作为训练数据输入所述参考模型,进行学习,得到训练后的所述参考模型的优化参数;Obtaining a reference model, and inputting the first sample map and the second sample map as training data into the reference model, performing learning, and obtaining optimized parameters of the reference model after training;
    获取所述预设后台应用程序和所述电子设备当前的多个特征信息,并形成第一特征图和第二特征图,根据所述参考模型、所述优化参数、所述第一特征图以及所述第二特征图,生成预测结果,并根据所述预测结果对所述预设后台应用程序进行管控。Acquiring the preset background application and the current plurality of feature information of the electronic device, and forming a first feature map and a second feature map, according to the reference model, the optimization parameter, the first feature map, and The second feature map generates a prediction result, and controls the preset background application according to the prediction result.
  2. 根据权利要求1所述的后台应用程序管控方法,其中,所述参考模型包括两个子参考模型,两个所述子参考模型为卷积神经网络模型。The background application management method according to claim 1, wherein the reference model comprises two sub-reference models, and the two sub-reference models are convolutional neural network models.
  3. 根据权利要求2所述的后台应用程序管控方法,其中,所述参考模型还包括分类器;The background application management method according to claim 2, wherein the reference model further comprises a classifier;
    所述将所述第一样本图和第二样本图作为训练数据输入所述参考模型,进行学习,得到训练后的所述参考模型的优化参数具体包括:And inputting the first sample map and the second sample map as the training data into the reference model, and learning, and obtaining the optimized parameters of the reference model after training includes:
    将所述第一样本图和第二样本图作为训练数据分别输入两个所述子参考模型;And inputting the first sample map and the second sample map as training data into two of the sub-reference models respectively;
    将两个所述子参考模型的输出值合成输入所述分类器,并得到对应多个所述预测结果的概率;Combining output values of two of the sub-reference models into the classifier, and obtaining a probability corresponding to the plurality of prediction results;
    根据多个所述预测结果和与其对应的多个所述概率得到损失值;Obtaining a loss value according to the plurality of prediction results and a plurality of the probabilities corresponding thereto;
    根据所述损失值进行训练,得到所述优化参数。Training is performed according to the loss value to obtain the optimization parameter.
  4. 根据权利要求3所述的后台应用程序管控方法,其中,所述根据所述损失值进行训练具体包括:The background application management method according to claim 3, wherein the training according to the loss value specifically includes:
    根据所述损失值利用随机梯度下降法进行训练。Training is performed using a stochastic gradient descent method based on the loss value.
  5. 根据权利要求3所述的后台应用程序管控方法,其中,所述将两个所述子参考模型的输出值合成输入所述分类器具体包括:The background application management method according to claim 3, wherein the synthesizing the output values of the two sub-reference models into the classifier comprises:
    将两个所述子参考模型的输出值按不同权重合成输入所述分类器。The output values of the two sub-reference models are combined into the classifier by different weights.
  6. 根据权利要求3所述的后台应用程序管控方法,其中,所述将两个所述子参考模型的输出值合成输入所述分类器,并得到对应多个所述预测结果的概率具体包括:The background application management method according to claim 3, wherein the synthesizing the output values of the two sub-reference models into the classifier and obtaining the probability corresponding to the plurality of prediction results specifically includes:
    基于第一预设公式将两个所述子参考模型的输出值合成输入所述分类器,并得到对应多个所述预测结果的概率,其中所述第一预设公式为:Generating an output value of two of the sub-reference models into the classifier based on a first preset formula, and obtaining a probability corresponding to the plurality of prediction results, wherein the first preset formula is:
    Figure PCTCN2018102205-appb-100001
    Figure PCTCN2018102205-appb-100001
    其中,Z K为两个所述子参考模型的输出值的合成值,C为预测结果的类别数,Z j为第j个合成值。 Where Z K is a composite value of the output values of the two sub-reference models, C is the number of categories of the prediction result, and Z j is the j-th composite value.
  7. 根据权利要求3所述的后台应用程序管控方法,其中,所述根据多个所述预测结 果和与其对应的多个所述概率得到损失值具体包括:The background application management method according to claim 3, wherein the obtaining the loss value according to the plurality of the prediction results and the plurality of the probabilities corresponding thereto specifically comprises:
    基于第二预设公式根据多个所述预测结果和与其对应的多个所述概率得到损失值,其中所述第二预设公式为:And obtaining, according to the second preset formula, a loss value according to the plurality of the prediction results and a plurality of the probabilities corresponding thereto, wherein the second preset formula is:
    Figure PCTCN2018102205-appb-100002
    Figure PCTCN2018102205-appb-100002
    其中C为预测结果的类别数,y k为真实值。 Where C is the number of categories of predictions and y k is the true value.
  8. 根据权利要求3所述的后台应用程序管控方法,其中,所述根据所述损失值进行训练具体包括:The background application management method according to claim 3, wherein the training according to the loss value specifically includes:
    获取多个所述损失值,根据多个所述损失值的平均值进行训练。A plurality of the loss values are obtained, and training is performed based on an average of the plurality of the loss values.
  9. 根据权利要求8所述的后台应用程序管控方法,其中,所述根据多个所述预测结果和与其对应的多个所述概率得到损失值具体包括:The background application management method according to claim 8, wherein the obtaining the loss value according to the plurality of the prediction results and the plurality of the probabilities corresponding thereto specifically comprises:
    基于第三预设公式根据多个所述预测结果和与其对应的多个所述概率得到损失值,其中所述第三预设公式为:And obtaining, according to a third preset formula, a loss value according to the plurality of the prediction results and a plurality of the probabilities corresponding thereto, wherein the third preset formula is:
    Figure PCTCN2018102205-appb-100003
    Figure PCTCN2018102205-appb-100003
    其中C为预测结果的类别数,y k为真实值,E为平均值。 Where C is the number of categories of prediction results, y k is the true value, and E is the average.
  10. 根据权利要求1所述的后台应用程序管控方法,其中,所述获取预设后台应用程序和电子设备当前的多个特征信息具体包括:The background application management method according to claim 1, wherein the obtaining the preset background application and the plurality of feature information of the electronic device specifically includes:
    获取预设时间;Get the preset time;
    若当前系统时间到达预设时间时,则获取预设后台应用程序和电子设备当前的多个特征信息。If the current system time reaches the preset time, the preset background application and the plurality of feature information of the electronic device are obtained.
  11. 根据权利要求1所述的后台应用程序管控方法,其中,所述获取预设后台应用程序和电子设备当前的多个特征信息具体包括:The background application management method according to claim 1, wherein the obtaining the preset background application and the plurality of feature information of the electronic device specifically includes:
    检测到预设后台应用程序是否进入后台;Detecting whether the default background application enters the background;
    若进入后台,则获取预设后台应用程序和电子设备当前的多个特征信息。If the background is entered, the preset background application and the plurality of feature information of the electronic device are obtained.
  12. 一种存储介质,其上存储有计算机程序,其中,当所述计算机程序在计算机上运行时,使得所述计算机执行如权利要求1至12任一项所述的后台应用程序管控方法。A storage medium having stored thereon a computer program, wherein when the computer program is run on a computer, the computer is caused to execute the background application management method according to any one of claims 1 to 12.
  13. 一种电子设备,包括处理器和存储器,所述存储器有计算机程序,其中,所述处理器通过调用所述计算机程序,其中,所述处理器还执行:An electronic device comprising a processor and a memory, the memory having a computer program, wherein the processor calls the computer program, wherein the processor further executes:
    获取预设后台应用程序的第一样本集,获取所述电子设备的第二样本集,其中所述第一样本集和第二样本集中的样本分别包括所述预设后台应用程序和所述电子设备的多个特征信息;Obtaining a first sample set of the preset background application, acquiring a second sample set of the electronic device, where the samples in the first sample set and the second sample set respectively include the preset background application and the Denoting a plurality of characteristic information of the electronic device;
    将所述第一样本集和所述第二样本集分别构建成二维的第一样本图和第二样本图;Constructing the first sample set and the second sample set into a two-dimensional first sample map and a second sample map, respectively;
    获取参考模型,并将所述第一样本图和所述第二样本图作为训练数据输入所述参考模型,进行学习,得到训练后的所述参考模型的优化参数;Obtaining a reference model, and inputting the first sample map and the second sample map as training data into the reference model, performing learning, and obtaining optimized parameters of the reference model after training;
    获取所述预设后台应用程序和所述电子设备当前的多个特征信息,并形成第一特征图和第二特征图,根据所述参考模型、所述优化参数、所述第一特征图以及所述第二特征图, 生成预测结果,并根据所述预测结果对所述预设后台应用程序进行管控。Acquiring the preset background application and the current plurality of feature information of the electronic device, and forming a first feature map and a second feature map, according to the reference model, the optimization parameter, the first feature map, and The second feature map generates a prediction result, and controls the preset background application according to the prediction result.
  14. 根据权利要求13所述的电子设备,其中,所述参考模型包括两个子参考模型,两个所述子参考模型为卷积神经网络模型。The electronic device of claim 13, wherein the reference model comprises two sub-reference models, two of which are convolutional neural network models.
  15. 根据权利要求14所述的电子设备,其中,所述参考模型还包括分类器;The electronic device of claim 14, wherein the reference model further comprises a classifier;
    在将所述第一样本图和第二样本图作为训练数据输入所述参考模型,进行学习,得到训练后的所述参考模型的优化参数中,所述处理器还执行:And inputting, by the first sample map and the second sample map as the training data into the reference model, learning, and obtaining the optimized parameters of the reference model after training, the processor further performing:
    将所述第一样本图和第二样本图作为训练数据分别输入两个所述子参考模型;And inputting the first sample map and the second sample map as training data into two of the sub-reference models respectively;
    将两个所述子参考模型的输出值合成输入所述分类器,并得到对应多个所述预测结果的概率;Combining output values of two of the sub-reference models into the classifier, and obtaining a probability corresponding to the plurality of prediction results;
    根据多个所述预测结果和与其对应的多个所述概率得到损失值;Obtaining a loss value according to the plurality of prediction results and a plurality of the probabilities corresponding thereto;
    根据所述损失值进行训练,得到所述优化参数。Training is performed according to the loss value to obtain the optimization parameter.
  16. 根据权利要求15所述的电子设备,其中,所述参考模型还包括分类器;The electronic device of claim 15, wherein the reference model further comprises a classifier;
    在根据所述损失值进行训练中,所述处理器还执行:In training based on the loss value, the processor also performs:
    根据所述损失值利用随机梯度下降法进行训练。Training is performed using a stochastic gradient descent method based on the loss value.
  17. 根据权利要求15所述的电子设备,其中,所述参考模型还包括分类器;The electronic device of claim 15, wherein the reference model further comprises a classifier;
    在将两个所述子参考模型的输出值合成输入所述分类器,并得到对应多个所述预测结果的概率中,所述处理器还执行:In synthesizing the output values of the two sub-reference models into the classifier and obtaining a probability corresponding to the plurality of prediction results, the processor further performs:
    基于第一预设公式将两个所述子参考模型的输出值合成输入所述分类器,并得到对应多个所述预测结果的概率,其中所述第一预设公式为:Generating an output value of two of the sub-reference models into the classifier based on a first preset formula, and obtaining a probability corresponding to the plurality of prediction results, wherein the first preset formula is:
    Figure PCTCN2018102205-appb-100004
    Figure PCTCN2018102205-appb-100004
    其中,Z K为两个所述子参考模型的输出值的合成值,C为预测结果的类别数,Z j为第j个合成值。 Where Z K is a composite value of the output values of the two sub-reference models, C is the number of categories of the prediction result, and Z j is the j-th composite value.
  18. 根据权利要求15所述的电子设备,其中,所述参考模型还包括分类器;The electronic device of claim 15, wherein the reference model further comprises a classifier;
    在根据多个所述预测结果和与其对应的多个所述概率得到损失值中,所述处理器还执行:基于第二预设公式根据多个所述预测结果和与其对应的多个所述概率得到损失值,其中所述第二预设公式为:In the obtaining a loss value according to the plurality of the prediction results and the plurality of the probabilities corresponding thereto, the processor further performs: performing, according to the second preset formula, the plurality of the prediction results and the plurality of the corresponding ones The probability yields a loss value, wherein the second preset formula is:
    Figure PCTCN2018102205-appb-100005
    Figure PCTCN2018102205-appb-100005
    其中C为预测结果的类别数,y k为真实值。 Where C is the number of categories of predictions and y k is the true value.
  19. 根据权利要求15所述的电子设备,其中,所述参考模型还包括分类器;The electronic device of claim 15, wherein the reference model further comprises a classifier;
    在根据所述损失值进行训练中,所述处理器还执行:In training based on the loss value, the processor also performs:
    获取多个所述损失值,根据多个所述损失值的平均值进行训练。A plurality of the loss values are obtained, and training is performed based on an average of the plurality of the loss values.
  20. 根据权利要求19所述的电子设备,其中,在根据多个所述预测结果和与其对应的多个所述概率得到损失值中,所述处理器还执行:The electronic device according to claim 19, wherein said processor further performs: in accordance with a plurality of said prediction results and a plurality of said probabilities corresponding to the loss values, said processor further performing:
    基于第三预设公式根据多个所述预测结果和与其对应的多个所述概率得到损失值,其中所述第三预设公式为:And obtaining, according to a third preset formula, a loss value according to the plurality of the prediction results and a plurality of the probabilities corresponding thereto, wherein the third preset formula is:
    Figure PCTCN2018102205-appb-100006
    Figure PCTCN2018102205-appb-100006
    其中C为预测结果的类别数,y k为真实值,E为平均值。 Where C is the number of categories of prediction results, y k is the true value, and E is the average.
PCT/CN2018/102205 2017-09-30 2018-08-24 Method for managing and controlling background application program, storage medium, and electronic device WO2019062411A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201710917794.1 2017-09-30
CN201710917794.1A CN107729078B (en) 2017-09-30 2017-09-30 Background application management-control method, device, storage medium and electronic equipment

Publications (1)

Publication Number Publication Date
WO2019062411A1 true WO2019062411A1 (en) 2019-04-04

Family

ID=61209618

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2018/102205 WO2019062411A1 (en) 2017-09-30 2018-08-24 Method for managing and controlling background application program, storage medium, and electronic device

Country Status (2)

Country Link
CN (1) CN107729078B (en)
WO (1) WO2019062411A1 (en)

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107729078B (en) * 2017-09-30 2019-12-03 Oppo广东移动通信有限公司 Background application management-control method, device, storage medium and electronic equipment
CN110459204A (en) * 2018-05-02 2019-11-15 Oppo广东移动通信有限公司 Audio recognition method, device, storage medium and electronic equipment
CN110458223B (en) * 2019-08-06 2023-03-17 湖南省华芯医疗器械有限公司 Automatic detection method and detection system for bronchial tumor under endoscope

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106055399A (en) * 2016-05-31 2016-10-26 宇龙计算机通信科技(深圳)有限公司 Application program control method and terminal
CN106295506A (en) * 2016-07-25 2017-01-04 华南理工大学 A kind of age recognition methods based on integrated convolutional neural networks
CN106295682A (en) * 2016-08-02 2017-01-04 厦门美图之家科技有限公司 A kind of judge the method for the picture quality factor, device and calculating equipment
US9753949B1 (en) * 2016-03-14 2017-09-05 Shutterstock, Inc. Region-specific image download probability modeling
CN107729078A (en) * 2017-09-30 2018-02-23 广东欧珀移动通信有限公司 Background application management-control method, device, storage medium and electronic equipment

Family Cites Families (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US9622041B2 (en) * 2013-03-15 2017-04-11 DGS Global Systems, Inc. Systems, methods, and devices for electronic spectrum management
CN104156715B (en) * 2014-09-01 2018-08-28 杭州朗和科技有限公司 A kind of terminal device, information collecting method and device
CN107133094B (en) * 2017-06-05 2021-11-02 努比亚技术有限公司 Application management method, mobile terminal and computer readable storage medium

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US9753949B1 (en) * 2016-03-14 2017-09-05 Shutterstock, Inc. Region-specific image download probability modeling
CN106055399A (en) * 2016-05-31 2016-10-26 宇龙计算机通信科技(深圳)有限公司 Application program control method and terminal
CN106295506A (en) * 2016-07-25 2017-01-04 华南理工大学 A kind of age recognition methods based on integrated convolutional neural networks
CN106295682A (en) * 2016-08-02 2017-01-04 厦门美图之家科技有限公司 A kind of judge the method for the picture quality factor, device and calculating equipment
CN107729078A (en) * 2017-09-30 2018-02-23 广东欧珀移动通信有限公司 Background application management-control method, device, storage medium and electronic equipment

Also Published As

Publication number Publication date
CN107729078B (en) 2019-12-03
CN107729078A (en) 2018-02-23

Similar Documents

Publication Publication Date Title
WO2019062413A1 (en) Method and apparatus for managing and controlling application program, storage medium, and electronic device
WO2022083536A1 (en) Neural network construction method and apparatus
CN110929807B (en) Training method of image classification model, and image classification method and device
WO2022016556A1 (en) Neural network distillation method and apparatus
WO2019120019A1 (en) User gender prediction method and apparatus, storage medium and electronic device
CN111813532B (en) Image management method and device based on multitask machine learning model
US11126140B2 (en) Electronic device, external device capable of being combined with the electronic device, and a display method thereof
US11249645B2 (en) Application management method, storage medium, and electronic apparatus
CN113284142B (en) Image detection method, image detection device, computer-readable storage medium and computer equipment
WO2019062411A1 (en) Method for managing and controlling background application program, storage medium, and electronic device
CN112287994A (en) Pseudo label processing method, device, equipment and computer readable storage medium
WO2019062405A1 (en) Application program processing method and apparatus, storage medium, and electronic device
WO2021089008A1 (en) Method and device for predicting intermolecular binding activity
CN114402336A (en) Neural processing unit
CN112632380A (en) Training method of interest point recommendation model and interest point recommendation method
WO2023207487A1 (en) Circuit wiring determination method and related device
CN107943571B (en) Background application control method and device, storage medium and electronic equipment
CN115905687A (en) Cold start-oriented recommendation system and method based on meta-learning graph neural network
CN113628221B (en) Image processing method, image segmentation model training method and related device
CN113111917B (en) Zero sample image classification method and device based on dual self-encoders
US20210150371A1 (en) Automatic multi-objective hardware optimization for processing of deep learning networks
WO2024114659A1 (en) Summary generation method and related device
WO2019062409A1 (en) Method for managing and controlling background application program, storage medium, and electronic device
CN108681480B (en) Background application program control method and device, storage medium and electronic equipment
CN112418442A (en) Data processing method, device, equipment and storage medium for federal transfer learning

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 18860044

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 18860044

Country of ref document: EP

Kind code of ref document: A1