CN108427618B - Method and device for determining stuck state and computer readable storage medium - Google Patents

Method and device for determining stuck state and computer readable storage medium Download PDF

Info

Publication number
CN108427618B
CN108427618B CN201810193822.4A CN201810193822A CN108427618B CN 108427618 B CN108427618 B CN 108427618B CN 201810193822 A CN201810193822 A CN 201810193822A CN 108427618 B CN108427618 B CN 108427618B
Authority
CN
China
Prior art keywords
terminal
resource
use information
resource use
stuck state
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
CN201810193822.4A
Other languages
Chinese (zh)
Other versions
CN108427618A (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.)
Beijing Xiaomi Mobile Software Co Ltd
Original Assignee
Beijing Xiaomi Mobile Software Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Beijing Xiaomi Mobile Software Co Ltd filed Critical Beijing Xiaomi Mobile Software Co Ltd
Priority to CN201810193822.4A priority Critical patent/CN108427618B/en
Publication of CN108427618A publication Critical patent/CN108427618A/en
Application granted granted Critical
Publication of CN108427618B publication Critical patent/CN108427618B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/30Monitoring
    • G06F11/32Monitoring with visual or acoustical indication of the functioning of the machine
    • G06F11/324Display of status information
    • G06F11/328Computer systems status display
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/30Monitoring
    • G06F11/3055Monitoring arrangements for monitoring the status of the computing system or of the computing system component, e.g. monitoring if the computing system is on, off, available, not available
    • 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

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Data Mining & Analysis (AREA)
  • Quality & Reliability (AREA)
  • Computing Systems (AREA)
  • Artificial Intelligence (AREA)
  • Evolutionary Computation (AREA)
  • Evolutionary Biology (AREA)
  • Bioinformatics & Computational Biology (AREA)
  • Bioinformatics & Cheminformatics (AREA)
  • Life Sciences & Earth Sciences (AREA)
  • Computer Hardware Design (AREA)
  • Telephone Function (AREA)
  • Information Transfer Between Computers (AREA)

Abstract

The disclosure relates to a stuck state determination method, a stuck state determination device and a computer readable storage medium, and relates to the technical field of terminals. The method comprises the following steps: acquiring resource use information of a terminal within a preset time before the current time; and determining the current blocking state of the terminal according to the resource use information. The method and the device can accurately predict the current blocking state of the terminal by monitoring the resource use condition of the terminal before the current time in real time.

Description

Method and device for determining stuck state and computer readable storage medium
Technical Field
The present disclosure relates to the field of terminal technologies, and in particular, to a method and an apparatus for determining a stuck state, and a computer-readable storage medium.
Background
With the rapid development of terminal technology, the terminal such as a mobile phone and a tablet computer has increasingly powerful functions, and becomes an indispensable tool in work and life of people gradually. As the usage time of the terminal increases and the number of applications installed increases, the operating speed of the terminal may become slower, so that the terminal is often stuck during the usage. When the terminal is stuck, a user needs to manually end part or all of the running processes of the terminal to improve the stuck state, the operation is troublesome, and the normal use of the user is affected, so that a stuck state determination method is urgently needed to determine the stuck state of the terminal in advance.
Disclosure of Invention
To overcome the problems in the related art, the present disclosure provides a stuck state determination method, apparatus, and computer-readable storage medium.
According to a first aspect of the embodiments of the present disclosure, there is provided a stuck state determination method, including:
acquiring resource use information of a terminal within a preset time before the current time;
and determining the current blocking state of the terminal according to the resource use information.
Optionally, the determining, according to the resource usage information, a current stuck state of the terminal includes:
determining the stuck state corresponding to the resource use information through a specified classifier, and determining the stuck state corresponding to the resource use information as the current stuck state of the terminal; or,
and acquiring the stuck state corresponding to the resource use information from the corresponding relation between the stored resource use information and the stuck state, and determining the stuck state corresponding to the resource use information as the current stuck state of the terminal.
Optionally, before determining the stuck state corresponding to the resource usage information by the specified classifier, the method further includes:
when the terminal is blocked, acquiring resource use information of the terminal within the preset time before the terminal is blocked, and forming the acquired resource use information into a first resource use information set;
when the terminal is not blocked, acquiring resource use information of the terminal within the preset time before the terminal is not blocked, and forming a second resource use information set by the acquired resource use information;
and training a classification model to be trained by using the first resource usage information set and the second resource usage information set to obtain the specified classifier.
Optionally, after determining the current stuck state of the terminal according to the resource usage information, the method further includes:
when the current blocking state of the terminal is blocking, displaying preset blocking prompt information; or,
and when the current blocking state of the terminal is blocking, adjusting the resource state of the terminal.
Optionally, the resource usage information includes at least one of a CPU usage rate of the central processing unit, a CPU frequency, a memory usage rate, a number of memory fragments, a total number of bytes of the memory fragments, a number of running processes, and a temperature.
According to a second aspect of the embodiments of the present disclosure, there is provided a stuck state determination apparatus including:
the acquisition module is used for acquiring resource use information of the terminal within a preset time length before the current time;
and the determining module is used for determining the current blocking state of the terminal according to the resource use information.
Optionally, the determining module includes:
the first determining submodule is used for determining the stuck state corresponding to the resource using information through a specified classifier, and determining the stuck state corresponding to the resource using information as the current stuck state of the terminal; or,
and the second determining submodule is used for acquiring the stuck state corresponding to the resource use information from the corresponding relation between the stored resource use information and the stuck state, and determining the stuck state corresponding to the resource use information as the current stuck state of the terminal.
Optionally, the determining module further comprises:
the first obtaining submodule is used for obtaining resource use information of the terminal within the preset time before the terminal is blocked when the terminal is blocked, and forming a first resource use information set by the obtained resource use information;
the second obtaining submodule is used for obtaining resource use information of the terminal within the preset time before the terminal is not blocked when the terminal is not blocked, and forming a second resource use information set by the obtained resource use information;
and the training submodule is used for training a classification model to be trained by using the first resource use information set and the second resource use information set to obtain the specified classifier.
Optionally, the apparatus further comprises:
the display module is used for displaying preset pause prompt information when the current pause state of the terminal is pause; or,
and the adjusting module is used for adjusting the resource state of the terminal when the current clamping state of the terminal is clamping.
Optionally, the resource usage information includes at least one of a CPU usage rate of the central processing unit, a CPU frequency, a memory usage rate, a number of memory fragments, a total number of bytes of the memory fragments, a number of running processes, and a temperature.
According to a third aspect of embodiments of the present disclosure, there is provided a stuck state determination apparatus, the apparatus including:
a processor;
a memory for storing processor-executable instructions;
wherein the processor is configured to perform the steps of the method of the first aspect.
According to a fourth aspect of embodiments of the present disclosure, there is provided a computer-readable storage medium having stored thereon instructions which, when executed by a processor, implement the steps of the method of the first aspect described above.
The technical scheme provided by the embodiment of the disclosure can have the following beneficial effects:
in the embodiment of the disclosure, the resource use information of the terminal in the preset time before the current time can be acquired, and then the current blocking state of the terminal is determined according to the resource use information, so that the current blocking state of the terminal can be accurately predicted by monitoring the resource use condition of the terminal before the current time in real time.
It is to be understood that both the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the disclosure.
Drawings
The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present disclosure and together with the description, serve to explain the principles of the disclosure.
FIG. 1 is a flow chart illustrating a stuck state determination method in accordance with an exemplary embodiment.
FIG. 2A is a flow chart illustrating another stuck state determination method in accordance with an exemplary embodiment.
FIG. 2B is a diagram illustrating a preset stuck prompt according to an example embodiment.
Fig. 3A is a block diagram illustrating a first stuck state determination device, according to an example embodiment.
FIG. 3B is a block diagram illustrating a determination module in accordance with an exemplary embodiment.
FIG. 3C is a block diagram illustrating another determination module in accordance with an exemplary embodiment.
FIG. 3D is a block diagram illustrating a second stuck state determination device, according to an example embodiment.
FIG. 4 is a block diagram illustrating a third stuck state determination device, according to an example embodiment.
Detailed Description
Reference will now be made in detail to the exemplary embodiments, examples of which are illustrated in the accompanying drawings. When the following description refers to the accompanying drawings, like numbers in different drawings represent the same or similar elements unless otherwise indicated. The implementations described in the exemplary embodiments below are not intended to represent all implementations consistent with the present disclosure. Rather, they are merely examples of apparatus and methods consistent with certain aspects of the present disclosure, as detailed in the appended claims.
For convenience of understanding, before explaining the embodiments of the present disclosure in detail, an application scenario related to the embodiments of the present disclosure will be described.
The operation speed of the terminal may be slower and slower along with the increase of the service time of the terminal and the increase of the installed applications, so that the terminal is often jammed in the use process, when the terminal is jammed, a user needs to manually end part or all of the running processes of the terminal to improve the jamming, the operation is troublesome, and the normal use of the user is affected.
Next, a stuck state determination method provided by an embodiment of the present disclosure will be described in detail with reference to the drawings.
Fig. 1 is a flow chart illustrating a stuck state determination method according to an exemplary embodiment, as shown in fig. 1, including the following steps.
In step 101, resource usage information of the terminal within a preset duration before the current time is obtained.
In step 102, the current stuck state of the terminal is determined according to the resource usage information.
In the embodiment of the disclosure, the resource use information of the terminal in the preset time before the current time can be acquired, and then the current blocking state of the terminal is determined according to the resource use information, so that the current blocking state of the terminal can be accurately predicted by monitoring the resource use condition of the terminal before the current time in real time.
Optionally, determining the current stuck state of the terminal according to the resource usage information includes:
determining the stuck state corresponding to the resource use information through a specified classifier, and determining the stuck state corresponding to the resource use information as the current stuck state of the terminal; or,
and acquiring the stuck state corresponding to the resource use information from the corresponding relation between the stored resource use information and the stuck state, and determining the stuck state corresponding to the resource use information as the current stuck state of the terminal.
Optionally, before determining the stuck state corresponding to the resource usage information by the specified classifier, the method further includes:
when the terminal is blocked, acquiring resource use information of the terminal within the preset time before the terminal is blocked, and forming the acquired resource use information into a first resource use information set;
when the terminal does not have a pause in the card, acquiring resource use information of the terminal within the preset time before the terminal does not have the pause in the card, and forming a second resource use information set by the acquired resource use information;
and training the classification model to be trained by using the first resource use information set and the second resource use information set to obtain the specified classifier.
Optionally, after determining the current stuck state of the terminal according to the resource usage information, the method further includes:
when the current blocking state of the terminal is blocking, displaying preset blocking prompt information; or,
and when the current blocking state of the terminal is blocking, adjusting the resource state of the terminal.
Optionally, the resource usage information includes at least one of a CPU usage rate of the central processing unit, a CPU frequency, a memory usage rate, a number of memory fragments, a total number of bytes of the memory fragments, a number of running processes, and a temperature.
All the above optional technical solutions can be combined arbitrarily to form optional embodiments of the present disclosure, and the embodiments of the present disclosure are not described in detail again.
Fig. 2A is a flowchart illustrating a stuck state determination method according to an exemplary embodiment, and the stuck state determination method provided in the embodiment of fig. 1 will be described with reference to fig. 2A. As shown in fig. 2A, the method includes the following steps.
In step 201, resource usage information of the terminal within a preset duration before the current time is obtained.
It should be noted that the preset time period may be preset according to different requirements, for example, the preset time period may be 5 minutes, 10 minutes, 15 minutes, and the like.
In addition, the resource usage information is used to reflect the resource usage in the terminal, for example, the resource usage information may include at least one of a CPU (Central Processing Unit) usage rate, a CPU frequency, a memory usage rate, a memory fragment number, a total byte number of the memory fragment, a running process number, a temperature, and the like. The CPU utilization rate refers to CPU resources occupied by all processes operated by the terminal; the CPU frequency refers to the clock frequency of the CPU, namely the working frequency of the CPU during operation; the memory utilization rate refers to memory resources occupied by all processes operated by the terminal; the memory fragments include an internal fragment and an external fragment, the internal fragment refers to a memory space which is allocated to a process but cannot be used, the external fragment refers to a memory free area which is not allocated to the process but is too small to be allocated to a new process applying for the memory space, the number of the memory fragments refers to the sum of the numbers of the internal fragment and the external fragment, and the total number of bytes of the memory fragments refers to the total number of bytes of the internal fragment and the external fragment.
For example, the resource usage information of the terminal within the preset duration before the current time may include a CPU usage rate of 80%, a memory usage rate of 90%, a memory fragmentation number of 20, a temperature of 30 ℃.
In step 202, the current stuck state of the terminal is determined according to the resource usage information.
It should be noted that the stuck state may include stuck and not stuck.
It should be noted that, since the resource usage information may reflect the resource usage in the terminal, and the resource usage often affects the stuck state of the terminal, the present stuck state of the terminal may be accurately predicted according to the resource usage information in the embodiment of the present disclosure.
For example, the resource usage information of the terminal within 5 minutes before the current time includes a CPU usage rate of 80%, a memory usage rate of 90%, a number of memory fragments of 20, and a temperature of 30 degrees celsius, and at this time, the current stuck state of the terminal may be determined according to the resource usage condition.
Wherein, step 202 may include the following 2 possible implementation manners:
a first possible implementation: and determining the stuck state corresponding to the resource use information through a specified classifier, and determining the stuck state corresponding to the resource use information as the current stuck state of the terminal.
It should be noted that, the designated classifier is used to classify the resource usage information, in practical application, after a certain resource usage information is input into the designated classifier, the designated classifier may determine the category to which the resource usage information belongs from the stuck category and the non-stuck category, and then output the category to which the resource usage information belongs, where the category to which the resource usage information belongs is the stuck state corresponding to the resource usage information.
Further, before determining the stuck state corresponding to the resource usage information by the specified classifier, the specified classifier may be generated first.
The implementation process of generating the specified classifier may be: when the terminal is blocked, acquiring resource use information of the terminal within a preset time length before the terminal is blocked, and forming the acquired resource use information into a first resource use information set; when the terminal does not have a pause in the card, acquiring resource use information of the terminal within a preset time length before the terminal does not have the pause in the card, and forming a second resource use information set by the acquired resource use information; and training the classification model to be trained by using the first resource use information set and the second resource use information set to obtain the specified classifier.
It should be noted that the first resource usage information set is a set of resource usage information acquired when the terminal is in a stuck state, that is, a category to which all resource usage information in the first resource usage information set belongs is a stuck category, and the second resource usage information set is a set of resource usage information acquired when the terminal is not in a stuck state, that is, a category to which all resource usage information in the second resource usage information set belongs is a non-stuck category.
In addition, the first resource usage information set and the second resource usage information set are used for training a classification model to be trained, when a specified classifier is obtained, the classification model to be trained can be trained in a supervised learning mode to obtain the specified classifier, the supervised learning means that parameters in the classification model are continuously adjusted through a preset adjusting algorithm under the condition of input and output of the given classification model, so that the classification model achieves the process of required performance, and the classification model is the specified classifier when the required performance is achieved.
It is worth noting that in the embodiment of the present disclosure, the first resource usage information set and the second resource usage information set may be used to train the classification model to be trained, so as to obtain the specified classifier, and since the first resource usage information set and the second resource usage information set are obtained by acquiring a large amount of resource usage information of the terminal, the pertinence is strong, so that the classification accuracy of the specified classifier obtained by training is high.
Certainly, in practical application, the resource usage information of the terminal can be collected to form the first resource usage information set and the second resource usage information set, and the resource usage information of other terminals can be obtained to form the first resource usage information set and the second resource usage information set.
A second possible implementation: and acquiring the stuck state corresponding to the resource use information from the corresponding relation between the stored resource use information and the stuck state, and determining the stuck state corresponding to the resource use information as the current stuck state of the terminal.
It should be noted that, the terminal may store the corresponding relationship between the resource usage information and the stuck state in advance, and then directly determine the stuck state corresponding to the resource usage information through the corresponding relationship between the resource usage information and the stuck state, and then determine the stuck state as the current stuck state of the terminal, which is simple in determination process and high in determination speed.
For example, if the resource usage information is resource usage information 1, the stuck state corresponding to the resource usage information may be obtained from the correspondence between the resource usage information and the stuck state shown in table 1 below, and then the current stuck state of the terminal may be determined to be stuck.
TABLE 1
Resource usage information Stuck state
Resource usage information 1 Catton
Resource usage information 2 Catton
Resource usage information 3 Without jamming
It should be noted that, in the embodiment of the present disclosure, only the correspondence between the resource usage information and the stuck state shown in table 1 is taken as an example for description, and table 1 does not limit the embodiment of the present disclosure.
Further, before acquiring the stuck state corresponding to the resource usage information from the stored correspondence between the resource usage information and the stuck state, the correspondence between the resource usage information and the stuck state may also be created. Specifically, when a setting instruction is detected, resource usage information and a stuck state carried in the setting instruction may be acquired, and the resource usage information and the stuck state may be correspondingly stored to obtain a corresponding relationship between the resource usage information and the stuck state.
It should be noted that the setting instruction is used to create a corresponding relationship between the resource usage information and the stuck state carried by the setting instruction, the setting instruction may be triggered by a user, and the user may trigger the setting instruction through a specified operation, where the specified operation may be a click operation, a slide operation, a voice operation, or the like.
In step 203, when the current card-pause state of the terminal is card-pause, the resource state of the terminal is adjusted.
It should be noted that the resource state of the terminal may be a state in which a CPU, a memory fragment, a running process, hardware, and the like of the terminal are located.
In addition, the terminal may be stuck due to too high CPU utilization, too low CPU frequency, too high memory utilization, too many memory fragments, too many total bytes of the memory fragments, too many running processes, too high temperature, and the like, so that when the current stuck state of the terminal is stuck, the resource state of the terminal may be adjusted.
The implementation process of adjusting the resource state of the terminal may be: the CPU utilization rate is reduced; and/or, increasing the CPU frequency; and/or, reducing memory usage; and/or, reducing the number of memory fragments; and/or reducing the total byte number of the memory fragments; and/or, reducing the number of processes running; and/or reduce the temperature, etc., however, in practical applications, there may be other implementation manners in the implementation process of adjusting the resource state of the terminal, and the embodiment of the present disclosure does not limit this.
For example, the CPU utilization rate can be reduced and the number of running processes can be reduced by ending the processes running in the background of the terminal with lower use frequency; the memory utilization rate can be reduced by cleaning the memory of the terminal; the number of the memory fragments and the total byte number of the memory fragments can be reduced by sorting the memory fragments; the temperature of the terminal may be reduced by adding a heat sink to the terminal, etc.
It should be noted that the terminal is usually due to the fact that resources are used excessively, and therefore, when the current state of the terminal is stuck, it is indicated that the current resources of the terminal are used excessively, and at this time, the resource state of the terminal can be adjusted to increase the operation speed of the terminal, so as to avoid the terminal being stuck, and facilitate normal use of the terminal by a user.
Furthermore, when the current blocking state of the terminal is blocking, the resource state of the terminal can be adjusted, and blocking reminding can be performed on a user, so that the user can timely know the blocking condition which may possibly occur at the current terminal. When the user is reminded of the stuck state, preset stuck state prompt information can be displayed.
It should be noted that the preset stuck prompt message may be set in advance according to different requirements, for example, as shown in fig. 2B, the preset stuck prompt message may include "if the program is executed, the terminal may be stuck and whether the program is continuously executed? The "ok" button, and the "cancel" button, and when the user clicks the "ok" button, the program continues to run, and when the user clicks the "cancel" button, the program stops running.
It should be noted that when the current card pause state of the terminal is card pause, it indicates that the terminal may be currently card pause, at this time, preset card pause prompt information may be displayed to inform the user, and the user may know the card pause condition that may currently occur in the terminal in advance, so that the user may select to continue running the program or quit the program, and the user experience is improved.
In the embodiment of the disclosure, the resource use information of the terminal in the preset time before the current time can be acquired, and then the current blocking state of the terminal is determined according to the resource use information, so that the current blocking state of the terminal can be accurately predicted by monitoring the resource use condition of the terminal before the current time in real time. In addition, when the current blocking state of the terminal is determined to be blocking, preset blocking prompt information can be displayed to remind a user, so that the user can know the blocking condition possibly occurring at the terminal in advance; or when the current blocking state of the terminal is determined to be blocking, the resource state of the terminal can be adjusted to increase the running speed of the terminal, so that the blocking state of the terminal is predicted in real time and optimized in advance to avoid the blocking of the terminal, and the normal use of a user is facilitated.
FIG. 3A is a block diagram illustrating a stuck state determination device in accordance with an exemplary embodiment. Referring to fig. 3A, the apparatus includes an acquisition module 301 and a determination module 302.
An obtaining module 301, configured to obtain resource usage information of a terminal within a preset duration before a current time.
A determining module 302, configured to determine a current stuck state of the terminal according to the resource usage information.
Optionally, referring to fig. 3B, the determining module 302 includes:
a first determining submodule 3021, configured to determine the stuck state corresponding to the resource usage information by specifying a classifier, and determine the stuck state corresponding to the resource usage information as the current stuck state of the terminal; or,
the second determining sub-module 3022 is configured to obtain the stuck state corresponding to the resource usage information from the stored correspondence between the resource usage information and the stuck state, and determine the stuck state corresponding to the resource usage information as the current stuck state of the terminal.
Optionally, referring to fig. 3C, the determining module 302 further includes:
the first obtaining sub-module 3023, configured to, when the terminal is stuck, obtain resource usage information of the terminal within the preset time period before the terminal is stuck, and form a first resource usage information set with the obtained resource usage information.
The second obtaining sub-module 3024, configured to, when the terminal does not turn on, obtain resource usage information of the terminal within the preset time period before turning on, and compose the obtained resource usage information into a second resource usage information set.
The training submodule 3025 is configured to train the classification model to be trained by using the first resource usage information set and the second resource usage information set, so as to obtain the specified classifier.
Optionally, referring to fig. 3D, the apparatus further comprises:
the display module 303 is configured to display preset pause prompt information when the current pause state of the terminal is pause; or,
the adjusting module 304 is configured to adjust the resource status of the terminal when the current card-pause status of the terminal is card-pause.
Optionally, the resource usage information includes at least one of a CPU usage rate of the central processing unit, a CPU frequency, a memory usage rate, a number of memory fragments, a total number of bytes of the memory fragments, a number of running processes, and a temperature.
In the embodiment of the disclosure, the resource use information of the terminal in the preset time before the current time can be acquired, and then the current blocking state of the terminal is determined according to the resource use information, so that the current blocking state of the terminal can be accurately predicted by monitoring the resource use condition of the terminal before the current time in real time. In addition, when the current blocking state of the terminal is determined to be blocking, preset blocking prompt information can be displayed to remind a user, so that the user can know the blocking condition possibly occurring at the terminal in advance; or when the current blocking state of the terminal is determined to be blocking, the resource state of the terminal can be adjusted to increase the running speed of the terminal, so that the blocking state of the terminal is predicted in real time and optimized in advance to avoid the blocking of the terminal, and the normal use of a user is facilitated.
With regard to the apparatus in the above-described embodiment, the specific manner in which each module performs the operation has been described in detail in the embodiment related to the method, and will not be elaborated here.
Fig. 4 is a block diagram illustrating a stuck state determination apparatus 400 according to an example embodiment. For example, the apparatus 400 may be a mobile phone, a computer, a digital broadcast terminal, a messaging device, a game console, a tablet device, a medical device, an exercise device, a personal digital assistant, and the like.
Referring to fig. 4, the apparatus 400 may include one or more of the following components: processing components 402, memory 404, power components 406, multimedia components 408, audio components 410, input/output (I/O) interfaces 412, sensor components 414, and communication components 416.
The processing component 402 generally controls overall operation of the apparatus 400, such as operations associated with display, telephone calls, data communications, camera operations, and recording operations. The processing component 402 may include one or more processors 420 to execute instructions to perform all or a portion of the steps of the methods described above. Further, the processing component 402 can include one or more modules that facilitate interaction between the processing component 402 and other components. For example, the processing component 402 can include a multimedia module to facilitate interaction between the multimedia component 408 and the processing component 402.
The memory 404 is configured to store various types of data to support operations at the apparatus 400. Examples of such data include instructions for any application or method operating on the device 400, contact data, phonebook data, messages, pictures, videos, and so forth. The memory 404 may be implemented by any type or combination of volatile or non-volatile memory devices such as Static Random Access Memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic memory, flash memory, magnetic or optical disks.
Power supply components 406 provide power to the various components of device 400. The power components 406 may include a power management system, one or more power supplies, and other components associated with generating, managing, and distributing power supplies for the apparatus 400.
The multimedia component 408 includes a screen that provides an output interface between the device 400 and the user. In some embodiments, the screen may include a Liquid Crystal Display (LCD) and a Touch Panel (TP). If the screen includes a touch panel, the screen may be implemented as a touch screen to receive an input signal from a user. The touch panel includes one or more touch sensors to sense touch, slide, and gestures on the touch panel. The touch sensor may not only sense the boundary of a touch or slide action, but also detect the duration and pressure associated with the touch or slide operation. In some embodiments, the multimedia component 408 includes a front facing camera and/or a rear facing camera. The front camera and/or the rear camera may receive external multimedia data when the apparatus 400 is in an operation mode, such as a photographing mode or a video mode. Each front camera and rear camera may be a fixed optical lens system or have a focal length and optical zoom capability.
The audio component 410 is configured to output and/or input audio signals. For example, audio component 410 includes a Microphone (MIC) configured to receive external audio signals when apparatus 400 is in an operational mode, such as a call mode, a recording mode, and a voice recognition mode. The received audio signals may further be stored in the memory 404 or transmitted via the communication component 416. In some embodiments, audio component 410 also includes a speaker for outputting audio signals.
The I/O interface 412 provides an interface between the processing component 402 and peripheral interface modules, which may be keyboards, click wheels, buttons, etc. These buttons may include, but are not limited to: a home button, a volume button, a start button, and a lock button.
The sensor component 414 includes one or more sensors for providing various aspects of status assessment for the apparatus 400. For example, the sensor assembly 414 may detect an open/closed state of the apparatus 400, the relative positioning of the components, such as a display and keypad of the apparatus 400, the sensor assembly 414 may also detect a change in the position of the apparatus 400 or a component of the apparatus 400, the presence or absence of user contact with the apparatus 400, orientation or acceleration/deceleration of the apparatus 400, and a change in the temperature of the apparatus 400. The sensor assembly 414 may include a proximity sensor configured to detect the presence of a nearby object without any physical contact. The sensor assembly 414 may also include a light sensor, such as a CMOS or CCD image sensor, for use in imaging applications. In some embodiments, the sensor assembly 414 may also include an acceleration sensor, a gyroscope sensor, a magnetic sensor, a pressure sensor, or a temperature sensor.
The communication component 416 is configured to facilitate wired or wireless communication between the apparatus 400 and other devices. The apparatus 400 may access a wireless network based on a communication standard, such as WiFi, 2G or 3G, or a combination thereof. In an exemplary embodiment, the communication component 416 receives broadcast signals or broadcast related information from an external broadcast management system via a broadcast channel. In an exemplary embodiment, the communication component 416 further includes a Near Field Communication (NFC) module to facilitate short-range communications. For example, the NFC module may be implemented based on Radio Frequency Identification (RFID) technology, infrared data association (IrDA) technology, Ultra Wideband (UWB) technology, Bluetooth (BT) technology, and other technologies.
In an exemplary embodiment, the apparatus 400 may be implemented by one or more Application Specific Integrated Circuits (ASICs), Digital Signal Processors (DSPs), Digital Signal Processing Devices (DSPDs), Programmable Logic Devices (PLDs), Field Programmable Gate Arrays (FPGAs), controllers, micro-controllers, microprocessors or other electronic components for performing the methods provided by the embodiments illustrated in fig. 1 and 2A and described above.
In an exemplary embodiment, a non-transitory computer-readable storage medium comprising instructions, such as the memory 404 comprising instructions, executable by the processor 420 of the apparatus 400 to perform the above-described method is also provided. For example, the non-transitory computer readable storage medium may be a ROM, a Random Access Memory (RAM), a CD-ROM, a magnetic tape, a floppy disk, an optical data storage device, and the like.
A non-transitory computer readable storage medium having instructions therein which, when executed by a processor of a terminal, enable the terminal to perform a stuck state determination method, the method comprising:
acquiring resource use information of a terminal within a preset time before the current time;
and determining the current stuck state of the terminal according to the resource use information.
Optionally, determining the current stuck state of the terminal according to the resource usage information includes:
determining the stuck state corresponding to the resource use information through a specified classifier, and determining the stuck state corresponding to the resource use information as the current stuck state of the terminal; or,
and acquiring the stuck state corresponding to the resource use information from the corresponding relation between the stored resource use information and the stuck state, and determining the stuck state corresponding to the resource use information as the current stuck state of the terminal.
Optionally, before determining the stuck state corresponding to the resource usage information by the specified classifier, the method further includes:
when the terminal is blocked, acquiring resource use information of the terminal within the preset time before the terminal is blocked, and forming the acquired resource use information into a first resource use information set;
when the terminal does not have a pause in the card, acquiring resource use information of the terminal within the preset time before the terminal does not have the pause in the card, and forming a second resource use information set by the acquired resource use information;
and training the classification model to be trained by using the first resource use information set and the second resource use information set to obtain the specified classifier.
Optionally, after determining the current stuck state of the terminal according to the resource usage information, the method further includes:
when the current blocking state of the terminal is blocking, displaying preset blocking prompt information; or,
and when the current blocking state of the terminal is blocking, adjusting the resource state of the terminal.
Optionally, the resource usage information includes at least one of a CPU usage rate of the central processing unit, a CPU frequency, a memory usage rate, a number of memory fragments, a total number of bytes of the memory fragments, a number of running processes, and a temperature.
In the embodiment of the disclosure, the resource use information of the terminal in the preset time before the current time can be acquired, and then the current blocking state of the terminal is determined according to the resource use information, so that the current blocking state of the terminal can be accurately predicted by monitoring the resource use condition of the terminal before the current time in real time. In addition, when the current blocking state of the terminal is determined to be blocking, preset blocking prompt information can be displayed to remind a user, so that the user can know the blocking condition possibly occurring at the terminal in advance; or when the current blocking state of the terminal is determined to be blocking, the resource state of the terminal can be adjusted to increase the running speed of the terminal, so that the blocking state of the terminal is predicted in real time and optimized in advance to avoid the blocking of the terminal, and the normal use of a user is facilitated.
Other embodiments of the disclosure will be apparent to those skilled in the art from consideration of the specification and practice of the disclosure disclosed herein. This application is intended to cover any variations, uses, or adaptations of the disclosure following, in general, the principles of the disclosure and including such departures from the present disclosure as come within known or customary practice within the art to which the disclosure pertains. It is intended that the specification and examples be considered as exemplary only, with a true scope and spirit of the disclosure being indicated by the following claims.
It will be understood that the present disclosure is not limited to the precise arrangements described above and shown in the drawings and that various modifications and changes may be made without departing from the scope thereof. The scope of the present disclosure is limited only by the appended claims.

Claims (8)

1. A stuck state determination method, the method comprising:
acquiring resource use information of a terminal within a preset time before the current time;
determining the current stuck state of the terminal according to the resource use information, wherein the determining comprises the following steps: determining the stuck state corresponding to the resource use information through a specified classifier, and determining the stuck state corresponding to the resource use information as the current stuck state of the terminal;
before determining the stuck state corresponding to the resource usage information by the specified classifier, the method further includes:
when the terminal is blocked, acquiring resource use information of the terminal within the preset time before the terminal is blocked, and forming the acquired resource use information into a first resource use information set;
when the terminal is not blocked, acquiring resource use information of the terminal within the preset time before the terminal is not blocked, and forming a second resource use information set by the acquired resource use information;
training a classification model to be trained by using the first resource usage information set and the second resource usage information set in a supervised learning manner to obtain the specified classifier, wherein the supervised learning is a process of continuously adjusting parameters in the classification model through a preset adjusting algorithm under the condition of inputting and outputting the given classification model to enable the classification model to achieve the required performance;
wherein the first resource usage information set and the second resource usage information set are collected from a plurality of terminals, and the specified classifier is applicable to the plurality of terminals.
2. The method of claim 1, wherein after determining the current stuck state of the terminal according to the resource usage information, further comprising:
when the current blocking state of the terminal is blocking, displaying preset blocking prompt information; or,
and when the current blocking state of the terminal is blocking, adjusting the resource state of the terminal.
3. The method according to any one of claims 1-2, wherein the resource usage information includes at least one of CPU usage, CPU frequency, memory usage, number of memory fragments, total number of bytes of memory fragments, number of running processes, and temperature.
4. A stuck state determination apparatus, the apparatus comprising:
the acquisition module is used for acquiring resource use information of the terminal within a preset time length before the current time;
the determining module is used for determining the current blocking state of the terminal according to the resource use information;
the determining module comprises:
the first determining submodule is used for determining the stuck state corresponding to the resource using information through a specified classifier, and determining the stuck state corresponding to the resource using information as the current stuck state of the terminal;
the determining module further comprises:
the first obtaining submodule is used for obtaining resource use information of the terminal within the preset time before the terminal is blocked when the terminal is blocked, and forming a first resource use information set by the obtained resource use information;
the second obtaining submodule is used for obtaining resource use information of the terminal within the preset time before the terminal is not blocked when the terminal is not blocked, and forming a second resource use information set by the obtained resource use information;
the training submodule is used for training a classification model to be trained by using the first resource use information set and the second resource use information set in a supervised learning mode to obtain the specified classifier, and the supervised learning is a process of continuously adjusting parameters in the classification model through a preset adjusting algorithm under the condition of inputting and outputting the given classification model so as to enable the classification model to reach the required performance;
wherein the first resource usage information set and the second resource usage information set are collected from a plurality of terminals, and the specified classifier is applicable to the plurality of terminals.
5. The apparatus of claim 4, further comprising:
the display module is used for displaying preset pause prompt information when the current pause state of the terminal is pause; or,
and the adjusting module is used for adjusting the resource state of the terminal when the current clamping state of the terminal is clamping.
6. The apparatus according to any one of claims 4-5, wherein the resource usage information comprises at least one of CPU usage, CPU frequency, memory usage, number of memory fragments, total number of bytes of memory fragments, number of running processes, and temperature.
7. A stuck state determination apparatus, the apparatus comprising:
a processor;
a memory for storing processor-executable instructions;
wherein the processor is configured to perform the steps of any of the methods of claims 1-3.
8. A computer-readable storage medium having instructions stored thereon, wherein the instructions, when executed by a processor, implement the steps of any of the methods of claims 1-3.
CN201810193822.4A 2018-03-09 2018-03-09 Method and device for determining stuck state and computer readable storage medium Active CN108427618B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201810193822.4A CN108427618B (en) 2018-03-09 2018-03-09 Method and device for determining stuck state and computer readable storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201810193822.4A CN108427618B (en) 2018-03-09 2018-03-09 Method and device for determining stuck state and computer readable storage medium

Publications (2)

Publication Number Publication Date
CN108427618A CN108427618A (en) 2018-08-21
CN108427618B true CN108427618B (en) 2021-09-07

Family

ID=63158000

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201810193822.4A Active CN108427618B (en) 2018-03-09 2018-03-09 Method and device for determining stuck state and computer readable storage medium

Country Status (1)

Country Link
CN (1) CN108427618B (en)

Families Citing this family (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108984369A (en) * 2018-07-13 2018-12-11 厦门美图移动科技有限公司 Caton prediction method and device and mobile terminal
CN109935312A (en) * 2019-02-28 2019-06-25 深圳市理邦精密仪器股份有限公司 Progress control method, device, patient monitor and the medium of patient monitor
CN110837420B (en) * 2019-11-12 2022-11-15 Oppo广东移动通信有限公司 Resource scheduling method, device, terminal and storage medium
CN112732542A (en) * 2020-12-30 2021-04-30 中国平安财产保险股份有限公司 Information processing method, information processing device and terminal equipment
CN113961354A (en) * 2021-10-29 2022-01-21 重庆长安汽车股份有限公司 Machine-based stuck identification method and system based on weak supervision learning vehicle

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106445783A (en) * 2016-09-27 2017-02-22 北京金山安全软件有限公司 Method and device for detecting jamming of electronic equipment and electronic equipment
CN106776030A (en) * 2016-12-21 2017-05-31 维沃移动通信有限公司 The method and mobile terminal of a kind of dynamic managing internal memory
CN107193678A (en) * 2017-04-28 2017-09-22 北京小米移动软件有限公司 Interim card method for determining reason, device and storage medium
CN107678800A (en) * 2017-09-30 2018-02-09 广东欧珀移动通信有限公司 Background application method for cleaning, device, storage medium and electronic equipment

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20120283991A1 (en) * 2011-05-06 2012-11-08 The Board of Trustees of the Leland Stanford, Junior, University Method and System for Online Detection of Multi-Component Interactions in Computing Systems

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106445783A (en) * 2016-09-27 2017-02-22 北京金山安全软件有限公司 Method and device for detecting jamming of electronic equipment and electronic equipment
CN106776030A (en) * 2016-12-21 2017-05-31 维沃移动通信有限公司 The method and mobile terminal of a kind of dynamic managing internal memory
CN107193678A (en) * 2017-04-28 2017-09-22 北京小米移动软件有限公司 Interim card method for determining reason, device and storage medium
CN107678800A (en) * 2017-09-30 2018-02-09 广东欧珀移动通信有限公司 Background application method for cleaning, device, storage medium and electronic equipment

Also Published As

Publication number Publication date
CN108427618A (en) 2018-08-21

Similar Documents

Publication Publication Date Title
CN108427618B (en) Method and device for determining stuck state and computer readable storage medium
EP3188066B1 (en) A method and an apparatus for managing an application
US9588805B2 (en) Method and terminal device for controlling background application
CN108268322B (en) Memory optimization method and device and computer readable storage medium
US20170055221A1 (en) Method and apparatus for starting energy saving mode
CN107798309B (en) Fingerprint input method and device and computer readable storage medium
US9628966B2 (en) Method and device for sending message
CN108538258B (en) Method and device for adjusting backlight current and display equipment
CN109314842B (en) Resource sensing result reporting method and device, user equipment and storage medium
EP2988458A1 (en) Method and device for sending message
CN107480785A (en) The training method and device of convolutional neural networks
CN106209471A (en) Fault feedback method and device
CN108462784A (en) In Call method of adjustment and device
CN109862169B (en) Electronic equipment control method, device and storage medium
CN112256563A (en) Android application stability testing method and device, electronic equipment and storage medium
CN104360875B (en) Privacy mode starts method and apparatus
CN108874450B (en) Method and device for waking up voice assistant
US10671827B2 (en) Method and device for fingerprint verification
CN105227426B (en) Application interface switching method and device and terminal equipment
CN105786561B (en) Method and device for calling process
CN106454540B (en) Method and device for processing interactive information based on live broadcast
CN108427582B (en) Method and device for determining stuck state and computer readable storage medium
CN108886461B (en) Data transmission method and device
CN103973883B (en) A kind of method and device controlling voice-input device
CN107422911B (en) Pressure value detection method and device and computer readable storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant