Door-to-door signing image definition detection method, device and equipment and storage medium

By constructing the EfficientNet network model and introducing hybrid precision training technology, the problem of inconsistent quality of signed delivery photos was solved, enabling real-time clarity detection and scoring of signed delivery photos, thereby improving logistics efficiency and consumer satisfaction.

CN121415399APending Publication Date: 2026-01-27SHANGHAI DONGPU INFORMATION TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202511523518.8
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-10-23
Publication Date
2026-01-27

AI Technical Summary

Technical Problem

The quality of signed-for photos uploaded by couriers in the current technology is inconsistent, making it difficult to effectively manage blurry photos, which affects the operational efficiency of the logistics industry and the consumer experience. Furthermore, blurry photos cannot provide a clear chain of evidence, making it difficult to determine liability.

Method used

By employing the EfficientNet network model and introducing mixed precision training techniques, and using labeled datasets and the Cross-Entropy Loss function, a photo sharpness classification and scoring model is constructed to classify and score photos uploaded by couriers in real time.

Benefits of technology

It enables real-time monitoring of the clarity of signed delivery photos, reduces reliance on manual review, improves the efficiency of logistics information management, enhances the consumer experience, and ensures the accuracy and traceability of logistics information.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121415399A_ABST
    Figure CN121415399A_ABST
Patent Text Reader

Abstract

The invention relates to the field of logistics, in particular to a door-to-door signing image definition detection method and device, equipment and a storage medium. The door-to-door sign-in image definition detection method comprises the following steps: obtaining express door-to-door sign-in photo samples, and marking the express door-to-door sign-in photo samples according to definition levels to obtain a data set; the method comprises the following steps: constructing an OfficientNet network model, and introducing a mixed precision training technology in a model training process so as to optimize the OfficientNet network model; a data set is adopted to train an OfficientNet network model, and Cross-Entry Loss is adopted as a loss function to obtain a photo definition classification scoring model; and classifying and scoring the photos uploaded in real time by adopting the photo definition classification and scoring model. According to the invention, the system can carry out automatic photo definition classification and scoring, the dependence on manual auditing is reduced, the logistics information management efficiency is improved, fuzzy photos are found and processed in time, and the accuracy and traceability of logistics information are ensured.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of logistics, and in particular to a method, apparatus, equipment, and storage medium for detecting the clarity of images received upon delivery. Background Technology

[0002] In the current door-to-door delivery signing process of the express delivery industry, taking photos as evidence has become an important means of protecting the rights and interests of both parties in the transaction. However, the quality of the signature photos uploaded by couriers is currently inconsistent. Many photos suffer from distortion, blurriness, and loss of detail due to insufficient lighting, incorrect shooting angles, and equipment pixel compatibility issues. These low-quality photos are negatively impacting the efficient operation and service reputation of the logistics industry from multiple dimensions. From a consumer experience perspective, blurry photos of signed packages fail to clearly demonstrate crucial information such as the integrity of the packaging and details of the signing process. When consumers raise concerns about damaged packages, incorrect or missing deliveries, the lack of photographic evidence not only hinders quick verification of the issue but can also lead to consumer distrust of the logistics service's professionalism, escalating complaints and disputes, and severely damaging user goodwill towards the logistics company's brand. Within the internal operations of logistics, blurry photos pose a significant obstacle to information verification and traceability. Logistics systems rely on signed-for photos to complete critical processes such as recipient information confirmation, delivery address verification, and receipt status archiving. However, illegible text (such as recipient names and addresses) and blurred package markings in blurry photos lead to frequent errors during data entry, significantly increasing the workload and time cost of manual verification. More seriously, when logistics disputes arise and responsibility needs to be traced, blurry photos fail to provide a clear chain of evidence, making liability determination difficult. It is evident that existing technologies still need improvement and enhancement. Summary of the Invention

[0003] In view of the shortcomings of the prior art, the purpose of this invention is to provide a method, apparatus, device and storage medium for detecting the clarity of on-site delivery images, aiming to solve the technical problem that the quality of delivery photos uploaded by couriers on a daily basis is inconsistent and difficult to manage effectively.

[0004] To achieve the above objectives, the present invention adopts the following technical solution: The first aspect of this invention provides a method for detecting the sharpness of images received for home delivery, comprising the following steps: acquiring samples of photos of home delivery for home delivery, labeling the samples of photos according to their sharpness levels to obtain a dataset; constructing an EfficientNet network model, introducing mixed precision training technology during model training to optimize the EfficientNet network model; training the EfficientNet network model using the dataset, and using Cross-Entropy Loss as the loss function to obtain a photo sharpness classification and scoring model; acquiring photos uploaded in real time by the courier, classifying and scoring the real-time uploaded photos using the photo sharpness classification and scoring model, and outputting the classification and scoring results in real time.

[0005] Optionally, in a first implementation of the first aspect of the present invention, the step of obtaining express delivery receipt photo samples and labeling the express delivery receipt photo samples according to the clarity level to obtain a dataset specifically includes: obtaining express delivery receipt photo samples in different scenarios, wherein the express delivery receipt photo samples include express delivery type, shooting equipment, environmental conditions, and shooting operation data; formulating a clarity level standard based on text content, key information on the waybill, and package characteristics, and using a labeling tool to label the express delivery receipt photo samples according to the clarity level standard; storing all labeled express delivery receipt photo samples according to clarity level, generating a metadata file containing image path, labeling level, labeling personnel, and review results, forming a complete labeled dataset.

[0006] Optionally, in the second implementation of the first aspect of the present invention, the construction of the EfficientNet network model, which involves introducing mixed precision training technology during model training to optimize the EfficientNet network model, specifically includes: constructing an EfficientNet-B0 model as a baseline model, and building each MBConv block for the baseline model; setting hyperparameters for the baseline model to form the EfficientNet network model, wherein the hyperparameters are set as follows: initial learning rate 0.001, batch size 32, total number of iterations 100, and weight decay coefficient 0.0001; and introducing mixed precision training technology during model training to optimize the EfficientNet network model.

[0007] Optionally, in the third implementation of the first aspect of the present invention, the construction of the EfficientNet-B0 model as a baseline model, and the construction of each MBConv block for the baseline model, specifically includes: setting an input layer to unify the size of the input image, setting a normalization layer after the input layer to make the distribution of the input data consistent with the distribution of the data during model pre-training; constructing 16 MBConv blocks, and constructing a feature extractor based on the 16 MBConv blocks; constructing an output layer, using global average pooling to compress the final feature map into a 1×1×C vector, then connecting it to a fully connected layer with an output dimension of 4, and finally outputting the probability of each level through the Softmax activation function.

[0008] Optionally, in the fourth implementation of the first aspect of the present invention, the introduction of mixed precision training technology during model training to optimize the EfficientNet network model specifically includes: simultaneously maintaining weights and activation values ​​in FP16 and FP32 formats during network training; allocating FP16 computation to computationally intensive operators and forcing FP32 computation to be used for precision-sensitive operators; setting an initial scaling factor range and dynamically adjusting gradient values ​​during backpropagation based on the scaling factor; establishing a gradient overflow detection mechanism and judging the real-time gradient values ​​during backpropagation based on the gradient overflow detection mechanism; adjusting the scaling factor and recalculating the forward and backward propagation of the current batch when the gradient is non-numerical or infinite; and dynamically optimizing the operator precision configuration based on historical overflow records to stabilize the model training process.

[0009] Optionally, in the fifth implementation of the first aspect of the present invention, the step of training the EfficientNet network model using a dataset and using Cross-Entropy Loss as the loss function to obtain a photo sharpness classification and scoring model specifically includes: performing enhancement processing on the samples in the dataset, the enhancement processing including random flipping, random cropping, brightness and contrast adjustment, and random Gaussian blur; using stratified sampling to divide the dataset proportionally to obtain a training set, a validation set, and a test set; calculating the weights of each type of sample in the training set, validation set, and test set, using the Cross-Entropy Loss loss function, and adjusting the model's error sensitivity to minority class samples during training according to the weights of each type of sample; training the EfficientNet network model using the training set, evaluating the model performance using the validation set after every 10 iterations, and evaluating it using the test set after training to obtain a photo sharpness classification and scoring model.

[0010] Optionally, in the sixth implementation of the first aspect of the present invention, the step of acquiring photos uploaded in real time by the courier, classifying and scoring the real-time uploaded photos using a photo clarity classification and scoring model, and outputting the classification and scoring results in real time specifically includes: acquiring photos uploaded in real time by the courier, preprocessing the real-time uploaded photos to obtain preprocessed photos; classifying the preprocessed photos using a photo clarity classification and scoring model to obtain classification results, wherein the classification results include probabilities of multiple clarity levels; using the clarity level with the highest probability as the final classification result, and converting the final classification result into a score; setting a pass threshold, comprehensively judging whether the photos uploaded in real time by the courier are qualified based on the final classification result and the pass threshold, and outputting the classification result, score, and qualification judgment result.

[0011] A second aspect of the present invention provides a device for detecting the sharpness of images received at the door, comprising: an annotation module for acquiring samples of photos of express delivery received at the door, and annotating the samples of photos according to their sharpness levels to obtain a dataset; a construction module for constructing an EfficientNet network model, and introducing mixed precision training technology during model training to optimize the EfficientNet network model; a training module for training the EfficientNet network model using the dataset, and using Cross-Entropy Loss as the loss function to obtain a photo sharpness classification and scoring model; and a detection module for acquiring photos uploaded in real time by the courier, classifying and scoring the real-time uploaded photos using the photo sharpness classification and scoring model, and outputting the classification and scoring results in real time.

[0012] Optionally, in the first implementation of the second aspect of the present invention, the annotation module includes: an acquisition unit, used to acquire photo samples of express delivery signing in different scenarios, wherein the express delivery signing photo samples include express delivery type, shooting equipment, environmental conditions, and shooting operation data; an annotation unit, used to formulate a clarity level standard based on text content, key information on the waybill, and package characteristics, and use an annotation tool to annotate the express delivery signing photo samples according to the clarity level standard; and a storage unit, used to classify and store all annotated express delivery signing photo samples according to clarity level, generate a metadata file containing image path, annotation level, annotation personnel, and review results, and form a complete annotation dataset.

[0013] Optionally, in a second implementation of the second aspect of the present invention, the construction module includes: a construction unit for constructing an EfficientNet-B0 model as a baseline model and building each MBConv block for the baseline model; a setting unit for setting hyperparameters for the baseline model to form an EfficientNet network model, wherein the hyperparameters are set as follows: initial learning rate 0.001, batch size 32, total number of iterations 100, and weight decay coefficient 0.0001; and an optimization unit for introducing mixed precision training technology during model training to optimize the EfficientNet network model.

[0014] Optionally, in a third implementation of the second aspect of the present invention, the construction unit includes: an input layer subunit for setting an input layer to unify the size of the input image, and setting a normalization layer after the input layer to make the distribution of the input data consistent with the distribution of the data during model pre-training; a feature subunit for building 16 MBConv blocks and constructing a feature extractor based on the 16 MBConv blocks; and an output layer subunit for constructing an output layer, using global average pooling to compress the final feature map into a 1×1×C vector, then connecting it to a fully connected layer with an output dimension of 4, and finally outputting the probability of each level through a Softmax activation function.

[0015] Optionally, in the fourth implementation of the second aspect of the present invention, the optimization unit includes: a maintenance subunit, used to maintain weights and activation values ​​in both FP16 and FP32 formats during network training, allocating FP16 computation for computationally intensive operators and forcing FP32 computation for precision-sensitive operators; an adjustment subunit, used to set an initial scaling factor range and dynamically adjust gradient values ​​during backpropagation based on the scaling factor; a detection subunit, used to establish a gradient overflow detection mechanism, judging the real-time gradient values ​​during backpropagation based on the gradient overflow detection mechanism, adjusting the scaling factor and recalculating the forward and backward propagation of the current batch when the gradient is non-numerical or infinite; and an optimization subunit, used to dynamically optimize operator precision configuration based on historical overflow records to stabilize the model training process.

[0016] Optionally, in the fifth implementation of the second aspect of the present invention, the training module includes: an enhancement unit for enhancing samples in the dataset, the enhancement process including random flipping, random cropping, brightness and contrast adjustment, and random Gaussian blur; a partitioning unit for dividing the dataset proportionally using stratified sampling to obtain a training set, a validation set, and a test set; an adjustment unit for calculating the weights of each type of sample in the training set, validation set, and test set, using the Cross-Entropy Loss function, and adjusting the model's error sensitivity to minority class samples during training based on the weights of each type of sample; and a training unit for training the EfficientNet network model using the training set, evaluating the model performance using the validation set after every 10 iterations, and evaluating it using the test set after training to obtain a photo sharpness classification scoring model.

[0017] Optionally, in the sixth implementation of the second aspect of the present invention, the detection module includes: a preprocessing unit, used to acquire photos uploaded by the courier in real time, preprocess the uploaded photos to obtain preprocessed photos; a calculation unit, used to classify the preprocessed photos using a photo clarity classification scoring model to obtain classification results, the classification results including the probabilities of multiple clarity levels; a scoring unit, used to take the clarity level with the highest probability as the final classification result and convert the final classification result into a score; and a judgment unit, used to set a pass threshold, comprehensively judge whether the photos uploaded by the courier in real time are qualified based on the final classification result and the pass threshold, and output the classification result, the score, and the qualification judgment result.

[0018] A third aspect of the present invention provides a device for detecting the clarity of images received upon delivery, comprising a memory and at least one processor, wherein the memory stores computer-readable instructions; the at least one processor invokes the computer-readable instructions in the memory to execute the various steps of the method for detecting the clarity of images received upon delivery as described above.

[0019] A fourth aspect of the present invention provides a computer-readable storage medium storing computer-readable instructions, characterized in that, when executed by a processor, the computer-readable instructions implement the various steps of the on-site signing image clarity detection method described above.

[0020] Beneficial Effects: This invention provides a method for detecting the sharpness of images received at the door. The method first acquires sample photos of express delivery receipts, labels these photos according to their sharpness levels to obtain a dataset, providing sufficient data for subsequent model training. Then, an EfficientNet network model is constructed, and mixed precision training technology is introduced during model training to optimize the EfficientNet model and improve its training efficiency and performance. Next, the EfficientNet network model is trained using the dataset, and Cross-Entropy Loss is used as the loss function to address the sample imbalance problem in template classification, ultimately obtaining a high-performance photo sharpness classification and scoring model. Finally, the photo sharpness classification and scoring model is used to classify and score real-time uploaded photos, thereby supervising the sharpness of photos uploaded to the system. Attached Figure Description

[0021] Figure 1 This is a first flowchart of the image clarity detection method for door-to-door delivery signing provided in an embodiment of the present invention; Figure 2 This is a second flowchart of the image clarity detection method for door-to-door delivery confirmation provided in an embodiment of the present invention; Figure 3 This is a third flowchart of the image clarity detection method for door-to-door delivery confirmation provided in this embodiment of the invention; Figure 4 This is a fourth flowchart of the image clarity detection method for door-to-door delivery confirmation provided in this embodiment of the invention; Figure 5 The fifth flowchart of the image clarity detection method for door-to-door delivery signing provided in this embodiment of the invention; Figure 6 The sixth flowchart of the image clarity detection method for door-to-door delivery signing provided in this embodiment of the invention; Figure 7 The seventh flowchart of the image clarity detection method for door-to-door delivery signing provided in this embodiment of the invention; Figure 8 A schematic diagram of a door-to-door delivery image clarity detection device provided in an embodiment of the present invention; Figure 9 This is another structural schematic diagram of the on-site delivery image clarity detection device provided in an embodiment of the present invention; Figure 10 This is a schematic diagram of the structure of the on-site signing image clarity detection device provided in an embodiment of the present invention. Detailed Implementation

[0022] This invention provides a method, apparatus, device, and storage medium for detecting the sharpness of images received for package pickup. First, the invention acquires samples of photos of package pickups and signing for them, and accurately labels the samples according to their sharpness levels to construct a dataset, laying a solid data foundation for subsequent model training. Then, in the model construction and optimization stage, an EfficientNet network model is built, and mixed-precision training technology is introduced to optimize it, significantly improving the model's training efficiency and further optimizing its performance, enabling it to maintain good feature recognition capabilities even in complex image scenes. Next, during model training, the optimized EfficientNet network model is trained using the previously constructed high-quality dataset, and Cross-Entropy Loss is selected as the loss function to effectively solve the sample imbalance problem in sample classification. Finally, the trained photo sharpness classification and scoring model is applied to a real-time scenario to classify and score uploaded photos in real time, achieving real-time supervision of photo sharpness. This method can promptly detect cases of substandard sharpness in uploaded photos, providing strong technical support for quality control of package pickup and signing photos.

[0023] The terms "first," "second," "third," "fourth," etc. (if present) in the specification, claims, and accompanying drawings of this invention are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. It should be understood that such data can be interchanged where appropriate so that the embodiments described herein can be implemented in orders other than those illustrated or described herein. Furthermore, the terms "comprising" or "having" and any variations thereof are intended to cover a non-exclusive inclusion; for example, a process, method, system, product, or apparatus that comprises a series of steps or units is not necessarily limited to those steps or units explicitly listed, but may include other steps or units not explicitly listed or inherent to such processes, methods, products, or apparatus.

[0024] For ease of understanding, the specific process of the embodiments of the present invention is described below. Please refer to [link / reference]. Figure 1 The first embodiment of the image clarity detection method for door-to-door delivery signing in this invention includes: S101. Obtain sample photos of express delivery signatures at the door, and label the sample photos according to the clarity level to obtain a dataset; S102. Construct the EfficientNet network model and introduce mixed precision training technology during the model training process to optimize the EfficientNet network model; S103. The EfficientNet network model is trained using the dataset, and Cross-EntropyLoss is used as the loss function to obtain a photo sharpness classification and scoring model. S104. Obtain photos uploaded by couriers in real time, use a photo clarity classification and scoring model to classify and score the uploaded photos in real time, and output the classification and scoring results in real time.

[0025] In this embodiment, at least 5,000 photos of delivery personnel signing for packages are collected during operation, covering different actual operational scenarios. This ensures that the subsequently trained model can handle different situations and improves model performance. After acquiring the photos, annotation tools are used to label photo samples of different clarity levels. The annotation content includes the clarity level (e.g., clear, fairly clear, blurry, very blurry), thereby obtaining the dataset.

[0026] Before training with the dataset, an EfficientNet network model needs to be built. The EfficientNet network model possesses powerful feature extraction capabilities, accurately capturing key features related to image sharpness. This provides precise feature support for subsequent image sharpness classification and scoring, reducing judgment errors caused by insufficient feature extraction. Furthermore, even in complex scenarios such as lighting variations and shooting angle differences in photos of packages delivered to the door, the EfficientNet network model maintains stable and good feature recognition capabilities, ensuring effective sharpness detection in diverse real-world scenarios. To improve training efficiency and model accuracy, this embodiment also introduces a hybrid precision training technique. Hybrid precision training dynamically adjusts the precision of weights during training, reducing memory usage, accelerating training speed, and maintaining model accuracy.

[0027] During training, this embodiment further employs Cross-Entropy Loss as the loss function to address the imbalanced sample problem in classification. When training on a dataset, it needs to be divided into training, validation, and test sets. This can lead to uneven sample distribution. Furthermore, the samples themselves may exhibit a surplus of some classes and a shortage of others. Cross-Entropy Loss effectively handles the non-linear relationships between classes, especially in addressing the imbalanced sample problem. By adjusting the class weights, the model can focus more on minority class samples, ensuring balanced classification performance across all classes.

[0028] After obtaining the photo clarity classification and scoring model, the photos uploaded by the courier are input into the model, which will classify and score the photo clarity in real time. If the system detects that the photo clarity does not meet the preset standard (e.g., the clarity level is lower than "relatively clear"), the system will prompt the courier to take a new photo. Only when the photo clarity meets the preset standard can the courier complete the signing process.

[0029] The automated photo clarity classification and scoring system of this invention effectively reduces reliance on manual review, lowers labor costs and review workload, and improves the efficiency of logistics information management. In addition, the real-time classification and scoring mechanism can promptly detect and process blurry photos, effectively enhancing the consumer experience and ensuring the accuracy and traceability of logistics information.

[0030] Please see Figure 2 The second embodiment of the image clarity detection method for door-to-door delivery signing in this invention includes: S201. Obtain sample photos of express delivery signing at the door in different scenarios, wherein the sample photos of express delivery signing at the door include express delivery type, shooting equipment, environmental conditions and shooting operation data; S202. Based on the text content, key information on the waybill, and characteristics of the package, formulate clarity level standards, and use annotation tools to annotate the sample photos of express delivery signatures according to the clarity level standards; S203. Store all annotated express delivery receipt photos according to their clarity level, and generate metadata files containing image paths, annotation levels, annotators, and review results to form a complete annotation dataset.

[0031] In this embodiment, to ensure that the samples reflect various clarity variations in real-world delivery scenarios, in addition to acquiring the photo samples themselves, it is also necessary to acquire information such as the type of express delivery, the shooting equipment, environmental conditions, and shooting operation data, all of which are relevant data affecting photo clarity. When specifically annotating, a user-friendly and collaborative annotation tool, such as LabelMe or VGGImageAnnotator, is selected. At the same time, the clarity level standards are refined, specifying the following: "Clear" means the photo must meet the conditions that the text on the express delivery slip is fully identifiable and the edges of the package features are sharp and unblurred; "Relatively Clear" means the key information on the express delivery slip is identifiable, and secondary information is slightly blurred but does not affect the overall judgment; "Blurred" means the key information in the photo is partially lost, the overall outline is discernible but details are blurred; "Very Blurred" means no key information can be identified in the photo, and it can only be roughly identified as an express delivery item. All annotated samples are categorized and stored according to level, generating a metadata file containing image path, annotation level, annotator, and review results, forming a complete annotation dataset.

[0032] Please see Figure 3 The third embodiment of the image clarity detection method for door-to-door delivery signing in this invention includes: S301. Construct the EfficientNet-B0 model as the baseline model, and build each MBConv block for the baseline model; S302. Set hyperparameters for the baseline model to form the EfficientNet network model. The hyperparameters are set as follows: initial learning rate 0.001, batch size 32, total number of iterations 100, and weight decay coefficient 0.0001. S303. Introduce hybrid precision training techniques during model training to optimize the EfficientNet network model.

[0033] In this embodiment, the EfficientNet-B0 model is used as the baseline model, which contains 16 MBConv blocks. The EfficientNet-B0 model can accurately capture details related to sharpness in express delivery photos, such as the degree of blurring of image textures and edge sharpness. Furthermore, while ensuring high sharpness recognition accuracy, the model does not rely on high-performance computing equipment and can run stably on ordinary servers or edge devices. For large-scale deployment of sharpness detection systems in the express delivery industry, this can significantly reduce hardware procurement and maintenance costs, while balancing recognition performance and cost control. After building the baseline model, hyperparameters are set to form the EfficientNet network model. The hyperparameters are set as follows: initial learning rate 0.001, batch size 32, total number of iterations 100, and weight decay coefficient 0.0001. Finally, a hybrid precision training technique is introduced to optimize the EfficientNet network model. By optimizing the training process, the training efficiency and performance of the model can be improved. Hybrid precision training can dynamically adjust the precision of weights during training, reducing memory usage, accelerating training speed, and maintaining model accuracy.

[0034] Please see Figure 4 The fourth embodiment of the image clarity detection method for door-to-door delivery signing in this invention includes: S401. Set up an input layer to unify the size of the input image, and set a normalization layer after the input layer to make the distribution of the input data consistent with the distribution of the data during model pre-training; S402. Construct 16 MBConv blocks and build a feature extractor based on the 16 MBConv blocks; S403. Construct the output layer, use global average pooling to compress the final feature map into a 1×1×C vector, then connect it to a fully connected layer with an output dimension of 4, and finally output the probability of each level through the Softmax activation function.

[0035] In this embodiment, when constructing the EfficientNet-B0 model, an input layer is set up, which uniformly adjusts the size of the input image to 224×224. Specifically, bilinear interpolation can be used to handle images with mismatched sizes. Then, a normalization layer is added after the input layer to normalize the pixel values ​​from [0,255] to [-1,1], so that the distribution of the input data is consistent with that during model pre-training.

[0036] The EfficientNet-B0 model comprises 16 MBConv blocks for feature extraction. Each MBConv block is constructed as follows: First, the number of input feature channels is increased to 6 times the original number of channels through a 1×1 convolution; then, a 3×3 depthwise separable convolution is performed, with batch normalization and a Swish activation function added; then, an SE attention module is embedded; the features are compressed into a 1×1×C vector through global average pooling, and then channel weights are generated through two fully connected layers and a Sigmoid activation; finally, the weights are multiplied with the original features to enhance the key channel features; finally, the number of channels is reduced back to the original dimension through a 1×1 convolution, and residual connections are added.

[0037] The output layer adopts a fully connected structure. First, the feature map is compressed into a 1x1xC vector through global average pooling, then connected to a fully connected layer with an output dimension of 4, and finally the probability of each level is output through the Softmax activation function.

[0038] Please see Figure 5 The fifth embodiment of the image clarity detection method for door-to-door delivery signing in this invention includes: S501. During network training, both FP16 and FP32 format weights and activation values ​​are maintained simultaneously. FP16 computation is assigned to computationally intensive operators, while FP32 computation is forced to be used for precision-sensitive operators. S502. Set the initial scaling factor range and dynamically adjust the gradient values ​​during backpropagation based on the scaling factor; S503. Establish a gradient overflow detection mechanism. Based on the gradient overflow detection mechanism, judge the real-time gradient value during the backpropagation process. When the gradient is non-numerical or infinite, adjust the scaling factor and recalculate the forward and backward propagation of the current batch. S504. Dynamically optimize operator precision configuration based on historical overflow records to stabilize the model training process.

[0039] In this embodiment, by introducing mixed precision training technology during model training, the training process can be optimized, thereby improving the training efficiency and performance of the model. Specifically, the AMP module of the PyTorch framework can be selected to ensure that the training device supports FP16 computation; the autocast context manager and GradScaler are initialized in the code, and the hardware is checked to see if it supports FP16 operations. If not, it is automatically downgraded to FP32 training; the weights and activation values ​​in the network are stored in FP16 format, but a copy of the weights in FP32 format is retained; FP32 computation is forced for precision-sensitive operators, while FP16 computation is used for computationally intensive operators, balancing efficiency and stability.

[0040] During training, the initial scaling factor is set to 2–15. Training data is input into the model for forward propagation to obtain prediction results. The prediction results and the true labels are compared using a loss function to calculate the loss value. Before backpropagation, the loss value is multiplied by the scaling factor to amplify the gradient values ​​to the range representable by FP16. Before parameter updates, the calculated gradient is divided by the scaling factor to restore the true gradient value. After each iteration, the scaling factor is adjusted based on whether gradient overflow occurs. During backpropagation, the gradient is continuously monitored for non-numerical or infinite values; if any are found, the current iteration is marked as invalid. For invalid iterations, the model parameters are not updated; the scaling factor is reduced, and the forward and backward propagation of the current batch is recalculated. Simultaneously, the frequency and operator type of gradient overflow are recorded. If a certain type of operator frequently causes overflow, it is forcibly switched to FP32 calculation to ensure stable training.

[0041] Please see Figure 6 The sixth embodiment of the image clarity detection method for door-to-door delivery signing in this invention includes: S601. Enhance the samples in the dataset, the enhancement process including random flipping, random cropping, brightness and contrast adjustment, and random Gaussian blur; S602. Stratified sampling is used to divide the dataset proportionally to obtain training set, validation set and test set; S603. Calculate the weights of each type of sample in the training set, validation set, and test set, and use the Cross-Entropy Loss function to adjust the model's error sensitivity to minority class samples during training based on the weights of each type of sample. S604. The EfficientNet network model is trained using the training set. After every 10 iterations, the model performance is evaluated using the validation set. After training, the model is evaluated using the test set to obtain the photo sharpness classification and scoring model.

[0042] In this embodiment, the training set is input into the improved EfficientNet model for model training. Cross-Entropy Loss is used as the loss function to solve the sample imbalance problem in classification problems. Specifically, it includes: First, the training set samples are augmented in various ways, including random horizontal / vertical flipping, random cropping, brightness / contrast adjustment, and random Gaussian blurring. These augmentation operations are performed online in real time without altering the original dataset storage.

[0043] Then, stratified sampling is used to divide the labeled dataset into training, validation, and test sets in a 7:2:1 ratio to ensure that the proportion of samples of the four sharpness levels in the three subsets is consistent with that of the original dataset. If there is a serious imbalance, the minority class samples are oversampled to keep the proportion of samples of each level within 1:1.5. The weights of each level are calculated to make the loss function more sensitive to errors of minority class samples.

[0044] During training, the Adam optimizer was selected, and a cosine annealing strategy was adopted for the learning rate. The initial learning rate was 0.001, and it gradually decreased according to the cosine function in each iteration, dropping to 1 / 100 of the initial value in the last iteration to balance rapid convergence in the early stage with fine-tuning in the later stage. In each iteration, 32 augmented samples were randomly selected from the training set and input into the model to obtain the predicted probabilities. The weighted cross-entropy loss was calculated, and the gradient was calculated through backpropagation. The optimizer was used to update the model parameters. After every 10 iterations, the model performance was evaluated using the validation set, and the accuracy at each level and the overall accuracy were calculated. The model parameters with the highest accuracy on the validation set were saved. After training, the model was finally evaluated using the test set, and the confusion matrix of the model at each level was recorded.

[0045] Please see Figure 7 The seventh embodiment of the image clarity detection method for door-to-door delivery signing in this invention includes: S701. Obtain photos uploaded in real time by the courier, preprocess the uploaded photos, and obtain preprocessed photos; S702. The preprocessed photos are classified using a photo sharpness classification and scoring model to obtain classification results, wherein the classification results include the probabilities of multiple sharpness levels; S703. The clarity level with the highest probability is used as the final classification result, and the final classification result is converted into a score; S704. Set a pass / fail threshold, and combine the final classification result with the pass / fail threshold to determine whether the photos uploaded by the courier in real time are qualified. Output the classification result, score and pass / fail judgment result.

[0046] In this embodiment, before using the trained model to analyze real-time uploaded photos, the photos need to be preprocessed to obtain preprocessed photos. For example, when receiving photos uploaded by a courier through an app, the image format is first checked. If the format is not compatible, it is automatically converted to JPG. Then, the input layer adjusts the image size, using bilinear interpolation to scale the image to 224×224. If the image ratio differs significantly from the target ratio, edge padding is used to maintain the original content ratio. The adjusted image is then standardized to ensure consistency with the input distribution during training. The preprocessed image is then input into the feature extractor, where forward propagation is performed, passing through the input layer, MBConv block, attention module, and finally the output layer and fully connected layer. Softmax is used to output the probabilities of four sharpness levels.

[0047] For a given photo, the probability results of the sharpness level are as follows: sharp 0.7, fairly sharp 0.2, blurry 0.08, and very blurry 0.02. The system then selects the level with the highest probability as the final classification result and converts the probability of that level into a score of 0-100. The preset standard for passing the sharpness test is "fairly sharp" or above, that is, only the classification result of sharp or fairly sharp is acceptable.

[0048] In addition, this embodiment further sets an auxiliary threshold. If the probability of being clearer is ≥0.5, it is still judged as qualified even if other level scores are higher; if the classification result is blurry or very blurry, or the probability of being clearer is <0.5, it is judged as unqualified.

[0049] If the photo is deemed unqualified, a specific prompt message will be sent to the courier's app. For example, if the photo is not clear enough, please retake it in a well-lit place to ensure that the text on the waybill is clear, and prohibit the courier from entering the signing process. If the photo is deemed qualified, the system will allow the courier to continue to complete the signing operation, and at the same time, the system will write information such as photo path, clarity level, score, judgment result, and operation time into the system log for future traceability and model optimization reference.

[0050] The above describes the method for detecting the clarity of images received upon delivery in an embodiment of the present invention. The following describes the device for detecting the clarity of images received upon delivery in an embodiment of the present invention. Please refer to [link / reference]. Figure 8 One embodiment of the on-site delivery image clarity detection device of the present invention includes: The annotation module 10 is used to obtain sample photos of express delivery signatures and to annotate the sample photos according to their clarity level in order to obtain a dataset. Module 20 is used to build the EfficientNet network model and introduces mixed precision training technology during the model training process to optimize the EfficientNet network model. Training module 30 is used to train the EfficientNet network model using the dataset and uses Cross-Entropy Loss as the loss function to obtain a photo sharpness classification and scoring model. The detection module 40 is used to acquire photos uploaded by couriers in real time, and uses a photo clarity classification and scoring model to classify and score the uploaded photos in real time, and outputs the classification and scoring results in real time.

[0051] Please see Figure 9 One embodiment of the on-site delivery image clarity detection device of the present invention includes: The annotation module 10 is used to obtain sample photos of express delivery signatures and to annotate the sample photos according to their clarity level in order to obtain a dataset. Module 20 is used to build the EfficientNet network model and introduces mixed precision training technology during the model training process to optimize the EfficientNet network model. Training module 30 is used to train the EfficientNet network model using the dataset and uses Cross-Entropy Loss as the loss function to obtain a photo sharpness classification and scoring model. The detection module 40 is used to acquire photos uploaded by couriers in real time, and uses a photo clarity classification and scoring model to classify and score the uploaded photos in real time, and outputs the classification and scoring results in real time. In this embodiment, the annotation module 10 includes: The acquisition unit 11 is used to acquire photo samples of express delivery signing in different scenarios. The express delivery signing photo samples include express delivery type, shooting device, environmental conditions and shooting operation data. The annotation unit 12 is used to formulate clarity level standards based on text content, key information on the waybill, and package characteristics, and to use annotation tools to annotate the sample of express delivery signature photos according to the clarity level standards. Storage unit 13 is used to classify and store all labeled express delivery receipt photos according to their clarity level, generate metadata files containing image paths, labeling levels, labelers, and review results, and form a complete labeled dataset. In this embodiment, the construction module 20 includes: Building unit 21 is used to build the EfficientNet-B0 model as a baseline model and to build each MBConv block for the baseline model; Setting unit 22 is used to set hyperparameters for the baseline model to form the EfficientNet network model. The hyperparameters are set as follows: initial learning rate 0.001, batch size 32, total number of iterations 100, and weight decay coefficient 0.0001. Optimization unit 23 is used to introduce mixed precision training techniques during model training to optimize the EfficientNet network model; In this embodiment, the building unit 21 includes: Input layer subunit 211 is used to set up the input layer to unify the size of the input image. A normalization layer is set after the input layer to make the distribution of the input data consistent with the distribution of the data during model pre-training. Feature subunit 212 is used to build 16 MBConv blocks and construct a feature extractor based on the 16 MBConv blocks; Output layer subunit 213 is used to construct the output layer. Global average pooling is used to compress the final feature map into a 1×1×C vector, which is then connected to a fully connected layer with an output dimension of 4. Finally, the probability of each level is output through the Softmax activation function. In this embodiment, the optimization unit 23 includes: Maintenance subunit 231 is used to maintain weights and activation values ​​in both FP16 and FP32 formats during network training. FP16 computation is allocated for computationally intensive operators, while FP32 computation is forced for precision-sensitive operators. Adjust subunit 232 is used to set the initial scaling factor range and dynamically adjust the gradient value according to the scaling factor during backpropagation. The detection subunit 233 is used to establish a gradient overflow detection mechanism. Based on the gradient overflow detection mechanism, the real-time gradient value in the backpropagation process is judged. When the gradient is non-numerical or infinite, the scaling factor is adjusted and the forward and backward propagation of the current batch is recalculated. Optimization subunit 234 is used to dynamically optimize the operator precision configuration based on historical overflow records in order to stabilize the model training process; In this embodiment, the training module 30 includes: Enhancement unit 31 is used to enhance samples in the dataset, the enhancement process including random flipping, random cropping, brightness and contrast adjustment, and random Gaussian blur; The partitioning unit 32 is used to divide the dataset proportionally using stratified sampling to obtain the training set, validation set, and test set; The adjustment unit 33 is used to calculate the weights of various types of samples in the training set, validation set, and test set. It adopts the Cross-Entropy Loss function and adjusts the model's error sensitivity to minority class samples during training based on the weights of various types of samples. Training unit 34 is used to train the EfficientNet network model using the training set. After every 10 iterations, the model performance is evaluated using the validation set. After training, the model is evaluated using the test set to obtain the photo sharpness classification and scoring model. In this embodiment, the detection module 40 includes: Preprocessing unit 41 is used to acquire photos uploaded by the courier in real time, preprocess the uploaded photos in real time, and obtain preprocessed photos; The calculation unit 42 is used to classify the preprocessed photo using a photo sharpness classification scoring model to obtain a classification result, wherein the classification result includes the probability of multiple sharpness levels. Scoring unit 43 is used to convert the final classification result into a score by taking the sharpness level with the highest probability as the final classification result; Judgment unit 44 is used to set the pass threshold, and to judge whether the photos uploaded by the courier in real time are qualified by combining the final classification result and the pass threshold. It outputs the classification result, score and pass judgment result.

[0052] The image sharpness detection device for door-to-door express delivery signing of this invention first collects sample photos of express delivery signing, and accurately labels them according to sharpness levels to build a dataset, laying a solid data foundation for subsequent model training. Then, an EfficientNet network model is built, and mixed-precision training technology is introduced to optimize it, which not only significantly improves the model training efficiency but also further enhances the model performance, enabling it to maintain excellent feature recognition capabilities even in complex image scenes. Next, the optimized EfficientNet network model is trained using the previously built high-quality dataset, and Cross-Entropy Loss is selected as the loss function to efficiently solve the sample imbalance problem in the sample classification process. Finally, the trained photo sharpness classification and scoring model is deployed to a real-time scene to classify and score real-time uploaded photos, realizing real-time supervision of photo sharpness. This method can quickly identify cases where the sharpness of uploaded photos does not meet the standards, providing reliable and efficient technical support for the quality control of express delivery signing photos, effectively ensuring the quality standards of signing photos, and contributing to the standardized management of key image data in the express delivery business process.

[0053] The above describes the door-to-door delivery image clarity detection device in this embodiment of the invention from the perspective of modular functional entities. The following describes the door-to-door delivery image clarity detection device in this embodiment of the invention from the perspective of hardware processing.

[0054] Figure 10 This is a schematic diagram of the structure of a door-to-door delivery image clarity detection device 900 provided in an embodiment of the present invention. The door-to-door delivery image clarity detection device 900 can vary significantly due to different configurations or performance. It may include one or more central processing units (CPUs) 910 (e.g., one or more processors) and a memory 920, and one or more storage media 930 (e.g., one or more mass storage devices) storing application programs 933 or data 932. The memory 920 and storage media 930 can be temporary or persistent storage. The program stored in the storage media 930 may include one or more modules (not shown in the diagram), each module may include a series of instruction operations on the door-to-door delivery image clarity detection device 900. Furthermore, the processor 910 may be configured to communicate with the storage media 930 and execute a series of instruction operations in the storage media 930 on the door-to-door delivery image clarity detection device 900 to implement the steps of the door-to-door delivery image clarity detection method provided in the above-described method embodiments.

[0055] The on-site image sharpness inspection device 900 may also include one or more power supplies 940, one or more wired or wireless network interfaces 950, one or more input / output interfaces 960, and / or one or more operating systems 931, such as Windows Server, Mac OS X, Unix, Linux, FreeBSD, etc. Those skilled in the art will understand that... Figure 10 The illustrated structure of the on-site delivery image clarity testing device does not constitute a limitation on the on-site delivery image clarity testing device. It may include more or fewer components than illustrated, or combine certain components, or have different component arrangements.

[0056] The present invention also provides a computer-readable storage medium, which can be a non-volatile computer-readable storage medium or a volatile computer-readable storage medium, wherein the computer-readable storage medium stores instructions that, when executed on a computer, cause the computer to perform the steps of the on-site signing image clarity detection method.

[0057] Those skilled in the art will clearly understand that, for the sake of convenience and brevity, the specific working process of the device or apparatus described above can be referred to the corresponding process in the foregoing method embodiments, and will not be repeated here.

[0058] If the integrated unit is implemented as a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention, in essence, or the part that contributes to the prior art, 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 several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of the present invention. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.

[0059] It is understood that those skilled in the art can make equivalent substitutions or modifications to the technical solution and inventive concept of the present invention, and all such substitutions or modifications should fall within the protection scope of the appended claims.

Claims

1. A method for detecting the clarity of images received upon home delivery, characterized in that, Includes the following steps: Obtain sample photos of express delivery signatures, and label the sample photos according to their clarity level to obtain a dataset; An EfficientNet network model was constructed, and a mixed precision training technique was introduced during the model training process to optimize the EfficientNet network model. The EfficientNet network model was trained using a dataset, and Cross-Entropy Loss was used as the loss function to obtain a photo sharpness classification and scoring model. The system acquires photos uploaded by couriers in real time, uses a photo clarity classification and scoring model to classify and score the uploaded photos, and outputs the classification and scoring results in real time.

2. The method for detecting the clarity of images upon on-site delivery as described in claim 1, characterized in that, The process of obtaining sample photos of express delivery signatures and labeling them according to their clarity level to obtain a dataset specifically includes: Obtain sample photos of express delivery signing in different scenarios, including express delivery type, shooting equipment, environmental conditions, and shooting operation data; Based on the text content, key information on the waybill, and characteristics of the package, a clarity level standard was established, and a labeling tool was used to label the sample photos of express delivery signatures according to the clarity level standard. All labeled express delivery receipt photos are categorized and stored according to their clarity level, generating metadata files containing image paths, labeling levels, labelers, and review results, thus forming a complete labeled dataset.

3. The method for detecting the clarity of images upon on-site delivery as described in claim 1, characterized in that, The construction of the EfficientNet network model, which incorporates mixed-precision training techniques during model training to optimize the EfficientNet network model, specifically includes: Construct the EfficientNet-B0 model as the baseline model, and build each MBConv block for the baseline model; Hyperparameters were set for the baseline model to form the EfficientNet network model. The hyperparameters were set as follows: initial learning rate 0.001, batch size 32, total number of iterations 100, and weight decay coefficient 0.0001. Hybrid precision training techniques are introduced during model training to optimize the EfficientNet network model.

4. The method for detecting the clarity of images upon on-site delivery as described in claim 3, characterized in that, The construction of the EfficientNet-B0 model as a baseline model, and the building of each MBConv block for the baseline model, specifically includes: Set up an input layer to unify the size of the input images, and set up a normalization layer after the input layer to make the distribution of the input data consistent with the distribution of the data during model pre-training; Construct 16 MBConv blocks, and build a feature extractor based on the 16 MBConv blocks; The output layer is constructed, and global average pooling is used to compress the final feature map into a 1×1×C vector. Then, a fully connected layer with an output dimension of 4 is connected, and finally, the probability of each level is output through the Softmax activation function.

5. The method for detecting the clarity of images upon on-site delivery as described in claim 3, characterized in that, The introduction of mixed precision training techniques during model training to optimize the EfficientNet network model specifically includes: During network training, both FP16 and FP32 format weights and activation values ​​are maintained simultaneously. FP16 computation is allocated for computationally intensive operators, while FP32 computation is forced for precision-sensitive operators. Set the initial scaling factor range, and dynamically adjust the gradient values ​​during backpropagation based on the scaling factor; Establish a gradient overflow detection mechanism. Based on the gradient overflow detection mechanism, judge the real-time gradient value during the backpropagation process. When the gradient is non-numerical or infinite, adjust the scaling factor and recalculate the forward and backward propagation of the current batch. The operator precision configuration is dynamically optimized based on historical overflow records to stabilize the model training process.

6. The method for detecting the clarity of images upon on-site delivery as described in claim 1, characterized in that, The method involves training the EfficientNet network model using a dataset and employing Cross-Entropy Loss as the loss function to obtain a photo sharpness classification and scoring model, specifically including: The samples in the dataset are enhanced, including random flipping, random cropping, brightness and contrast adjustment, and random Gaussian blurring. Stratified sampling is used to divide the dataset proportionally to obtain training, validation, and test sets. Calculate the weights of each type of sample in the training set, validation set, and test set, and use the Cross-Entropy Loss function to adjust the model's error sensitivity to minority class samples during training based on the weights of each type of sample. The EfficientNet network model is trained using the training set. After every 10 iterations, the model performance is evaluated using the validation set. After training, the model is evaluated using the test set to obtain a photo sharpness classification and scoring model.

7. The method for detecting the clarity of images upon on-site delivery as described in claim 1, characterized in that, The process of acquiring photos uploaded in real time by delivery personnel involves using a photo clarity classification and scoring model to classify and score the uploaded photos, and outputting the classification and scoring results in real time. Specifically, this includes: Get photos uploaded by couriers in real time, preprocess the uploaded photos, and obtain preprocessed photos; A photo sharpness classification and scoring model is used to classify preprocessed photos to obtain classification results, which include the probabilities of multiple sharpness levels. The clarity level with the highest probability is used as the final classification result, and the final classification result is converted into a score; Set a passing threshold, combine the final classification result and the passing threshold to determine whether the photos uploaded by the courier in real time are qualified, and output the classification result, score and qualification judgment result.

8. A device for detecting the clarity of images received upon home delivery, characterized in that, include: The annotation module is used to obtain sample photos of express delivery signatures and to annotate these photos according to their clarity level in order to obtain a dataset. The building blocks are used to construct the EfficientNet network model and introduce mixed precision training techniques during model training to optimize the EfficientNet network model. The training module is used to train the EfficientNet network model using the dataset and uses Cross-EntropyLoss as the loss function to obtain a photo sharpness classification and scoring model. The detection module is used to acquire photos uploaded by couriers in real time, and uses a photo clarity classification and scoring model to classify and score the uploaded photos in real time, and outputs the classification and scoring results in real time.

9. A device for detecting the clarity of images upon on-site delivery, characterized in that, It includes a memory and at least one processor, wherein the memory stores computer-readable instructions; The at least one processor invokes the computer-readable instructions in the memory to perform the steps of the door-to-door delivery image clarity detection method as described in any one of claims 1-7.

10. A computer-readable storage medium storing computer-readable instructions thereon, characterized in that, When the computer-readable instructions are executed by a processor, they implement the steps of the image clarity detection method for door-to-door delivery as described in any one of claims 1-7.