Safety shoe rapid detection method based on deep learning and color analysis

By combining deep learning and color analysis methods, and utilizing HSV color space and human posture recognition technology, the accuracy and efficiency issues of safety shoe detection under low-quality video conditions are solved, achieving efficient and accurate safety shoe detection.

CN120808445APending Publication Date: 2025-10-17ZHOUSHAN YONGXIANG SHIPPING CO LTD
View PDF 5 Cites 0 Cited by

Patent Information

Application Number
CN202511012266.2
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-07-22
Publication Date
2025-10-17

AI Technical Summary

Technical Problem

In the existing technology, the detection method of safety shoes relies on manual visual inspection or rule-based methods. It is difficult to accurately detect the wearing condition of safety shoes under low-quality video conditions, and it is time-consuming and labor-intensive.

Method used

A method based on deep learning and color analysis is adopted, combined with human posture recognition technology and color feature analysis. Through target detection and posture estimation models, the HSV color space is used to determine the color range of safety shoes. The color range is detected in the video stream and combined with the confidence assessment of the ankle area to determine whether safety shoes are worn.

Benefits of technology

Efficient and accurate safety shoe detection is achieved under low-quality video conditions, reducing false positives and missed negatives, improving the adaptability and accuracy of detection, and reducing computing resource consumption.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120808445A_ABST
    Figure CN120808445A_ABST
Patent Text Reader

Abstract

The invention discloses a safety shoe rapid detection method based on deep learning and color analysis, and the method comprises the steps: obtaining a human body posture data set, and randomly dividing the data set into a training set, a verification set and a test set according to a proportion of 8: 1: 1; training a target detection and attitude estimation model by using the training set and the verification set to obtain personnel positioning information and key point information; acquiring color data of the safety shoes, and determining a color range of the safety shoes in the HSV color space; obtaining a to-be-detected video stream and performing preprocessing; reasoning the video stream by using the trained target detection and attitude estimation model, and positioning ankle part coordinates and confidence information; and by taking the coordinates of the ankle part as the circle center, whether the safety shoe is worn or not is judged by checking whether an element with a pixel value greater than zero exists in the mask or not.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the technical field of safety shoe detection, in particular, and especially relates to a safety shoe rapid detection method based on deep learning and color analysis. BACKGROUND

[0002] With the continuous improvement of industrial production safety awareness, ensuring that workers correctly wear personal protective equipment (PPE) has become an important part of enterprise safety management. Safety shoes, as one of the personal protective equipment, are crucial for protecting workers from ground hazards. However, in practical applications, especially in complex working environments, manually checking whether all workers are correctly wearing safety shoes is both time-consuming and prone to errors.

[0003] Traditional safety shoe detection methods mainly rely on manual visual inspection or rule-based methods, which have limitations in practical applications, especially in low-quality video conditions, making it difficult to accurately detect the wearing of safety shoes. In recent years, with the development of computer vision technology and deep learning, image processing and machine learning-based methods have been widely applied to various visual tasks, including object detection and recognition. SUMMARY

[0004] To overcome the limitations of existing technology, the present application proposes a safety shoe rapid detection method based on deep learning and color analysis. This method combines human pose recognition technology and color feature analysis technology to achieve efficient and accurate safety shoe detection under low-quality video conditions. The key technical means of the present application are as follows: Obtain a human pose dataset and randomly divide it into a training set, a validation set, and a test set in a ratio of 8:1:1; Use the training set and validation set to train the target detection and pose estimation model to obtain personnel positioning information and key point information; Obtain color data of safety shoes and determine the color range of safety shoes in the HSV color space; Obtain the video stream to be detected and preprocess it; Use the trained target detection and pose estimation model to infer the video stream to locate the ankle part coordinates and confidence information; Take the ankle part coordinates as the center, check whether there are pixel values greater than zero in the mask, and determine whether there are pixels belonging to the specified HSV color range in the ROI detection area. If pixels meeting the conditions are detected, it is determined that safety shoes are worn, and if no pixels meeting the conditions are detected, it is determined that safety shoes are not worn.

[0005] Further, when training the target detection and pose estimation model using the training set: The object detection and pose estimation models are trained using the following gradient descent method:

[0006] in, Indicates the The parameter value at the iteration, Indicates the The parameter value at the iteration, is the learning rate, which controls the step size of parameter updates, Represents the loss function In the parameters About a single training example gradient; Use the validation set to evaluate and adjust the performance of the trained model; The test set is used to verify the performance of the final object detection and pose estimation model.

[0007] Furthermore, color data of safety shoe samples are collected, the color data are analyzed in the HSV color space to determine the color range of the safety shoes, and a database of the color range of the safety shoes is established.

[0008] Furthermore, each frame of the video stream is input into the trained target detection and posture estimation model to extract the coordinates of the key points of the human skeleton. The ankle key points include the left ankle and the right ankle, and their positions are recorded as ; For each ankle key point, the heat map response intensity output by the neural network is used , the confidence score of the point is determined by the value corresponding to the maximum response position , the specific calculation formula is:

[0009] in Indicates Central Region, used to enhance local confidence robustness; Use the non-maximum suppression (NMS) algorithm to filter all candidate ankle detection boxes and retain the confidence score The maximum result is output as the final ankle position.

[0010] Furthermore, the following methods are used to determine whether safety shoes are worn: Define a rectangular area with a specified radius with the ankle coordinates as the center; Let the image be I , the center point coordinates are ( x c , y c), the detection radius is r , the lower limit of the HSV color range is , the upper limit of the HSV color range is The detection area ROI is represented by a rectangle, and the coordinate range is determined by the center point and the radius

[0011] Where H and W are the height and width of the image respectively, in the ROI detection area, color analysis is performed using the determined safety shoe color range, to detect whether there is a color consistent with the safety shoe in the ROI detection area, and a mask is created using the HSV color range, and the marked pixels in the HSV color range are:

[0012]

[0013] The marked pixels of the mask are determined by checking whether there are pixel values greater than zero in the mask, to determine whether the pixels belonging to the specified HSV color range are detected in the ROI detection area, if the pixels meeting the conditions are detected, it is determined that safety shoes are worn, and if the pixels meeting the conditions are not detected, it is determined that safety shoes are not worn.

[0014] Further, according to the color analysis result, it is judged whether there is a safety shoe in the ROI detection area, and the detection result is comprehensively evaluated in combination with the confidence of the ankle position coordinates, and the information of wearing safety shoes is output, including whether to wear and the position information of the wearer.

[0015] The safety shoe rapid detection method based on deep learning and color analysis disclosed in the present application can maintain high detection accuracy under low-quality video conditions by combining human posture recognition technology and color feature analysis method, and uses target detection and posture estimation model for target detection and posture estimation, to ensure rapid positioning of personnel and ankle, and reduce unnecessary consumption of computing resources.

[0016] The color range of the safety shoe is determined in the HSV color space, which can more accurately identify the safety shoe and reduce false positives and false negatives, and since a combination of multiple technologies and strategies is adopted, the present application shows good adaptability in different environments. BRIEF DESCRIPTION OF DRAWINGS

[0017] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the following briefly introduces the drawings required for use in the embodiments or the description of the prior art. Obviously, the drawings described below are only some embodiments recorded in this application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative work.

[0018] Figure 1 This is a flow chart of the method for rapid detection of safety shoes based on deep learning and color analysis of the present invention. Figure 2 The detection diagram in the embodiment of the present invention is Figure 3 The detection diagram in the embodiment of the present invention is DETAILED DESCRIPTION In order to enable those skilled in the art to better understand the solutions of the present invention, the technical solutions 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 embodiments described are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without making creative efforts should fall within the scope of protection of the present invention.

[0019] like Figure 1 As shown, the present invention provides a fast detection method for safety shoes based on deep learning and color analysis, comprising the following steps: S01: Obtain a human posture dataset and randomly divide it into a training set, a validation set, and a test set in a ratio of 8:1:1; S02: Pre-train the training set and validation set in S01 using a target detection and posture estimation model to obtain personnel positioning information and key point information.

[0020] The S02 step further includes: S021: Using the training set to train the target detection and pose estimation model; The gradient descent method involved in the training process is expressed as the formula:

[0021] in, Indicates the The parameter value at the iteration, Indicates the The parameter value at the iteration, is the learning rate, which controls the step size of parameter update, Represents the loss function In the parameters About a single training example gradient.

[0022] S022: Using the validation set to evaluate and adjust the performance of the trained model; S023: Use the test set to verify the performance of the final model.

[0023] S03: Acquire color data of the safety shoes and determine the color range of the safety shoes in the HSV color space; S031: Collect color data of safety shoe samples; S032: Analyze the color data in the HSV color space to determine the color range of the safety shoes; S033: Establish a database of safety shoe color ranges for use in subsequent testing.

[0024] S04: Obtaining a video stream and performing preprocessing. The S04 step further includes: S041: Obtain a low-quality video stream, where the video stream includes but is not limited to a video captured by a surveillance camera; S042: Preprocessing the video stream, such as image cropping, to improve the accuracy of subsequent detection; S043: Input the pre-processed video stream to the subsequent step to detect the safety shoes.

[0025] S05: Utilize the target detection and posture estimation model trained in S02 to infer the video stream in S04, and locate the ankle coordinates and confidence.

[0026] The S05 step further includes: S051: using the target detection and posture estimation model trained in S02 to infer the video stream in S04, and performing a non-maximum suppression algorithm to obtain usable information; S052: Locate the coordinates of the ankle in the input frame of the video stream in step S04; S053: Calculate the confidence level of the ankle coordinates.

[0027] S06: With the ankle coordinates in S05 as the center of the circle, using the safety shoe color range determined in S03, detect whether there is a color consistent with the safety shoe within a specified radius.

[0028] The step S06 further includes: S061: defining a rectangular area with a specified radius using the ankle coordinates in S05 as the center; Let the image be I , the center point coordinates are ( x c ,y c ), the detection radius is r , the lower limit of the HSV color range is , the upper limit of the HSV color range is The detection area ROI can be approximated by a rectangle, the coordinate range of which is determined by the center point and the radius.

[0029]

[0030] where H and W are the height and width of the image, respectively.

[0031] S062: In the circular region, color analysis is performed using the safety shoe color range determined in S03; S063: Detecting whether there is a color consistent with safety shoes in the circular region.

[0032] An HSV color range is used to create a mask that marks the pixels within the HSV color range.

[0033]

[0034]

[0035] where Mask is the marked pixel of the mask, and whether there is a pixel value greater than zero in the mask is checked, that is, whether there is a pixel belonging to the HSV color range.

[0036] S07: Combining the color analysis result in S06 with the ankle position confidence in S05, the video stream in S04 is accurately detected for safety shoes to obtain information about wearing safety shoes.

[0037] The S07 step further comprises: S071: According to the color analysis result in S06, it is judged whether there is a safety shoe in the circular region; S072: Combining the confidence of the ankle position coordinates in S05, the detection result is comprehensively evaluated; S073: Output the information about wearing safety shoes, including but not limited to whether to wear, the position of the person wearing, etc.

[0038] Embodiment 1 As Figure 2As shown, in order to detect safety shoes, the sample color data of the safety shoes is obtained through the color of the safety shoes, and the color range of the safety shoes is determined in the HSV color space. The collected color data is used to establish a database of the color range of the safety shoes. The video stream is acquired and preprocessed, including image cropping and other steps, to improve the accuracy of detection. Then, the preprocessed video stream is input into the trained model for inference to locate the ankle position coordinates and confidence. With the ankle position coordinates as the center, the color range of the safety shoes is determined to detect whether there is a color consistent with the safety shoes within the specified radius. The detection area can be approximated by a rectangle, and color analysis is performed in this area. Combining the color analysis result with the ankle position confidence, the video stream is accurately detected for safety shoes. The experimental results are shown in the figure. Figure 2 and Figure 3 The safety shoe detection effect under different backgrounds and postures is shown. It can be seen that the model can accurately locate the posture of the personnel and identify the position and state of the safety shoes.

[0039] The above-mentioned embodiment numbers of the present application are only for description, not representing the advantages and disadvantages of the embodiments. In the above-mentioned embodiments of the present application, the description of each embodiment has its own emphasis, and the parts not described in detail in a certain embodiment can be referred to the related description of other embodiments. In the several embodiments provided in the present application, it should be understood that the disclosed technical contents can be realized by other ways.

[0040] Finally, it should be pointed out that: the above embodiments are only used to illustrate the technical solutions of the present application, and not to limit them; although the present application has been described in detail with reference to the above embodiments, those skilled in the art should understand that: it can still modify the technical solutions recorded in the above embodiments, or make equivalent replacement for part or all of the technical features; and these modifications or replacements do not make the essence of the corresponding technical solutions deviate from the scope of the technical solutions of the embodiments of the present application.

Claims

1. A fast safety shoe detection method based on deep learning and color analysis, characterized in that include: Obtain a human posture dataset and randomly divide it into a training set, a validation set, and a test set in a ratio of 8:1:1; Using the training set and the validation set to train the target detection and posture estimation models, and obtain personnel positioning information and key point information; Obtain the color data of the safety shoes and determine the color range of the safety shoes in the HSV color space; Obtain the video stream to be detected and perform preprocessing; Using the trained object detection and pose estimation model to infer the video stream, the ankle coordinates and confidence information are located; Taking the ankle coordinates as the center of the circle, the mask is checked for elements with pixel values ​​greater than zero to determine whether there are pixels belonging to the specified HSV color range in the ROI detection area. If pixels meeting the conditions are detected, it is determined that safety shoes are worn. If no pixels meeting the conditions are detected, it is determined that safety shoes are not worn.

2. The method for rapid safety shoe detection based on deep learning and color analysis according to claim 1, characterized in that: When training the object detection and pose estimation models using the training set: The object detection and pose estimation models are trained using the following gradient descent method: in, Indicates the The parameter value at the iteration, Indicates the The parameter value at the iteration, is the learning rate, which controls the step size of parameter updates, Represents the loss function In the parameters About a single training example The validation set is used to evaluate and adjust the performance of the trained model; the test set is used to verify the performance of the final object detection and pose estimation model.

3. The method for rapid safety shoe detection based on deep learning and color analysis according to claim 1, characterized in that: Color data of safety shoe samples are collected, the color data are analyzed in the HSV color space to determine the color range of the safety shoes, and a database of the color range of the safety shoes is established.

4. The method for rapid safety shoe detection based on deep learning and color analysis according to claim 3, characterized in that: Each frame of the video stream is input into the trained target detection and posture estimation model to extract the coordinates of the key points of the human skeleton. The ankle key points include the left ankle and the right ankle, and their positions are recorded as ; For each ankle key point, the heat map response intensity output by the neural network is used , the confidence score of the point is determined by the value corresponding to the maximum response position , the specific calculation formula is: in Indicates Central Region, used to enhance local confidence robustness; Use the non-maximum suppression (NMS) algorithm to filter all candidate ankle detection boxes and retain the confidence score The maximum result is output as the final ankle position.

5. The method for rapid safety shoe detection based on deep learning and color analysis according to claim 4, characterized in that: The specific method for judging whether safety shoes are worn is as follows: define a rectangular area with a specified radius with the ankle coordinates as the center; suppose the image is I , the center point coordinates are ( x c , y c ), the detection radius is r , set the lower limit of the HSV color range to , the upper limit of the HSV color range is , the detection area ROI is represented by a rectangle, and its coordinate range is determined by the center point and radius Where H and W are the height and width of the image, respectively. Within the ROI detection area, color analysis is performed using the determined safety shoe color range to detect whether there is a color consistent with the safety shoe within the ROI detection area. A mask is created using the HSV color range. The marked pixels of the mask in the HSV color range are: The marked pixels of the mask are checked to see if there are elements with pixel values ​​greater than zero in the mask. It is determined whether pixels belonging to the specified HSV color range are detected in the ROI detection area. If pixels that meet the conditions are detected, it is determined that safety shoes are worn. If no pixels that meet the conditions are detected, it is determined that safety shoes are not worn.

6. The method for rapid safety shoe detection based on deep learning and color analysis according to claim 5, characterized in that: Based on the color analysis results, it is determined whether there are safety shoes in the ROI detection area. Combined with the confidence level of the ankle coordinates, the detection results are comprehensively evaluated and the information of wearing safety shoes is output, including whether the shoes are worn and the location of the wearer.

Citation Information

Patent Citations

  • Safety helmet wearing detection method based on yov5 and attitude estimation

    CN115035088A

  • Three-dimensional target thermodynamic diagram generation method and device, storage medium and equipment

    CN115393811A

  • Well lid identification method, device and equipment and storage medium

    CN116523993A

  • Target positioning method based on monocular vision

    CN118710866A

  • Method, apparatus, and recording medium for estimating sales opportunity

    KR102807356B1