Beam yard construction safety quality monitoring method and system based on AI recognition
By debugging the construction safety monitoring network through enhanced interval metric learning, the problem of image semantic deviation and unclear construction behavior in bridge construction is solved, and the accuracy and efficiency of beam field construction safety monitoring are improved.
Patent Information
- Application Number
- CN202410969202.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-07-19
- Publication Date
- 2024-10-01
- Estimated Expiration
- 2044-07-19
AI Technical Summary
In the existing technology, in bridge construction safety monitoring, image semantic deviation, unclear construction behavior and complexity of sample enhancement lead to low recognition accuracy, making it difficult to effectively monitor construction safety in complex environments.
The AI-based beam field construction safety quality monitoring method is used to obtain the beam field monitoring video, extract the image semantic descriptor of the real-time monitoring image, use the enhanced interval metric learning to debug the construction safety monitoring network, enhance the classification interface, and reduce the dependence on sample enhancement. Improve recognition accuracy.
It improves the accuracy and efficiency of beam field construction safety monitoring, overcomes the problem of image semantic deviation and unclear construction behavior, simplifies the data processing process, and enhances the network's recognition ability.
Smart Images

Figure CN118506290B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of artificial intelligence, and more specifically, to a beam yard construction safety and quality monitoring method and system based on AI recognition. Background Art
[0002] With the rapid development of infrastructure construction in my country, bridge projects, as important transportation infrastructure, have attracted much attention for their construction quality and safety. During bridge construction, construction safety monitoring is a key link to ensure project quality and personnel safety. However, traditional construction safety monitoring methods often rely on manual inspections and empirical judgments, which have problems such as low efficiency, strong subjectivity, and difficulty in comprehensive coverage. Especially in complex construction environments, such as beam construction areas, accurate identification of construction behaviors becomes particularly difficult due to the influence of various factors such as lighting changes, occlusion, and noise interference. In recent years, with the rapid development of computer vision and machine learning technologies, intelligent systems based on image recognition and safety monitoring have gradually been applied to the field of bridge construction.
[0003] These systems significantly improve the efficiency and accuracy of construction safety monitoring by extracting semantic features of construction images and using deep learning algorithms for automatic classification and recognition. However, existing technologies still face many challenges in practical applications. Image semantic deviation: Construction scenes are complex and changeable, and real-time monitoring images often contain a lot of noise and interference information, which leads to deviations in image semantic descriptors and affects the accuracy of classification and recognition. Unclear construction behavior: In some cases, due to occlusion, changes in viewing angles, etc., the construction behavior in real-time monitoring images may not be clear enough, and it is difficult to directly determine whether it complies with safety regulations. Sample enhancement complexity: In order to improve recognition accuracy, traditional methods usually need to separately add feature information associated with the image for sample enhancement, which not only increases the complexity of data processing, but also may introduce additional noise and errors. Fuzzy classification interface: In the feature space, the classification interface of different construction behaviors may not be clear enough, which makes it easy for the classifier to misjudge when identifying edge samples. Therefore, improving the accuracy of construction behavior recognition is a technical problem that needs to be solved in the current field of construction safety monitoring. Summary of the invention
[0004] The purpose of the present invention is to provide a method and system for monitoring the safety and quality of beam field construction based on AI recognition. The embodiment of the present application is implemented as follows:
[0005] In the first aspect, the embodiment of the present application provides a beam yard construction safety quality monitoring method based on AI recognition, including: obtaining a beam yard monitoring video collected for the target beam yard monitoring area; obtaining a beam yard real-time monitoring image from the beam yard monitoring video; calling a construction safety monitoring network to perform construction safety detection on the beam yard real-time monitoring image, and obtaining a construction safety detection result of the beam yard real-time monitoring image. The construction safety monitoring network is debugged based on the following process:
[0006] The beam yard real-time monitoring image and behavior reference image of each debugging learning sample in P debugging learning samples are obtained, and based on the construction safety monitoring network, the image semantic descriptor of the beam yard real-time monitoring image and the image semantic descriptor of the behavior reference image of each debugging learning sample are extracted, P ≥ 1; according to the preset safety distance, and the image semantic descriptor of the beam yard real-time monitoring image and the image semantic descriptor of the behavior reference image of each debugging learning sample, the classification interface between the debugging learning samples of different construction behaviors in the P debugging learning samples is strengthened to obtain the network cost value of the construction safety monitoring network; according to the network cost value, the construction safety monitoring network is debugged.
[0007] In a second aspect, an embodiment of the present application provides a computer system, comprising: one or more processors; a memory; one or more computer programs; wherein the one or more computer programs are stored in the memory and configured to be executed by the one or more processors, and when the one or more computer programs are executed by the processors, the method described above is implemented.
[0008] The beneficial effects of the present application include at least: in the debugging process of the construction safety monitoring network, the present application adopts a method of reinforced interval metric learning in the image dimension, that is, obtaining the beam field real-time monitoring image and behavior reference image of each debugging learning sample in P debugging learning samples, and extracting the image semantic descriptor of the beam field real-time monitoring image and the image semantic descriptor of the behavior reference image of each debugging learning sample based on the construction safety monitoring network. Then, based on the preset safety distance, and the image semantic descriptor of the beam field real-time monitoring image and the image semantic descriptor of the behavior reference image of each debugging learning sample, the classification interface between the debugging learning samples of different construction behaviors in the P debugging learning samples is strengthened to obtain the network generation value of the construction safety monitoring network, and then the construction safety monitoring network is debugged based on the network generation value. In other words, the embodiment of the present application strengthens the classification interface between the debugging learning samples of different construction behaviors in P debugging learning samples based on the preset safety distance, the image semantic descriptors of the beam field real-time monitoring images of each debugging learning sample, and the image semantic descriptors of the behavior reference images, so that the construction safety monitoring network can absorb the feature knowledge of the descriptors containing stability of the image semantic deviation, so as to accurately correspond the beam field real-time monitoring images with the corresponding behavior reference images, overcome the information deviation of the image with unclear construction behavior, and at the same time, in the debugging process, there is no need to separately add feature information associated with the image to perform sample enhancement, making the debugging process of the construction safety monitoring network more concise. Based on this, the accuracy of construction safety detection of beam field real-time monitoring images using the construction safety monitoring network is higher. BRIEF DESCRIPTION OF THE DRAWINGS
[0009] Figure 1 It is a flow chart of a beam yard construction safety and quality monitoring method based on AI identification provided in an embodiment of the present application.
[0010] Figure 2 It is a schematic diagram of the debugging process of the construction safety monitoring network provided in the embodiment of the present application.
[0011] Figure 3 It is a schematic diagram of the composition of a computer system provided in an embodiment of the present application. DETAILED DESCRIPTION
[0012] The execution subject of the beam yard construction safety quality monitoring method based on AI recognition in the embodiment of the present application is a computer system, including but not limited to a server, a personal computer, a laptop, a tablet computer, a smart phone, etc. Figure 1 As shown, the method includes:
[0013] Step S100: Acquire the beam yard monitoring video collected for the target beam yard monitoring area.
[0014] In the beam yard construction environment, in order to comprehensively monitor construction activities and ensure construction quality and safety, multiple high-definition cameras are deployed in key locations, such as the work area, equipment operation area, material storage area, etc. These cameras not only have night vision functions and waterproof and dustproof designs to adapt to the complex and changing construction environment, but are also connected to the central monitoring room or cloud storage platform through the network to achieve remote monitoring and data transmission.
[0015] As the executor of this process, the computer system will configure the connection parameters with the beam yard monitoring network, including but not limited to the IP address, port number, authentication information, etc. of the camera. Subsequently, a continuously running video acquisition service will be started, which requests video stream data from each camera periodically or in real time. These video stream data are usually transmitted in a compressed format (such as H.264 or H.265) to reduce bandwidth occupancy and improve transmission efficiency. Specifically, in step S100, when the video acquisition service is started, it will initiate video stream requests for all cameras in the target beam yard monitoring area (i.e., the pre-set construction area that needs to be focused on). These requests are sent to the corresponding cameras through the network, and the cameras respond to the requests and start sending real-time video frame data to the computer system.
[0016] Taking a beam yard as an example, assuming that the target monitoring area is the steel bar binding area, where many workers are working and large equipment such as tower cranes frequently shuttle back and forth. The computer system obtains the monitoring video of this area in real time by connecting to multiple high-definition cameras in the area. In the video, key information such as the workers' helmet wearing, safety belt use, whether the operation complies with the specifications, and the running trajectory and load status of the tower crane are clearly recorded. These video data not only provide raw materials for subsequent real-time monitoring image extraction (step S200), but also provide valuable data resources for the training and debugging of the construction safety monitoring network (involving deep learning algorithms or neural network models, such as convolutional neural networks CNN). By learning from a large number of real construction scene videos, the construction safety monitoring network can continuously improve its recognition accuracy and generalization ability, so as to better serve the construction safety quality monitoring work of the beam yard.
[0017] Step S200: Acquire a real-time monitoring image of the beam yard from the beam yard monitoring video.
[0018] Step S300: calling the construction safety monitoring network to perform construction safety detection on the real-time monitoring image of the beam yard, and obtaining the construction safety detection result of the real-time monitoring image of the beam yard.
[0019] After acquiring the beam yard monitoring video, the computer system further processes the data to extract images that reflect the construction status in real time. This process usually involves decoding, extraction, and preprocessing of video frames. For example, multiple frames of images can be extracted from the video per second (such as 25 frames per second), and one or more clear and unobstructed frames can be selected as real-time monitoring images. These real-time monitoring images not only show the overall construction status of the current beam yard, but also capture specific construction details, such as whether workers are wearing safety helmets and whether mechanical equipment is operated in accordance with specifications. In order to improve the accuracy of subsequent construction safety inspections, the images may also be preprocessed, such as adjusting brightness, contrast, removing noise, etc., to enhance the key features of the image.
[0020] After acquiring the real-time monitoring images of the beam yard, the computer system calls a specially trained construction safety monitoring network to analyze and process these images. This monitoring network is a complex machine learning model, usually built based on deep learning algorithms, such as convolutional neural networks (CNN). The network has been trained with a large amount of labeled construction image data and can automatically identify construction safety hazards in images.
[0021] For example, in a real-time monitoring image, if a worker is not wearing a hard hat, the construction safety monitoring network can quickly capture this feature (such as by detecting the color, shape and other feature vectors of the head area) and compare it with the learned hard hat wearing pattern. If the difference exceeds the preset threshold, it is determined to be a safety hazard and the corresponding construction safety detection results are generated. These detection results may include specific hazard types (such as not wearing a hard hat, illegal operation, etc.), hazard locations (marked by image coordinates), and severity assessments. The computer system feeds these results back to construction managers or monitoring system interfaces in real time so that they can take timely measures to correct unsafe behaviors and ensure the smooth progress of the construction process.
[0022] The following describes the debugging process of the construction safety monitoring network. Please refer to Figure 2 , including the following steps:
[0023] Step S10: Obtain the beam yard real-time monitoring image and behavior reference image of each debugging learning sample in P debugging learning samples, and extract the image semantic descriptor of the beam yard real-time monitoring image and the behavior reference image of each debugging learning sample based on the construction safety monitoring network, P≥1.
[0024] In step S10 of the embodiment of the present application, the computer system is responsible for acquiring and processing a series of debugging learning samples for training the network. These samples include real-time monitoring images of the beam yard and behavior reference images, aiming to improve the network's ability to recognize uncertain behaviors in construction scenarios.
[0025] Specifically, the computer system first collects P debugging learning samples from the beam yard monitoring system, where P is an integer greater than or equal to 1, representing the total number of samples. Each debugging learning sample contains a pair of images: a beam yard real-time monitoring image and a behavior reference image. The beam yard real-time monitoring image is usually captured in real time by surveillance cameras installed in various areas of the beam yard. These images may face various challenges, such as workers being partially blocked (such as blocked by steel bars or formwork), there is noise in the image (such as caused by light changes, camera shaking), or the construction behavior itself is not visually clear (such as subtle operations under long-distance observation). For example, the beam yard real-time monitoring image shows a worker standing on the edge of the scaffolding, but it is difficult to directly judge whether he is wearing a safety belt due to distance and angle problems. To make up for this deficiency, the computer system also obtains the corresponding behavior reference images. These images are standard images selected by domain experts after careful analysis and judgment based on the construction behavior in the real-time monitoring image. They clearly show how the construction behavior should be carried out correctly in the same or similar scenarios. Importantly, the behavior reference image is not an absolute judgment of the correctness of the construction behavior, but provides a more clear and unambiguous way to display the behavior. Taking the aforementioned example of not wearing a hard hat, if the worker's head is blocked in the real-time monitoring image, experts will determine whether he is wearing a hard hat based on other clues at the scene (such as the worker's behavior patterns, safety regulations of the surrounding environment, etc.), and select a standard image of not wearing a hard hat in the same scene as a behavioral reference.
[0026] Next, the computer system uses the construction safety monitoring network to conduct in-depth analysis of the beam field real-time monitoring images and behavior reference images in each debugging learning example. This network is built based on deep learning algorithms, especially convolutional neural networks (CNNs), which are good at extracting useful feature information from images. In this process, the network automatically extracts image semantic descriptors from each pair of images. These descriptors can be regarded as high-level feature representations of images. They capture key information in the image, such as shape, texture, color distribution, etc., and are stored in the form of vectors or arrays. For example, in the task of identifying whether a helmet is worn, the image semantic descriptor may contain edge contours and color contrast features of the head area, which help distinguish the state of wearing and not wearing a helmet. By extracting image semantic descriptors, the computer system provides a rich data foundation for subsequent network debugging. These descriptors not only reflect the uncertain behavior in the beam field real-time monitoring images, but also provide clear behavior standards through behavior reference images, which provides strong support for the optimization and training of the construction safety monitoring network.
[0027] Step S20: Based on the preset safety distance, the image semantic descriptors of the real-time monitoring images of the beam yard of each debugging learning sample and the image semantic descriptors of the behavior reference image, the classification interface between the debugging learning samples of different construction behaviors in the P debugging learning samples is strengthened to obtain the network cost of the construction safety monitoring network.
[0028] In the embodiment of the present application, a comparative learning method is used to utilize a preset safety distance (margin) to enhance the classification interface between different construction behaviors, thereby improving the network's ability to identify construction safety hazards.
[0029] First, the computer system obtains P debugging learning samples, each of which contains a pair of images: a real-time monitoring image of the beam field and a behavioral reference image. Through in-depth analysis of these images, their image semantic descriptors have been extracted. These descriptors represent the key feature information in the image in the form of vectors or arrays. Next, these descriptors are operated according to the preset safety distance. The safety distance is an important hyperparameter that defines the minimum interval that should be maintained between different categories (here, different construction behaviors). In contrastive learning, this interval is called margin, and its function is to ensure that the network can clearly distinguish samples of different categories during the learning process and prevent confusion between categories.
[0030] In order to strengthen the classification interface between different construction behaviors, the computer system compares the image semantic descriptors of the beam yard real-time monitoring images and the behavior reference images in each debugging learning example. These descriptors represent the position of the image in the feature space, and the classification interface is the decision boundary between these positions. The system determines whether the current classification interface is clear enough by calculating the distance between descriptors (such as Euclidean distance, cosine similarity, etc.) and combining it with the preset safety distance.
[0031] If the descriptor distance between the real-time monitoring image of a construction behavior and the behavior reference image is less than the safe distance, it means that the current network is not accurate enough in identifying this construction behavior, and the classification interface needs to be strengthened. At this time, a loss function (such as contrast loss, triple loss, etc.) will be used to calculate the network cost (i.e., loss), which reflects the recognition error of the network in the current state. Specifically, the loss function will penalize sample pairs that are too close, and encourage the network to increase the distance between them during the learning process until it exceeds the preset safe distance. For example, in the case of triple loss, a triple (anchor, positive, negative) will be constructed, where the anchor is the descriptor of the real-time monitoring image, the positive is the descriptor of the behavior reference image that belongs to the same construction behavior as the anchor (but more specific), and the negative is the descriptor of another real-time monitoring image that belongs to a different construction behavior than the anchor. The loss function will try to minimize the distance between the anchor and the positive, while maximizing the distance between the anchor and the negative, and this distance difference must be greater than the safe distance.
[0032] Through this process of continuous iteration, the computer system can gradually adjust the parameters of the construction safety monitoring network, making the classification interface between different construction behaviors clearer and more accurate. Finally, when the network cost value is reduced to a certain level, it means that the network has a good construction safety monitoring capability and can be used in the actual beam yard construction safety quality monitoring task.
[0033] Step S30: Debugging the construction safety monitoring network according to the network cost value.
[0034] In the embodiment of the present application, step S30 debugs the construction safety monitoring network according to the previously calculated network cost value to further enhance its ability to identify construction safety hazards.
[0035] Specifically, the network cost value is an important indicator to measure the recognition performance of the construction safety monitoring network in the current state. It reflects the degree of difference between the network output and the true label, that is, the error generated by the network when identifying construction behavior. In step S20, the computer system has calculated the network cost value after strengthening the classification interface based on the preset safety distance through comparative learning. In order to reduce this network cost value and improve the recognition performance of the network, the computer system adopts a series of debugging strategies. These strategies usually involve the adjustment of network security parameters, the optimization of network structure, and the improvement of learning algorithms. For example, the computer system can adjust the hyperparameters such as the weight attenuation coefficient and learning rate in the network to control the training speed and overfitting degree of the network; or optimize the structural parameters such as the number of layers and the number of nodes of the network to enhance the feature extraction and classification capabilities of the network.
[0036] In actual operation, the computer system dynamically adjusts these debugging strategies according to the changes in the network cost value. If the network cost value does not drop significantly in several consecutive training cycles, or there is a trend of increasing fluctuations, then the system can determine that the current debugging strategy is not effective and needs to try a new strategy. For example, more complex regularization methods can be introduced, more advanced optimization algorithms (such as Adam, RMSprop, etc.) can be used, or more training data can be added to enhance the generalization ability of the network.
[0037] The debugging process is an iterative optimization process. The computer system continuously evaluates the changes in the network cost value and adjusts the debugging strategy according to the evaluation results. This process will continue until the network cost value is reduced to a certain level and remains relatively stable. At this point, it can be considered that the construction safety monitoring network has good recognition performance and can be used in the actual beam field construction safety quality monitoring task.
[0038] Taking the detection of safety helmet wearing in beam yard construction as an example, if the construction safety monitoring network can accurately identify whether the workers are wearing safety helmets during the debugging process, and the optimization of the network cost value achieves the expected goal, then in actual application, the network will be able to analyze and process the construction images in the beam yard in real time, promptly discover safety hazards such as not wearing safety helmets, and remind managers through the alarm system to take corresponding measures to ensure construction safety.
[0039] As an implementation method, the debugging process of the construction safety monitoring network includes a pre-debugging stage, and the network cost value includes a first pre-debugging cost value. Based on this, step S20, based on the preset safety distance, and the image semantic descriptor of the beam field real-time monitoring image of each debugging learning sample and the image semantic descriptor of the behavior reference image, strengthen the classification interface between the debugging learning samples of different construction behaviors in the P debugging learning samples, and obtain the network cost value of the construction safety monitoring network, which may specifically include:
[0040] Step S21: Strengthening the classification interface between the image semantic descriptor of the beam yard real-time monitoring image and the image semantic descriptor of the behavior reference image of each debugging learning example according to the safety distance, and determining the first pre-debugging cost value;
[0041] Based on this, step S30, according to the network cost value, debug the construction safety monitoring network, which may specifically include:
[0042] Step S31: pre-debugging the construction safety monitoring network according to the first pre-debugging cost value.
[0043] Step S20 depends not only on the real-time monitoring images of the beam yard and the behavioral reference images in the debugging learning examples, but also on the important parameter of the preset safety distance (margin). The computer system extracts the image semantic descriptors of the real-time monitoring images and behavioral reference images in each debugging learning example. These descriptors are usually high-dimensional vectors that contain quantitative representations of key features in the image. For example, in the scenario of identifying whether a worker is wearing a safety helmet, the descriptor may include the edge contour, color distribution, texture features, etc. of the head area. These feature vectors can capture subtle differences in the image and provide strong support for subsequent classification tasks.
[0044] Next, the preset safety distance is used to evaluate whether the classification interface between different construction behaviors is clear enough. The safety distance is an important hyperparameter that defines the minimum interval that samples of different categories should maintain in the feature space. If the descriptor distance between the real-time monitoring image of a construction behavior and the behavior reference image is less than the safety distance, then the current classification interface is considered not clear enough and needs to be strengthened.
[0045] In order to strengthen the classification interface, one or more contrastive learning methods are used. For example, a triplet loss can be calculated, which encourages the distance between the descriptor of the real-time monitoring image and the descriptor of the behavior reference image of the same construction behavior to be as small as possible, and the distance between the descriptor of the real-time monitoring image of different construction behaviors to be as large as possible, and this distance difference must be greater than the preset safety distance.
[0046] By continuously optimizing this loss function, the parameters of the construction safety monitoring network can be gradually adjusted to make the classification interface between different construction behaviors clearer and more accurate. Finally, a first pre-debugging cost value will be calculated, which reflects the degree of optimization of the classification interface by the network in the pre-debugging stage.
[0047] After obtaining the first pre-debugging cost value, the computer system enters step S30, that is, pre-debugging the construction safety monitoring network according to the network cost value. Pre-debugging is also called pre-training.
[0048] First, the performance of the current network is judged based on the value of the first pre-debugging cost. If the cost is high, it means that the network still has a large error in the classification task and needs further debugging. At this time, a series of debugging strategies can be adopted to reduce the cost.
[0049] Debugging strategies may include adjusting the network's hyperparameters such as learning rate and regularization strength, as well as adopting more advanced optimization algorithms. For example, you can try using the Adam optimization algorithm instead of the traditional SGD algorithm, because the Adam algorithm can automatically adjust the learning rate of each parameter, thereby accelerating the training process and improving convergence performance. In addition, you can also consider adding more debugging learning examples to enrich the training data. More examples can cover a wider range of construction scenarios and behavior patterns, which helps to improve the generalization ability and robustness of the network.
[0050] During the debugging process, the computer system continuously evaluates the changes in the network cost value and dynamically adjusts the debugging strategy based on the evaluation results. This process will continue until the network cost value is reduced to a certain level and remains relatively stable. At this point, it can be considered that the construction safety monitoring network has completed the pre-debugging stage and is ready to enter the subsequent fine training stage.
[0051] Through the pre-debugging stage, the construction safety monitoring network can more accurately identify potential safety hazards when faced with complex and changeable situations in actual beam yard construction scenarios, providing strong protection for construction safety.
[0052] As an implementation mode, the safety distance includes an angular separation margin. Based on this, in step S21, according to the safety distance, the classification interface between the image semantic descriptor of the beam field real-time monitoring image and the image semantic descriptor of the behavior reference image of each debugging learning example is strengthened to determine the first pre-debugging cost value, which may specifically include:
[0053] Step S211: for the xth debugging learning sample among the P debugging learning samples, determining the first direction difference between the image semantic descriptor of the behavior reference image of the xth debugging learning sample and the image semantic descriptor of the beam yard real-time monitoring image, wherein 1≤x≤P;
[0054] Step S212: performing boundary reconstruction on the first direction difference according to the angular separation margin, and obtaining a second direction difference between the image semantic descriptor of the behavior reference image of the x-th debugging learning example and the image semantic descriptor of the beam field real-time monitoring image;
[0055] Step S213: determining a first pre-debugging cost value according to the second direction difference corresponding to each debugging learning example in the P debugging learning examples.
[0056] In step S211 of the embodiment of the present application, the surveillance camera continuously captures real-time images of the construction site, and these images are processed to become real-time monitoring images of the beam field. At the same time, the expert team selects standard images that can clearly show the construction behavior, namely, behavior reference images, based on the uncertain construction behavior in these real-time monitoring images. These image pairs constitute the basis for training the construction safety monitoring network - debugging learning samples. In step S211, the computer system extracts the image semantic descriptors of the real-time monitoring image of the beam field and the behavior reference image for each of the P debugging learning samples (the xth, where 1≤x≤P). These descriptors are usually high-dimensional vectors that contain quantitative representations of key features in the image. For example, in a scenario where a worker is identified as wearing a helmet, the descriptor may include shape feature vectors (such as edge contours) of the head area, color feature vectors (such as the color distribution of the helmet), and the like.
[0057] Next, the first direction difference between the image semantic descriptor of the behavior reference image of the x-th debugging learning example and the image semantic descriptor of the beam field real-time monitoring image is calculated. This direction difference actually refers to the vector angle between the two descriptors in the feature space, which reflects the similarity or difference between the two images at the semantic level. The smaller the angle, the more similar the two images are; the larger the angle, the greater the difference between the two images.
[0058] For example, assuming that the image semantic descriptor of the behavior reference image is vector A ([a1, a2, ..., an]), and the image semantic descriptor of the beam field real-time monitoring image is vector B ([b1, b2, ..., bn]), then the first direction difference θ between them can be calculated by the cosine similarity formula:
[0059] ;;
[0060] Wherein, (A·B) represents the dot product of vectors A and B, (|A|) and (|B|) respectively represent the modulus lengths of vectors A and B. Through the inverse cosine transform, the first direction difference θ can be obtained.
[0061] After obtaining the first direction difference, the computer system strengthens the classification interface according to the angular separation margin. The angular separation margin is a preset parameter that defines the minimum angle difference that samples of different categories should maintain in the feature space to ensure the clarity and robustness of the classification interface.
[0062] In step S212, the first direction difference is boundedly reconstructed, that is, the angle is optimized and adjusted according to the angular separation margin. Specifically, the angular separation margin is added to the first direction difference to obtain a new angle, namely the second direction difference. This second direction difference represents the position of the enhanced classification interface in the feature space. For example, assuming that the angular separation margin is Δθ, the second direction difference θ' of the x-th debugging learning example can be expressed as: θ'=θ+Δθ.
[0063] It should be noted that since the range of the angle θ is [0, π], it may be necessary to normalize θ' in actual calculations to ensure that it still falls within the valid range. However, in most cases, since the angular separation margin Δθ is relatively small and is mainly used to enhance the clarity of the classification interface, θ' rarely exceeds the valid range. Through boundary reconstruction, different construction behaviors that may have been relatively close are separated by a larger distance in the feature space, thereby enhancing the ability to distinguish the classification interface. This is of great significance for improving the recognition accuracy of the construction safety monitoring network.
[0064] After obtaining the second direction differences of all debugging learning samples, the computer system enters step S213 to determine the first pre-debugging cost value based on these second direction differences. This cost value reflects the effect of the construction safety monitoring network strengthening the classification interface in the pre-debugging stage.
[0065] Specifically, a contrast loss function (such as Triplet Loss) can be used to calculate the cost. The contrast loss function is designed to encourage samples of the same category to be closer in the feature space, while samples of different categories maintain a certain distance. In this scenario, the real-time monitoring image of the beam field of each debugging learning example can be regarded as an anchor, the behavior reference image can be regarded as a positive sample, and the real-time monitoring images in other debugging learning examples may be used as negative samples to participate in the calculation (although in actual operation, it may not be necessary to explicitly select negative samples).
[0066] However, here we are more concerned with how to calculate the cost value through the second direction difference. A simple method is to define a cost function based on the angle difference, which decreases as the second direction difference increases (because the larger the second direction difference, the clearer the classification interface). For example, the cost function can be designed as:
[0067] ;
[0068] Among them, β is a hyperparameter used to control the sensitivity of the cost function to the second direction difference; θ' is the second direction difference of the x-th debugging learning example; θ_target is a target angle threshold. When the second direction difference is greater than this threshold, the classification interface is considered to be clear enough. This cost function uses the properties of the sigmoid function. When θ' is close to or greater than θ_target, the cost approaches 0; when θ' is much smaller than θ_target, the cost increases significantly.
[0069] However, it should be noted that the above cost function is only given as an example. In practice, a more complex cost function can be designed according to specific application scenarios and requirements. For example, the cost function can consider factors such as the weight difference between different debugging learning samples and the contribution of different feature dimensions to the classification interface reinforcement.
[0070] Finally, the computer system calculates the sum (or weighted average sum) of the costs corresponding to all debugging learning examples to obtain the first pre-debugging cost value. This cost value will serve as one of the important reference indicators in the subsequent debugging process, used to evaluate the performance of the construction safety monitoring network in the pre-debugging stage, and guide the subsequent debugging strategy adjustment.
[0071] Taking the monitoring of workers wearing helmets in beam yard construction as an example, the specific role of the above steps in practical applications can be further explained. Assume that the surveillance camera captures a real-time monitoring image in which a worker's head is partially blocked, and it is impossible to directly determine whether he is wearing a helmet. At this time, the expert team will select a behavioral reference image based on this image, which clearly shows the situation of the worker not wearing a helmet in the same scene.
[0072] In step S21, the computer system first extracts the image semantic descriptors of the two images and calculates the first direction difference between them. Since the head of the worker in the real-time monitoring image is blocked, its descriptor may be different from the descriptor of the behavior reference image, but this difference may not be enough for the construction safety monitoring network to make an accurate judgment.
[0073] Therefore, in step S212, the first direction difference is boundedly reconstructed by introducing an angular separation margin to obtain a second direction difference. This second direction difference further increases the distance between the real-time monitoring image and the behavior reference image in the feature space, thereby enhancing the distinguishing ability of the classification interface.
[0074] Finally, in step S213, the first pre-debugging cost is calculated based on the second direction difference of all debugging learning samples. If the cost is high, it means that the current network still has a large error in identifying whether the worker is wearing a helmet, and further debugging is needed. At this time, a series of debugging strategies can be adopted to reduce the cost, such as adjusting the network structure, optimizing hyperparameters, and increasing training data.
[0075] Through the implementation of the above steps, the construction safety monitoring network can more accurately identify key safety hazards such as whether workers are wearing safety helmets when facing complex and changeable beam yard construction scenes, thereby providing strong protection for construction safety. At the same time, this process also provides important reference and guidance for subsequent network training and debugging.
[0076] As an implementation manner, step S211, determining the first direction difference between the image semantic descriptor of the behavior reference image of the x-th debugging learning example and the image semantic descriptor of the beam field real-time monitoring image, may specifically include:
[0077] Step S2111: Determine the first direction difference between the image semantic descriptor of the behavior reference image of the x-th debugging learning example and the image semantic descriptor of the real-time monitoring image of the beam field, and the first direction difference between the image semantic descriptor of the real-time monitoring image of the beam field and the image semantic descriptor of the behavior reference image.
[0078] In beam yard construction monitoring, due to the complex and changeable construction site environment, the real-time monitoring images captured by the surveillance camera are often affected by multiple factors such as lighting, occlusion, and noise, making it difficult to directly extract key information from the image. Therefore, the computer system first processes the image through a deep learning algorithm (such as a convolutional neural network CNN) to extract the image semantic descriptor. These descriptors are usually high-dimensional vectors that can capture key features in the image, such as shape, texture, color, etc.
[0079] In step S211, the computer system calculates the first direction difference between the image semantic descriptor of the behavior reference image and the image semantic descriptor of the beam field real-time monitoring image for the x-th debugging learning example (where 1≤x≤P), and also calculates the first direction difference between the image semantic descriptor of the beam field real-time monitoring image and the image semantic descriptor of the behavior reference image. This two-way calculation method helps to more comprehensively evaluate the similarity or difference between the two images in the feature space.
[0080] Assume that the behavior reference image (referred to as image A) in the xth debugging learning example shows a scene where a worker wears a helmet correctly, and the beam yard real-time monitoring image (referred to as image B) captures the real-time picture of the same worker during the construction process, but because the head is partially blocked, it is impossible to directly determine whether he is wearing a helmet. Through algorithms such as CNN, the computer system extracts the image semantic descriptors of image A and image B, which are respectively recorded as vectors (A = [a_1, a_2, ..., a_n]) and vectors (B = [b_1, b_2, ..., b_n]). Among them, n is the dimension of the descriptor, which represents the number of different features in the image.
[0081] Next, the angle between the two descriptors is calculated as the first direction difference. Since the angle is bidirectional, the system needs to calculate the angle θ_AB from vector A to vector B and the angle θ_BA from vector B to vector A respectively. Although θ_AB and θ_BA should be equal (that is, the cosine values of the angles are the same) in an ideal case, in practical applications, due to the precision limitations of numerical calculations and slight differences in feature extraction, the two may be slightly different. The angles θ_AB and θ_BA can be calculated using the cosine similarity formula:
[0082] ;
[0083] ;
[0084] Step S212, based on the angular separation margin, the first direction difference is boundedly reconstructed to obtain the second direction difference between the image semantic descriptor of the behavior reference image of the x-th debugging learning example and the image semantic descriptor of the beam field real-time monitoring image, which may specifically include:
[0085] Step S2121: Based on the angular separation margin, the first direction difference between the image semantic descriptor of the behavior reference image of the x-th debugging learning sample and the image semantic descriptor of the real-time monitoring image of the beam field, and the first direction difference between the image semantic descriptor of the real-time monitoring image of the beam field and the image semantic descriptor of the behavior reference image are boundary reconstructed to obtain the second direction difference between the image semantic descriptor of the behavior reference image of the x-th debugging learning sample and the image semantic descriptor of the real-time monitoring image of the beam field, and the second direction difference between the image semantic descriptor of the real-time monitoring image of the beam field and the image semantic descriptor of the behavior reference image.
[0086] After obtaining the first direction difference, the computer system needs to strengthen the classification interface according to the preset angular separation margin. The angular separation margin is an important hyperparameter that defines the minimum angle difference that samples of different categories should maintain in the feature space. By increasing this difference, the classification interface can be made clearer and more robust. In step S212, the computer system reconstructs the boundaries of the two first direction differences (θ_AB and θ_BA) calculated in step S211. Specifically, the angular separation margin Δθ is added to each first direction difference to obtain two new angles, namely the second direction differences θ'_AB and θ'_BA.
[0087] Continuing with image A and image B as an example, assuming that the preset angular separation margin is Δθ, the system first calculates the second direction difference θ'_AB from image A to image B:
[0088] θ'_AB=θ_AB+Δθ;
[0089] Then calculate the second direction difference θ'_BA from image B to image A:
[0090] θ'_BA=θ_BA+Δθ;
[0091] It should be noted that since the value range of the angle θ is [0, π], the second direction difference needs to be normalized after boundary reconstruction to ensure that it still falls within the valid range. However, in most cases, since the angular separation margin Δθ is relatively small and is mainly used to enhance the clarity of the classification interface, θ'_AB and θ'_BA rarely exceed the valid range. Through boundary reconstruction, different construction behaviors that may have been relatively close (such as wearing a helmet and not wearing a helmet) are further apart in the feature space, thereby enhancing the ability to distinguish the classification interface. This is of great significance for improving the recognition accuracy of the construction safety monitoring network.
[0092] Step S213, determining a first pre-debugging cost value according to the second direction difference corresponding to each debugging learning example in the P debugging learning examples, may specifically include:
[0093] Step S2131: Determine the first pre-debugging cost value based on the second direction difference between the image semantic descriptor of the behavior reference image of each debugging learning sample in the P debugging learning samples and the image semantic descriptor of the real-time monitoring image of the beam field, and the second direction difference between the image semantic descriptor of the real-time monitoring image of the beam field and the image semantic descriptor of the behavior reference image.
[0094] After obtaining the second direction differences of all debugging learning samples, the computer system enters step S213 to determine the first pre-debugging cost value based on these second direction differences. This cost value reflects the overall effect of the construction safety monitoring network on strengthening the classification interface during the pre-debugging stage.
[0095] In step S213, a suitable cost function needs to be designed to calculate the cost value. This cost function should be able to reflect the relationship between the second direction difference and the clarity of the classification interface: when the second direction difference is large (indicating that the classification interface is clear), the cost value should be small; when the second direction difference is small (indicating that the classification interface is blurred), the cost value should be large. However, since the bidirectional second direction difference (θ'_AB and θ'_BA) is calculated in step S212, these two direction differences need to be considered comprehensively when determining the cost value. A simple method is to take the larger value or the average value of the two as the second direction difference representing the debugging learning example to participate in subsequent calculations. But more commonly, a cost function that can consider both direction differences at the same time is designed. To simplify the explanation, it is assumed that the system uses a cost function based on the average second direction difference to calculate the first pre-debugging cost value. Specifically, for each debugging learning example x (where 1≤x≤P), first calculate the average value of its two second direction differences θ'_AB and θ'_BA:
[0096] ;
[0097] Then, a cost function is designed based on the average second direction difference of all debugging learning examples. This cost function may take into account factors such as the weight difference between different debugging learning examples and the contribution of different feature dimensions to the classification interface reinforcement. But here, in order to simplify the explanation, it is assumed that the cost function is only inversely proportional to the average second direction difference (that is, the larger the average second direction difference, the smaller the cost value):
[0098] ;
[0099] Among them, β is a hyperparameter used to control the sensitivity of the cost function to the average second direction difference; θ_target is a target angle threshold. When the average second direction difference is greater than this threshold, the classification interface is considered to be clear enough. It should be noted that the above cost function is only given as an example. In practice, more complex cost functions can be designed according to specific application scenarios and requirements.
[0100] It should be noted that the summation term in the above cost function may not directly reflect the contribution of all debugging learning examples to the cost value. In practical applications, more complex cost functions can be used, such as variants based on Triplet Loss or customized contrast loss functions, which can more directly evaluate the relative distance between samples of different categories and calculate more representative cost values accordingly.
[0101] Finally, the computer system calculates the sum (or weighted average sum) of the costs corresponding to all debugging learning examples to obtain the first pre-debugging cost value. This cost value will serve as one of the important reference indicators in the subsequent debugging process, used to evaluate the performance of the construction safety monitoring network in the pre-debugging stage, and guide the subsequent debugging strategy adjustment.
[0102] As an implementation manner, step S2111, determining the first direction difference between the image semantic descriptor of the behavior reference image of the x-th debugging learning example and the image semantic descriptor of the beam field real-time monitoring image, and the first direction difference between the image semantic descriptor of the beam field real-time monitoring image and the image semantic descriptor of the behavior reference image, may specifically include:
[0103] Step S21111: determining a first direction cosine metric between an image semantic descriptor of a behavior reference image of an x-th debugging learning example and an image semantic descriptor of an image of a beam field real-time monitoring image, and performing angle solving on the first direction cosine metric to obtain a first direction difference between an image semantic descriptor of the behavior reference image of an x-th debugging learning example and an image semantic descriptor of an image of a beam field real-time monitoring image;
[0104] Step S21112: Determine the second direction cosine measurement between the image semantic descriptor of the real-time monitoring image of the beam field of the x-th debugging learning example and the image semantic descriptor of the behavior reference image, and perform angle solution on the second direction cosine measurement to obtain the first direction difference between the image semantic descriptor of the real-time monitoring image of the beam field of the x-th debugging learning example and the image semantic descriptor of the behavior reference image.
[0105] In step S2111, the surveillance camera continuously captures the real-time images of the construction site to form a real-time monitoring image of the beam field. At the same time, the expert team will select standard images that can clearly show the construction behavior based on the uncertain construction behavior in these real-time monitoring images, namely the behavior reference images. For each debugging learning example (denoted as the xth example, where 1≤x≤P), the computer system needs to calculate the bidirectional first direction difference between the behavior reference image and the real-time monitoring image of the beam field. This calculation process not only considers the direction from the behavior reference image to the real-time monitoring image, but also the opposite direction to ensure the comprehensiveness and accuracy of the calculation.
[0106] In step S21111, the computer system determines the image semantic descriptors of the behavior reference image (referred to as image A) and the beam yard real-time monitoring image (referred to as image B) of the x-th debugging learning example. These descriptors are usually high-dimensional vectors that can capture key feature information in the image, such as shape, texture, color distribution, etc. For example, in the scenario of identifying whether a worker is wearing a safety helmet, the descriptor may include an edge contour feature vector and a color feature vector of the head area. Next, the first direction cosine metric between the two descriptors, i.e., cosine similarity, is calculated. Cosine similarity is an indicator that measures the degree of similarity between two vectors in direction, and its value range is [-1, 1]. When the directions of the two vectors are exactly the same, the cosine similarity is 1; when the directions are completely opposite, the cosine similarity is -1; when the two vectors are perpendicular, the cosine similarity is 0. For image semantic descriptors, the closer the cosine similarity is to 1, the more similar the two images are semantically.
[0107] Assuming that the image semantic descriptor of image A is a vector (A = [a_1, a_2, ..., a_n]), and the image semantic descriptor of image B is a vector (B = [b_1, b_2, ..., b_n]), the first direction cosine metric cos(θ_AB) between them can be calculated by the following formula:
[0108] ;
[0109] Where (A·B) represents the dot product of vectors A and B, (|A|) and (|B|) represent the modulus of vectors A and B, respectively.
[0110] After obtaining the cosine similarity, it needs to be converted into an angle form to more intuitively represent the direction difference between the two vectors. This conversion process can be achieved through the inverse cosine transformation:
[0111] θ_AB=arccos(cos(θ_AB);
[0112] Among them, θ_AB is the first direction difference between the behavior reference image of the x-th debugging learning example and the real-time monitoring image of the beam field, and its value range is [0, π].
[0113] Taking the monitoring of workers wearing helmets in beam yard construction as an example, suppose image A shows a scene of a worker wearing a helmet correctly, and image B is a real-time monitoring image of the same worker during construction. However, due to some reasons (such as head occlusion, lighting changes, etc.), it is impossible to directly determine whether he is wearing a helmet. Through deep learning algorithms (such as convolutional neural networks CNN), the computer system extracts image semantic descriptor vectors A and B of image A and image B respectively. Then, the cosine similarity between the two vectors is calculated to obtain cos(θ_AB). Since there may be some differences in semantics between image A and image B (although they describe the same worker), the value of cos(θ_AB) may be less than 1 but greater than a certain threshold (indicating that the two still have some similarity).
[0114] Next, perform an inverse cosine transformation on cos(θ_AB) to obtain the angle θ_AB. This angle intuitively reflects the directional difference between image A and image B in the feature space. If θ_AB is small, it means that the two images are close in direction, which may mean that the worker is wearing a helmet; if θ_AB is large, it means that there is a large difference in direction between the two images, which may mean that the worker is not wearing a helmet or is wearing it improperly.
[0115] Step S21112 is similar to step S21111, but in the opposite direction. In this step, the computer system calculates the second direction cosine metric, i.e., cosine similarity, between the beam field real-time monitoring image (image B) and the behavior reference image (image A) of the x-th debugging learning example, and solves the angle. Since the dot product operation satisfies the commutative law ((A·B = B·A)) and the vector modulus is unchanged ((|A| = |A|) and (|B| = |B|)), the second direction cosine metric cos(θ_BA) is actually equal to the first direction cosine metric cos(θ_AB):
[0116] ;
[0117] Similarly, perform an inverse cosine transform on cos(θ_BA) to obtain the angle θ_BA:
[0118] ;
[0119] By implementing the above step S2111, the computer system can accurately calculate the bidirectional first direction difference between the behavior reference image of the x-th debugging learning example and the real-time monitoring image of the beam field. This calculation process not only considers the direction from the behavior reference image to the real-time monitoring image, but also considers the opposite direction, thereby ensuring the comprehensiveness and accuracy of the calculation. By combining the cosine similarity and the inverse cosine transform, the similarity between high-dimensional vectors can be converted into an intuitive angle form, which provides an important basis for the subsequent classification interface reinforcement and cost value calculation.
[0120] As an implementation mode, step S2121, based on the angular separation margin, boundary reconstruction is performed on the first direction difference between the image semantic descriptor of the behavior reference image of the x-th debugging learning example and the image semantic descriptor of the beam field real-time monitoring image, and the first direction difference between the image semantic descriptor of the beam field real-time monitoring image and the image semantic descriptor of the behavior reference image, respectively, to obtain the second direction difference between the image semantic descriptor of the behavior reference image of the x-th debugging learning example and the image semantic descriptor of the beam field real-time monitoring image, and the second direction difference between the image semantic descriptor of the beam field real-time monitoring image and the image semantic descriptor of the behavior reference image, which may specifically include:
[0121] Step S21211: the safety distance is added to the first direction difference between the image semantic descriptor of the behavior reference image of the x-th debugging learning example and the image semantic descriptor of the beam field real-time monitoring image, and the second direction difference between the image semantic descriptor of the behavior reference image of the x-th debugging learning example and the image semantic descriptor of the beam field real-time monitoring image is determined;
[0122] Step S21212: The sum of the safety distance and the first direction difference between the image semantic descriptor of the real-time monitoring image of the beam field of the x-th debugging learning example and the image semantic descriptor of the behavior reference image is determined as the second direction difference between the image semantic descriptor of the real-time monitoring image of the beam field of the x-th debugging learning example and the image semantic descriptor of the behavior reference image.
[0123] In the embodiment of the present application, the computer system debugs the construction safety monitoring network through a series of fine steps to ensure that it can accurately identify various safety hazards in the construction process. Step S2121, as one of the key links in this process, focuses on reconstructing the boundaries of the first direction difference to introduce an angular separation margin (i.e., a safety distance), thereby enhancing the clarity and robustness of the classification interface.
[0124] In step S211, the computer system has calculated the bidirectional first direction differences (θ_AB and θ_BA) between the behavioral reference image of the x-th debugging learning example and the real-time monitoring image of the beam field. However, these first direction differences may not be sufficient to ensure the clarity and robustness of the classification interface, especially when facing a complex and changeable construction site environment. Therefore, in step S2121, by introducing an angular separation margin (denoted as Δθ), the first direction difference is boundedly reconstructed to obtain the second direction difference (θ'_AB and θ'_BA) to further enhance the distinguishing ability of the classification interface.
[0125] In step S21211, the computer system adds the angular separation margin Δθ to the first direction difference θ_AB from the behavior reference image of the x-th debugging learning sample to the real-time monitoring image of the beam field to obtain the second direction difference θ'_AB. This operation actually adds an additional angle interval on the basis of the original direction difference to ensure that samples of different categories (or different construction behaviors) maintain a sufficient distance in the feature space. The specific calculation process is as follows:
[0126] ;
[0127] Among them, θAB is the first direction difference, which represents the original angle between the behavior reference image and the real-time monitoring image in the feature space; Δθ is the angular separation margin, which is a preset hyperparameter used to enhance the clarity of the classification interface; θ'AB is the second direction difference, which represents the new angle after boundary reconstruction.
[0128] Taking the monitoring of workers wearing helmets in beam yard construction as an example, assume that image A is a behavioral reference image, showing the scene of workers wearing helmets correctly; image B is a real-time monitoring image of the beam yard, capturing the real-time picture of the same worker during the construction process. Through the calculation of step S211, the first direction difference θ_AB from image A to image B has been obtained.
[0129] Now, the angular separation margin Δθ needs to be added to θ_AB to obtain the second direction difference θ'_AB. Assume that Δθ is 0.1 radians (this is just an example value, and it may be adjusted according to the specific application scenario and requirements in practice), and θ_AB is 0.5 radians (indicating that image A and image B have certain similarities in the feature space but are not exactly the same). Then the second direction difference θ'_AB after boundary reconstruction is 0.5 + 0.1 = 0.6. This new angle θ'_AB reflects the clearer distinction between the behavioral reference image and the real-time monitoring image in the feature space after the introduction of the angular separation margin. When the construction safety monitoring network makes classification judgments, it will use this enhanced distinction to more accurately identify the workers' helmet wearing conditions.
[0130] Step S21212 is similar to step S21211, but in the opposite direction. In this step, the computer system adds the angular separation margin Δθ to the first direction difference θ_BA from the beam field real-time monitoring image to the behavior reference image of the x-th debugging learning example to obtain the second direction difference θ'_BA.
[0131] However, since the dot product operation satisfies the commutative law (i.e. (A·B = B·A)) and the vector modulus is unchanged (i.e. (|A| =|A|) and (|B| = |B|)), when calculating the cosine similarity, the cosine value obtained from the direction from image A to image B is the same as the cosine value obtained from the direction from image B to image A. Therefore, the first direction differences θ_AB and θ_BA obtained by the inverse cosine transform should also be equal (although there may be slight differences in actual calculations due to numerical accuracy and other reasons).
[0132] It can be inferred that the second direction difference θ'_AB and θ'_BA should also be equal:
[0133] ;
[0134] Through the implementation of the above step S2121, the computer system successfully reconstructs the boundary of the bidirectional first direction difference between the behavior reference image of the x-th debugging learning example and the real-time monitoring image of the beam field, and obtains the second direction differences θ'_AB and θ'_BA. This process enhances the clarity and robustness of the classification interface by introducing the angular separation margin Δθ, providing a more reliable basis for subsequent classification judgment and cost value calculation.
[0135] As an implementation manner, step S2131 determines the first pre-debugging cost value according to the second direction difference between the image semantic descriptor of the behavior reference image of each debugging learning example in the P debugging learning examples and the image semantic descriptor of the beam field real-time monitoring image, and the second direction difference between the image semantic descriptor of the beam field real-time monitoring image and the image semantic descriptor of the behavior reference image, which may specifically include:
[0136] Step S21311: determining a third direction difference between an image semantic descriptor of a behavior reference image of the x-th debugging learning sample and an image semantic descriptor of a beam field real-time monitoring image of each debugging learning sample in O debugging learning samples, and a fourth direction difference between an image semantic descriptor of the beam field real-time monitoring image of the x-th debugging learning sample and an image semantic descriptor of a behavior reference image of each debugging learning sample in O debugging learning samples, where the O debugging learning samples are debugging learning samples other than the x-th debugging learning sample in P debugging learning samples, and O=P-1;
[0137] Step S21312: determining a first error between the behavior reference image of the xth debugging learning example and the beam yard real-time monitoring image of the Oth debugging learning example based on the second direction difference between the image semantic descriptor of the behavior reference image of the xth debugging learning example and the image semantic descriptor of the beam yard real-time monitoring image, and the third direction difference corresponding to the xth debugging learning example;
[0138] Step S21313: Determine the second error between the real-time monitoring image of the beam field of the xth debugging learning example and the behavior reference image of the Oth debugging learning example based on the second direction difference between the image semantic descriptor of the beam field real-time monitoring image of the xth debugging learning example and the image semantic descriptor of the behavior reference image, and the fourth direction difference corresponding to the xth debugging learning example;
[0139] Step S21314: Determine a first pre-debugging cost value according to the first error and the second error corresponding to each debugging learning example in the P debugging learning examples.
[0140] In step S212, the computer system has calculated the second direction difference (θ'_AB and θ'_BA, although θ'_AB is usually equal to θ'_BA due to the symmetry of cosine similarity, the concept of bidirectional calculation is still retained here for easy understanding) between the behavior reference image of each sample in the P debugging learning samples and the real-time monitoring image of the beam field. Now, it is necessary to further use these second direction differences and the relationship with other debugging learning samples to determine the first pre-debugging cost value.
[0141] In step S21311, the computer system first focuses on the relationship between the xth debugging learning example (where 1≤x≤P) and the other O debugging learning examples (O=P-1, i.e., all examples except the xth example). Specifically, two sets of directional differences need to be calculated:
[0142] The third direction difference is the angle between the image semantic descriptor of the behavior reference image of the xth debugging learning example and the image semantic descriptor of the beam field real-time monitoring image of each debugging learning example in the O debugging learning examples. These angles reflect the relative position relationship between the behavior reference image and other real-time monitoring images in the feature space.
[0143] Fourth direction difference: the angle between the image semantic descriptor of the beam field real-time monitoring image of the xth debugging learning example and the image semantic descriptor of the behavior reference image of each debugging learning example in the O debugging learning examples. These angles reflect the relative position relationship between the real-time monitoring image and other behavior reference images in the feature space.
[0144] It should be noted that the direction differences calculated here are not directly used for subsequent error calculation and cost value determination, but are used as the basis for evaluating the similarities and differences between different debugging learning examples. In practical applications, these direction differences can be calculated by cosine similarity and converted into angle form for easier understanding.
[0145] However, to simplify the description and maintain consistency with the previous steps, it can be assumed that these directional differences have been optimized or adjusted in some way (such as through a preset boundary reconstruction process), although this optimization process is not explicitly mentioned in step S21311.
[0146] Assume that P=4, that is, there are a total of 4 debugging learning samples. Focusing on the first debugging learning sample (recorded as sample 1), then O=3, that is, the other 3 samples other than sample 1 (recorded as sample 2, sample 3, sample 4). For the third direction difference: the system needs to calculate the angle between the behavior reference image of sample 1 and the beam field real-time monitoring image of sample 2, sample 3, and sample 4. These angles are recorded as θ_12', θ_13', and θ_14', respectively, where the subscripts represent the numbers of the two samples for calculating the angle, and the apostrophe indicates that this is the angle after some optimization or adjustment (although the optimization process is not explicitly mentioned in step S21311, it can be assumed that it has occurred). For the fourth direction difference: the system needs to calculate the angle between the beam field real-time monitoring image of sample 1 and the behavior reference image of sample 2, sample 3, and sample 4. These angles are denoted as θ_21', θ_31', and θ_41', respectively. Again, the subscripts indicate the numbers of the two samples for calculating the angles, and the prime sign indicates that the angles have been optimized or adjusted.
[0147] In step S21312, the computer system uses the second direction difference (θ'_AB) from the behavior reference image of the x-th debugging learning example to the beam field real-time monitoring image, and the third direction difference (such as θ_12', θ_13', θ_14') between the sample and the beam field real-time monitoring image of the other O debugging learning examples to determine the first error. The first error reflects the position deviation of the behavior reference image of the x-th debugging learning example relative to other real-time monitoring images in the feature space. This deviation may be caused by a variety of factors, such as differences in construction scenes, changes in lighting conditions, occlusion, etc. By calculating the first error, the sensitivity and robustness of the current classification interface to these deviations can be evaluated. However, it should be noted that the specific calculation formula for the first error is not directly given in step S21312. In practical applications, the calculation of the first error may involve comprehensive consideration of multiple factors, such as the absolute value of the direction difference, the relative relationship between the direction differences, and the weight distribution of different debugging learning examples.
[0148] To simplify the description, it can be assumed that the first error is proportional to some difference measure between the second direction difference and the third direction difference. For example, the average difference or maximum difference between the second direction difference and all third direction differences can be calculated, and this difference value is used as part of the first error.
[0149] Step S21313 is similar to step S21312, but focuses on the second direction difference (θ'_BA, although in most cases it is equal to θ'_AB) from the real-time monitoring image of the beam field of the x-th debugging learning example to the behavioral reference image, and the fourth direction difference (such as θ_21', θ_31', θ_41') between this example and the behavioral reference images of the other O debugging learning examples.
[0150] The second error reflects the position deviation of the real-time monitoring image of the x-th debugging learning example in the feature space relative to other behavior reference images. Similar to the first error, the calculation of the second error may also involve a comprehensive consideration of multiple factors. However, since the real-time monitoring images usually contain more noise and uncertainty (such as occlusion, lighting changes, etc.), the second error may be more challenging than the first error.
[0151] In step S21314, the computer system combines the first error and the second error corresponding to each sample in the P debugging learning samples to determine the first pre-debugging cost value. This cost value reflects the optimization degree and overall performance of the classification interface of the construction safety monitoring network in the pre-debugging stage.
[0152] Specifically, a weighted summation method can be used to calculate the cost value. The first error and second error of each debugging learning example will be assigned a certain weight (these weights may be assigned based on factors such as the importance, difficulty, and reliability of the example), and then the total cost value is obtained by summing them up.
[0153] In addition, some regularization or penalty terms may be introduced to further adjust the cost value. For example, if the first error or second error of a debugging learning example is too large, an additional penalty can be imposed on it to ensure that the network pays more attention to these difficult-to-distinguish examples during training.
[0154] The final first pre-debugging cost value will be used as one of the important reference indicators for the subsequent debugging process. By continuously iterating and optimizing this cost value, the parameters and structure of the construction safety monitoring network can be gradually adjusted to improve its accuracy and robustness in identifying construction safety hazards.
[0155] Through the implementation of the above step S2131, the computer system can comprehensively evaluate the positional relationship and deviation of P debugging learning samples in the feature space, and determine the first pre-debugging cost value accordingly. This process not only considers the relationship between the behavioral reference image and the real-time monitoring image within a single debugging learning sample (through the second direction difference), but also considers the relationship between different debugging learning samples (through the calculation of the third and fourth direction differences and the first and second errors). By combining these factors, the performance of the construction safety monitoring network can be more accurately evaluated, and strong support can be provided for its subsequent optimization. In the actual application of beam yard construction safety quality monitoring, this process is of great significance for improving the recognition accuracy of the network and reducing the false alarm rate and missed alarm rate.
[0156] As an implementation manner, step S21312, based on the second direction difference between the image semantic descriptor of the behavior reference image of the xth debugging learning example and the image semantic descriptor of the beam field real-time monitoring image, and the third direction difference corresponding to the xth debugging learning example, determines the first error between the behavior reference image of the xth debugging learning example and the beam field real-time monitoring image of the Oth debugging learning example, which may specifically include:
[0157] Step S213121: performing a commonality metric transformation on the second direction difference between the image semantic descriptor of the behavior reference image of the x-th debugging learning example and the image semantic descriptor of the beam field real-time monitoring image, to obtain a first commonality metric value between the behavior reference image of the x-th debugging learning example and the beam field real-time monitoring image;
[0158] Step S213122: performing a commonality metric transformation on the third direction difference between the image semantic descriptor of the behavior reference image of the xth debugging learning sample and the image semantic descriptor of the beam field real-time monitoring image of each debugging learning sample in the O debugging learning samples, to obtain a second commonality metric value between the behavior reference image of the xth debugging learning sample and the beam field real-time monitoring image of each debugging learning sample in the O debugging learning samples;
[0159] Step S213123: Determine the first error corresponding to the xth debugging learning sample based on the first commonality measurement value between the behavior reference image of the xth debugging learning sample and the real-time monitoring image of the beam yard, and the second commonality measurement value between the behavior reference image of the xth debugging learning sample and the real-time monitoring image of the beam yard of each of the O debugging learning samples.
[0160] In step S21312, the computer system needs to determine the first error corresponding to the xth debugging learning sample based on the second direction difference (θ'_AB) between the behavior reference image of the xth debugging learning sample and the real-time monitoring image of the beam field, and the third direction difference (such as θ_12', θ_13', θ_14', etc., where the subscripts represent the numbers of the two samples for calculating the angle) between the sample and the real-time monitoring image of the beam field of the other O debugging learning samples. This process involves the common metric transformation of the direction difference and the error calculation.
[0161] In step S213121, the computer system first performs a common metric transformation on the second direction difference (θ'_AB) between the behavioral reference image of the x-th debugging learning example and the real-time monitoring image of the beam field. Common metric transformation is a process of converting an original metric value (such as an angle, distance, etc.) into a new metric value with common properties and scales for subsequent comparison and analysis. For angles, a common common metric transformation method is to first operate on the cosine value, and then perform an appropriate nonlinear transformation (such as an exponential operation) to expand the difference between different angles. The cosine value (i.e. (\cos(\theta'_AB))) reflects the similarity of two vectors in direction, and its value range is [-1, 1]. Through nonlinear transformations such as exponential operations, this similarity metric can be converted into a new value that is more sensitive to changes in the angle in terms of numerical value, and thus can better reflect the differences between different directions. The specific calculation process is as follows:
[0162] Calculate the cosine value: First calculate the cosine value of the second direction difference θ'_AB.
[0163] Nonlinear transformation: Then, the cosine value is subjected to nonlinear transformation, such as exponential operation. Assuming that the transformation function used is (f(x) = e^{\alpha x}) (where α is a positive hyperparameter used to control the sensitivity and scale of the transformation), the transformed first commonality measure (M1) can be expressed as:
[0164] ;
[0165] Here, the choice of α needs to be adjusted according to the specific application scenario and debugging requirements. A larger α value will make the transformed metric value more sensitive to the change of the angle, but it may also cause numerical instability; a smaller α value will make the transformed metric value change more slowly, but it may not fully reflect the differences between different angles.
[0166] Assume that the second direction difference θ'_AB between the behavior reference image of the x-th debugging learning example and the real-time monitoring image of the beam field is 0.3 radians (about 17°), and the α value in the selected nonlinear transformation function is 2. Then the calculation process of the first commonality metric value (M_1) is as follows:
[0167] ;
[0168] ;
[0169] This first commonality metric (M1) reflects the directional similarity between the behavior reference image and the real-time monitoring image. After nonlinear transformation, its value is more sensitive to the change of the angle.
[0170] In step S213122, the computer system performs the same commonality measurement transformation on the third direction difference (such as θ_12', θ_13', θ_14', etc.) between the behavior reference image of the xth debugging learning example and the beam field real-time monitoring image of each debugging learning example in the O debugging learning examples to obtain the second commonality measurement value. These second commonality measurement values respectively reflect the similarity in direction between the behavior reference image and other real-time monitoring images, and the difference is amplified after nonlinear transformation.
[0171] The specific calculation process is similar to step S213121, except that the input direction difference is different. For each third direction difference θ_xy' (where x represents the number of the currently concerned debugging learning sample, and y represents the number of other debugging learning samples), the corresponding second commonality metric value (M{xy}) will be calculated:
[0172] ;
[0173] Continuing with the example of the xth debugging learning sample, assume that the third-direction differences between it and the other three debugging learning samples (sample 2, sample 3, sample 4) are θ_12', θ_13', and θ_14' respectively. The system performs commonality metric transformation on these third-direction differences and obtains three second commonality metric values (M_{12}), (M_{13}), and (M_{14}).
[0174] In step S213123, the computer system determines the first error corresponding to the xth debugging learning sample based on the first commonality measurement value ((M_1)) between the behavior reference image of the xth debugging learning sample and the real-time monitoring image of the beam field, and the second commonality measurement value ((M_{xy})) between the sample and the real-time monitoring image of the beam field of each debugging learning sample in the other O debugging learning samples.
[0175] The calculation of the first error may involve comprehensive consideration of multiple factors, such as the difference between the first commonality metric value and the second commonality metric value, the relative relationship between different second commonality metric values, and the importance of these metrics in the network debugging process, etc. However, in order to simplify the description and maintain consistency with the previous steps, it can be assumed that the first error is proportional to a certain difference metric between the first commonality metric value and all second commonality metric values.
[0176] One possible approach is to calculate the average difference or maximum difference between the first commonality metric and all second commonality metric values, and use this difference value as part of the first error. Another more complex approach is to introduce a weighted difference measure, in which the weights of different second commonality metrics may be assigned based on their similarity, importance, or other factors to the current debugging learning sample. However, the specific first error calculation formula is no longer given here, because the design of this formula in actual application may vary depending on specific scenarios and requirements. But no matter how the formula is designed, the core idea is to evaluate the impact of the directional difference between the behavior reference image and the real-time monitoring image (as well as between other real-time monitoring images) on the network classification performance, and calculate an error value that can reflect this impact based on this.
[0177] The first error finally obtained will serve as one of the important reference indicators in the subsequent debugging process. By continuously iteratively optimizing this error value, the parameters and structure of the construction safety monitoring network can be gradually adjusted to improve its accuracy and robustness in identifying construction safety hazards.
[0178] Through the implementation of the above step S21312, the computer system can comprehensively evaluate the directional differences between the behavior reference image of the x-th debugging learning sample and the real-time monitoring image of the beam field, as well as the real-time monitoring images of the beam field of other debugging learning samples, and calculate the first error accordingly. This process not only considers the directional relationship within a single debugging learning sample (through the calculation of the second directional difference and the first commonality metric value), but also considers the mutual relationship between different debugging learning samples (through the calculation of the third directional difference and the second commonality metric value and the determination of the first error). Through the comprehensive application of commonality metric transformation and error calculation, the performance of the construction safety monitoring network in the classification task can be more accurately evaluated, and strong support can be provided for its subsequent optimization. In the actual application of beam field construction safety quality monitoring, this process is of great significance for improving the recognition accuracy of the network and reducing the false alarm rate and missed alarm rate.
[0179] As an implementation mode, the debugging process of the construction safety monitoring network includes a detail optimization stage, and the network cost value includes a first detail optimization cost value. Based on this, step S30, according to the network cost value, debugs the construction safety monitoring network, which may specifically include:
[0180] Step S32: obtaining the beam field real-time monitoring image and the behavior reference image of each debugging learning example in the Q debugging learning examples, and extracting the image semantic descriptor of the beam field real-time monitoring image and the behavior reference image of each debugging learning example in the Q debugging learning examples based on the construction safety monitoring network after pre-debugging, wherein Q≥1;
[0181] Step S33: for the yth debugging learning sample among the Q debugging learning samples, obtaining A debugging learning samples carrying the same prior mark (that is, the same label) as the yth debugging learning sample from the Q debugging learning samples, where 1≤A≤Q;
[0182] Step S34: according to the safety distance, strengthening the classification interface between the image semantic descriptor of the beam field real-time monitoring image of the yth debugging learning example and the image semantic descriptor of the beam field real-time monitoring image of the A debugging learning examples, and determining the first detail optimization cost value;
[0183] Step S35: Optimize the details of the construction safety monitoring network after pre-debugging according to the first detail optimization cost value.
[0184] In the embodiment of the present application, the debugging process of the construction safety monitoring network is a crucial link. It not only involves the preliminary adjustment of the overall performance of the network (i.e., the pre-debugging stage), but also includes further optimization of specific details, also called fine-tuning, to ensure that the network can accurately identify safety hazards in the construction scene. As an implementation method, the debugging process of the construction safety monitoring network includes a detail optimization stage, in which step S30 specifically describes how to further debug the network based on the network cost value.
[0185] In the detail optimization stage, the computer system first focuses on how to minimize the first detail optimization generation value by adjusting the network parameters and structure. This generation value reflects the clarity and robustness of the network's classification interface when identifying samples with the same prior label (i.e., the same construction behavior or state). By continuously optimizing this generation value, the performance of the construction safety monitoring network can be further improved.
[0186] In step S32, the computer system obtains Q debugging learning samples from the pre-prepared data set. These samples include real-time monitoring images of the beam field and behavioral reference images, which together constitute the basic data for network debugging. Similar to the pre-debugging stage, these image data are processed through the construction safety monitoring network to extract image semantic descriptors. These descriptors are high-dimensional vectors that can capture key feature information in the image, such as shape, texture, color distribution, etc., providing an important basis for subsequent classification and recognition tasks. Assume that Q=10, that is, the system obtains 10 debugging learning samples. For each sample, the image semantic descriptors of its real-time monitoring image of the beam field and the behavioral reference image are extracted respectively. These descriptors will be used as input data for subsequent steps to calculate the classification interface and optimize the cost value.
[0187] In step S33, for each of the Q debugging learning samples (denoted as the yth sample, where 1≤y≤Q), the computer system selects A debugging learning samples with the same prior label from the remaining samples. The prior label is usually manually annotated by experts based on the image content, and it represents the construction behavior or state shown in the image. By selecting samples with the same prior label, it is possible to focus more on optimizing the performance of the network in identifying specific construction behaviors or states.
[0188] Assume that in the yth debugging learning example, the worker is performing steel bar tying and wearing a safety helmet and protective glasses. The system will select all the examples that also show steel bar tying and the worker wearing a safety helmet and protective glasses from the remaining 9 examples, and the number of these examples is recorded as A (where 1≤A≤9).
[0189] In step S34, the computer system strengthens the classification interface between the image semantic descriptor of the beam field real-time monitoring image of the yth debugging learning example and the image semantic descriptor of the beam field real-time monitoring image of the selected A debugging learning examples with the same prior label according to the preset safety distance (such as the angular separation margin Δθ). The purpose of this process is to ensure that different construction behaviors or states maintain a sufficient distance in the feature space, thereby enhancing the clarity and robustness of the classification interface.
[0190] Specifically, the angle between the image semantic descriptor of the y-th debugging learning sample (such as vector (A_1)) and the image semantic descriptors of A samples with the same prior label (such as vectors (A_2), (A_3), (A_4)) is first calculated, and the bounds of these angles are reconstructed according to the safety distance (such as by adding the angle separation margin Δθ). Then, a cost function value is calculated based on the reconstructed angle, which reflects the degree of optimization of the current classification interface. Finally, the above process is repeated for all Q debugging learning samples, and the sum or weighted average of all cost function values is taken as the first detail optimization cost value. Continuing with the y-th debugging learning sample as an example, the angle between vector (A_1) and vectors (A_2), (A_3), (A_4) is first calculated, and the bounds of these angles are reconstructed according to the safety distance Δθ. Then, a cost function value is calculated based on the reconstructed angle (the specific calculation formula may involve multiple factors such as cosine similarity, exponential operation, weight distribution, etc.). Finally, this process is repeated for all 10 debugging learning examples, and the sum of all cost function values is taken as the first detail optimization cost value.
[0191] It should be noted that the cost function design here may vary depending on the specific application scenario and requirements. In practical applications, a more complex cost function form can be used to more accurately evaluate the degree of optimization of the classification interface. For example, the cost function may not only consider the change in the angle but also the relative position relationship between different samples, the weight distribution of samples, and other factors.
[0192] In step S35, the computer system optimizes the details of the pre-debugging construction safety monitoring network according to the first detail optimization cost value. This process usually involves adjusting the parameters of the network (such as weights and biases), changing the network structure (such as increasing or decreasing the number of layers, changing the activation function, etc.), or using more advanced optimization algorithms (such as Adam, RMSprop, etc.). By continuously iterating and optimizing this process until the first detail optimization cost value is reduced to a certain level and remains relatively stable, the performance of the construction safety monitoring network can be gradually improved.
[0193] Specifically, in each iteration, the network parameters and structure are adjusted according to the current first-detail optimization cost. Then the cost is recalculated to evaluate the effect of the adjustment. If the cost decreases, it means that the adjustment direction is correct and needs to be optimized; if the cost increases, it means that the adjustment direction may be wrong and other adjustment strategies need to be tried. Through continuous trial and error and adjustment, the system can gradually find the optimal network parameters and structural configuration to achieve the best performance.
[0194] It should be noted that the detailed optimization stage may be a time-consuming and complex process that requires the computer system to have strong computing power and efficient optimization algorithm support. At the same time, domain experts are also required to provide appropriate prior knowledge and guidance based on specific application scenarios and requirements to ensure the smooth progress of the optimization process and the reliability of the final results.
[0195] It can be seen from the description of the implementation method of step S30 that the debugging process of the construction safety monitoring network is a task involving multiple steps and complex calculations. Among them, the detail optimization stage, as an important part of the debugging process, plays a key role in improving network performance. Through a series of steps such as obtaining debugging learning samples, extracting image semantic descriptors, selecting samples with the same priori labels, strengthening the classification interface and determining the optimization cost, and optimizing the details according to the cost, the computer system can gradually adjust and optimize the parameters and structure of the construction safety monitoring network to achieve more accurate identification of construction safety hazards. This process not only relies on advanced machine learning algorithms and neural network models, but also requires the guidance and support of field experts to ensure the reliability and practicality of the final results. In the actual application of beam field construction safety quality monitoring, this process is of great significance for improving construction safety, reducing accident risks and protecting the lives and property of workers.
[0196] As an implementation mode, step S34, based on the safety distance, strengthens the classification interface between the image semantic descriptor of the beam field real-time monitoring image of the yth debugging learning example and the image semantic descriptor of the beam field real-time monitoring image of the A debugging learning examples, and determines the first detail optimization cost value, which may specifically include:
[0197] Step S341: for the Ath debugging learning sample among the A debugging learning samples, determining the fifth direction difference between the image semantic descriptor of the beam field real-time monitoring image of the yth debugging learning sample and the image semantic descriptor of the beam field real-time monitoring image of the Ath debugging learning sample, where 1≤a≤A;
[0198] Step S342: performing boundary reconstruction on the fifth direction difference according to the angular separation margin, and obtaining a sixth direction difference between the image semantic descriptor of the beam field real-time monitoring image of the yth debugging learning example and the image semantic descriptor of the beam field real-time monitoring image of the Ath debugging learning example;
[0199] Step S343: determining a first detail optimization cost value according to the sixth direction difference corresponding to each debugging learning example in the Q debugging learning examples.
[0200] In step S34, the computer system first focuses on how to strengthen the classification interface between the yth debugging learning sample (referred to as sample Y) and the other A debugging learning samples (referred to as sample set A, where the sample number is a, 1≤a≤A) with the same prior label (i.e., the same construction behavior or state). The purpose of this process is to ensure that samples of different construction behaviors or states can maintain a sufficient distance in the feature space to facilitate accurate classification judgment by the construction safety monitoring network. In step S341, the computer system calculates the direction difference between each debugging learning sample (i.e., the Ath debugging learning sample) in the sample set A and the image semantic descriptor of the beam field real-time monitoring image of sample Y, which is referred to as the fifth direction difference (referred to as θ_Ya). This direction difference reflects the relative position relationship between the two samples in the feature space and is the basis for subsequent boundary reconstruction.
[0201] Specifically, the image semantic descriptors of the beam field real-time monitoring images of sample Y and sample a are first extracted and recorded as vector (F_Y) and vector (F_a), respectively. Then, the angle between the two vectors is calculated as the fifth direction difference θ_Ya. This calculation process usually involves the application of cosine similarity, that is, the vector dot product is first calculated and then divided by the vector modulus length product, and finally the angle value is obtained by inverse cosine transformation.
[0202] In step S342, the computer system reconstructs the boundaries of the fifth direction difference θ_Ya calculated in step S341 according to the preset angular separation margin (denoted as Δθ). The purpose of this process is to add an additional angular interval on the basis of the original direction difference to ensure that samples of different construction behaviors or states maintain a sufficient distance in the feature space, thereby enhancing the clarity and robustness of the classification interface.
[0203] Specifically, the angular separation margin Δθ is added to the fifth direction difference θ_Ya to obtain a new angle value, ie, the sixth direction difference θ′_Ya.
[0204] In step S343, the computer system determines the first detail optimization generation value according to the sixth direction difference corresponding to each debugging learning sample in the Q debugging learning samples (i.e., the set of all θ'_Ya). This generation value reflects the degree of optimization of the classification interface by the construction safety monitoring network in the current debugging stage, and is an important basis for subsequent network parameter and structure adjustments.
[0205] Specifically, it is necessary to design a suitable cost function to calculate the cost value. This cost function should be able to reflect the relationship between the sixth direction difference and the clarity of the classification interface: when the sixth direction difference is large (indicating that the classification interface is clear), the cost value should be small; when the sixth direction difference is small (indicating that the classification interface is fuzzy), the cost value should be large. However, since step S343 involves the comparison of direction differences between multiple debugging learning samples and the comprehensive calculation of the optimization cost value, the design of the cost function may be relatively complex. In practical applications, a cost function based on distance measurement (such as a variant of Triplet Loss), a cost function based on angle difference, or a custom composite cost function can be used. These functions usually take into account multiple factors such as the relative position relationship between different samples, the weight distribution of samples, the sensitivity and stability of the cost function, etc.
[0206] In order to simplify the description and maintain consistency with the previous steps, a simple cost function form based on the average sixth direction difference can be assumed. Specifically, the average (or weighted average) of all sixth direction differences is first calculated, and then the cost value is determined based on the comparison between this average and a preset threshold. However, it should be noted that this simplified form may not fully reflect the complexity and diversity of the actual debugging process. In practical applications, a more complex cost function form can be used to more accurately evaluate the degree of optimization of the classification interface. For example, the cost function can consider factors such as the relative differences between different sixth direction differences, the similarities and differences between different debugging learning examples, and the specific impact of these differences on network performance. By continuously optimizing the cost function and debugging strategy, the parameters and structure of the construction safety monitoring network can be gradually adjusted to improve its accuracy and robustness in identifying construction safety hazards.
[0207] It can be seen from the description of the implementation method of step S34 above that in the embodiment of the present application, the computer system calculates and debugs the directional difference between the learning samples, reconstructs the boundaries to strengthen the classification interface, and finally determines the first detail optimization cost value. This process not only involves key technical points such as the extraction and comparison of image semantic descriptors, the calculation of directional differences and boundary reconstruction, but also requires the design of a suitable cost function to evaluate the degree of optimization of the classification interface. By continuously iterating and optimizing this process, the performance of the construction safety monitoring network can be gradually improved, providing more reliable technical support for safety monitoring at construction sites.
[0208] As an implementation manner, step S343, determining the first detail optimization cost value according to the sixth direction difference corresponding to each debugging learning example in the Q debugging learning examples, may specifically include:
[0209] Step S3431: for the yth debugging learning sample, determining the seventh direction difference between the image semantic descriptor of the beam yard real-time monitoring image of the yth debugging learning sample and the image semantic descriptor of the beam yard real-time monitoring image of each debugging learning sample in Q-1 debugging learning samples, where the Q-1 debugging learning samples are debugging learning samples other than the yth debugging learning sample in the Q debugging learning samples;
[0210] Step S3432: determining the detail optimization error corresponding to the yth debugging learning example according to the sixth direction difference between the image semantic descriptor of the beam field real-time monitoring image of the yth debugging learning example and the image semantic descriptor of the beam field real-time monitoring image of the Ath debugging learning example, and the seventh direction difference corresponding to the yth debugging learning example;
[0211] Step S3433: Determine a first detail optimization cost value according to the detail optimization error corresponding to each debugging learning example in the Q debugging learning examples.
[0212] In step S343, the computer system determines the first detail optimization generation value based on the sixth direction difference corresponding to each of the Q debugging learning samples (these direction differences have been obtained through boundary reconstruction in step S342). This generation value reflects the degree of optimization of the classification interface by the construction safety monitoring network in the detail optimization stage, and is an important basis for subsequent network adjustments.
[0213] In step S3431, the computer system calculates the direction difference between the image semantic descriptors of the real-time monitoring images of the beam field of the yth debugging learning sample (denoted as sample Y) and Q-1 other debugging learning samples (i.e., all samples except sample Y), which is referred to as the seventh direction difference (denoted as θ_Yq, where q represents the number of the debugging learning sample except Y, 1≤q≤Q-1).
[0214] Specifically, firstly, the image semantic descriptors of the beam field real-time monitoring images of sample Y and sample q are extracted and recorded as vector (F_Y) and vector (F_q) respectively. Then, the angle between the two vectors is calculated as the seventh direction difference θ_Yq. This calculation process is similar to the process of calculating the fifth direction difference in step S341, and also involves the application of cosine similarity and inverse cosine transform.
[0215] It should be noted that although the seventh direction difference θ_Yq is similar to the fifth and sixth direction differences mentioned above in terms of calculation, their uses and focuses are different. The fifth direction difference is used to compare the similarity between samples with the same prior label (in step S341), and the sixth direction difference considers the strengthening effect of the angular separation margin on the classification interface (in step S342). The seventh direction difference more broadly compares the similarity between sample Y and all other samples, providing more comprehensive information for the subsequent detail optimization error calculation.
[0216] In step S3432, the computer system determines the detail optimization error corresponding to sample Y based on the sixth direction difference θ'_Ya (note that this is the direction difference after boundary reconstruction) between the image semantic descriptor of the real-time monitoring image of the beam field of the y-th debugging learning sample (sample Y) and the image semantic descriptor of the real-time monitoring image of the beam field of the A-th debugging learning sample (sample A, where a∈{1,2,...,A}, and A≤Q-1, representing the number of samples with the same prior label as sample Y), and all seventh direction differences θ_Yq (q≠Y) corresponding to sample Y.
[0217] The calculation of detail optimization error usually involves comprehensive consideration of multiple factors, such as the difference between the sixth direction difference and the seventh direction difference, the relative relationship between different direction differences, the weight distribution of samples, etc. However, in order to simplify the description and maintain consistency with the previous steps, a simple error calculation method based on the difference in direction differences can be assumed. Specifically, a certain difference metric (such as absolute value difference, square difference, etc.) between the sixth direction difference and all seventh direction differences can be calculated, and this difference metric can be used as part of the detail optimization error.
[0218] However, it should be noted that in practical applications, the calculation of detail optimization errors may be more complex and sophisticated. The system can adopt the form of error functions based on distance metrics (such as variants of Triplet Loss), error functions based on angle differences, or custom composite error functions. These functions usually take into account multiple factors such as the relative position relationship between different samples, the prior labels of samples, the sensitivity of the network to the classification interface, and stability requirements.
[0219] In step S3433, the computer system determines the first detail optimization generation value according to the detail optimization errors corresponding to each of the Q debugging learning samples (these errors have been calculated in step S3432). This generation value comprehensively reflects the overall optimization degree of the classification interface of the construction safety monitoring network in the detail optimization stage.
[0220] Specifically, a weighted summation method can be used to calculate the cost value. The detailed optimization error corresponding to each debugging learning example will be assigned a certain weight (these weights may be assigned based on factors such as the importance, difficulty, and reliability of the example), and then the total cost value is summed up. In addition, some regularization terms or penalty terms may be introduced to further adjust the cost value to ensure that the network can pay more attention to those difficult-to-distinguish samples or those samples that have a greater impact on the classification interface during training.
[0221] The final first detail optimization cost value will be used as one of the important reference indicators in the subsequent network debugging process. By continuously iterating and optimizing this cost value, the parameters and structure of the construction safety monitoring network can be gradually adjusted to improve its accuracy and robustness in identifying construction safety hazards.
[0222] It can be seen from the description of the implementation method of step S343 above that in the embodiment of the present application, the computer system guides the further optimization of the network by calculating the directional difference (including the sixth directional difference and the seventh directional difference) between the debugging learning samples, determining the detail optimization error and finally calculating the first detail optimization cost value. This process not only involves key technical points such as the extraction and comparison of image semantic descriptors, the calculation of directional differences and boundary reconstruction, but also needs to consider the comprehensive influence of various factors to design a suitable error calculation method and cost evaluation method. Through continuous iterative optimization of this process, the system can gradually improve the performance of the construction safety monitoring network and provide more reliable technical support for safety monitoring of construction sites. In actual applications, the system can appropriately adjust and expand the various sub-steps in step S343 according to specific scenarios and needs to adapt to different debugging and optimization needs.
[0223] As an implementation mode, step S31, pre-debugging the construction safety monitoring network according to the first pre-debugging cost value, may specifically include:
[0224] Step S311: extracting image block semantic descriptors of beam yard real-time monitoring images and image block semantic descriptors of behavior reference images of each debugging learning example in P debugging learning examples based on the construction safety monitoring network;
[0225] Step S312: performing optimal manifold distance calculation based on the image block semantic descriptors of the beam yard real-time monitoring image of each debugging learning example in the P debugging learning examples and the image block semantic descriptors of the behavior reference image to determine the second pre-debugging cost value of the construction safety monitoring network;
[0226] Step S313: Pre-debugging the construction safety monitoring network according to the first pre-debugging cost value and the second pre-debugging cost value.
[0227] In the pre-debugging stage, the main goal of the computer system is to minimize the first pre-debugging cost value by adjusting the parameters and structure of the construction safety monitoring network. This cost value reflects the degree of optimization of the classification interface during the initial debugging process and is an important reference indicator for subsequent network optimization. In order to further improve network performance, a second pre-debugging cost value will be introduced. This cost value is calculated based on the optimal manifold distance of the image block semantic descriptor, which can more comprehensively evaluate the network's feature extraction and classification capabilities.
[0228] In step S311, the computer system first uses the construction safety monitoring network to extract features from each of the P debugging learning samples. Unlike the previous extraction of semantic descriptors for the entire image, this step focuses on extracting semantic descriptors for image blocks. Image blocks are local areas in an image and usually contain more detailed and specific feature information. By extracting semantic descriptors for image blocks, we can understand the image content more deeply and provide stronger support for subsequent classification and recognition tasks.
[0229] Specifically, the beam field real-time monitoring image and behavior reference image in each debugging learning example are divided into multiple image blocks (such as blocks of 32x32 pixels, 64x64 pixels, etc.), and features are extracted for each image block. These features may include various types of descriptors such as shape, texture, color, etc., which together constitute the semantic descriptor vector of the image block. These vectors will serve as the basic data for subsequent optimal manifold distance calculations. Assume that P=10, that is, the system has 10 debugging learning examples. For each example, the semantic descriptors of all image blocks in its beam field real-time monitoring image and behavior reference image are extracted respectively. Taking one of the examples as an example, assume that its real-time monitoring image is divided into 100 image blocks (referred to as block set M), and the behavior reference image is divided into 100 image blocks (referred to as block set R). The system will extract a high-dimensional vector as a semantic descriptor for each image block, such as vectors (F_{M1}), (F_{M2}), ..., (F_{M100}) represent the semantic descriptors of each image block in the block set M, and vectors (F_{R1}), (F_{R2}), ..., (F_{R100}) represent the semantic descriptors of each image block in the block set R.
[0230] In step S312, the computer system performs optimal manifold distance calculation (i.e., optimal transmission processing) based on the image block semantic descriptors extracted in step S311. The optimal manifold distance is a measure of the similarity or difference between two distributions (or two sets of image blocks), which can take into account the geometric structure and topological relationship of the data in the manifold space. By calculating the optimal manifold distance of the image blocks between the real-time monitoring image of the beam field and the behavior reference image, the performance of the construction safety monitoring network in feature extraction and classification tasks can be more accurately evaluated.
[0231] Specifically, a method based on optimal transmission theory can be used to calculate the optimal manifold distance. Optimal transmission theory is a mathematical tool used to study how to map one distribution (or a set of data points) to another distribution (or another set of data points) while minimizing a certain cost function (such as transmission cost). In this scenario, the image block set M in the real-time monitoring image of the beam field can be regarded as the source distribution, the image block set R in the behavioral reference image can be regarded as the target distribution, and the optimal transmission plan from M to R and its corresponding transmission cost can be calculated. This transmission cost reflects the optimal manifold distance between the two image block sets.
[0232] However, it should be noted that directly calculating the optimal manifold distance between two sets of high-dimensional vectors may be computationally infeasible or very time-consuming. Therefore, in practical applications, the system can use some approximate methods or simplification strategies to reduce the computational complexity. For example, the system can project the high-dimensional vector into a low-dimensional manifold space for calculation or use a sample-based approximation method to estimate the optimal manifold distance. Regardless of the method used to calculate the optimal manifold distance, the system will eventually obtain a numerical result as the second pre-debugging generation value. This generation value reflects the ability of the construction safety monitoring network to evaluate the similarity or difference of image blocks in feature extraction and classification tasks. By minimizing this generation value, the system can further improve the performance of the network.
[0233] Continuing with the example of the scene in the beam yard construction, assume that the system has extracted the semantic descriptors of all image blocks in the real-time monitoring image and the behavior reference image. Now the system needs to calculate the optimal manifold distance between the two sets of image blocks. Assume that the system uses an approximate method based on optimal transmission theory to calculate this distance, and measures the transmission cost through a certain cost function (such as the sum of the squares of the Euclidean distance). Through the calculation system, a specific numerical result is obtained as the second pre-debugging cost value. This cost value reflects the performance of the network in evaluating the similarity or difference of image blocks, and will serve as an important basis for subsequent network debugging.
[0234] In step S313, the computer system performs pre-debugging on the construction safety monitoring network according to the first pre-debugging cost value and the second pre-debugging cost value. This process usually involves adjusting the parameters of the network (such as weights and biases), changing the network structure (such as increasing or decreasing the number of layers, changing the activation function, etc.) or adopting more advanced optimization algorithms (such as Adam, RMSprop, etc.). By continuously iteratively optimizing the two cost values until they are reduced to a certain extent and remain relatively stable, the system can gradually improve the performance of the construction safety monitoring network. Specifically, in each iteration, the system will evaluate the performance of the network based on the current first pre-debugging cost value and the second pre-debugging cost value, and adjust the parameters and structure of the network accordingly. Then recalculate the cost value to evaluate the adjustment effect. If the cost value decreases, it means that the adjustment direction is correct and needs to be optimized; if the cost value increases, it means that the adjustment direction may be wrong and other adjustment strategies need to be tried. Through continuous trial and error and adjustment, the system can gradually find the optimal network parameters and structural configuration to achieve the best performance. It should be noted that in actual applications, the pre-debugging stage may be a time-consuming and complex process that requires the computer system to have strong computing power and efficient optimization algorithm support. At the same time, domain experts are also required to provide appropriate prior knowledge and guidance based on specific application scenarios and requirements to ensure the smooth progress of the optimization process and the reliability of the final results.
[0235] Through the description of the implementation method of the above step S31, it can be seen that in the embodiment of the present application, the computer system gradually optimizes the performance of the construction safety monitoring network by a series of steps such as extracting the image block semantic descriptor, calculating the optimal manifold distance and determining the second pre-debugging cost value, and performing pre-debugging based on the cost value. This process not only involves key technical points such as the extraction and comparison of image block semantic descriptors and the calculation of the optimal manifold distance, but also requires the guidance and support of field experts and the application of efficient optimization algorithms. By continuously iterating and optimizing this process, the system can gradually improve the recognition accuracy and robustness of the construction safety monitoring network to provide more reliable technical guarantees for safety monitoring at the construction site.
[0236] As an implementation mode, step S312, performing optimal manifold distance calculation based on the image block semantic descriptor of the beam yard real-time monitoring image of each debugging learning example in the P debugging learning examples and the image block semantic descriptor of the behavior reference image, and determining the second pre-debugging cost value of the construction safety monitoring network, may specifically include:
[0237] Step S3121: for the x-th debugging learning sample among the P debugging learning samples, determining a first optimal allocation cost between an image block semantic descriptor of a behavior reference image of the x-th debugging learning sample and an image block semantic descriptor of a beam field real-time monitoring image, and a second optimal allocation cost between an image block semantic descriptor of a beam field real-time monitoring image of the x-th debugging learning sample and an image block semantic descriptor of a behavior reference image;
[0238] Step S3122: determining a third optimal allocation cost between an image block semantic descriptor of a behavior reference image of the x-th debugging learning sample and an image block semantic descriptor of a beam field real-time monitoring image of each debugging learning sample in O debugging learning samples, and determining a fourth optimal allocation cost between an image block semantic descriptor of the beam field real-time monitoring image of the x-th debugging learning sample and an image block semantic descriptor of a behavior reference image of each debugging learning sample in O debugging learning samples, where the O debugging learning samples are debugging learning samples other than the x-th debugging learning sample among the P debugging learning samples;
[0239] Step S3123: Determine the second pre-debugging cost value according to the first optimal allocation cost, the second optimal allocation cost, the third optimal allocation cost and the fourth optimal allocation cost corresponding to each debugging learning example in the P debugging learning examples.
[0240] In step S312, the computer system calculates the optimal allocation cost (i.e., the minimum transmission cost) of the image block semantic descriptor between the behavior reference image and the real-time monitoring image for each of the P debugging learning samples (denoted as the xth sample, where 1≤x≤P). Then, this calculation process is further extended to consider the mutual comparison of the image block semantic descriptors between the xth sample and the other O samples (O=P-1, i.e., all samples except the xth sample). Finally, the optimal allocation cost of all samples is combined to determine the second pre-debugging cost value.
[0241] In step S3121, the computer system calculates the first optimal allocation cost between the image block semantic descriptor of the behavior reference image and the image block semantic descriptor of the beam field real-time monitoring image, and the second optimal allocation cost between the image block semantic descriptor of the real-time monitoring image and the image block semantic descriptor of the behavior reference image for the x-th debugging learning example. The optimal allocation cost is a metric based on the optimal transfer theory, which measures the minimum cost required to map a distribution (or a set of data points) to another distribution (or another set of data points). In this scenario, the distribution is composed of semantic descriptors of image blocks, and the cost function can be any metric that can reflect the similarity or difference between descriptors (such as Euclidean distance, Manhattan distance, etc.).
[0242] Specifically, an iterative optimization algorithm (such as Sinkhorn algorithm, Earth Mover's Distance algorithm, etc.) can be used to calculate the optimal allocation cost. These algorithms minimize the transmission cost by continuously adjusting the mapping scheme until the convergence condition is reached.
[0243] Assume that the behavior reference image of the x-th debugging learning example contains M image blocks (denoted as block set R), and the real-time monitoring image contains N image blocks (denoted as block set M). The system first extracts semantic descriptor vectors for each image block (such as (F_{R1}), (F_{R2}), ..., (F_{RM}) represent the image block semantic descriptor vectors of the behavior reference image; (F_{M1}), (F_{M2}), ..., (F_{MN}) represent the image block semantic descriptor vectors of the real-time monitoring image). Then, the minimum transmission cost from block set R to block set M is calculated as the first optimal allocation cost (denoted as (C_{RM})), and the minimum transmission cost from block set M to block set R is calculated as the second optimal allocation cost (denoted as (C_{MR})).
[0244] It should be noted that since the optimal transmission problem is usually an asymmetric problem (i.e., the minimum transmission cost from distribution A to distribution B is not necessarily equal to the minimum transmission cost from distribution B to distribution A), the system needs to calculate the first and second optimal allocation costs separately.
[0245] In step S3122, the computer system further expands the calculation process to consider the comparison between the image block semantic descriptors of the x-th debugging learning sample and the other O debugging learning samples. Specifically, the third optimal allocation cost (recorded as set ({C_{RxM_y}}), where y represents the number of other samples) between the image block semantic descriptors of the behavior reference image of the x-th sample and the image block semantic descriptors of the real-time monitoring images of the O samples, and the fourth optimal allocation cost (recorded as set ({C_{MxR_y}}) between the image block semantic descriptors of the real-time monitoring images of the x-th sample and the image block semantic descriptors of the behavior reference images of the O samples are calculated.
[0246] The purpose of this step is to evaluate the uniqueness and difference of the xth sample when compared with other samples. By calculating the optimal allocation cost between different samples, we can have a more comprehensive understanding of the performance of the construction safety monitoring network in feature extraction and classification tasks, and discover possible problems and deficiencies.
[0247] It should be noted that since this step involves a large amount of computation (it is necessary to calculate pairwise comparisons between P samples), some approximate methods or simplification strategies may be needed to reduce the computational complexity in practical applications. For example, a portion of samples can be randomly selected for calculation, or a sample-based approximate method can be used to estimate the optimal allocation cost.
[0248] In step S3123, the computer system determines the second pre-debugging generation value according to the first optimal allocation cost, the second optimal allocation cost, the third optimal allocation cost and the fourth optimal allocation cost corresponding to each of the P debugging learning samples. This generation value comprehensively reflects the overall performance of the construction safety monitoring network in feature extraction and classification tasks.
[0249] Specifically, a weighted summation method can be used to calculate the cost. Each optimal allocation cost will be assigned a certain weight (these weights may be assigned based on factors such as the importance, difficulty, and reliability of the sample), and then the total cost is summed up. In addition, some regularization terms or penalty terms may be introduced to further adjust the cost to ensure that the network can pay more attention to those samples that are difficult to distinguish or those that have a greater impact on the classification interface during training.
[0250] The final second pre-debugging generation value will serve as one of the important reference indicators for the subsequent network debugging process. By continuously iterating and optimizing this generation value, the parameters and structure of the construction safety monitoring network can be gradually adjusted to improve its accuracy and robustness in identifying construction safety hazards.
[0251] It can be seen from the description of the implementation method of the above step S312 that in the embodiment of the present application, the computer system evaluates the performance of the construction safety monitoring network in the feature extraction and classification tasks by calculating the optimal manifold distance (i.e., the optimal transmission cost). This process not only takes into account the relationship between the behavioral reference image and the real-time monitoring image within a single debugging learning sample (by calculating the first and second optimal allocation costs), but also extends to the mutual comparison of image block semantic descriptors between different debugging learning samples (by calculating the third and fourth optimal allocation costs). The final second pre-debugging cost value comprehensively reflects the overall performance of the network and provides an important reference for subsequent network debugging. In practical applications, it may be necessary to adopt some approximate methods or simplified strategies to reduce the computational complexity and ensure the smooth progress of the optimization process and the reliability of the final results. By continuously iterating and optimizing this process, the recognition accuracy and robustness of the construction safety monitoring network can be gradually improved, providing a more reliable technical guarantee for safety monitoring at the construction site.
[0252] As an implementation mode, step S35, according to the first detail optimization cost value, performs detail optimization on the construction safety monitoring network after pre-commissioning, which may specifically include:
[0253] Step S351: extracting image block semantic descriptors of beam yard real-time monitoring images of each debugging learning example in Q debugging learning examples based on the construction safety monitoring network after pre-debugging;
[0254] Step S352: performing optimal manifold distance calculation based on the image block semantic descriptor of the beam yard real-time monitoring image of each debugging learning example in the Q debugging learning examples to determine the second detail optimization cost value of the construction safety monitoring network;
[0255] Step S353: Optimize the details of the construction safety monitoring network after pre-debugging according to the first detail optimization cost value and the second detail optimization cost value.
[0256] In step S35, the computer system first uses the pre-debugging construction safety monitoring network to extract the image block semantic descriptors of the beam yard real-time monitoring images in the Q debugging learning samples. Then, the second detail optimization cost value is determined by calculating the optimal manifold distance between these image block semantic descriptors. Finally, the network is optimized in detail by combining the first detail optimization cost value and the second detail optimization cost value to improve its recognition accuracy and robustness.
[0257] In step S351, the computer system extracts features at the image block level for each of the Q debugging learning samples based on the construction safety monitoring network after pre-debugging. Similar to step S311, this step focuses on dividing multiple image blocks from the real-time monitoring image of the beam yard and extracting semantic descriptors for each image block. These image block semantic descriptors contain local feature information of the image blocks, such as shape, texture, color, etc., which are the basis for subsequent optimal manifold distance calculation.
[0258] Assume that Q=10, that is, the system has 10 debugging learning samples. For each sample, its real-time monitoring image of the beam field will be divided into multiple image blocks (such as blocks of 32x32 pixels, 64x64 pixels, etc.), and the feature extraction layer in the construction safety monitoring network will be used to extract features from each image block. These features may be processed by multiple layers such as convolutional layers, pooling layers, and activation functions, and finally form a high-dimensional vector as the semantic descriptor of the image block. Taking one of the samples as an example, assuming that its real-time monitoring image is divided into 100 image blocks, the system will extract 100 high-dimensional vectors as the image block semantic descriptor set of the sample.
[0259] In step S352, the computer system uses the image block semantic descriptor extracted in step S351 to calculate the best manifold distance. The best manifold distance is a measure of the similarity or difference between two distributions (or two sets of image blocks), which can take into account the geometric structure and topological relationship of the data in the manifold space. By calculating the best manifold distance of the image block semantic descriptor between different debugging learning samples, the performance of the construction safety monitoring network in detail feature extraction and classification tasks can be evaluated.
[0260] Similar to step S312, a method based on optimal transfer theory can be used to calculate the optimal manifold distance. However, in step S352, the calculation focuses more on the comparison between different debugging learning samples to find the network's shortcomings in identifying subtle differences. Specifically, the image block semantic description subset set of each debugging learning sample can be regarded as a distribution, and the optimal transfer cost between these distributions is calculated as the optimal manifold distance.
[0261] To simplify the explanation, we can assume that the system uses a simplified optimal transmission cost calculation method. This method first defines a cost matrix C, where C[i,j] represents the cost required to transfer the jth image block semantic descriptor of the i-th sample to a certain image block semantic descriptor of another sample (this cost can be Euclidean distance, Manhattan distance or any other suitable metric). Then, we solve a linear programming problem to find the optimal transmission plan π, which minimizes the sum of transmission costs:
[0262] ;
[0263] Among them, π[i,j,k,l] represents the quality of the transfer from the jth image block semantic descriptor of the ith sample to the lth image block semantic descriptor of the kth sample. Finally, the sum of the optimal transmission costs is the second detail optimization cost, which reflects the performance of the construction safety monitoring network in detail feature extraction and classification tasks. It should be noted that since directly calculating the optimal manifold distance of the image block semantic descriptors between all debugging learning samples may be computationally infeasible or very time-consuming, in practical applications, the system can use some approximate methods or simplification strategies to reduce the computational complexity. For example, a portion of the image blocks can be randomly selected for calculation, or a sample-based approximation method can be used to estimate the optimal manifold distance.
[0264] In step S353, the computer system performs detail optimization on the pre-debugging construction safety monitoring network based on the first detail optimization cost value and the second detail optimization cost value. This process usually involves adjusting the parameters of the network (such as weights and biases), changing the network structure (such as increasing or decreasing the number of layers, changing the activation function, etc.), or using more advanced optimization algorithms (such as Adam, RMSprop, etc.). By continuously iteratively optimizing the two cost values until they are reduced to a certain level and remain relatively stable, the performance of the construction safety monitoring network can be gradually improved.
[0265] Specifically, in each iteration, the performance of the network is evaluated based on the current first detail optimization cost value and the second detail optimization cost value, and the parameters and structure of the network are adjusted accordingly. The direction and magnitude of the adjustment may be determined based on the gradient descent method, Newton's method or other optimization algorithms. Then, the cost value is recalculated to evaluate the effect of the adjustment. If the cost value decreases, it means that the adjustment direction is correct and needs to be optimized; if the cost value increases, it means that the adjustment direction may be wrong and other adjustment strategies need to be tried. Through continuous trial and error and adjustment, the system can gradually find the optimal network parameters and structural configuration to achieve the best performance. In the process of detail optimization, some additional strategies may be used to speed up the optimization process or improve the optimization effect. For example, the system can use batch normalization to speed up the network training process and reduce the problem of internal covariate shift; or use dropout technology to prevent network overfitting and improve generalization ability; it can also use transfer learning strategy to migrate pre-trained model parameters to the current task to accelerate the convergence process, etc.
[0266] Through the description of the implementation method of the above step S35, it can be seen that in the embodiment of the present application, the computer system further improves the performance of the construction safety monitoring network by a series of steps such as extracting image block semantic descriptors, calculating the optimal manifold distance and determining the second detail optimization cost value, and optimizing the details according to the cost value. This process not only involves key technical points such as the extraction and comparison of image block semantic descriptors and the calculation of the optimal manifold distance, but also requires the guidance and support of field experts and the application of efficient optimization algorithms. Through continuous iteration and optimization of this process, the system can gradually improve the recognition accuracy and robustness of the construction safety monitoring network to provide more reliable technical guarantees for the safety monitoring of the construction site. At the same time, this process also demonstrates the application potential and advantages of machine learning models (especially deep learning models) in complex tasks, which provides a useful reference and reference for research and application in related fields.
[0267] As an implementation manner, step S352, performing optimal manifold distance calculation based on the image block semantic descriptor of the beam yard real-time monitoring image of each debugging learning example in the Q debugging learning examples to determine the second detail optimization cost value of the construction safety monitoring network, may specifically include:
[0268] Step S3521: for the zth debugging learning sample among the A debugging learning samples, determining the fifth optimal allocation cost between the image block semantic descriptor of the beam field real-time monitoring image of the yth debugging learning sample and the image semantic descriptor of the beam field real-time monitoring image of the zth debugging learning sample;
[0269] Step S3522: determining a sixth optimal allocation cost between an image block semantic descriptor of the beam field real-time monitoring image of the y-th debugging learning example and an image block semantic descriptor of the beam field real-time monitoring image of each debugging learning example in Q-1 debugging learning examples, where the Q-1 debugging learning examples are debugging learning examples other than the y-th debugging learning example in the Q debugging learning examples;
[0270] Step S3523: Determine the second detail optimization cost value according to the fifth optimal allocation cost and the sixth optimal allocation cost corresponding to each debugging learning example in the Q debugging learning examples.
[0271] In step S352, the computer system first calculates the optimal allocation cost of the image block semantic descriptor of the beam field real-time monitoring image between each of the Q debugging learning samples (but the yth debugging learning sample is used as an example for detailed description here) and other debugging learning samples. This process is intended to evaluate the detail recognition ability of the construction safety monitoring network in feature extraction and classification tasks from multiple perspectives.
[0272] In step S3521, the computer system calculates the optimal allocation cost between the image block semantic descriptor of the real-time monitoring image of the beam field of the y-th debugging learning sample and the image semantic descriptor of the real-time monitoring image of the beam field of the z-th debugging learning sample for the z-th debugging learning sample among the A debugging learning samples (note that a is a general term here. In fact, during the traversal process, a will be equal to Q, that is, all debugging learning samples are considered; and z is the sample number currently traversed), which is referred to as the fifth optimal allocation cost.
[0273] It should be noted that there may be an inconsistency in the original text because it mentions "image semantic descriptor" rather than "image block semantic descriptor" in step S3521. However, in the detail optimization stage, more attention is paid to feature comparison at the image block level, because image blocks can provide more refined feature information, which helps the network to identify subtle differences in construction scenes. Therefore, when explaining this step, it will be assumed that the "image semantic descriptor" in the original text actually refers to "some aggregation or representation of image block semantic descriptors" (although in actual operation, it is more likely to directly compare image block semantic descriptors).
[0274] To simplify the description, it can be assumed that the real-time monitoring image of the beam field of the yth debugging learning example is divided into M image blocks, each image block corresponds to a semantic descriptor vector (such as (F_{y1}), (F_{y2}), ..., (F_{yM})); similarly, the real-time monitoring image of the beam field of the zth debugging learning example is also divided into N image blocks (although N may be different from M, it is temporarily assumed that N=M for the sake of simplicity), and each image block corresponds to a semantic descriptor vector (such as (F_{z1}), (F_{z2}), ..., (F_{zN})). However, since step S3521 mentions the comparison with the "image semantic descriptor", it is assumed here that all the image block semantic descriptors of the zth example are aggregated into a global "image semantic descriptor" vector (G_z) by some method (such as average pooling, maximum pooling, etc.).
[0275] Then, the optimal allocation cost between each image block semantic descriptor vector of the yth sample and the global "image semantic descriptor" vector of the zth sample is calculated. However, since directly comparing the optimal allocation cost of a single image block with the global vector may be technically complex and meaningless, a simplified method is more likely to be used: for example, the average distance between all corresponding image block semantic descriptors (the distance here can be Euclidean distance, Manhattan distance, etc.) is calculated, and this average value is used as an approximate estimate of the fifth optimal allocation cost. However, in order to follow the description of the original text and maintain consistency, it is still called the "fifth optimal allocation cost", and it is assumed that the system uses an internally defined metric that can reasonably reflect the similarity or difference between two samples to calculate this cost.
[0276] In step S3522, the computer system further expands the calculation scope to determine the optimal allocation cost between the image block semantic descriptor of the beam field real-time monitoring image of the yth debugging learning example and the image block semantic descriptor of the beam field real-time monitoring image of each debugging learning example in the Q-1 debugging learning examples. This is referred to as the sixth optimal allocation cost set because it includes the optimal allocation cost between the yth example and all other examples except itself.
[0277] Different from step S3521, step S3522 no longer compares the image block semantic descriptor of a single sample with the global "image semantic descriptor" of another sample, but directly compares the semantic descriptor vectors of the corresponding image blocks between the two samples. The advantage of this is that it can capture the subtle differences in the construction scene more finely, because each image block contains specific feature information of the local area.
[0278] Specifically, it is still assumed that the real-time monitoring image of the beam field of the y-th debugging learning example is divided into M image blocks (corresponding to semantic descriptor vectors (F_{y1}), (F_{y2}), ..., (F_{yM})), and for each of the Q-1 other debugging learning examples (denoted as the q-th example, where q≠y and 1≤q≤Q), the semantic descriptor vectors of the corresponding number of image blocks in the real-time monitoring image of the beam field are also extracted (although the actual number may be different from M, for the sake of simplicity, it is temporarily assumed that they are all M, and the corresponding image blocks have a certain consistency or correspondence in spatial position).
[0279] Then, the optimal allocation cost between the semantic descriptor vector of each image block of the yth sample and the semantic descriptor vector of the corresponding image block of the qth sample is calculated (the optimal allocation cost here is actually closer to a distance metric or similarity metric, because in actual operation, an optimal transmission plan may not be actually solved to obtain the allocation cost; but in order to maintain consistency with the original text, the expression "optimal allocation cost" is still used). These cost values will form a set as the sixth optimal allocation cost between the yth sample and the qth sample. Finally, all Q-1 sixth optimal allocation costs are combined to form the final sixth optimal allocation cost set.
[0280] It should be noted that in actual operation, it may be computationally infeasible or very time-consuming to calculate the optimal allocation cost between all corresponding image blocks. Therefore, the system can use some approximate methods or simplification strategies to reduce the computational complexity. For example, the system can randomly select a part of the image blocks for calculation or use a sample-based approximate method to estimate the optimal allocation cost between the entire set of image blocks. In step S3523, the computer system determines the second detail optimization generation value based on the fifth optimal allocation cost and the sixth optimal allocation cost corresponding to each sample in the Q debugging learning samples. This generation value comprehensively reflects the overall performance of the construction safety monitoring network in detail feature extraction and classification tasks.
[0281] Specifically, the system can use a weighted summation method to calculate the cost value. Each optimal allocation cost (whether it is a cost value in the fifth optimal allocation cost or the sixth optimal allocation cost set) will be assigned a certain weight (these weights may be assigned based on factors such as the importance, difficulty, and reliability of the sample). The system then sums up all weighted optimal allocation costs to obtain a total cost value as the second detail optimization cost value. In addition, the system may also introduce some regularization terms or penalty terms to further adjust the cost value to ensure that the network can pay more attention to those samples that are difficult to distinguish or those samples that have a greater impact on the classification interface during training. For example, the system can impose additional penalties on samples with larger cost values (indicating lower similarity or greater difference) to promote the network's learning of these samples.
[0282] The final second detail optimization generation value will be used as one of the important reference indicators for subsequent network detail optimization. Through continuous iterative optimization of this generation value system, the parameters and structure of the construction safety monitoring network can be gradually adjusted to improve its accuracy and robustness in identifying construction safety hazards.
[0283] Through the description of the implementation of step S352 above, it can be seen that in the embodiment of the present application, the computer system evaluates the performance of the construction safety monitoring network in detail feature extraction and classification tasks by calculating the optimal manifold distance (specifically, the optimal allocation cost). This process not only involves the extraction and comparison of image block semantic descriptors, but also uses the optimal transmission theory (or its approximate method) to calculate the similarity or difference between different examples. By comprehensively considering the comparison between single sample pairs and a single sample and multiple samples.
[0284] The present application embodiment provides a computer system, such as Figure 3 As shown, the computer system 100 includes: a processor 101 and a memory 103. The processor 101 and the memory 103 are connected, such as through a bus 102. Optionally, the computer system 100 may also include a transceiver 104. It should be noted that in actual applications, the transceiver 104 is not limited to one, and the structure of the computer system 100 does not constitute a limitation on the embodiments of the present application.
[0285] In other words, an embodiment of the present application provides a computer system, and the computer system in the embodiment of the present application includes: one or more processors; a memory; one or more computer programs, wherein the one or more computer programs are stored in the memory and configured to be executed by the one or more processors, and when the one or more programs are executed by the processor, the above method is implemented.
Claims
1. A beam yard construction safety quality monitoring method based on AI recognition, characterized in that: include: Obtain the beam yard monitoring video collected for the target beam yard monitoring area; Acquire a beam yard real-time monitoring image from the beam yard monitoring video; Calling the construction safety monitoring network to perform construction safety detection on the real-time monitoring image of the beam yard, and obtaining the construction safety detection result of the real-time monitoring image of the beam yard; The construction safety monitoring network is debugged based on the following process: Obtaining beam field real-time monitoring images and behavior reference images of each debugging learning example in P debugging learning examples, and extracting image semantic descriptors of beam field real-time monitoring images and behavior reference images of each debugging learning example based on the construction safety monitoring network, P ≥ 1; According to the preset safety distance, the image semantic descriptor of the beam yard real-time monitoring image of each debugging learning sample and the image semantic descriptor of the behavior reference image, the classification interface between the debugging learning samples of different construction behaviors in the P debugging learning samples is strengthened to obtain the network cost value of the construction safety monitoring network; Debugging the construction safety monitoring network according to the network cost value; The debugging process of the construction safety monitoring network includes a pre-debugging stage, and the network cost value includes a first pre-debugging cost value; According to the preset safety distance, and the image semantic descriptors of the beam yard real-time monitoring images and the image semantic descriptors of the behavior reference images of the debugging learning samples, the classification interface between the debugging learning samples of different construction behaviors in the P debugging learning samples is strengthened to obtain the network cost value of the construction safety monitoring network, including: According to the safety distance, the classification interface between the image semantic descriptor of the beam yard real-time monitoring image and the image semantic descriptor of the behavior reference image of each debugging learning example is strengthened to determine the first pre-debugging cost value; The debugging of the construction safety monitoring network according to the network cost value includes: Pre-debugging the construction safety monitoring network according to the first pre-debugging cost; The safety distance includes an angular separation margin, and the classification interface between the image semantic descriptor of the beam field real-time monitoring image and the image semantic descriptor of the behavior reference image of each debugging learning example is strengthened according to the safety distance to determine the first pre-debugging cost value, including: For an x-th debugging learning example among the P debugging learning examples, determining a first direction difference between an image semantic descriptor of a behavior reference image of the x-th debugging learning example and an image semantic descriptor of a beam yard real-time monitoring image, wherein 1≤x≤P; According to the angular separation margin, the first direction difference is boundedly reconstructed to obtain a second direction difference between the image semantic descriptor of the behavior reference image of the x-th debugging learning example and the image semantic descriptor of the beam field real-time monitoring image; Determining the first pre-debugging cost value according to the second direction difference corresponding to each debugging learning example in the P debugging learning examples; The pre-debugging of the construction safety monitoring network according to the first pre-debugging cost value includes: Based on the construction safety monitoring network, extracting image block semantic descriptors of beam yard real-time monitoring images and image block semantic descriptors of behavior reference images of each debugging learning example in the P debugging learning examples; Performing optimal manifold distance calculation based on image block semantic descriptors of beam yard real-time monitoring images and image block semantic descriptors of behavior reference images of each debugging learning example in the P debugging learning examples, and determining a second pre-debugging cost value of the construction safety monitoring network; Pre-debugging the construction safety monitoring network according to the first pre-debugging cost value and the second pre-debugging cost value; The method of performing optimal manifold distance calculation based on the image block semantic descriptor of the beam yard real-time monitoring image of each debugging learning example in the P debugging learning examples and the image block semantic descriptor of the behavior reference image to determine the second pre-debugging cost value of the construction safety monitoring network includes: For an x-th debugging learning sample among the P debugging learning samples, determining a first optimal allocation cost between an image block semantic descriptor of a behavior reference image of the x-th debugging learning sample and an image block semantic descriptor of a beam field real-time monitoring image, and a second optimal allocation cost between an image block semantic descriptor of the beam field real-time monitoring image of the x-th debugging learning sample and an image block semantic descriptor of a behavior reference image; Determine a third optimal allocation cost between an image block semantic descriptor of a behavior reference image of the x-th debugging learning sample and an image block semantic descriptor of a beam field real-time monitoring image of each debugging learning sample in O debugging learning samples, and determine a fourth optimal allocation cost between an image block semantic descriptor of the beam field real-time monitoring image of the x-th debugging learning sample and an image block semantic descriptor of a behavior reference image of each debugging learning sample in O debugging learning samples, wherein the O debugging learning samples are debugging learning samples other than the x-th debugging learning sample among the P debugging learning samples; Determine the second pre-debugging cost value according to the first optimal allocation cost, the second optimal allocation cost, the third optimal allocation cost and the fourth optimal allocation cost corresponding to each debugging learning sample in the P debugging learning samples; The determining of the first direction difference between the image semantic descriptor of the behavior reference image of the x-th debugging learning example and the image semantic descriptor of the beam field real-time monitoring image comprises: Determine a first direction difference between an image semantic descriptor of the behavior reference image of the x-th debugging learning example and an image semantic descriptor of the beam field real-time monitoring image, and a first direction difference between an image semantic descriptor of the beam field real-time monitoring image and an image semantic descriptor of the behavior reference image; The step of performing boundary reconstruction on the first direction difference according to the angular separation margin to obtain a second direction difference between the image semantic descriptor of the behavior reference image of the x-th debugging learning example and the image semantic descriptor of the beam field real-time monitoring image comprises: According to the angular separation margin, boundary reconstruction is performed on the first direction difference between the image semantic descriptor of the behavior reference image of the x-th debugging learning example and the image semantic descriptor of the beam field real-time monitoring image, and the first direction difference between the image semantic descriptor of the beam field real-time monitoring image and the image semantic descriptor of the behavior reference image, respectively, to obtain the second direction difference between the image semantic descriptor of the behavior reference image of the x-th debugging learning example and the image semantic descriptor of the beam field real-time monitoring image, and the second direction difference between the image semantic descriptor of the beam field real-time monitoring image and the image semantic descriptor of the behavior reference image; The determining the first pre-debugging cost value according to the second direction difference corresponding to each debugging learning example in the P debugging learning examples includes: Determine the first pre-debugging cost value according to the second direction difference between the image semantic descriptor of the behavior reference image of each debugging learning example in the P debugging learning examples and the image semantic descriptor of the beam field real-time monitoring image, and the second direction difference between the image semantic descriptor of the beam field real-time monitoring image and the image semantic descriptor of the behavior reference image; The step of determining a first direction difference between an image semantic descriptor of the behavior reference image of the x-th debugging learning example and an image semantic descriptor of the beam field real-time monitoring image, and a first direction difference between an image semantic descriptor of the beam field real-time monitoring image and an image semantic descriptor of the behavior reference image, comprises: Determine a first direction cosine metric between an image semantic descriptor of a behavior reference image of the x-th debugging learning example and an image semantic descriptor of a beam field real-time monitoring image, and perform angle solving on the first direction cosine metric to obtain a first direction difference between an image semantic descriptor of the behavior reference image of the x-th debugging learning example and an image semantic descriptor of the beam field real-time monitoring image; Determine a second direction cosine metric between an image semantic descriptor of the beam field real-time monitoring image of the x-th debugging learning example and an image semantic descriptor of the behavior reference image, and perform angle solving on the second direction cosine metric to obtain a first direction difference between the image semantic descriptor of the beam field real-time monitoring image of the x-th debugging learning example and the image semantic descriptor of the behavior reference image; According to the angular separation margin, the first direction difference between the image semantic descriptor of the behavior reference image of the x-th debugging learning example and the image semantic descriptor of the beam field real-time monitoring image, and the first direction difference between the image semantic descriptor of the beam field real-time monitoring image and the image semantic descriptor of the behavior reference image are respectively reconstructed to obtain the second direction difference between the image semantic descriptor of the behavior reference image of the x-th debugging learning example and the image semantic descriptor of the beam field real-time monitoring image, and the second direction difference between the image semantic descriptor of the beam field real-time monitoring image and the image semantic descriptor of the behavior reference image, including: Determine the second direction difference between the image semantic descriptor of the behavior reference image of the x-th debugging learning example and the image semantic descriptor of the real-time monitoring image of the beam field by adding the safety distance to the first direction difference between the image semantic descriptor of the behavior reference image of the x-th debugging learning example and the image semantic descriptor of the real-time monitoring image of the beam field; Determine the second direction difference between the image semantic descriptor of the beam field real-time monitoring image of the x-th debugging learning example and the image semantic descriptor of the behavior reference image by adding the safety distance to the first direction difference between the image semantic descriptor of the beam field real-time monitoring image of the x-th debugging learning example and the image semantic descriptor of the behavior reference image; The determining of the first pre-debugging cost value according to the second direction difference between the image semantic descriptor of the behavior reference image of each debugging learning example in the P debugging learning examples and the image semantic descriptor of the beam field real-time monitoring image, and the second direction difference between the image semantic descriptor of the beam field real-time monitoring image and the image semantic descriptor of the behavior reference image, comprises: Determine a third direction difference between an image semantic descriptor of a behavior reference image of the x-th debugging learning sample and an image semantic descriptor of a beam field real-time monitoring image of each debugging learning sample in O debugging learning samples, and a fourth direction difference between an image semantic descriptor of the beam field real-time monitoring image of the x-th debugging learning sample and an image semantic descriptor of a behavior reference image of each debugging learning sample in the O debugging learning samples, wherein the O debugging learning samples are debugging learning samples other than the x-th debugging learning sample in the P debugging learning samples, wherein O=P-1; Determine a first error between the behavior reference image of the xth debugging learning example and the real-time monitoring image of the beam field of the Oth debugging learning example according to a second direction difference between the image semantic descriptor of the behavior reference image of the xth debugging learning example and the image semantic descriptor of the real-time monitoring image of the beam field, and a third direction difference corresponding to the xth debugging learning example; Determine a second error between the real-time monitoring image of the beam field of the x-th debugging learning example and the behavior reference image of the O-th debugging learning example according to a second direction difference between the image semantic descriptor of the beam field real-time monitoring image of the x-th debugging learning example and the image semantic descriptor of the behavior reference image, and a fourth direction difference corresponding to the x-th debugging learning example; Determining the first pre-debugging cost value according to the first error and the second error corresponding to each debugging learning example in the P debugging learning examples; The debugging process of the construction safety monitoring network includes a detail optimization stage, the network cost value includes a first detail optimization cost value, and the debugging of the construction safety monitoring network based on the network cost value includes: Obtaining a beam field real-time monitoring image and a behavior reference image of each debugging learning example in the Q debugging learning examples, and extracting an image semantic descriptor of the beam field real-time monitoring image and an image semantic descriptor of the behavior reference image of each debugging learning example in the Q debugging learning examples based on the construction safety monitoring network after pre-debugging, wherein Q ≥ 1; For the yth debugging learning sample among the Q debugging learning samples, obtaining A debugging learning samples carrying the same prior label as the yth debugging learning sample from the Q debugging learning samples, where 1≤A≤Q; According to the safety distance, strengthening the classification interface between the image semantic descriptor of the beam field real-time monitoring image of the yth debugging learning example and the image semantic descriptor of the beam field real-time monitoring image of the A debugging learning examples, and determining the first detail optimization cost value; According to the first detail optimization cost value, performing detail optimization on the construction safety monitoring network after the pre-debugging; The step of strengthening the classification interface between the image semantic descriptor of the beam field real-time monitoring image of the yth debugging learning example and the image semantic descriptor of the beam field real-time monitoring image of the A debugging learning examples according to the safety distance, and determining the first detail optimization cost value includes: For the a-th debugging learning sample among the A debugging learning samples, determining a fifth direction difference between an image semantic descriptor of the beam field real-time monitoring image of the y-th debugging learning sample and an image semantic descriptor of the beam field real-time monitoring image of the a-th debugging learning sample, wherein 1≤a≤A; According to the angular separation margin, the fifth direction difference is boundedly reconstructed to obtain a sixth direction difference between the image semantic descriptor of the beam field real-time monitoring image of the yth debugging learning example and the image semantic descriptor of the beam field real-time monitoring image of the ath debugging learning example; For the yth debugging learning sample, determining a seventh direction difference between an image semantic descriptor of the beam yard real-time monitoring image of the yth debugging learning sample and an image semantic descriptor of the beam yard real-time monitoring image of each debugging learning sample in Q-1 debugging learning samples, wherein the Q-1 debugging learning samples are debugging learning samples other than the yth debugging learning sample in the Q debugging learning samples; Determine the detail optimization error corresponding to the yth debugging learning example according to the sixth direction difference between the image semantic descriptor of the beam yard real-time monitoring image of the yth debugging learning example and the image semantic descriptor of the beam yard real-time monitoring image of the ath debugging learning example, and the seventh direction difference corresponding to the yth debugging learning example; The first detail optimization cost value is determined according to the detail optimization error corresponding to each debugging learning example in the Q debugging learning examples.
2. The method according to claim 1, characterized in that The method of determining a first error between the behavior reference image of the xth debugging learning example and the real-time monitoring image of the beam field of the Oth debugging learning example based on the second direction difference between the image semantic descriptor of the behavior reference image of the xth debugging learning example and the image semantic descriptor of the real-time monitoring image of the beam field, and the third direction difference corresponding to the xth debugging learning example, comprises: Performing a commonality metric transformation on the second direction difference between the image semantic descriptor of the behavior reference image of the x-th debugging learning example and the image semantic descriptor of the beam field real-time monitoring image to obtain a first commonality metric value between the behavior reference image of the x-th debugging learning example and the beam field real-time monitoring image; Performing a commonality metric transformation on the third direction difference between the image semantic descriptor of the behavior reference image of the x-th debugging learning example and the image semantic descriptor of the beam field real-time monitoring image of each debugging learning example in the O debugging learning examples, to obtain a second commonality metric value between the behavior reference image of the x-th debugging learning example and the beam field real-time monitoring image of each debugging learning example in the O debugging learning examples; Based on the first commonality measurement value between the behavior reference image of the x-th debugging learning sample and the real-time monitoring image of the beam yard, and the second commonality measurement value between the behavior reference image of the x-th debugging learning sample and the real-time monitoring image of the beam yard of each of the O debugging learning samples, the first error corresponding to the x-th debugging learning sample is determined.
3. The method according to claim 1, characterized in that The step of optimizing the construction safety monitoring network after the pre-debugging according to the first detail optimization cost value includes: Based on the construction safety monitoring network after the pre-debugging, extracting the image block semantic descriptor of the beam yard real-time monitoring image of each debugging learning example in the Q debugging learning examples; Performing optimal manifold distance calculation based on image block semantic descriptors of beam yard real-time monitoring images of each debugging learning example in the Q debugging learning examples, and determining a second detail optimization cost value of the construction safety monitoring network; According to the first detail optimization cost value and the second detail optimization cost value, the construction safety monitoring network after the pre-debugging is optimized in detail.
4. The method according to claim 3, characterized in that: The method of performing optimal manifold distance calculation based on the image block semantic descriptor of the beam yard real-time monitoring image of each debugging learning example in the Q debugging learning examples to determine the second detail optimization cost value of the construction safety monitoring network includes: For the zth debugging learning sample among the A debugging learning samples, determining a fifth optimal allocation cost between an image block semantic descriptor of the beam field real-time monitoring image of the yth debugging learning sample and an image semantic descriptor of the beam field real-time monitoring image of the zth debugging learning sample; Determine a sixth optimal allocation cost between an image block semantic descriptor of the beam field real-time monitoring image of the y-th debugging learning example and an image block semantic descriptor of the beam field real-time monitoring image of each debugging learning example in Q-1 debugging learning examples, wherein the Q-1 debugging learning examples are debugging learning examples other than the y-th debugging learning example in the Q debugging learning examples; The second detail optimization cost value is determined according to the fifth optimal allocation cost and the sixth optimal allocation cost corresponding to each debugging learning example in the Q debugging learning examples.
5. A computer system, characterized in that: include: one or more processors; Memory; one or more computer programs; The one or more computer programs are stored in the memory and configured to be executed by the one or more processors, and when the one or more computer programs are executed by the processors, the method according to any one of claims 1 to 4 is implemented.
