Fan operation control method and apparatus, and electronic device and storage medium
The fan speed prediction model optimized through BP neural network and genetic algorithm solves the problem of fan operation control lag, achieves accurate and timely heat dissipation of terminal equipment, and improves the safety and stability of the equipment.
Patent Information
- Application Number
- PCT/CN2023/141633
- Authority / Receiving Office
- WO · WO
- Patent Type
- Applications
- Current Assignee / Owner
- Priority Date
- 2023-03-02
- Filing Date
- 2023-12-25
- Publication Date
- 2024-09-06
AI Technical Summary
Existing fan operation control methods rely on the temperature of internal components of the device, resulting in delayed fan operation control actions and affecting the safe and stable operation of the terminal equipment.
The BP neural network is used to establish a fan speed prediction model, and the model is trained through the historical operating parameters of the terminal equipment. The genetic algorithm is used to optimize the model weights and thresholds to achieve automated prediction and control of the fan target speed.
Predict the fan target speed in advance and accurately to avoid fan operation lag caused by reliance on temperature calculations and improve the safe and stable operation of terminal equipment.
Smart Images

Figure CN2023141633_06092024_PF_FP
Abstract
Description
Fan operation control method, device, electronic device and storage medium
[0001] CROSS-REFERENCE TO RELATED APPLICATIONS
[0002] This application claims priority to the Chinese patent application filed with the China Patent Office on March 2, 2023, with application number 202310193137.2, and application name “Fan operation control method, device, electronic device and storage medium”, all contents of which are incorporated by reference into this application. Technical Field
[0003] The present application relates to the field of heat dissipation technology, and in particular to a fan operation control method, a fan operation control device, an electronic device, and a non-volatile readable storage medium. Background Art
[0004] For terminal devices that require heat dissipation (such as servers, switches, etc.), a fan operation control system is configured to adjust the fan speed in real time according to the different operating states of the equipment to ultimately achieve reliable heat dissipation of the equipment.
[0005] On current terminal devices, for fans of the same rotor type, the target fan speed is calculated based on the device's current air inlet temperature, the device's internal motherboard temperature, and the port-side optical module temperature, combined with the system's given temperature and speed control algorithm. Based on the temperature values of different components within the switch, the speed control algorithm uses a combination of linear speed control and PID speed control to calculate the fan's target speed. The highest value of the two is taken as the final target speed, thereby achieving heat dissipation for the terminal device through the fan.
[0006] However, both the linear speed control algorithm and the PID speed control algorithm rely on the temperature of the internal components of the device. When the power consumption of the device increases instantaneously, the rate of increase of its internal temperature has a certain delay compared to the rate of increase of power consumption, which eventually leads to a lag in the fan operation control action, posing a certain hidden danger to the safe and stable operation of the equipment.
[0007] Summary of the Invention
[0008] Some embodiments of the present application provide a fan operation control method, device, electronic device and non-volatile readable storage medium to solve the problem of relying on the temperature of internal components of the device to calculate the target speed of the fan, resulting in delayed fan operation control action.
[0009] Some embodiments of the present application disclose a fan operation control method, which is applied to a terminal device provided with a fan for heat dissipation. The method includes:
[0010] Detect the operating status of terminal equipment;
[0011] If the terminal device is in a normal operating state, obtain the operating parameters of the terminal device;
[0012] Input the operating parameters into the fan speed prediction model to predict the fan's target speed; the fan speed prediction model is obtained by training the BP neural network with the historical operating parameters of the terminal device;
[0013] The fan operation is controlled based on the target speed.
[0014] In some embodiments, before inputting the operating parameters into the fan speed prediction model, the method further includes:
[0015] Obtain historical operating parameters of terminal devices as training sets and test sets;
[0016] Train the BP neural network based on the training set to obtain the initial BP neural network model;
[0017] The initial BP neural network model is verified based on the test set to obtain a trained fan speed prediction model.
[0018] In some embodiments, the BP neural network includes: an input layer, a hidden layer, and an output layer. The number of neuron nodes in the input layer is 8, the number of neuron nodes in the hidden layer is 5, and the number of neuron nodes in the output layer is 1.
[0019] In some embodiments, before training the BP neural network based on the training set to obtain the initial BP neural network model, the method further includes:
[0020] Determine the structure of BP neural network;
[0021] Determine all initial weights and thresholds of the BP neural network according to its structure;
[0022] Genetic algorithm is used to optimize the initial weights and thresholds to obtain the optimal weights and thresholds of the BP neural network, so that the BP neural network can be trained based on the optimal weights and thresholds.
[0023] In some embodiments, a genetic algorithm is used to optimize the initial weights and thresholds to obtain the optimal weights and thresholds of the BP neural network, including:
[0024] Encoding is performed according to the initial weights and thresholds to form the initial population of the genetic algorithm;
[0025] Perform selection, crossover and mutation operations on the initial population to obtain the candidate population;
[0026] When the number of operations reaches the preset maximum number of evolutions, the optimal population group in the candidate population is decoded to obtain the optimal weights and thresholds of the BP neural network; when the number of operations is less than the preset maximum number of evolutions, the candidate population is used as the initial population, and the selection, crossover and mutation operation steps of the initial population are returned to be executed.
[0027] In some embodiments, the terminal device is provided with a CPU and a switching chip, and the operating parameters include at least the CPU temperature, CPU current, CPU voltage, CPU power consumption, switching chip temperature, switching chip current, switching chip voltage, switching chip power consumption and fan speed.
[0028] In some embodiments, after detecting the operating status of the terminal device, the method further includes:
[0029] If the operating state of the terminal device is an abnormal operating state, the operation of the fan is controlled based on the abnormal operating state.
[0030] In some embodiments, further comprising:
[0031] If the operating status of the terminal device is abnormal, an alarm signal is output.
[0032] In some embodiments, controlling the operation of a fan in a terminal device based on an abnormal operating state includes:
[0033] If the terminal device is in a high temperature test state, the fan is controlled to run at a first speed;
[0034] After the high temperature test phase state, return to execute the step of detecting the operating state of the terminal equipment.
[0035] In some embodiments, a temperature sensor is provided in the terminal device, and the operation of a fan in the terminal device is controlled based on an abnormal operating state, including:
[0036] If at least one temperature sensor in the terminal device detects that the internal temperature of the terminal device is greater than or equal to a first alarm threshold, the fan is controlled to run at a first speed.
[0037] In some embodiments, further comprising:
[0038] If the temperature sensors in the terminal device detect that the internal temperature of the terminal device is less than a first alarm threshold, and at least one temperature sensor in the terminal device detects that the temperature is greater than or equal to a second alarm threshold, then obtaining the operating parameters of the terminal device; wherein the second alarm threshold is less than the first alarm threshold;
[0039] Inputting the operating parameters into the fan speed prediction model to predict the target speed of the fan in the terminal device;
[0040] The operation of a fan in a terminal device is controlled based on a target speed.
[0041] In some embodiments, a terminal device is provided with a switching chip and a CPU (Central Processing Unit), and controlling the operation of a fan in the terminal device based on an abnormal operating state includes:
[0042] If temperature data of at least one of the temperature sensors located at the switching chip and the CPU in the terminal device is lost and the duration is greater than or equal to a first preset time, the fan is controlled to run at a first speed.
[0043] In some embodiments, controlling the operation of a fan in a terminal device based on an abnormal operating state includes:
[0044] If the redundant power supply of the terminal device is in a lost state, controlling the fan to run at a first speed;
[0045] When the redundant power supply of the terminal device changes from an out-of-position state to an in-position state, the fan is controlled to run at a second speed for a second preset time, and returns to execute the step of detecting the operating status of the terminal device after the second preset time; wherein the second preset speed is less than the first speed.
[0046] In some embodiments, controlling the operation of a fan in a terminal device based on an abnormal operating state includes:
[0047] If at least one fan in the terminal device is in an out-of-position state, controlling the fan in the position state to run at a first speed;
[0048] When all fans are in the on-position state, the fans are controlled to run at a second preset speed for a second preset time, and after the second preset time, the step of detecting the operating status of the terminal device is returned to execute; wherein the second preset speed is less than the first speed.
[0049] In some embodiments, controlling the operation of a fan in a terminal device based on an abnormal operating state includes:
[0050] If the fan data in the electrically erasable programmable read-only memory in the terminal device is lost, or the system of the terminal device is reset and restarted, the fan is controlled to run at the first speed.
[0051] In some embodiments, controlling the operation of a fan in a terminal device based on an abnormal operating state includes:
[0052] If the board management controller in the terminal device is suspended / failed, or the complex programmable logic device in the terminal device is upgraded online / failed, the fan is controlled to run at the first speed.
[0053] In some embodiments, controlling the operation of a fan in a terminal device based on an abnormal operating state includes:
[0054] If the rotation speed of at least one fan in the terminal device is less than the third rotation speed and lasts for a third preset time, the fan in the terminal device is controlled to run at the first rotation speed; wherein the third rotation speed is less than the first rotation speed.
[0055] In some embodiments, controlling the operation of a fan in a terminal device based on an abnormal operating state includes:
[0056] If it is detected that the system of the terminal device is powered on and restarted and the baseboard management controller of the terminal device is not started, controlling the fan to run at a fourth speed and detecting the operating state of the baseboard management controller;
[0057] When the baseboard management controller starts normally, the process returns to executing the step of detecting the operating status of the terminal device.
[0058] In some embodiments, the first rotational speed is the full rotational speed of the fan.
[0059] Some embodiments of the present application further disclose a fan operation control device, which is applied to a terminal device provided with a fan for heat dissipation, including:
[0060] Status detection module, used to detect the operating status of the terminal device;
[0061] A parameter acquisition module is used to obtain the operating parameters of the terminal device if the operating state of the terminal device is a normal operating state;
[0062] The speed prediction module is used to input the operating parameters into the fan speed prediction model to predict the target speed of the fan; the fan speed prediction model is obtained by training the BP neural network with the historical operating parameters of the terminal device;
[0063] The first operation control module is configured to control the operation of the fan based on a target rotational speed.
[0064] In some embodiments, further comprising:
[0065] A training set generation module is used to obtain historical operating parameters of terminal devices as training sets and test sets;
[0066] The model training module is used to train the BP neural network based on the training set to obtain the initial BP neural network model;
[0067] The model testing module is used to verify the initial BP neural network model based on the test set to obtain a trained fan speed prediction model.
[0068] In some embodiments, the BP neural network includes: an input layer, a hidden layer, and an output layer. The number of neuron nodes in the input layer is 8, the number of neuron nodes in the hidden layer is 5, and the number of neuron nodes in the output layer is 1.
[0069] In some embodiments, further comprising:
[0070] Structure determination module, used to determine the structure of BP neural network;
[0071] An initial parameter determination module is used to determine the initial weights and thresholds of the BP neural network according to the structure of the BP neural network;
[0072] The model optimization module is used to optimize the initial weights and thresholds using a genetic algorithm to obtain the optimal weights and thresholds of the BP neural network so as to train the BP neural network based on the optimal weights and thresholds.
[0073] In some embodiments, the model optimization module includes:
[0074] A population formation submodule is used to encode according to initial weights and thresholds to form an initial population of the genetic algorithm;
[0075] The population training submodule is used to perform selection, crossover and mutation operations on the initial population to obtain the candidate population;
[0076] The population decoding submodule is used to perform a decoding operation on the optimal population group in the candidate population when the number of operations reaches the preset maximum number of evolutions, so as to obtain the optimal weights and thresholds of the BP neural network;
[0077] The step return execution submodule is used to use the candidate population as the initial population when the number of operations is less than the preset maximum number of evolutions, and return to execute the selection, crossover and mutation operation steps on the initial population.
[0078] In some embodiments, the terminal device is provided with a CPU and a switching chip, and the operating parameters include at least the CPU temperature, CPU current, CPU voltage, CPU power consumption, switching chip temperature, switching chip current, switching chip voltage, switching chip power consumption and fan speed.
[0079] In some embodiments, further comprising:
[0080] The second operation control module is used to control the operation of the fan based on the abnormal operation state if the operation state of the terminal device is an abnormal operation state.
[0081] In some embodiments, further comprising:
[0082] The alarm output module is used to output an alarm signal if the operating status of the terminal device is abnormal.
[0083] In some embodiments, the second operation control module includes:
[0084] an operation control submodule, configured to control the fan to operate at a first speed if the terminal device is in a high temperature test state;
[0085] The step return submodule is used to return to the execution status detection module after the high temperature test phase state.
[0086] In some embodiments, the terminal device is provided with several temperature sensors, and the second operation control module includes:
[0087] The operation control submodule is configured to control the fan to operate at a first speed if at least one temperature sensor in the terminal device detects that the internal temperature of the terminal device is greater than or equal to a first alarm threshold.
[0088] In some embodiments, further comprising:
[0089] a parameter acquisition submodule, configured to acquire operating parameters of the terminal device if the temperature sensors in the terminal device detect that the internal temperature of the terminal device is less than a first alarm threshold, and if at least one temperature sensor in the terminal device detects that the temperature is greater than or equal to a second alarm threshold, wherein the second alarm threshold is less than the first alarm threshold;
[0090] A speed prediction submodule is used to input operating parameters into a fan speed prediction model to predict the target speed of the fan in the terminal device;
[0091] The operation control submodule is used to control the operation of the fan in the terminal device based on the target speed.
[0092] In some embodiments, the terminal device is provided with a switching chip and a CPU, and the second operation control module includes:
[0093] The operation control submodule is used to control the fan to run at a first speed if temperature data of at least one temperature sensor located at the switching chip and CPU position in the terminal device is lost and the duration is greater than or equal to a first preset time.
[0094] In some embodiments, the second operation control module includes:
[0095] An operation control submodule, configured to control the fan to operate at a first speed if the redundant power supply of the terminal device is in a lost state;
[0096] The step returns the submodule, which is used to control the fan to run at a second speed for a second preset time when the redundant power supply of the terminal device changes from an out-of-position state to an in-position state, and return to the execution status detection module after the second preset time; wherein the second preset speed is less than the first speed.
[0097] In some embodiments, the second operation control module includes:
[0098] an operation control submodule, configured to control the fans in the in-position state to operate at a first speed if at least one fan in the terminal device is in an out-of-position state;
[0099] The step returns to the execution submodule, which is used to control the fans to run at a second preset speed for a second preset time when all fans are in the in-place state, and return to the execution step of detecting the operating status of the terminal device after the second preset time; wherein the second preset speed is less than the first speed.
[0100] In some embodiments, the second operation control module includes:
[0101] The operation control submodule is used to control the fan to run at a first speed if the fan data in the electrically erasable programmable read-only memory in the terminal device is lost or the system of the terminal device is reset and restarted.
[0102] In some embodiments, the second operation control module includes:
[0103] The operation control submodule is used to control the fan to run at a first speed if the board management controller in the terminal device is suspended / failed, or the complex programmable logic device in the terminal device is upgraded online / failed.
[0104] In some embodiments, the second operation control module includes:
[0105] The operation control submodule is used to control the fan in the terminal device to run at the first speed if the speed of at least one fan in the terminal device is less than the third speed and lasts for a third preset time; wherein the third speed is less than the first speed.
[0106] In some embodiments, the second operation control module includes:
[0107] an operation control submodule, configured to control the fan to operate at a fourth speed and detect an operating state of the baseboard management controller if it is detected that the system of the terminal device is powered on and restarted and the baseboard management controller of the terminal device is not started;
[0108] The step returns to the execution submodule, which is used to return to the step of detecting the operating status of the terminal device when the baseboard management controller starts normally.
[0109] In some embodiments, the first rotational speed is the full rotational speed of the fan.
[0110] The embodiment of the present application further discloses an electronic device, comprising a processor, a communication interface, a memory, and a communication bus, wherein the processor, the communication interface, and the memory communicate with each other via the communication bus;
[0111] Memory for storing computer programs;
[0112] The processor is used to implement the methods of some embodiments of the present application when executing the program stored in the memory.
[0113] Some embodiments of the present application also disclose a non-volatile readable storage medium having instructions stored thereon, which, when executed by one or more processors, enable the processors to execute the method of the embodiments of the present application.
[0114] Some embodiments of the present application include the following advantages: when the operating state of the terminal device is normal, a fan speed prediction model is established using a BP neural network, and the operating parameters of the terminal device are used as input to realize automatic prediction of the target speed of the fan in the terminal device. The target speed of the fan can be predicted in advance and accurately, avoiding the delay of the fan operation control action due to relying on the temperature of the internal components of the device to calculate the fan speed, which creates certain hidden dangers to the safe and stable operation of the terminal device. BRIEF DESCRIPTION OF THE DRAWINGS
[0115] FIG1 is a flowchart of a fan operation control method provided in some embodiments of the present application;
[0116] FIG2 is a flowchart of a fan speed prediction model training method provided in some embodiments of the present application;
[0117] FIG3 is a schematic structural diagram of a multi-layer feedforward network based on a BP algorithm provided in some embodiments of the present application;
[0118] FIG4 is a schematic diagram of a prediction result based on a genetic algorithm optimized BP neural network provided in some embodiments of the present application;
[0119] FIG5 is a flowchart of another method for training a fan speed prediction model provided in some embodiments of the present application;
[0120] FIG6 is a flowchart of another fan operation control method provided in some embodiments of the present application;
[0121] FIG7 is a flowchart showing one of the steps of a fan control strategy under abnormal operating conditions provided in some embodiments of the present application;
[0122] FIG8 is a second flowchart of a control strategy for a fan in an abnormal operating state provided in some embodiments of the present application;
[0123] FIG9 is a third flowchart of a control strategy for a fan in an abnormal operating state provided in some embodiments of the present application;
[0124] FIG10 is a fourth flowchart of a control strategy for a fan in an abnormal operating state provided in some embodiments of the present application;
[0125] FIG11 is a fifth step flow chart of a fan control strategy under abnormal operating conditions provided in some embodiments of the present application;
[0126] FIG12 is a sixth flowchart of a control strategy for a fan in an abnormal operating state provided in some embodiments of the present application;
[0127] FIG13 is a seventh flowchart of a control strategy for a fan in an abnormal operating state provided in some embodiments of the present application;
[0128] FIG14 is a flowchart of the eighth step of a fan control strategy under abnormal operating conditions provided in some embodiments of the present application;
[0129] FIG15 is a ninth flowchart of a control strategy for a fan in an abnormal operating state provided in some embodiments of the present application;
[0130] FIG16 is a structural block diagram of a fan operation control device provided in some embodiments of the present application;
[0131] FIG17 is a block diagram of an electronic device provided in some embodiments of the present application;
[0132] FIG18 is a block diagram of a non-volatile readable storage medium provided in some embodiments of the present application. DETAILED DESCRIPTION
[0133] In order to make the above-mentioned purposes, features and advantages of the present application more obvious and easy to understand, the present application is further described in detail below with reference to the accompanying drawings and specific implementation methods.
[0134] Definitions of Abbreviations and Key Terms:
[0135] BMC: Baseboard Management Controller
[0136] CPLD: Complex Programming Logic Device
[0137] PSU: Power Supply Unit, power supply
[0138] Sensor: Sensor
[0139] BP neural network: Back Propagation neural network
[0140] GA: Genetic Algorithm
[0141] GA-BP: Genetic Algorithm-Back Propagation
[0142] PID: abbreviation of Proportional, Integral, and Differential
[0143] EEPROM: Electrically Erasable Programmable Read Only Memory
[0144] Network terminal devices such as servers and white-box switches are equipped with fan control systems to adjust fan speed in real time based on the device's operating status, ultimately ensuring reliable heat dissipation. Current speed control strategies include speed control methods tailored to fan single- and dual-rotor types. Alternatively, for fans of the same rotor type, a target fan speed is calculated based on the device's current air inlet temperature, internal motherboard temperature, and port-side optical module temperature, combined with a system-defined temperature and speed control algorithm. Furthermore, a more advanced approach combines these methods with the power consumption of the device's core components to calculate the target speed using a PID speed control algorithm. These fan control methods generally address heat dissipation during device operation. However, as white-box switches within data centers become increasingly complex, the amount of heat generated per unit time by large-capacity white-box switches is rapidly increasing. To ensure safe, reliable, and stable operation of these devices and to actively respond to national carbon peak and carbon neutrality policies, both customers and white-box switch vendors are placing higher demands on the real-time and accuracy of cooling systems, particularly fan control systems. Consequently, a more precise fan control method and speed control strategy are urgently needed to ensure the reliable and stable operation of large-capacity white-box switches.
[0145] One of the existing technical solutions is widely used in current white box switches. For fans of the same rotor type, the fan target speed value is calculated based on the current air inlet temperature of the device, the temperature of the mainboard inside the device, and the temperature of the optical module on the port side, combined with the temperature given by the system and the speed control algorithm. According to the temperature values of different components inside the switch, the speed control algorithm adopts a combination of linear speed control and PID speed control to calculate the target speed of the fan respectively, and the highest value of the two is taken as the final target speed. However, this technical means can achieve accurate speed control of the fan to a certain extent, solve the heat dissipation problem of the fan, and ensure the smooth and safe operation of the white box switch, but there are the following shortcomings: (1) Both the linear speed control algorithm and the PID speed control algorithm rely on the temperature of the internal components of the device. When the power consumption of the device increases instantaneously, the speed of its internal temperature increase has a certain delay compared to the speed of power consumption increase, which ultimately leads to a lag in the fan operation control action, causing certain hidden dangers to the safe and stable operation of the device. (2) Taking the highest speed value obtained by the linear speed control and PID speed control algorithms as the target speed value is likely to make the fan speed too fast, thereby causing excessive waste of electricity and affecting the service life of the fan.
[0146] The second existing technical solution is to introduce the device power consumption on the basis of the first technical solution, and adopt two speed control strategies. The speed control algorithm needs to rely not only on the temperature of the internal components of the device for speed control, but also on the instantaneous power consumption of the core components of the device. However, this technical solution alleviates the hysteresis of the fan operation control to a certain extent, but there are still at least two problems: (1) The proportional parameter Kp, integral parameter Ki, and differential parameter Kd in the PID speed control algorithm are all specified by empirical values, which have certain errors. Moreover, the fan manufacturers are different. Using the same set of parameters to control the operation of fans from different manufacturers further aggravates this inaccuracy; (2) After introducing the instantaneous power consumption of the internal components of the device, although the hysteresis of the speed control is alleviated to a certain extent, the power consumption changes under abnormal conditions of the device are not fully considered, which easily leads to the misadjustment of the fan speed.
[0147] Based on this, the present application discloses a fan operation control method, device, electronic device and non-volatile readable storage medium in some embodiments to solve the above-mentioned technical problems.
[0148] 1 , a flowchart illustrating a fan operation control method provided in some embodiments of the present application is shown. The fan operation control method is applied to a terminal device provided with a fan for heat dissipation. The method includes:
[0149] Step 101: Detect the operating status of the terminal device.
[0150] The terminal device may be a terminal device provided with a cooling fan, such as a server or a switch.
[0151] Specifically, after the terminal device is powered on and started, the terminal device operation status is continuously checked in a polling manner by the CPU in the terminal device. The terminal device operation status includes an abnormal operation status and a normal operation status.
[0152] Step 102: If the operating state of the terminal device is a normal operating state, obtain the operating parameters of the terminal device.
[0153] Among them, the operating parameters are the operating parameters of important components in the terminal device (such as CPU, switching chip, etc.), such as CPU temperature, CPU current, CPU voltage, CPU power consumption, switching chip temperature, switching chip current, switching chip voltage and switching chip power consumption, etc.
[0154] Specifically, when the terminal device is in a normal operating state, the fan operation of the terminal device is controlled according to a conventional speed regulation strategy (ie, BP algorithm), and specifically, the operating parameters of the terminal device are first obtained.
[0155] Step 103: Input the operating parameters into the fan speed prediction model to predict the target speed of the fan.
[0156] Step 104: Control the operation of the fan based on the target speed.
[0157] The fan speed prediction model is obtained by training the BP neural network with the historical operating parameters of the terminal device, that is, the historical operating parameters of the terminal device are collected as training data to train the BP neural network to obtain the trained fan speed prediction model.
[0158] Specifically, by inputting the terminal device's operating parameters into the fan speed prediction model, the target speed of the terminal device's fan for the next period of time can be predicted. For example, if the terminal device's operating parameters include eight parameters, such as the CPU's temperature, current, voltage, and power consumption, as well as the switch chip's temperature, current, voltage, and power consumption, these eight parameters can be directly input into the fan speed prediction model to predict the target speed of the terminal device's fan for the next period of time, thereby controlling the operation of the terminal device's fan based on the target speed.
[0159] In some embodiments of the present application, when the operating state of the terminal device is normal, a BP neural network is used to establish a fan speed prediction model, and the operating parameters of the terminal device are used as input to realize automatic prediction of the target speed of the fan in the terminal device. The target speed of the fan can be predicted in advance and accurately, avoiding the lag of the fan operation control action due to relying on the temperature of the internal components of the device to calculate the fan speed, which creates certain hidden dangers to the safe and stable operation of the terminal device.
[0160] 2 shows a flowchart of the steps of a fan speed prediction model training method provided in some embodiments of the present application. This embodiment of the present application mainly describes a fan speed prediction model training method based on the embodiment shown in FIG1. As shown in FIG2, the method of this embodiment may include:
[0161] Step 201: Obtain historical operating parameters of the terminal device as a training set and a test set.
[0162] Among them, the historical operating parameters in some embodiments of the present application are illustrated by taking the CPU temperature, CPU current, CPU voltage, CPU power consumption, switching chip temperature, switching chip current, switching chip voltage, switching chip power consumption and fan speed as examples.
[0163] Specifically, the number of hidden layer neuron nodes can be set to 5, then the BP neural network structure in the embodiment of the present application is 8-5-1, that is, the input layer has 8 nodes, the hidden layer has 5 nodes, and the output layer has 1 node, that is, the number of neuron nodes in the input layer is 8, the number of neuron nodes in the hidden layer is 5, and the number of neuron nodes in the output layer is 1, so there are 45 weights and 6 thresholds. Therefore, the operating parameters of the terminal device can be periodically obtained, with the temperature, current, voltage, and power consumption of the CPU and switching chip as 8 input values, and the corresponding fan speed value at the next moment as the output, to obtain several groups of input and output data (historical operating parameters), and the obtained several groups of input and output data are used as training data and test data respectively. For example, if 200 groups of input and output data are obtained, then 140 groups can be randomly selected from the 200 groups of input and output data as training data for network training, and 60 groups can be used as test data. The sum of the absolute value of the prediction error of the training data is used as the individual fitness value. The smaller the individual fitness value, the better the individual.
[0164] Step 202: Train the BP neural network based on the training set to obtain an initial BP neural network model.
[0165] Among them, the BP neural network structure is determined in the network initialization stage. As a feedforward network, the BP neural network adopts an error reverse transmission mechanism. After the information is input into the input layer, it is processed by the hidden layer and the actual output value of each unit is calculated. If the expected output value is not obtained in the output layer, the deviation value between the actual output and the expected output is recursively calculated layer by layer, and then the weight is adjusted based on this deviation value. The three-layer structure based on the BP neural network algorithm is shown in Figure 3. x and o serve as the input and output of this network respectively. Each neuron is represented by a node. In this application, it includes an input layer, a hidden layer and an output layer. In Figure 3, j represents the number of neurons in the input layer, i represents the number of neurons in the hidden layer, and k represents the number of neurons in the output layer. The back propagation algorithm that learning depends on in the network is as follows, and the objective function is selected as:
[0166] The error function E is used to reduce the fastest direction adjustment to make the BP neural network converge gradually. According to the gradient descent algorithm, the t+1th weight coefficient adjustment value from neuron j to neuron i is obtained:
[0167] The error function E is related to the actual output of the network at this moment:
[0168] A single hidden layer was used, and the trial-and-error method was used to determine the optimal number of nodes in the hidden layer. The transfer function of the hidden layer neurons was the sigmoid function Tansig, and the transfer function of the output layer was the linear function Purelin. The Trainlm function, which had the fastest convergence speed, was selected as the training function.
[0169] Specifically, the BP neural network is trained with eight input parameters (temperature, current, voltage, and power consumption of the CPU and switching chip) and a corresponding output parameter (the fan speed value at the next moment) to obtain an initial BP neural network model.
[0170] In some embodiments of the present application, before step 202, the process also includes: determining the structure of the BP neural network; determining the initial weights and thresholds of the BP neural network based on the structure of the BP neural network; optimizing the initial weights and thresholds using a genetic algorithm to obtain the optimal weights and thresholds of the BP neural network, so as to train the BP neural network based on the optimal weights and thresholds.
[0171] Among them, in view of the shortcomings of a single BP neural network algorithm such as being prone to falling into local minima, this application uses a genetic algorithm to optimize it. During the optimization process, operations are mainly divided into selection, crossover, mutation and other links.
[0172] The genetic algorithm is a parallel random search optimization method proposed by a professor at the University of Michigan in 1962, which simulates natural genetic mechanisms and biological evolution. One of its main features is that it is based on a group search strategy. In the evolutionary search, it basically does not use external information and only uses the objective function, namely the fitness function, as the basis. In the process of genetic evolution, for the phenomenon of immature convergence, efforts should be made to reduce the competitiveness of certain abnormal individuals. This can be achieved by reducing the corresponding fitness value. It is mainly divided into operations such as selection, crossover, and mutation. The genetic algorithm optimizes the BP neural network mainly by determining the initial weights and thresholds of the BP neural network. Among them, the optimal individual of the genetic algorithm, that is, the optimal weights and thresholds of the genetic algorithm, are calculated, and the optimal weights and thresholds are used as the initial weights and thresholds of the BP neural network.
[0173] Specifically, the use of genetic algorithms to optimize the initial weights and thresholds of the BP neural network can be divided into the following two parts: 1. Determine the BP neural network structure, specifically determine the initial weights and thresholds of the BP neural network based on the BP neural network structure (neuron nodes in the input layer, neuron nodes in the hidden layer, and neuron nodes in the output layer); 2. After determining the initial weights and thresholds of the BP neural network, use genetic algorithms to optimize the initial weights and thresholds of the BP neural network to obtain the optimal weights and thresholds of the BP neural network.
[0174] In some embodiments of the present application, a genetic algorithm is used to optimize the initial weights and thresholds to obtain the optimal weights and thresholds of the BP neural network, including: encoding the initial weights and thresholds to form an initial population of the genetic algorithm; performing selection, crossover and mutation operations on the initial population to obtain a candidate population; when the number of operations reaches a preset maximum number of evolutions, decoding the optimal population group in the candidate population to obtain the optimal weights and thresholds of the BP neural network; when the number of operations is less than the preset maximum number of evolutions, using the candidate population as the initial population, and returning to execute the selection, crossover and mutation operations on the initial population.
[0175] Specifically, encoding (binary encoding or real number encoding) is performed according to the initial weights and thresholds to form the initial population of the genetic algorithm. For example, the number of neuron nodes in the input layer of the BP neural network is 8, the number of neuron nodes in the hidden layer is 5, and the number of neuron nodes in the output layer is 1. Then the BP neural network includes 45 initial weights and 6 initial thresholds. Then the 45 initial weights and 6 initial thresholds are encoded, and the individual coding length of the genetic algorithm is 51 to obtain the initial population. Each individual in the population includes all the initial weights and initial thresholds of a network.
[0176] Then, a fitness function is established to perform selection, crossover, mutation and other operations on the initial population, optimize the initial weights and thresholds inside the BP neural network, and obtain the candidate population.
[0177] Determine whether the number of operations has reached the preset maximum number of evolutions. The preset maximum number of evolutions is pre-set, for example, the number of evolutions is 100. When the number of operations is less than the preset maximum number of evolutions, the candidate population is used as the initial population, and the operation of selecting, crossing, and mutation on the initial population is returned.
[0178] When the number of operations reaches the preset maximum number of evolutions, the population with the largest fitness value is selected from all candidate populations as the optimal population group for decoding operation to obtain the optimal weights and thresholds of the BP neural network;
[0179] Among them, for example, in the genetic algorithm optimization weight and threshold part, the number of evolutions can be set to 100. If the population size is set too small, it is difficult to find the optimal solution. If it is set too large, the convergence time is too long. According to experience, it is generally appropriate to take 30-160. In this application, the population size can be set to 50, and each individual in the population contains all the initial weights and initial thresholds of a network. The crossover probability Pc can be 0.4, and the mutation probability can be 0.1.
[0180] After the initial weights and thresholds of the BP neural network are determined by the genetic algorithm, the BP neural network can be trained using the training set to obtain an optimal BP neural network, ie, a fan speed prediction model.
[0181] Step 203: Verify the initial BP neural network model based on the test set to obtain a trained fan speed prediction model.
[0182] Specifically, after the BP neural network is trained using the sample data in the training set to obtain the initial BP neural network, in order to obtain a model with higher prediction accuracy, the trained initial BP neural network needs to be verified. Specifically, the trained initial BP neural network is tested using the test samples in the test set, and the output prediction result is compared with the expected value. When the expected value of the fan speed is basically consistent with the predicted value, as shown in Figure 4, the speed regulation prediction accuracy is high, indicating that a well-trained fan speed prediction model is obtained.
[0183] Referring to Figure 5, there is shown a flowchart of the steps of another fan speed prediction model training method provided in some embodiments of the present application. After initializing the BP neural network, the BP neural network is optimized by a genetic algorithm. Specifically, the initial value of the BP neural network is encoded. For example, when the BP neural network includes 45 weights and 6 thresholds, the individual encoding length of the genetic algorithm is 51. Then, a fitness function is established, and operations such as selection, crossover, and mutation are performed to optimize the internal weights and thresholds of the BP neural network, that is, to obtain the optimal weights and optimal thresholds of the BP neural network. The initial BP neural network is trained according to the training set, the optimal weights and thresholds to obtain the optimal BP neural network. The optimal BP neural network is verified according to the test set. If the verification passes, the fan speed prediction model is obtained.
[0184] In some of the above embodiments, a BP neural network is used to establish a fan speed prediction model and optimize it. A fan speed prediction model based on a genetic algorithm BP neural network is established. On the basis of analyzing and understanding the BP neural network algorithm and the genetic algorithm ideas, a neural network is established. Through actual simulation tests, the model's simulation of the fan speed has the characteristics of small error and stable prediction, providing an effective solution for energy-saving, safe, reliable and stable operation of terminal equipment.
[0185] Moreover, in the BP (GA-BP) neural network model in some embodiments of the present application, the prediction accuracy and stability of the model can be further improved by increasing the types of input parameters and the number of hidden layer nodes.
[0186] 6 , a flowchart of another method for training a fan speed prediction model is shown in some embodiments of the present application. Based on some embodiments shown in FIG1 , the present application mainly describes a method for controlling a fan when the terminal device is in an abnormal operating state. The method in some embodiments of FIG6 may include:
[0187] Step 601: If the operation state of the terminal device is an abnormal operation state, the operation of the fan is controlled based on the abnormal operation state.
[0188] Specifically, the abnormal operating status of the terminal device includes but is not limited to the following: system power-on restart, BMC not started, high temperature test state, abnormal internal temperature of the device, plugging and unplugging fans, plugging and unplugging PSU, CPLD upgrade or failure, BMC hang, etc. According to different abnormal operating states, corresponding control strategies need to be adopted to control the fan speed to better dissipate heat for the terminal device.
[0189] In some embodiments of the present application, the following further includes: if the operating state of the terminal device is abnormal, an alarm signal is output. Specifically, when the operating state of the terminal device is abnormal, an alarm signal needs to be output to the staff / user, for example, by setting an audible and visual alarm on the terminal device to warn the user, or by sending a warning message to the mobile terminal used by the staff / user via a communication component. The specific configuration can be based on actual needs and is not limited in some embodiments of the present application.
[0190] In some embodiments of the present application, the operation of a fan in a terminal device is controlled based on an abnormal operating state, including: if the terminal device is in a high-temperature test state, controlling the fan to run at a first speed; after the high-temperature test phase state, returning to execute the step of detecting the operating state of the terminal device.
[0191] Among them, the first speed in some embodiments of the present application can be the full speed of the fan, or it can be a high speed set as needed (for example, 80% of the full speed). It can be set according to actual needs, and this is not limited in some embodiments of the present application.
[0192] Specifically, as shown in Figure 7, if the terminal device is performing a high temperature test, a high temperature alarm signal will no longer be issued. At the same time, the fan runs at full speed to ensure stable operation of the switch. After the high temperature test is completed, the process returns to the step of detecting the operating status of the terminal device. If it is detected that the operating status of the terminal device is normal operation, the fan operation is controlled according to the conventional speed regulation strategy (fan speed prediction module).
[0193] In some embodiments of the present application, a plurality of temperature sensors are provided in the terminal device, and the operation of the fan in the terminal device is controlled based on the abnormal operating status, including: if there is at least one temperature sensor in the terminal device that detects that the internal temperature of the terminal device is greater than or equal to a first alarm threshold, then the fan is controlled to run at a first speed.
[0194] Specifically, as shown in Figure 8, if any temperature sensor in the terminal device detects that the temperature inside the device reaches or exceeds the maximum alarm threshold (first alarm threshold), a high temperature alarm signal is immediately issued. At the same time, the fan runs at full speed to prevent malfunctions caused by excessive temperature of the terminal device.
[0195] In some embodiments of the present application, it also includes: if the temperature sensor in the terminal device detects that the internal temperature of the terminal device is less than a first alarm threshold, and there is at least one temperature sensor in the terminal device that detects a temperature greater than or equal to a second alarm threshold, then obtaining the operating parameters of the terminal device; wherein the second alarm threshold is less than the first alarm threshold; inputting the operating parameters into a fan speed prediction model to predict the target speed of the fan in the terminal device; and controlling the operation of the fan in the terminal device based on the target speed.
[0196] Specifically, if any temperature sensor in the terminal device detects that the temperature inside the device reaches or exceeds the minimum alarm threshold (the second alarm threshold), and all temperature sensors detect that the temperature inside the device is less than the first alarm threshold, only a high temperature alarm signal is issued, and the fan operation is controlled according to the conventional speed regulation strategy, that is, the operating parameters of the terminal device are obtained, the operating parameters are input into the fan speed prediction model, the target speed of the fan in the terminal device is predicted, and the operation of the fan in the terminal device is controlled based on the target speed.
[0197] In some embodiments of the present application, a switching chip and a CPU are provided in the terminal device, and the operation of a fan in the terminal device is controlled based on an abnormal operating state, including: if the temperature data of at least one temperature sensor located at the switching chip and the CPU in the terminal device is lost and the duration is greater than or equal to a first preset time, then the fan is controlled to run at a first speed.
[0198] Specifically, as shown in FIG9 , if it is detected that the temperature reading of any of the temperature sensors of the internal switching chip or the CPU of the terminal device is lost and the duration is greater than or equal to the first preset time, the fan of the terminal device is immediately adjusted to full speed and an alarm signal is issued to prevent the switching chip or CPU from overheating and causing performance degradation or failure. Once the temperature reading of the above sensor is restored, the process returns to the step of detecting the operating status of the terminal device. If the operating status of the terminal device is normal, the fan operation is controlled according to the conventional speed control strategy (fan speed prediction module).
[0199] In some embodiments of the present application, the operation of a fan in a terminal device is controlled based on an abnormal operating state, including: if the redundant power supply of the terminal device is in an out-of-position state, controlling the fan to operate at a first speed; when the redundant power supply of the terminal device changes from an out-of-position state to an in-position state, controlling the fan to operate at a second speed for a second preset time, and returning to execute the step of detecting the operating state of the terminal device after the second preset time; wherein the second preset speed is less than the first speed.
[0200] Specifically, as shown in Figure 10, if it is detected that the PSU (redundant power supply) of the terminal device is manually unplugged or suddenly lost, the fan immediately runs at full speed. If it is detected that the PSU of the terminal device is reinserted or restored to its original position, the fan immediately runs at a second speed (60% speed, 70% speed of full speed, etc.) for a second preset time (for example, 20 seconds, 30 seconds, etc.), and returns to execute the step of detecting the operating status of the terminal device after the second preset time. If the operating status of the terminal device is normal, the fan operation is controlled according to the conventional speed regulation strategy (fan speed prediction module).
[0201] In some embodiments of the present application, the operation of the fan in the terminal device is controlled based on the abnormal operating status, including: if there is at least one fan in the terminal device that is in an out-of-position state, controlling the fan in the in-position state to run at a first speed; when all fans are in the in-position state, controlling the fan to run at a second preset speed for a second preset time, and returning to execute the step of detecting the operating status of the terminal device after the second preset time; wherein the second preset speed is less than the first speed.
[0202] Specifically, as shown in Figure 11, if it is detected that the fan of the terminal device is manually unplugged or suddenly out of place, the other fans immediately run at full speed to prevent the fan's heat dissipation efficiency from decreasing. If it is detected that the fan of the terminal device is reinserted or restored to its original position, the fan immediately runs at a second speed (60% speed, 70% speed of full speed, etc.) for a second preset time (for example, 20 seconds, 30 seconds, etc.), and returns to execute the step of detecting the operating status of the terminal device after the second preset time. If the operating status of the terminal device is normal, the fan operation is controlled according to the conventional speed regulation strategy (fan speed prediction module).
[0203] In some embodiments of the present application, the operation of a fan in a terminal device is controlled based on an abnormal operating state, including: if fan data in a powered erasable programmable read-only memory in the terminal device is lost, or the system of the terminal device is reset and restarted, the fan is controlled to run at a first speed.
[0204] Specifically, as shown in Figure 12, if it is detected that the fan EEPROM (Electrically Erasable Programmable Read-Only Memory) is lost, or the PSU (Redundant Power Supply) fails, or the system is reset and restarted, the switch fan is immediately adjusted to full speed, and an alarm signal is issued and the fan indicator light keeps flashing.
[0205] In some embodiments of the present application, the operation of a fan in a terminal device is controlled based on an abnormal operating state, including: if a board management controller in the terminal device is hung / failed, or a complex programmable logic device in the terminal device is upgraded / failed online, then the fan is controlled to run at a first speed.
[0206] Specifically, as shown in FIG13 , if it is detected that the BMC (Board Management Controller) is suddenly hung up, fails, or the CPLD (Complex Programmable Logic Device) is upgraded online or fails, the switch fan is immediately adjusted to full speed and an alarm signal is issued.
[0207] In some embodiments of the present application, the operation of a fan in a terminal device is controlled based on an abnormal operating state, including: if there is at least one fan in the terminal device whose rotational speed is less than a third rotational speed and lasts for a third preset time, then the fan in the terminal device is controlled to operate at a first rotational speed; wherein the third rotational speed is less than the first rotational speed.
[0208] The third rotation speed may be the lowest rotation speed of the fan.
[0209] Specifically, as shown in Figure 14, if it is detected that the speed of any fan of the terminal device is less than the third speed and lasts for a third preset time (25 seconds, 30 seconds, etc.), it means that a fan is in a faulty state, so the other fans in the terminal device need to be immediately adjusted to full speed and an alarm signal is issued.
[0210] In some embodiments of the present application, the operation of a fan in a terminal device is controlled based on an abnormal operating status, including: if it is detected that the system of the terminal device is powered on and restarted and the baseboard management controller of the terminal device is not started, then the fan is controlled to run at a fourth speed and the operating status of the baseboard management controller is detected; when the baseboard management controller is started normally, the step of detecting the operating status of the terminal device is returned to execute.
[0211] Specifically, as shown in FIG15 , if it is detected that the system is powered on and restarted and the BMC is not started, the fan runs at the fourth speed (e.g., 50% of the full speed) and the BMC operating status is detected in real time. Once it is detected that the BMC is started normally, the process returns to the step of detecting the operating status of the terminal device. If the operating status of the terminal device is normal, the fan operation is controlled according to the conventional speed regulation strategy (fan speed prediction module).
[0212] In some of the above embodiments, a reasonable fan operation control strategy is formulated to control the fan in the mobile terminal according to the different abnormal operating states of the terminal device, and an appropriate heat dissipation method is provided for different abnormal conditions to achieve effective heat dissipation of the mobile terminal, thereby avoiding as much as possible the terminal device temperature from being too high due to abnormal conditions, resulting in performance degradation or failure of the mobile terminal, and saving energy at the same time.
[0213] In summary, in some embodiments of the present application, the abnormal operation scenarios and normal operation scenarios during the operation of the fan are fully considered, and reasonable fan operation control strategies are formulated for the above two business scenarios respectively.
[0214] To solve the problem of PID speed regulation lag and inaccuracy, the existing PID speed regulation algorithm is abandoned and the GA-BP (genetic-BP neural network) algorithm is adopted. The temperature, current, voltage, power consumption and other information of the main components inside the switch are used as the neural network model input to construct a fan speed prediction model based on the BP neural network. The neural network algorithm is further improved and the genetic algorithm is used to optimize the network weights and thresholds. In this way, a complete fan speed prediction model based on the genetic BP neural network is established. Compared with the use of the PID algorithm alone, the real-time performance and prediction accuracy are higher, and the fan speed can be effectively predicted.
[0215] It should be noted that for the method embodiments, for the sake of simplicity, they are all expressed as a series of action combinations, but those skilled in the art should be aware that some embodiments of the present application are not limited by the order of the actions described, because according to some embodiments of the present application, certain steps can be performed in other orders or simultaneously. Secondly, those skilled in the art should also be aware that some embodiments described in the specification are preferred embodiments, and the actions involved are not necessarily required by the embodiments of the present application.
[0216] 16 shows a block diagram of a fan operation control device provided in some embodiments of the present application. The fan operation control device is applied to a terminal device provided with a fan for heat dissipation, including:
[0217] Status detection module 1601, used to detect the operating status of the terminal device;
[0218] The parameter acquisition module 1602 is configured to acquire the operating parameters of the terminal device if the operating state of the terminal device is a normal operating state;
[0219] The speed prediction module 1603 is used to input the operating parameters into the fan speed prediction model to predict the target speed of the fan; the fan speed prediction model is obtained by training the BP neural network with the historical operating parameters of the terminal device;
[0220] The first operation control module 1604 is configured to control the operation of the fan based on the target rotation speed.
[0221] In some embodiments, further comprising:
[0222] A training set generation module is used to obtain historical operating parameters of terminal devices as training sets and test sets;
[0223] The model training module is used to train the BP neural network based on the training set to obtain the initial BP neural network model;
[0224] The model testing module is used to verify the initial BP neural network model based on the test set to obtain a trained fan speed prediction model.
[0225] In some embodiments, the BP neural network includes: an input layer, a hidden layer, and an output layer. The number of neuron nodes in the input layer is 8, the number of neuron nodes in the hidden layer is 5, and the number of neuron nodes in the output layer is 1.
[0226] In some embodiments, further comprising:
[0227] Structure determination module, used to determine the structure of BP neural network;
[0228] An initial parameter determination module is used to determine the initial weights and thresholds of the BP neural network according to the structure of the BP neural network;
[0229] The model optimization module is used to optimize the initial weights and thresholds using a genetic algorithm to obtain the optimal weights and thresholds of the BP neural network so as to train the BP neural network based on the optimal weights and thresholds.
[0230] In some embodiments, the model optimization module includes:
[0231] A population formation submodule is used to encode according to initial weights and thresholds to form an initial population of the genetic algorithm;
[0232] The population training submodule is used to perform selection, crossover and mutation operations on the initial population to obtain the candidate population;
[0233] The population decoding submodule is used to perform a decoding operation on the optimal population group in the candidate population when the number of operations reaches the preset maximum number of evolutions, so as to obtain the optimal weights and thresholds of the BP neural network;
[0234] The step return execution submodule is used to use the candidate population as the initial population when the number of operations is less than the preset maximum number of evolutions, and return to execute the selection, crossover and mutation operation steps on the initial population.
[0235] In some embodiments, the terminal device is provided with a CPU and a switching chip, and the operating parameters include at least the CPU temperature, CPU current, CPU voltage, CPU power consumption, switching chip temperature, switching chip current, switching chip voltage, switching chip power consumption and fan speed.
[0236] In some embodiments, further comprising:
[0237] The second operation control module is used to control the operation of the fan based on the abnormal operation state if the operation state of the terminal device is an abnormal operation state.
[0238] In some embodiments, further comprising:
[0239] The alarm output module is used to output an alarm signal if the operating status of the terminal device is abnormal.
[0240] In some embodiments, the second operation control module includes:
[0241] an operation control submodule, configured to control the fan to operate at a first speed if the terminal device is in a high temperature test state;
[0242] The step return submodule is used to return to the execution status detection module after the high temperature test phase state.
[0243] In some embodiments, the terminal device is provided with several temperature sensors, and the second operation control module includes:
[0244] The operation control submodule is configured to control the fan to operate at a first speed if at least one temperature sensor in the terminal device detects that the internal temperature of the terminal device is greater than or equal to a first alarm threshold.
[0245] In some embodiments, further comprising:
[0246] a parameter acquisition submodule, configured to acquire operating parameters of the terminal device if the temperature sensors in the terminal device detect that the internal temperature of the terminal device is less than a first alarm threshold, and if at least one temperature sensor in the terminal device detects that the temperature is greater than or equal to a second alarm threshold, wherein the second alarm threshold is less than the first alarm threshold;
[0247] A speed prediction submodule is used to input operating parameters into a fan speed prediction model to predict the target speed of the fan in the terminal device;
[0248] The operation control submodule is used to control the operation of the fan in the terminal device based on the target speed.
[0249] In some embodiments, the terminal device is provided with a switching chip and a CPU, and the second operation control module includes:
[0250] The operation control submodule is used to control the fan to run at a first speed if temperature data of at least one temperature sensor located at the switching chip and CPU position in the terminal device is lost and the duration is greater than or equal to a first preset time.
[0251] In some embodiments, the second operation control module includes:
[0252] An operation control submodule, configured to control the fan to operate at a first speed if the redundant power supply of the terminal device is in a lost state;
[0253] The step returns the submodule, which is used to control the fan to run at a second speed for a second preset time when the redundant power supply of the terminal device changes from an out-of-position state to an in-position state, and return to the execution status detection module after the second preset time; wherein the second preset speed is less than the first speed.
[0254] In some embodiments, the second operation control module includes:
[0255] an operation control submodule, configured to control the fans in the in-position state to operate at a first speed if at least one fan in the terminal device is in an out-of-position state;
[0256] The step returns to the execution submodule, which is used to control the fans to run at a second preset speed for a second preset time when all fans are in the in-place state, and return to the execution step of detecting the operating status of the terminal device after the second preset time; wherein the second preset speed is less than the first speed.
[0257] In some embodiments, the second operation control module includes:
[0258] The operation control submodule is used to control the fan to run at a first speed if the fan data in the electrically erasable programmable read-only memory in the terminal device is lost or the system of the terminal device is reset and restarted.
[0259] In some embodiments, the second operation control module includes:
[0260] The operation control submodule is used to control the fan to run at a first speed if the board management controller in the terminal device is suspended / failed, or the complex programmable logic device in the terminal device is upgraded online / failed.
[0261] In some embodiments, the second operation control module includes:
[0262] The operation control submodule is used to control the fan in the terminal device to run at the first speed if the speed of at least one fan in the terminal device is less than the third speed and lasts for a third preset time; wherein the third speed is less than the first speed.
[0263] In some embodiments, the second operation control module includes:
[0264] an operation control submodule, configured to control the fan to operate at a fourth speed and detect an operating state of the baseboard management controller if it is detected that the system of the terminal device is powered on and restarted and the baseboard management controller of the terminal device is not started;
[0265] The step returns to the execution submodule, which is used to return to the step of detecting the operating status of the terminal device when the baseboard management controller starts normally.
[0266] In some embodiments, the first rotational speed is the full rotational speed of the fan.
[0267] As for the device embodiment, since it is basically similar to the method embodiment, the description is relatively simple, and the relevant parts can be referred to the partial description of the method embodiment.
[0268] In addition, some embodiments of the present application also provide an electronic device, including: a processor, a memory, and a computer program stored in the memory and runnable on the processor. When the computer program is executed by the processor, the various processes of the above-mentioned data acquisition method embodiment are implemented and the same technical effect can be achieved. To avoid repetition, it will not be repeated here.
[0269] The present application also provides a non-volatile readable storage medium, which stores a computer program. When the computer program is executed by a processor, each process of the above-mentioned data acquisition method embodiment is implemented, and the same technical effect is achieved. To avoid repetition, it is not described here. The non-volatile readable storage medium is, for example, a read-only memory (ROM), a random access memory (RAM), a magnetic disk, or an optical disk.
[0270] FIG17 is a schematic diagram of the hardware structure of an electronic device implementing some embodiments of the present application.
[0271] The electronic device 1700 includes but is not limited to components such as a radio frequency unit 1701, a network module 1702, an audio output unit 1703, an input unit 1704, a sensor 1705, a display unit 1706, a user input unit 1707, an interface unit 1708, a memory 1709, a processor 1710, and a power supply 1711. Those skilled in the art will appreciate that the electronic device structure shown in FIG17 does not constitute a limitation on the electronic device, and the electronic device may include more or fewer components than shown, or combine certain components, or arrange the components differently. In the embodiments of the present application, the electronic device includes but is not limited to a mobile phone, a tablet computer, a laptop computer, a PDA, a vehicle-mounted terminal, a wearable device, and a pedometer.
[0272] It should be understood that in some embodiments of the present application, RF unit 1701 may be used to receive and transmit signals during information transmission or calls. Specifically, it receives downlink data from the base station and transmits it to processor 1710 for processing; in addition, it transmits uplink data to the base station. Generally, RF unit 1701 includes, but is not limited to, an antenna, at least one amplifier, a transceiver, a coupler, a low-noise amplifier, a duplexer, and the like. Furthermore, RF unit 1701 may communicate with the network and other devices via a wireless communication system.
[0273] The electronic device provides users with wireless broadband Internet access through the network module 1702, such as helping users to send and receive emails, browse web pages, and access streaming media.
[0274] The audio output unit 1703 can convert audio data received by the RF unit 1701 or the network module 1702 or stored in the memory 1709 into an audio signal and output it as sound. In addition, the audio output unit 1703 can also provide audio output related to a specific function performed by the electronic device 1700 (for example, a call signal reception sound, a message reception sound, etc.). The audio output unit 1703 includes a speaker, a buzzer, a receiver, etc.
[0275] Input unit 1704 is used to receive audio or video signals. Input unit 1704 may include a graphics processing unit (GPU) 17041 and a microphone 17042. The GPU 17041 processes image data of still images or videos obtained by an image capture device (such as a camera) in video capture mode or image capture mode. The processed image frames can be displayed on display unit 1706. The image frames processed by the GPU 17041 can be stored in memory 1709 (or other non-volatile readable storage medium) or transmitted via the RF unit 1701 or network module 1702. Microphone 17042 can receive sound and process such sound into audio data. In telephone call mode, the processed audio data can be converted into a format that can be transmitted to a mobile communication base station via the RF unit 1701 for output.
[0276] The electronic device 1700 also includes at least one sensor 1705, such as a light sensor, a motion sensor, and other sensors. Specifically, the light sensor includes an ambient light sensor and a proximity sensor, wherein the ambient light sensor can adjust the brightness of the display panel 17061 according to the brightness of the ambient light, and the proximity sensor can turn off the display panel 17061 and / or the backlight when the electronic device 1700 is moved to the ear. As a type of motion sensor, the accelerometer sensor can detect the magnitude of acceleration in all directions (generally three axes), and can detect the magnitude and direction of gravity when stationary. It can be used to identify the posture of the electronic device (such as horizontal and vertical screen switching, related games, magnetometer posture calibration), vibration recognition related functions (such as pedometer, tapping), etc.; the sensor 1705 can also include a fingerprint sensor, a pressure sensor, an iris sensor, a molecular sensor, a gyroscope, a barometer, a hygrometer, a thermometer, an infrared sensor, etc., which will not be repeated here.
[0277] The display unit 1706 is used to display information input by the user or information provided to the user. The display unit 1706 may include a display panel 17061, which may be configured in the form of a liquid crystal display (LCD), an organic light-emitting diode (OLED), or the like.
[0278] The user input unit 1707 can be used to receive input digital or character information, and to generate key signal input related to the user settings and function control of the electronic device. Specifically, the user input unit 1707 includes a touch panel 17071 and other input devices 17072. The touch panel 17071, also known as a touch screen, can collect user touch operations on or near it (such as operations performed by the user using any suitable object or accessory such as a finger, stylus, etc. on or near the touch panel 17071). The touch panel 17071 may include two parts: a touch detection device and a touch controller. Among them, the touch detection device detects the user's touch direction and detects the signal caused by the touch operation, and transmits the signal to the touch controller; the touch controller receives the touch information from the touch detection device and converts it into touch point coordinates, which are then sent to the processor 1710, which receives and executes the command sent by the processor 1710. In addition, the touch panel 17071 can be implemented using various types such as resistive, capacitive, infrared, and surface acoustic wave. In addition to the touch panel 17071, the user input unit 1707 may further include other input devices 17072. Specifically, the other input devices 17072 may include but are not limited to a physical keyboard, function keys (such as volume control keys, switch keys, etc.), a trackball, a mouse, and an operating stick, which will not be described in detail here.
[0279] Furthermore, the touch panel 17071 may be overlaid on the display panel 17061. When the touch panel 17071 detects a touch operation on or near the touch panel 17071, the touch operation is transmitted to the processor 1710 to determine the type of touch event. The processor 1710 then provides a corresponding visual output on the display panel 17061 based on the type of touch event. Although in FIG17 , the touch panel 17071 and the display panel 17061 are two independent components to implement the input and output functions of the electronic device, in some embodiments, the touch panel 17071 and the display panel 17061 may be integrated to implement the input and output functions of the electronic device, which is not limited to this specific embodiment.
[0280] The interface unit 1708 is an interface for connecting an external device to the electronic device 1700. For example, the external device may include a wired or wireless headset port, an external power supply (or battery charger) port, a wired or wireless data port, a memory card port, a port for connecting a device with an identification module, an audio input / output (I / O) port, a video I / O port, a headphone port, etc. The interface unit 1707 may be used to receive input (e.g., data information, power, etc.) from an external device and transmit the received input to one or more elements within the electronic device 1700, or may be used to transmit data between the electronic device 1700 and an external device.
[0281] Memory 1709 can be used to store software programs and various data. Memory 1709 may primarily include a program storage area and a data storage area. The program storage area may store an operating system and at least one application required for a function (such as a sound playback function or an image playback function); the data storage area may store data generated based on the use of the phone (such as audio data, a phone book, etc.). Furthermore, memory 1709 may include high-speed random access memory and non-volatile memory, such as at least one disk storage device, flash memory device, or other volatile solid-state storage device.
[0282] Processor 1710 is the control center of the electronic device, connecting the various components of the entire electronic device using various interfaces and lines. By running or executing software programs and / or modules stored in memory 1709 and accessing data stored in memory 1709, it performs various functions of the electronic device and processes data, thereby monitoring the entire electronic device. Processor 1710 may include one or more processing units; preferably, processor 1710 may integrate an application processor and a modem processor, wherein the application processor primarily processes the operating system, user interface, and application programs, while the modem processor primarily handles wireless communications. It is understood that the modem processor may not be integrated into processor 1710.
[0283] The electronic device 1700 may also include a power supply 1711 (such as a battery) to supply power to each component. Preferably, the power supply 1711 may be logically connected to the processor 1710 through a power management system, thereby enabling the power management system to manage functions such as charging, discharging, and power consumption.
[0284] In addition, the electronic device 1700 includes some functional modules not shown, which will not be described here.
[0285] Some embodiments of the present application also provide a non-volatile readable storage medium, as shown in FIG18 , on which a computer program 1801 is stored. When the computer program 1801 is executed by the processor, each process of the above-mentioned data acquisition method embodiment is implemented, and the same technical effect is achieved. To avoid repetition, the above description is omitted. The non-volatile readable storage medium may be a read-only memory (ROM), a random access memory (RAM), a magnetic disk, or an optical disk.
[0286] It should be noted that, in this document, the terms "comprises," "includes," or any other variations thereof are intended to encompass non-exclusive inclusion, such that a process, method, article, or apparatus comprising a series of elements includes not only those elements but also other elements not explicitly listed, or elements inherent to such process, method, article, or apparatus. In the absence of further limitations, an element defined by the phrase "comprising a ..." does not exclude the presence of other identical elements in the process, method, article, or apparatus comprising the element.
[0287] Through the description of the above implementation methods, those skilled in the art can clearly understand that some of the above-mentioned embodiment methods can be implemented by means of software plus the necessary general hardware platform, and of course can also be implemented by hardware, but in many cases the former is a better implementation method. Based on this understanding, the technical solution of the present application is essentially or the part that contributes to the prior art can be embodied in the form of a software product, which is stored in a non-volatile readable storage medium (such as ROM / RAM, magnetic disk, optical disk), including a number of instructions for enabling a terminal (which can be a mobile phone, computer, resource server, air conditioner, or network device, etc.) to execute the methods of some embodiments of the present application.
[0288] The embodiments of the present application are described above in conjunction with the accompanying drawings, but the present application is not limited to the above-mentioned specific implementation methods. The above-mentioned specific implementation methods are merely illustrative and not restrictive. Under the guidance of this application, ordinary technicians in this field can also make many forms without departing from the purpose of this application and the scope of protection of the claims, all of which are within the protection of this application.
[0289] Those skilled in the art will appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed in the embodiments of this application can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professional and technical personnel can use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of this application.
[0290] Those skilled in the art will clearly understand that, for the convenience and brevity of description, the specific working processes of the systems, devices and units described above can refer to the corresponding processes in the aforementioned method embodiments and will not be repeated here.
[0291] In the embodiments provided in this application, it should be understood that the disclosed devices and methods can be implemented in other ways. For example, the device embodiments described above are merely schematic. For example, the division of units is only a logical function division. In actual implementation, there may be other division methods, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms.
[0292] Units described as separate components may or may not be physically separate, and components shown as units may or may not be physical units, that is, they may be located in one place or distributed across multiple network units. Some or all of these units may be selected to achieve the purpose of this embodiment according to actual needs.
[0293] In addition, each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit.
[0294] If the function is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a non-volatile readable storage medium. Based on this understanding, the technical solution of the present application, or the part that contributes to the prior art, or the part of the technical solution, can be embodied in the form of a software product. The computer software product is stored in a non-volatile readable storage medium, including a number of instructions for enabling a computer device (which can be a personal computer, a resource server, or a network device, etc.) to execute all or part of the steps of some embodiments of the present application. The aforementioned non-volatile readable storage medium includes: various media that can store program codes, such as USB flash drives, mobile hard drives, ROM, RAM, magnetic disks or optical disks.
[0295] The above are only specific embodiments of the present application, but the scope of protection of this application is not limited thereto. Any changes or substitutions that can be easily conceived by a person skilled in the art within the technical scope disclosed in this application should be included in the scope of protection of this application. Therefore, the scope of protection of this application should be based on the scope of protection of the claims.
Claims
1. A fan operation control method, characterized in that: Applied to a terminal device, the terminal device is provided with a fan for heat dissipation, and the method comprises: Detecting the operating status of the terminal device; If the operating state of the terminal device is a normal operating state, obtaining the operating parameters of the terminal device; Inputting the operating parameters into a fan speed prediction model to predict the target speed of the fan; the fan speed prediction model is obtained by training a BP neural network with the historical operating parameters of the terminal device; The operation of the fan is controlled based on the target rotation speed.
2. The method according to claim 1, characterized in that Before inputting the operating parameters into the fan speed prediction model, the method further includes: Acquire historical operating parameters of the terminal device as a training set and a test set; Training the BP neural network according to the training set to obtain an initial BP neural network model; The initial BP neural network model is verified according to the test set to obtain a trained fan speed prediction model.
3. The method according to claim 1, characterized in that The BP neural network comprises: an input layer, a hidden layer and an output layer. The number of neuron nodes in the input layer is 8, the number of neuron nodes in the hidden layer is 5, and the number of neuron nodes in the output layer is 1.
4. The method according to claim 1, characterized in that: Before training the BP neural network according to the training set to obtain the initial BP neural network model, the method further includes: Determine the structure of the BP neural network; Determining the initial weight and threshold of the BP neural network according to the structure of the BP neural network; The initial weights and thresholds are optimized by using a genetic algorithm to obtain the optimal weights and thresholds of the BP neural network, so as to train the BP neural network based on the optimal weights and thresholds.
5. The method according to claim 4, characterized in that The method of optimizing the initial weights and thresholds by using a genetic algorithm to obtain the optimal weights and thresholds of the BP neural network includes: Encoding according to the initial weights and thresholds to form an initial population of the genetic algorithm; Performing selection, crossover and mutation operations on the initial population to obtain a candidate population; When the number of operations reaches the preset maximum number of evolutions, the optimal population group in the candidate population is decoded to obtain the optimal weight and threshold of the BP neural network; when the number of operations is less than the preset maximum number of evolutions, the candidate population is used as the initial population, and the steps of selecting, crossing over and mutating the initial population are returned to be executed.
6. The method according to claim 1, characterized in that The terminal device is provided with a CPU and a switching chip, and the operating parameters include at least the temperature of the CPU, the current of the CPU, the voltage of the CPU, the power consumption of the CPU, the temperature of the switching chip, the current of the switching chip, the voltage of the switching chip, the power consumption of the switching chip and the speed of the fan.
7. The method according to claim 1, characterized in that After detecting the operating status of the terminal device, the method further includes: If the operation state of the terminal device is an abnormal operation state, the operation of the fan is controlled based on the abnormal operation state.
8. The method according to claim 7, characterized in that Also includes: If the operating state of the terminal device is an abnormal operating state, an alarm signal is output.
9. The method according to claim 7, characterized in that: The controlling the operation of the fan in the terminal device based on the abnormal operation state includes: If the terminal device is in a high temperature test state, controlling the fan to run at a first speed; After the high temperature test phase state, return to execute the step of detecting the operating state of the terminal device.
10. The method according to claim 7, characterized in that The terminal device is provided with a temperature sensor, and the controlling the operation of a fan in the terminal device based on the abnormal operation state includes: If at least one temperature sensor in the terminal device detects that the internal temperature of the terminal device is greater than or equal to a first alarm threshold, the fan is controlled to run at a first speed.
11. The method according to claim 10, characterized in that Also includes: If the temperature sensor in the terminal device detects that the internal temperature of the terminal device is less than the first alarm threshold, and at least one temperature sensor in the terminal device detects that the temperature is greater than or equal to the second alarm threshold, then obtaining the operating parameters of the terminal device; wherein the second alarm threshold is less than the first alarm threshold; Inputting the operating parameters into a fan speed prediction model to predict a target speed of the fan in the terminal device; The operation of the fan in the terminal device is controlled based on the target rotation speed.
12. The method according to claim 10, characterized in that The terminal device is provided with a switching chip and a CPU, and the controlling the operation of a fan in the terminal device based on the abnormal operation state includes: If temperature data of at least one of the temperature sensors located at the switching chip and the CPU in the terminal device is lost and the duration is greater than or equal to a first preset time, the fan is controlled to run at a first speed.
13. The method according to claim 7, characterized in that The controlling the operation of the fan in the terminal device based on the abnormal operation state includes: If the redundant power supply of the terminal device is in a lost state, controlling the fan to run at a first speed; When the redundant power supply of the terminal device changes from the out-of-position state to the in-position state, the fan is controlled to run at a second speed for a second preset time, and returns to execute the step of detecting the operating status of the terminal device after the second preset time; wherein the second preset speed is less than the first speed.
14. The method according to claim 7, characterized in that The controlling the operation of the fan in the terminal device based on the abnormal operation state includes: If at least one of the fans in the terminal device is in an out-of-position state, controlling the fan in the in-position state to run at a first speed; When the fans are all in the on-position state, the fans are controlled to run at a second preset speed for a second preset time, and after the second preset time, the step of returning to execute the step of detecting the operating status of the terminal device is performed; wherein the second preset speed is less than the first speed.
15. The method according to claim 7, characterized in that The controlling the operation of the fan in the terminal device based on the abnormal operation state includes: If the fan data in the electrically erasable programmable read-only memory in the terminal device is lost, or the system of the terminal device is reset and restarted, the fan is controlled to run at the first speed.
16. The method according to claim 7, characterized in that The controlling the operation of the fan in the terminal device based on the abnormal operation state includes: If the board management controller in the terminal device is hung up / failed, or the complex programmable logic device in the terminal device is upgraded online / failed, the fan is controlled to run at a first speed.
17. The method according to claim 7, characterized in that The controlling the operation of the fan in the terminal device based on the abnormal operation state includes: If there is at least one fan in the terminal device whose rotation speed is less than a third rotation speed and lasts for a third preset time, the fan in the terminal device is controlled to run at a first rotation speed; wherein the third rotation speed is less than the first rotation speed.
18. The method according to claim 7, characterized in that The controlling the operation of the fan in the terminal device based on the abnormal operation state includes: If it is detected that the system of the terminal device is powered on and restarted and the baseboard management controller of the terminal device is not started, controlling the fan to run at a fourth speed and detecting the running state of the baseboard management controller; When the baseboard management controller starts normally, the process returns to executing the step of detecting the operating status of the terminal device.
19. The method according to any one of claims 9-10, 12-17, characterized in that: The first rotation speed is the full rotation speed of the fan.
20. A fan operation control device, characterized in that: Applied to a terminal device, the terminal device is provided with a fan for heat dissipation, including: A status detection module, used to detect the operating status of the terminal device; A parameter acquisition module, used for acquiring the operating parameters of the terminal device if the operating state of the terminal device is a normal operating state; A speed prediction module, used for inputting the operating parameters into a fan speed prediction model to predict the target speed of the fan; the fan speed prediction model is obtained by training a BP neural network with the historical operating parameters of the terminal device; An operation control module is used to control the operation of the fan based on the target rotation speed.
21. An electronic device, characterized in that: It includes a processor, a communication interface, a memory and a communication bus, wherein the processor, the communication interface and the memory communicate with each other through the communication bus; The memory is used to store computer programs; The processor is used to implement the method according to any one of claims 1 to 19 when executing the program stored in the memory.
22. A non-volatile readable storage medium, characterized in that: Instructions are stored thereon, which, when executed by one or more processors, cause the processors to perform the method according to any one of claims 1 to 19.
Citation Information
Patent Citations
Method, device, medium and apparatus for controlling fan cooling group of storage server
CN109375750A
Energy-saving optimal control method and system of engine electric control silicone oil fan
CN109779736A
Fan control method and device, electronic equipment and storage medium
CN111580626A
Cluster centralized heat dissipation regulation and control system and method
CN114002952A
Self-adaptive adjustment control method for cooling system of engine of tracked vehicle in plateau environment
CN114320560A
Cited By
Electric control cabinet air cooling control method and system and storage medium
CN118804571A
Power supply test method and device, storage medium, electronic equipment and program product
CN119291555A
Baseboard management controller starting method and device, electronic equipment and storage medium
CN119690530A
Server heat dissipation control method and device, electronic equipment and storage medium
CN120447699A
Embedded micro-channel heat dissipation system oriented to SIP (Session Initiation Protocol) packaging and collaborative heat management method
CN120709241A
