CN107678845B - Application program control method and device, storage medium and electronic equipment - Google Patents

Application program control method and device, storage medium and electronic equipment Download PDF

Info

Publication number
CN107678845B
CN107678845B CN201710940355.2A CN201710940355A CN107678845B CN 107678845 B CN107678845 B CN 107678845B CN 201710940355 A CN201710940355 A CN 201710940355A CN 107678845 B CN107678845 B CN 107678845B
Authority
CN
China
Prior art keywords
application program
application
prediction
loss function
sample
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201710940355.2A
Other languages
Chinese (zh)
Other versions
CN107678845A (en
Inventor
曾元清
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Guangdong Oppo Mobile Telecommunications Corp Ltd
Original Assignee
Guangdong Oppo Mobile Telecommunications Corp Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Guangdong Oppo Mobile Telecommunications Corp Ltd filed Critical Guangdong Oppo Mobile Telecommunications Corp Ltd
Priority to CN201710940355.2A priority Critical patent/CN107678845B/en
Publication of CN107678845A publication Critical patent/CN107678845A/en
Priority to PCT/CN2018/102254 priority patent/WO2019062414A1/en
Application granted granted Critical
Publication of CN107678845B publication Critical patent/CN107678845B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

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
    • 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/46Multiprogramming arrangements
    • G06F9/48Program initiating; Program switching, e.g. by interrupt
    • G06F9/4806Task transfer initiation or dispatching
    • G06F9/4843Task transfer initiation or dispatching by program, e.g. task dispatcher, supervisor, operating system
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/20Analysing
    • G06F18/21Design or setup of recognition systems or techniques; Extraction of features in feature space; Blind source separation
    • G06F18/214Generating training patterns; Bootstrap methods, e.g. bagging or boosting
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/20Analysing
    • G06F18/285Selection of pattern recognition techniques, e.g. of classifiers in a multi-classifier system
    • 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/46Multiprogramming arrangements
    • G06F9/48Program initiating; Program switching, e.g. by interrupt
    • G06F9/4806Task transfer initiation or dispatching
    • G06F9/4843Task transfer initiation or dispatching by program, e.g. task dispatcher, supervisor, operating system
    • G06F9/485Task life-cycle, e.g. stopping, restarting, resuming execution
    • 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/46Multiprogramming arrangements
    • G06F9/50Allocation of resources, e.g. of the central processing unit [CPU]
    • G06F9/5005Allocation of resources, e.g. of the central processing unit [CPU] to service a request
    • G06F9/5011Allocation of resources, e.g. of the central processing unit [CPU] to service a request the resources being hardware resources other than CPUs, Servers and Terminals
    • G06F9/5022Mechanisms to release resources
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N20/00Machine learning
    • G06N20/20Ensemble learning
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/08Learning methods

Abstract

The application discloses an application program control method, an application program control device, a storage medium and electronic equipment, wherein the method comprises the following steps: the method comprises the steps of collecting multi-dimensional feature information of an application program as a sample, constructing a sample set of the application program, extracting feature information from the sample set according to preset rules, constructing a plurality of training sets, training a logistic regression model according to the training sets to obtain a trained prediction model, obtaining the current multi-dimensional feature information of the application program and using the current multi-dimensional feature information as a prediction sample, generating a prediction result according to the prediction sample and the trained prediction model, and managing and controlling the application program according to the prediction result. According to the application program prediction method and device, the accuracy of prediction of the application program can be improved, and therefore the intelligence and the accuracy of management and control of the application program entering a background are improved.

Description

Application program control method and device, storage medium and electronic equipment
Technical Field
The present application belongs to the field of communications technologies, and in particular, to a method and an apparatus for managing and controlling an application, a storage medium, and an electronic device.
Background
With the development of electronic technology, people usually install many applications on electronic devices. When a user opens multiple application programs in the electronic device, if the user returns to a desktop of the electronic device or stays at an application interface of a certain application program or controls a screen of the electronic device, the multiple application programs opened by the user still run in a background of the electronic device. However, many application users in the background do not use the applications for a period of time, but the applications running in the background can severely occupy the memory of the electronic device, so that the occupancy rate of a Central Processing Unit (CPU) is too high, which causes the problems of slow running speed, blocking, too fast power consumption and the like of the electronic device, and causes the power consumption speed of the electronic device to be increased.
Disclosure of Invention
The application provides an application program control method and device, a storage medium and an electronic device, and the intellectualization and the accuracy of control of the application program can be improved.
In a first aspect, an embodiment of the present application provides an application management and control method, including:
collecting multidimensional characteristic information of an application program as a sample, and constructing a sample set of the application program;
extracting characteristic information from the sample set according to a preset rule, and constructing a plurality of training sets;
training a logistic regression model according to the training sets to obtain a trained prediction model;
acquiring current multi-dimensional feature information of the application program and using the current multi-dimensional feature information as a prediction sample, generating a prediction result according to the prediction sample and the trained prediction model, and managing and controlling the application program according to the prediction result.
In a second aspect, an embodiment of the present application provides an application management and control apparatus, including:
the acquisition module is used for acquiring multi-dimensional characteristic information of an application program as a sample and constructing a sample set of the application program;
the construction module is used for extracting characteristic information from the sample set according to a preset rule and constructing a plurality of training sets;
the training module is used for training the logistic regression model according to the plurality of training sets to obtain a trained prediction model;
and the control module is used for acquiring the current multi-dimensional characteristic information of the application program and taking the information as a prediction sample, generating a prediction result according to the prediction sample and the trained prediction model, and controlling the application program according to the prediction result.
In a third 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, the computer is caused to execute the application program management and control method described above.
In a fourth 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 is configured to execute the application management and control method described above by calling the computer program.
According to the application program control method, the application program control device, the storage medium and the electronic equipment, the multi-dimensional feature information of the application program is collected to serve as the sample, the sample set of the application program is built, the feature information is extracted from the sample set according to the preset rules, the training sets are built, the logistic regression model is trained according to the training sets to obtain the trained prediction model, the current multi-dimensional feature information of the application program is obtained and serves as the prediction sample, the prediction result is generated according to the prediction sample and the trained prediction model, and the application program is controlled according to the prediction result. According to the application program prediction method and device, the accuracy of prediction of the application program can be improved, and therefore the intelligence and the accuracy of management and control of the application program entering a background are improved.
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 introduced below. It is obvious that the drawings in the following description are only some embodiments of the application, and that for a person skilled in the art, other drawings can be derived from them without inventive effort.
Fig. 1 is a system diagram of an application management and control apparatus according to an embodiment of the present disclosure.
Fig. 2 is a schematic view of an application scenario of an application management and control apparatus according to an embodiment of the present application.
Fig. 3 is a flowchart illustrating an application management and control method according to an embodiment of the present application.
Fig. 4 is another flowchart illustrating an application management and control method according to an embodiment of the present disclosure.
Fig. 5 is a schematic view of another application scenario of the application management and control apparatus according to the embodiment of the present application.
Fig. 6 is a schematic structural diagram of an application management and control apparatus according to an embodiment of the present disclosure.
Fig. 7 is another schematic structural diagram of an application management and control apparatus according to an embodiment of the present disclosure.
Fig. 8 is a schematic structural diagram of an application management and control apparatus according to an embodiment of the present disclosure.
Fig. 9 is a schematic structural diagram of an electronic device according to an embodiment of the present application.
Fig. 10 is another schematic structural diagram of an electronic device according to an embodiment of the present application.
Detailed Description
Referring to the drawings, wherein like reference numbers refer to like elements, the principles of the present application are illustrated as being implemented in a suitable computing environment. The following description is based on illustrated embodiments of the application and should not be taken as limiting the application with respect to other embodiments that are not detailed herein.
In the description that follows, specific embodiments of the present application will be described with reference to steps and symbols executed by one or more computers, unless otherwise indicated. Accordingly, these steps and operations will be referred to, several times, as being performed by a computer, the computer performing operations involving a processing unit of the computer in electronic signals representing data in a structured form. This operation transforms the data or maintains it at locations in the computer's memory system, which may be reconfigured or otherwise altered in a manner well known to those skilled in the art. The data maintains a data structure that is a physical location of the memory that has particular characteristics defined by the data format. However, while the principles of the application have been described in language specific to above, it is not intended to be limited to the specific form set forth herein, and it will be recognized by those of ordinary skill in the art that various of the steps and operations described below may be implemented in hardware.
The term "module" as used herein may be considered a software object executing on the computing system. The different components, modules, engines, and services described herein may be considered as implementation objects on the computing system. The apparatus and method described herein may be implemented in software, but may also be implemented in hardware, and are within the scope of the present application.
The terms "first", "second", and "third", etc. in this application are used to distinguish between different objects and not to describe a particular order. Furthermore, the terms "include" and "have," as well as any variations thereof, are intended to cover non-exclusive inclusions. For example, a process, method, system, article, or apparatus that comprises a list of steps or modules is not limited to only those steps or modules listed, but rather, some embodiments may include other steps or modules not listed or inherent to such process, method, article, or apparatus.
Reference herein to "an embodiment" means that a particular feature, structure, or characteristic described in connection with the embodiment can be included in at least one embodiment of the application. The appearances of the phrase in various places in the specification are not necessarily all referring to the same embodiment, nor are separate or alternative embodiments mutually exclusive of other embodiments. It is explicitly and implicitly understood by one skilled in the art that the embodiments described herein can be combined with other embodiments.
In the prior art, when a background application is managed and controlled, part of the background application is generally cleaned directly according to the memory occupation condition of the electronic device and the priority of each application, so as to release the memory. However, some applications are important to the user, or some applications need to be used again by the user in a short time, and if the applications are cleaned up when cleaning up the applications later, the process of reloading the applications by the electronic device is required when the user uses the applications again, which consumes a lot of time and memory resources. The electronic device can be a smart phone, a tablet computer, a desktop computer, a notebook computer, a palm computer or other devices.
Referring to fig. 1, fig. 1 is a system schematic diagram of an application management and control apparatus according to an embodiment of the present disclosure. The application program management and control device is mainly used for: the method comprises the steps of collecting multi-dimensional feature information of an application program as a sample, constructing a sample set of the application program, extracting feature information from the sample set according to preset rules, constructing a plurality of training sets, training a logistic regression model according to the training sets to obtain a trained prediction model, obtaining the current multi-dimensional feature information of the application program and using the current multi-dimensional feature information as a prediction sample, generating a prediction result according to the prediction sample and the trained prediction model, and managing and controlling the application program according to the prediction result, such as cleaning or freezing.
Specifically, please refer to fig. 2, and fig. 2 is a schematic view illustrating an application scenario of an application management and control apparatus according to an embodiment of the present disclosure. For example, when receiving the management request, the application management device detects that the applications running in the background of the electronic device include an application a, an application b, and an application c. Then, respectively acquiring multidimensional characteristic information corresponding to the application program a, multidimensional characteristic information corresponding to the application program b and multidimensional characteristic information corresponding to the application program c, predicting the probability of whether the application program a needs to be used or not through a logistic regression model to obtain a probability a ', predicting the probability of whether the application program b needs to be used or not through the logistic regression model to obtain a probability b ', predicting the probability of whether the application program c needs to be used or not through the logistic regression model to obtain a probability c '; and managing and controlling the application programs a, b and c running in the background according to the probabilities a ', b ' and c ', for example, closing the application program b with the lowest probability.
An execution main body of the application management and control method may be the application management and control device provided in the embodiment of the present application, or an electronic device integrated with the application management and control device, where the application management and control device may be implemented in a hardware or software manner.
The embodiments of the present application will be described from the perspective of an application management and control apparatus, which may be specifically integrated in an electronic device. The application program management and control method comprises the following steps: the method comprises the steps of collecting multi-dimensional feature information of an application program as a sample, constructing a sample set of the application program, extracting feature information from the sample set according to preset rules, constructing a plurality of training sets, training a logistic regression model according to the training sets to obtain a trained prediction model, obtaining the current multi-dimensional feature information of the application program and using the current multi-dimensional feature information as a prediction sample, generating a prediction result according to the prediction sample and the trained prediction model, and managing and controlling the application program according to the prediction result.
Referring to fig. 3, fig. 3 is a flowchart illustrating an application management and control method according to an embodiment of the present disclosure. The application program management and control method provided by the embodiment of the application program is applied to the electronic equipment, and the specific flow can be as follows:
step 101, collecting multidimensional characteristic information of an application program as a sample, and constructing a sample set of the application program.
The predetermined application may be any application installed in the electronic device, such as a communication application, a multimedia application, a game application, an information application, or a shopping application.
The applied multidimensional characteristic information has dimensions with a certain length, and the parameter on each dimension corresponds to one characteristic information for representing the application, namely the multidimensional characteristic information is composed of a plurality of characteristic information. The plurality of feature information may include feature information related to the application itself. In one embodiment, 30 features of a device may be gathered to form a 30-dimensional vector, the 30 features being, for example:
applying the time length from last background switching-in to present;
accumulating the closing time length of the screen during the period from the last background switching-in to the present application;
the last time the application is used in the foreground;
the last time the application is used in the foreground;
the last time the application is used in the foreground;
applying the number of times of entering the foreground in one day (counted by each day);
applying the times of entering the foreground in one day (the rest days are separately counted according to the working days and the rest days);
applying the time of day (counted daily) in the foreground;
applying the time in the foreground in one day (the rest days are counted separately according to the working days and the rest days);
the length of time that the target application is used in the period of 8:00-12:00 per day;
target application is in the first bin of the background dwell time histogram (0-5 minutes corresponding times to a ratio);
target application stays in the first bin of the histogram (5-10 minutes corresponding times in proportion) in the background;
target application is in the first bin of the background dwell time histogram (10-15 minutes corresponding times to a ratio);
target application stays in the first bin of the histogram (number of times in 15-20 minutes) in the background;
target application stays in the first bin of the histogram (number of times in 15-20 minutes) in the background;
target application first bin in background dwell time histogram (25-30 minutes corresponding times to ratio);
target application stays in the first bin of the histogram in background (corresponding number of times after 30 minutes is a ratio);
a target application primary type;
a target application secondary type;
the switching mode of the target application is divided into home key switching, receiver key switching and other application switching;
measuring the off time of the screen;
the current screen is in a bright or dark state;
whether charging is currently performed;
the current amount of power;
a current wifi state;
the time period index of the current time on the day;
the background application is opened for times immediately after the current foreground application, and the times are obtained by statistics on weekdays;
the number of times that the background application is opened following the current foreground application is counted by the working day and the break day;
the average interval time counted every day from the current foreground application entering the background to the target application entering the foreground;
and counting the average screen-off time per day from the current foreground application entering the background to the target application entering the foreground.
The sample set of the application may comprise a plurality of samples collected at a preset frequency during the historical time period. Historical time periods, such as the past 7 days, 10 days; the preset frequency may be, for example, one acquisition every 10 minutes, one acquisition every half hour. It is to be understood that the multi-dimensional feature data of an application acquired at one time constitutes one sample, and a plurality of samples constitutes the sample set.
After the sample set is constructed, each sample in the sample set may be labeled to obtain a sample label of each sample, and since what is to be realized in the present implementation is to predict whether the application can be cleaned, the labeled sample labels include cleanable and uncleanable. Specifically, the application may be marked according to the historical usage habit of the user, for example: when the application enters the background for 30 minutes, the user closes the application, and the application is marked as 'cleanable'; for another example, when the application enters the background for 3 minutes, the user switches the application to the foreground running, and the application is marked as "uncleanable". Specifically, the value "1" may be used to indicate "cleanable", the value "0" may be used to indicate "uncleanable", and vice versa.
For the convenience of classification and training, the feature information that is not directly represented by a numerical value in the applied multidimensional feature information can be quantized by a specific numerical value, for example, for the feature information of the wireless network connection state of the electronic device, a normal state can be represented by a numerical value 1, and an abnormal state can be represented by a numerical value 0 (or vice versa); for another example, the characteristic information of whether the electronic device is in the charging state may be represented by a value 1, and a value 0 to represent the non-charging state (or vice versa).
And 102, extracting characteristic information from the sample set according to a preset rule, and constructing a plurality of training sets.
In an embodiment, a preset number of pieces of feature information can be extracted randomly in a put-back manner from the multi-dimensional feature information of each sample to form corresponding sub-samples, a plurality of sub-samples form a training set, a plurality of training sets are constructed after multiple times of extraction, and the preset number can be set by a user according to actual needs.
In one embodiment, the training set may be divided into two parts, one part is a single sample x, and the target application is marked whether to be used next or not, if so, the target application may be marked as 1, otherwise, the target application is marked as 0, and the form may be (x)i,yi) Wherein y isiE {0, 1 }. The other part is a triplet, i.e. by sampling two samples (x)i,xj) If two sample labels are consistent, it is marked as 1, and if the labels are not consistent, it is marked as-1, and the form is (x)i,xjγ), where γ ∈ {1, -1 }.
Therefore, the step of extracting feature information from the sample set according to the preset rule to construct a plurality of training sets may include:
marking the samples in the sample set to obtain a first label of each sample;
extracting a single sample from the sample set, forming a first training set according to the sample and the corresponding first label, and extracting for multiple times to obtain multiple first training sets;
extracting two samples from the sample set, generating second labels of the two samples according to the first labels respectively corresponding to the two samples, forming a second training set according to the two samples and the corresponding second labels, and extracting for multiple times to obtain a plurality of second training sets;
a plurality of training sets is constructed from the plurality of first training sets and the second training set.
And 103, training the logistic regression model according to the plurality of training sets to obtain a trained prediction model.
A Logistic Regression (LR) model is a classification model in machine learning, and is very widely applied in practice due to the simplicity and high efficiency of an algorithm. Logistic regression is mainly achieved by constructing an important index: the occurrence ratio determines the type of the dependent variable. The method introduces a concept of probability, wherein the occurrence of an event (such as application cleanable) is defined as Y-1, the non-occurrence of the event (such as application unclonable) is defined as Y-0, the probability of the occurrence of the event is p, the probability of the non-occurrence of the event is 1-p, and p is regarded as a linear function of x.
In practical applications, the logistic regression model can be expressed in various forms, for example, in the form of a classifier, and according to the classification capability of the classifier, the classifier can be divided into: weak classifiers and strong classifiers. Therefore, classifiers are generally referred to as time-lapse logistic regression models.
According to the embodiment of the application, the corresponding logistic regression model can be trained by utilizing the training set, and the corresponding trained prediction model is obtained. The neural network in the invention is a shallow neural network, the network structure is only two layers, namely an embedding layer and a full connection layer, the parameters of the embedding layer are obtained by training a single sample and a triple simultaneously, and the embedding layer is classified after passing through the full connection layer, thus the accuracy is greatly improved.
In one embodiment, the step of training the logistic regression model according to the plurality of training sets comprises:
obtaining a first loss function of the logistic regression model according to a plurality of first training sets;
obtaining a second loss function of the logistic regression model according to a plurality of second training sets;
and generating a target loss function according to the first loss function and the second loss function, and estimating model parameters in the logistic regression model according to the target loss function.
Wherein the step of generating the target loss function according to the first loss function and the second loss function comprises:
respectively obtaining weight values of a first loss function and a second loss function;
a weighted sum of the first loss function and the second loss function is calculated to obtain a target loss function.
After the target loss function is obtained, the target loss function may be calculated based on a gradient descent method to obtain model parameters in the logistic regression model.
For example, after building multiple training sets, x is computed for each data in the training setiAn embedded value is calculated, and the process is realized by forming a neural network hidden node by 8 neurons.
For a single sample, classifying the embedded layers through logistic regression, and adopting class cross entropy as a loss function:
Figure BDA0001426836030000091
wherein:
Figure BDA0001426836030000092
i. k is a positive integer and k is a positive integer,
Figure BDA0001426836030000093
to predict the probability distribution, NsFor training the batch size of the classification, C is the number of classes, yiThe weight of the full connection layer is W; by minimizing the loss function, the training results in an embedded layer.
For triple samples (x)i,xjγ), where γ is the label of the sample, if the agreement is 1, the disagreement is-1, by cosine distance:
Figure BDA0001426836030000094
calculating the similarity of two nodes on the embedding layer by minimizing a logistic regression loss function:
Figure BDA0001426836030000095
wherein N isgTo train the batch size of triples, the learned embedded layers are further trained.
The final optimized target loss function is a weighted sum of the two terms, i.e., L ═ Ls+λLuλ is a weight to adjust the relative proportion of the individual sample and triplet loss functions; and obtaining a final embedded layer by a gradient descent method of the self-adaptive learning rate.
The loss function (loss function) is used to measure the degree of inconsistency between the predicted value f (x) and the true value Y of the model, and is a non-negative real value function, usually expressed by L (Y, f (x)) or L (w), and the smaller the loss function is, the better the robustness of the model is. The loss function is a core part of the empirical risk function and is also an important component of the structural risk function.
And step 104, acquiring the current multi-dimensional characteristic information of the application program and using the current multi-dimensional characteristic information as a prediction sample, generating a prediction result according to the prediction sample and the trained prediction model, and managing and controlling the application program according to the prediction result.
For example, the applied multidimensional feature may be collected as a prediction sample based on the prediction time. The predicted time can be set according to requirements, such as the current time. For example, multi-dimensional features of an application may be collected at a predicted time point as a prediction sample.
The prediction result may include cleaning or not, if it is required to determine whether the current background application is cleanable, the current multidimensional feature information of the application program, such as application program use information and current multiple feature information of the electronic device, is acquired and input to the prediction model, and the prediction model calculates according to the model parameters to obtain the prediction result, thereby determining whether the application program is required to be cleaned.
It should be noted that the training process of the prediction model may be performed on the server side or the electronic device side. When the training process and the actual prediction process of the prediction model are finished at the server side and the trained prediction model needs to be used, the characteristic information of the current multiple dimensions of the application program can be input into the server, the prediction result is sent to the electronic equipment side after the actual prediction of the server is finished, and the electronic equipment controls the application program according to the prediction result.
When the training process and the actual prediction process of the prediction model are finished at the electronic equipment end and the trained prediction model needs to be used, the current multi-dimensional feature information of the application program can be input into the electronic equipment, and after the actual prediction of the electronic equipment is finished, the electronic equipment controls the application program according to the prediction result.
As can be seen from the above, the application program control method provided in the embodiment of the present application acquires multi-dimensional feature information of an application program as a sample, constructs a sample set of the application program, extracts feature information from the sample set according to a preset rule, constructs a plurality of training sets, trains a logistic regression model according to the plurality of training sets to obtain a trained prediction model, obtains current multi-dimensional feature information of the application program and uses the current multi-dimensional feature information as a prediction sample, generates a prediction result according to the prediction sample and the trained prediction model, and controls the application program according to the prediction result. According to the application program prediction method and device, the accuracy of prediction of the application program can be improved, and therefore the intelligence and the accuracy of management and control of the application program entering a background are improved.
The cleaning method of the present application will be further described below on the basis of the method described in the above embodiment. Referring to fig. 4, the application management and control method includes:
and 201, collecting multidimensional characteristic information of the application program as a sample, and constructing a sample set of the application program.
The applied multidimensional characteristic information has dimensions with a certain length, and the parameter on each dimension corresponds to one characteristic information for representing the application, namely the multidimensional characteristic information is composed of a plurality of characteristic information. The plurality of feature information may include feature information related to the application itself. In one embodiment, 30 features of a device may be gathered to form a 30-dimensional vector, the 30 features being, for example:
applying the time length from last background switching-in to present;
accumulating the closing time length of the screen during the period from the last background switching-in to the present application;
the last time the application is used in the foreground;
the last time the application is used in the foreground;
the last time the application is used in the foreground;
applying the number of times of entering the foreground in one day (counted by each day);
applying the times of entering the foreground in one day (the rest days are separately counted according to the working days and the rest days);
applying the time of day (counted daily) in the foreground;
applying the time in the foreground in one day (the rest days are counted separately according to the working days and the rest days);
the length of time that the target application is used in the period of 8:00-12:00 per day;
target application is in the first bin of the background dwell time histogram (0-5 minutes corresponding times to a ratio);
target application stays in the first bin of the histogram (5-10 minutes corresponding times in proportion) in the background;
target application is in the first bin of the background dwell time histogram (10-15 minutes corresponding times to a ratio);
target application stays in the first bin of the histogram (number of times in 15-20 minutes) in the background;
target application stays in the first bin of the histogram (number of times in 15-20 minutes) in the background;
target application first bin in background dwell time histogram (25-30 minutes corresponding times to ratio);
target application stays in the first bin of the histogram in background (corresponding number of times after 30 minutes is a ratio);
a target application primary type;
a target application secondary type;
the switching mode of the target application is divided into home key switching, receiver key switching and other application switching;
measuring the off time of the screen;
the current screen is in a bright or dark state;
whether charging is currently performed;
the current amount of power;
a current wifi state;
the time period index of the current time on the day;
the background application is opened for times immediately after the current foreground application, and the times are obtained by statistics on weekdays;
the number of times that the background application is opened following the current foreground application is counted by the working day and the break day;
the average interval time counted every day from the current foreground application entering the background to the target application entering the foreground;
and counting the average screen-off time per day from the current foreground application entering the background to the target application entering the foreground.
202, extracting characteristic information from the sample set according to a preset rule, and constructing a plurality of training sets.
In one embodiment, the training set may be divided into two parts, one part is the monomer sample x, and the target is labeled at this timeThe application is then used or not, and if so may be labeled 1, and if otherwise labeled 0, the form may be (x)i,yi) Wherein y isiE {0, 1 }. The other part is a triplet, i.e. by sampling two samples (x)i,xj) If two sample labels are consistent, it is marked as 1, and if the labels are not consistent, it is marked as-1, and the form is (x)i,xjγ), where γ ∈ {1, -1 }.
And 203, training the logistic regression model according to a plurality of training sets to obtain a trained prediction model.
According to the embodiment of the application, the corresponding logistic regression model can be trained by utilizing the training set, and the corresponding trained prediction model is obtained. The neural network in the invention is a shallow neural network, the network structure is only two layers, namely an embedding layer and a full connection layer, the parameters of the embedding layer are obtained by training a single sample and a triple simultaneously, and the embedding layer is classified after passing through the full connection layer, thus the accuracy is greatly improved.
And 204, acquiring current multi-dimensional characteristic information of the application program and using the information as a prediction sample, and generating a first probability that the application program can be cleaned and a second probability that the application program cannot be cleaned according to the prediction sample and the trained prediction model.
And outputting corresponding prediction probabilities according to the prediction set samples and the corresponding trained logistic regression model to obtain a plurality of prediction probabilities. A logistic regression model outputs a predicted probability that includes a first probability that an application is cleanable and a second probability that the application is not cleanable.
And 205, comparing the first probability that the application program can be cleaned with the second probability that the application program cannot be cleaned to obtain a comparison result.
And 206, outputting a first prediction result which can be cleared by the application program or a second prediction result which cannot be cleared according to the comparison result.
Specifically, when the first probability is larger than the second probability, a cleanable first prediction result is output, and when the first probability is not larger than the second probability, a non-cleanable second prediction result is output.
For example, for a certain prediction probability P, if Y ═ 1 indicates that cleaning is applicable and Y ═ 0 indicates that cleaning is not applicable, assuming that P (Y ═ 1| x) is greater than P (Y ═ 0| x), then a first prediction result predicted to be applicable for cleaning is output; assuming that P (Y ═ 1| x) is not greater than P (Y ═ 0| x), at this time, a second prediction result that the prediction application cannot clean up is output.
And 207, determining whether the application program can be cleaned according to the number of the first prediction results and the number of the second prediction results.
Determining that the application is cleanable when the number of first predictors is greater than the number of second predictors;
determining that the application is uncleanable when the number of first predictors is not greater than the number of second predictors.
In a specific example, a pre-trained logistic regression model can be used to predict whether multiple applications running in the background can be cleaned, as shown in table 1, and then it is determined that the applications a1 and A3 running in the background can be cleaned, while the state of the application a2 running in the background is kept unchanged.
Applications of Predicted results
Application A1 Can be cleaned
Application A2 Can not be cleaned
Application A3 Can be cleaned
TABLE 1
As can be seen from the above, the application program control method provided in the embodiment of the present application acquires multi-dimensional feature information of an application program as a sample, constructs a sample set of the application program, extracts feature information from the sample set according to a preset rule, constructs a plurality of training sets, trains a logistic regression model according to the plurality of training sets to obtain a trained prediction model, obtains current multi-dimensional feature information of the application program and uses the current multi-dimensional feature information as a prediction sample, generates a prediction result according to the prediction sample and the trained prediction model, and controls the application program according to the prediction result. According to the application program prediction method and device, the accuracy of prediction of the application program can be improved, and therefore the intelligence and the accuracy of management and control of the application program entering a background are improved.
Referring to fig. 5, fig. 5 is a schematic view illustrating another application scenario of the application management and control apparatus according to the embodiment of the present application. When the training process of the prediction model is completed at the server side, the actual prediction process of the prediction model is completed at the electronic equipment side, and the optimized prediction model needs to be used, the current multidimensional feature information of the application program can be input into the electronic equipment, and after the actual prediction of the electronic equipment is completed, the electronic equipment controls the application program according to the prediction result. Optionally, the trained prediction model file (model file) may be transplanted to the intelligent device, if it is necessary to determine whether the current background application can be cleaned, the current sample set is updated, the current sample set is input to the trained prediction model file (model file), and the prediction value is obtained through calculation.
In some embodiments, before the step of obtaining the current multidimensional feature information of the application program, the method may further include:
and detecting whether the application program enters a background, and if so, acquiring the current multi-dimensional characteristic information of the application program. And then inputting a prediction model to generate a prediction result, and managing and controlling the application program according to the prediction result.
In some embodiments, before the step of obtaining the current multidimensional feature information of the application program, the method may further include:
and acquiring preset time, and acquiring the current multi-dimensional characteristic information of the application program if the current system time reaches the preset time. The preset time may be a time of day, such as 9 am, or several time of day, such as 9 am, 6 pm, etc. But may also be one or several time points in a plurality of days. And then inputting a prediction model to generate a prediction result, and managing and controlling the application program according to the prediction result.
All the above technical solutions can be combined arbitrarily to form the optional embodiments of the present application, and are not described herein again.
Referring to fig. 6, fig. 6 is a schematic structural diagram of an application management and control apparatus according to an embodiment of the present disclosure. The application management and control apparatus 300 is applied to an electronic device, and the application management and control apparatus 300 includes an acquisition module 301, a construction module 302, a training module 303, and a management and control module 304.
The acquisition module 301 is configured to acquire multidimensional feature information of an application program as a sample, and construct a sample set of the application program.
The predetermined application may be any application installed in the electronic device, such as a communication application, a multimedia application, a game application, an information application, or a shopping application.
The applied multidimensional characteristic information has dimensions with a certain length, and the parameter on each dimension corresponds to one characteristic information for representing the application, namely the multidimensional characteristic information is composed of a plurality of characteristic information. The plurality of feature information may include feature information related to the application itself. In one embodiment, 30 features of a device may be gathered to form a 30-dimensional vector, the 30 features being, for example:
applying the time length from last background switching-in to present;
accumulating the closing time length of the screen during the period from the last background switching-in to the present application;
the last time the application is used in the foreground;
the last time the application is used in the foreground;
the last time the application is used in the foreground;
applying the number of times of entering the foreground in one day (counted by each day);
applying the times of entering the foreground in one day (the rest days are separately counted according to the working days and the rest days);
applying the time of day (counted daily) in the foreground;
applying the time in the foreground in one day (the rest days are counted separately according to the working days and the rest days);
the length of time that the target application is used in the period of 8:00-12:00 per day;
target application is in the first bin of the background dwell time histogram (0-5 minutes corresponding times to a ratio);
target application stays in the first bin of the histogram (5-10 minutes corresponding times in proportion) in the background;
target application is in the first bin of the background dwell time histogram (10-15 minutes corresponding times to a ratio);
target application stays in the first bin of the histogram (number of times in 15-20 minutes) in the background;
target application stays in the first bin of the histogram (number of times in 15-20 minutes) in the background;
target application first bin in background dwell time histogram (25-30 minutes corresponding times to ratio);
target application stays in the first bin of the histogram in background (corresponding number of times after 30 minutes is a ratio);
a target application primary type;
a target application secondary type;
the switching mode of the target application is divided into home key switching, receiver key switching and other application switching;
measuring the off time of the screen;
the current screen is in a bright or dark state;
whether charging is currently performed;
the current amount of power;
a current wifi state;
the time period index of the current time on the day;
the background application is opened for times immediately after the current foreground application, and the times are obtained by statistics on weekdays;
the number of times that the background application is opened following the current foreground application is counted by the working day and the break day;
the average interval time counted every day from the current foreground application entering the background to the target application entering the foreground;
and counting the average screen-off time per day from the current foreground application entering the background to the target application entering the foreground.
The building module 302 is configured to extract feature information from the sample set according to a preset rule, and build a plurality of training sets.
In an embodiment, a preset number of pieces of feature information can be extracted randomly in a put-back manner from the multi-dimensional feature information of each sample to form corresponding sub-samples, a plurality of sub-samples form a training set, a plurality of training sets are constructed after multiple times of extraction, and the preset number can be set by a user according to actual needs.
In one embodiment, the training set may be divided into two parts, one part is a single sample x, and the target application is marked whether to be used next or not, if so, the target application may be marked as 1, otherwise, the target application is marked as 0, and the form may be (x)i,yi) Wherein y isiE {0, 1 }. The other part is a triplet, i.e. by sampling two samples (x)i,xj) If two sample labels are consistent, it is marked as 1, and if the labels are not consistent, it is marked as-1, and the form is (x)i,xjγ), where γ ∈ {1, -1 }.
The training module 303 is configured to train the logistic regression model according to a plurality of training sets to obtain a trained prediction model.
A Logistic Regression (LR) model is a classification model in machine learning, and is very widely applied in practice due to the simplicity and high efficiency of an algorithm. Logistic regression is mainly achieved by constructing an important index: the occurrence ratio determines the type of the dependent variable. The method introduces a concept of probability, wherein the occurrence of an event (such as application cleanable) is defined as Y-1, the non-occurrence of the event (such as application unclonable) is defined as Y-0, the probability of the occurrence of the event is p, the probability of the non-occurrence of the event is 1-p, and p is regarded as a linear function of x.
In practical applications, the logistic regression model can be expressed in various forms, for example, in the form of a classifier, and according to the classification capability of the classifier, the classifier can be divided into: weak classifiers and strong classifiers. Therefore, classifiers are generally referred to as time-lapse logistic regression models.
According to the embodiment of the application, the corresponding logistic regression model can be trained by utilizing the training set, and the corresponding trained prediction model is obtained. The neural network in the invention is a shallow neural network, the network structure is only two layers, namely an embedding layer and a full connection layer, the parameters of the embedding layer are obtained by training a single sample and a triple simultaneously, and the embedding layer is classified after passing through the full connection layer, thus the accuracy is greatly improved.
In an embodiment, after building multiple training sets, x is computed for each data in the training setiAn embedded value is calculated, and the process is realized by forming a neural network hidden node by 8 neurons.
For a single sample, classifying the embedded layers through logistic regression, and adopting class cross entropy as a loss function:
Figure BDA0001426836030000161
wherein:
Figure BDA0001426836030000162
Nsfor training the batch size of the classification, C is the number of classes, yiThe weight of the full connection layer is W; by minimizing the loss function, the training results in an embedded layer.
For triple samples (x)i,xjγ), where γ is the label of the sample, if the agreement is 1, the disagreement is-1, by cosine distance:
Figure BDA0001426836030000163
calculating the similarity of two nodes on the embedding layer by minimizing a logistic regression loss function:
Figure BDA0001426836030000171
wherein N isgTo train the batch size of triples, the learned embedded layers are further trained.
The final optimized target loss function is a weighted sum of the two terms, i.e., L ═ Ls+λLuλ is a weight to adjust the relative proportion of the individual sample and triplet loss functions; and obtaining a final embedded layer by a gradient descent method of the self-adaptive learning rate.
And the control module 304 is configured to obtain current multidimensional feature information of the application program and use the current multidimensional feature information as a prediction sample, generate a prediction result according to the prediction sample and the trained prediction model, and control the application program according to the prediction result.
For example, the applied multidimensional feature may be collected as a prediction sample based on the prediction time. The predicted time can be set according to requirements, such as the current time. For example, multi-dimensional features of an application may be collected at a predicted time point as a prediction sample.
The prediction result may include cleaning or not, if it is required to determine whether the current background application is cleanable, the current multidimensional feature information of the application program, such as application program use information and current multiple feature information of the electronic device, is acquired and input to the prediction model, and the prediction model calculates according to the model parameters to obtain the prediction result, thereby determining whether the application program is required to be cleaned.
It should be noted that the training process of the prediction model may be performed on the server side or the electronic device side. When the training process and the actual prediction process of the prediction model are finished at the server side and the trained prediction model needs to be used, the characteristic information of the current multiple dimensions of the application program can be input into the server, the prediction result is sent to the electronic equipment side after the actual prediction of the server is finished, and the electronic equipment controls the application program according to the prediction result.
When the training process and the actual prediction process of the prediction model are finished at the electronic equipment end and the trained prediction model needs to be used, the current multi-dimensional feature information of the application program can be input into the electronic equipment, and after the actual prediction of the electronic equipment is finished, the electronic equipment controls the application program according to the prediction result.
Referring to fig. 7, the building module 302 may specifically include:
a marking submodule 3021, configured to mark samples in the sample set to obtain a first label of each sample;
the first extraction submodule 3022 is configured to extract a single sample from the sample set, form a first training set according to the sample and the corresponding first label, and extract the samples multiple times to obtain multiple first training sets;
the second extraction submodule 3023 is configured to extract two samples from the sample set, generate second labels of the two samples according to the first labels respectively corresponding to the two samples, form a second training set according to the two samples and the corresponding second labels, and perform multiple extractions to obtain multiple second training sets;
a construction submodule 3024 is configured to construct a plurality of training sets from the plurality of first training sets and the second training set.
With continued reference to fig. 8, the training module 303 specifically includes:
a first function obtaining submodule 3031, configured to obtain a first loss function of the logistic regression model according to the plurality of first training sets;
a second function obtaining submodule 3032, configured to obtain a second loss function of the logistic regression model according to the plurality of second training sets;
and a parameter estimation submodule 3033, configured to generate a target loss function according to the first loss function and the second loss function, and estimate a model parameter in the logistic regression model according to the target loss function.
In an embodiment, the parameter estimation submodule 3033 is specifically configured to obtain weight values of the first loss function and the second loss function respectively, and calculate a weighted sum of the first loss function and the second loss function to obtain the target loss function.
The parameter estimation submodule 3033 is further specifically configured to calculate the target loss function based on a gradient descent method, so as to obtain a model parameter in the logistic regression model.
In one embodiment, the predicted outcome includes: a first probability that the application can be cleaned and a second probability that the application cannot be cleaned, and the management and control module 304 includes:
the output submodule is used for comparing the first probability that the application program can be cleaned with the second probability that the application program cannot be cleaned to obtain a comparison result, and outputting a first prediction result that the application program can be cleaned or a second prediction result that the application program cannot be cleaned according to the comparison result;
and the determining submodule is used for determining whether the application program can be cleaned according to the number of the first prediction results and the number of the second prediction results.
The output submodule is specifically configured to output a first prediction result that can be cleared when the first probability is greater than the second probability;
outputting a second prediction that is not cleanable when the first probability is not greater than the second probability.
All the above technical solutions can be combined arbitrarily to form the optional embodiments of the present application, and are not described herein again.
As can be seen from the above, in the application program control device according to the embodiment of the application program, the multidimensional feature information of the application program is collected as a sample, a sample set of the application program is constructed, the feature information is extracted from the sample set according to a preset rule, a plurality of training sets are constructed, the logistic regression model is trained according to the plurality of training sets to obtain a trained prediction model, the current multidimensional feature information of the application program is obtained and used as a prediction sample, a prediction result is generated according to the prediction sample and the trained prediction model, and the application program is controlled according to the prediction result. According to the application program prediction method and device, the accuracy of prediction of the application program can be improved, and therefore the intelligence and the accuracy of management and control of the application program entering a background are improved.
In the embodiment of the present application, the application management and control apparatus and the application management and control method in the foregoing embodiments belong to the same concept, and any method provided in the embodiment of the application management and control method may be run on the application management and control apparatus, and a specific implementation process thereof is described in detail in the embodiment of the application management and control method, and is not described herein again.
The embodiment of the application also provides the electronic equipment. Referring to fig. 9, an 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, connects various parts of the entire electronic device using various interfaces and lines, performs various functions of the electronic device 400 by running or loading a computer program stored in the memory 402 and calling data stored in the memory 402, and processes the data, thereby monitoring the electronic device 400 as a whole.
The memory 402 may be used to store software programs and modules, and the processor 401 executes various functional applications and data processing by operating the computer programs and modules stored in the memory 402. The memory 402 may mainly include a program storage area and a data storage area, wherein the program storage area may store an operating system, a computer program required by at least one function (such as a sound playing function, an image playing function, etc.), and the like; the storage data area may store data created according to use of the electronic device, and the like. Further, the memory 402 may include high speed random access memory, and may 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, the memory 402 may also include a memory controller to provide the processor 401 access to the memory 402.
In this embodiment, the processor 401 in the electronic device 400 loads instructions corresponding to one or more processes of the computer program into the memory 402 according to the following steps, and the processor 401 runs the computer program stored in the memory 402, so as to implement various functions, as follows:
the method comprises the steps of collecting multi-dimensional feature information of an application program as a sample, constructing a sample set of the application program, extracting feature information from the sample set according to preset rules, constructing a plurality of training sets, training a logistic regression model according to the training sets to obtain a trained prediction model, obtaining the current multi-dimensional feature information of the application program and using the current multi-dimensional feature information as a prediction sample, generating a prediction result according to the prediction sample and the trained prediction model, and managing and controlling the application program according to the prediction result. According to the application program prediction method and device, the accuracy of prediction of the application program can be improved, and therefore the intelligence and the accuracy of management and control of the application program entering a background are improved.
Referring also to fig. 10, in some embodiments, the electronic device 400 may further include: a display 403, radio frequency circuitry 404, audio circuitry 405, and a power supply 406. The display 403, the rf circuit 404, the audio circuit 405, and the power source 406 are electrically connected to the processor 401.
The display 403 may be used to display information entered by or provided to the user as well as various graphical user interfaces, which may be made up of graphics, text, icons, video, and any combination thereof. The Display 403 may include a Display panel, and in some embodiments, the Display panel may be configured in the form of a Liquid Crystal Display (LCD), an Organic Light-Emitting Diode (OLED), or the like.
The rf circuit 404 may be used for transceiving rf signals to establish wireless communication with a network device or other electronic devices through wireless communication, and for transceiving signals with the network device or other electronic devices.
The audio circuit 405 may be used to provide an audio interface between the user and the electronic device through a speaker, microphone.
The power supply 406 may be used to power various components of the electronic device 400. In some embodiments, power supply 406 may be logically coupled to processor 401 via a power management system, such that functions to manage charging, discharging, and power consumption management are performed via the power management system.
Although not shown in fig. 10, the electronic device 400 may further include a camera, a bluetooth module, and the like, which are not described in detail herein.
The embodiment of the present application further provides a storage medium, where a computer program is stored, and when the computer program runs on a computer, the computer is enabled to execute the application program management and control method in any of the above embodiments.
In the embodiment of the present application, the storage medium may be a magnetic disk, an optical disk, a Read Only Memory (ROM), a Random Access Memory (RAM), or the like.
In the foregoing embodiments, the descriptions of the respective embodiments have respective emphasis, and for parts that are not described in detail in a certain embodiment, reference may be made to related descriptions of other embodiments.
It should be noted that, for the application management and control method in the embodiment of the present application, it can be understood by a person skilled in the art that all or part of the process for implementing the application management and control method in the embodiment of the present application can be completed by controlling the relevant hardware through a computer program, where the computer program can be stored in a computer-readable storage medium, such as a memory of an electronic device, and executed by at least one processor in the electronic device, and the process of executing the application management and control method can include the process of the embodiment of the application management and control method. The storage medium may be a magnetic disk, an optical disk, a read-only memory, a random access memory, etc.
For the application management and control device in the embodiment of the present application, each functional module may be integrated in one processing chip, or each module may exist alone physically, or two or more modules are integrated in one module. The integrated module can be realized in a hardware mode, and can also be realized in a software functional module mode. The integrated module, if implemented in the form of a software functional module and sold or used as a stand-alone product, may also be stored in a computer readable storage medium, such as a read-only memory, a magnetic or optical disk, or the like.
The application management and control method, the application management and control device, the storage medium and the electronic device provided by the embodiment of the application are introduced in detail, a specific example is applied in the description to explain the principle and the implementation of the application, and the description of the embodiment is only used to help understanding the method and the core idea of the application; meanwhile, for those skilled in the art, according to the idea of the present application, there may be variations in the specific embodiments and the application scope, and in summary, the content of the present specification should not be construed as a limitation to the present application.

Claims (15)

1. An application management and control method is characterized by comprising the following steps:
collecting multidimensional characteristic information of an application program as a sample, and constructing a sample set of the application program;
marking the samples in the sample set to obtain a first label of each sample, wherein the first label comprises cleanable and uncleanable samples;
extracting a single sample from the sample set, forming a first training set according to the sample and the corresponding first label, and extracting for multiple times to obtain multiple first training sets;
extracting two samples from the sample set, generating second labels of the two samples according to the first labels respectively corresponding to the two samples, wherein the second labels comprise consistency and inconsistency of the first labels respectively corresponding to the two samples, forming a second training set according to the two samples and the corresponding second labels, and extracting for multiple times to obtain a plurality of second training sets;
constructing a plurality of training sets from the plurality of first training sets and the second training set;
training a logistic regression model according to the training sets to obtain a trained prediction model;
acquiring current multi-dimensional feature information of the application program and using the current multi-dimensional feature information as a prediction sample, generating a prediction result according to the prediction sample and the trained prediction model, and managing and controlling the application program according to the prediction result.
2. The method according to claim 1, wherein the step of training a logistic regression model according to the training sets comprises:
obtaining a first loss function of the logistic regression model according to the plurality of first training sets;
obtaining a second loss function of the logistic regression model according to the plurality of second training sets;
and generating a target loss function according to the first loss function and the second loss function, and estimating model parameters in the logistic regression model according to the target loss function.
3. The method according to claim 2, wherein the first loss function of the logistic regression model is obtained according to a preset formula and the plurality of first training sets, wherein the preset formula is:
Figure FDA0002365045370000021
wherein:
LSfor the first loss function of the logistic regression model, i and k are both positive integers,
Figure FDA0002365045370000022
to predict the probability distribution, NgFor training the batch size of the classification, C is the number of classes, yiAre unique codes that characterize a sample class.
4. The method for managing and controlling the application program according to claim 2, wherein the step of generating the target loss function according to the first loss function and the second loss function includes:
respectively acquiring weighted values of the first loss function and the second loss function;
and calculating the weighted sum of the first loss function and the second loss function to obtain the target loss function.
5. The method for managing and controlling applications according to claim 2, wherein the step of estimating model parameters in the logistic regression model according to the objective loss function comprises:
and calculating the target loss function based on a gradient descent method to obtain model parameters in the logistic regression model.
6. The application management and control method according to claim 1, wherein the prediction result includes: a first probability that the application is cleanable, and a second probability that the application is not cleanable;
the step of managing and controlling the application program according to the prediction result comprises the following steps:
comparing the first probability that the application program can be cleaned with the second probability that the application program cannot be cleaned to obtain a comparison result;
outputting a first prediction result which can be cleaned by the application program or a second prediction result which cannot be cleaned according to the comparison result;
and determining whether the application program can be cleaned according to the number of the first prediction results and the number of the second prediction results.
7. The method for managing and controlling the application program according to claim 6, wherein the step of outputting a first prediction result that the application program can be cleaned or a second prediction result that the application program cannot be cleaned according to the comparison result includes:
outputting a cleanable first prediction result when the first probability is greater than the second probability;
outputting a second prediction that is not cleanable when the first probability is not greater than the second probability.
8. An application management and control apparatus, comprising:
the acquisition module is used for acquiring multi-dimensional characteristic information of an application program as a sample and constructing a sample set of the application program;
the construction module is used for extracting characteristic information from the sample set according to a preset rule and constructing a plurality of training sets;
the building module specifically comprises:
the marking sub-module is used for marking the samples in the sample set to obtain a first label of each sample, and the first label comprises a cleanable label and a non-cleanable label;
the first extraction submodule is used for extracting a single sample from the sample set, forming a first training set according to the sample and the corresponding first label, and extracting for multiple times to obtain multiple first training sets;
the second extraction submodule is used for extracting two samples from the sample set, generating second labels of the two samples according to the first labels respectively corresponding to the two samples, forming a second training set according to the two samples and the corresponding second labels, and extracting for multiple times to obtain a plurality of second training sets, wherein the second labels comprise consistency and inconsistency of the first labels respectively corresponding to the two samples;
a construction sub-module for constructing a plurality of training sets from the plurality of first training sets and the second training set;
the training module is used for training the logistic regression model according to the plurality of training sets to obtain a trained prediction model;
and the control module is used for acquiring the current multi-dimensional characteristic information of the application program and taking the information as a prediction sample, generating a prediction result according to the prediction sample and the trained prediction model, and controlling the application program according to the prediction result.
9. The application management and control device according to claim 8, wherein the training module specifically includes:
a first function obtaining submodule, configured to obtain a first loss function of the logistic regression model according to the plurality of first training sets;
a second function obtaining submodule, configured to obtain a second loss function of the logistic regression model according to the plurality of second training sets;
and the parameter estimation submodule is used for generating a target loss function according to the first loss function and the second loss function and estimating the model parameters in the logistic regression model according to the target loss function.
10. The application management and control apparatus according to claim 9,
the parameter estimation submodule is specifically configured to obtain weight values of the first loss function and the second loss function, and calculate a weighted sum of the first loss function and the second loss function to obtain the target loss function.
11. The application management and control apparatus according to claim 9,
the parameter estimation submodule is further specifically configured to calculate the target loss function based on a gradient descent method to obtain a model parameter in the logistic regression model.
12. The application management and control apparatus according to claim 8, wherein the prediction result includes: the management and control module comprises a first probability that the application program can be cleaned and a second probability that the application program cannot be cleaned:
the output submodule is used for comparing the first probability that the application program can be cleaned with the second probability that the application program cannot be cleaned to obtain a comparison result, and outputting a first prediction result that the application program can be cleaned or a second prediction result that the application program cannot be cleaned according to the comparison result;
and the determining submodule is used for determining whether the application program can be cleaned according to the number of the first prediction results and the number of the second prediction results.
13. The application management and control apparatus according to claim 12,
the output submodule is specifically configured to output a first prediction result that can be cleared when the first probability is greater than the second probability;
outputting a second prediction that is not cleanable when the first probability is not greater than the second probability.
14. A storage medium on which a computer program is stored, characterized by causing a computer to execute an application program management method according to any one of claims 1 to 7 when the computer program runs on the computer.
15. An electronic device comprising a processor and a memory, the memory having a computer program, wherein the processor is configured to execute the application management method according to any one of claims 1 to 7 by calling the computer program.
CN201710940355.2A 2017-09-30 2017-09-30 Application program control method and device, storage medium and electronic equipment Active CN107678845B (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
CN201710940355.2A CN107678845B (en) 2017-09-30 2017-09-30 Application program control method and device, storage medium and electronic equipment
PCT/CN2018/102254 WO2019062414A1 (en) 2017-09-30 2018-08-24 Method and apparatus for managing and controlling application program, storage medium, and electronic device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201710940355.2A CN107678845B (en) 2017-09-30 2017-09-30 Application program control method and device, storage medium and electronic equipment

Publications (2)

Publication Number Publication Date
CN107678845A CN107678845A (en) 2018-02-09
CN107678845B true CN107678845B (en) 2020-03-10

Family

ID=61140234

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201710940355.2A Active CN107678845B (en) 2017-09-30 2017-09-30 Application program control method and device, storage medium and electronic equipment

Country Status (2)

Country Link
CN (1) CN107678845B (en)
WO (1) WO2019062414A1 (en)

Families Citing this family (18)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107678845B (en) * 2017-09-30 2020-03-10 Oppo广东移动通信有限公司 Application program control method and device, storage medium and electronic equipment
CN108337358B (en) * 2017-09-30 2020-01-14 Oppo广东移动通信有限公司 Application cleaning method and device, storage medium and electronic equipment
CN110163460B (en) * 2018-03-30 2023-09-19 腾讯科技(深圳)有限公司 Method and equipment for determining application score
CN111797880A (en) * 2019-04-09 2020-10-20 Oppo广东移动通信有限公司 Data processing method, data processing device, storage medium and electronic equipment
CN111797861A (en) * 2019-04-09 2020-10-20 Oppo广东移动通信有限公司 Information processing method, information processing apparatus, storage medium, and electronic device
CN110232403B (en) * 2019-05-15 2024-02-27 腾讯科技(深圳)有限公司 Label prediction method and device, electronic equipment and medium
CN110442516B (en) * 2019-07-12 2024-02-09 未鲲(上海)科技服务有限公司 Information processing method, apparatus, and computer-readable storage medium
CN112396445A (en) * 2019-08-16 2021-02-23 京东数字科技控股有限公司 Method and device for identifying user identity information
CN112770002B (en) * 2019-10-17 2022-04-19 荣耀终端有限公司 Heartbeat control method and electronic equipment
CN111124632B (en) * 2019-12-06 2024-02-13 西安易朴通讯技术有限公司 Optimization method and device of mobile terminal, terminal equipment and storage medium
CN111144473A (en) * 2019-12-23 2020-05-12 中国医学科学院肿瘤医院 Training set construction method and device, electronic equipment and computer readable storage medium
CN113325998B (en) * 2020-02-29 2022-09-06 杭州海康存储科技有限公司 Read-write speed control method and device
CN111460150B (en) * 2020-03-27 2023-11-10 北京小米松果电子有限公司 Classification model training method, classification method, device and storage medium
CN111949530B (en) * 2020-08-07 2024-02-20 北京灵汐科技有限公司 Test result prediction method and device, computer equipment and storage medium
CN112130991A (en) * 2020-08-28 2020-12-25 北京思特奇信息技术股份有限公司 Application program control method and system based on machine learning
CN112506556B (en) * 2020-11-19 2023-08-25 杭州云深科技有限公司 Application program classification method, device, computer equipment and storage medium
CN113342335A (en) * 2021-05-11 2021-09-03 北京大学 Fast application page selection method, device, equipment and storage medium
CN113239799A (en) * 2021-05-12 2021-08-10 北京沃东天骏信息技术有限公司 Training method, recognition method, device, electronic equipment and readable storage medium

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104102917A (en) * 2014-07-03 2014-10-15 中国石油大学(北京) Construction method of domain self-adaptive classifier, construction device for domain self-adaptive classifier, data classification method and data classification device
CN106096538A (en) * 2016-06-08 2016-11-09 中国科学院自动化研究所 Face identification method based on sequencing neural network model and device
CN106093612A (en) * 2016-05-26 2016-11-09 国网江苏省电力公司电力科学研究院 A kind of method for diagnosing fault of power transformer
CN106993083A (en) * 2017-02-21 2017-07-28 北京奇虎科技有限公司 A kind of method and apparatus of recommendation intelligent terminal operation prompt information
CN107133094A (en) * 2017-06-05 2017-09-05 努比亚技术有限公司 Application management method, mobile terminal and computer-readable recording medium

Family Cites Families (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104298549B (en) * 2014-09-30 2018-03-30 北京金山安全软件有限公司 Method and device for cleaning application programs in mobile terminal and mobile terminal
CN104991803B (en) * 2015-07-10 2018-04-06 上海斐讯数据通信技术有限公司 To the managing and control system and method for the self-starting under given conditions of android application programs
CN107133436A (en) * 2016-02-26 2017-09-05 阿里巴巴集团控股有限公司 A kind of multiple sample model training method and device
CN107678845B (en) * 2017-09-30 2020-03-10 Oppo广东移动通信有限公司 Application program control method and device, storage medium and electronic equipment
CN107704364B (en) * 2017-09-30 2019-08-06 Oppo广东移动通信有限公司 Background application management-control method, device, storage medium and electronic equipment
CN107678799B (en) * 2017-09-30 2019-10-25 Oppo广东移动通信有限公司 Application program management-control method, device, storage medium and electronic equipment
CN107643948B (en) * 2017-09-30 2020-06-02 Oppo广东移动通信有限公司 Application program control method, device, medium and electronic equipment

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104102917A (en) * 2014-07-03 2014-10-15 中国石油大学(北京) Construction method of domain self-adaptive classifier, construction device for domain self-adaptive classifier, data classification method and data classification device
CN106093612A (en) * 2016-05-26 2016-11-09 国网江苏省电力公司电力科学研究院 A kind of method for diagnosing fault of power transformer
CN106096538A (en) * 2016-06-08 2016-11-09 中国科学院自动化研究所 Face identification method based on sequencing neural network model and device
CN106993083A (en) * 2017-02-21 2017-07-28 北京奇虎科技有限公司 A kind of method and apparatus of recommendation intelligent terminal operation prompt information
CN107133094A (en) * 2017-06-05 2017-09-05 努比亚技术有限公司 Application management method, mobile terminal and computer-readable recording medium

Also Published As

Publication number Publication date
WO2019062414A1 (en) 2019-04-04
CN107678845A (en) 2018-02-09

Similar Documents

Publication Publication Date Title
CN107678845B (en) Application program control method and device, storage medium and electronic equipment
CN108337358B (en) Application cleaning method and device, storage medium and electronic equipment
US10673707B2 (en) Systems and methods for managing lifecycle and reducing power consumption by learning an IoT device
CN108280458B (en) Group relation type identification method and device
CN107678803B (en) Application control method and device, storage medium and electronic equipment
CN111813532B (en) Image management method and device based on multitask machine learning model
CN107704070B (en) Application cleaning method and device, storage medium and electronic equipment
CN107832132B (en) Application control method and device, storage medium and electronic equipment
CN107632697B (en) Processing method, device, storage medium and the electronic equipment of application program
CN107943583B (en) Application processing method and device, storage medium and electronic equipment
CN107729081B (en) Application management method and device, storage medium and electronic equipment
CN107870810B (en) Application cleaning method and device, storage medium and electronic equipment
CN107943582B (en) Feature processing method, feature processing device, storage medium and electronic equipment
CN107894827B (en) Application cleaning method and device, storage medium and electronic equipment
Sone et al. Wireless traffic usage forecasting using real enterprise network data: Analysis and methods
CN111797861A (en) Information processing method, information processing apparatus, storage medium, and electronic device
US20160282821A1 (en) Management of complex physical systems using time series segmentation to determine behavior switching
CN115545103A (en) Abnormal data identification method, label identification method and abnormal data identification device
CN107728772B (en) Application processing method and device, storage medium and electronic equipment
CN107832848B (en) Application management method, device, storage medium and electronic equipment
CN107741867B (en) Application program management method and device, storage medium and electronic equipment
CN107861769B (en) Application cleaning method and device, storage medium and electronic equipment
CN107943535B (en) Application cleaning method and device, storage medium and electronic equipment
CN107870811B (en) Application cleaning method and device, storage medium and electronic equipment
CN108681480B (en) Background application program control method and device, storage medium and electronic equipment

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
CB02 Change of applicant information

Address after: 523860 No. 18, Wu Sha Beach Road, Changan Town, Dongguan, Guangdong

Applicant after: OPPO Guangdong Mobile Communications Co., Ltd.

Address before: 523860 No. 18, Wu Sha Beach Road, Changan Town, Dongguan, Guangdong

Applicant before: Guangdong OPPO Mobile Communications Co., Ltd.

CB02 Change of applicant information
GR01 Patent grant
GR01 Patent grant