Temperature prediction method, device, storage medium and computer equipment
By constructing the temperature, position and state matrix to generate feature vectors, and using BERT and GBDT algorithms to predict temperature, the problem of manual intervention after high temperature alarm of computer room information equipment is solved, and efficient temperature prediction and stable equipment operation is achieved.
Patent Information
- Application Number
- CN202110481118.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-04-30
- Publication Date
- 2025-08-26
- Estimated Expiration
- 2041-04-30
AI Technical Summary
In the prior art, manual intervention is required after high temperature alarms of computer room information equipment, resulting in low temperature prediction efficiency and inability to effectively predict the temperature of the information equipment, affecting the normal operation of the equipment and business continuity.
By constructing the temperature matrix, position matrix and state matrix, generating feature vectors, using the BERT model to perform feature coding and GBDT algorithm to predict temperature, generate predicted temperature vectors, and realize intelligent prediction of the temperature of information equipment.
It improves the efficiency of temperature prediction, reduces high-temperature alarm failures, reduces the energy consumption of the computer room, and ensures the stable operation of information equipment and network security.
Smart Images

Figure CN115270383B_ABST
Abstract
Description
Technical field
[0001] The present invention relates to the field of computer technology, and in particular to a temperature prediction method, device, storage medium and computer equipment. [Background Technology]
[0002] The operating temperature of information equipment in a computer room typically ranges from 0 to 40°C during normal operation. Computer room cooling has always been a crucial aspect of data center operations and maintenance. In related technologies, when an information device generates a high-temperature alarm, maintenance personnel must remotely monitor the alarm, enter the computer room, identify the cause, and then implement appropriate local cooling measures. This ineffectively predicts the temperature of the information device, reducing its efficiency. [Summary of the invention]
[0003] In view of this, embodiments of the present invention provide a temperature prediction method, apparatus, storage medium, and computer device to improve the efficiency of temperature prediction.
[0004] In one aspect, an embodiment of the present invention provides a temperature prediction method, comprising:
[0005] Generate multiple eigenvectors according to the constructed temperature matrix, original position matrix and original state matrix;
[0006] Perform feature encoding on each eigenvector and generate the output vector corresponding to each eigenvector;
[0007] According to the multiple output vectors, a predicted temperature vector corresponding to each output vector is generated;
[0008] Predict temperature based on multiple predicted temperature vectors.
[0009] Optionally, the generating of multiple eigenvectors based on the constructed temperature matrix, original position matrix and original state matrix includes:
[0010] Performing matrix encoding on the original position matrix by an embedding algorithm to generate a position matrix;
[0011] Performing matrix encoding on the original state matrix by an embedding algorithm to generate a state matrix;
[0012] performing an addition operation on the temperature matrix, the position matrix, and the state matrix to generate an addition matrix;
[0013] Performing a transpose calculation on the addition matrix to generate an addition transposed matrix;
[0014] The added transposed matrix is split to generate a plurality of eigenvectors.
[0015] Optionally, the step of performing feature encoding on each feature vector to generate an output vector corresponding to each feature vector includes:
[0016] By constructing a bidirectional encoder representation model from the converter, each feature vector is feature encoded to generate an output vector corresponding to each feature vector.
[0017] Optionally, the bidirectional encoder representation model from the converter is constructed to perform feature encoding on each feature vector and generate an output vector corresponding to each feature vector, including:
[0018] Perform cross multiplication calculation on the constructed first weight matrix and each eigenvector to generate an input encoding matrix;
[0019] Perform cross product calculation on the constructed second weight matrix and each eigenvector to generate an input weight matrix;
[0020] Perform cross product calculation on the constructed third weight matrix and each eigenvector to generate an output weight matrix;
[0021] Generate a self-attention encoding matrix according to the input encoding matrix and the input weight matrix;
[0022] Calculate the self-attention encoding matrix using the softmax algorithm to generate a probability matrix;
[0023] Performing a cross product calculation on the probability matrix and the output weight matrix to generate a feedforward vector encoding matrix;
[0024] The feedforward vector encoding matrix is split to generate multiple output vectors.
[0025] Optionally, generating a predicted temperature vector corresponding to each output vector according to the multiple output vectors includes:
[0026] The gradient boosting decision tree (GBDT) algorithm is used to calculate multiple output vectors and generate a predicted temperature vector corresponding to each output vector.
[0027] Optionally, generating a self-attention encoding matrix according to the input encoding matrix and the input weight matrix includes:
[0028] By formula The input encoding matrix and the input weight matrix are calculated to generate a self-attention encoding matrix, where A is the self-attention encoding matrix, Q is the input encoding matrix, K is the input weight matrix, and m is the number of rows of the input encoding matrix.
[0029] In another aspect, an embodiment of the present invention provides a temperature prediction device, comprising:
[0030] A first generating module is used to generate a plurality of eigenvectors according to the constructed temperature matrix, the original position matrix and the original state matrix;
[0031] The second generation module is used to perform feature encoding on each feature vector and generate an output vector corresponding to each feature vector;
[0032] A third generating module is used to generate a predicted temperature vector corresponding to each output vector according to the multiple output vectors;
[0033] The prediction module is used for predicting temperature according to a plurality of predicted temperature vectors.
[0034] Optionally, the first generating module includes:
[0035] A first generating submodule is configured to perform matrix encoding on the original position matrix through an embedding algorithm to generate a position matrix;
[0036] A second generating submodule is used to perform matrix encoding on the original state matrix through an embedding algorithm to generate a state matrix;
[0037] A third generating submodule is configured to perform an addition operation on the temperature matrix, the position matrix, and the state matrix to generate an addition matrix;
[0038] a fourth generating submodule, configured to perform a transpose calculation on the addition matrix to generate an addition transposed matrix;
[0039] The fifth generating submodule is used to split the added transposed matrix to generate multiple eigenvectors.
[0040] On the other hand, an embodiment of the present invention provides a storage medium, including: the storage medium includes a stored program, wherein when the program is running, the device where the storage medium is located is controlled to execute the above-mentioned temperature prediction method.
[0041] On the other hand, an embodiment of the present invention provides a computer device comprising a memory and a processor, wherein the memory is used to store information including program instructions, and the processor is used to control the execution of the program instructions, and is characterized in that the program instructions implement the steps of the above-mentioned temperature prediction method when loaded and executed by the processor.
[0042] In the technical solution of the temperature prediction method provided by the embodiment of the present invention, multiple eigenvectors are generated based on a constructed temperature matrix, an original position matrix, and an original state matrix; feature encoding is performed on each eigenvector to generate an output vector corresponding to each eigenvector; based on the multiple output vectors, a predicted temperature vector corresponding to each output vector is generated; and based on the multiple predicted temperature vectors, the temperature is predicted. The technical solution provided by the embodiment of the present invention can generate a predicted temperature vector based on the constructed temperature matrix, the original position matrix, and the original state matrix, thereby realizing temperature prediction of an information device based on the predicted temperature vector, thereby improving the efficiency of temperature prediction.
Brief Description of the Drawings
[0043] In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the following briefly introduces the drawings required for use in the embodiments. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative work.
[0044] Figure 1 A flow chart of a temperature prediction method provided by an embodiment of the present invention;
[0045] Figure 2 for Figure 1 A flowchart of generating multiple eigenvectors based on the constructed temperature matrix, original position matrix and original state matrix;
[0046] Figure 3 for Figure 1 In the flowchart, each feature vector is encoded and the output vector corresponding to each feature vector is generated;
[0047] Figure 4 A schematic diagram of the structure of a temperature prediction device provided by an embodiment of the present invention;
[0048] Figure 5 for Figure 4 A schematic diagram of the structure of the first generation module;
[0049] Figure 6 for Figure 4 A schematic diagram of the structure of the second generation module;
[0050] Figure 7 A schematic diagram of a computer device provided in an embodiment of the present invention. [Specific implementation method]
[0051] In order to better understand the technical solution of the present invention, the embodiments of the present invention are described in detail below with reference to the accompanying drawings.
[0052] It should be understood that the embodiments described are only a portion of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by persons of ordinary skill in the art without creative work are within the scope of protection of the present invention.
[0053] The terms used in the embodiments of the present invention are only for the purpose of describing specific embodiments and are not intended to limit the present invention. The singular forms "a", "an", "the" and "the" used in the embodiments of the present invention and the appended claims are also intended to include plural forms unless the context clearly indicates otherwise.
[0054] It should be understood that the term "and / or" as used herein simply describes a relationship between associated objects, indicating that three possible relationships exist. For example, "A and / or B" can represent: A alone, A and B together, or B alone. Furthermore, the character " / " in this document generally indicates an "or" relationship between the associated objects.
[0055] In related technologies, data center operations and maintenance typically address localized hotspots in computer rooms through intelligent monitoring of information equipment or manual cooling. Information equipment is connected to a remote monitoring system. When the operating temperature of the information equipment exceeds a set threshold, the equipment will issue a high-temperature alarm. After remotely monitoring the high-temperature alarm, operations and maintenance personnel enter the faulty computer room to determine the cause of the high-temperature alarm. They then take measures such as lowering the cooling system's set temperature, activating a backup cooling system, or temporarily adding axial fans to dissipate heat locally.
[0056] In related technologies, high-temperature alarms from information equipment can cause the equipment to malfunction, leading to equipment failure and impacting the services it carries. This can be time-delayed. These solutions fail to effectively predict the temperature of information equipment, reducing its efficiency.
[0057] In order to solve the technical problems in the related art, the embodiment of the present invention provides a temperature prediction method. Figure 1 A flow chart of a temperature prediction method provided by an embodiment of the present invention is shown in FIG. Figure 1 As shown, the method includes:
[0058] Step 102: Generate multiple eigenvectors according to the constructed temperature matrix, original position matrix and original state matrix.
[0059] In the embodiment of the present invention, the temperature sensor collects the temperature of the information device within a set time and a set range, and constructs a temperature matrix based on the temperature of the information device. In the embodiment of the present invention, the set time and set range can be set according to actual conditions.
[0060] For example, construct the temperature matrix T m×n , T m×n Represents a two-dimensional matrix with m rows and n columns. Each element in the temperature matrix is T i×j , T i×j Represents the temperature value of the i-th information device at the j-th time sampling point, where i is greater than 0 and less than or equal to m, and j is greater than 0 and less than or equal to n.
[0061] For example, construct the original position matrix as Pos m×2 , Pos m×2 Less than or equal to yi and greater than or equal to xi, Pos m×2 Indicates the coordinates of the mth information device located at row x and column y.
[0062] For example, construct the original state matrix S m×3 , S m×3 The one-hot encoding represents the three states of the m-th information device. The three states of the information device include: the information device is next to the turned-on air conditioner (can be recorded as: [0, 0, 1]); the information device is not next to the turned-on air conditioner (can be recorded as: [0, 1, 0]); the information device is next to the turned-off air conditioner (can be recorded as: [1, 0, 0].
[0063] Figure 2 for Figure 1 The flowchart of generating multiple eigenvectors according to the constructed temperature matrix, original position matrix and original state matrix is as follows: Figure 2 As shown, step 102 includes:
[0064] Step 1022: Perform matrix encoding on the original position matrix by using an embedding algorithm to generate a position matrix.
[0065] Specifically, construct the first embedding matrix Em 2×n , the first embedding matrix Em 2×n and the original position matrix Pos m×2 Perform cross multiplication operation to generate the position matrix Pos m×n .
[0066] Step 1024: Perform matrix encoding on the original state matrix through an embedding algorithm to generate a state matrix.
[0067] Specifically, construct the second embedding matrix Em 3×n , the second embedding matrix Em 3×n With the original state matrix S m×3 Perform cross multiplication operation to generate state matrix S m×n .
[0068] Step 1026: perform an addition operation on the temperature matrix, the position matrix, and the state matrix to generate an addition matrix.
[0069] For example, for the temperature matrix T m×n , Position matrix Pos m×n and the state matrix S m×n Perform addition operation to generate addition matrix E m×n .
[0070] Step 1028: Perform transpose calculation on the addition matrix to generate an addition transposed matrix.
[0071] For example, for the addition matrix E m×n Perform transpose calculation to generate the additive transpose matrix E' n×m .
[0072] Step 1030: Split the added transposed matrix to generate multiple eigenvectors.
[0073] For example, add the transposed matrix E' n×m Split and generate multiple feature vectors. For example, multiple feature vectors include: F1 1×n 、F2 1×n ...Fm 1×n .
[0074] Step 104: Perform feature encoding on each feature vector to generate an output vector corresponding to each feature vector.
[0075] Specifically, a Bidirectional Encoder Representations from Transformers (BERT) model is constructed to perform feature encoding on each feature vector and generate an output vector corresponding to each feature vector.
[0076] Figure 3 for Figure 1 In the flowchart, each feature vector is encoded and the output vector corresponding to each feature vector is generated, as shown in Figure 3 As shown, step 104 includes:
[0077] Step 1042: Perform a cross product calculation on the constructed first weight matrix and each eigenvector to generate an input coding matrix.
[0078] In this step, the first weight matrix Wq is constructed n×n , for the first weight matrix Wq n×n With each eigenvector Fi 1×n Perform cross multiplication calculation to generate input encoding matrix Q m×n . Wherein, i is greater than 0 and less than or equal to m.
[0079] Step 1044: Perform a cross product calculation on the constructed second weight matrix and each eigenvector to generate an input weight matrix.
[0080] In this step, the second weight matrix Wk is constructed n×n , for the second weight matrix Wk n×n With each eigenvector Fi 1×n Perform cross multiplication calculation to generate input weight matrix K m×n . Wherein, i is greater than 0 and less than or equal to m.
[0081] Step 1046: Perform a cross product calculation on the constructed third weight matrix and each eigenvector to generate an output weight matrix.
[0082] In this step, the third weight matrix Wv is constructed n×n , for the third weight matrix Wv n×n With each eigenvector Fi 1×n Perform cross multiplication calculation to generate the output weight matrix V m×n . Wherein, i is greater than 0 and less than or equal to m.
[0083] Step 1048: Generate a self-attention encoding matrix based on the input encoding matrix and the input weight matrix.
[0084] Specifically, through the formula The input encoding matrix and the input weight matrix are calculated to generate the self-attention encoding matrix, where A is the self-attention encoding matrix, Q is the input encoding matrix, K is the input weight matrix, and m is the number of rows in the input encoding matrix.
[0085] Step 1050: Calculate the self-attention encoding matrix using the softmax algorithm to generate a probability matrix.
[0086] For example, the self-attention encoding matrix A is calculated by the softmax algorithm to generate the probability matrix P m×n .
[0087] In the embodiment of the present invention, the probability matrix P m×n Able to simulate each eigenvector Fi 1×n The higher the contribution, the higher the correlation between the eigenvalues and the greater the dependency.
[0088] Step 1052: Perform a cross product calculation on the probability matrix and the output weight matrix to generate a feedforward vector encoding matrix.
[0089] For example, for the probability matrix P m×n With the output weight matrix V m×n Perform cross multiplication calculation to generate the feedforward vector encoding matrix Out m×n .
[0090] Step 1054: Split the feedforward vector encoding matrix to generate multiple output vectors.
[0091] For example, the feedforward vector encoding matrix Out m×n Split and generate multiple output vectors. Multiple output vectors include: Out1 1×n 、Out2 1×n ...Outm 1×n .
[0092] Step 106: Generate a predicted temperature vector corresponding to each output vector based on the multiple output vectors.
[0093] Specifically, multiple output vectors are calculated using a gradient boosting decision tree (GBDT) algorithm to generate a predicted temperature vector corresponding to each output vector.
[0094] For example, the gradient boosting decision tree (GBDT) algorithm is used to calculate multiple output vectors Out1. 1×n 、Out2 1×n ...Outm 1×n Calculate and generate the predicted temperature vector corresponding to each output vector. Multiple predicted temperature vectors include: Pred1, Pred2...Pred m Among them, the output vector Out1 1×n Corresponding to the predicted temperature vector Pred1, the output vector Out2 1×n Corresponding to the predicted temperature vector Pred2...output vector Outm 1×n Corresponding to the predicted temperature vector Pred m .
[0095] Step 108: Predict the temperature based on the multiple predicted temperature vectors.
[0096] In this step, the i-th predicted temperature vector Pred among the multiple predicted temperature vectors i It can be used as the predicted temperature value of the i-th information device at the set time, and the predicted temperature value can be used to predict the temperature. Wherein, i is greater than 0 and less than or equal to m.
[0097] In the technical solution provided by the embodiment of the present invention, multiple eigenvectors are generated based on a constructed temperature matrix, an original position matrix, and an original state matrix; feature encoding is performed on each eigenvector to generate an output vector corresponding to each eigenvector; a predicted temperature vector corresponding to each output vector is generated based on the multiple output vectors; and temperature is predicted based on the multiple predicted temperature vectors. In the technical solution provided by the embodiment of the present invention, a predicted temperature vector can be generated based on the constructed temperature matrix, the original position matrix, and the original state matrix, thereby enabling temperature prediction of an information device based on the predicted temperature vector, thereby improving the efficiency of temperature prediction.
[0098] The technical solution provided by the embodiment of the present invention can assist in adjusting the cooling system of the computer room through an intelligent temperature prediction mechanism, reduce high-temperature alarm failures of information equipment, reduce the energy consumption of the computer room and the power usage effectiveness (PUE) value of the data center, and realize green and energy-saving operation and maintenance of the data center.
[0099] In the technical solution provided by the embodiment of the present invention, the encoding of the location information of the information device and the interaction information between the information device and the air conditioner is added through the position matrix and the state matrix, so that the BERT model can extract richer local feature information, which can greatly improve the accuracy of temperature prediction.
[0100] In the technical solution provided by the embodiments of the present invention, the temperature of an information device is interdependent with the temperatures of other information devices and air conditioners in the local area. A BERT network model is used to predict the temperature. By using a self-attention layer to extract dependencies, the model can focus on important feature information, thereby better extracting local features and improving the accuracy of feature representation. BERT also possesses strong generalization capabilities, further improving the accuracy of temperature prediction. Furthermore, while increasing the accuracy of feature information extraction by the BERT model, it reduces steps such as data analysis, screening, and staged input, simplifying the complexity of data processing and facilitating model training and application.
[0101] In the technical solution provided by the embodiment of the present invention, only one BERT model needs to be trained for temperature prediction, which further improves the generalization ability and universality of the model and increases the portability of the model.
[0102] In the technical solution provided by the embodiment of the present invention, the cooling system of the computer room is assisted in adjustment based on the predicted temperature. Unlike the traditional method of first triggering a high temperature alarm and then cooling the local hot spots in the computer room, through intelligent temperature prediction, potential local hot spot hazards can be discovered in advance, and cooling measures such as lowering the set temperature of the cooling system and starting the backup air conditioner can be taken in time, effectively reducing the impact of high temperature weather on information equipment, reducing high temperature alarms of information equipment, and ensuring safe and stable operation of the network during the high temperature period in summer.
[0103] An embodiment of the present invention provides a temperature prediction device. Figure 4 A schematic diagram of a temperature prediction device provided by an embodiment of the present invention is shown in FIG. Figure 4 As shown, the device includes: a first generating module 11, a second generating module 12, a third generating module 13 and a prediction module 14.
[0104] The first generating module 11 is used to generate a plurality of eigenvectors according to the constructed temperature matrix, original position matrix and original state matrix.
[0105] The second generating module 12 is used to perform feature encoding on each feature vector and generate an output vector corresponding to each feature vector.
[0106] The third generating module 13 is configured to generate a predicted temperature vector corresponding to each output vector based on the multiple output vectors.
[0107] The prediction module 14 is configured to predict the temperature based on a plurality of predicted temperature vectors.
[0108] Figure 5 for Figure 4 The structural diagram of the first generation module 11 is as follows: Figure 5 As shown, the first generation module 11 includes: a first generation submodule 111 , a second generation submodule 112 , a third generation submodule 113 , a fourth generation submodule 114 and a fifth generation submodule 115 .
[0109] The first generating submodule 111 is used to perform matrix encoding on the original position matrix through an embedding algorithm to generate a position matrix.
[0110] The second generating submodule 112 is used to perform matrix encoding on the original state matrix through an embedding algorithm to generate a state matrix.
[0111] The third generating submodule 113 is used to perform an addition operation on the temperature matrix, the position matrix and the state matrix to generate an addition matrix.
[0112] The fourth generating submodule 114 is used to perform a transpose calculation on the addition matrix to generate an addition transposed matrix.
[0113] The fifth generating submodule 115 is used to split the addition transposed matrix to generate multiple eigenvectors.
[0114] In the embodiment of the present invention, the second generating module 12 is specifically configured to perform feature encoding on each feature vector by using the constructed bidirectional encoder representation model from the converter, and generate an output vector corresponding to each feature vector.
[0115] Figure 6 for Figure 4The structural diagram of the second generation module 12 is as follows: Figure 6 As shown, the second generation module 12 includes: a sixth generation submodule 121, a seventh generation submodule 122, an eighth generation submodule 123, a ninth generation submodule 124, a tenth generation submodule 125, an eleventh generation submodule 126 and a twelfth generation submodule 127.
[0116] The sixth generating submodule 121 is used to perform a cross product calculation on the constructed first weight matrix and each eigenvector to generate an input coding matrix.
[0117] The seventh generating submodule 122 is used to perform a cross product calculation on the constructed second weight matrix and each eigenvector to generate an input weight matrix.
[0118] The eighth generating submodule 123 is used to perform a cross product calculation on the constructed third weight matrix and each eigenvector to generate an output weight matrix.
[0119] The ninth generation submodule 124 is used to generate a self-attention encoding matrix based on the input encoding matrix and the input weight matrix.
[0120] The tenth generation submodule 125 is used to calculate the self-attention encoding matrix through the softmax algorithm to generate a probability matrix.
[0121] The eleventh generating submodule 126 is used to perform a cross product calculation on the probability matrix and the output weight matrix to generate a feedforward vector encoding matrix.
[0122] The twelfth generating submodule 127 is used to split the feedforward vector encoding matrix to generate multiple output vectors.
[0123] In the embodiment of the present invention, the third generating module 13 is specifically configured to calculate the multiple output vectors using a gradient boosting decision tree (GBDT) algorithm to generate a predicted temperature vector corresponding to each output vector.
[0124] In the embodiment of the present invention, the ninth generating submodule 124 is specifically configured to generate The input encoding matrix and the input weight matrix are calculated to generate the self-attention encoding matrix, where A is the self-attention encoding matrix, Q is the input encoding matrix, K is the input weight matrix, and m is the number of rows in the input encoding matrix.
[0125] In the technical solution provided by the embodiment of the present invention, multiple eigenvectors are generated based on a constructed temperature matrix, an original position matrix, and an original state matrix; feature encoding is performed on each eigenvector to generate an output vector corresponding to each eigenvector; a predicted temperature vector corresponding to each output vector is generated based on the multiple output vectors; and temperature is predicted based on the multiple predicted temperature vectors. In the technical solution provided by the embodiment of the present invention, a predicted temperature vector can be generated based on the constructed temperature matrix, the original position matrix, and the original state matrix, thereby enabling temperature prediction of an information device based on the predicted temperature vector, thereby improving the efficiency of temperature prediction.
[0126] The temperature prediction device provided in this embodiment can be used to achieve the above Figure 1 、 Figure 2 and Figure 3 The temperature prediction method in , for a detailed description, please refer to the embodiment of the temperature prediction method mentioned above, which will not be repeated here.
[0127] An embodiment of the present invention provides a storage medium, which includes a stored program, wherein when the program is running, the device where the storage medium is located is controlled to execute the steps of the embodiment of the above-mentioned temperature prediction method. For a specific description, please refer to the embodiment of the above-mentioned temperature prediction method.
[0128] An embodiment of the present invention provides a computer device including a memory and a processor, wherein the memory is used to store information including program instructions, and the processor is used to control the execution of the program instructions. When the program instructions are loaded and executed by the processor, the steps of the embodiment of the above-mentioned temperature prediction method are implemented. For a specific description, please refer to the embodiment of the above-mentioned temperature prediction method.
[0129] Figure 7 Schematic diagram of a computer device provided by an embodiment of the present invention. Figure 7 As shown, the computer device 20 of this embodiment includes: a processor 21, a memory 22, and a computer program 23 stored in the memory 22 and executable on the processor 21. When executed by the processor 21, the computer program 23 implements the temperature prediction method applied in the embodiment. To avoid repetition, a detailed description is not given here. Alternatively, when executed by the processor 21, the computer program implements the functions of each model / unit in the temperature prediction device applied in the embodiment. To avoid repetition, a detailed description is not given here.
[0130] The computer device 20 includes, but is not limited to, a processor 21 and a memory 22. Those skilled in the art will understand that Figure 7 This is merely an example of the computer device 20 and does not constitute a limitation of the computer device 20 . The computer device 20 may include more or fewer components than shown in the figure, or a combination of certain components, or different components. For example, the computer device may also include input and output devices, network access devices, buses, etc.
[0131] The processor 21 may be a central processing unit (CPU), or other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), field-programmable gate arrays (FPGA), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. The general-purpose processor may be a microprocessor or any conventional processor.
[0132] The memory 22 can be an internal storage unit of the computer device 20, such as the hard disk or memory of the computer device 20. The memory 22 can also be an external storage device of the computer device 20, such as a plug-in hard disk, a Smart Media Card (SMC), a Secure Digital (SD) card, a flash memory card, etc. equipped on the computer device 20. Furthermore, the memory 22 can include both the internal storage unit of the computer device 20 and an external storage device. The memory 22 is used to store computer programs and other programs and data required by the computer device. The memory 22 can also be used to temporarily store data that has been output or is about to be output.
[0133] 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.
[0134] In the several embodiments provided by the present invention, it should be understood that the disclosed systems, devices and methods can be implemented in other ways. For example, the device embodiments described above are merely illustrative. For example, the division of the units is merely a logical function division. In actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. In addition, the mutual coupling or direct coupling or communication connection shown or discussed may be an indirect coupling or communication connection through some interface, device or unit, which may be electrical, mechanical or other forms.
[0135] The units described as separate components may or may not be physically separate, and the 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.
[0136] In addition, the functional units in various embodiments of the present invention may be integrated into a single processing unit, each unit may exist physically separately, or two or more units may be integrated into a single unit. The aforementioned integrated units may be implemented in the form of hardware or hardware plus software functional units.
[0137] The above-mentioned integrated unit implemented in the form of a software functional unit can be stored in a computer-readable storage medium. The above-mentioned software functional unit is stored in a storage medium and includes a number of instructions for causing a computer device (which can be a personal computer, server, or network device, etc.) or a processor to perform some steps of the method described in various embodiments of the present invention. The aforementioned storage medium includes: a USB flash drive, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk, or an optical disk, etc., various media that can store program code.
[0138] The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the present invention should be included in the scope of protection of the present invention.
Claims
1. A temperature prediction method, characterized in that: include: Generate multiple eigenvectors according to the constructed temperature matrix, original position matrix and original state matrix; Perform feature encoding on each eigenvector and generate the output vector corresponding to each eigenvector; According to the multiple output vectors, a predicted temperature vector corresponding to each output vector is generated; predicting temperature based on a plurality of predicted temperature vectors; The method generates multiple eigenvectors based on the constructed temperature matrix, original position matrix and original state matrix, including: Performing matrix encoding on the original position matrix by an embedding algorithm to generate a position matrix; Performing matrix encoding on the original state matrix by an embedding algorithm to generate a state matrix; performing an addition operation on the temperature matrix, the position matrix, and the state matrix to generate an addition matrix; Performing a transpose calculation on the addition matrix to generate an addition transposed matrix; Splitting the added transposed matrix to generate multiple eigenvectors; The feature encoding of each feature vector to generate an output vector corresponding to each feature vector includes: By constructing a bidirectional encoder representation model from the transformer, each feature vector is feature encoded to generate an output vector corresponding to each feature vector; Generating a predicted temperature vector corresponding to each output vector according to the multiple output vectors includes: The gradient boosting decision tree (GBDT) algorithm is used to calculate multiple output vectors and generate a predicted temperature vector corresponding to each output vector.
2. The method according to claim 1, characterized in that The bidirectional encoder representation model from the converter is constructed to perform feature encoding on each feature vector and generate an output vector corresponding to each feature vector, including: Perform cross multiplication calculation on the constructed first weight matrix and each eigenvector to generate an input encoding matrix; Perform cross product calculation on the constructed second weight matrix and each eigenvector to generate an input weight matrix; Perform cross product calculation on the constructed third weight matrix and each eigenvector to generate an output weight matrix; Generate a self-attention encoding matrix according to the input encoding matrix and the input weight matrix; Calculate the self-attention encoding matrix using a softmax algorithm to generate a probability matrix; Performing a cross product calculation on the probability matrix and the output weight matrix to generate a feedforward vector encoding matrix; The feedforward vector encoding matrix is split to generate multiple output vectors.
3. The method according to claim 2, characterized in that Generating a self-attention encoding matrix according to the input encoding matrix and the input weight matrix includes: By formula The input encoding matrix and the input weight matrix are calculated to generate a self-attention encoding matrix, where A is the self-attention encoding matrix, Q is the input encoding matrix, K is the input weight matrix, and m is the number of rows of the input encoding matrix.
4. A temperature prediction device, characterized in that: include: A first generating module is used to generate a plurality of eigenvectors according to the constructed temperature matrix, the original position matrix and the original state matrix; The second generation module is used to perform feature encoding on each feature vector and generate an output vector corresponding to each feature vector; A third generating module is used to generate a predicted temperature vector corresponding to each output vector according to the multiple output vectors; A prediction module, configured to predict temperature based on a plurality of predicted temperature vectors; The first generation module includes: A first generating submodule is configured to perform matrix encoding on the original position matrix through an embedding algorithm to generate a position matrix; A second generating submodule is used to perform matrix encoding on the original state matrix through an embedding algorithm to generate a state matrix; A third generating submodule is configured to perform an addition operation on the temperature matrix, the position matrix, and the state matrix to generate an addition matrix; a fourth generating submodule, configured to perform a transpose calculation on the addition matrix to generate an addition transposed matrix; A fifth generating submodule, configured to split the additive transposed matrix to generate a plurality of eigenvectors; The second generating module is specifically configured to perform feature encoding on each feature vector by using a bidirectional encoder representation model from a transformer, and generate an output vector corresponding to each feature vector; The third generation module is specifically used to calculate multiple output vectors through the gradient boosting decision tree GBDT algorithm to generate a predicted temperature vector corresponding to each output vector.
5. A storage medium, characterized in that: include: The storage medium includes a stored program, wherein when the program is executed, the device where the storage medium is located is controlled to execute the temperature prediction method according to any one of claims 1 to 3.
6. A computer device comprising a memory and a processor, wherein the memory is used to store information including program instructions, and the processor is used to control the execution of the program instructions, characterized in that: When the program instructions are loaded and executed by a processor, the steps of the temperature prediction method according to any one of claims 1 to 3 are implemented.
Citation Information
Patent Citations
A method for constructing a multi-sensor data prediction model of a refrigerating unit
CN109697304A
Device for controlling performance of the device based on fluctuations in internal temperature and method thereof
US20160062326A1