Unmanned aerial vehicle logistics distribution method based on face recognition and related equipment
By improving the YOLOv8 model and edge-cloud collaborative architecture, the problems of misidentification and computing resource limitations in identity authentication in drone logistics and delivery systems were solved, achieving high-precision, real-time user identity authentication and cargo delivery.
Patent Information
- Application Number
- CN202510709973.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-05-29
- Publication Date
- 2025-10-03
AI Technical Summary
Existing drone logistics and delivery systems have problems with misidentification and insufficient security in user authentication, and limited computing resources make it difficult to achieve high-precision identification and real-time interaction.
An improved YOLOv8 model is adopted, an adaptive feature fusion module is embedded, and the shallow detection head is deleted. Combined with the edge-cloud collaborative architecture, multi-scale feature fusion and lightweight design are used to improve detection accuracy and reduce computational complexity.
It significantly improves the identity authentication performance of drones in dynamic scenarios, achieves high-precision robust detection and real-time requirements, and reduces computational complexity and resource utilization.
Smart Images

Figure CN120746411A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of drone logistics and delivery, and in particular to a drone logistics and delivery method based on face recognition and related equipment. Background Art
[0002] With the rapid development of e-commerce and the logistics industry, traditional human delivery models are facing bottlenecks such as low efficiency, high costs, and limited coverage in remote areas, high-density cities, and specialized scenarios. Drone delivery, with its flexibility, unrestricted terrain routes, and rapid response times, has become a key technology for addressing the "last mile" problem. However, existing drone delivery systems generally utilize fixed receiving stations, with goods only delivered to designated locations and requiring users to collect them themselves, failing to achieve true "direct delivery." This limitation limits the user experience, particularly in urgent deliveries and privacy-critical scenarios, and fails to meet the demands of precise and personalized logistics.
[0003] In drone terminal interaction technology, vision-based identity authentication is the core link to achieve direct delivery. Existing solutions mostly rely on simple human posture detection or positioning technology, lack high-precision verification of user identity, and have problems such as misidentification and insufficient security. Although deep learning-based face detection algorithms perform well in static scenes, in the dynamic environment of drones, the detection accuracy of target faces often drops significantly due to factors such as flight altitude, lighting changes, and multi-scale features. The traditional YOLOv8 model constructs a feature extraction network by stacking Bottleneck modules, but the single-scale feature fusion mechanism cannot effectively capture multi-level information in complex scenes, which limits the model's generalization ability from the drone's perspective. In addition, the computing resources of drone edge devices are limited, and the contradiction between the high computational complexity of the original model and the real-time requirements further restricts the actual deployment effect.
[0004] On the other hand, existing systems often rely on pure edge computing or pure cloud processing architectures. The former, limited by hardware computing power, struggles to support high-precision recognition, while the latter, due to network latency, cannot meet the demands of real-time interaction. The key to overcoming the bottleneck in drone precision delivery technology is to improve computational efficiency while maintaining detection accuracy through lightweight model design, multi-scale feature optimization, and edge-cloud collaboration. Summary of the Invention
[0005] The technical problem to be solved by the present invention is: a drone logistics distribution method and related equipment based on face recognition, aiming to ensure the drone detection accuracy while improving computing efficiency.
[0006] In order to solve the above technical problems, the technical solution adopted by the present invention is: a drone logistics distribution method based on face recognition, comprising the steps of:
[0007] S10. Requesting the cloud server to download the pre-stored consignee registration information through the edge device carried by the drone, where the registration information includes at least facial feature data and delivery authority information;
[0008] S20: Based on the preset delivery route planning, control the drone to deliver the goods to the target geographic location and trigger the camera to capture the user's posture;
[0009] S30. After detecting the user's posture, perform face detection using an improved YOLOv8 model, wherein the improvement includes embedding an adaptive feature fusion module in the Bottleneck module and deleting a shallow detection head.
[0010] S40, transmitting the detected facial image to the cloud server, calling the pre-trained facial recognition API to perform feature vector comparison, and generating an identity verification result;
[0011] S50. Based on the identity verification result, the drone is controlled to land at the consignee's location and an interactive interface for a QR code or verification code is activated to complete the cargo handover.
[0012] S60: After the delivery task is completed, the feedback data including the timestamp, geographic location and handover status is integrated and sent back to the cloud server to update the order status in the logistics management system.
[0013] Furthermore, the improved YOLOv8 model in step S30 includes:
[0014] In the CSPLayer_2Conv module of the Backbone network, the Bottleneck structure is replaced by an adaptive feature fusion module that integrates a multi-scale channel attention mechanism. The adaptive feature fusion module achieves adaptive aggregation of cross-scale features through weight fusion of global average pooling and local point-by-point convolution branches, and generates an attention weight matrix based on the channel dimension.
[0015] Furthermore, the improved YOLOv8 model in step S30 also includes:
[0016] The shallow detection head of the original YOLOv8 model is deleted, and the middle and high-level dual detection head structure is retained; the middle-level detection head corresponds to a 40x40 feature map, and the high-level detection head corresponds to a 20x20 feature map. In the post-processing stage, differentiated confidence thresholds and weighted non-maximum suppression strategies are adopted.
[0017] Furthermore, the training process of the improved YOLOv8 model includes:
[0018] In the data preprocessing stage, the input image is subjected to aspect ratio-preserving grayscale filling and HSV color perturbation enhancement;
[0019] During the forward propagation of the model, the adaptive feature fusion module dynamically assigns weights to the multi-branch features of the Bottleneck layer, and optimizes the balance between classification and regression tasks based on the Focal Loss function.
[0020] After training is completed, knowledge distillation technology is used to compress the model into a lightweight version to adapt to the computing resource limitations of edge devices.
[0021] Furthermore, step S30 further includes:
[0022] The improved YOLOv8 model is subjected to vertical layer fusion and horizontal quantization processing through the TensorRT acceleration engine, including:
[0023] Convert the trained model to ONNX format and build an INT8 quantization calibration dataset;
[0024] Perform dynamic range quantization in the TensorRT engine, convert the convolutional layer weights to 8-bit integers, and perform dequantization on the output layer to restore accuracy;
[0025] Generate optimized .engine file.
[0026] Furthermore, the face recognition process of the cloud server in step S40 includes:
[0027] Call the pre-trained ArcFace deep model to extract the 512-dimensional feature vector of the face image;
[0028] The cosine similarity algorithm is used to compare the feature vectors with those in the registration database in real time. When the similarity exceeds the preset threshold, the authentication success instruction is triggered.
[0029] If recognition fails three times in a row, a repositioning command will be sent to the drone and the backup sound and light prompt module will be activated.
[0030] Furthermore, the feedback data including the timestamp, geographic location and handover status integrated in step S60 includes:
[0031] Establish a spatiotemporal correlation database on the cloud server and perform Kalman filtering and smoothing on the delivery trajectory data;
[0032] Generate regional heat maps based on historical delivery records and dynamically optimize the path planning weight parameters of subsequent drones.
[0033] The present invention also provides a drone logistics distribution device based on face recognition, comprising:
[0034] A registration information download module is used to request the cloud server to download the pre-stored consignee registration information through the edge device carried by the drone. The registration information includes at least facial feature data and delivery authority information;
[0035] The flight control module is used to control the drone to deliver the goods to the target location based on the preset delivery route planning, and trigger the camera to capture the user's posture;
[0036] A face detection module, configured to perform face detection using an improved YOLOv8 model after detecting a user's posture. The improvement includes embedding an adaptive feature fusion module in the Bottleneck module and removing the shallow detection head.
[0037] The identity recognition module is used to transmit the detected face image to the cloud server, call the pre-trained face recognition API to perform feature vector comparison, and generate the identity verification result;
[0038] The drone landing module is used to control the drone to land at the consignee's location based on the identity verification result, and activate the QR code or verification code interactive interface to complete the cargo handover;
[0039] The data feedback module is used to integrate feedback data including timestamp, geographic location and handover status and transmit it back to the cloud server after the delivery task is completed, thereby updating the order status in the logistics management system.
[0040] The present invention also provides a computer device, which includes a memory and a processor, wherein a computer program is stored in the memory, and when the processor executes the computer program, it implements the drone logistics distribution method based on face recognition as described in any one of the above items.
[0041] The present invention also provides a storage medium storing a computer program, which, when executed by a processor, can implement the drone logistics distribution method based on face recognition as described in any of the above items.
[0042] The beneficial effects of the present invention are: through the lightweight multi-scale feature fusion model and edge-cloud collaborative architecture, the identity authentication performance of drones in dynamic scenarios is significantly improved; the model introduces an adaptive feature fusion module and deletes the shallow detection head to achieve a significant improvement in detection accuracy and a significant reduction in false detection rate, effectively supporting robust detection of extremely small targets at long distances; through lightweight design and computational optimization strategies, the model's computational complexity and resource occupancy are significantly reduced, and efficient reasoning is achieved at the edge to meet real-time requirements. BRIEF DESCRIPTION OF THE DRAWINGS
[0043] The specific structure of the present invention is described in detail below with reference to the accompanying drawings.
[0044] Figure 1 This is a flow chart of a drone logistics distribution method based on face recognition according to an embodiment of the present invention;
[0045] Figure 2 This is a diagram of the Backbone structure of the YOLOv8 model according to an embodiment of the present invention;
[0046] Figure 3 This is a structural diagram of an AFF module embedded in a Bottleneck module according to an embodiment of the present invention;
[0047] Figure 4 This is a structural diagram of an AFF module according to an embodiment of the present invention;
[0048] Figure 5 This is a structural diagram of the MS-CAM module according to an embodiment of the present invention;
[0049] Figure 6 This is a structural diagram of the improved YOLOv8 model according to an embodiment of the present invention;
[0050] Figure 7 This is a YOLOv8 running data link diagram according to an embodiment of the present invention;
[0051] Figure 8 This is a schematic diagram of the TensorRT acceleration principle of an embodiment of the present invention;
[0052] Figure 9 This is a block diagram of a drone logistics distribution device based on face recognition according to an embodiment of the present invention;
[0053] Figure 10 A schematic block diagram of a computer device according to an embodiment of the present invention. DETAILED DESCRIPTION
[0054] The following will clearly and completely describe the technical solutions in the embodiments of the present invention in conjunction with the accompanying drawings. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of them. All other embodiments obtained by ordinary technicians in this field based on the embodiments of the present invention without making any creative efforts shall fall within the scope of protection of the present invention.
[0055] It will be understood that when used in this specification and the appended claims, the terms “comprises” and “comprising” indicate the presence of described features, integers, steps, operations, elements and / or components, but do not preclude the presence or addition of one or more other features, integers, steps, operations, elements, components and / or groups thereof.
[0056] It should also be understood that the terminology used in this specification is for the purpose of describing particular embodiments only and is not intended to limit the present invention. As used in the specification and appended claims, the singular forms "a," "an," and "the" are intended to include the plural forms unless the context clearly indicates otherwise.
[0057] It should be further understood that the term "and / or" used in the present description and the appended claims refers to and includes any and all possible combinations of one or more of the associated listed items.
[0058] like Figure 1 As shown, an embodiment of the present invention is: a drone logistics distribution method based on face recognition, comprising the steps of:
[0059] S10. Requesting the cloud server to download the pre-stored consignee registration information through the edge device carried by the drone, where the registration information includes at least facial feature data and delivery authority information;
[0060] S20: Based on the preset delivery route planning, control the drone to deliver the goods to the target geographic location and trigger the camera to capture the user's posture;
[0061] S30. After detecting the user's posture, perform face detection using an improved YOLOv8 model, wherein the improvement includes embedding an adaptive feature fusion module in the Bottleneck module and deleting a shallow detection head.
[0062] In a specific embodiment, the improved YOLOv8 model in step S30 includes:
[0063] like Figure 2 The following is a diagram of the Backbone network structure. Figure 3 Embed the AFF module structure diagram in the Bottleneck module. Figure 4 Figure 3 is the structural diagram of the AFF module. In the CSPLayer_2Conv module of the Backbone network, the Bottleneck structure is replaced with an adaptive feature fusion module that integrates a multi-scale channel attention mechanism. The adaptive feature fusion module achieves adaptive aggregation of cross-scale features through weight fusion of global average pooling and local point-by-point convolution branches, and generates an attention weight matrix based on the channel dimension.
[0064] In a specific embodiment, the improved YOLOv8 model in step S30 further includes:
[0065] The shallow detection head of the original YOLOv8 model is deleted, and the middle and high-level dual detection head structure is retained; the middle-level detection head corresponds to a 40x40 feature map, and the high-level detection head corresponds to a 20x20 feature map. In the post-processing stage, differentiated confidence thresholds and weighted non-maximum suppression strategies are adopted.
[0066] In this embodiment, the attention feature fusion module (AFF) is introduced into the Bottleneck module, the core component of the YOLOv8 model. The Bottleneck module is located in the CSPLayer_2Conv module in the Backbone layer. Figure 5 As shown, the attention feature fusion module uses the multi-scale channel attention mechanism (MS-CAM) to input features X, Y∈R C×H×W , output fusion feature Z∈R C×H×W .
[0067] Initial fusion, element-by-element addition by default:
[0068]
[0069] M=MS-GAM(S)#(2)
[0070]
[0071] The reasonable fusion of global and local feature contexts solves the inconsistency problem faced by traditional feature fusion methods in dealing with features of different scales, allowing YOLOv8 to better capture the detailed information of the target during detection. The multi-scale channel attention module (MS-CAM) involved refers to the realization of channel attention at multiple scales by changing the control pooling size. In order to keep it lightweight, the local context is only added to the global context inside the multi-scale channel attention module. The multi-scale channel attention module (MS-CAM) refers to the realization of channel attention at multiple scales by changing the control pooling size, using point-by-point (PWConv) as the context aggregator of the local channel, and utilizing the point-by-point channel interaction of each space. Input feature map Y∈R C×H×W , output attention weight matrix M∈R C×H×W
[0072] Global Average Pooling:
[0073] G(Y)=GAP(Y)#(4)
[0074] Sigmoid activation:
[0075]
[0076] Local branch:
[0077] L(Y)=β(PWConv2(δ(βPWConv(Y))))) (6)
[0078] in:
[0079] PWConv2:R C×H×W →R C / r×H×W
[0080] PWConv1:R C / r×H×W →R C×H×W
[0081] β is batch normalization, δ is ReLU activation, Addition for broadcasting.
[0082] By integrating the attention feature fusion module, the accuracy and stability of YOLOv8 can theoretically be significantly improved for objects with multi-scale features and complex scenes. Leveraging multi-scale feature fusion technology, the attention feature fusion module deepens its comprehensive understanding of image content, effectively improving both precision and recall. The attention feature fusion module's adaptive fusion weight adjustment mechanism facilitates smooth transitions between different scales and semantic features, significantly enhancing YOLOv8's generalization. This means the model maintains excellent performance even when faced with new datasets. Furthermore, the attention feature fusion module's design demonstrates versatility and compatibility, allowing for easy integration without requiring major adjustments to YOLOv8's Bottleneck module. This plug-and-play nature simplifies the improvement process, enabling simple deployment and testing. While pursuing detection accuracy, the attention feature fusion module also considers computational efficiency and resource consumption. By optimizing the attention mechanism, the improved YOLOv8 achieves a certain degree of performance improvement while maintaining real-time detection speed, achieving a dual optimization of performance and efficiency.
[0083] At the same time, considering the actual engineering application scenario, when the drone is performing logistics distribution, after detecting that the user's posture has dropped, the user is relatively close to the drone when performing face detection and recognition. This means that the user is not a small target for the drone's detection camera. Therefore, for the YOLOv8 model after inserting the AFF module, this patent considers cutting off a shallow detection head to further improve the speed and efficiency of detection and recognition while saving a certain amount of computing power to improve performance. Figure 6 shown.
[0084] The following is a detailed description of the modified YOLOv8-AFF model detection process, including the data flow changes after removing the shallow detection head and the module function description:
[0085] Input preprocessing, including:
[0086] Input image: The original image size is [H×W×3] (such as a 640×640×3 RGB image).
[0087] Normalization: Pixel values are linearly scaled from [0,255] to [0,1].
[0088] Fill and Scale: Maintain the aspect ratio, fill the short side to 640 pixels, scale the long side proportionally, and fill the excess area with grayscale values.
[0089] Data augmentation (training phase): random horizontal flipping, mosaic splicing, and HSV color space perturbation.
[0090] Backbone network (CSPDarknet53-AFF), including:
[0091] (1) Stem layer;
[0092] Operation: Fast downsampling via 3×3 convolution (stride 2) with SiLU activation function.
[0093] Input: [640×640×3] → Output: [320×320×64].
[0094] (2) CSPLayer_2Conv module (including AFF improvements);
[0095] Module structure:
[0096] Branch 1: 1×1 convolution (channel number 64→32) → 3×3 convolution (channel number 32→64) → AFF module.
[0097] Branch 2: Identity mapping.
[0098] Merge: The outputs of branch 1 and branch 2 are merged through channel concatenation.
[0099] Output features: [160×160×256] (features after enhancing multi-scale information).
[0100] (3) Multi-stage feature extraction;
[0101] Stage 1: [320×320×64] → output [160×160×128] (not embedded in AFF).
[0102] Stage 2: [160×160×128] → output [80×80×256] (embedded in AFF module).
[0103] Stage 3: [80×80×256] → output [40×40×512] (embedded in AFF module).
[0104] Stage 4: [40×40×512] → output [20×20×1024] (without AFF embedding).
[0105] 3. Neck network (PANet lightweight);
[0106] Function: Fusion of high-level semantic features and mid-level detail features.
[0107] The shallow (original 80×80 scale) feature fusion path is deleted, and only two scales are retained.
[0108] operate:
[0109] Top-down path:
[0110] High-level features [20×20×1024] are upsampled to 40×40 → concatenated with mid-level features [40×40×512] → output is [40×40×(512+1024)].
[0111] Bottom-up path:
[0112] The middle-level features [40×40×512] are downsampled to 20×20 → concatenated with the high-level features → output [20×20×(512+1024)].
[0113] Output feature map: two scales (originally deleted the shallow 80×80 detection head):
[0114] Middle-layer fusion features: [40×40×1536] (used for detecting medium and small targets).
[0115] High-level fusion features: [20×20×1536] (used for detecting large objects).
[0116] 4.Head network (dual detection heads);
[0117] Modification points: Delete the original shallow detection head (corresponding to the 80×80 feature map) and retain the following two:
[0118] Detection head 1: processes the [40×40×1536] feature map (original middle layer).
[0119] Detection head 2: Processes [20×20×1536] feature map (original high-level). Structure:
[0120] Classification branch: 1×1 convolution outputs category probabilities (e.g., 40×40×N, where N is the number of categories).
[0121] Regression branch: 1×1 convolution outputs bounding box coordinates (cx, cy, w, h) and confidence.
[0122] Output analysis (taking 40×40×1536 as an example):
[0123] Each grid predicts 3 anchor boxes, and the output dimension is 40×40×(3×(4+1+N)).
[0124] Sigmoid is used to process the coordinate offset, and Softmax is used to process the category probability.
[0125] 5. Post-processing (adaptive multi-scale NMS);
[0126] Confidence filtering:
[0127] Detection head 1 (middle layer): confidence threshold 0.4 (focuses on small objects).
[0128] Detection head 2 (high-level): confidence threshold 0.5 (focusing on large objects).
[0129] Scale-weighted NMS:
[0130] The prediction boxes of different detection heads are weighted according to their scale (0.6 for the middle layer and 0.4 for the high layer).
[0131] After merging, non-maximum suppression is performed according to the IoU threshold of 0.5.
[0132] Final output: The retained detection box format is [x1,y1,x2,y2,class_id,confidence].
[0133] The overall data link is as follows Figure 7 shown.
[0134] In a specific embodiment, the training process of the improved YOLOv8 model includes:
[0135] In the data preprocessing stage, the input image is subjected to aspect ratio-preserving grayscale filling and HSV color perturbation enhancement;
[0136] During the forward propagation of the model, the adaptive feature fusion module dynamically assigns weights to the multi-branch features of the Bottleneck layer, and optimizes the balance between classification and regression tasks based on the Focal Loss function.
[0137] After training is completed, knowledge distillation technology is used to compress the model into a lightweight version to adapt to the computing resource limitations of edge devices.
[0138] In this embodiment, a personal face dataset is selected to train the YOLO model. Based on the YOLOv8 target detection algorithm and the personal face dataset, accurate face detection and positioning can be achieved through deep learning technology. The system supports real-time detection of pictures, videos, and cameras. By using a certain number of face datasets for deep training, it is ensured that the system can significantly enhance generalization capabilities and have higher face detection accuracy. In the training process of the improved YOLOv8 model, first, the images in the training set are input into the model and undergo preprocessing steps such as scaling and normalization to meet the input requirements of the model. Then, the images are subjected to feature extraction through the improved YOLOv8 Backbone network. In the Bottleneck module, the AFF mechanism mentioned in the previous step is introduced for feature fusion. This mechanism effectively fuses global and local feature contexts through the multi-scale channel attention mechanism (MS-CAM), solving the semantic inconsistency problem faced by traditional feature fusion methods when processing features of different scales. The extracted features are then further processed and enhanced to prepare for classification and regression prediction. During training, loss functions are calculated based on the model's predictions and the true labels, including classification loss and regression loss. Backpropagation is then used to calculate gradients, and model parameters are updated accordingly. An optimizer (such as Adam or SGD) adjusts parameters such as the learning rate to accelerate training and improve model performance. After each training epoch, the model's performance is evaluated using a validation set. Based on the results, model parameters or the training strategy are adjusted, such as reducing the learning rate or increasing the number of training epochs, to ensure optimal performance. Two models were trained on the same dataset for comparison. Table 1 below shows the training results before and after the improvements.
[0139] Table 1: Comparison of relevant indicators before and after YOLOv8 model improvement
[0140]
[0141] The precision (P), recall (R), and average precision (mAP) mentioned here refer to:
[0142] The accuracy P formula is as follows:
[0143]
[0144] TP is a true positive, FP is a false positive, and P refers to the ratio of the target you want to the detected target.
[0145] The recall rate R formula is as follows:
[0146]
[0147] TP is a true positive example, FN is a false negative example, and R refers to how many of the desired targets are detected among the detected targets.
[0148] The average accuracy mAP formula is as follows:
[0149]
[0150] In the table, mAP(50) represents the average accuracy of the model when the IoU threshold is 50%; mAP(50-95) represents the average accuracy of the model when the IoU threshold ranges from 50% to 95%.
[0151] Comparing the above data, the model performance is significantly optimized after adding the AFF module, and the third model with further cropping of the gradient head has the most outstanding overall performance. The baseline model YOLOv8n has a precision (P) of 0.987, a recall (R) of 1, an mAP50-95 of 0.874, and a computational load of 8.1 GFLOPs. The overall performance is excellent but there is still room for improvement. After introducing the AFF module, the model's precision is improved to 0.995, the recall rate drops slightly to 0.987, and the mAP50-95 is improved to 0.891, with a slight increase in computational load to 8.2 GFLOPs. This shows that the AFF module enhances the ability to capture target details and reduces false positives (FP) through multi-scale feature fusion, thereby performing better in high-precision scenarios. In particular, the improvement in mAP50-95 verifies its ability to locate complex targets. It is worth noting that after cropping the gradient head, the third model's precision is further improved to a near-perfect 0.999, the recall rate is restored to 1, and the computational load is significantly reduced by 13.6% (7.0 GFLOPs). This design significantly reduces the computational load while maintaining zero missed detection (R=1) and high precision (P=0.999), making it more suitable for mobile deployment with strict real-time requirements. In addition, its mAP50-95 is 0.882, which is slightly lower than the uncropped AFF model (0.891), but still better than the baseline model (0.874), indicating that the cropping operation achieves a better balance between accuracy and efficiency. Overall, the third model is more suitable for practical application scenarios with its extremely low false positive rate (P=0.999), zero missed detection (R=1), and lightweight computation (7.0 GFLOPs).
[0152] In a specific embodiment, step S30 further includes:
[0153] The improved YOLOv8 model is subjected to vertical layer fusion and horizontal quantization processing through the TensorRT acceleration engine, including:
[0154] Convert the trained model to ONNX format and build an INT8 quantization calibration dataset;
[0155] Perform dynamic range quantization in the TensorRT engine, convert the convolutional layer weights to 8-bit integers, and perform dequantization on the output layer to restore accuracy;
[0156] Generate optimized .engine file.
[0157] In this embodiment, in order to significantly improve the execution efficiency of the algorithm, the algorithm is deeply optimized, and the TensorRT deep learning acceleration solution launched by NVIDIA provides strong support for this. The acceleration mechanism of this solution is as follows Figure 8 As shown, the core of this approach lies in two major optimization steps: First, vertical optimization. This step deeply analyzes the network structure, removing unnecessary output layers to reduce unnecessary computational burden. Furthermore, network layers that can be fused are vertically integrated to form a more compact and efficient computational unit. This optimization strategy not only simplifies the network structure but also significantly reduces computational effort. Second, horizontal optimization. In this stage, the focus is on fusing layers that share the same input tensors and perform the same operations, achieving horizontal integration. This optimization method further reduces the number of model parameters, thereby improving the algorithm's speed.
[0158] To achieve TensorRT acceleration, the model format is first converted, and the trained face detection model (usually a .pt file in PyTorch format) is converted to ONNX format to ensure that the model can be more widely used on different platforms and tools, including TensorRT. Then build the TensorRT engine, load the converted ONNX model, and create the corresponding TensorRT execution engine file (.engine). In addition, quantization technology is used to further speed up the calculation process. Specifically, the FP32 floating-point number is converted to an INT8 integer for calculation to greatly reduce the amount of calculation and memory consumption. After the calculation is completed, it is dequantized to FP32 to ensure that the accuracy is not excessively lost due to quantization. After quantization is completed, the data set is also used to fine-tune the quantized parameters to ensure the accuracy and stability of the algorithm.
[0159] This series of optimization measures successfully achieved a significant improvement in the algorithm's running speed. As shown in Table 2, the inference time of the video stream after acceleration and quantization on the local device was significantly improved compared to before optimization.
[0160] Table 2: Comparison of inference time before and after acceleration
[0161]
[0162] S40, transmitting the detected facial image to the cloud server, calling the pre-trained facial recognition API to perform feature vector comparison, and generating an identity verification result;
[0163] In one embodiment, the face recognition process of the cloud server in step S40 includes:
[0164] Call the pre-trained ArcFace deep model to extract the 512-dimensional feature vector of the face image;
[0165] The cosine similarity algorithm is used to compare the feature vectors with those in the registration database in real time. When the similarity exceeds the preset threshold, the authentication success instruction is triggered.
[0166] If recognition fails three times in a row, a repositioning command will be sent to the drone and the backup sound and light prompt module will be activated.
[0167] In this embodiment, the drone uses its onboard camera or other image acquisition device to capture images or video streams in the target area. It performs face detection and sends the detected face results to a cloud server for further identification. The drone needs to be equipped with a 5G network module to transmit images directly to the cloud server via the 5G network. After receiving the face detection results from the drone, the cloud server processes the image using a face detection and recognition algorithm. The core principle of the cloud server using an existing face recognition API to implement face recognition is to convert the face image into a mathematical feature vector using a pre-trained deep learning model in the cloud, and then complete identity verification or recognition through feature comparison. The specific process is as follows: After a device (such as a drone) captures a facial image, it first transmits the image to a cloud service via an API. The cloud performs image preprocessing (including face detection, keypoint alignment, and illumination normalization). It then calls a deployed deep neural network model (such as ResNet or ArcFace) to extract a high-dimensional feature vector (typically a 512-dimensional floating-point array) of the face. This vector uses the deep learning model to mathematically encode global facial features (such as outline) and local features (such as eye and nose details) to form a unique representation. The cloud then calculates the similarity between the extracted feature vector and a pre-stored feature database (commonly using cosine similarity or Euclidean distance). If the similarity exceeds a preset threshold (such as 0.92), the image is considered to be the same person. The entire process leverages the cloud service's distributed computing architecture, enabling millisecond-level response times. Through analysis and comparison, the API calls generate a similarity probability between the analyzed image and the target person's image. Based on this similarity probability, the cloud server determines whether the analyzed image matches the target person and identifies the target person. Based on the analysis results, the cloud server will perform corresponding operations and send the recognition results to the drone.
[0168] S50. Based on the identity verification result, the drone is controlled to land at the consignee's location and an interactive interface for a QR code or verification code is activated to complete the cargo handover.
[0169] S60: After the delivery task is completed, the feedback data including the timestamp, geographic location and handover status is integrated and sent back to the cloud server to update the order status in the logistics management system.
[0170] In one embodiment, integrating the feedback data including the timestamp, geographic location, and handover status in step S60 includes:
[0171] Establish a spatiotemporal correlation database on the cloud server and perform Kalman filtering and smoothing on the delivery trajectory data;
[0172] Generate regional heat maps based on historical delivery records and dynamically optimize the path planning weight parameters of subsequent drones.
[0173] In one specific embodiment, the drone's edge device uses facial recognition to identify the recipient. If the facial recognition result matches the recipient's information, the drone confirms the recipient's identity and lands near the recipient. The recipient can then collect the goods from the drone by scanning a QR code or entering a verification code, confirming receipt and completing the transaction. If the facial recognition result does not match the recipient's information, the drone repeats step 3 until the correct recipient's information is identified, at which point it lands near the recipient to complete the transaction. After completing a delivery, the drone immediately initiates a series of procedures to ensure accurate feedback on the delivery results. During this process, the drone first uses its built-in communication module to securely and efficiently transmit detailed delivery result information, including delivery confirmation, delivery location, timestamp, and delivery status updates, to a cloud server. As the central brain of the entire logistics system, the cloud server plays a core role in receiving, processing, and storing this critical data. Upon receiving the delivery result information from the drone, the cloud server immediately verifies and analyzes the data to ensure the accuracy and completeness of each piece of information. This information is then integrated into logistics management systems to update order status, calculate delivery efficiency, and optimize delivery routes, thereby ensuring smoother and more efficient logistics operations. Furthermore, this valuable delivery data is used for in-depth data analysis, helping logistics companies identify bottlenecks and opportunities in the delivery process and providing strong data support for developing more scientific and rational logistics strategies.
[0174] The embodiment of the present invention further provides a drone logistics distribution device based on face recognition, comprising:
[0175] A registration information download module is used to request the cloud server to download the pre-stored consignee registration information through the edge device carried by the drone. The registration information includes at least facial feature data and delivery authority information;
[0176] The flight control module is used to control the drone to deliver the goods to the target location based on the preset delivery route planning, and trigger the camera to capture the user's posture;
[0177] A face detection module, configured to perform face detection using an improved YOLOv8 model after detecting a user's posture. The improvement includes embedding an adaptive feature fusion module in the Bottleneck module and removing the shallow detection head.
[0178] The identity recognition module is used to transmit the detected face image to the cloud server, call the pre-trained face recognition API to perform feature vector comparison, and generate the identity verification result;
[0179] The drone landing module is used to control the drone to land at the consignee's location based on the identity verification result, and activate the QR code or verification code interactive interface to complete the cargo handover;
[0180] The data feedback module is used to integrate feedback data including timestamp, geographic location and handover status and transmit it back to the cloud server after the delivery task is completed, thereby updating the order status in the logistics management system.
[0181] It should be noted that technical personnel in the relevant field can clearly understand that the specific implementation process of the above-mentioned drone logistics distribution device based on face recognition can refer to the corresponding description in the aforementioned method embodiment. For the convenience and conciseness of the description, it will not be repeated here.
[0182] The above-mentioned drone logistics distribution device based on face recognition can be implemented in the form of a computer program, which can be used in Figure 10 Runs on the computer device shown.
[0183] See also Figure 10 , Figure 10 This is a schematic block diagram of a computer device provided in an embodiment of the present application. The computer device 500 can be a terminal or a server. The terminal can be a smart phone, tablet computer, laptop computer, desktop computer, personal digital assistant, wearable device, or other electronic device with communication capabilities. The server can be a standalone server or a server cluster consisting of multiple servers.
[0184] See Figure 10The computer device 500 includes a processor 502 , a memory, and a network interface 505 connected via a system bus 501 , wherein the memory may include a non-volatile storage medium 503 and an internal memory 504 .
[0185] The non-volatile storage medium 503 can store an operating system 5031 and a computer program 5032. The computer program 5032 includes program instructions, which, when executed, can cause the processor 502 to execute a drone logistics distribution method based on face recognition.
[0186] The processor 502 is used to provide computing and control capabilities to support the operation of the entire computer device 500.
[0187] The internal memory 504 provides an environment for the operation of the computer program 5032 in the non-volatile storage medium 503. When the computer program 5032 is executed by the processor 502, the processor 502 can execute a drone logistics distribution method based on face recognition.
[0188] The network interface 505 is used to communicate with other devices through the network. Figure 10 The structure shown in the figure is merely a block diagram of a portion of the structure related to the solution of the present application, and does not constitute a limitation on the computer device 500 to which the solution of the present application is applied. The specific computer device 500 may include more or fewer components than shown in the figure, or combine certain components, or have a different component arrangement.
[0189] The processor 502 is configured to execute a computer program 5032 stored in a memory to implement the drone logistics distribution method based on face recognition as described above.
[0190] It should be understood that in the embodiment of the present application, the processor 502 may be a central processing unit (CPU), and the processor 502 may also be other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), field-programmable gate arrays (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. Among them, the general-purpose processor may be a microprocessor or the processor may also be any conventional processor, etc.
[0191] Those skilled in the art will appreciate that all or part of the steps in the method of the above-described embodiment can be implemented by instructing the relevant hardware through a computer program. The computer program includes program instructions, which can be stored in a storage medium that is computer-readable. The program instructions are executed by at least one processor in the computer system to implement the steps in the method of the above-described embodiment.
[0192] Therefore, the present invention also provides a storage medium. The storage medium may be a computer-readable storage medium. The storage medium stores a computer program, wherein the computer program includes program instructions. When executed by a processor, the program instructions cause the processor to execute the drone logistics delivery method based on facial recognition as described above.
[0193] The storage medium may be any computer-readable storage medium that can store program codes, such as a USB flash drive, a mobile hard disk, a read-only memory (ROM), a magnetic disk, or an optical disk.
[0194] Those skilled in the art will appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, computer software, or a combination of the two. In order to clearly illustrate the interchangeability of hardware and software, the above description has generally described the composition and steps of each example according to function. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professional and technical personnel can use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of the present invention.
[0195] In the several embodiments provided herein, it should be understood that the disclosed devices and methods can be implemented in other ways. For example, the device embodiments described above are merely illustrative. For example, the division of the various units is merely a logical functional division, and actual implementation may employ other division methods. For example, multiple units or components may be combined or integrated into another system, or some features may be omitted or not implemented.
[0196] The steps in the methods of the embodiments of the present invention may be adjusted in order, combined, or deleted as needed. The units in the devices of the embodiments of the present invention may be combined, divided, or deleted as needed. Furthermore, the functional units in the various embodiments of the present invention may be integrated into a single processing unit, each unit may exist physically separately, or two or more units may be integrated into a single unit.
[0197] If this integrated unit is implemented as a software functional unit and sold or used as an independent product, it can be stored in a storage medium. Based on this understanding, the technical solution of the present invention, or the part that contributes to the existing technology, or all or part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes a number of instructions for causing a computer device (which can be a personal computer, terminal, or network device, etc.) to execute all or part of the steps of the method described in various embodiments of the present invention.
[0198] The above description is merely a specific embodiment of the present invention, but the scope of protection of the present invention is not limited thereto. Any person skilled in the art can easily conceive of various equivalent modifications or substitutions within the technical scope disclosed in the present invention, and such modifications or substitutions are intended to be within the scope of protection of the present invention. Therefore, the scope of protection of the present invention shall be subject to the scope of protection of the claims.
Claims
1. A drone logistics distribution method based on face recognition, characterized in that: Including steps: S10. Requesting, through the edge device carried by the drone, to download the pre-stored consignee registration information from the cloud server, where the registration information includes at least facial feature data and delivery authority information; S20: Based on the preset delivery route planning, control the drone to deliver the goods to the target geographic location and trigger the camera to capture the user's posture; S30. After detecting the user's posture, perform face detection using an improved YOLOv8 model, wherein the improvement includes embedding an adaptive feature fusion module in the Bottleneck module and deleting a shallow detection head. S40, transmitting the detected facial image to the cloud server, calling the pre-trained facial recognition API to perform feature vector comparison, and generating an identity verification result; S50. Based on the identity verification result, the drone is controlled to land at the consignee's location and an interactive interface for a QR code or verification code is activated to complete the cargo handover. S60: After the delivery task is completed, the feedback data including the timestamp, geographic location and handover status is integrated and sent back to the cloud server to update the order status in the logistics management system.
2. The drone logistics distribution method based on face recognition according to claim 1 is characterized in that: The improved YOLOv8 model in step S30 includes: In the CSPLayer_2Conv module of the Backbone network, the Bottleneck structure is replaced by an adaptive feature fusion module that integrates a multi-scale channel attention mechanism. The adaptive feature fusion module achieves adaptive aggregation of cross-scale features through weight fusion of global average pooling and local point-by-point convolution branches, and generates an attention weight matrix based on the channel dimension.
3. The drone logistics distribution method based on face recognition according to claim 2 is characterized in that: The improved YOLOv8 model in step S30 also includes: The shallow detection head of the original YOLOv8 model is deleted, and the middle and high-level dual detection head structure is retained; the middle-level detection head corresponds to a 40x40 feature map, and the high-level detection head corresponds to a 20x20 feature map. In the post-processing stage, differentiated confidence thresholds and weighted non-maximum suppression strategies are adopted.
4. The drone logistics distribution method based on face recognition according to claim 1 is characterized in that: The training process of the improved YOLOv8 model includes: In the data preprocessing stage, the input image is subjected to aspect ratio-preserving grayscale filling and HSV color perturbation enhancement; During the forward propagation of the model, the adaptive feature fusion module dynamically assigns weights to the multi-branch features of the Bottleneck layer, and optimizes the balance between classification and regression tasks based on the FocalLoss loss function. After training is completed, knowledge distillation technology is used to compress the model into a lightweight version to adapt to the computing resource limitations of edge devices.
5. The drone logistics distribution method based on face recognition according to claim 1 is characterized in that: Step S30 further includes: The improved YOLOv8 model is subjected to vertical layer fusion and horizontal quantization processing through the TensorRT acceleration engine, including: Convert the trained model to ONNX format and build an INT8 quantization calibration dataset; Perform dynamic range quantization in the TensorRT engine, convert the convolutional layer weights to 8-bit integers, and perform dequantization on the output layer to restore accuracy; Generate optimized .engine file.
6. The drone logistics distribution method based on face recognition according to claim 1 is characterized in that: The face recognition process of the cloud server in step S40 includes: Call the pre-trained ArcFace deep model to extract the 512-dimensional feature vector of the face image; The cosine similarity algorithm is used to compare the feature vectors with those in the registration database in real time. When the similarity exceeds the preset threshold, the authentication success instruction is triggered. If recognition fails three times in a row, a repositioning command is sent to the drone and the backup sound and light prompt module is activated.
7. The drone logistics distribution method based on face recognition according to claim 1 is characterized in that: The feedback data including the timestamp, geographic location and handover status integrated in step S60 includes: Establish a spatiotemporal correlation database on the cloud server and perform Kalman filtering and smoothing on the delivery trajectory data; Generate regional heat maps based on historical delivery records and dynamically optimize the path planning weight parameters of subsequent drones.
8. A drone logistics distribution device based on face recognition, characterized in that: include: A registration information download module is used to request the cloud server to download the pre-stored consignee registration information through the edge device carried by the drone. The registration information includes at least facial feature data and delivery authority information; The flight control module is used to control the drone to deliver the goods to the target location based on the preset delivery route planning, and trigger the camera to capture the user's posture; A face detection module, configured to perform face detection using an improved YOLOv8 model after detecting a user's posture. The improvement includes embedding an adaptive feature fusion module in the Bottleneck module and removing the shallow detection head. The identity recognition module is used to transmit the detected face image to the cloud server, call the pre-trained face recognition API to perform feature vector comparison, and generate the identity verification result; The drone landing module is used to control the drone to land at the consignee's location based on the identity verification result, and activate the QR code or verification code interactive interface to complete the cargo handover; The data feedback module is used to integrate feedback data including timestamp, geographic location and handover status and transmit it back to the cloud server after the delivery task is completed, thereby updating the order status in the logistics management system.
9. A computer device, characterized in that: The computer device includes a memory and a processor, the memory stores a computer program, and the processor implements the drone logistics distribution method based on face recognition as described in any one of claims 1 to 7 when executing the computer program.
10. A storage medium, characterized in that: The storage medium stores a computer program, which, when executed by a processor, can implement the drone logistics distribution method based on face recognition as described in any one of claims 1 to 7.
Citation Information
Cited By
Face recognition and encryption verification multi-grid article distribution control method and distribution vehicle
CN121052729A
