Temperature method, electronic device, and storage medium
Patent Information
- Application Number
- CN202610417401.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-03-31
- Publication Date
- 2026-10-16
AI Technical Summary
[0002]当前手机设计性能要求越来越高,发热也越来越高,对于手机温度,用户在不同环境温度下(如冬天和夏天)对于同样手机温度的感受是不同的,在低环温下用户对温度的感受不敏感,若是考虑到环境温度实现的温控策略也会更加准确,但目前环境温度的识别主要依靠天气预报、温度计等,前者无法识别室内温度,后者无法保证被手机实时读取成功,而如果手机本身能够识别环境温度,将会使依靠环温识别来进行温控的设想成为现实
Smart Images

Figure CN122933815A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of temperature prediction technology, and in particular to a temperature prediction method, electronic device and storage medium. Background Technology
[0002] With increasingly demanding performance requirements in mobile phone design, the amount of heat generated is also increasing. Users perceive the same phone temperature differently under varying ambient temperatures (such as winter and summer). In low ambient temperatures, users are less sensitive to temperature changes. Temperature control strategies that take ambient temperature into account would be more accurate. However, current ambient temperature recognition relies mainly on weather forecasts and thermometers. The former cannot accurately detect indoor temperatures, and the latter cannot guarantee that the phone will be able to read the temperature in real time. If the phone itself could recognize ambient temperature, the idea of using ambient temperature recognition for temperature control would become a reality. Summary of the Invention
[0003] This application provides a temperature prediction method, an electronic device, and a storage medium.
[0004] The technical solution of this application embodiment is implemented as follows: This application provides a temperature prediction method, the method including: Monitor the power consumption sequence corresponding to each application running on the electronic device, as well as the multiple temperature sequences corresponding to multiple temperature sensors on the electronic device; Based on multiple temperature value sequences and power consumption sequences, a data model relating power consumption, device surface temperature, and ambient temperature is constructed. The system acquires multiple operating temperature sequences and operating power consumption sequences from multiple temperature sensors when an electronic device runs at least one application within a preset time period, and determines the ambient temperature corresponding to the multiple operating temperature sequences and operating power consumption sequences based on a relational data model.
[0005] This application provides a temperature prediction device, including: The monitoring module is used to monitor the power consumption sequence corresponding to each application running on the electronic device, as well as the multiple temperature sequences corresponding to multiple temperature sensors on the electronic device. The building module is used to construct a data model relating power consumption, device surface temperature, and ambient temperature based on multiple temperature value sequences and power consumption sequences. The determination module is used to acquire multiple operating temperature sequences and operating power consumption sequences from multiple temperature sensors when an electronic device runs at least one application within a preset time period, and to determine the ambient temperature corresponding to the multiple operating temperature sequences and operating power consumption sequences based on a relational data model.
[0006] This application provides an electronic device, including: a processor, a memory, and a communication bus; A communication bus is used to establish communication connections between the processor and memory. The processor executes computer programs stored in memory to: monitor power consumption sequences corresponding to various applications running on the electronic device, and multiple temperature sequences corresponding to multiple temperature sensors on the electronic device; construct a relational data model of power consumption, device surface temperature, and ambient temperature based on the multiple temperature sequences and power consumption sequences; acquire multiple operating temperature sequences and operating power consumption sequences of multiple temperature sensors when the electronic device runs at least one application in a second preset time period, and determine the ambient temperature corresponding to the multiple operating temperature sequences and operating power consumption sequences based on the relational data model.
[0007] This application provides a computer-readable storage medium storing a computer program or computer-executable instructions for implementing the temperature prediction method provided in this application when executed by a processor.
[0008] This application provides a computer program product, including a computer program or computer-executable instructions. When the computer program or computer-executable instructions are executed by a processor, they implement the temperature prediction method provided in this application. Attached Figure Description
[0009] Figure 1 This is a schematic flowchart of a temperature prediction method provided in an embodiment of this application; Figure 2 This is a schematic diagram of an input data format provided in an embodiment of this application; Figure 3 This is an exemplary flowchart illustrating the process of determining temperature rise, provided in an embodiment of this application. Figure 4 This is an exemplary flowchart of determining ambient temperature provided in an embodiment of this application. Figure 1 ; Figure 5 This is an exemplary flowchart of determining ambient temperature provided in an embodiment of this application. Figure 2 ; Figure 6 This is an exemplary flowchart of determining ambient temperature provided in an embodiment of this application. Figure 3 ; Figure 7 This is a schematic diagram of an exemplary memory network structure provided in an embodiment of this application; Figure 8 This is an exemplary flowchart of generating hidden output states provided in an embodiment of this application; Figure 9 This is a schematic diagram illustrating an exemplary process for obtaining a relational data model, provided in an embodiment of this application. Figure 10 This is a schematic diagram illustrating an exemplary model training process provided in an embodiment of this application; Figure 11 This is an exemplary flowchart illustrating the prediction of ambient temperature provided in an embodiment of this application; Figure 12 This is an exemplary schematic diagram comparing the target ambient temperature with the predicted ambient temperature, provided in an embodiment of this application. Figure 13 This is an exemplary flowchart of determining ambient temperature provided in an embodiment of this application. Figure 4 ; Figure 14 This is a schematic diagram illustrating an exemplary process for determining a temperature control strategy, provided in an embodiment of this application. Figure 15 This is an exemplary illustration of how illuminance values change with the angle of sunlight, provided in an embodiment of this application. Figure 1 ; Figure 16 This is an exemplary illustration of how illuminance values change with the angle of sunlight, provided in an embodiment of this application. Figure 2 ; Figure 17 This is a schematic diagram of an exemplary auxiliary light illuminance value provided in an embodiment of this application; Figure 18 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this application. Figure 1 ; Figure 19 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this application. Figure 2 . Detailed Implementation
[0010] To make the objectives, technical solutions, and advantages of this application clearer, the application will be further described in detail below with reference to the accompanying drawings. The described embodiments should not be regarded as limitations on this application. All other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this application.
[0011] With increasingly demanding performance requirements in mobile phone design, heat generation is also rising. Providing better heat dissipation is a key challenge. Manufacturers are striving to develop optimal hardware cooling solutions for a better user experience, but the effectiveness of these solutions is limited by factors such as the phone's size and structural design. Besides hardware cooling, software strategies are also a crucial means of improving user experience.
[0012] Current temperature control strategies generally limit the CPU, GPU, and charging strategies based on the phone's temperature. However, in reality, users perceive the same phone temperature differently under different ambient temperatures. In low ambient temperatures, users are less sensitive to temperature. In such cases, blindly pursuing a low phone temperature at the expense of performance loss is counterproductive. Therefore, ambient temperature should be considered as a dimension in temperature control strategies.
[0013] This application provides a temperature prediction method, such as... Figure 1 As shown, the process includes the following steps S101 to S103: Step S101: Monitor the power consumption sequence corresponding to each application running on the electronic device, as well as the multiple temperature sequences corresponding to multiple temperature sensors on the electronic device.
[0014] In the embodiments of this application, the electronic device is a device with temperature prediction function. Exemplary electronic devices may be mobile phones, tablets, laptops, handheld computers, personal digital assistants (PDAs), desktop computers, etc. The exemplary electronic devices are not limited here.
[0015] In embodiments of this application, the electronic device can monitor the power consumption sequence of each application running on it, as well as multiple temperature sequences corresponding to multiple temperature sensors on the electronic device. For example, the electronic device has N applications; for each application running, the electronic device records the corresponding power consumption sequence and multiple temperature value sequences corresponding to multiple sensors on the electronic device.
[0016] In embodiments of this application, the electronic device has multiple temperature sensors, such as Figure 2 As shown, the data of various temperature sensors (ntc) and power consumption at different times are displayed during the process of different applications (APP) from the start of operation to the basic stabilization under different temperatures. For example, the temperature or thermal sensor readings of different components (xog-therm, conn-therm, schg-therm, spk1-therm, chg-therm)21, time22, and power consumption23.
[0017] For example, for application A, the temperature or thermal sensor readings of different components on the electronic device at different temperatures, as well as the power consumption, will be collected during a certain period of time when application A is running.
[0018] In this way, the electronic device can obtain the power consumption sequence and multiple temperature sequences corresponding to each of the multiple applications on the electronic device.
[0019] Step S102: Based on multiple temperature value sequences and power consumption sequences, construct a data model relating power consumption, device surface temperature, and ambient temperature.
[0020] In the embodiments of this application, when an electronic device acquires the power consumption sequence and multiple temperature sequences corresponding to each of multiple applications on the electronic device, it combines the power consumption sequence and multiple temperature sequences corresponding to each application into a data entry. The format of each data entry can be [T1, P1 T2, P2 … T50, P50], where T1 represents the 49 values (aoss-0, cpuss-1, cpu-1-0-0, …, spk1-therm, chg-therm) at time t1, and P1 represents the power value at time t1. Note that the number of temperature sensors stored may vary across different electronic devices, resulting in either more than 49 values or fewer than 49 values.
[0021] In the embodiments of this application, the label value of each data point is the corresponding real ambient temperature value. After processing all the data into data points in the above format, each data point is preprocessed, including calculating the mean and standard deviation of each feature (ntc, power), and standardizing it so that the variance of the dataset is 1 and the mean is 0, so as to eliminate the influence of the units and accelerate the convergence of the model to obtain the relational data model.
[0022] In the embodiments of this application, under the condition of using an electronic device and without considering external heat sources, the temperature rise caused by the power consumption of the APP can be considered to be equal to the difference between the surface temperature of the phone and the ambient temperature. For example, as... Figure 3 As shown, the ambient temperature is the temperature rise caused by the measured temperature and the power consumption of the APP. The temperature rise caused by the power consumption of the APP can be obtained based on the artificial intelligence model 31, that is, the relational data model.
[0023] In the embodiments of this application, when the electronic device (mobile phone) is in use, the temperature (temperature value sequence) of the internal sensor of the mobile phone and the current and voltage data (power consumption sequence) are obtained by actual measurement under various ambient temperatures. The artificial intelligence model is then used to automatically calculate the surface temperature of the mobile phone and the power consumption of various APPs. The database of the relationship between the three is obtained through AI learning, that is, a relationship data model (artificial intelligence model) of power consumption, device surface temperature and ambient temperature is constructed.
[0024] Step S103: Obtain multiple operating temperature sequences and operating power consumption sequences from multiple temperature sensors when the electronic device runs at least one application within a preset time period, and determine the ambient temperature corresponding to the multiple operating temperature sequences and operating power consumption sequences based on the relational data model.
[0025] In embodiments of this application, the relational data model implicitly contains the relationship between power consumption, device surface temperature, and ambient temperature, so that when multiple operating temperature sequences and operating power consumption sequences of multiple temperature sensors are obtained when an electronic device is running at least one application, the corresponding ambient temperature can be determined.
[0026] In the embodiments of this application, when a user is running any APP, the electronic device (e.g., a mobile phone) automatically acquires the temperature (multiple operating temperature sequences) and current and voltage data (operating power consumption sequences) of the internal sensors to calculate the current surface temperature of the mobile phone and the power consumption of the APP. Then, by comparing the information in the AI database, it obtains the current ambient temperature of the user.
[0027] In the embodiments of this application, the preset time period can be 1 minute, 2 minutes or other time periods. Then, the multiple operating temperature sequences and operating power consumption sequences are the data sequences corresponding to the preset time periods.
[0028] like Figure 4 As shown, a flowchart of an exemplary temperature prediction method is provided, including steps S401 to S409: Step S401: Monitor the application.
[0029] Here, the electronic device begins to monitor the logs of different applications running.
[0030] Step S402: Obtain the sensor temperature, current, and voltage under different ambient temperatures.
[0031] Here, the electronic device obtains sensor temperature, current, and voltage data (power consumption data) corresponding to different ambient temperatures from the log.
[0032] Step S403: Calculate the surface temperature and power consumption of the mobile phone.
[0033] Here, based on the data obtained in step S402 above, the surface temperature and power consumption of the mobile phone are calculated.
[0034] Step S404: Obtain a database relating application power consumption, phone surface temperature, and ambient temperature.
[0035] Here, the electronic device establishes a database relating application power consumption, phone surface temperature, and ambient temperature based on the calculated phone surface temperature and power consumption.
[0036] Step S405: The user uses the application.
[0037] Here, the user obtains runtime logs when using the application on their electronic device.
[0038] Step S406: Obtain the current sensor temperature, current, and voltage data.
[0039] Here, the electronic device obtains sensor temperature, current, and voltage data corresponding to at least one running program from the operation log.
[0040] Step S407: Calculate the current surface temperature and power consumption of the mobile phone.
[0041] Here, based on the data obtained in step S406 above, the current surface temperature and power consumption of the mobile phone are calculated.
[0042] Step S408: Input the current mobile phone surface temperature and power consumption into the database relating application running power consumption, mobile phone surface temperature and ambient temperature.
[0043] Here, the electronic device inputs the calculated current phone surface temperature and power consumption into a relational database of application running power consumption, phone surface temperature, and ambient temperature.
[0044] Step S409, Ambient temperature.
[0045] Here, electronic devices can directly obtain the ambient temperature.
[0046] The steps S403, S404, S407 to S409 mentioned above are all steps performed in the artificial intelligence model.
[0047] In this way, the ambient temperature of an electronic device can be predicted based on the temperature rise caused by the operation of the application, enabling the electronic device to obtain the ambient temperature and increasing the possibility of temperature prediction.
[0048] In some embodiments, the electronic device may further perform the following steps: in response to the electronic device being in a non-operating state, determining the device surface temperature of the electronic device based on multiple temperatures from multiple temperature sensors, and determining the device surface temperature as the ambient temperature of the environment in which the electronic device is currently located.
[0049] In the embodiments of this application, if the surface temperature of an electronic device (such as a mobile phone) is approximately equal to the ambient temperature after the screen is off and the device is left in standby mode without charging for a certain period of time, then when the electronic device is not in operation, the surface temperature of the electronic device can be determined directly based on the multiple temperatures of multiple temperature sensors, and the surface temperature of the device can be determined as the ambient temperature of the environment in which the electronic device is currently located.
[0050] In the embodiments of this application, the artificial intelligence model can also determine the surface temperature of the electronic device based on multiple temperatures from multiple temperature sensors. If the application is not running at this time, there is no need to compare the relational data model, and the device surface temperature can be directly output as the ambient temperature.
[0051] In some embodiments, the electronic device may also perform the following steps: in response to the electronic device being in operation, determining the ambient temperature corresponding to multiple operating temperature sequences and operating power consumption sequences based on a relational data model.
[0052] In the embodiments of this application, when an electronic device (e.g., a mobile phone) is in use (in operation), without considering external heat sources, it can be basically assumed that the surface temperature of the mobile phone minus the temperature rise caused by the power consumption of the APP is equal to the ambient temperature. At this time, the ambient temperature corresponding to multiple operating temperature sequences and operating power consumption sequences can be determined based on the relational data model, because the relational data model involves the relationship between power consumption, device surface temperature, and ambient temperature.
[0053] In the embodiments of this application, if the temperature rise is caused by the power consumption of the APP, the artificial intelligence model infers the temperature rise caused by the power consumption of the APP based on multiple operating temperature sequences and operating power consumption sequences, and then obtains the ambient temperature based on the surface temperature of the device.
[0054] In this way, different methods are set for determining the ambient temperature under different states of electronic devices, which improves the accuracy of temperature prediction.
[0055] In some embodiments, when the electronic device performs the above step S103 "determines the ambient temperature corresponding to multiple operating temperature sequences and operating power consumption sequences based on the relational data model", it may also perform the following steps: using the contribution factor of each parameter in multiple operating temperatures and operating power consumption in the relational data model to the ambient temperature, processing the parameters in multiple operating temperature sequences and operating power consumption sequences, and determining the corresponding ambient temperature based on the processed parameters.
[0056] In the embodiments of this application, the relational data model includes contribution factors of each parameter in multiple operating temperatures and operating power consumption to ambient temperature. Based on the contribution factor of each parameter to ambient temperature, the parameters in multiple operating temperature sequences and operating power consumption sequences can be processed to obtain the ambient temperature. For example, the implementation of processing parameters in multiple operating temperature sequences and operating power consumption sequences based on the contribution factor of each parameter to ambient temperature can be as follows: parameters with small or no contribution factors can be removed, while parameters with large contribution factors, i.e., parameters that have a significant impact on ambient temperature, are given increased weight. In this way, the ambient temperature can be obtained.
[0057] In the embodiments of this application, the electronic device can select the parameter that has the greatest impact on the ambient temperature or has an impact on the ambient temperature from multiple parameters based on the contribution factor of each parameter to the ambient temperature, and then determine the corresponding ambient temperature based on the parameter with the greatest impact.
[0058] In the embodiments of this application, the relationship between power consumption, device surface temperature and ambient temperature implied in the relational data model constructed by the electronic device is actually the influence relationship between each parameter on the ambient temperature. If there is an influence, it is filtered out as the basis for determining the ambient temperature. If there is no influence, it is removed to filter out the parameters that really have an impact on the ambient temperature, and then the ambient temperature is obtained based on the filtered parameters.
[0059] In this way, based on the contribution factors of each parameter in the multiple operating temperatures and power consumption contained in the relational data model to the ambient temperature, the parameters that have an impact can be screened out from multiple parameters. Then, the ambient temperature can be determined based on the parameters that affect the ambient temperature, which can be used to determine the ambient temperature in a targeted manner and improve the accuracy of ambient temperature prediction.
[0060] In some embodiments, the relational data model includes at least one sequentially connected memory network, each memory network including a memory cell and a gating cell. When the electronic device performs the above step S103, "determining the ambient temperature corresponding to multiple operating temperature sequences and operating power consumption sequences based on the relational data model," as shown... Figure 5 As shown, the following steps S501 to S504 can also be performed: Step S501: For each memory network, using the corresponding gating unit, based on multiple operating temperature sequences, operating power consumption sequences, and input hidden states, determine the removal and addition information of the corresponding memory unit.
[0061] In the embodiments of this application, such as Figure 6As shown, the relational data model can be a Long Short-Term Memory (LSTM) network 61. Electronic devices input information 62 such as power, CPU_NTC temperature sensor, GPU_NTC temperature sensor, and camera_NTC temperature sensor into the LSTM network 61 to obtain the ambient temperature 63.
[0062] In embodiments of this application, the Long Short-Term Memory (LSTM) network includes at least one sequentially connected memory network, each memory network including a memory unit and a gating unit, such as... Figure 7 As shown, a schematic diagram of the structure of a memory network 71 in a Long Short-Term Memory (LSTM) network is presented. The memory unit 72 is used to store long-term information, and the gating unit 73 is used to filter parameters that affect the ambient temperature. The LSTM network is used as the algorithm model to handle the ambient temperature detection problem with time series prediction properties.
[0063] In the embodiments of this application, for each memory network, the removal and addition information of the corresponding memory unit is determined by using the corresponding gating unit based on multiple operating temperature sequences, operating power consumption sequences, and input hidden states. The multiple operating temperature sequences and operating power consumption sequences are the data obtained corresponding to the current operation of at least one application. If the input hidden state is the first memory network in the Long Short-Term Memory network, then the input hidden state is 0, that is, there is no initial value. The input hidden state of subsequent memory networks is the output hidden state of the previous time step.
[0064] Step S502: For each memory network, using the corresponding memory unit, remove the removal information from the corresponding input memory information, and add the addition information to the corresponding removal result to obtain the corresponding output memory information.
[0065] In the embodiments of this application, the memory network stores long-term information. For information that needs to be removed, the relevant information is removed from the input memory information, and information is added to the corresponding removed result to obtain the output memory information.
[0066] In the embodiments of this application, after determining the information to be removed and the information to be added, corresponding operations need to be performed on the input memory information to obtain more accurate long-term information.
[0067] Step S503: For each memory network, use the corresponding gating unit to extract information from the output memory information and generate the corresponding output hidden state.
[0068] In the embodiments of this application, for each memory network, information is extracted from the output memory information using the corresponding gating unit to generate the corresponding output hidden state.
[0069] In the embodiments of this application, the gating unit can decide to extract information from the memory information as needed, and then output the required information.
[0070] Step S504: Output ambient temperature based on the hidden state of the last memory network in at least one sequentially connected memory network.
[0071] In embodiments of this application, the electronic device outputs the hidden state of the last memory network in at least one sequentially connected memory network as the ambient temperature.
[0072] In this way, by using gating mechanisms and cell states, long-term dependent information can be effectively preserved and transmitted, thereby improving the accuracy of temperature prediction.
[0073] In some embodiments, the gating unit includes an input gate, an output gate, and a forget gate. When the electronic device performs step S501 above, as follows: Figure 8 As shown, the following steps S801 and S802 can be performed: Step S801: For each memory network, using the corresponding forget gate, based on multiple temperature sequences, power consumption sequences, and input hidden states, determine the removal information of the corresponding memory unit.
[0074] In the embodiments of this application, for each memory network, the electronic device uses the corresponding forget gate to determine the removal information of the corresponding memory cell based on multiple temperature sequences, operating power consumption sequences, and input hidden states.
[0075] like Figure 7 As shown, the gating unit 73 includes a forget gate 731, an input gate 732, and an output gate 733. The forget gate is used to determine which irrelevant information is forgotten.
[0076] An exemplary implementation of the forget gate is as follows: the current input xt and the previous hidden state h... t-1 The Forgotten Gate can be accessed The decision is made from the previous memory unit C. t-1 To determine which information to remove, the method for determining the information to remove is illustrated in formula (1): (1); in, To remove the information, This is the input hidden state. The information entered at the current moment. , , All of these are model parameters.
[0077] Step S802: For each memory network, using the corresponding input gate, based on multiple operating temperature sequences, operating power consumption sequences, and input hidden states, determine the addition information of the corresponding memory cell.
[0078] In the embodiments of this application, for each memory network, the input gate determines which new knowledge to remember, that is, the input gate determines the proportion of new information Ct to be added through it (0-1).
[0079] For example, the input is implemented as shown in formula (2): (2); in, To determine the proportion of addition, This is the input hidden state. The information entered at the current moment. , , All of these are model parameters.
[0080] Then, determine the input information. For an example, see formula (3): (3); in, To add information, This is the input hidden state. The information entered at the current moment. , , These are the model parameters.
[0081] In some embodiments, when the electronic device performs step S503 as described above, such as Figure 8 As shown, the following steps S803 can be performed: Step S803: For each memory network, extract information from the output memory information using the corresponding output gate to generate the corresponding output hidden state.
[0082] In the embodiments of this application, the output gate determines which knowledge to output as needed, and extracts information from the current memory unit Ct through the output gate Ot to generate the hidden state ht. Selective memorization is achieved by controlling the increase or decrease of the information flow through the gating unit.
[0083] For example, the implementation of the output gate Ot is shown in formula (4): (4); Where Ot represents the output information. This is the input hidden state. The information entered at the current moment. , , These are the model parameters.
[0084] In the embodiments of this application, the method for generating the hidden state ht by extracting information from the current memory unit Ct based on the output information is shown in formula (5): (5); Where ht represents the hidden state. To output the memory information.
[0085] In the embodiments of this application, The implementation can be done in C. t-1 and The product of these, then add and The accumulation of.
[0086] In this way, selective memory is achieved by controlling the increase or decrease of information flow through the gating unit, making the hidden state generated from the information ultimately extracted from the memory more accurate and improving the accuracy of temperature prediction.
[0087] In some embodiments, when the electronic device performs the above step S102, such as Figure 9 As shown, the following steps S901 and S902 can also be performed: Step S901: Using the relationship data model to be trained, based on multiple temperature sequences and power consumption sequences, predict the sample environment temperature of the environment in which the electronic device is located; the temperature prediction model to be trained is a long short-term memory network model.
[0088] In the embodiments of this application, the relational data model to be trained predicts the sample ambient temperature of the environment in which the electronic device is located, based on multiple temperature sequences and power consumption sequences.
[0089] For example, as described in step S102 above, the standardized data is used as the input to the relational data model to be trained, and the predicted sample environmental temperature is output by the relational data model to be trained.
[0090] like Figure 10 As shown, the standardized data 101 is input into the relational data model 102 to be trained, and the output is the sample environmental temperature 103.
[0091] Step S902: Determine the loss information between the sample ambient temperature and the target ambient temperature, and adjust the model parameters of the relational data model to be trained based on the loss information to obtain the relational data model.
[0092] In the embodiments of this application, the model parameters of the relational data model to be trained are adjusted based on the loss information between the sample ambient temperature and the target ambient temperature to obtain the relational data model.
[0093] For example, such as Figure 10 As shown, after obtaining the sample ambient temperature, the loss information between the sample ambient temperature and the target ambient temperature is calculated. The implementation method is shown in the following formula (6): (6); in, The target ambient temperature, The ambient temperature of the sample.
[0094] The learning rate is 0.01, the optimization algorithm is RMSprop, the gradient is weighted and averaged, and the model weights (model parameters) are updated.
[0095] Here, the data is input into the LSTM model to obtain the model prediction result E_predict (sample ambient temperature). SmoothL1Loss is used to calculate the difference loss between the prediction result E_predict and the actual ambient temperature label E_target (target ambient temperature). The learning rate and weights are continuously updated until the loss no longer decreases and reaches a stable state, thus obtaining the optimal model.
[0096] After obtaining the relational data model, inputting the values of the phone's NTC and power over one minute into the optimal model allows for the estimation of the ambient temperature E_predict. Corresponding to step S903 above, the inference process is as follows: Figure 11 As shown: The standardized data 111 is input into the relational data model 112, and the output is the ambient temperature 63. The model has 1 layer and a hidden size of 32.
[0097] In the embodiments of this application, the results of the predicted ambient temperature and the target ambient temperature are as follows: Figure 12 As shown, if the error range is between -1℃ and -1℃, the accuracy rate can reach 91.87%, and if the error range is between -2℃ and -2℃, the accuracy rate can reach 93.90%.
[0098] Therefore, the accuracy of environmental temperature prediction using relational data models is relatively high.
[0099] In some embodiments, when the electronic device performs the above step S103, "determining the ambient temperature corresponding to multiple operating temperature sequences and operating power consumption sequences based on the relational data model," as follows: Figure 13 As shown, it may also include the following steps S1301 to S1303: Step S1301: Determine the device surface temperature corresponding to the electronic device based on multiple operating temperature sequences.
[0100] In the embodiments of this application, the electronic device can invoke an AI model to determine the device surface temperature corresponding to the electronic device based on multiple operating temperature sequences.
[0101] Step S1302: Based on the operating power consumption sequence, determine the temperature rise value corresponding to the power consumption generated when the electronic device runs the program.
[0102] In the embodiments of this application, the above step S103 states that the operation of the electronic device will generate power consumption, which will cause the temperature of the electronic device to rise. Therefore, the corresponding ambient temperature can be obtained by subtracting the temperature rise caused by the running program from the surface temperature of the mobile phone.
[0103] Step S1303: Determine the ambient temperature based on the equipment surface temperature and temperature rise value.
[0104] In the embodiments of this application, the difference between the device surface temperature and the temperature rise value is determined as the ambient temperature.
[0105] In the embodiments of this application, the steps S1301 to S1303 are the same as the steps S407 to S409 described above, and will not be repeated here.
[0106] In this way, the corresponding ambient temperature can be determined based on the difference between the ambient temperature and the surface temperature of the equipment. The relational data model can accurately determine the temperature rise generated by the running program, and then obtain the ambient temperature based on the surface temperature of the equipment, making it possible for the equipment to identify the ambient temperature itself and improving the possibility of temperature rise control.
[0107] In some embodiments, after performing the above step S103 of "determining the ambient temperature corresponding to multiple operating temperature sequences and operating power consumption sequences", the electronic device may also perform the following step: determining the temperature control strategy corresponding to the electronic device based on the relationship between the ambient temperature and the preset temperature.
[0108] In the embodiments of this application, considering that users feel the same device temperature differently under different ambient temperatures, different temperature control strategies can be configured for different ambient temperatures to achieve more precise temperature control, balance temperature rise and performance, and obtain a better user experience.
[0109] For example, such as Figure 14 As shown, an exemplary implementation of configuring different temperature control strategies for different ambient temperatures may include the following steps S1401 to S1406: Step S1401: Mobile phone is powered on.
[0110] The phone is powered on here.
[0111] Step S1402: Determine that the current ambient temperature is less than 10℃.
[0112] Here, the mobile phone will obtain the current ambient temperature value. The method for determining the current ambient temperature value can be found in steps S103, S1401 to S1403 above. If the current ambient temperature value is less than 10℃, step S1403 is executed. If the current ambient temperature is greater than or equal to 10℃, step S1404 is executed.
[0113] Step S1403: Switch the temperature control strategy for release performance.
[0114] Here, if the current ambient temperature is less than 10°C, a performance-enhancing temperature control strategy can be switched to. For example, the current strategy reduces the CPU frequency when the phone's surface temperature reaches 42°C, which limits device performance. A performance-enhancing temperature control strategy could be set to reduce the CPU frequency only when the phone's surface temperature reaches 45°C, allowing users to use the phone for a longer period at higher performance.
[0115] Step S1404: Determine that the current ambient temperature is greater than 30℃.
[0116] Here, if the current ambient temperature is greater than or equal to 10℃, further determine whether the current ambient temperature is greater than 30℃. If yes, proceed to step S1405; otherwise, proceed to step S1406.
[0117] Step S1405: Switch to strict temperature control strategy.
[0118] Here, as discussed in step S1403, the performance-releasing temperature control strategy can be set to reduce the CPU frequency only when the phone surface temperature reaches 45 degrees Celsius. Correspondingly, the strict temperature control strategy can be set to reduce the CPU frequency when the phone surface temperature reaches 40 degrees Celsius. In this way, users can use the phone for a shorter time at higher performance, but the phone temperature can be controlled at a lower level.
[0119] Step S1406: Maintain the current strategy.
[0120] Here, when the current ambient temperature is greater than or equal to 10°C and less than or equal to 30°C, the current strategy is maintained, which means that the CPU frequency can be reduced when the surface temperature of the phone reaches 42°C.
[0121] In this example, the preset temperatures are 10 degrees Celsius and 30 degrees Celsius. Of course, the preset temperatures can also be other temperature values, which can be set based on actual needs and application scenarios. This application does not limit this.
[0122] Therefore, setting a temperature control strategy based on ambient temperature takes into account the impact of ambient temperature on user perception, making it more suitable for the scenario and improving the accuracy of temperature control.
[0123] In some embodiments, after performing the above step S103 of "determining the ambient temperature corresponding to multiple operating temperature sequences and operating power consumption sequences", the electronic device may also perform the following step: monitoring the health status of the target object operating the electronic device based on changes in ambient temperature.
[0124] In the embodiments of this application, the electronic device, knowing the current ambient temperature, can monitor human health in real time based on changes in ambient temperature.
[0125] For example, health advice: When an electronic device detects that the ambient temperature is too high, it can automatically pop up a window to remind the user (target) to pay attention to hydration and heatstroke prevention; when it detects that the ambient temperature is too low, it can automatically pop up a window to remind the user to add clothing in time to avoid catching a cold.
[0126] For example, room temperature regulation: After the user falls asleep at night, if the electronic device detects that the ambient temperature has suddenly dropped from a comfortable temperature to a certain threshold, it will automatically turn on the air conditioner to adjust the room temperature back to a comfortable temperature, preventing the user from catching a cold due to low temperatures while sleeping. The threshold can be set by the user or set by the device based on the actual scenario.
[0127] For example, disease characteristic association: If the sensor of an electronic device (such as a mobile phone) detects that a user always has cough symptoms when the ambient temperature is below a certain level through sound monitoring, by collecting historical data, the relationship between temperature and cough symptoms can be automatically matched to remind the user to seek medical attention in time.
[0128] In this way, electronic devices can monitor the health status of the target object using the electronic device based on changes in ambient temperature, thereby improving the flexibility of device usage scenarios.
[0129] In some embodiments, after performing the above step S103 of "determining the ambient temperature corresponding to multiple operating temperature sequences and operating power consumption sequences", the electronic device may also perform the following steps: in response to the difference between the ambient temperature and the ambient temperature corresponding to adjacent time periods being greater than a preset threshold, determining that the electronic device is in a scenario with an external heat source, and determining the type of external heat source based on the illuminance value of the light sensor on the electronic device.
[0130] In the embodiments of this application, if the obtained ambient temperature shows a significant jump, i.e., the ambient temperature at times Tn and Tn-1 is much higher than the ambient temperature before Tn-1, it can be determined that an external heat source exists. Furthermore, the external heat source, direct sunlight, can be identified simultaneously by reading the value of the mobile phone's light sensor. According to test results, the value of the mobile phone's light sensor under direct sunlight conditions is generally above 10000 lux. Figure 15 As shown, under direct sunlight and a normal reading posture, the lux value varies linearly with the angle of sunlight, ranging from 20,000 to 100,000 lux. Figure 16 As shown, under the shade of a tree, in a normal reading posture, the lux value changes linearly with the angle of sunlight, ranging from 10,000 to 18,000 lux. Figure 17 As shown, during the use of the navigation app inside the car, the light sensor readings were between 112,172 and 62,643 lux due to direct sunlight. Therefore, based on the illuminance values from the light sensor on the electronic device, it can be determined whether there is an external heat source, such as direct sunlight, because the indoor illuminance is below 1000 lux.
[0131] In the embodiments of this application, the preset threshold for measuring a significant jump in ambient temperature can be set based on actual needs and application scenarios, and this application does not limit this.
[0132] In embodiments of this application, the electronic device can determine the type of external heat source based on the illuminance value of the light sensor. The type can be direct sunlight, indoor lighting, etc.
[0133] Thus, when the difference between the ambient temperature and the ambient temperature in adjacent time periods exceeds a preset threshold, the external heat source is determined based on the illuminance value of the light sensor, increasing the application scenarios of ambient temperature.
[0134] One method for temperature prediction involves: monitoring the power consumption sequence corresponding to each application running on an electronic device, as well as multiple temperature sequences corresponding to multiple temperature sensors on the electronic device; constructing a relational data model of power consumption, device surface temperature, and ambient temperature based on multiple temperature value sequences and power consumption sequences; obtaining multiple operating temperature sequences and operating power consumption sequences from multiple temperature sensors when the electronic device runs at least one application within a preset time period; processing the parameters in the multiple operating temperature sequences and operating power consumption sequences using the contribution factor of each parameter in the multiple operating temperatures and operating power consumption sequences to the ambient temperature, and determining the corresponding ambient temperature based on the processed parameters; and determining the temperature control strategy corresponding to the electronic device based on the relationship between the ambient temperature and the preset temperature.
[0135] Another method for temperature prediction involves: acquiring multiple operating temperature sequences and power consumption sequences from multiple temperature sensors when an electronic device runs at least one application within a preset time period; determining the device surface temperature based on the multiple operating temperature sequences; determining the temperature rise corresponding to the power consumption generated by the electronic device while running the program based on the power consumption sequence; determining the ambient temperature based on the device surface temperature and the temperature rise; and monitoring the health status of the target object operating the electronic device based on changes in the ambient temperature.
[0136] Another method for temperature prediction involves monitoring the power consumption sequence of various applications running on an electronic device, as well as multiple temperature sequences from multiple temperature sensors on the device. Using a training relational data model, the ambient temperature of the electronic device is predicted based on these multiple temperature and power consumption sequences. The training temperature prediction model is a Long Short-Term Memory (LSTM) network model. The loss information between the ambient temperature and the target ambient temperature is determined, and the model parameters are adjusted based on this loss information to obtain the relational data model. The relational data model includes at least one sequentially connected memory network, each including a memory unit and a gating unit. The gating unit includes an input gate, an output gate, and a forget gate. For each memory network, the corresponding forget gate is used to predict the ambient temperature based on multiple temperature sequences, the running power consumption sequence, and the input hidden state. The process involves: determining the removal information of the corresponding memory cell; for each memory network, using the corresponding input gate, determining the addition information of the corresponding memory cell based on multiple operating temperature sequences, operating power consumption sequences, and input hidden states; for each memory network, using the corresponding memory cell, removing the removal information from the corresponding input memory information, and adding the addition information to the result after removal to obtain the corresponding output memory information; for each memory network, using the corresponding output gate, extracting information from the output memory information to generate the corresponding output hidden state; outputting the ambient temperature based on the hidden state of the last memory network in at least one sequentially connected memory network; and determining that the electronic device is in a scenario with an external heat source in response to the difference between the ambient temperature and the ambient temperature corresponding to an adjacent time period being greater than a preset threshold, and determining the type of external heat source based on the illuminance value of the light sensor on the electronic device.
[0137] This application provides a temperature prediction method that monitors the power consumption sequence corresponding to various applications running on an electronic device, as well as multiple temperature sequences corresponding to multiple temperature sensors on the electronic device. Based on the multiple temperature value sequences and power consumption sequences, a relational data model is constructed between power consumption, device surface temperature, and ambient temperature. Multiple operating temperature sequences and operating power consumption sequences from multiple temperature sensors are obtained when the electronic device runs at least one application within a preset time period. Based on the relational data model, the ambient temperature corresponding to the multiple operating temperature sequences and operating power consumption sequences is determined. The temperature prediction method provided in this application can predict the current ambient temperature of the electronic device based on the temperature rise caused by application operation, enabling the electronic device to obtain the ambient temperature and improving the accuracy of temperature prediction.
[0138] like Figure 18 As shown, this application embodiment provides an electronic device 18, including: Monitoring module 181 is used to monitor the power consumption sequence corresponding to each application running on the electronic device, as well as the multiple temperature sequences corresponding to multiple temperature sensors on the electronic device. Module 182 is used to build a data model relating power consumption, device surface temperature, and ambient temperature based on multiple temperature value sequences and power consumption sequences. The determination module 183 is used to acquire multiple operating temperature sequences and operating power consumption sequences of multiple temperature sensors when an electronic device runs at least one application within a preset time period, and to determine the ambient temperature corresponding to the multiple operating temperature sequences and operating power consumption sequences based on a relational data model.
[0139] In one embodiment of this application, the determining module 183 is further configured to, in response to the electronic device being in a non-operating state, determine the device surface temperature of the electronic device based on multiple temperatures from multiple temperature sensors, and determine the device surface temperature as the ambient temperature of the environment in which the electronic device is currently located; and in response to the electronic device being in an operating state, determine the ambient temperature corresponding to multiple operating temperature sequences and operating power consumption sequences based on a relational data model.
[0140] In one embodiment of this application, the determining module 183 is further configured to process the parameters in the multiple operating temperature sequences and operating power consumption sequences by utilizing the contribution factor of each parameter in the multiple operating temperatures and operating power consumption sequences to the ambient temperature in the relational data model, and determine the corresponding ambient temperature based on the processed parameters.
[0141] In one embodiment of this application, the relational data model includes at least one sequentially connected memory network, each memory network including a memory unit and a gating unit; the determining module 183 is further configured to, for each memory network, use the corresponding gating unit to determine the removal information and addition information of the corresponding memory unit based on multiple operating temperature sequences, operating power consumption sequences, and input hidden states; for each memory network, use the corresponding memory unit to remove the removal information from the corresponding input memory information and add the addition information to the corresponding removal result to obtain the corresponding output memory information; for each memory network, use the corresponding gating unit to extract information from the output memory information to generate the corresponding output hidden state; and output the ambient temperature based on the hidden state of the last memory network in the at least one sequentially connected memory network.
[0142] In one embodiment of this application, the gating unit includes an input gate, an output gate, and a forget gate; the determining module 183 is further configured to, for each memory network, use the corresponding forget gate to determine the removal information of the corresponding memory unit based on multiple temperature sequences, operating power consumption sequences, and input hidden states; for each memory network, use the corresponding input gate to determine the addition information of the corresponding memory unit based on multiple operating temperature sequences, operating power consumption sequences, and input hidden states; and for each memory network, use the corresponding output gate to extract information from the output memory information and generate the corresponding output hidden state.
[0143] In one embodiment of this application, the construction module 182 is further configured to use the relationship data model to be trained to predict the sample ambient temperature of the environment in which the electronic device is located based on multiple temperature sequences and power consumption sequences; the temperature prediction model to be trained is a long short-term memory network model; determine the loss information between the sample ambient temperature and the target ambient temperature, and adjust the model parameters of the relationship data model to be trained based on the loss information to obtain the relationship data model.
[0144] In one embodiment of this application, the determining module 183 is further configured to determine the device surface temperature corresponding to the electronic device based on multiple operating temperature sequences; determine the temperature rise value corresponding to the power consumption generated when the electronic device runs a program based on an operating power consumption sequence; and determine the ambient temperature based on the device surface temperature and the temperature rise value.
[0145] In one embodiment of this application, the determining module 183 is further configured to determine the temperature control strategy corresponding to the electronic device based on the relationship between the ambient temperature and the preset temperature; monitor the health status of the target object operating the electronic device based on the changes in the ambient temperature; and determine that the electronic device is in a scenario with an external heat source in response to the difference between the ambient temperature and the ambient temperature corresponding to an adjacent time period being greater than a preset threshold, and determine the type of external heat source based on the illuminance value of the light sensor on the electronic device.
[0146] like Figure 19 As shown, this application provides an electronic device 18, including: a processor 191, a memory 192, and a communication bus 193; Communication bus 193 is used to realize the communication connection between processor 191 and memory 192; The processor 191 is used to execute the computer program stored in the memory 192 to: monitor the power consumption sequence corresponding to the electronic device running various applications, and the multiple temperature sequences corresponding to multiple temperature sensors on the electronic device; construct a relational data model of power consumption, device surface temperature, and ambient temperature based on the multiple temperature sequences and power consumption sequences; obtain multiple operating temperature sequences and operating power consumption sequences of multiple temperature sensors when the electronic device runs at least one application in a second preset time period, and determine the ambient temperature corresponding to the multiple operating temperature sequences and operating power consumption sequences based on the relational data model.
[0147] This application provides an electronic device that monitors power consumption sequences corresponding to the operation of various applications and multiple temperature sequences corresponding to multiple temperature sensors on the electronic device. Based on the multiple temperature value sequences and power consumption sequences, a relational data model is constructed between power consumption, device surface temperature, and ambient temperature. Multiple operating temperature sequences and operating power consumption sequences from multiple temperature sensors are obtained when the electronic device runs at least one application within a preset time period. Based on the relational data model, the ambient temperature corresponding to the multiple operating temperature sequences and operating power consumption sequences is determined. The electronic device provided in this application can predict the current ambient temperature of the electronic device based on the temperature rise caused by application operation, enabling the electronic device to obtain the ambient temperature and improving the possibility of temperature prediction.
[0148] This application provides a computer-readable storage medium storing one or more computer programs, which can be executed by one or more processors to implement the temperature prediction method described above. The computer-readable storage medium can be transient or non-transient.
[0149] This application provides a computer program product, which includes a non-transitory computer-readable storage medium storing a computer program. When the computer program is read and executed by a computer, it implements some or all of the steps in the temperature prediction method described above. This computer program product can be implemented specifically through hardware, software, or a combination thereof. In one optional embodiment, the computer program product is specifically embodied as a computer storage medium; in another optional embodiment, the computer program product is specifically embodied as a software product, such as a software development kit (SDK), etc.
[0150] In some embodiments, the storage medium may be a computer-readable storage medium, which may be volatile memory, such as random-access memory (RAM); or non-volatile memory, such as read-only memory (ROM), flash memory, hard disk drive (HDD), solid-state drive (SSD), ferromagnetic random access memory (FRAM), programmable read-only memory (PROM), erasable programmable read-only memory (EPROM), electrically erasable programmable read-only memory (EEPROM), flash memory, magnetic surface memory, optical disk, or compact disk-read-only memory (CD-ROM); or it may be various devices including one or any combination of the above-mentioned memories, such as mobile phones, computers, tablet devices, personal digital assistants, etc.
[0151] Those skilled in the art will understand that embodiments of this application can be provided as methods, systems, or computer program products. Therefore, this application can take the form of hardware embodiments, software embodiments, or embodiments combining software and hardware aspects. Furthermore, this application can take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage and optical storage) containing computer-usable program code.
[0152] This application is described with reference to flowchart illustrations and / or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of this application. It will be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, special-purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, generate instructions for implementing the flowchart... Figure 1One or more processes and / or boxes Figure 1 A device that provides the functions specified in one or more boxes.
[0153] These computer program instructions may also be stored in a computer-readable storage medium that can direct a computer or other programmable data processing device to function in a particular manner, such that the instructions stored in the computer-readable storage medium produce an article of manufacture including instruction means, which are implemented in a process Figure 1 One or more processes and / or boxes Figure 1 The function specified in one or more boxes.
[0154] These computer program instructions may also be loaded onto a computer or other programmable data processing equipment to cause a series of operational steps to be performed on the computer or other programmable equipment to produce a computer-implemented process, thereby providing instructions that execute on the computer or other programmable equipment for implementing the process. Figure 1 One or more processes and / or boxes Figure 1 The steps of the function specified in one or more boxes.
[0155] In some embodiments, executable instructions may take the form of a program, software, software module, script, or code, written in any form of programming language (including compiled or interpreted languages, or declarative or procedural languages), and may be deployed in any form, including as a standalone program or as a module, component, subroutine, or other unit suitable for use in a computing environment.
[0156] As an example, executable instructions may, but do not necessarily, correspond to files in a file system. They may be stored as part of a file containing other programs or data, for example, in one or more scripts within a Hyper Text Markup Language (HTML) document, in a single file dedicated to the program in question, or in multiple co-located files (e.g., files storing one or more modules, subroutines, or code sections). As an example, executable instructions may be deployed to execute on a single computing device, or on multiple computing devices located in one location, or on multiple computing devices distributed across multiple locations and interconnected via a communication network.
[0157] It should be understood that the phrase "one embodiment" or "an embodiment" throughout the specification means that a specific feature, structure, or characteristic related to the embodiment is included in at least one embodiment of this application. Therefore, "in one embodiment" or "in an embodiment" appearing throughout the specification does not necessarily refer to the same embodiment. Furthermore, these specific features, structures, or characteristics can be combined in any suitable manner in one or more embodiments. It should be understood that in the various embodiments of this application, the sequence numbers of the above-described processes do not imply a sequential order of execution; the execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of this application. The sequence numbers of the above-described embodiments are merely descriptive and do not represent the superiority or inferiority of the embodiments.
[0158] It should be noted that, in this document, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, or apparatus. Without further limitations, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes that element. In the several embodiments provided in this application, it should be understood that the disclosed devices and methods can be implemented in other ways. The device embodiments described above are merely illustrative; for example, the division of units is only a logical functional division, and in actual implementation, there may be other division methods, such as: multiple units or components may be combined, or integrated into another system, or some features may be ignored or not performed.
[0159] The above description is merely a specific embodiment of this application, but the scope of protection of this application is not limited thereto. Any variations or substitutions that can be easily conceived by those skilled in the art within the scope of the technology disclosed in this application should be included within the scope of protection of this application.
Claims
1. A temperature prediction method, the method comprising: Monitor the power consumption sequence corresponding to each application running on the electronic device, as well as the multiple temperature sequences corresponding to multiple temperature sensors on the electronic device; Based on the multiple temperature value sequences and the power consumption sequence, a data model relating power consumption, device surface temperature, and ambient temperature is constructed. The system acquires multiple operating temperature sequences and operating power consumption sequences of the multiple temperature sensors when the electronic device runs at least one application within a preset time period, and determines the ambient temperature corresponding to the multiple operating temperature sequences and the operating power consumption sequences based on the relational data model.
2. The temperature prediction method according to claim 1, further comprising: In response to the electronic device being in a non-operating state, the device surface temperature of the electronic device is determined based on multiple temperatures from the multiple temperature sensors, and the device surface temperature is determined as the ambient temperature of the environment in which the electronic device is currently located; In response to the electronic device being in operation, the ambient temperature corresponding to the plurality of operating temperature sequences and the operating power consumption sequence is determined based on the relational data model.
3. The temperature prediction method according to claim 1 or 2, wherein determining the ambient temperature corresponding to the plurality of operating temperature sequences and the operating power consumption sequence based on the relational data model includes: By utilizing the contribution factor of each parameter in the multiple operating temperatures and power consumption in the relational data model to the ambient temperature, the parameters in the multiple operating temperature sequences and the operating power consumption sequences are processed, and the corresponding ambient temperature is determined based on the processed parameters.
4. The temperature prediction method according to claim 1 or 3, wherein the relational data model includes at least one sequentially connected memory network, each memory network including a memory unit and a gating unit; the step of determining the ambient temperature corresponding to the plurality of operating temperature sequences and the operating power consumption sequence based on the relational data model includes: For each memory network, using the corresponding gating unit, based on the multiple operating temperature sequences, the operating power consumption sequence, and the input hidden state, the removal and addition information of the corresponding memory unit are determined; For each memory network, using the corresponding memory unit, the removal information is removed from the corresponding input memory information, and the addition information is added to the result after removal to obtain the corresponding output memory information; For each memory network, information is extracted from the output memory information using the corresponding gating unit to generate the corresponding output hidden state; The ambient temperature is output based on the hidden state of the last memory network in the at least one sequentially connected memory network.
5. The temperature prediction method according to claim 4, wherein the gating unit includes an input gate, an output gate, and a forget gate; the step of determining the removal and addition information of the corresponding memory unit for each memory network using the corresponding gating unit, based on the plurality of operating temperature sequences, the operating power consumption sequence, and the input hidden state, includes: For each memory network, the removal information of the corresponding memory cell is determined using the corresponding forget gate based on the multiple temperature sequences, the operating power consumption sequence, and the input hidden state. For each memory network, the addition information for the corresponding memory cell is determined using the corresponding input gate based on the multiple operating temperature sequences, the operating power consumption sequence, and the input hidden state. For each memory network, the step of extracting information from the output memory information using the corresponding gating unit to generate a corresponding output hidden state includes: For each memory network, information is extracted from the output memory information using the corresponding output gate to generate the corresponding output hidden state.
6. The temperature prediction method according to claim 1, wherein constructing a relational data model of power consumption, device surface temperature, and ambient temperature based on the plurality of temperature sequences and the power consumption sequence comprises: Using the relationship data model to be trained, the sample ambient temperature of the environment in which the electronic device is located is predicted based on the multiple temperature sequences and the power consumption sequence; The temperature prediction model to be trained is a long short-term memory network model. The loss information between the sample ambient temperature and the target ambient temperature is determined, and the model parameters of the relational data model to be trained are adjusted based on the loss information to obtain the relational data model.
7. The temperature prediction method according to claim 1, wherein determining the ambient temperature corresponding to the plurality of operating temperature sequences and the operating power consumption sequence based on the relational data model includes: Based on the multiple operating temperature sequences, the device surface temperature corresponding to the electronic device is determined; Based on the operating power consumption sequence, determine the temperature rise value corresponding to the power consumption generated when the electronic device runs the program; The ambient temperature is determined based on the surface temperature of the device and the temperature rise.
8. The temperature prediction method according to any one of claims 5 to 7, after determining the ambient temperature corresponding to the plurality of operating temperature sequences and the operating power consumption sequence, at least one of the following can be performed: Based on the relationship between the ambient temperature and the preset temperature, the temperature control strategy corresponding to the electronic device is determined; Based on the changes in ambient temperature, monitor the health status of the target object operating the electronic device; In response to the fact that the difference between the ambient temperature and the ambient temperature corresponding to an adjacent time period is greater than a preset threshold, it is determined that the electronic device is in a scenario with an external heat source, and the type of the external heat source is determined based on the illuminance value of the light sensor on the electronic device.
9. An electronic device, comprising: Processor, memory, and communication bus; The communication bus is used to realize the communication connection between the processor and the memory; The processor is configured to execute a computer program stored in the memory to: monitor the power consumption sequence corresponding to each application running on the electronic device, and multiple temperature sequences corresponding to multiple temperature sensors on the electronic device; construct a relational data model of power consumption, device surface temperature, and ambient temperature based on the multiple temperature sequences and the power consumption sequence; obtain multiple operating temperature sequences and operating power consumption sequences of the multiple temperature sensors when the electronic device runs at least one application in a second preset time period, and determine the ambient temperature corresponding to the multiple operating temperature sequences and the operating power consumption sequence based on the relational data model.
10. A computer-readable storage medium storing one or more computer programs that can be executed by one or more processors to implement the temperature prediction method of any one of claims 1 to 8.