An engineering safety prediction method and system based on the Internet of Things

Acquire and preprocess engineering safety data through the Internet of Things, build a random forest model and use an improved genetic algorithm to optimize hyperparameters, which solves the problem that traditional methods cannot monitor and predict accurately in real time, achieves efficient prediction and analysis of engineering safety, and improves improve the accuracy of emergency response to accidents.

CN118445708BActive Publication Date: 2024-09-20JIANGXI RUNLIN ENG QUALITY INSPECTION CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202410905208.1
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-07-08
Publication Date
2024-09-20
Estimated Expiration
2044-07-08

AI Technical Summary

Technical Problem

Traditional engineering safety management methods cannot monitor in real time and respond promptly, and it is difficult to effectively use IoT sensor data for safety prediction, which affects the accuracy of preventive maintenance and accident emergency response.

Method used

An engineering safety prediction method based on the Internet of Things is used to construct a random forest model by obtaining and preprocessing original data, and uses an improved genetic algorithm to simulate and optimize hyperparameters to improve the accuracy of the prediction model.

Benefits of technology

It achieves real-time prediction and accurate analysis of engineering safety data, improves the effectiveness of preventive maintenance and accident emergency response, and adapts to the processing needs of huge data items.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118445708B
    Figure CN118445708B
Patent Text Reader

Abstract

The present invention relates to the field of construction engineering, and in particular to an engineering safety prediction method and system based on the Internet of Things. An engineering safety prediction system based on the Internet of Things comprises: an engineering safety raw data acquisition module, an engineering safety raw data preprocessing module and an engineering safety prediction module. The present invention can realize a comprehensive analysis of the huge data items in the engineering safety prediction data through an engineering safety prediction model, realize the prediction of engineering safety, and during the training process of the engineering safety prediction model, the engineering safety prediction model is hyperparameter-adjusted through an improved genetic algorithm, which can improve the prediction accuracy of the engineering safety prediction model when facing engineering safety prediction data with huge data items.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of construction engineering, and in particular to an engineering safety prediction method and system based on the Internet of Things. Background Art

[0002] In the field of modern engineering, safety prediction is a key factor in ensuring the smooth progress of projects and reducing accident risks. Traditional engineering safety management methods usually rely on manual experience and periodic inspections, which have the limitation of being unable to monitor in real time and respond in time. With the rapid development of Internet of Things technology, various sensor devices can collect a large amount of key data in real time, providing a new solution for engineering safety management.

[0003] However, there are still several technical challenges to effectively use this data to achieve engineering safety prediction. First, traditional data processing methods are inefficient when processing large-scale real-time data, and it is difficult to provide real-time feedback on the engineering safety status. Second, how to extract and identify key features for safety prediction from complex sensor data is also a problem that needs to be solved. In addition, the accuracy of the safety prediction model directly affects the effectiveness of preventive maintenance and accident emergency response. Summary of the invention

[0004] The present invention uses an engineering safety prediction model to comprehensively analyze the huge amount of data items in the engineering safety prediction data and realize the prediction of engineering safety. In addition, during the training process of the engineering safety prediction model, the hyperparameters of the engineering safety prediction model are adjusted through an improved genetic algorithm, which can improve the prediction accuracy of the engineering safety prediction model when facing engineering safety prediction data with huge data items.

[0005] An engineering safety prediction method based on the Internet of Things, comprising:

[0006] Obtain original engineering safety data through the Internet of Things at monitoring points;

[0007] Preprocess the original engineering safety data to obtain engineering safety prediction data;

[0008] The engineering safety prediction data is sent to the engineering safety prediction model for processing, and the engineering safety prediction accident labels are output to realize the prediction of engineering safety. The engineering safety prediction model is constructed based on the random forest model, and the hyperparameters in the engineering safety prediction model are simulated and optimized through the improved genetic algorithm.

[0009] As a preferred aspect of the present invention, training is performed on the engineering safety prediction model, specifically comprising the following steps:

[0010] Acquire several copies of historical engineering safety original data, perform preprocessing operations on the historical engineering safety original data, obtain engineering safety prediction data training samples, and annotate the engineering safety prediction data training samples with engineering safety prediction accident labels, and form an engineering safety prediction data training set and an engineering safety prediction data training set test set with all annotated engineering safety prediction data training samples, send the engineering safety prediction data training set to the engineering safety prediction model with parameter initialization for training, and output the first accuracy of the engineering safety prediction model, and judge whether the first accuracy of the engineering safety prediction model is greater than a first preset threshold. If the first accuracy of the engineering safety prediction model is greater than the first preset threshold, output the trained engineering safety prediction model; simulate and optimize the hyperparameters in the engineering safety prediction model through the engineering safety prediction data training set test set and the improved genetic algorithm.

[0011] As a preferred aspect of the present invention, the hyperparameters in the engineering safety prediction model are simulated and optimized by using the engineering safety prediction data training set test set and the improved genetic algorithm, which specifically includes the following steps:

[0012] S1: Construct several simulation hyperparameter sets, and divide all simulation hyperparameter sets into M simulation population sets, and the storage form of simulation hyperparameter sets is {F1, F2, F3, ..., F i , …, F I}, where i=1, 2, 3, ..., I, and F i is the hyperparameter in the engineering safety prediction model, I is the total number of hyperparameters in the engineering safety prediction model, and the maximum number of iterations W is set;

[0013] S2: Let w=1, w is used to record the number of iterations;

[0014] S3: Calculate the fitness of each simulation hyperparameter set based on the engineering safety prediction data training set and test set, and select the simulation hyperparameter set with the largest fitness among all simulation hyperparameter sets and store it in the optimal simulation hyperparameter set library;

[0015] S4: For each simulation population set, select the simulation hyperparameter set with the largest fitness from the simulation population set as the optimal simulation hyperparameter seed, then perform a local search strategy based on the M optimal simulation hyperparameter seeds, and then add the M optimal simulation hyperparameter seeds that have undergone the local search strategy to the corresponding simulation population set;

[0016] S5: For each simulated population set, perform the following operations: based on the fitness of the simulated hyperparameter set, select the simulated hyperparameter set through the roulette algorithm until 0.5M simulated hyperparameter sets are selected, and then the selected 0.5M simulated hyperparameter sets are formed into a parent set; a reorganization operation is performed on the simulated hyperparameter sets in the parent set, and the reorganization operation is specifically to randomly select two simulated hyperparameter sets from the parent set, and the selected simulated hyperparameter sets are no longer selected, and a random integer μ between (1, I) is generated by a random function, and the hyperparameters at positions μ in the two selected simulated hyperparameter sets are swapped to generate 0.5M new simulated hyperparameter sets, and then the parent set and the 0.5M new simulated hyperparameter sets are formed into an intermediate population set, and a mutation operation is performed on the intermediate population set, and the mutation operation is specifically to select simulated hyperparameter sets one by one from the intermediate population set, and a random number η between (0, 1) is generated by a random function, and it is judged that "η>P c "Is it true? c is the mutation threshold, if "η>P c " is established, a random integer α between (1, I) is generated by a random function, and the hyperparameter at position α in the selected simulation hyperparameter set is mutated. If "η>P c "Not true, no operation; record the intermediate population set after the mutation operation as the new simulated population set; M simulated populations are merged and operated;

[0017] S6: Determine whether "w<W" is true. If "w<W" is true, return to S3; if "w<W" is not true, enter S7;

[0018] S7: Select the simulation hyperparameter set with the largest fitness in the optimal simulation hyperparameter set library as the optimal simulation hyperparameter set for output, and use the hyperparameters in the optimal simulation hyperparameter set as the hyperparameters in the engineering safety prediction model, and use the hyperparameters in the optimal simulation hyperparameter set as the hyperparameters of the engineering safety prediction model.

[0019] As a preferred aspect of the present invention, the construction of the simulation hyperparameter set specifically includes the following steps:

[0020] Set a temporary storage set with a length of I, traverse i from 1 to I, and for each traversed element i, randomly generate a random number δ from the hyperparameter range corresponding to the i-th hyperparameter and store it in the i-th position in the temporary storage set until i is traversed. The temporary storage set is recorded as the simulated hyperparameter set.

[0021] As a preferred aspect of the present invention, the fitness of each simulation hyperparameter set is calculated based on the engineering safety prediction data training set and test set, specifically comprising the following steps:

[0022] Obtain the trained engineering safety prediction model, use the simulation hyperparameter set as the hyperparameter of the trained engineering safety prediction model, then send the engineering safety prediction data training set and test set into the engineering safety prediction model for processing, and output the second accuracy of the engineering safety prediction model, and use the second accuracy of the engineering safety prediction model as the fitness of the simulation hyperparameter set.

[0023] As a preferred aspect of the present invention, a local search strategy is executed based on M optimal simulation hyperparameter seeds, specifically including the following steps:

[0024] The one with the largest fitness among the M optimal simulation hyperparameter seeds is recorded as the optimal simulation hyperparameter seed F best ;

[0025] For all but the optimal simulation hyperparameter seed F best Each optimal simulation hyperparameter seed of is transformed by the following formula: i (new) = F i (ran)+β(|F i -F i (best)|), where F i (new) is the i-th hyperparameter in the transformed optimal simulation hyperparameter seed, F i (ran) is the optimal simulation hyperparameter seed F best The i-th hyperparameter in a random optimal simulation hyperparameter seed, β is a random number between (0, 1), F i (best) is the optimal simulation hyperparameter seed F best The i-th hyperparameter in is used to determine whether the fitness of the transformed optimal simulation hyperparameter seed is higher than that of the original optimal simulation hyperparameter seed. If so, the transformed optimal simulation hyperparameter seed replaces the original optimal simulation hyperparameter seed. Otherwise, no operation is performed to realize the local search strategy.

[0026] As a preferred aspect of the present invention, the engineering safety raw data includes data uploaded by all sensors and cameras connected to the Internet of Things.

[0027] The present invention also provides an engineering safety prediction system based on the Internet of Things, comprising:

[0028] The engineering safety raw data acquisition module is used to obtain the engineering safety raw data through the Internet of Things at the monitoring point;

[0029] The engineering safety raw data preprocessing module is used to preprocess the engineering safety raw data to obtain engineering safety prediction data;

[0030] The engineering safety prediction module is used to send the engineering safety prediction data to the engineering safety prediction model for processing, output the engineering safety prediction accident label, and realize the prediction of engineering safety. The engineering safety prediction model is constructed based on the random forest model, and the hyperparameters in the engineering safety prediction model are simulated and optimized through the improved genetic algorithm.

[0031] The present invention has the following advantages:

[0032] 1. The present invention can realize comprehensive analysis of huge data items in engineering safety prediction data through the engineering safety prediction model, realize the prediction of engineering safety, and during the training process of the engineering safety prediction model, the hyperparameters of the engineering safety prediction model are adjusted through the improved genetic algorithm, which can improve the prediction accuracy of the engineering safety prediction model when facing engineering safety prediction data with huge data items.

[0033] 2. The present invention can improve the diversity of changes in simulation hyperparameter sets by setting multiple simulation population sets, and by executing a local search strategy for the optimal simulation hyperparameter seed corresponding to each simulation population set, it can integrate excellent genes in different simulation population sets, thereby improving the convergence speed and being able to adapt to large data items. BRIEF DESCRIPTION OF THE DRAWINGS

[0034] Figure 1 This is a schematic diagram of the structure of an engineering safety prediction system based on the Internet of Things adopted in an embodiment of the present invention. DETAILED DESCRIPTION

[0035] In order to enable persons skilled in the art to better understand the technical solutions in the present invention, the technical solutions in the embodiments of the present invention will be clearly and completely described below in conjunction with the accompanying drawings in the embodiments of the present invention.

[0036] Embodiment 1, a method for predicting engineering safety based on the Internet of Things, comprising:

[0037] The original data of engineering safety is obtained through the Internet of Things at the monitoring point. It should be noted that the original data of engineering safety obtained through the Internet of Things includes data uploaded by all sensors and cameras connected to the Internet of Things, including environmental data, equipment data and building structure data. Environmental data includes temperature, humidity, wind speed and rainfall, etc. Equipment data includes usage status data and equipment parameters of various equipment, etc. Building structure data includes pictures taken by cameras at key points of each building structure, and the key points of the building structure are set in advance by professionals according to design drawings;

[0038] Preprocess the original data of engineering safety to obtain the engineering safety prediction data. It should be added that the preprocessing of the original data of engineering safety includes the following contents: for the numerical data uploaded by the sensor, it is necessary to filter outliers, supplement missing values ​​and other operations; for the image data uploaded by the camera, the state label of the building structure will be output according to the corresponding image recognition model, such as loose scaffolding and accumulation of flammable materials, and each type of key point corresponds to a type of state label, and then the state label is encoded through tools such as the bag of words model to construct numerical data, and then all numerical data are spliced ​​according to data items to obtain engineering safety prediction data;

[0039] The engineering safety prediction data is sent to the engineering safety prediction model for processing, and the engineering safety prediction accident labels are output to achieve the prediction of engineering safety. The engineering safety accident labels include electric shock accidents, fire accidents and collapse accidents, etc., which are confirmed by the developers during training; and the engineering safety prediction model is constructed based on the random forest model, and the hyperparameters in the engineering safety prediction model are simulated and optimized through the improved genetic algorithm;

[0040] The present application can realize comprehensive analysis of huge data items in engineering safety prediction data and realize prediction of engineering safety through the engineering safety prediction model. In addition, during the training process of the engineering safety prediction model, the hyperparameters of the engineering safety prediction model are adjusted through the improved genetic algorithm, which can improve the prediction accuracy of the engineering safety prediction model when facing engineering safety prediction data with huge data items.

[0041] Training the engineering safety prediction model includes the following steps:

[0042] Obtain several copies of historical engineering safety original data, and perform preprocessing operations on the historical engineering safety original data. It should be noted that the preprocessing operation here is consistent with the preprocessing of the engineering safety original data, obtain engineering safety prediction data training samples, and annotate the engineering safety prediction data training samples with engineering safety prediction accident labels. It should be noted that the engineering safety prediction labels are engineering safety prediction data training samples corresponding to engineering safety accidents that will occur in the future, which can be obtained through the records of historical safety accident data. All annotated engineering safety prediction data training samples are composed of an engineering safety prediction data training set and an engineering safety prediction data training set test set. The ratio of the test data training set and the engineering safety prediction data training set to the test set is generally 8:2. The engineering safety prediction data training set is sent to the engineering safety prediction model with parameter initialization for training, and the first accuracy of the engineering safety prediction model is output to determine whether the first accuracy of the engineering safety prediction model is greater than the first preset threshold. The first preset threshold is set by the developer and is used to characterize the confidence of the engineering safety prediction model prediction. If the first accuracy of the engineering safety prediction model is greater than the first preset threshold, the trained engineering safety prediction model is output; the hyperparameters in the engineering safety prediction model are simulated and optimized through the engineering safety prediction data training set test set and the improved genetic algorithm.

[0043] The hyperparameters in the engineering safety prediction model are simulated and optimized through the engineering safety prediction data training set test set and the improved genetic algorithm, which specifically includes the following steps:

[0044] S1: Construct several simulation hyperparameter sets, and divide all simulation hyperparameter sets into M simulation population sets, and the storage form of simulation hyperparameter sets is {F1, F2, F3, ..., F i , …, F I}, where i=1, 2, 3, ..., I, and F i is a hyperparameter in the engineering safety prediction model, which can be the number of trees, the maximum depth of the tree, the minimum number of sample splits, the minimum number of leaf node samples, the maximum number of features, etc. I is the total number of hyperparameters in the engineering safety prediction model, and the maximum number of iterations W is set;

[0045] S2: Let w=1, w is used to record the number of iterations;

[0046] S3: Calculate the fitness of each simulation hyperparameter set based on the engineering safety prediction data training set and test set, and select the simulation hyperparameter set with the largest fitness among all simulation hyperparameter sets and store it in the optimal simulation hyperparameter set library;

[0047] S4: For each simulation population set, select the simulation hyperparameter set with the largest fitness from the simulation population set as the optimal simulation hyperparameter seed, then perform a local search strategy based on the M optimal simulation hyperparameter seeds, and then add the M optimal simulation hyperparameter seeds that have undergone the local search strategy to the corresponding simulation population set;

[0048] S5: For each simulated population set, perform the following operations: based on the fitness of the simulated hyperparameter set, select the simulated hyperparameter set through the roulette algorithm, specifically, the fitness of the simulated hyperparameter set is formed into a building from small to large, and the position on the roulette wheel is determined according to the generated random number of 0-1, and then the simulated hyperparameter set is selected according to the position on the roulette wheel until 0.5M simulated hyperparameter sets are selected, and then the selected 0.5M simulated hyperparameter sets are formed into a parent set; the simulated hyperparameter sets in the parent set are reorganized, and the reorganization operation is specifically from the parent set Two simulated hyperparameter sets are randomly selected from the set, and the selected simulated hyperparameter sets are no longer selected. A random integer μ between (1, I) is generated by a random function, and the hyperparameters at position μ of the two selected simulated hyperparameter sets are swapped to generate 0.5M new simulated hyperparameter sets. The parent set and the 0.5M new simulated hyperparameter sets are then combined into an intermediate population set, and a mutation operation is performed on the intermediate population set. The mutation operation is specifically to select simulated hyperparameter sets one by one from the intermediate population set, and to generate a random number η between (0, 1) by a random function, and to judge whether "η>P c "Is it true? c is the mutation threshold, generally 0.7. If “η>P c " is established, a random integer α between (1, I) is generated by a random function, and the hyperparameter at position α in the selected simulation hyperparameter set is mutated, that is, the hyperparameter at position α in the selected simulation hyperparameter set is randomly replaced with a value in another range. If "η>P c "Not true, no operation; record the intermediate population set after the mutation operation as the new simulated population set; M simulated populations are merged and operated;

[0049] S6: Determine whether "w<W" holds. If "w<W" holds, it means that the maximum number of iterations has not been reached, and return to S3; if "w<W" does not hold, it means that the maximum number of iterations has been reached, and enter S7;

[0050] S7: Select the simulation hyperparameter set with the largest fitness in the optimal simulation hyperparameter set library as the optimal simulation hyperparameter set for output, and use the hyperparameters in the optimal simulation hyperparameter set as the hyperparameters in the engineering safety prediction model, and use the hyperparameters in the optimal simulation hyperparameter set as the hyperparameters of the engineering safety prediction model.

[0051] By setting up multiple simulation population sets, the present application can improve the diversity of changes in simulation hyperparameter sets, and by executing a local search strategy for the optimal simulation hyperparameter seed corresponding to each simulation population set, it can integrate excellent genes from different simulation population sets, thereby improving the convergence speed and being able to adapt to large data items.

[0052] The construction of the simulation hyperparameter set includes the following steps:

[0053] Set a temporary collection of length I, traverse i from 1 to I, and for each traversed element i, randomly generate a random number δ from the hyperparameter range corresponding to the i-th hyperparameter and store it in the i-th position in the temporary collection. It should be noted that the hyperparameter range is set by the developer based on experience. Until i is traversed, the temporary collection is recorded as a simulated hyperparameter set;

[0054] The fitness of each simulation hyperparameter set is calculated based on the engineering safety prediction data training set and test set, which specifically includes the following steps:

[0055] Obtain the trained engineering safety prediction model, use the simulation hyperparameter set as the hyperparameter of the trained engineering safety prediction model, then send the engineering safety prediction data training set and test set into the engineering safety prediction model for processing, and output the second accuracy of the engineering safety prediction model, and use the second accuracy of the engineering safety prediction model as the fitness of the simulation hyperparameter set.

[0056] Then, a local search strategy is executed based on the M optimal simulation hyperparameter seeds, which specifically includes the following steps:

[0057] The one with the largest fitness among the M optimal simulation hyperparameter seeds is recorded as the optimal simulation hyperparameter seed F best ;

[0058] For all but the optimal simulation hyperparameter seed F best Each optimal simulation hyperparameter seed of is transformed by the following formula: i (new) = F i (ran)+β(|F i -F i (best)|), where F i (new) is the i-th hyperparameter in the transformed optimal simulation hyperparameter seed, F i (ran) is the optimal simulation hyperparameter seed F best The i-th hyperparameter in a random optimal simulation hyperparameter seed, β is a random number between (0, 1), F i (best) is the optimal simulation hyperparameter seed F bestThe i-th hyperparameter in , determines whether the fitness of the transformed optimal simulation hyperparameter seed is higher than that of the original optimal simulation hyperparameter seed, if so, replaces the original optimal simulation hyperparameter seed with the transformed optimal simulation hyperparameter seed, otherwise, no operation is performed to realize the local search strategy;

[0059] This application achieves local search by targeting the optimal simulation hyperparameter seed and integrating the excellent features of other simulation population sets.

[0060] Example 2, an engineering safety prediction system based on the Internet of Things, such as Figure 1 As shown, including:

[0061] The engineering safety original data acquisition module is used to obtain the engineering safety original data through the Internet of Things at the monitoring point. It should be noted that the engineering safety original data obtained through the Internet of Things includes data uploaded by all sensors and cameras connected to the Internet of Things, including environmental data, equipment data and building structure data. Environmental data includes temperature, humidity, wind speed and rainfall, etc. Equipment data includes usage status data and equipment parameters of various equipment, etc. Building structure data includes pictures taken by cameras at key points of each building structure, and the key points of the building structure are set in advance by professionals according to design drawings;

[0062] The engineering safety raw data preprocessing module is used to preprocess the engineering safety raw data to obtain engineering safety prediction data. It should be added that the preprocessing of the engineering safety raw data specifically includes the following contents: for the numerical data uploaded by the sensor, it is necessary to perform outlier filtering, missing value supplementation and other operations. For the image data uploaded by the camera, the state label of the building structure will be output according to the corresponding image recognition model, such as loose scaffolding and accumulation of flammable materials, and each type of key point corresponds to a type of state label, and then the state label is encoded through tools such as the bag of words model to construct numerical data, and then all numerical data are spliced ​​according to data items to obtain engineering safety prediction data;

[0063] The engineering safety prediction module is used to send the engineering safety prediction data to the engineering safety prediction model for processing, output the engineering safety prediction accident labels, and realize the prediction of engineering safety. The engineering safety accident labels include electric shock accidents, fire accidents, and collapse accidents, etc., which are confirmed by the developers during training; and the engineering safety prediction model is constructed based on the random forest model, and the hyperparameters in the engineering safety prediction model are simulated and optimized through the improved genetic algorithm.

[0064] It should be understood that those skilled in the art can make improvements or changes based on the above description, and all such improvements and changes should fall within the scope of protection of the appended claims of the present invention. Parts not described in detail in this specification belong to the prior art known to those skilled in the art.

Claims

1. An engineering safety prediction method based on the Internet of Things, characterized in that: include: Obtain original engineering safety data through the Internet of Things at monitoring points; Preprocess the original engineering safety data to obtain engineering safety prediction data; The engineering safety prediction data is sent to the engineering safety prediction model for processing, and the engineering safety prediction accident label is output to realize the prediction of engineering safety. The engineering safety prediction model is constructed based on the random forest model, and the hyperparameters in the engineering safety prediction model are simulated and optimized through the improved genetic algorithm; Training the engineering safety prediction model includes the following steps: Acquire several copies of historical engineering safety original data, perform preprocessing operations on the historical engineering safety original data, obtain engineering safety prediction data training samples, and annotate the engineering safety prediction data training samples with engineering safety prediction accident labels, form all annotated engineering safety prediction data training samples into an engineering safety prediction data training set and an engineering safety prediction data training set test set, send the engineering safety prediction data training set to the parameter-initialized engineering safety prediction model for training, and output the first accuracy of the engineering safety prediction model, determine whether the first accuracy of the engineering safety prediction model is greater than a first preset threshold, and if the first accuracy of the engineering safety prediction model is greater than the first preset threshold, output the trained engineering safety prediction model; simulate and optimize the hyperparameters in the engineering safety prediction model through the engineering safety prediction data training set test set and the improved genetic algorithm; The hyperparameters in the engineering safety prediction model are simulated and optimized through the engineering safety prediction data training set test set and the improved genetic algorithm, which specifically includes the following steps: S1: Construct several simulation hyperparameter sets, and divide all simulation hyperparameter sets into M simulation population sets, and the storage form of simulation hyperparameter sets is {F1, F2, F3, ..., F i , …, F I }, where i=1, 2, 3, ..., I, and F i is the hyperparameter in the engineering safety prediction model, I is the total number of hyperparameters in the engineering safety prediction model, and the maximum number of iterations W is set; S2: Let w=1, w is used to record the number of iterations; S3: Calculate the fitness of each simulation hyperparameter set based on the engineering safety prediction data training set and test set, and select the simulation hyperparameter set with the largest fitness among all simulation hyperparameter sets and store it in the optimal simulation hyperparameter set library; S4: For each simulation population set, select the simulation hyperparameter set with the largest fitness from the simulation population set as the optimal simulation hyperparameter seed, then perform a local search strategy based on the M optimal simulation hyperparameter seeds, and then add the M optimal simulation hyperparameter seeds that have undergone the local search strategy to the corresponding simulation population set; S5: For each simulated population set, perform the following operations: based on the fitness of the simulated hyperparameter set, select the simulated hyperparameter set through the roulette algorithm until 0.5M simulated hyperparameter sets are selected, and then the selected 0.5M simulated hyperparameter sets are formed into a parent set; a reorganization operation is performed on the simulated hyperparameter sets in the parent set, and the reorganization operation is specifically to randomly select two simulated hyperparameter sets from the parent set, and the selected simulated hyperparameter sets are no longer selected, and a random integer μ between (1, I) is generated by a random function, and the hyperparameters at positions μ in the two selected simulated hyperparameter sets are swapped to generate 0.5M new simulated hyperparameter sets, and then the parent set and the 0.5M new simulated hyperparameter sets are formed into an intermediate population set, and a mutation operation is performed on the intermediate population set, and the mutation operation is specifically to select simulated hyperparameter sets one by one from the intermediate population set, and a random number η between (0, 1) is generated by a random function, and it is judged that "η>P c "Is it true? c is the mutation threshold, if "η>P c " is established, a random integer α between (1, I) is generated by a random function, and the hyperparameter at position α in the selected simulation hyperparameter set is mutated. If "η>P c "Not true, no operation; record the intermediate population set after the mutation operation as the new simulated population set; M simulated populations are merged and operated; S6: Determine whether "w<W" holds. If so, return to S3; if not, enter S7; S7: Select the simulation hyperparameter set with the largest fitness in the optimal simulation hyperparameter set library as the optimal simulation hyperparameter set for output, and use the hyperparameters in the optimal simulation hyperparameter set as the hyperparameters in the engineering safety prediction model, and use the hyperparameters in the optimal simulation hyperparameter set as the hyperparameters of the engineering safety prediction model.

2. According to the engineering safety prediction method based on the Internet of Things according to claim 1, it is characterized in that: The construction of the simulation hyperparameter set includes the following steps: Set a temporary storage set with a length of I, traverse i from 1 to I, and for each traversed element i, randomly generate a random number δ from the hyperparameter range corresponding to the i-th hyperparameter and store it in the i-th position in the temporary storage set until i is traversed. The temporary storage set is recorded as the simulated hyperparameter set.

3. According to the method for predicting engineering safety based on the Internet of Things in claim 2, it is characterized in that: The fitness of each simulation hyperparameter set is calculated based on the engineering safety prediction data training set and test set, which specifically includes the following steps: Obtain the trained engineering safety prediction model, use the simulation hyperparameter set as the hyperparameter of the trained engineering safety prediction model, then send the engineering safety prediction data training set and test set into the engineering safety prediction model for processing, and output the second accuracy of the engineering safety prediction model, and use the second accuracy of the engineering safety prediction model as the fitness of the simulation hyperparameter set.

4. According to the engineering safety prediction method based on the Internet of Things according to claim 3, it is characterized in that: Then, a local search strategy is executed based on the M optimal simulation hyperparameter seeds, which specifically includes the following steps: The one with the largest fitness among the M optimal simulation hyperparameter seeds is recorded as the optimal simulation hyperparameter seed F best ; For all but the optimal simulation hyperparameter seed F best Each optimal simulation hyperparameter seed of is transformed by the following formula: i (new) = F i (ran)+β(|F i -F i (best)|), where F i (new) is the i-th hyperparameter in the transformed optimal simulation hyperparameter seed, F i (ran) is the optimal simulation hyperparameter seed F best The i-th hyperparameter in a random optimal simulation hyperparameter seed, β is a random number between (0, 1), F i (best) is the optimal simulation hyperparameter seed F best The i-th hyperparameter in is used to determine whether the fitness of the transformed optimal simulation hyperparameter seed is higher than that of the original optimal simulation hyperparameter seed. If so, the transformed optimal simulation hyperparameter seed replaces the original optimal simulation hyperparameter seed. Otherwise, no operation is performed to realize the local search strategy.

5. According to the method for predicting engineering safety based on the Internet of Things according to claim 4, it is characterized in that: Engineering safety raw data includes data uploaded by all sensors and cameras connected to the Internet of Things.

6. An engineering safety prediction system based on the Internet of Things, characterized in that: The system applies an engineering safety prediction method based on the Internet of Things as described in any one of claims 1 to 5, including: The engineering safety raw data acquisition module is used to obtain the engineering safety raw data through the Internet of Things at the monitoring point; The engineering safety raw data preprocessing module is used to preprocess the engineering safety raw data to obtain engineering safety prediction data; The engineering safety prediction module is used to send the engineering safety prediction data to the engineering safety prediction model for processing, output the engineering safety prediction accident label, and realize the prediction of engineering safety. The engineering safety prediction model is constructed based on the random forest model, and the hyperparameters in the engineering safety prediction model are simulated and optimized through the improved genetic algorithm.