A distributed multi-dimensional information data verification method for Internet of Things terminals
By building temperature sensor coding standards and deep learning technology, real-time analysis and verification of the temperature data of IoT terminals has been solved, and the problem of inability to accurately verify temperature data in the existing technology is solved, and timely detection and processing of abnormal data is realized.
Patent Information
- Application Number
- CN202510006496.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-01-03
- Publication Date
- 2025-05-13
- Estimated Expiration
- 2045-01-03
AI Technical Summary
Existing temperature data verification technologies cannot use temperature sensors to collect temperatures, while real-time and accurate analysis and verification of whether the collected temperature is abnormal, resulting in errors in control behavior or serious consequences.
By constructing temperature sensor coding standards, and mapping and encoding of distributed temperature sensors, collecting temperature data and related data for analysis and verification, combining deep learning technology to predict temperature, and conducting a second data analysis and verification to achieve real-time and accurate abnormal data detection.
Real-time and accurate analysis and verification of whether the collected temperature is abnormal, timely discover and judge data abnormalities and environmental abnormalities, and improve the accuracy and efficiency of temperature information verification.
Smart Images

Figure CN119397462B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of data verification, and in particular to a distributed multi-dimensional information data verification method for an Internet of Things terminal. Background Art
[0002] Temperature data verification technology refers to a series of technologies used to ensure the accuracy, integrity, consistency and reliability of temperature data; most of the current IoT terminals are equipped with temperature sensors, such as ventilation equipment, refrigeration equipment and smart thermostats. They are one of the basic components of the IoT system to achieve data collection, analysis and intelligent management, which is of great significance for ensuring the normal operation of equipment, improving production efficiency and promoting industry development.
[0003] Existing temperature data verification technology often does not perform verification during the temperature information collection process, or only performs simple verification. For example, the collected temperature information is verified based on the measurable range of the temperature sensor, and it is judged as abnormal if it exceeds the measurable range. The collected temperature information is not verified when it is collected, and control is performed directly based on the collected temperature information. If the collected temperature information is wrong, it will inevitably lead to control behavior errors and even cause serious consequences. By using mathematical means to analyze and verify the temperature information collected at different times to obtain abnormal data, this method can often only be operated after collection, and it is necessary to rely on the normal data before and after the abnormal data for analysis and verification. It cannot be applied to IoT terminals that are adjusted in real time, for example, Smart air conditioners need to collect indoor temperature in real time to adjust the cooling and heating temperatures. However, this method cannot verify in real time whether the indoor temperature collected by the smart air conditioner is normal, and can only identify data with larger abnormalities, and the verification accuracy is not high. Placing multiple temperature sensors of the same or different types in the same measurement environment, measuring the temperature at the same time, and then comparing the measurement results, although this method can verify the collected data in real time, it is not accurate enough and has a lag in the judgment of abnormal conditions. Therefore, the existing temperature data verification technology cannot use the temperature sensor to collect temperature while combining the basic parameters of the temperature sensor with deep learning technology to perform real-time and accurate analysis and verification on whether the collected temperature is abnormal, and timely discover and judge data anomalies and environmental abnormalities. Summary of the invention
[0004] The present invention aims to solve one of the technical problems in the prior art to at least a certain extent, by collecting first temperature data and first related data through a distributed temperature sensor, and performing a first data analysis and verification to obtain second temperature data; collecting second related data, predicting the temperature based on the second temperature data and the second related data, and performing a second data analysis and verification; so as to solve the problem that the existing temperature data verification technology is unable to use the temperature sensor to collect the temperature while using the basic parameters of the temperature sensor combined with deep learning technology to perform real-time and accurate analysis and verification on whether the collected temperature is abnormal, and timely discover and judge data anomalies and environmental abnormalities.
[0005] To achieve the above purpose, the present application provides a distributed multi-dimensional information data verification method for an Internet of Things terminal, comprising the following steps:
[0006] Construct temperature sensor coding standards and perform mapping and coding processing on distributed temperature sensors;
[0007] Collecting first temperature data and first related data based on the distributed temperature sensor, and performing a first data analysis and verification to obtain second temperature data;
[0008] collecting second related data, and predicting the temperature based on the second temperature data and the second related data to obtain first predicted data;
[0009] A second data analysis verification is performed based on the first prediction data and the first temperature data.
[0010] Furthermore, constructing the temperature sensor coding standard includes the following sub-steps:
[0011] The device type, device name, device number and spatial location of all distributed temperature sensors in the space are obtained and marked as the basic information of the temperature sensor. A four-level temperature sensor coding standard is established based on the basic information of the temperature sensor. The temperature sensor coding standard includes: level 1 type code, level 2 name code, level 3 location code and level 4 number code.
[0012] Furthermore, mapping and encoding the distributed temperature sensors includes the following sub-steps:
[0013] Encode all distributed temperature sensors in the space based on the temperature sensor encoding standard to obtain temperature sensor encoding data, ensure that the encoding of any two distributed temperature sensors is not repeated, and record any distributed temperature sensor as Pi;
[0014] Get the codes of the x0 distributed temperature sensors closest to the distributed temperature sensor Pi, and arrange them from near to far according to the straight-line distance from the distributed temperature sensor Pi. According to the codes, mark the first x1 distributed temperature sensors as Pi direct-level temperature sensors, and mark the last x2 distributed temperature sensors as Pi secondary temperature sensors, x0=x1+x2.
[0015] Further, collecting the first temperature data and the first related data based on the distributed temperature sensor and performing a first data analysis and verification to obtain the second temperature data includes the following sub-steps:
[0016] The temperature measurement range, rated voltage range, and rated current range of all distributed temperature sensors are obtained, and stored according to the codes of the distributed temperature sensors, and marked as basic parameters of the temperature sensors;
[0017] Based on the distributed temperature sensor, temperature information is collected at a first time interval, and the time information when the temperature information is collected is recorded, and stored according to the coding of the distributed temperature sensor, marked as the first temperature data, and the first time interval is t1;
[0018] After each temperature information is collected, it is determined whether the collected temperature information is within the temperature measurement range of the corresponding distributed temperature sensor. If not, the collected temperature information is marked as invalid data. If so, the time difference between the time information when the temperature information is collected this time and the time information when the temperature information was collected last time is calculated, marked as the collected temperature time difference, and it is determined whether the collected temperature time difference is equal to the first time interval. If not, the collected temperature information is marked as time abnormality data.
[0019] Furthermore, collecting the first temperature data and the first related data based on the distributed temperature sensor and performing a first data analysis and verification to obtain the second temperature data also includes the following sub-steps:
[0020] Acquire the input voltage and input current of all distributed temperature sensors at a second time interval, record the time information when acquiring, store according to the coding of the distributed temperature sensor, mark as the first relevant data, and the second time interval is t2;
[0021] After each acquisition of the input voltage and input current of the distributed temperature sensor, determine whether the input voltage of the distributed temperature sensor acquired this time is within the rated voltage range, and whether the input current is within the rated current range based on the basic parameters of the temperature sensor. If the input voltage is not within the rated voltage range or the input current is not within the rated current range, obtain the time information when the input voltage and input current of the distributed temperature sensor were acquired last time, mark it as an invalid time, and mark the collected temperature information acquired after the invalid time as invalid data;
[0022] Based on the first temperature data, invalid data and time abnormal data in the first temperature data are eliminated, and after completion, the second temperature data is obtained.
[0023] Further, collecting the second related data, predicting the temperature based on the second temperature data and the second related data, and obtaining the predicted temperature data includes the following sub-steps:
[0024] collecting weather temperature at first time intervals and marking them as second relevant data;
[0025] The missing temperature information in the second temperature data due to the removal of the abnormal time data is filled by using the weighted average of the latest x3 non-missing temperature information before the missing temperature information and the latest x3 non-missing temperature information after the missing temperature information, and the filled second temperature data is marked as the third temperature data;
[0026] The third temperature data and the second related data are combined and stored according to the data collection time, and the first temperature training set and the first temperature test set are divided into a ratio of 7:3;
[0027] The first temperature training set and the first temperature test set are normalized, and the air temperature data size and the temperature data size in the first temperature training set and the first temperature test set are normalized to [0, 1]. After completion, the second temperature training set and the second temperature test set are obtained.
[0028] Furthermore, collecting the second related data, predicting the temperature based on the second temperature data and the second related data, and obtaining the first predicted data also includes the following sub-steps:
[0029] A multilayer perceptron model is selected, and improvements to the multilayer perceptron model include: setting the number of neurons in the input layer of the multilayer perceptron model to Y0, setting the number of hidden layers of the multilayer perceptron model to Z0, setting the number of neurons in the first hidden layer to Y1, setting the number of neurons in the second hidden layer to Y2, setting the number of neurons in the output layer of the multilayer perceptron model to Y3, setting the activation function from the input layer to the first hidden layer and the activation function from the first hidden layer to the second hidden layer to the ReLU function; after completion, the first initial model is obtained.
[0030] Furthermore, collecting the second related data, predicting the temperature based on the second temperature data and the second related data, and obtaining the predicted temperature data also includes the following sub-steps:
[0031] Setting model training hyperparameters includes: setting the learning rate to a1, the batch size to a2, and the training rounds to a3; defining the mean square error as the loss function for model training; defining the mean absolute error as the evaluation function for the model, and setting the model qualification threshold to B0;
[0032] The first initial model is trained using the second temperature training set of the second block, and a second initial model is obtained after the training is completed;
[0033] The second initial model is tested using the second temperature test set, the average absolute error and the maximum absolute error of the second initial model are calculated, the average absolute error value A0 and the maximum absolute error A1 of the second initial model are obtained, and it is determined whether A0 satisfies A0≤B0. If so, the second initial model is marked as the third prediction model; the average absolute error value A0 is recorded, marked as the model average difference; the maximum absolute error A1 is recorded, marked as the model maximum difference;
[0034] If not, adjust the model training hyperparameters, the number of neurons in the first hidden layer Y1, and the number of neurons in the second hidden layer Y2. After the adjustment, use the second temperature training set to train the second initial model. After completion, use the second temperature test set to test again until the third prediction model, the model average difference, and the model maximum difference are obtained.
[0035] Normalization processing is performed based on the third temperature data, and then the future temperature is predicted using the third prediction model to obtain first prediction data.
[0036] Furthermore, performing a second data analysis verification based on the first prediction data and the first temperature data includes the following sub-steps:
[0037] Set the data suspected abnormal threshold to R0, and the value range of R0 is [A0, A1];
[0038] When the distributed temperature sensor collects temperature information at a first time interval, each time a temperature information is collected, based on the recorded time information when the temperature information is collected, the predicted temperature information with the same time information in the first prediction data is used to calculate the error value with the collected temperature information to obtain the actual error R1. When the actual error R1>R0, the collected temperature information is marked as suspected abnormal data.
[0039] Furthermore, performing a second data analysis verification based on the first prediction data and the first temperature data further includes the following sub-steps:
[0040] Based on the temperature sensor Pi of the suspected abnormal data in time information and the collected time information, obtain the temperature information collected by the Pi direct temperature sensor under the same collected time information, and mark it as the direct temperature information; and obtain the temperature information collected by the Pi secondary temperature sensor and mark it as the secondary temperature information; obtain whether the direct temperature information and the secondary temperature information are suspected abnormal data, if K% of the direct temperature information and the secondary temperature information are suspected abnormal data, cancel the mark of the suspected abnormal data.
[0041] Beneficial effects of the present invention: The present invention constructs a temperature sensor coding standard and performs mapping coding processing on distributed temperature sensors; collects first temperature data and first related data based on distributed temperature sensors, and performs a first data analysis and verification to obtain second temperature data; collects second related data, predicts temperature based on the second temperature data and the second related data, and obtains first predicted data; performs a second data analysis and verification based on the first predicted data and the first temperature data; while using the temperature sensor to collect temperature, the basic parameters of the temperature sensor are combined with deep learning technology to perform real-time and accurate analysis and verification on whether the collected temperature is abnormal, and timely discover and judge data anomalies and environmental abnormalities;
[0042] The present invention predicts the future temperature by improving the multi-layer perceptron, and uses the prediction results to verify the collected temperature information in real time. The advantage is that the complex patterns and trends in the temperature data can be better captured, thereby improving the accuracy of verifying the temperature information. Weather and temperature data are added when predicting the future temperature, because changes in weather and temperature often affect changes in temperature in a certain space. By adding weather and temperature data, the prediction accuracy can be improved and the generalization ability of the model can be enhanced, thereby improving the accuracy of verifying the temperature information. The first analysis and verification is performed through the basic parameters of the temperature sensor. The advantage is that some obviously abnormal data can be screened and excluded first, and then carefully verified through the second analysis and verification, thereby improving the efficiency of the analysis and verification. BRIEF DESCRIPTION OF THE DRAWINGS
[0043] Figure 1is a flow chart of the steps of the method of the present invention;
[0044] Figure 2 It is a schematic diagram of the temperature sensor coding of the present invention;
[0045] Figure 3 is a first initial model structure diagram of the present invention;
[0046] Figure 4 It is a schematic structural diagram of the electronic device of the present invention. DETAILED DESCRIPTION
[0047] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part 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 ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0048] Example 1, please refer to Figure 1 As shown, in the first aspect, the present application provides a distributed multi-dimensional information data verification method for an Internet of Things terminal, comprising the following steps:
[0049] Step S1, constructing a temperature sensor coding standard and performing mapping coding processing on distributed temperature sensors; Step S1 includes the following sub-steps:
[0050] Step S101, obtaining the device type, device name, device number and spatial location of all distributed temperature sensors in the space, and marking them as basic information of the temperature sensors;
[0051] Step S102, see Figure 2 As shown, a total of four levels of temperature sensor coding standards are established based on the basic information of the temperature sensor. The temperature sensor coding standards include: level 1 type code, level 2 name code, level 3 location code and level 4 number code. The significance of coding the temperature sensor is to ensure the uniqueness and identifiability of each temperature sensor, so that the system can accurately read and operate the data of a specific temperature sensor. Through coding, data from different temperature sensors can be distinguished to avoid data confusion, thereby improving the accuracy of subsequent data verification;
[0052] Step S103, encoding all distributed temperature sensors in the space based on the temperature sensor encoding standard to obtain temperature sensor encoding data, ensuring that the encodings of any two distributed temperature sensors are not repeated, ensuring the uniqueness and identifiability of each temperature sensor, and denoting any distributed temperature sensor as Pi, where Pi represents the i-th temperature sensor, and the specific data form is the encoding of the i-th temperature sensor;
[0053] Step S104, obtain the codes of the x0 distributed temperature sensors closest to the distributed temperature sensor Pi, and arrange them from near to far according to the straight-line distance from the distributed temperature sensor Pi, and mark the first x1 distributed temperature sensors as Pi direct temperature sensors according to the codes, and mark the last x2 distributed temperature sensors as Pi secondary temperature sensors, x0=x1+x2; x0, x1 and x2 can be set according to the density of the distributed temperature sensors, for example, there are 20 temperature sensors arranged on the ceiling of a 120-square-meter room, then x0 can be set to 5, x1 can be set to 2, and x2 can be 3; that is, for any temperature sensor, such as P8, the 5 temperature sensors closest to P8 are arranged from near to far, the two closest ones are marked as P8 direct temperature sensors, and the remaining 3 are marked as P8 secondary temperature sensors;
[0054] In the specific implementation process, most of the current Internet of Things terminals are equipped with temperature sensors, which are one of the basic components of the Internet of Things system to realize data collection, analysis and intelligent management. They are of great significance for ensuring the normal operation of equipment, improving production efficiency and promoting industry development. Common types of temperature sensors include thermal resistor temperature sensors, thermocouple temperature sensors, thermistor temperature sensors, digital temperature sensors, infrared temperature sensors and optical fiber temperature sensors. In this embodiment, a digital temperature sensor is used. The digital temperature sensor is produced using silicon technology and integrates temperature sensors, A / D converters, control logic and other circuits to directly output digital signals.
[0055] Step S2, collecting the first temperature data and the first related data based on the distributed temperature sensor, and performing a first data analysis and verification to obtain the second temperature data; Step S2 includes the following sub-steps:
[0056] Step S201, obtaining the temperature measurement range, rated voltage range and rated current range of all distributed temperature sensors, and storing them according to the codes of the distributed temperature sensors, and marking them as basic parameters of the temperature sensors; different temperature sensors have different temperature measurement ranges, rated voltage ranges and rated current ranges. For example, in this embodiment, the temperature measurement range of the digital temperature sensor used is [-55°C, 125°C], the rated voltage range is [3V, 5.5V], and the rated current range is [0.5MA, 1MA];
[0057] Step S202: Based on the distributed temperature sensor, temperature information is collected at a first time interval, and the time information when the temperature information is collected is recorded, and the temperature information is stored according to the coding of the distributed temperature sensor, marked as the first temperature data, and the first time interval is t1; in this embodiment, the first time interval t1 is 10s, that is, the temperature information is collected once every 10s;
[0058] Step S203, after each temperature information is collected, it is determined whether the collected temperature information is within the temperature measurement range of the corresponding distributed temperature sensor. If not, the collected temperature information is marked as invalid data; when the collected temperature information is not within the corresponding temperature measurement range, it means that the temperature sensor is damaged, so the collected temperature information is invalid data;
[0059] Step S204, if yes, then calculate the time difference between the time information when the temperature information is collected this time and the time information when the temperature information is collected last time, mark it as the collected temperature time difference, and determine whether the collected temperature time difference is equal to the first time interval. If not, mark the collected temperature information as time abnormal data;
[0060] Step S205, acquiring the input voltage and input current of all distributed temperature sensors at a second time interval, and recording the time information when acquiring, storing according to the coding of the distributed temperature sensor, marking as the first relevant data, and the second time interval is t2; in this embodiment, the second time interval t2 is 30s, the first time interval t1 and the second time interval t2 can be set according to the actual application scenario, and in general, in order to reduce power consumption cost, the second time interval should not be too small, generally t2 ≥ t1;
[0061] Step S205: after obtaining the input voltage and input current of the distributed temperature sensor each time, determine whether the input voltage of the distributed temperature sensor obtained this time is within the rated voltage range, and whether the input current is within the rated current range based on the basic parameters of the temperature sensor.
[0062] Step S206, if the input voltage is not within the rated voltage range or the input current is not within the rated current range, then the time information when the input voltage and input current of the distributed temperature sensor were obtained last time is obtained, marked as an invalid time, and the collected temperature information obtained after the invalid time is marked as invalid data; because if the input voltage and input current of the temperature sensor obtained this time are abnormal, it means that the temperature sensor has been abnormal before this acquisition. For example, the second time interval t2 is 30s, and the input voltage and input current of the temperature sensor obtained at 14:30:30 are abnormal, then the temperature information obtained after 14:30:00 may be abnormal, so it is marked as invalid data;
[0063] Step S207, based on the first temperature data, remove invalid data and time abnormal data in the first temperature data, and obtain second temperature data after completion;
[0064] During the specific implementation process, if the time information when the temperature information is collected this time is not equal to the time information when the temperature information was collected last time, it may be that the timing device of the temperature sensor fluctuates, or the temperature sensor is damaged. It can be judged in combination with the input voltage and input current collected most recently. If the input voltage and input current are normal, it is that the timing device of the temperature sensor fluctuates. Then the temperature information collected this time is the actual temperature at that moment, but because the collection time is incorrect, although it has a certain reference value, it is not conducive to subsequent processing, so it is also eliminated.
[0065] Step S3, collecting second related data, predicting the temperature based on the second temperature data and the second related data, and obtaining first predicted data; Step S3 includes the following sub-steps:
[0066] Step S301, collecting weather and temperature at a first time interval, that is, collecting weather and temperature once each time temperature information is collected, ensuring that the collection time of the two is consistent; marked as second related data, weather and temperature will affect the temperature change in the building, adding weather data can improve the accuracy of subsequent temperature prediction;
[0067] Step S302: The temperature information missing in the second temperature data due to the removal of the time abnormal data is filled by using the latest x3 non-missing temperature information before the missing temperature information and the latest x3 non-missing temperature information after the missing temperature information. In this embodiment, x3=2, x3 should not be too large, generally [2, 5], and a weighted average is calculated to fill the missing temperature information. The filled second temperature data is marked as the third temperature data; for example, the two data before the missing data H3 are H1=25.4℃ and H2=25.6 ℃, then two data H4=25.9℃, H5=25.7℃, because H2 and H4 are closer to H3 in time scale, so H2 and H4 are given a weight of 0.35, while H1 and H5 are farther away from H3 in time scale, so H1 and H5 are given a weight of 0.15, so H3=0.15*25.4+0.35*25.6+0.35*25.9+0.15*25.7=25.69℃, when assigning weights, the total weight should be equal to 1, and the closer the time distance, the greater the weight;
[0068] Step S303, the third temperature data and the second related data are combined and stored according to the data collection time, that is, the temperature information at the same time is stored together with the weather temperature; and the first temperature training set and the first temperature test set are divided according to the ratio of 7:3;
[0069] Step S304, normalize the first temperature training set and the first temperature test set, and normalize the air temperature data size and the temperature data size in the first temperature training set and the first temperature test set to [0, 1]. The normalization formula is as follows: W1=W0 / Wm, where W1 is the normalized value, W0 is the original value, and Wm is the maximum value in the first temperature training set and the first temperature test set. It can also be set by yourself. For example, in this embodiment, the temperature measurement range of the digital temperature sensor used is [-55°C, 125°C], and Wm can be set to 125. After completion, the second temperature training set and the second temperature test set are obtained;
[0070] Step S305, see Figure 3 As shown, Figure 3 Where L represents a neuron, a multilayer perceptron model is selected, and the improvement of the multilayer perceptron model includes: setting the number of neurons in the input layer of the multilayer perceptron model to Y0, setting the number of hidden layers of the multilayer perceptron model to Z0, setting the number of neurons in the first hidden layer to Y1, setting the number of neurons in the second hidden layer to Y2, setting the number of neurons in the output layer of the multilayer perceptron model to Y3, setting the activation function from the input layer to the first hidden layer and the activation function from the first hidden layer to the second hidden layer to the ReLU function; after completion, the first initial model is obtained; in this embodiment, Y0=3, because the input model has time, temperature and weather temperature; Y3=1, because the output is only temperature, Z0=2, Y1=32, Y2=16;
[0071] Step S306, setting the model training hyperparameters includes: setting the learning rate to a1, the batch size to a2, and the training rounds to a3; the learning rate is a hyperparameter that controls the weight update step size during the model training process, the batch size refers to the number of data samples used in each training iteration, and the training rounds refer to the number of times the model completely traverses the entire training data set. In this embodiment, a1=0.0002, a2=16, and a3=180; define the mean square error as the loss function of the model training, and the mean square error formula is as follows; , where S is the actual temperature value in the first block temperature training set, C is the predicted temperature value output by the model, MSE is the mean square error, and K is the total number of predicted temperature values output by the model; the mean absolute error is defined as the evaluation function of the model, and the mean absolute error calculation formula is as follows: , where MAE is the mean absolute error; the model qualification threshold is set to B0, in this embodiment, M0=0.1;
[0072] Step S307, using the second temperature training set of the second block to perform model training on the first initial model, and after completion, a second initial model is obtained;
[0073] Step S308, using the second temperature test set to test the second initial model, calculate the mean absolute error and the maximum absolute error of the second initial model, the maximum absolute error calculation formula is as follows: , where MAM is the maximum absolute error; obtain the average absolute error value A0 and the maximum absolute error A1 of the second initial model, determine whether A0 satisfies A0≤B0, and if so, mark the second initial model as the third prediction model; record the average absolute error value A0, marked as the model average difference; record the maximum absolute error A1, marked as the model maximum difference; the smaller the value of the average absolute error value A0, the closer the predicted value of the model is to the true value, and the higher the prediction accuracy of the model; for example, a model with an average absolute error value A0 of 0.2 is better in accuracy than a model with an average absolute error value A0 of 0.5, because the former has a smaller prediction error in the average sense;
[0074] Step S309, if not satisfied, adjust the model training hyperparameters, the number of neurons Y1 in the first hidden layer, and the number of neurons Y2 in the second hidden layer, and appropriately reduce the number of neurons Y1 in the first hidden layer and the number of neurons Y2 in the second hidden layer; after the adjustment is completed, train the second initial model with the second temperature training set, and after completion, test again with the second temperature test set until the third prediction model, the model average difference, and the model maximum difference are obtained;
[0075] Step S310, performing normalization processing based on the third temperature data, and then using the third prediction model to predict the future temperature to obtain first prediction data;
[0076] In the specific implementation process, the output layer has only one neuron, and its output value is the predicted temperature value. Because temperature is a continuous value, the output layer does not need a special activation function for classification operations, and can directly output the predicted temperature. The number of hidden layers is usually determined according to the complexity of the problem and the scale of the data. For simple temperature prediction problems, 1-3 hidden layers may be sufficient. More neurons and layers in the hidden layer can make the model have stronger fitting ability, but may also lead to overfitting. Too few neurons and layers may make the model unable to learn the complex relationships in the data well. In the case of multiple hidden layers, the strategy of decreasing the number of neurons is sometimes adopted.
[0077] Step S4, performing a second data analysis verification based on the first prediction data and the first temperature data; Step S4 includes the following sub-steps:
[0078] Step S401, setting the data suspected abnormal threshold to R0, the value range of R0 is [A0, A1]; in this embodiment, R0=(A0+A1) / 2;
[0079] Step S402, when the distributed temperature sensor collects temperature information at the first time interval, each time a temperature information is collected, based on the recorded time information when the temperature information is collected, the predicted temperature information with the same time information in the first prediction data is used to calculate the error value with the collected temperature information to obtain the actual error R1. When the actual error R1>R0, the collected temperature information is marked as suspected abnormal data; because the average absolute error value of the third prediction model is A0 and the maximum absolute error value is A1, the error value between the first prediction data and the actual temperature information is also [A0, A1] , and the value range of 0 is set to [A0, A1]. Therefore, when the actual error R1>R0, that is, the collected temperature information has a large change, it is very likely that the collected temperature information is abnormal data, so it is marked as suspected abnormal data for further verification. The cause of this data abnormality may be the large deviation caused by the long-term use of the temperature sensor without calibration; the setting of R0 is related to the sensitivity of abnormal data detection. The smaller R0 is, the more sensitive it is to abnormal data, but the possibility of misjudgment will also increase. The larger R0 is, the less sensitive it is to abnormal data, and the corresponding possibility of misjudgment will decrease.
[0080] Step S403, based on the temperature sensor Pi of the suspected abnormal data of the time information and the collected time information, obtain the temperature information collected by the Pi direct temperature sensor under the same collected time information, marked as the direct temperature information; and obtain the temperature information collected by the Pi secondary temperature sensor and mark it as the secondary temperature information; that is, obtain the temperature information collected by the surrounding temperature sensors;
[0081] Step S404, obtaining whether the direct temperature information and the secondary temperature information are suspected abnormal data, if K% of the direct temperature information and the secondary temperature information are suspected abnormal data, the mark of the suspected abnormal data is cancelled, in this embodiment, K%=20%, that is, the temperature information collected by 20% of the surrounding temperature sensors is compared; because the third prediction model can predict the temperature change under normal conditions, but cannot predict the temperature change under sudden conditions, for example, the occurrence of a fire, it is necessary to compare and verify with the temperature information collected by the surrounding temperature sensors at the same time, if the temperature information collected by some of the surrounding temperature sensors at the same time is suspected abnormal data, that is, a large change has also occurred, it means that the collected temperature information is not abnormal, but the ambient temperature has indeed changed significantly;
[0082] In the specific implementation process, if a sudden change in temperature is detected, that is, K% of the direct temperature information and the secondary temperature information are suspected abnormal data, an alarm should be issued immediately, because rapid changes in temperature often mean that a fire has occurred; and if it is verified that the data collected by a single temperature sensor is abnormal and the abnormality persists, it is often because the temperature sensor has been used for a long time without calibration, resulting in a large deviation or damage to the temperature sensor, and the temperature sensor needs to be repaired.
[0083] Example 2, please refer to Figure 4 As shown, Figure 4 The structural diagram of an electronic device is illustrated, and the electronic device may include: a processor, a communication interface, a memory and a communication bus, wherein the processor, the communication interface and the memory communicate with each other through the communication bus. The memory stores computer-readable instructions, and the processor can call the instructions in the memory. When the computer-readable instructions are executed by the processor, the steps in a distributed multi-dimensional information data verification method for an Internet of Things terminal are executed to achieve the following functions: construct a temperature sensor coding standard, and perform mapping coding processing on the distributed temperature sensor; collect the first temperature data and the first related data based on the distributed temperature sensor, and perform the first data analysis and verification to obtain the second temperature data; collect the second related data, and predict the temperature based on the second temperature data and the second related data to obtain the first predicted data.
[0084] In addition, the logic instructions in the above-mentioned memory can be implemented in the form of software functional units and can be stored in a computer-readable storage medium when sold or used as an independent product. Based on this understanding, the technical solution of the present application can be essentially or partly embodied in the form of a software product that contributes to the prior art. The computer software product is stored in a storage medium, including several instructions to enable a computer device (which can be a personal computer, server, or network device, etc.) to execute all or part of the steps of the method described in each embodiment of the present application. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), disk or optical disk, etc. Various media that can store program codes.
[0085] Embodiment 3, the present application also provides a computer-readable storage medium, the present application provides a storage medium, on which a computer program is stored. When the computer program is executed by a processor, the steps in the above distributed multi-dimensional information data verification method for an Internet of Things terminal are executed to achieve the following functions: construct a temperature sensor coding standard, and perform mapping coding processing on the distributed temperature sensor; collect first temperature data and first related data based on the distributed temperature sensor, and perform a first data analysis and verification to obtain second temperature data; collect second related data, and predict the temperature based on the second temperature data and the second related data to obtain first predicted data.
[0086] Through the description of the above implementation methods, the embodiments of the present invention can be provided as methods, systems or computer program products. Based on such an understanding, the above technical solutions can be essentially or partly contributed to the prior art in the form of software products, which can be stored in a computer-readable storage medium, such as ROM / RAM, a magnetic disk, an optical disk, etc., and include several instructions for enabling a computer device (which can be a personal computer, a server, or a network device, etc.) to execute the methods described in each embodiment or some parts of the embodiments.
[0087] In the embodiments provided in the present application, it should be understood that the disclosed system or method can be implemented in other ways. The embodiments described above are merely schematic. For example, the division of modules or units is only a logical function division. There may be other division methods in actual implementation. For example, multiple modules or units can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some communication interfaces, and the indirect coupling or communication connection of systems, modules and units can be electrical, mechanical or other forms.
[0088] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present application, rather than to limit it. Although the present application has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or make equivalent replacements for some of the technical features therein. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present application.
Claims
1. A distributed multi-dimensional information data verification method for an Internet of Things terminal, characterized in that: The steps include: Construct temperature sensor coding standards and perform mapping and coding processing on distributed temperature sensors; Collecting first temperature data and first related data based on the distributed temperature sensor, and performing a first data analysis and verification to obtain second temperature data; collecting second related data, and predicting the temperature based on the second temperature data and the second related data to obtain first predicted data; Perform a second data analysis verification based on the first prediction data and the first temperature data; Collecting the first temperature data and the first related data based on the distributed temperature sensor and performing a first data analysis and verification to obtain the second temperature data includes the following sub-steps: The temperature measurement range, rated voltage range, and rated current range of all distributed temperature sensors are obtained, and stored according to the codes of the distributed temperature sensors, and marked as basic parameters of the temperature sensors; Based on the distributed temperature sensor, temperature information is collected at a first time interval, and the time information when the temperature information is collected is recorded, and stored according to the coding of the distributed temperature sensor, marked as the first temperature data, and the first time interval is t1; After each temperature information, determine whether the collected temperature information is within the temperature measurement range of the corresponding distributed temperature sensor. If not, mark the collected temperature information as invalid data. If so, calculate the time difference between the time information when the temperature information is collected this time and the time information when the temperature information is collected last time, mark it as the collected temperature time difference, determine whether the collected temperature time difference is equal to the first time interval, if not, mark the collected temperature information as time abnormal data. Collecting the first temperature data and the first related data based on the distributed temperature sensor and performing a first data analysis and verification to obtain the second temperature data also includes the following sub-steps: Acquire the input voltage and input current of all distributed temperature sensors at a second time interval, record the time information when acquiring, store according to the coding of the distributed temperature sensor, mark as the first relevant data, and the second time interval is t2; After each acquisition of the input voltage and input current of the distributed temperature sensor, determine whether the input voltage of the distributed temperature sensor acquired this time is within the rated voltage range, and whether the input current is within the rated current range based on the basic parameters of the temperature sensor. If the input voltage is not within the rated voltage range or the input current is not within the rated current range, obtain the time information when the input voltage and input current of the distributed temperature sensor were acquired last time, mark it as an invalid time, and mark the collected temperature information acquired after the invalid time as invalid data; Based on the first temperature data, invalid data and time abnormal data in the first temperature data are eliminated, and second temperature data is obtained after completion; Collecting the second related data, predicting the temperature based on the second temperature data and the second related data, and obtaining the predicted temperature data includes the following sub-steps: collecting weather temperature at first time intervals and marking them as second relevant data; The missing temperature information in the second temperature data due to the removal of the abnormal time data is filled by using the weighted average of the latest x3 non-missing temperature information before the missing temperature information and the latest x3 non-missing temperature information after the missing temperature information, and the filled second temperature data is marked as the third temperature data; The third temperature data and the second related data are combined and stored according to the data collection time, and the first temperature training set and the first temperature test set are divided into a ratio of 7:3; The first temperature training set and the first temperature test set are normalized, and the air temperature data size and the temperature data size in the first temperature training set and the first temperature test set are normalized to [0, 1]. After completion, the second temperature training set and the second temperature test set are obtained.
2. A distributed multi-dimensional information data verification method for an Internet of Things terminal according to claim 1, characterized in that: Building a temperature sensor coding standard includes the following sub-steps: The device type, device name, device number and spatial location of all distributed temperature sensors in the space are obtained and marked as the basic information of the temperature sensor. A four-level temperature sensor coding standard is established based on the basic information of the temperature sensor. The temperature sensor coding standard includes: level 1 type code, level 2 name code, level 3 location code and level 4 number code.
3. A distributed multi-dimensional information data verification method for an Internet of Things terminal according to claim 2, characterized in that: The mapping and encoding process of the distributed temperature sensor includes the following sub-steps: Based on the temperature sensor coding standard, all distributed temperature sensors in the space are encoded to obtain temperature sensor coding data, ensuring that the coding of any two distributed temperature sensors is not repeated, and any distributed temperature sensor is recorded as Pi; Get the codes of the x0 distributed temperature sensors closest to the distributed temperature sensor Pi, and arrange them from near to far according to the straight-line distance from the distributed temperature sensor Pi. According to the codes, mark the first x1 distributed temperature sensors as Pi direct-level temperature sensors, and mark the last x2 distributed temperature sensors as Pi secondary temperature sensors, x0=x1+x2.
4. A distributed multi-dimensional information data verification method for an Internet of Things terminal according to claim 3, characterized in that: Collecting the second related data, predicting the temperature based on the second temperature data and the second related data, and obtaining the first predicted data also includes the following sub-steps: Select the multi-layer perceptron model, and improve the multi-layer perceptron model including: Set the number of neurons in the input layer of the multilayer perceptron model to Y0, set the number of hidden layers of the multilayer perceptron model to Z0, set the number of neurons in the first hidden layer to Y1, set the number of neurons in the second hidden layer to Y2, set the number of neurons in the output layer of the multilayer perceptron model to Y3, set the activation function from the input layer to the first hidden layer and the activation function from the first hidden layer to the second hidden layer to the ReLU function; after completion, the first initial model is obtained.
5. A distributed multi-dimensional information data verification method for an Internet of Things terminal according to claim 4, characterized in that: Collecting the second related data, predicting the temperature based on the second temperature data and the second related data, and obtaining the predicted temperature data also includes the following sub-steps: Setting model training hyperparameters includes: setting the learning rate to a1, the batch size to a2, and the training rounds to a3; defining the mean square error as the loss function for model training; defining the mean absolute error as the evaluation function for the model, and setting the model qualification threshold to B0; The first initial model is trained using the second temperature training set of the second block, and a second initial model is obtained after the training is completed; The second initial model is tested using the second temperature test set, the average absolute error and the maximum absolute error of the second initial model are calculated, the average absolute error value A0 and the maximum absolute error A1 of the second initial model are obtained, and it is determined whether A0 satisfies A0≤B0. If so, the second initial model is marked as the third prediction model; the average absolute error value A0 is recorded, marked as the model average difference; the maximum absolute error A1 is recorded, marked as the model maximum difference; If not, adjust the model training hyperparameters, the number of neurons in the first hidden layer Y1, and the number of neurons in the second hidden layer Y2. After the adjustment, use the second temperature training set to train the second initial model. After completion, use the second temperature test set to test again until the third prediction model, the model average difference, and the model maximum difference are obtained. Normalization processing is performed based on the third temperature data, and then the future temperature is predicted using the third prediction model to obtain first prediction data.
6. A distributed multi-dimensional information data verification method for an Internet of Things terminal according to claim 5, characterized in that: The second data analysis verification based on the first prediction data and the first temperature data includes the following sub-steps: Set the data suspected abnormal threshold to R0, and the value range of R0 is [A0, A1]; When the distributed temperature sensor collects temperature information at a first time interval, each time a temperature information is collected, based on the recorded time information when the temperature information is collected, the predicted temperature information with the same time information in the first prediction data is used to calculate the error value with the collected temperature information to obtain the actual error R1. When the actual error R1>R0, the collected temperature information is marked as suspected abnormal data.
7. A distributed multi-dimensional information data verification method for an Internet of Things terminal according to claim 6, characterized in that: The second data analysis verification based on the first prediction data and the first temperature data also includes the following sub-steps: Based on the temperature sensor Pi of the suspected abnormal data in time information and the collected time information, obtain the temperature information collected by the Pi direct temperature sensor under the same collected time information, and mark it as the direct temperature information; and obtain the temperature information collected by the Pi secondary temperature sensor and mark it as the secondary temperature information; obtain whether the direct temperature information and the secondary temperature information are suspected abnormal data, if more than K% of the direct temperature information and the secondary temperature information are suspected abnormal data, cancel the mark of the suspected abnormal data.
Citation Information
Patent Citations
Temperature monitoring method for underground cable, temperature measurement host and medium
CN118149997A
Power transmission line distribution management simulation method and system based on virtual operation
CN118709611A