Detection method, device and electronic equipment for high-altitude working scenes
By obtaining target images and identifying them in high-altitude operation scene detection, using the position matching between people and equipment to identify high-altitude operation scenes, the problem of restricted detection positions in the prior art is solved, and a wider range of high-altitude operation scenes are achieved Identification and safety hazard detection.
Patent Information
- Application Number
- CN202110852733.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-07-27
- Publication Date
- 2024-11-05
- Estimated Expiration
- 2041-07-27
AI Technical Summary
The existing high-altitude operation scenario detection method can only be detected at a fixed position, and cannot be applied to environments that are inconvenient to install surveillance cameras in a fixed manner, and more high-altitude operation scenarios cannot be identified.
By obtaining the target image and identifying the target, we can determine whether there are personnel and target equipment, and use the position matching or mismatch between the people and the equipment to identify high-altitude work scenarios, and use the overlap and coordinate matching results to determine whether it is a high-altitude work scenario. Improves the universality and accuracy of detection.
It realizes high-altitude operation scene detection of target images collected at any location, can accurately identify more high-altitude operation scenes, improves detection efficiency and reliability, and promptly alarms when safety hazards are detected.
Smart Images

Figure CN113569729B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of image processing technology, and in particular to a detection method, device and electronic equipment for high-altitude working scenes. Background Art
[0002] Any work performed at a height of 2m or more (including 2m) above the falling height reference plane, where there is a possibility of falling, is called high-altitude work. A common application of high-altitude work scenes is to detect whether workers are wearing safety belts. Most of these applications are based on monitoring scenes. Among them, for the images collected in the monitoring scene, it is first determined whether it is in a high-altitude work scene, and then subsequent detection and judgment are performed based on the high-altitude work scene.
[0003] The existing detection of high-altitude working scenes is generally carried out through a fixed monitoring camera angle, and it is assumed that all people appearing in the monitoring angle are high-altitude working personnel. However, this detection method can only be performed at a fixed position, and is not applicable in some environments where it is not convenient to install a fixed monitoring camera. Summary of the invention
[0004] In view of this, an embodiment of the present invention provides a method, device and electronic equipment for detecting a high-altitude working scene, so as to solve the existing detection problem of the high-altitude working scene.
[0005] According to a first aspect, an embodiment of the present invention provides a method for detecting a high-altitude working scene, comprising:
[0006] Acquire a target image and perform target recognition on the target image;
[0007] Determine whether there is a person in the target image and whether the detection result of the target device in the target image does not meet the preset conditions;
[0008] When there is a person in the target image and the detection result of the target device in the target image does not meet the preset condition, identifying the working scene of the target image;
[0009] Based on the recognition result of the target working scene, it is determined whether the target image is an image of a high-altitude working scene.
[0010] The method for detecting high-altitude work scenes provided by the embodiment of the present invention has no restrictions on the installation location of the device for collecting target images. Since the recognition of work scenes is added to the detection process, more common high-altitude work scenes can be accurately identified, and the method has universality.
[0011] In combination with the first aspect, in a first implementation of the first aspect, when there is a person in the target image and the detection result of the target device does not meet the preset condition, identifying the operation scene of the target image includes:
[0012] When the person and the target device exist in the target image, obtaining positions of the person and the target device in the target image;
[0013] Based on the positions of the person and the target device, determining whether the person matches the target device;
[0014] When the person does not match the target device, the target image is identified as a work scene.
[0015] The method for detecting high-altitude work scenes provided by an embodiment of the present invention directly determines the high-altitude work scene by matching the positions of the person and the target device when both the person and the target device exist in the target image. The high-altitude work scene is identified only when there is a mismatch, thereby improving detection efficiency.
[0016] In combination with the first implementation manner of the first aspect, in the second implementation manner of the first aspect, the position includes coordinates of a detection box corresponding to the target in the target image and a center point of the detection box, and determining whether the person matches the target device based on the positions of the person and the target device includes:
[0017] Calculating the overlap between the first detection frame corresponding to the person and the second detection frame corresponding to the target device to determine an overlap matching result;
[0018] Determine a coordinate matching result based on a relationship between the coordinates and center point of the first detection frame and the coordinates and center point of the second detection frame;
[0019] Using the coordinate matching result and the coincidence matching result, determine whether the person matches the target device.
[0020] The detection method for high-altitude working scenes provided by the embodiment of the present invention utilizes the coincidence matching result and the coordinate matching result, integrates the two results to determine whether the person matches the target equipment, and improves the reliability of the determination result.
[0021] In combination with the second implementation manner of the first aspect, in the third implementation manner of the first aspect, when the target device is a supporting platform, determining the coordinate matching result based on the relationship between the coordinates and the center point of the first detection frame and the coordinates and the center point of the second detection frame includes:
[0022] Determine whether the vertical coordinate of the center point of the second detection frame is greater than the vertical coordinate of the center point of the first detection frame;
[0023] When the ordinate of the center point of the second detection frame is greater than the ordinate of the center point of the first detection frame, determining whether the abscissa of the center point of the first detection frame is between the abscissas of the left and right corner points of the second detection frame;
[0024] When the horizontal coordinate of the center point of the first detection frame is between the horizontal coordinates of the left and right corner points of the second detection frame, it is determined that the coordinates of the person and the target device match.
[0025] The detection method for high-altitude working scenes provided by the embodiment of the present invention, for a support platform, determines the coordinate matching result based on the positional relationship between the center points of the detection frame, so that the determination result is more suitable for the target device such as the support platform, thereby improving the accuracy of detection.
[0026] In combination with the second implementation manner of the first aspect, in the fourth implementation manner of the first aspect, when the target device is a lifting device, determining the coordinate matching result based on the relationship between the coordinates and the center point of the first detection frame and the coordinates and the center point of the second detection frame includes:
[0027] Determine whether the vertical coordinate of the lower right corner of the second detection frame is greater than the vertical coordinate of the lower right corner of the first detection frame;
[0028] When the ordinate of the lower right corner of the second detection frame is greater than the ordinate of the lower right corner of the first detection frame, determining whether the abscissa of the center point of the first detection frame is between the abscissas of the left and right corner points of the second detection frame;
[0029] When the horizontal coordinate of the center point of the first detection frame is between the horizontal coordinates of the left and right corner points of the second detection frame, it is determined that the coordinates of the person and the target device match.
[0030] The detection method for high-altitude working scenes provided by an embodiment of the present invention, for a lifting device, determines the coordinate matching result based on the center point of the detection frame and the coordinates of the detection frame, so that the determination result is more suitable for the target equipment such as the lifting device, thereby improving the accuracy of detection.
[0031] In combination with the first aspect, in a fifth implementation of the first aspect, when there is a person in the target image and the detection result of the target device does not meet the preset condition, identifying the operation scene of the target image includes:
[0032] When a person exists in the target image but the target device does not exist, the target image is identified as a work scene.
[0033] The method for detecting high-altitude work scenes provided by an embodiment of the present invention further identifies the work scene on the target image when there are personnel but no target equipment. It can detect the situation where the personnel are not on the target equipment but are still working at high altitude, thereby improving the reliability of the detection result.
[0034] In combination with the first aspect, or any one of the first to fifth embodiments of the first aspect, in a sixth embodiment of the first aspect, the detection method further includes:
[0035] When it is determined that the target image is an image of a high-altitude working scene, performing safety detection on a person in the target image;
[0036] When the result of the safety detection does not meet the safety condition, it is determined that there is a safety hazard.
[0037] The detection method for high-altitude working scenes provided by the embodiment of the present invention determines that there are safety hazards when it is detected that the personnel are in a high-altitude working scene and the safety detection results do not meet the safety conditions, so that the method can be applied to the daily inspections of inspectors to improve the detection efficiency of safety hazards.
[0038] According to the second aspect, an embodiment of the present invention further provides a detection device for a high-altitude working scene, comprising:
[0039] An acquisition module, used for acquiring a target image;
[0040] A judgment module, used to judge whether there is a person in the target image and whether the detection result of the target device in the target image does not meet the preset conditions;
[0041] A scene recognition module, used for identifying the working scene of the target image when there is a person in the target image and the detection result of the target device in the target image does not meet the preset conditions;
[0042] A determination module is used to determine whether the target image is an image of a high-altitude working scene based on the recognition result of the target working scene.
[0043] The detection device for high-altitude working scenes provided by the embodiment of the present invention has no restriction on the installation position of the device for collecting target images. Since the recognition of working scenes is added during the detection process, more common high-altitude working scenes can be recognized, and it has universality.
[0044] According to the third aspect, an embodiment of the present invention provides an electronic device, comprising: a memory and a processor, the memory and the processor being communicatively connected to each other, the memory storing computer instructions, and the processor executing the method for detecting high-altitude work scenes described in the first aspect or any one of the embodiments of the first aspect by executing the computer instructions.
[0045] According to the fourth aspect, an embodiment of the present invention provides a computer-readable storage medium, which stores computer instructions, and the computer instructions are used to enable the computer to execute the method for detecting high-altitude work scenes described in the first aspect or any one embodiment of the first aspect. BRIEF DESCRIPTION OF THE DRAWINGS
[0046] In order to more clearly illustrate the specific implementation methods of the present invention or the technical solutions in the prior art, the drawings required for use in the specific implementation methods or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are some implementation methods of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
[0047] Figure 1 is a flow chart of a method for detecting a high-altitude working scene according to an embodiment of the present invention;
[0048] Figure 2 is a flow chart of a method for detecting a high-altitude working scene according to an embodiment of the present invention;
[0049] Figure 3 is a schematic diagram of a detection frame corresponding to a person and a target device in an embodiment of the present invention;
[0050] Figure 4 is a flow chart of a method for detecting a high-altitude working scene according to an embodiment of the present invention;
[0051] Figure 5 is a flow chart of a method for detecting a high-altitude working scene according to an embodiment of the present invention;
[0052] Figure 6 is a structural block diagram of a detection device for a high-altitude working scene according to an embodiment of the present invention;
[0053] Figure 7 It is a schematic diagram of the hardware structure of an electronic device provided by an embodiment of the present invention. DETAILED DESCRIPTION
[0054] In order to make the purpose, technical solution and advantages of the embodiments of the present invention clearer, the technical solution in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative work are within the scope of protection of the present invention.
[0055] When personnel are working at heights, they rely on specific equipment to be able to carry out the work, and the specific equipment can be a ladder, a hanging basket, a lift, etc. Based on this, it is generally determined whether it is working at height by detecting whether there are personnel and specific equipment in the target image at the same time, and then judging whether the personnel are on the specific equipment. Although this detection method can detect some high-altitude working scenes, when the specific equipment is not detected, the conclusion given by the method is that it is not a high-altitude working scene at this time. However, the failure to detect a specific device does not mean that it is not a high-altitude working scene. For example, personnel are in the construction area near the edge of the floor or the edge of the balcony, etc., although no specific equipment is detected in these scenes, they also belong to the high-altitude working scene. Based on this, an embodiment of the present invention provides a detection method for a high-altitude working scene, which is not limited to the installation position of the monitoring equipment, but also has a certain detection comprehensiveness.
[0056] The detection method for high-altitude work scenes described in the embodiment of the present invention can be applied to the detection of high-altitude work scenes in power scenarios, and can also be applied to the detection of high-altitude work scenes in construction scenarios, etc., and there is no limitation on its application scenarios.
[0057] Furthermore, when determining the high-altitude working scene, subsequent applications can be expanded on this basis, for example, to detect whether the personnel are wearing safety belts, whether they are wearing safety helmets, whether the operation is in compliance with regulations, etc.
[0058] According to an embodiment of the present invention, an embodiment of a detection method for a high-altitude work scene is provided. It should be noted that the steps shown in the flowchart of the accompanying drawings can be executed in a computer system such as a set of computer executable instructions, and although a logical order is shown in the flowchart, in some cases, the steps shown or described can be executed in an order different from that shown here.
[0059] In this embodiment, a method for detecting a high-altitude working scene is provided, which can be used for electronic devices such as computers, mobile phones, smart glasses, inspection equipment, etc. Figure 1 is a flow chart of a method for detecting a high-altitude working scene according to an embodiment of the present invention. Figure 1 As shown, the process includes the following steps:
[0060] S11, acquiring a target image and performing target recognition on the target image.
[0061] The target image acquired by the electronic device may be acquired by the electronic device, or may be acquired by a third-party device and sent to the electronic device. There is no restriction on the way in which the electronic device acquires the target image. For example, the electronic device is an inspection device, and the inspection personnel use the inspection device to acquire images of the working area, and accordingly, the inspection device acquires the corresponding target image; for another example, the electronic device is smart glasses, and the inspection personnel wear the smart glasses to acquire images of the working area, and accordingly, the smart glasses acquire the corresponding target image.
[0062] After acquiring the target image, the electronic device performs target recognition on it to determine whether there is a corresponding target in the target image, such as a person, a target device, etc. The target recognition can be implemented in the form of a recognition network. Specifically, the electronic device inputs the acquired template image into the recognition network and outputs the recognition result. Alternatively, the electronic device can also perform feature extraction on the target image to identify the target in the target image.
[0063] Optionally, in a construction scenario, the recognition network is used to recognize personnel and target equipment, and common target equipment includes hanging baskets, elevators, ladders, and gantry scaffolds, etc. The recognition network can be built based on YOLOv5 or other networks, and there is no limitation on it here, as long as the recognition network can recognize the corresponding target in the target image.
[0064] S12, determining whether there is a person in the target image and whether the detection result of the target device in the target image does not meet the preset conditions.
[0065] Since the purpose of detecting high-altitude working scenes is to ensure the safety of personnel, if there are no personnel in the target image, it can be directly determined that the current scene is not a high-altitude working scene. If there are personnel in the target image, check whether the detection result of the target device in the target image does not meet the preset conditions. Among them, the target device in the target image is not limited to the target device must exist in the target image, it may also be that the target device does not exist; accordingly, when the target device exists in the target image, the detection result is compared with the first preset condition to determine whether it does not meet the preset condition; when the target device does not exist in the target image, it can be directly determined that it does not meet the preset condition. When there are personnel in the target image and the detection result of the target device does not meet the preset conditions, execute S13; otherwise, execute other operations.
[0066] The other operations include determining that the target image is an image of a non-high-altitude working scene when there is no person in the target image; or determining that the target image is an image of a high-altitude working scene when there is a person and the person matches the target device. Corresponding to the above, the detection result of the target device meets the preset conditions and is also divided into two cases, namely, when the target device exists in the target image, and when the target device does not exist in the target image.
[0067] S13, identifying the working scene of the target image.
[0068] When the electronic device determines that there is a person in the target image and the detection result of the target device does not meet the preset conditions, it does not directly determine that it is in a non-high-pressure working scene, but recognizes the working scene of the target image again. Among them, the recognition of the working scene can be realized by using a scene classification model, inputting the target image into the scene classification model, and outputting the predicted classification result. Alternatively, the electronic device can also perform image recognition on the target image, extract the features of the target image, analyze the features, and then recognize the working scene of the target image.
[0069] For different application scenarios, the sample scene data used to train the scene classification model are also different. The training samples include positive samples and negative samples, where the positive samples are high-altitude working scenes and the negative samples are non-high-altitude working scenes. For example, for the construction scene, the scene classification model is trained to identify high-altitude working scenes, i.e., positive sample scenes such as scaffolding construction areas, floor edge or balcony edge construction areas, and building top floor construction areas. The scene classification model can be built based on ResNet50 or other model components. There is no limitation on it here. It only needs to ensure that the scene classification model can identify the working scenes in the target image.
[0070] It should be noted that the above-mentioned identification of targets and operation scenarios can be set accordingly according to actual conditions, and there are no special limitations thereto.
[0071] S14, based on the recognition result of the target working scene, determining whether the target image is an image of a high-altitude working scene.
[0072] As described above, the scene classification model identifies the work scene of the target image, and the output of the model is the predicted work scene and its probability value, and the work scene with the largest probability value is determined as the target work scene. Accordingly, it can be determined whether the target image is an image of a high-altitude work scene.
[0073] The method for detecting high-altitude work scenes provided in this embodiment has no restrictions on the installation location of the device for collecting target images. Since the recognition of work scenes is added to the detection process, more common high-altitude work scenes can be accurately identified, and the method has universality.
[0074] In this embodiment, a method for detecting a high-altitude working scene is provided, which can be used in electronic devices such as computers, mobile phones, smart glasses, inspection equipment, etc. Figure 2 is a flow chart of a method for detecting a high-altitude working scene according to an embodiment of the present invention. Figure 2 As shown, the process includes the following steps:
[0075] S21, acquiring a target image and performing target recognition on the target image.
[0076] For details, please see Figure 1 S11 of the illustrated embodiment will not be described in detail here.
[0077] S22, determining whether there is a person in the target image and whether the detection result of the target device in the target image does not meet the preset conditions.
[0078] Specifically, the above S22 includes:
[0079] S221: When there is a person in the target image, determine whether there is a target device in the target image.
[0080] As described above, a recognition network is used to perform target recognition on a target image. The recognition network outputs each target in the target image. The recognition network can be used to simultaneously recognize a person and a target device in the target image.
[0081] When there are people and the target device in the target image, execute S222; otherwise, execute S23.
[0082] S222, obtaining the positions of the person and the target device in the target image.
[0083] When the recognition network outputs each target in the target image, it accordingly outputs the position of each target in the target image. Alternatively, when the image analysis method is used to determine the person and the target device in the target image, the position of each target in the target image is given accordingly.
[0084] S223: Determine whether the person and the target device match based on the positions of the person and the target device.
[0085] The determination of whether the person matches the target device is to determine the position between the person and the target device, or to determine whether the person is on the target device. The position between the person and the target device can be determined by using the intersection of the corresponding detection frames, or by using the center point coordinates of the corresponding detection frames, etc., which are not limited in any way.
[0086] When the person does not match the target device, S23 is executed; otherwise, it means that the person matches the target device, and the target image can be determined to be an image of a high-altitude working scene. In some optional implementations of this embodiment, the above S223 may include:
[0087] (1) Calculate the overlap between the first detection frame corresponding to the person and the second detection frame corresponding to the target device to determine the overlap matching result.
[0088] Taking the recognition network as an example, when the recognition network outputs each target in the target image, it also outputs the corresponding detection box coordinates. Figure 3 As shown, a person and a target device are identified in the target image, and the upper left corner coordinates (x1, y1) and the lower right corner coordinates (x2, y2) of the first detection box corresponding to the person, and the upper left corner coordinates (X1, Y1) and the lower right corner coordinates (X2, Y2) of the second detection box corresponding to the target device are given accordingly.
[0089] The overlap between the first detection frame and the second detection frame can be calculated using the intersection area or the intersection-and-union ratio, which is not limited here. After calculating the overlap between the first detection frame and the second detection frame, the electronic device can determine the overlap matching result.
[0090] (2) Determine a coordinate matching result based on the relationship between the coordinates and center point of the first detection frame and the coordinates and center point of the second detection frame.
[0091] The center point of the detection frame can be calculated using the coordinates of the upper left corner and the lower right corner of the detection frame. For example, the center point of the first detection frame is recorded as (p1, p2), p1 = (x1 + x2) / 2, p2 = (y1 + y2) / 2; the center point of the second detection frame is recorded as (P1, P2), P1 = (X1 + X2) / 2, P2 = (Y1 + Y2) / 2.
[0092] By comparing the coordinates and center point of the first detection frame with the coordinates and center point of the second detection frame, the coordinate matching result can be determined.
[0093] In this embodiment, the coordinate matching result is determined in a corresponding manner according to the type of target device. The target device is divided into a support platform and a lifting device, the support platform is, for example, a gantry scaffold or a stepladder; the lifting device is, for example, a hanging basket or an elevator. Different methods are used to determine the coordinate matching result for different target devices. Specifically,
[0094] When the target device is a support platform, the above step (2) includes:
[0095] 2.11) Determine whether the vertical coordinate of the center point of the second detection frame is greater than the vertical coordinate of the center point of the first detection frame.
[0096] 2.12) When the ordinate of the center point of the second detection frame is greater than the ordinate of the center point of the first detection frame, determine whether the abscissa of the center point of the first detection frame is between the abscissas of the left and right corner points of the second detection frame.
[0097] 2.13) When the horizontal coordinate of the center point of the first detection frame is between the horizontal coordinates of the left and right corner points of the second detection frame, it is determined that the coordinates of the person and the target device match.
[0098] For the support platform, the coordinate matching result is determined based on the positional relationship between the center points of the detection frame, making the determination result more suitable for the target device such as the support platform, thereby improving the accuracy of the detection.
[0099] When the target device is a lifting device, the above step (2) includes:
[0100] 2.21) Determine whether the vertical coordinate of the lower right corner of the second detection frame is greater than the vertical coordinate of the lower right corner of the first detection frame.
[0101] 2.22) When the ordinate of the lower right corner of the second detection frame is greater than the ordinate of the lower right corner of the first detection frame, determine whether the horizontal coordinate of the center point of the first detection frame is between the horizontal coordinates of the left and right corner points of the second detection frame.
[0102] 2.23) When the horizontal coordinate of the center point of the first detection frame is between the horizontal coordinates of the left and right corner points of the second detection frame, it is determined that the coordinates of the person and the target device match.
[0103] For the lifting device, the coordinate matching result is determined based on the center point of the detection frame and the coordinates of the detection frame, so that the determination result is more suitable for the target device such as the lifting device, thereby improving the accuracy of the detection.
[0104] (3) Use the coordinate matching results and the coincidence matching results to determine whether the person matches the target device.
[0105] Specifically, the matching strategy between personnel and support platforms is:
[0106] If p2 < P2 and X1 < p1 < X2 and IOU(the first detection box, the second detection box) > th1, then they are matched; otherwise, they are not matched.
[0107] Specifically, the matching strategy between the personnel and the lifting device is as follows:
[0108] If y2 < Y2 and X1 < p1 < X2 and IOU(the first detection box, the second detection box) > th2, then they are matched; otherwise, they are not matched.
[0109] By using the matching result of the coincidence degree and the matching result of the coordinates, integrating the two results to determine whether the personnel and the target device are matched, the reliability of the determination result is improved.
[0110] S23. Identify the operation scenario of the target image.
[0111] For details, please refer to Figure 1 S13 in the illustrated embodiment, which will not be elaborated here.
[0112] S24. Based on the recognition result of the target operation scenario, determine whether the target image is an image of a high-altitude operation scenario.
[0113] For details, please refer to Figure 1 S14 in the illustrated embodiment, which will not be elaborated here.
[0114] The detection method for high-altitude operation scenarios provided in this embodiment, when both a person and a target device exist in the target image, uses the positions of the person and the target device for matching and directly determines the high-altitude operation scenario. Only in the case of non-matching, the high-altitude operation scenario is identified, which improves the detection efficiency; when a person exists but the target device does not exist, the operation scenario of the target image is further identified, which can detect the situation where the person is not on the target device but is still working at a high altitude, improving the reliability of the detection result.
[0115] As a specific application example of this embodiment, as Figure 4 shown, the detection method for high-altitude operation scenarios includes:
[0116] S(1). Obtain the target image;
[0117] S(2). The detection model, that is, use the detection model to perform target recognition on the target image;
[0118] S(3). Judge whether a person is detected. When a person is detected, execute S(4); otherwise, return a non-high-altitude operation scenario;
[0119] S(4). Judge whether a target device is detected. When a target device is detected, execute S(6); otherwise, execute S(5);
[0120] S(5), scene classification model, i.e., using the scene classification model to perform scene recognition on the target image, and executing S(7);
[0121] S(6), determine whether the person and the target device match. If they match, return to the high-altitude working scene; otherwise, execute S(5);
[0122] S(7), determine whether it is a high-altitude working scene. If it is a high-altitude working scene, return to the high-altitude working scene; otherwise, return to the non-high-altitude working scene.
[0123] The detection method for high-altitude working scenes can be deployed in the monitoring cameras of the construction site, without the need for a fixed viewing angle, and can identify high-altitude working scenes in a variety of scenes. At the same time, the method can also be extended to other terminal devices such as mobile phones and smart glasses to help inspectors report hidden dangers more quickly.
[0124] In this embodiment, a method for detecting a high-altitude working scene is provided, which can be used in electronic devices such as computers, mobile phones, smart glasses, inspection equipment, etc. Figure 5 is a flow chart of a method for detecting a high-altitude working scene according to an embodiment of the present invention. Figure 5 As shown, the process includes the following steps:
[0125] S31, acquiring a target image and performing target recognition on the target image.
[0126] For details, please see Figure 1 S11 of the illustrated embodiment will not be described in detail here.
[0127] S32, determining whether there is a person in the target image and whether the detection result of the target device in the target image does not meet the preset conditions.
[0128] When there is a person in the target image and the detection result of the target device does not meet the preset condition, execute S33; otherwise, execute other operations.
[0129] For details, please see Figure 2 S22 of the illustrated embodiment will not be described in detail here.
[0130] S33, identifying the working scene of the target image.
[0131] For details, please see Figure 1 S13 of the illustrated embodiment will not be described in detail here.
[0132] S34, based on the recognition result of the target working scene, determining whether the target image is an image of a high-altitude working scene.
[0133] Specifically, the above S34 includes:
[0134] S341: When it is determined that the target image is an image of a high-altitude working scene, a safety detection is performed on the personnel in the target image.
[0135] The safety detection may include whether the inspector wears a helmet, a safety belt, or other aspects. There is no special limitation on this and the specific settings can be made according to actual needs.
[0136] S342, when the result of the safety detection does not meet the safety conditions, it is determined that there is a safety hazard.
[0137] When it is detected that the safety conditions are not met, the electronic equipment confirms that there is a safety hazard and can issue an alarm or send the alarm information to the monitoring system for unified management, etc.
[0138] The detection method for high-altitude work scenes provided in this embodiment determines that there are safety hazards when it is detected that the personnel are in a high-altitude work scene and the safety detection results do not meet the safety conditions. This allows the method to be applied to the daily inspections of inspectors to improve the efficiency of detecting safety hazards.
[0139] In this embodiment, a detection device for a high-altitude working scene is also provided, which is used to implement the above-mentioned embodiments and preferred implementation modes, and the descriptions that have been made will not be repeated. As used below, the term "module" can implement a combination of software and / or hardware of a predetermined function. Although the devices described in the following embodiments are preferably implemented in software, the implementation of hardware, or a combination of software and hardware, is also possible and conceivable.
[0140] This embodiment provides a detection device for high-altitude working scenes, such as Figure 6 As shown, including:
[0141] An acquisition module 41, used for acquiring a target image;
[0142] A judgment module 42, used to judge whether there is a person in the target image and whether the detection result of the target device in the target image does not meet the preset conditions;
[0143] A scene recognition module 43, configured to recognize a work scene for the target image when there is a person in the target image and the detection result of the target device in the target image does not meet a preset condition;
[0144] The determination module 44 is used to determine whether the target image is an image of a high-altitude working scene based on the recognition result of the target working scene.
[0145] The detection device for high-altitude work scenes provided in this embodiment has no restrictions on the installation location of the device for collecting target images. Since the recognition of work scenes is added to the detection process, it can accurately identify more common high-altitude work scenes and has universality.
[0146] The detection device for high-altitude working scenes in this embodiment is presented in the form of functional units, where the units refer to ASIC circuits, processors and memories that execute one or more software or fixed programs, and / or other devices that can provide the above-mentioned functions.
[0147] The further functional description of each of the above modules is the same as that of the above corresponding embodiments and will not be repeated here.
[0148] The embodiment of the present invention also provides an electronic device having the above Figure 6 The detection device for the high-altitude working scene is shown.
[0149] See also Figure 7 , Figure 7 is a schematic diagram of the structure of a terminal provided by an optional embodiment of the present invention, such as Figure 7 As shown, the terminal may include: at least one processor 51, such as a CPU (Central Processing Unit), at least one communication interface 53, a memory 54, and at least one communication bus 52. The communication bus 52 is used to realize the connection and communication between these components. The communication interface 53 may include a display screen (Display) and a keyboard (Keyboard), and the optional communication interface 53 may also include a standard wired interface and a wireless interface. The memory 54 may be a high-speed RAM memory (Random Access Memory) or a non-volatile memory (non-volatile memory), such as at least one disk storage. The memory 54 may optionally be at least one storage device located away from the aforementioned processor 51. The processor 51 may be combined with Figure 6 In the described device, the memory 54 stores an application program, and the processor 51 calls the program code stored in the memory 54 to execute any of the above method steps.
[0150] The communication bus 52 may be a peripheral component interconnect (PCI) bus or an extended industry standard architecture (EISA) bus. The communication bus 52 may be divided into an address bus, a data bus, a control bus, etc. For ease of representation, Figure 7Only one thick line is used in the diagram, but this does not mean that there is only one bus or only one type of bus.
[0151] Among them, the memory 54 may include a volatile memory (English: volatile memory), such as a random access memory (English: random-access memory, abbreviated: RAM); the memory may also include a non-volatile memory (English: non-volatile memory), such as a flash memory (English: flash memory), a hard disk drive (English: hard disk drive, abbreviated: HDD) or a solid-state drive (English: solid-state drive, abbreviated: SSD); the memory 54 may also include a combination of the above types of memory.
[0152] The processor 51 may be a central processing unit (CPU), a network processor (NP), or a combination of a CPU and a NP.
[0153] The processor 51 may further include a hardware chip. The hardware chip may be an application-specific integrated circuit (ASIC), a programmable logic device (PLD), or a combination thereof. The PLD may be a complex programmable logic device (CPLD), a field-programmable gate array (FPGA), a generic array logic (GAL), or any combination thereof.
[0154] Optionally, the memory 54 is also used to store program instructions. The processor 51 can call the program instructions to implement the present application Figure 1 , 2 , 4 or 5, a method for detecting a high-altitude working scene.
[0155] The embodiment of the present invention further provides a non-transitory computer storage medium, which stores computer executable instructions, and the computer executable instructions can execute the detection method of the high-altitude working scene in any of the above method embodiments. Among them, the storage medium can be a disk, an optical disk, a read-only memory (ROM), a random access memory (RAM), a flash memory (Flash Memory), a hard disk (HDD) or a solid-state drive (SSD), etc.; the storage medium can also include a combination of the above types of memory.
[0156] Although the embodiments of the present invention have been described in conjunction with the accompanying drawings, those skilled in the art may make various modifications and variations without departing from the spirit and scope of the present invention, and such modifications and variations are all within the scope defined by the appended claims.
Claims
1. A method for detecting a high-altitude working scene, characterized in that: include: Acquire a target image and perform target recognition on the target image; Determine whether there is a person in the target image and whether the detection result of the target device in the target image does not meet the preset conditions; When there is a person in the target image and the detection result of the target device in the target image does not meet the preset condition, identifying the working scene of the target image; Based on the recognition result of the working scene, determining whether the target image is an image of a high-altitude working scene; Wherein, when there is a person in the target image and the detection result of the target device does not meet the preset condition, identifying the operation scene of the target image includes: When the person and the target device exist in the target image, obtaining positions of the person and the target device in the target image; Based on the positions of the person and the target device, determining whether the person matches the target device; When the person does not match the target device, the target image is identified as a work scene.
2. The detection method according to claim 1, characterized in that: The position includes coordinates of a detection frame corresponding to the target in the target image and a center point of the detection frame, and determining whether the person matches the target device based on the positions of the person and the target device includes: Calculating the overlap between the first detection frame corresponding to the person and the second detection frame corresponding to the target device to determine an overlap matching result; Determine a coordinate matching result based on a relationship between the coordinates and center point of the first detection frame and the coordinates and center point of the second detection frame; Using the coordinate matching result and the coincidence matching result, determine whether the person matches the target device.
3. The detection method according to claim 2, characterized in that: When the target device is a supporting platform, determining the coordinate matching result based on the relationship between the coordinates and the center point of the first detection frame and the coordinates and the center point of the second detection frame includes: Determine whether the vertical coordinate of the center point of the second detection frame is greater than the vertical coordinate of the center point of the first detection frame; When the ordinate of the center point of the second detection frame is greater than the ordinate of the center point of the first detection frame, determining whether the abscissa of the center point of the first detection frame is between the abscissas of the left and right corner points of the second detection frame; When the horizontal coordinate of the center point of the first detection frame is between the horizontal coordinates of the left and right corner points of the second detection frame, it is determined that the coordinates of the person and the target device match.
4. The detection method according to claim 2, characterized in that: When the target device is a lifting device, determining the coordinate matching result based on the relationship between the coordinates and the center point of the first detection frame and the coordinates and the center point of the second detection frame includes: Determine whether the vertical coordinate of the lower right corner of the second detection frame is greater than the vertical coordinate of the lower right corner of the first detection frame; When the ordinate of the lower right corner of the second detection frame is greater than the ordinate of the lower right corner of the first detection frame, determining whether the abscissa of the center point of the first detection frame is between the abscissas of the left and right corner points of the second detection frame; When the horizontal coordinate of the center point of the first detection frame is between the horizontal coordinates of the left and right corner points of the second detection frame, it is determined that the coordinates of the person and the target device match.
5. The detection method according to claim 1, characterized in that: When there is a person in the target image and the detection result of the target device does not meet the preset condition, identifying the operation scene of the target image also includes: When a person exists in the target image but the target device does not exist, the target image is identified as a work scene.
6. The detection method according to any one of claims 1 to 5, characterized in that: The detection method further comprises: When it is determined that the target image is an image of a high-altitude working scene, performing safety detection on a person in the target image; When the result of the safety detection does not meet the safety condition, it is determined that there is a safety hazard.
7. A detection device for high-altitude working scenes, characterized in that: include: An acquisition module, used for acquiring a target image and performing target recognition on the target image; A judgment module, used to judge whether there is a person in the target image and whether the detection result of the target device in the target image does not meet the preset conditions; A scene recognition module, used for identifying the working scene of the target image when there is a person in the target image and the detection result of the target device in the target image does not meet the preset conditions; A determination module, used to determine whether the target image is an image of a high-altitude working scene based on the recognition result of the working scene; Wherein, when there is a person in the target image and the detection result of the target device does not meet the preset condition, identifying the operation scene of the target image includes: When the person and the target device exist in the target image, obtaining positions of the person and the target device in the target image; Based on the positions of the person and the target device, determining whether the person matches the target device; When the person does not match the target device, the target image is identified as a work scene.
8. An electronic device, characterized in that: include: A memory and a processor, wherein the memory and the processor are communicatively connected to each other, the memory stores computer instructions, and the processor executes the method for detecting a high-altitude working scene according to any one of claims 1 to 6 by executing the computer instructions.
9. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores computer instructions, and the computer instructions are used to enable a computer to execute the method for detecting a high-altitude working scene according to any one of claims 1-6.
