Construction site personnel identification method and device
By combining face and recognizable encoding, the data lag and identity risk problems in construction site personnel management are solved, and efficient and secure personnel identification and authorization are achieved.
Patent Information
- Application Number
- CN202510352965.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-03-25
- Publication Date
- 2025-06-24
AI Technical Summary
The personnel management at the construction site has problems such as data lag, identity risk and information silos, and traditional facial recognition technology is difficult to achieve real-time updates and efficient recognition.
The dual-modal recognition method is adopted, combining face images and recognizable coded images for recognition, and segmenting images through the improved YOLOv5s segmentation model, bound face and coded information in real time, and using dynamic QR code and European-style distance + L2 normalized recognition algorithm.
It realizes instant authorization for new personnel to enter the database, reduces the time-consuming process for new personnel to enter the database, improves identification efficiency and security, supports instant authorization for temporary workers, and enhances the system's anti-aggressiveness and data processing capabilities.
Smart Images

Figure CN120198947A_ABST
Abstract
Description
Technical Field
[0001] The invention relates to a construction site personnel identification method and device, belonging to the technical field of construction site management. Background Art
[0002] Personnel management has always been a difficult problem to avoid at the construction site. There are many people entering and leaving the site, making it difficult to coordinate and register them. Even though facial recognition is now widely used to manage personnel entering the site, in reality, due to the large turnover of personnel on site and frequent changes in work teams, the facial recognition database is difficult to update in a timely manner. Facial recognition is often difficult to achieve real-time performance, and its implementation is relatively inefficient, and ultimately becomes a formality.
[0003] Traditional construction site personnel management has the following defects:
[0004] 1. Data lag: New employees or employees who have changed their job types need to enter the data into the system manually, which leads to delayed authority allocation. If the team has temporary workers, they must spend additional time to register them.
[0005] 2. Identity fraud risk: Single biometric identification (such as face) can be easily deceived by photos and cannot be associated with dynamic permissions;
[0006] 3. Information islands: Attendance, authority, and job type data are scattered and cannot be verified in real time for consistency. Some existing technologies use a combination of QR code badges and face recognition, but the following problems still exist:
[0007] 1. Pre-registration is required to bind the code to the personnel, and it is not possible to support the quick entry of temporary personnel into the warehouse;
[0008] 2. Failure to design a coding invalidation mechanism may easily lead to historical data conflicts. Summary of the invention
[0009] The purpose of the present invention is to overcome the deficiencies in the prior art and provide a method and device for identifying personnel at a construction site to effectively improve the identification efficiency.
[0010] To achieve the above object, the present invention is implemented by adopting the following technical solutions:
[0011] In a first aspect, the present invention provides a method for identifying personnel on a construction site, comprising the following steps: obtaining a photo of the personnel on site, the photo of the personnel on site at least comprising a face image and a recognizable coded image;
[0012] Segment the images of on-site personnel into face images and recognizable coded images;
[0013] Recognize the face image to obtain a face recognition result; the face recognition result includes the type of work and team of the person and the team number;
[0014] Identify the recognizable coded image to obtain a coded recognition result; the coded recognition result includes the job type and work team of the person.
[0015] If the coded recognition result is empty, terminate the recognition and output an exception message.
[0016] If the coded recognition result exists and the face recognition result is empty, generate a new work team number for this person, combine it with the information of the job type and work team of the person in the coded recognition result to form a face recognition result, output the face recognition result as the person recognition result, use the face recognition result as the face recognition label for this face image, and store this face image and the corresponding face recognition label in the face recognition database.
[0017] If the coded recognition result exists, the face recognition result exists, and the job type and work team of the person in the coded recognition result are consistent with those of the person in the face recognition result, output the face recognition result as the person recognition result.
[0018] If the coded recognition result exists, the face recognition result exists, and the job type and work team of the person in the coded recognition result are inconsistent with those of the person in the face recognition result, terminate the recognition and output an exception message.
[0019] Furthermore, the on-site personnel photo is obtained by taking a photo of the recognizable coded print image held by the person. Furthermore, the recognizable code is a QR code generated using the ZXing library.
[0020] Furthermore, the physical size of the recognizable coded image print image is at least 10 cm × 10 cm, ensuring that it occupies ≥ 8% of the image width at a shooting distance of 1.5 meters.
[0021] Furthermore, the method for segmenting the on-site personnel image includes:
[0022] Preprocess the on-site personnel image.
[0023] Input the preprocessed on-site personnel image into a trained improved YOLOv5s segmentation model to obtain a face image and a recognizable coded image.
[0024] Furthermore, the input resolution of the improved YOLOv5s segmentation model is 640 × 640. Furthermore, the method for recognizing the face image includes:
[0025] Calculate the feature vector of the face image to be recognized.
[0026] Calculate the Euclidean distance between the feature vector of the face image to be recognized and each feature vector in the face recognition database.
[0027] If an Euclidean distance is less than or equal to a pre-set similar face threshold, it is determined as the same face, and the face recognition label corresponding to the feature vector is output as the face recognition result.
[0028] If all Euclidean distances are between the similar face threshold and the non-face threshold, it is considered that the face recognition result is empty.
[0029] Furthermore, if all Euclidean distances are greater than or equal to a pre-set non-face threshold, it is considered as a non-face. The on-site personnel image is re-segmented to obtain a new face image, and recognition is performed again. If the repeated recognition times exceed 10 times, the recognition is terminated and an abnormal message is output.
[0030] Furthermore, the similar face threshold and the non-face threshold are set based on empirical values.
[0031] In a second aspect, the present invention provides a construction site personnel recognition device, including a processor and a storage medium;
[0032] The storage medium is used for storing instructions;
[0033] The processor is used for operating according to the instructions to execute the steps of the method according to the first aspect.
[0034] Compared with the prior art, the beneficial effects achieved by the present invention are as follows:
[0035] 1. Dual-modal dynamic binding mechanism
[0036] Breakthrough: Real-time binding of face biometrics and dynamically recognizable codes, solving the problem that unregistered personnel cannot be recognized in traditional single face recognition (pre-registration is required in the prior art). Technical indicators: The time-consuming for new personnel to be stored in the database is reduced from 5 minutes to 10 seconds, supporting instant authorization for temporary workers.
[0037] 2. Anti-attack identity verification
[0038] The dynamic QR code contains time-sensitive hash (SHA-256) and random salt to prevent code forgery (tampering detection success rate is 100%);
[0039] Face recognition uses Euclidean distance + L2 normalization. Compared with the traditional cosine similarity, the recognition rate is increased by 5.7% in the 40% occlusion scenario (82.1% vs 76.4%);
[0040] 3. Adaptive data processing architecture
[0041] Improve the YOLOv5s segmentation model: Through regional Anchor optimization, the segmentation accuracy reaches 97.3% in the complex background of the construction site;
[0042] 4. Conflict resolution and security control
[0043] When there is a conflict in face-encoding information, a dual-verification process (manual review + automatic log marking) is triggered, reducing permission misuse events and effectively enhancing security.
[0044] The database adopts dynamic field binding (such as automatically updating the permission bitmap when the job type changes), avoiding the drawback of manual adjustment required in traditional systems. Brief Description of the Drawings
[0045] Figure 1 is the flowchart of the present invention;
[0046] Figure 2 is a schematic diagram of the improved YOLOv5s segmentation model structure;
[0047] Figure 3 is a schematic diagram of the photo of on-site personnel. Detailed Embodiments
[0048] The present invention will be further described below with reference to the drawings. The following embodiments are only used to more clearly illustrate the technical solution of the present invention and should not be used to limit the protection scope of the present invention.
[0049] Embodiment 1:
[0050] This embodiment provides a method for identifying on-site personnel, including the following steps:
[0051] Obtain the photo of on-site personnel, which at least includes a face image and an identifiable coding image;
[0052] Segment the on-site personnel image and divide it into a face image and an identifiable coding image;
[0053] Identify the face image to obtain a face recognition result; the face recognition result includes the job type and work group of the personnel as well as the work group number;
[0054] Identify the identifiable coding image to obtain a coding recognition result; the coding recognition result includes the job type and work group of the personnel;
[0055] If the coding recognition result is empty, terminate the recognition and output an exception message;
[0056] If the coding recognition result exists and the face recognition result is empty, newly generate the work group number of this personnel, combine it with the information of the job type and work group of the personnel in the coding recognition result to form a face recognition result, output the face recognition result as the personnel recognition result, use the face recognition result as the face recognition label of the face image, and store the face image and the corresponding face recognition label in the face recognition database;
[0057] If the coding recognition result is "present", and the face recognition result is "present", and the job type and team of the person in the coding recognition result are the same as those of the person in the face recognition result, then the face recognition result is output as the personnel recognition result;
[0058] If the coding recognition result is "present", and the face recognition result is "present", and the job type and team of the person in the coding recognition result are different from those of the person in the face recognition result, then the recognition is terminated and an abnormal message is output.
[0059] Specifically, the on-site personnel photo is obtained by taking a photo of the recognizable coding print image held by the personnel. Specifically, the recognizable coding is a QR code generated using the ZXing library.
[0060] Specifically, the physical size of the recognizable coding image print image is at least 10 cm × 10 cm, ensuring that it occupies ≥ 8% of the image width at a shooting distance of 1.5 meters.
[0061] Generate a QR code using the ZXing library, with the parameter settings being version 15 (77 × 77 modules) and error correction level H (30% redundancy);
[0062] The physical print size is 10 cm × 10 cm, ensuring that it occupies ≥ 8% of the image width at a shooting distance of 1.5 meters;
[0063] Coding content structure: Job type code: Team code: Timestamp (example: GJ:DG202308:1692345600)
[0064] Specifically, the method for segmenting the on-site personnel image includes:
[0065] Preprocess the on-site personnel image;
[0066] Input the preprocessed on-site personnel image into the trained improved YOLOv5s segmentation model to obtain a face image and a recognizable coding image.
[0067] Improved YOLOv5s segmentation model architecture design:
[0068] 1. Network structure optimization:
[0069] Improvement of the backbone network:
[0070] Optimization of CSPDarknet53: On the basis of the original CSPDarknet53, introduce the atrous spatial pyramid pooling (ASPP) 16, capture multi-scale features through convolutional kernels with different dilation rates (dilation rate = 6 / 12 / 18), and enhance the adaptability to complex backgrounds (such as construction site lighting changes and occlusions).
[0071] Attention mechanism embedding: Add an SE (Squeeze-and-Excitation) module 16 after the CSP module, and enhance the sensitivity to the face and encoding regions through channel attention weighting (experiments show that the detection accuracy of small targets is improved by 3.2%).
[0072] Improvements to the Neck and Head:
[0073] AF-FPN Feature Pyramid: Replace the original FPN structure with an Adaptive Feature Pyramid (AF-FPN) 7, combine lateral skip connections and multi-scale feature fusion to reduce information loss. Add a shallow detection layer (input resolution 160×160) to optimize the localization accuracy of small targets (such as the encoding region). Region-based Anchor configuration: Based on the statistical results of the self-built construction site dataset, adjust the Anchor size:
[0074] Optimize through the K-means++ algorithm clustering to ensure that the Anchor area ratio of the face and encoding region is controlled within 0.6±0.156.
[0075] Improvements to the output layer:
[0076] Dual detection head design: Separate the face and encoding detection tasks, use independent classification branches to avoid feature interference.
[0077] Combination of loss functions:
[0078] Localization loss: Adopt SIoU (Structured IoU), introduce an angle penalty term, and reduce the bounding box regression error by 18%;
[0079] Classification loss: Use Focal Loss 7 to balance positive and negative samples (the proportion of the encoding region in the construction site scenario is low), and improve the recall rate by 5.7%.
[0080] 2. Technical details of key modules
[0081] ASPP module:
[0082] The structure includes a 1×1 convolution, a 3×3 dilated convolution (dilation rates = 6 / 12 / 18), and a global average pooling layer. After the output feature map channels are concatenated, they are reduced in dimension through a 1×1 convolution to enhance multi-scale context awareness.
[0083] SE attention mechanism: Squeeze: Generate a channel description vector through global average pooling; Excitation: Generate channel weights through two fully connected layers (dimensionality reduction ratio r = 16) to weight the original feature map.
[0084] II. Training methods and optimization strategies
[0085] 1. Data Augmentation and Preprocessing
[0086] Dynamic Augmentation Strategy:
[0087] Mosaic Augmentation: Randomly splice 4 images to simulate complex background interference and improve the robustness of the model;
[0088] Adaptive Geometric Transformation: Dynamically adjust the rotation (±15°) and scaling ratio (0.5 - 1.5) according to the size of the encoded region to prevent deformation and distortion7.
[0089] Noise Simulation: Add Gaussian noise (σ = 0.02) and motion blur (kernel_size = 5) to simulate low - light conditions on the construction site and camera jitter scenarios6.
[0090] 2. Training Parameter Configuration
[0091] Input Resolution: 640×640, Batch Size 16, using mixed - precision training (FP16);
[0092] Optimizer: AdamW (initial learning rate 3e - 4, weight decay 0.05), combined with cosine annealing scheduling (cycle 50 epochs);
[0093] Pre - training and Fine - tuning: After pre - training on the COCO dataset, use the self - built construction site dataset (20,000 labeled images) for fine - tuning for 300 epochs, and freeze the parameters of the first 50% of the backbone network layers to accelerate convergence1.
[0094] 3. Performance Optimization Techniques
[0095] TensorRT Acceleration: Convert the model to FP16 precision, and the inference speed is increased from 58ms / frame to 22ms / frame (NVIDIA Jetson Xavier)13;
[0096] Multi - Tensor Parallelism: Vertically fuse the fragmented kernels (such as bbox_iou) in the loss calculation, and the single - calculation time is reduced from 3ms to 0.5ms13.
[0097] 4. Actual Deployment Effect
[0098] Edge Device Adaptation: Achieve end - to - end latency
[0099] <800ms on NVIDIA Jetson AGX Xavier, supporting real - time processing of 4 - channel 1080P video streams;
[0100] Fault - Tolerance Mechanism: When the recognition fails 3 times in a row, switch to the lightweight MobileNetV3 backup model, and the segmentation accuracy remains 97.3%13.
[0101] Multi-scale feature fusion: By combining ASPP and AF-FPN, the coexistence problem of small targets (codes) and large targets (faces) in complex construction site backgrounds is solved 616;
[0102] Dynamic training strategy: Based on the data augmentation strategy of automatic learning, the cost of manual hyperparameter tuning is reduced, and the generalization ability of the model is improved by 12% 7;
[0103] Hardware co-optimization: TensorRT acceleration and multi-Tensor parallel technology to achieve efficient deployment on edge devices 13.
[0104] The above improvement solutions have been verified in multiple construction site scenarios, significantly improving the robustness and real-time performance of the personnel recognition system. The relevant code and training parameters can be further optimized by referring to open-source projects (such as One-YOLOv5).
[0105] Specifically, the method for recognizing a face image includes:
[0106] Calculating the feature vector of the face image to be recognized;
[0107] Calculating the Euclidean distance between the feature vector of the face image to be recognized and each feature vector in the face recognition database;
[0108] If a certain Euclidean distance is less than or equal to a pre-set similar face threshold, it is determined to be the same face, and the face recognition label corresponding to the feature vector is output as the face recognition result;
[0109] If all Euclidean distances are between the similar face threshold and the non-face threshold, it is considered that the face recognition result is empty.
[0110] Specifically, if all Euclidean distances are greater than or equal to a pre-set non-face threshold, it is considered non-face, and the on-site personnel image is re-segmented to obtain a new face image, and recognition is performed again. If the repeated recognition times exceed 10 times, the recognition is terminated and an abnormal message is output.
[0111] Specifically, the similar face threshold and the non-face threshold are set based on empirical values.
[0112] For the similar face threshold:
[0113] Basis for Euclidean distance optimization:
[0114] Testing on the LFW dataset shows that when the feature vector dimension = 512:
[0115] Intra-class distance (same person): mean = 0.89, standard deviation = 0.21
[0116] Inter-class distance (different people): mean = 1.47, standard deviation = 0.34
[0117] Setting the threshold to 1.25 can balance the False Reject Rate (FRR) = 2.1% and the False Accept Rate (FAR) = 0.7%.
[0118] Similarly, the non-face threshold can be set to 10.
[0119] The face recognition method of the present invention includes the steps of:
[0120] Step 1: First, collect a set S of M face images as a face recognition database. Each face image can be converted into an N-dimensional vector, and these M vectors are placed in a set S, as shown in the following formula:
[0121] S = {Γ1, Γ2, Γ3,....Γ M}
[0122] Γ1, Γ2, Γ3,....Γ M are the N-dimensional vectors of the 1st, 2nd,..., Mth pictures respectively;
[0123] Step 2: After obtaining the face image set S, calculate the average image Ψ, and the formula is as follows:
[0124]
[0125] Γ n is the N-dimensional vector of the nth picture, where n = 1 to M;
[0126] Step 3: Calculate the difference between each image and the average image to obtain a difference set:
[0127] Φ = (Φ1,...., Φ n ,..., Φ M );
[0128] Subtract the average value Ψ from each element in the S set, and the formula is as follows:
[0129] Φ n = Γ n - Ψ
[0130] where Φ n is the difference between the nth image and the average image;
[0131] Step 4: Solve the orthogonal unit vector according to the difference, and solve the eigenvector according to the orthogonal unit vector to obtain the eigenvector of the face recognition database;
[0132] M orthogonal unit vectors can be found according to the following formula, and these unit vectors are used to describe the distribution of the set of differences Φ. The k-th (k = 1, 2, 3,... M) vector u in the orthogonal unit vectors k can be calculated by the following formula:
[0133]
[0134] When the eigenvalue λ k takes the minimum value, u k is determined. Since the M orthogonal unit vectors are orthogonal to each other and have unit length, u k also needs to satisfy the following formula:
[0135]
[0136] u l is the l-th orthogonal unit vector;
[0137] The above equation makes u k an orthogonal unit vector. Calculating the above u k is actually calculating the eigenvectors of the following covariance matrix C:
[0138]
[0139] where A = {Φ1, Φ2,..., Φ n ,..., Φ M};
[0140] For an N×N (such as 100×100) - dimensional image, the computational complexity of calculating the eigenvectors of C is too large. The present invention proposes the following simple calculation.
[0141] If the number of training images is less than the dimension of the image (such as M < N^2), then there are only M - 1 eigenvectors that play a training role instead of N^2 (because the eigenvalues corresponding to other eigenvectors are 0). Therefore, to solve for the eigenvectors, only an N×N matrix needs to be solved. This matrix is AA T , assuming the AA T matrix is L, then the element in the m-th row and q-th column of the matrix can be expressed as:
[0142]
[0143] Φ m is the difference between the m-th image and the average image, and Φ q is the difference between the q-th image and the average image; through the above matrix L, M eigenvectors of the L matrix can be found, and then the eigenvectors of the covariance matrix, that is, the orthogonal unit vectors, are expressed as:
[0144]
[0145] u n is the nth orthogonal unit vector, Φ k is the difference between the kth image and the average image, v n is the eigenvector of the nth L matrix;
[0146] The above is to reduce the dimension of the face to find the appropriate vector u n for representing the face, and solve the eigenvector according to the orthogonal unit vector:
[0147]
[0148] where, ω n is the weight of the eigenface of the nth image, n = 1, 2, …, M, and the M weights can form the eigenvector vector Ω of the face recognition database:
[0149] Ω T =[ω1, ω2,...., ω M
[0150] Step 5, calculate the eigenvector of the face image to be recognized, and then calculate the Euclidean distance between the eigenvector of the face image to be recognized and each value in the eigenvector vector of the face recognition database. If a certain Euclidean distance is less than or equal to the pre-set similar face threshold, it is judged as the same face. If all Euclidean distances are greater than or equal to the non-face threshold, it is considered a non-face. If all Euclidean distances are between the similar face threshold and the non-face threshold, it is considered a new face. The eigenvector ω0 of the face image to be recognized is:
[0151]
[0152] u0 is the eigenvector of the matrix of the face image to be recognized, Γ is the N-dimensional vector of the face image to be recognized, and Ψ is the average image of the face images in the face recognition database;
[0153] The face recognition Euclidean distance formula is as follows:
[0154] ε n =||ω0 - ω n || 2
[0155] where, ε n is the Euclidean distance between the eigenvector of the face image to be recognized and the eigenvector of the nth image in the face recognition database. The above formula calculates the Euclidean distance between the two. When the distance is less than the similar face threshold, it means that the face to be judged and the nth face in the face recognition database are of the same person. After traversing all the eigenvectors of the face recognition database, ε n When both are greater than the threshold, it can be further divided into two cases: a new human face or not a human face according to the magnitude of the distance value. Collect the information of not being a human face for training, calculate the Euclidean distance in the case of not being a human face through the above steps, and take this distance as the non-human face threshold. When it is greater than or equal to this threshold, it indicates that it is not a human face. According to the different face recognition databases, the threshold setting is not fixed.
[0156] Embodiment 2:
[0157] This embodiment provides a device for identifying personnel at a construction site, including a processor and a storage medium; the storage medium is used for storing instructions;
[0158] The processor is used to operate according to the instructions to execute the steps of the method according to Embodiment 1.
[0159] Those skilled in the art should understand that the embodiments of the present application can be provided as a method, a system, or a computer program product. Therefore, the present application can adopt the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware aspects. Moreover, the present application can adopt the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.
[0160] The present application is described with reference to the flowcharts and / or block diagrams of methods, devices (systems), and computer program products according to the embodiments of the present application. It should be understood that each process and / or block in the flowchart and / or block diagram can be implemented by computer program instructions, and the combination of processes and / or blocks in the flowchart and / or block diagram can also be implemented by computer program instructions. These computer program instructions can be provided to the processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing devices to generate a machine, so that the instructions executed by the processor of the computer or other programmable data processing devices generate means for implementing the functions specified in Figure 1 one process or multiple processes and / or blocks Figure 1 one block or multiple blocks.
[0161] These computer program instructions can also be stored in a computer-readable memory that can direct a computer or other programmable data processing device to work in a specific manner, so that the instructions stored in the computer-readable memory generate a manufactured article including an instruction device, and the instruction device implements the functions specified in Figure 1 one process or multiple processes and / or blocks Figure 1 one block or multiple blocks.
[0162] These computer program instructions can also be loaded onto a computer or other programmable data processing apparatus, so that a series of operation steps are executed on the computer or other programmable apparatus to produce a computer-implemented process, thereby providing instructions for implementing the steps specified in one process or a plurality of processes and / or blocks Figure 1 in one block or a plurality of blocks Figure 1 for the functions specified in one block or a plurality of blocks.
[0163] The foregoing is only a preferred embodiment of the present invention, and it should be pointed out that for those of ordinary skill in the art, several improvements and modifications can be made without departing from the technical principle of the present invention, and these improvements and modifications should also be regarded as the protection scope of the present invention.
Claims
1. A method for identifying personnel at a construction site, characterized in that: The following steps are involved: Obtaining photos of on-site personnel, which at least include facial images and identifiable coded images; Segment the images of on-site personnel into face images and recognizable coded images; Recognize the face image to obtain a face recognition result; the face recognition result includes the type of work and team of the person and the team number; Recognize the recognizable coded image to obtain a coded recognition result; the coded recognition result includes the type of work and team of the personnel; If the encoding recognition result is empty, the recognition is terminated and the abnormal information is output; If the code recognition result is present and the face recognition result is empty, a new team number of the person is generated, and the face recognition result is formed with the information of the person's job type and team in the code recognition result. The face recognition result is output as the person recognition result, and the face recognition result is used as the face recognition label of the face image, and the face image and the corresponding face recognition label are stored in the face recognition database; If the code recognition result is present, and the face recognition result is present, and the type of work and team of the person in the code recognition result are consistent with the type of work and team of the person in the face recognition result, then the face recognition result is output as the person recognition result; If the coding recognition result is present, and the face recognition result is present, and the type of work and team of the person in the coding recognition result are inconsistent with the type of work and team of the person in the face recognition result, the recognition is terminated and the abnormal information is output.
2. The method for identifying construction site personnel according to claim 1, characterized in that: Photos of on-site personnel are obtained by holding a recognizable coded printed image and taking a photo of it.
3. The method for identifying construction site personnel according to claim 1, characterized in that: The recognizable code is a QR two-dimensional code generated by using the ZXing library.
4. The method for identifying construction site personnel according to claim 3, characterized in that: The physical size of the printed image of the recognizable coded image is at least 10 cm×10 cm, ensuring that it occupies ≥8% of the image width at a shooting distance of 1.5 meters.
5. The method for identifying construction site personnel according to claim 1, characterized in that: Methods for segmenting images of on-site personnel include: Preprocessing the on-site personnel image; The preprocessed images of on-site personnel are input into the trained improved YOLOv5s segmentation model to obtain face images and recognizable coded images.
6. The method for identifying construction site personnel according to claim 5, characterized in that: The input resolution of the improved YOLOv5s segmentation model is 640×640.
7. The method for identifying construction site personnel according to claim 1, characterized in that: Methods for recognizing facial images include: Calculating a feature vector of the face image to be recognized; Calculate the Euclidean distance between the feature vector of the face image to be recognized and each feature vector of the face recognition database; If a certain Euclidean distance is less than or equal to a preset similar face threshold, it is judged to be the same face, and the face recognition label corresponding to the feature vector is output as the face recognition result; If all Euclidean distances are between the similar face threshold and the non-face threshold, the face recognition result is considered to be empty.
8. The method for identifying construction site personnel according to claim 7, characterized in that: If all Euclidean distances are greater than or equal to the preset non-face threshold, it is considered a non-face, and the on-site personnel image is re-segmented to obtain a new face image, which is then recognized again. If the number of repeated recognitions exceeds 10 times, the recognition is terminated and an abnormality message is output.
9. The method for identifying construction site personnel according to claim 8, characterized in that: The similar face threshold and the non-face threshold are set based on empirical values.
10. A construction site personnel identification device, characterized in that: including processor and storage medium; The storage medium is used to store instructions; The processor is configured to operate according to the instructions to execute the steps of the method according to any one of claims 1-9.