CN115393627A - Express mail weight abnormity identification method, device, equipment and storage medium - Google Patents

Express mail weight abnormity identification method, device, equipment and storage medium Download PDF

Info

Publication number
CN115393627A
CN115393627A CN202210906150.3A CN202210906150A CN115393627A CN 115393627 A CN115393627 A CN 115393627A CN 202210906150 A CN202210906150 A CN 202210906150A CN 115393627 A CN115393627 A CN 115393627A
Authority
CN
China
Prior art keywords
image
express
weight
data
training sample
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202210906150.3A
Other languages
Chinese (zh)
Inventor
曾月
李斯
杨周龙
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Dongpu Software Co Ltd
Original Assignee
Dongpu Software Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Dongpu Software Co Ltd filed Critical Dongpu Software Co Ltd
Priority to CN202210906150.3A priority Critical patent/CN115393627A/en
Publication of CN115393627A publication Critical patent/CN115393627A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V10/00Arrangements for image or video recognition or understanding
    • G06V10/70Arrangements for image or video recognition or understanding using pattern recognition or machine learning
    • G06V10/764Arrangements for image or video recognition or understanding using pattern recognition or machine learning using classification, e.g. of video objects
    • G06V10/765Arrangements for image or video recognition or understanding using pattern recognition or machine learning using classification, e.g. of video objects using rules for classification or partitioning the feature space
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V10/00Arrangements for image or video recognition or understanding
    • G06V10/70Arrangements for image or video recognition or understanding using pattern recognition or machine learning
    • G06V10/77Processing image or video features in feature spaces; using data integration or data reduction, e.g. principal component analysis [PCA] or independent component analysis [ICA] or self-organising maps [SOM]; Blind source separation
    • G06V10/774Generating sets of training patterns; Bootstrap methods, e.g. bagging or boosting
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V10/00Arrangements for image or video recognition or understanding
    • G06V10/70Arrangements for image or video recognition or understanding using pattern recognition or machine learning
    • G06V10/82Arrangements for image or video recognition or understanding using pattern recognition or machine learning using neural networks

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Evolutionary Computation (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Computing Systems (AREA)
  • Databases & Information Systems (AREA)
  • Health & Medical Sciences (AREA)
  • General Health & Medical Sciences (AREA)
  • Medical Informatics (AREA)
  • Software Systems (AREA)
  • Artificial Intelligence (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Multimedia (AREA)
  • Image Analysis (AREA)

Abstract

The invention relates to the technical field of detection, and discloses a method, a device, equipment and a storage medium for identifying express item weight abnormality. The method comprises the following steps: screening a plurality of acquired first images for weighing the packages to obtain training sample images; classifying and labeling express items in the training sample image to obtain labeled data; carrying out data augmentation on the training sample image to obtain a target data set; inputting the target data set and the labeling file into a preset GoogLeNet model for training to obtain an image classification model; and acquiring a second image in the express item weighing scene captured in real time, and inputting the second image into an image classification model for classification and prediction to obtain weight abnormity categories corresponding to the plurality of second images. According to the scheme, the express image is identified and detected, so that the problems of low detection efficiency and low detection accuracy of the express with abnormal weight in the prior art are solved.

Description

Express mail weight abnormity identification method, device, equipment and storage medium
Technical Field
The invention relates to the technical field of detection, in particular to a method, a device, equipment and a storage medium for identifying express item weight abnormity.
Background
The center of allocating can weigh the parcel when the letter sorting, and there is sorting person's operation improper, and artificial messenger parcel weight appears unusually, needs artifical symmetrical heavy unusual parcel to carry out repeated weighing, extravagant unnecessary time and manpower. In order to reduce the condition of weighing abnormity caused by the manual operation, the computer vision technology is utilized, the images captured by the weighing platform are classified by utilizing an image classification model, packages which are abnormally weighed and are caused by improper operation of sorting personnel are identified, and secondary weighing is carried out. Therefore, how to improve the detection efficiency and the detection accuracy rate of the express items with abnormal weight becomes a technical problem to be solved by the technical personnel in the field.
Disclosure of Invention
The invention mainly aims to solve the problems of low detection efficiency and low detection accuracy of the express with abnormal weight in the prior art by identifying and detecting the express image.
The invention provides a method for identifying abnormal express item weight in a first aspect, which comprises the following steps: acquiring a plurality of first images for weighing packages in a pre-shot express sorting scene, and screening out target images with package weighing abnormality from the first images based on a preset abnormality judgment threshold value to serve as training sample images; classifying and labeling the express mails in the training sample image to obtain labeled data, wherein the labeled data comprises a label type; performing data augmentation on the training sample image to obtain a target data set after data augmentation; dividing the target data set into a training sample set and a verification sample set according to a preset proportion, and inputting the training sample set and the label file into a preset GoogLeNet model for training to obtain an image classification model; and acquiring a plurality of second images in a real-time snapshot express item weighing scene, inputting the second images into the image classification model for classification and prediction, and obtaining a plurality of weight abnormity categories corresponding to the second images.
Optionally, in a first implementation manner of the first aspect of the present invention, before the acquiring a plurality of first images of packages weighed in a pre-shot express sorting scene, and screening out a target image of package weighing abnormality from the first images based on a preset abnormality judgment threshold as a training sample image, the method further includes: identifying whether the parcel has distribution weight data on the current distribution node; if the package is not distributed to the current distribution point, historical distribution weight data of the package on the historical distribution node before the current distribution point are obtained, and an initial abnormity judgment threshold value is calculated according to the historical distribution weight data; if the parcel weight distribution quantity exists, acquiring real-time distribution weight data of the parcel at the current distribution point and historical distribution weight data on the historical distribution node, and calculating a parcel weighing abnormal threshold according to the historical distribution weight data and the real-time distribution weight data.
Optionally, in a second implementation manner of the first aspect of the present invention, before the classifying and labeling the express mails in the training sample image to obtain labeled data, the method further includes: judging whether the resolution corresponding to the first image is higher than a preset resolution threshold value or not; and if so, eliminating image data of a pre-marked area in the first image which does not meet a preset condition to obtain a training sample image, wherein the density of the marked area in the first image is greater than a density threshold value.
Optionally, in a third implementation manner of the first aspect of the present invention, the performing data amplification on the training sample image to obtain a data-amplified target data set includes: acquiring initial labeling information of pixels corresponding to the training sample image; constructing a label generation network, and generating target label information based on the initial label data and the label generation network; inputting the target labeling information into a preset style migration network to obtain a virtual image corresponding to the training sample image; generating an image data augmentation network based on the label generation network and the style migration network, and training the image data augmentation network based on the training sample image and the initial label information through a loss function of a preset discriminator to obtain a data augmentation model; and inputting the training sample image into the data augmentation model for data augmentation to obtain a target data set after data augmentation.
Optionally, in a fourth implementation manner of the first aspect of the present invention, the inputting the training sample set and the markup file into a preset google lenet model for training to obtain an image classification model includes: inputting the training sample set into a preset GoogLeNet model to obtain a model output result; calculating the loss of the GoogLeNet model by using a loss function according to the model output result; and adjusting the weight parameters which are not frozen in the GoogLeNet model according to the loss until a convergence condition is reached to obtain an image classification model.
Optionally, in a fifth implementation manner of the first aspect of the present invention, the inputting the second image into the image classification model for classification and prediction to obtain a plurality of weight abnormality classes corresponding to the second image includes: inputting the second image into the image classification model for classification prediction to obtain a plurality of label categories corresponding to the second image and the probability of each label category; and judging whether the probability of each label category is greater than a preset probability threshold value, and determining the label category of which the probability meets the target requirement as the image category corresponding to the second image.
Optionally, in a sixth implementation manner of the first aspect of the present invention, after the inputting the second image into the image classification model for classification and prediction to obtain a plurality of weight abnormality categories corresponding to the second image, the method further includes: inputting the second image into a preset express item identification model to obtain an abnormal express item image corresponding to each express item in the second image; extracting the express item number of the express item with the abnormal weight; and generating a weight abnormal express record according to the express single number pair, and uploading the weight abnormal express record to a preset express management end.
The invention provides a device for identifying abnormal express item weight in a second aspect, which comprises: the screening module is used for acquiring a plurality of first images for weighing packages in a pre-shot express sorting scene, and screening out target images with package weighing abnormality from the first images based on a preset abnormality judgment threshold value to serve as training sample images; the labeling module is used for carrying out classification labeling on the express mails in the training sample image to obtain labeling data, wherein the labeling data comprises label types; the data amplification module is used for performing data amplification on the training sample image to obtain a target data set after the data amplification; the training module is used for dividing the target data set into a training sample set and a verification sample set according to a preset proportion, and inputting the training sample set and the labeling file into a preset GoogLeNet model for training to obtain an image classification model; and the prediction module is used for acquiring a plurality of second images in a real-time snapshot express weighing scene, inputting the second images into the image classification model for classification prediction, and obtaining weight abnormality categories corresponding to the plurality of second images.
Optionally, in a first implementation manner of the second aspect of the present invention, the device for identifying weight abnormality of the express mail further includes: the identification module is used for identifying whether the parcel has distribution weight data on the current distribution node; the calculation module is used for acquiring historical distribution weight data of the packages on a node Shi Fenbo in front of the current distribution point if the packages do not exist, and calculating an initial abnormity judgment threshold value according to the historical distribution weight data; and if the current distribution point exists, acquiring real-time distribution weight data of the parcel at the current distribution point and historical distribution weight data on the historical distribution node, and calculating a parcel weighing abnormal threshold according to the historical distribution weight data and the real-time distribution weight data.
Optionally, in a second implementation manner of the second aspect of the present invention, the device for identifying an abnormal express item weight further includes: the judging module is used for judging whether the corresponding resolution of the first image is higher than a preset resolution threshold value; and if so, rejecting image data of which the pre-labeled area in the first image does not meet the preset condition to obtain a training sample image, wherein the density of the labeled area in the first image is greater than a density threshold.
Optionally, in a third implementation manner of the second aspect of the present invention, the data amplification module is specifically configured to: acquiring initial labeling information of pixels corresponding to the training sample image; constructing a label generation network, and generating target label information based on the initial label data and the label generation network; inputting the target labeling information into a preset style migration network to obtain a virtual image corresponding to the training sample image; generating an image data augmentation network based on the label generation network and the style migration network, and training the image data augmentation network through a loss function of a preset discriminator based on the training sample image and the initial label information to obtain a data augmentation model; and inputting the training sample image into the data augmentation model for data augmentation to obtain a target data set after data augmentation.
Optionally, in a fourth implementation manner of the second aspect of the present invention, the training module is specifically configured to: inputting the training sample set into a preset GoogLeNet model to obtain a model output result; calculating the loss of the GoogLeNet model by using a loss function according to the model output result; and adjusting the weight parameters which are not frozen in the GoogLeNet model according to the loss until a convergence condition is reached to obtain an image classification model.
Optionally, in a fifth implementation manner of the second aspect of the present invention, the prediction module includes: the prediction unit is used for inputting the second image into the image classification model for classification prediction to obtain a plurality of label categories corresponding to the second image and the probability of each label category; and the determining unit is used for judging whether the probability of each label category is greater than a preset probability threshold value or not, and determining the label category of which the probability meets the target requirement as the image category corresponding to the second image.
Optionally, in a sixth implementation manner of the second aspect of the present invention, the device for identifying weight abnormality of express items further includes: the input module is used for inputting the second image into a preset express item identification model to obtain an abnormal-weight express item image corresponding to each express item in the second image; the extracting module is used for extracting the express item number of the express item with the abnormal weight; and the uploading module is used for uploading the record of the abnormal express items with the weight generated according to the express item single number pair and uploading the record of the abnormal express items with the weight to a preset express item management end.
The third aspect of the invention provides an identification device for express item weight abnormality, which comprises: a memory having instructions stored therein and at least one processor, the memory and the at least one processor interconnected by a line;
the at least one processor calls the instructions in the memory to enable the express weight abnormity identification device to execute the steps of the express weight abnormity identification method.
A fourth aspect of the present invention provides a computer-readable storage medium, which stores instructions that, when executed on a computer, cause the computer to perform the steps of the above-mentioned identification method for express weight abnormality.
According to the technical scheme provided by the invention, a plurality of acquired first images for weighing the packages are screened to obtain training sample images; classifying and labeling express items in the training sample image to obtain labeled data; carrying out data augmentation on the training sample image to obtain a target data set; inputting the target data set and the labeling file into a preset GoogLeNet model for training to obtain an image classification model; and acquiring a second image in a real-time captured express item weighing scene, inputting the second image into an image classification model for classification and prediction, and obtaining weight abnormity categories corresponding to a plurality of second images. According to the scheme, the problem that the detection efficiency and the detection accuracy rate of the express mail with abnormal weight are low in the prior art is solved by identifying and detecting the express mail image.
Drawings
Fig. 1 is a schematic view of a first embodiment of an identification method for express weight abnormality provided by the present invention;
FIG. 2 is a schematic diagram of a second embodiment of the method for identifying abnormal express item weight provided by the present invention;
FIG. 3 is a schematic diagram of a third embodiment of the method for identifying abnormal express item weight provided by the present invention;
FIG. 4 is a schematic view of a first embodiment of the device for identifying abnormality in the weight of the express item provided by the invention;
FIG. 5 is a schematic view of a second embodiment of the device for identifying abnormality in the weight of the express item provided by the invention;
fig. 6 is a schematic view of an embodiment of the device for identifying the abnormal express item weight provided by the invention.
Detailed Description
The embodiment of the invention provides a method, a device, equipment and a storage medium for identifying express item weight abnormality, wherein in the technical scheme of the invention, firstly, a plurality of acquired first images for weighing packages are screened to obtain training sample images; classifying and labeling express items in the training sample image to obtain labeled data; carrying out data augmentation on the training sample image to obtain a target data set; inputting the target data set and the labeling file into a preset GoogLeNet model for training to obtain an image classification model; and acquiring a second image in the real-time captured express item weighing scene, and inputting the second image into an image classification model for classification and prediction to obtain weight abnormity categories corresponding to the plurality of second images. According to the scheme, the problem that the detection efficiency and the detection accuracy rate of the express mail with abnormal weight are low in the prior art is solved by identifying and detecting the express mail image.
The terms "first," "second," "third," "fourth," and the like in the description and in the claims, as well as in the drawings, if any, are used for distinguishing between similar elements and not necessarily for describing a particular sequential or chronological order. It will be appreciated that the data so used may be interchanged under appropriate circumstances such that the embodiments described herein may be practiced otherwise than as specifically illustrated or described herein. Furthermore, the terms "comprises," "comprising," or "having," and any variations thereof, are intended to cover non-exclusive inclusions, such that a process, method, system, article, or apparatus that comprises a list of steps or elements is not necessarily limited to those steps or elements expressly listed, but may include other steps or elements not expressly listed or inherent to such process, method, article, or apparatus.
For convenience of understanding, a specific flow of the embodiment of the present invention is described below, and referring to fig. 1, a first embodiment of the method for identifying weight abnormality of express mail in the embodiment of the present invention includes:
101. acquiring a plurality of first images for weighing packages in a pre-shot express sorting scene, and screening out target images with package weighing abnormality from the first images based on a preset abnormality judgment threshold value to serve as training sample images;
in this embodiment, it can be understood that the execution main body of the present invention may be an identification apparatus for identifying express weight abnormality, and may also be a terminal or a server, which is not limited herein. The embodiment of the present invention is described by taking a server as an execution subject.
In this embodiment, a plurality of first images of packages being weighed in an express sorting scene are first captured by a camera or other device. For example, the shape of the express mail on the conveyor belt is rectangular, circular, irregular, and the like. The server then reads the stored first image as a training sample image.
102. Classifying and labeling express items in the training sample image to obtain labeled data, wherein the labeled data comprises label types;
in this embodiment, the training sample image is input into preset image labeling software for display. Preferably, labelme software is used as the image annotation software. And selecting the express in the image by using a closed line connected with the head through interactive equipment in a manual mode. And the server defines the express item area in the training sample image according to the position coordinate corresponding to the closed line to obtain an image containing the marked express item area range, namely marking information.
103. Carrying out data augmentation on the training sample image to obtain a target data set after data augmentation;
in the embodiment, a target image and target marking data thereof are obtained; constructing an annotation generation network and a style migration network; taking the output of the label generation network as the input of the style migration network, combining the label generation network and the style migration network into an image data augmentation network, and training the image data augmentation network by adopting a loss function based on a generator and a discriminator based on a target image and a target label thereof; and generating a target image to be augmented and a virtual image and a virtual label corresponding to the target label of the target image to be augmented by using the trained image data augmentation network, and using the target image to be augmented and the virtual image and the virtual label as data augmentation of the target image to be augmented and the target label of the target image to be augmented so as to obtain a target data set after data augmentation.
104. Dividing a target data set into a training sample set and a verification sample set according to a preset proportion, and inputting the training sample set and a label file into a preset GoogLeNet model for training to obtain an image classification model;
in this embodiment, the training sample set is input to a preset google lenet model, and the attention mechanism module is inserted between a convolutional layer (i.e., a feature extractor) and a full connection layer (i.e., a classifier) to adjust the features extracted by the convolutional layer in two dimensions, i.e., a channel and a space, respectively, and then the adjusted feature map is input to the full connection layer of the residual network, so that the features more useful for the classification task are enhanced, and the features less useful for the classification task are suppressed. Then, the loss of the google lenet model is calculated by using a loss function, the backward propagation of the loss adopts a random gradient descent method based on momentum to accelerate convergence, and the momentum factor is momentum =0.9.
Adjusting the non-frozen weight parameters in the image classification model according to the loss comprises: according to the model output result and the balance factor, adjusting the weight parameters of the convolution layer which is not frozen based on the first learning rate; adjusting the weight parameter of the full connection layer based on the second learning rate according to the model output result and the balance factor; wherein the first learning rate is less than the second learning rate; the balance factor is the ratio of the number of samples labeled by each classification label in the training data set to the total number of samples in the training data set.
105. And acquiring a plurality of second images in the express item weighing scene captured in real time, inputting the second images into an image classification model for classification and prediction, and obtaining weight abnormity categories corresponding to the plurality of second images.
In this embodiment, the image classification model is called to classify, identify and process the plurality of second images in the express item weighing scene captured in real time, and the process of obtaining the weight abnormality category corresponding to the image is as follows: calling an image classification model to identify the second image to obtain a plurality of reference classes corresponding to the second image and the probability of each reference class; and determining the reference category with the probability meeting the target requirement as the weight anomaly category corresponding to the second image.
The process of calling the image classification model to identify the second image and obtaining a plurality of reference categories corresponding to the second image and the probability of each reference category is as follows: and inputting the second image into the image classification model, and identifying the second image based on the image classification model to obtain a plurality of reference classes corresponding to the second image and the probability of each reference class. The reference category with the probability meeting the target requirement may be the reference category with the maximum probability, or may be another reference category, which is not limited in the embodiment of the present application.
For example, a second image is input into the image classification model, the image classification model identifies the second image, and the probabilities of a plurality of reference classes corresponding to the target image and each reference class are respectively: a first reference class, 80%, a second reference class, 15%, a third reference class, 5%. And determining the first reference category as the weight abnormity category corresponding to the target image because the probability of the first reference category is the maximum.
In the embodiment of the invention, a plurality of acquired first images for weighing packages are screened to obtain training sample images; classifying and labeling express items in the training sample image to obtain labeled data; carrying out data augmentation on the training sample image to obtain a target data set; inputting the target data set and the labeling file into a preset GoogLeNet model for training to obtain an image classification model; and acquiring a second image in the express item weighing scene captured in real time, and inputting the second image into an image classification model for classification and prediction to obtain weight abnormity categories corresponding to a plurality of second images. According to the scheme, the express image is identified and detected, so that the problems of low detection efficiency and low detection accuracy of the express with abnormal weight in the prior art are solved.
Referring to fig. 2, a second embodiment of the method for identifying weight abnormality of express items according to the embodiment of the present invention includes:
201. identifying whether the parcel has distribution weight data on the current distribution node;
in the embodiment, in order to solve the problem that the detection efficiency and the detection accuracy of the express items with abnormal weight are low in the prior art, the express items to be subjected to weight detection are arranged in sequence to generate a sequence to be weighed.
Specifically, in the process of transporting the express, a plurality of links are required to carry out weight detection and checking operation on the express so as to conveniently master the weight state of the express at any time for subsequent inquiry; for example, weight detection is performed at each distribution point, weight detection is performed before delivery at the end, and the like, and after data of weight detection is obtained, the weight data is stored in the express mail database as historical weight data according to the detected single number of the express mail. And subsequently, according to historical weight data in the express item database, information such as a responsible party of the goods loss can be determined when abnormal conditions such as article damage occur in the express items.
202. If the historical distribution weight data does not exist, acquiring historical distribution weight data wrapped on the historical distribution nodes before the current distribution point, and calculating an initial abnormity judgment threshold according to the historical distribution weight data;
in this embodiment, the historical weight data may be all historical weight data before a current time node for performing weight anomaly detection, and when performing weight detection on express items in a sequence to be weighed, mechanical devices such as a manipulator and the like are generally adopted to sequentially place the express items in the sequence to be weighed on a weighing platform for weighing, so as to obtain the express item weight of the current express item at the current node; in addition, before weighing or weighing, the two-dimensional code or the identification tags such as the induction tags on the express are scanned to obtain the single number corresponding to the express, historical weight data of the express during weight detection operation before weight detection is inquired in an express database according to the single number corresponding to the express, wherein the historical weight data are multiple for one express to be weighed.
And acquiring a preset abnormality judgment rule, and calculating an abnormality judgment threshold value of the node weight detection according to the abnormality judgment rule based on the acquired historical weight data.
203. If the package weight distribution abnormal threshold exists, acquiring real-time distribution weight data of the package at the current distribution point and historical distribution weight data on a historical distribution node, and calculating the package weighing abnormal threshold according to the historical distribution weight data and the real-time distribution weight data;
in the embodiment, the real-time distribution weight data of the express mail at the current distribution point and the historical distribution weight data at the historical distribution node are obtained, the invalid data values in the first distribution weight data and the real-time distribution weight data are removed according to a preset invalid data value removing rule, and the remaining distribution weight data form second valid historical weight data; sequencing the second effective historical weight data to obtain a second effective historical weight sequence; and screening the second effective historical weight data in the second effective historical weight sequence according to a preset index screening rule to obtain second weight index data.
Specifically, when the second weight index data is calculated, according to a preset invalid data value removing rule, removing invalid data values in the real-time allocated weight data to obtain valid historical weight data; wherein the invalid data values comprise null values and coarse error values.
Sequencing the second effective historical weight data to obtain a second effective historical weight sequence; extracting the maximum value of the weight data in the second effective historical weight sequence and the adjacent weight data value of the maximum value of the weight data according to the sorting sequence in the second effective historical weight sequence; and judging whether the difference value between the maximum value of the weight data and the adjacent weight data value is larger than a preset screening threshold value. And calculating based on the first weight index data according to a preset threshold calculation rule to obtain a second abnormal judgment threshold.
204. Acquiring a plurality of first images for weighing packages in a pre-shot express sorting scene, and screening out target images with package weighing abnormality from the first images based on a preset abnormality judgment threshold value to serve as training sample images;
205. judging whether the corresponding resolution of the first image is higher than a preset resolution threshold value or not;
in this embodiment, the first image may be image data that has undergone preliminary screening, or may be image data that is directly obtained from a network environment, and the format of the target image data may be common image formats such as jpg, png, jpeg, and the like.
In this embodiment, the resolution of the image may affect the actual effect of the initial image classification model, and in order to ensure the accuracy of the initial image classification model obtained by training, the resolution of the first image needs to be limited in advance. The first image needs to be marked with an area by using the existing other image recognition models, the image recognition models can be selected according to the type of the first image, for example, if the first image is a portrait of a human, the image recognition models can be face recognition models with a face recognition function, and can be specifically selected according to actual requirements, and the selection is not limited here.
206. If so, eliminating image data of a pre-marked area in the first image which does not accord with a preset condition to obtain a training sample image, wherein the density of the marked area in the first image is greater than a density threshold value;
in this embodiment, the preset condition may be determined according to a characteristic of the first image, for example, a congestion degree of the labeling area, a blocking condition of the labeling area, and the like. Furthermore, the first image can be classified through image classification data trained in advance, the first image is preliminarily screened according to the confidence degree of the obtained classification result, and image data with low confidence degree in the first image are removed to obtain a training sample image.
207. Classifying and labeling express items in the training sample image to obtain labeled data;
208. carrying out data augmentation on the training sample image to obtain a target data set after data augmentation;
209. inputting the training sample set into a preset GoogLeNet model to obtain a model output result;
in this embodiment, the training sample set is input to a preset google lenet model, and the attention mechanism module is inserted between a convolutional layer (i.e., a feature extractor) and a full connection layer (i.e., a classifier) to adjust the features extracted by the convolutional layer in two dimensions, i.e., a channel and a space, respectively, and then the adjusted feature map is input to the full connection layer of the residual network, so that the features more useful for the classification task are enhanced, and the features less useful for the classification task are suppressed.
Specifically, the first characteristic diagram output by the conv5_ x layer (i.e., the fifth convolutional layer) of the residual network wide rescet 50 is Fin, where Fin has a size of [ C, H, W ]. Firstly, inputting a first characteristic diagram Fin into an attention mechanism module for average pooling and maximum pooling respectively to obtain two descriptors [ C,1,1], then enabling the two descriptors to pass through a shared two-layer full connection layer MLP respectively and then adding to obtain a channel attention diagram [ C,1,1], and marking the channel attention diagram as Mc, wherein the Mc is a characteristic parameter of the first characteristic diagram Fin on a channel dimension, and a model output result is obtained.
210. Calculating the loss of the GoogLeNet model by using a loss function according to the output result of the model;
in this embodiment, the loss of the google lenet model is calculated by using a loss function, a random gradient descent method based on momentum is adopted for back propagation of the loss to accelerate convergence, and the momentum factor is momentum =0.9.
Then, the weight parameters in the fourth convolutional layer and the fifth convolutional layer are adjusted by using a first learning rate, and the first learning rate is set to be 0.001; adjusting the weight parameters in the attention mechanism module and the last full-connection layer of the residual error network by using a second learning rate, wherein the second learning rate is set to be 0.01; and freezing parameters in other layers without updating. In the training process, the size of the parameter learning rate is halved every 5 iterations.
211. Adjusting the weight parameters which are not frozen in the GoogLeNet model according to the loss function until a convergence condition is reached to obtain an image classification model;
in this embodiment, adjusting the non-frozen weight parameter in the image classification model according to the loss includes: adjusting the weight parameters of the not-frozen convolutional layers based on the first learning rate according to the model output result and the balance factor; adjusting the weight parameter of the full connection layer based on the second learning rate according to the model output result and the balance factor; wherein the first learning rate is less than the second learning rate; the balance factor is the ratio of the number of samples labeled by each classification label in the training data set to the total number of samples in the training data set. In particular, the model parameters are optimized using the focal loss function. The model output Y = { Y1, Y2, …, yN +1}, the balance factor a = { α 1, α 2, …, α N +1}, and the concentration parameter γ =2. And the value of the balance factor is determined based on the proportion of the number of samples marked by each classification label in the training data set to the total number of samples in the training data set.
212. And acquiring a plurality of second images in the express item weighing scene captured in real time, inputting the second images into an image classification model for classification and prediction, and obtaining weight abnormity categories corresponding to the plurality of second images.
Steps 204, 207-208, and 212 in this embodiment are similar to steps 101, 102-103, and 105 in the first embodiment, and are not repeated here.
In the embodiment of the invention, a plurality of acquired first images for weighing packages are screened to obtain training sample images; classifying and labeling express items in the training sample image to obtain labeled data; carrying out data augmentation on the training sample image to obtain a target data set; inputting the target data set and the labeling file into a preset GoogLeNet model for training to obtain an image classification model; and acquiring a second image in the express item weighing scene captured in real time, and inputting the second image into an image classification model for classification and prediction to obtain weight abnormity categories corresponding to a plurality of second images. According to the scheme, the express image is identified and detected, so that the problems of low detection efficiency and low detection accuracy of the express with abnormal weight in the prior art are solved.
Referring to fig. 3, a third embodiment of the method for identifying weight abnormality of express items according to the embodiment of the present invention includes:
301. acquiring a plurality of first images for weighing packages in a pre-shot express sorting scene, and screening out target images with package weighing abnormality from the first images based on a preset abnormality judgment threshold value to serve as training sample images;
302. classifying and labeling express items in the training sample image to obtain labeled data, wherein the labeled data comprises label types;
303. acquiring initial labeling information of pixels corresponding to a training sample image;
in the embodiment, training sample images are obtained, and for each image, an image annotation method is adopted to perform pixel-by-pixel two-classification annotation on the training sample images to obtain an initial annotation image; cutting and scaling each image, and adjusting the image to 512 × 512; and forming an image pair by the training sample image and the artificially labeled real semantic image, and dividing the image pair into a training set and a verification set according to a preset proportion. In this embodiment, a preset number of labeled training sample images are obtained after processing, and are divided into a training set and a verification set according to a preset ratio (1:3).
The label generation network comprises a multi-scale label generator and a label discriminator with multi-scale connection; the multi-scale label generator is used for generating multi-scale target labels; and the label discriminator with multi-scale connection is used for calculating discrimination scores and discriminating initial labels and target labels.
304. Constructing a label generation network, and generating target label information based on the initial label data and the label generation network;
in the embodiment, the Label generator (G _ Label) and the Image generator (G _ Image) are connected by using a multi-scale feature, the feature from the G _ Label is converted into a multi-scale Label after being convolved by 1x1, the G _ Image network feature is respectively synthesized with the Label feature with the corresponding resolution by the space module, and finally, the two generators (Label generator and Image generator) output the Label and the Image in pair. In the training process, the Label discriminator (D _ Label) also receives a multi-scale Label as an input, and provides multi-scale gradient propagation for the G _ Label. The Image discriminator (D _ Image) not only discriminates whether the input Image is from the generator output or the real data, but also discriminates whether the Image and its Label coincide, so the D _ Image uses a pair of data input, a pair of output from G _ Label and G _ Image, or a pair of data from the real distribution, that is, the distance between the generated data joint distribution and the real joint distribution is narrowed down by the countermeasure training.
305. Inputting the target labeling information into a preset style migration network to obtain a virtual image corresponding to the training sample image;
in the embodiment, an initial hidden variable z is randomly sampled from multi-dimensional Gaussian distribution, a transposed convolution and a 3 × 3 convolution are used for performing upsampling operation on the initial hidden variable z, and the characteristic size of the initial hidden variable z is enlarged to 4 × 4;
virtual labels of different scales are input into an image generator based on a preset Adaptive-regularization (SPADE) module, parameters reflecting three dimensions of a channel, a width dimension and a height dimension of the features are obtained by extracting feature calculation from the virtual labels, and image synthesis is carried out from a semantic feature map of spatial variation. In the SPADE module, firstly, a semantic feature map is projected to a low-dimensional vector space, and then convolution is performed to generate modulation parameters γ and β, which are different from a common batch normalization method, γ and β are not vectors, but tensors with spatial dimensions, meaning rotation (scale) and shift (shift) parameters to be learned, and are used for controlling the variance and mean of sample distribution. The gamma and beta generated by training are multiplied by the convolution feature map and added to the normalized activation element; and sequentially passing through continuous convolution and interpolation upper sampling layers, so that the characteristic resolution is sequentially enlarged, and finally, a virtual image with the same bottom semantic structure as the virtual annotation is output.
306. Generating an image data augmentation network based on an annotation generation network and a style migration network, and training the image data augmentation network based on training sample images and initial annotation information through a loss function of a preset discriminator to obtain a data augmentation model;
in this embodiment, the image data augmentation network is obtained by merging the multi-scale virtual labels generated by the label generation network as the input of the virtual labels in the style migration network. Specifically, the Label generator (G _ Label) and the Image generator (G _ Image) are connected by using a multi-scale feature, the feature from the G _ Label is converted into a multi-scale Label after being convolved by 1 × 1, the G _ Image network feature is respectively synthesized with the Label feature with the corresponding resolution through a space module, and finally the two generators (Label generator and Image generator) output a pair of Label and Image. In the training process, the Label discriminator (D _ Label) also receives a multi-scale Label as an input, and provides multi-scale gradient propagation for the G _ Label. The Image discriminator (D _ Image) not only distinguishes whether the input Image is from the output of the generator or the real data, but also judges whether the Image is consistent with the Label thereof, so that the D _ Image uses paired data input, paired output from G _ Label and G _ Image or paired data from the real distribution, namely, the distance between the generated data joint distribution and the real joint distribution is shortened through the countermeasure training.
307. Inputting the training sample image into a data augmentation model for data augmentation to obtain a target data set after data augmentation;
in the embodiment, a target image and target marking data thereof are obtained; constructing an annotation generation network and a style migration network; taking the output of the label generation network as the input of the style migration network, combining the label generation network and the style migration network into an image data augmentation network, and training the image data augmentation network by adopting a loss function based on a generator and a discriminator based on a target image and a target label thereof; and generating a target image to be augmented and a virtual image and a virtual label corresponding to the target label of the target image to be augmented by using the trained image data augmentation network, and using the target image to be augmented and the virtual image and the virtual label as data augmentation of the target image to be augmented and the target label of the target image to be augmented so as to obtain a target data set after data augmentation.
308. Dividing a target data set into a training sample set and a verification sample set according to a preset proportion, and inputting the training sample set and a label file into a preset GoogLeNet model for training to obtain an image classification model;
309. inputting a second image into the image classification model for classification prediction to obtain a plurality of label categories corresponding to the second image and the probability of each label category;
in this embodiment, the process of calling the image classification model to identify the second image and obtaining the multiple reference categories corresponding to the second image and the probabilities of the reference categories is as follows: and inputting the second image into the image classification model, and identifying the second image based on the image classification model to obtain a plurality of reference classes corresponding to the second image and the probability of each reference class.
310. Judging whether the probability of each label category is greater than a preset probability threshold value or not, and determining the label category with the probability meeting the target requirement as the image category corresponding to the second image;
in this embodiment, it is determined whether the probability of each label category is greater than a preset probability threshold, and the reference category for which the probability meets the target requirement may be the reference category with the highest probability or other reference categories.
For example, a second image is input into the image classification model, the image classification model identifies the second image, and the probabilities of a plurality of reference classes corresponding to the target image and each reference class are respectively: a first reference category, 80%, a second reference category, 15%, a third reference category, 5%. And determining the first reference category as the weight abnormity category corresponding to the target image because the probability of the first reference category is the maximum.
311. Inputting the second image into a preset express item identification model to obtain a weight abnormal express item image corresponding to each express item in the second image;
in this embodiment, the area range of each express item in the second image is cut out from the second image, so as to extract the corresponding weight-abnormal express item image corresponding to each express item. Specifically, after the weight abnormal express mail image is extracted, the weight abnormal express mail image is input into other models, for example, express mail information is acquired, and the models acquire corresponding express mail information. In this embodiment, an express information acquisition model that can identify express note numbers on express mail is preferred. And identifying the express serial number on the bill on the express through the express information acquisition model, and then determining the corresponding information such as the addressee, the addressee address and the like by the server according to the express serial number.
312. Extracting the express item number of the express item with abnormal weight;
in the embodiment, the express item number marked as weight abnormity is extracted, a weight abnormity express record is generated according to the item number, and the record is uploaded to an express database to update corresponding express information; and meanwhile, generating abnormal notification information based on the weight abnormal express record.
313. And generating an abnormal weight express record according to the express single number pair, and uploading the abnormal weight express record to a preset express management terminal.
In the embodiment, an express record with abnormal weight is generated according to the single number and uploaded to an express database to update corresponding express information; and meanwhile, generating abnormal notification information based on the weight abnormal express record, pushing the abnormal notification information into an express management system, and waiting for an administrator to process. The administrator can select to inform the delivery user of the weight abnormal express records according to the specific information of the weight abnormal express records.
Steps 301 to 302 and 308 in this embodiment are similar to steps 101 to 102 and 104 in the first embodiment, and are not described here again.
In the embodiment of the invention, a plurality of acquired first images for weighing packages are screened to obtain training sample images; classifying and labeling express items in the training sample image to obtain labeled data; carrying out data augmentation on the training sample image to obtain a target data set; inputting the target data set and the labeling file into a preset GoogLeNet model for training to obtain an image classification model; and acquiring a second image in the express item weighing scene captured in real time, and inputting the second image into an image classification model for classification and prediction to obtain weight abnormity categories corresponding to a plurality of second images. According to the scheme, the problem that the detection efficiency and the detection accuracy rate of the express with abnormal weight are low in the prior art is solved by identifying and detecting the express image.
With reference to fig. 4, the method for identifying weight abnormality of express mail in the embodiment of the present invention is described above, and a first embodiment of the apparatus for identifying weight abnormality of express mail in the embodiment of the present invention includes:
the screening module 401 is configured to acquire a plurality of first images for weighing packages in a pre-shot express sorting scene, and screen out a target image with package weighing abnormality from the first images based on a preset abnormality judgment threshold value to serve as a training sample image;
a labeling module 402, configured to perform classification labeling on express items in the training sample image to obtain labeling data, where the labeling data includes a label type;
a data augmentation module 403, configured to perform data augmentation on the training sample image to obtain a target data set after data augmentation;
a training module 404, configured to divide the target data set into a training sample set and a verification sample set according to a preset proportion, and input the training sample set and the markup file into a preset google lenet model for training, so as to obtain an image classification model;
the prediction module 405 is configured to acquire a plurality of second images in a real-time snapshot express item weighing scene, and input the second images into the image classification model for classification prediction to obtain weight abnormality categories corresponding to the plurality of second images.
In the embodiment of the invention, a plurality of acquired first images for weighing packages are screened to obtain training sample images; classifying and labeling express items in the training sample image to obtain labeled data; carrying out data augmentation on the training sample image to obtain a target data set; inputting the target data set and the labeling file into a preset GoogLeNet model for training to obtain an image classification model; and acquiring a second image in the express item weighing scene captured in real time, and inputting the second image into an image classification model for classification and prediction to obtain weight abnormity categories corresponding to a plurality of second images. According to the scheme, the express image is identified and detected, so that the problems of low detection efficiency and low detection accuracy of the express with abnormal weight in the prior art are solved.
Referring to fig. 5, a second embodiment of the identification apparatus for weight abnormality of express mail according to the embodiment of the present invention specifically includes:
the screening module 401 is configured to acquire a plurality of first images for weighing packages in a pre-shot express sorting scene, and screen out a target image with package weighing abnormality from the first images based on a preset abnormality judgment threshold value to serve as a training sample image;
a labeling module 402, configured to perform classification labeling on express items in the training sample image to obtain labeling data, where the labeling data includes a label type;
a data augmentation module 403, configured to perform data augmentation on the training sample image to obtain a target data set after data augmentation;
a training module 404, configured to divide the target data set into a training sample set and a verification sample set according to a preset proportion, and input the training sample set and the markup file into a preset google lenet model for training, so as to obtain an image classification model;
the prediction module 405 is configured to acquire a plurality of second images in a real-time snapshot express item weighing scene, and input the second images into the image classification model for classification prediction to obtain weight abnormality categories corresponding to the plurality of second images.
In this embodiment, the device for identifying the weight abnormality of the express mail further includes:
an identifying module 406, configured to identify whether the parcel has distribution weight data on a current distribution node;
a calculating module 407, configured to obtain historical distribution weight data of the package on a historical distribution node before the current distribution point if the package does not exist, and calculate an initial anomaly determination threshold according to the historical distribution weight data; and if the current distribution point exists, acquiring real-time distribution weight data of the parcel at the current distribution point and historical distribution weight data on the historical distribution node, and calculating a parcel weighing abnormal threshold according to the historical distribution weight data and the real-time distribution weight data.
In this embodiment, the device for identifying the weight abnormality of the express mail further includes:
a determining module 408, configured to determine whether a resolution corresponding to the first image is higher than a preset resolution threshold;
and the removing module 409 is configured to remove, if yes, image data in which a pre-labeled region in the first image does not meet a preset condition to obtain a training sample image, where density of the labeled region in the first image is greater than a density threshold.
In this embodiment, the data amplification module 403 is specifically configured to:
acquiring initial labeling information of pixels corresponding to the training sample image;
constructing a label generation network, and generating target label information based on the initial label data and the label generation network;
inputting the target labeling information into a preset style migration network to obtain a virtual image corresponding to the training sample image;
generating an image data augmentation network based on the label generation network and the style migration network, and training the image data augmentation network based on the training sample image and the initial label information through a loss function of a preset discriminator to obtain a data augmentation model;
and inputting the training sample image into the data augmentation model for data augmentation to obtain a target data set with augmented data.
In this embodiment, the training module 404 is specifically configured to:
inputting the training sample set into a preset GoogLeNet model to obtain a model output result;
calculating the loss of the GoogLeNet model by using a loss function according to the model output result;
and adjusting the weight parameters which are not frozen in the GoogLeNet model according to the loss until a convergence condition is reached to obtain an image classification model.
In this embodiment, the prediction module 405 includes:
a prediction unit 4051, configured to input the second image into the image classification model to perform classification prediction, so as to obtain a plurality of label categories corresponding to the second image and a probability of each label category;
a determining unit 4052, configured to determine whether the probability of each label category is greater than a preset probability threshold, and determine a label category of which the probability meets a target requirement as an image category corresponding to the second image.
In this embodiment, the device for identifying the weight abnormality of the express mail further includes:
an input module 410, configured to input the second image into a preset express item identification model, so as to obtain an abnormal-weight express item image corresponding to each express item in the second image;
the extracting module 411 is used for extracting the express item number of the express item with the abnormal weight;
and the uploading module 412 is used for uploading the record of the express item with the abnormal weight generated according to the express item single number pair, and uploading the record of the express item with the abnormal weight to a preset express item management terminal.
In the embodiment of the invention, a plurality of acquired first images for weighing packages are screened to obtain training sample images; classifying and labeling express items in the training sample image to obtain labeled data; carrying out data augmentation on the training sample image to obtain a target data set; inputting the target data set and the labeling file into a preset GoogLeNet model for training to obtain an image classification model; and acquiring a second image in the express item weighing scene captured in real time, and inputting the second image into an image classification model for classification and prediction to obtain weight abnormity categories corresponding to a plurality of second images. According to the scheme, the express image is identified and detected, so that the problems of low detection efficiency and low detection accuracy of the express with abnormal weight in the prior art are solved.
Fig. 4 and 5 describe the identification device for weight anomaly of express mail in the embodiment of the present invention in detail from the perspective of a modular functional entity, and the identification device for weight anomaly of express mail in the embodiment of the present invention is described in detail from the perspective of hardware processing.
Fig. 6 is a schematic structural diagram of an identification device for weight abnormality of express mail, where the identification device 800 for weight abnormality of express mail may generate relatively large differences due to different configurations or performances, and may include one or more processors (CPUs) 810 (e.g., one or more processors) and a memory 820, and one or more storage media 830 (e.g., one or more mass storage devices) storing an application 833 or data 832. Memory 820 and storage medium 830 may be, among other things, transitory or persistent storage. The program stored in the storage medium 830 may include one or more modules (not shown), each of which may include a series of instruction operations in the device 800 for identifying anomalies in the weight of the dispatch. Still further, the processor 810 may be configured to communicate with the storage medium 830, and execute a series of instruction operations in the storage medium 830 on the identification device 800 for express weight abnormality, so as to implement the steps of the express weight abnormality identification method provided by the above-mentioned method embodiments.
The device 800 for identifying express weight anomalies may also include one or more power supplies 840, one or more wired or wireless network interfaces 850, one or more input-output interfaces 860, and/or one or more operating systems 831, such as Windows Server, mac OS X, unix, linux, freeBSD, and the like. Those skilled in the art will appreciate that the configuration of the identification device for weight abnormality of express items shown in fig. 6 does not constitute a limitation of the identification device for weight abnormality of express items provided in the present application, and may include more or fewer components than those shown, or some components in combination, or a different arrangement of components.
The invention also provides a computer-readable storage medium, which may be a non-volatile computer-readable storage medium or a volatile computer-readable storage medium, where instructions are stored, and when the instructions are executed on a computer, the instructions cause the computer to execute the steps of the method for identifying the weight abnormality of the express item.
It can be clearly understood by those skilled in the art that, for convenience and brevity of description, the specific working processes of the above-described systems, apparatuses and units may refer to the corresponding processes in the foregoing method embodiments, and are not described herein again.
The integrated unit, if implemented in the form of a software functional unit and sold or used as a stand-alone product, may be stored in a computer readable storage medium. Based on such understanding, the technical solution of the present invention may be embodied in the form of a software product, which is stored in a storage medium and includes instructions for causing a computer device (which may be a personal computer, a server, or a network device) to execute all or part of the steps of the method according to the embodiments of the present invention. And the aforementioned storage medium includes: various media capable of storing program codes, such as a usb disk, a removable hard disk, a read-only memory (ROM), a Random Access Memory (RAM), a magnetic disk, or an optical disk.
The above-mentioned embodiments are only used for illustrating the technical solutions of the present invention, and not for limiting the same; while the invention has been described in detail and with reference to the foregoing examples, those skilled in the art will understand that: the technical solutions described in the foregoing embodiments may still be modified, or some technical features may be equivalently replaced; and the modifications or the substitutions do not depart from the spirit and scope of the technical solutions of the embodiments of the present invention.

Claims (10)

1. An identification method for express weight abnormity is characterized by comprising the following steps:
acquiring a plurality of first images for weighing packages in a pre-shot express sorting scene, and screening target images with package weighing abnormality from the first images based on a preset abnormality judgment threshold value to serve as training sample images;
classifying and labeling the express mails in the training sample image to obtain labeled data, wherein the labeled data comprises a label type;
performing data amplification on the training sample image to obtain a target data set after data amplification;
dividing the target data set into a training sample set and a verification sample set according to a preset proportion, and inputting the training sample set and the label file into a preset GoogLeNet model for training to obtain an image classification model;
and acquiring a plurality of second images in a real-time snapshot express item weighing scene, inputting the second images into the image classification model for classification and prediction, and obtaining weight abnormity categories corresponding to the plurality of second images.
2. The method for identifying the weight abnormality of the express mail according to claim 1, wherein before the obtaining of a plurality of first images for weighing packages in an express mail sorting scene shot in advance and screening out target images with package weighing abnormality from the first images based on a preset abnormality judgment threshold as training sample images, the method further comprises:
identifying whether the parcel has distribution weight data on the current distribution node;
if the package is not distributed to the current distribution point, historical distribution weight data of the package on a historical distribution node before the current distribution point are obtained, and an initial abnormity judgment threshold value is calculated according to the historical distribution weight data;
and if the current distribution point exists, acquiring real-time distribution weight data of the parcel at the current distribution point and historical distribution weight data on the historical distribution node, and calculating a parcel weighing abnormal threshold according to the historical distribution weight data and the real-time distribution weight data.
3. The method for identifying the weight abnormality of the express mail according to claim 1, wherein before the step of classifying and labeling the express mail in the training sample image to obtain labeled data, the method further comprises the following steps:
judging whether the corresponding resolution of the first image is higher than a preset resolution threshold value or not;
if so, eliminating image data of a pre-marked area in the first image which does not meet a preset condition to obtain a training sample image, wherein the density of the marked area in the first image is greater than a density threshold value.
4. The method for identifying the abnormal express weight according to claim 1, wherein the step of performing data augmentation on the training sample image to obtain a data augmented target dataset comprises:
acquiring initial labeling information of pixels corresponding to the training sample image;
constructing a label generation network, and generating target label information based on the initial label data and the label generation network;
inputting the target marking information into a preset style migration network to obtain a virtual image corresponding to the training sample image;
generating an image data augmentation network based on the label generation network and the style migration network, and training the image data augmentation network based on the training sample image and the initial label information through a loss function of a preset discriminator to obtain a data augmentation model;
and inputting the training sample image into the data augmentation model for data augmentation to obtain a target data set after data augmentation.
5. The method for identifying the weight abnormality of the express mail according to claim 1, wherein the step of inputting the training sample set and the labeling file into a preset GoogLeNet model for training to obtain an image classification model comprises the following steps:
inputting the training sample set into a preset GoogLeNet model to obtain a model output result;
calculating the loss of the GoogLeNet model by using a loss function according to the model output result;
and adjusting the weight parameters which are not frozen in the GoogLeNet model according to the loss until a convergence condition is reached to obtain an image classification model.
6. The method for identifying the weight abnormality of the express mail according to claim 1, wherein the step of inputting the second image into the image classification model for classification and prediction to obtain a plurality of weight abnormality categories corresponding to the second image comprises:
inputting the second image into the image classification model for classification prediction to obtain a plurality of label categories corresponding to the second image and the probability of each label category;
and judging whether the probability of each label category is greater than a preset probability threshold value or not, and determining the label category of which the probability meets the target requirement as the image category corresponding to the second image.
7. The method for identifying weight abnormality of express mail according to claim 1, wherein after the second image is input into the image classification model for classification prediction to obtain a plurality of weight abnormality categories corresponding to the second image, the method further comprises:
inputting the second image into a preset express item identification model to obtain an abnormal express item image corresponding to each express item in the second image;
extracting the express item number of the express item with the abnormal weight;
and generating an abnormal weight express record according to the express single number pair, and uploading the abnormal weight express record to a preset express management terminal.
8. An identification device for weight abnormality of express items, characterized in that the identification device for weight abnormality of express items comprises:
the screening module is used for acquiring a plurality of first images for weighing packages in a pre-shot express sorting scene, and screening target images with package weighing abnormality from the first images based on a preset abnormality judgment threshold value to serve as training sample images;
the labeling module is used for classifying and labeling the express mails in the training sample image to obtain labeling data, wherein the labeling data comprise label types;
the data amplification module is used for performing data amplification on the training sample image to obtain a target data set after the data amplification;
the training module is used for dividing the target data set into a training sample set and a verification sample set according to a preset proportion, and inputting the training sample set and the labeling file into a preset GoogLeNet model for training to obtain an image classification model;
and the prediction module is used for acquiring a plurality of second images in a real-time snapshot express weighing scene, inputting the second images into the image classification model for classification prediction, and obtaining a plurality of weight abnormity categories corresponding to the second images.
9. An identification device for weight abnormality of express items, characterized in that the identification device for weight abnormality of express items comprises: a memory having instructions stored therein and at least one processor, the memory and the at least one processor interconnected by a line;
the at least one processor calls the instructions in the memory to cause the identification device of the abnormality in express weight to execute the steps of the identification method of abnormality in express weight according to any one of claims 1 to 7.
10. A computer-readable storage medium, on which a computer program is stored which, when being executed by a processor, carries out the steps of the method for identifying abnormality in express weight according to any one of claims 1 to 7.
CN202210906150.3A 2022-07-29 2022-07-29 Express mail weight abnormity identification method, device, equipment and storage medium Pending CN115393627A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210906150.3A CN115393627A (en) 2022-07-29 2022-07-29 Express mail weight abnormity identification method, device, equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210906150.3A CN115393627A (en) 2022-07-29 2022-07-29 Express mail weight abnormity identification method, device, equipment and storage medium

Publications (1)

Publication Number Publication Date
CN115393627A true CN115393627A (en) 2022-11-25

Family

ID=84116637

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210906150.3A Pending CN115393627A (en) 2022-07-29 2022-07-29 Express mail weight abnormity identification method, device, equipment and storage medium

Country Status (1)

Country Link
CN (1) CN115393627A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117611524A (en) * 2023-10-26 2024-02-27 北京声迅电子股份有限公司 Express item security inspection method based on multi-source image

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117611524A (en) * 2023-10-26 2024-02-27 北京声迅电子股份有限公司 Express item security inspection method based on multi-source image
CN117611524B (en) * 2023-10-26 2024-05-31 北京声迅电子股份有限公司 Express item security inspection method based on multi-source image

Similar Documents

Publication Publication Date Title
CN111898547B (en) Training method, device, equipment and storage medium of face recognition model
US11657602B2 (en) Font identification from imagery
US9767604B2 (en) Image analysis method by analyzing point cloud using hierarchical search tree
AU2021208647A1 (en) Systems for multiclass object detection and alerting and methods therefor
US20220254134A1 (en) Region recognition method, apparatus and device, and readable storage medium
CN108229418B (en) Human body key point detection method and apparatus, electronic device, storage medium, and program
CN111461101B (en) Method, device, equipment and storage medium for identifying work clothes mark
US20210272088A1 (en) Method and system for item identification
CN114119007A (en) Computer vision transaction monitoring
CN110909698A (en) Electronic scale recognition result output method, system, device and readable storage medium
KR102283197B1 (en) A method and device for determining the type of product
CN111428682B (en) Express sorting method, device, equipment and storage medium
CN115393627A (en) Express mail weight abnormity identification method, device, equipment and storage medium
CN116434002A (en) Smoke detection method, system, medium and equipment based on lightweight neural network
CN110826481A (en) Data processing method, commodity identification method, server and storage medium
CN107798292A (en) Object identifying method, computer program, storage medium and electronic equipment
KR101991186B1 (en) Bar detection method and apparatus
CN114119970B (en) Target tracking method and device
CN112884755B (en) Method and device for detecting contraband
CN115761457A (en) Commodity identification method and device, electronic equipment and computer readable medium
CN113160414B (en) Automatic goods allowance recognition method, device, electronic equipment and computer readable medium
CN114840748A (en) Information pushing method, device and equipment based on face recognition and storage medium
CN114235122A (en) Weighing settlement method and system of electronic scale based on AI image recognition
CN114241249B (en) Image classification method and system based on target detection algorithm and convolutional neural network
CN112329676A (en) Reflow piece identification method, device, equipment and storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination