CN113888086A - Article signing method, device and equipment based on image recognition and storage medium - Google Patents
Article signing method, device and equipment based on image recognition and storage medium Download PDFInfo
- Publication number
- CN113888086A CN113888086A CN202111148147.1A CN202111148147A CN113888086A CN 113888086 A CN113888086 A CN 113888086A CN 202111148147 A CN202111148147 A CN 202111148147A CN 113888086 A CN113888086 A CN 113888086A
- Authority
- CN
- China
- Prior art keywords
- image
- preset
- pixel
- target
- region
- 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.)
- Granted
Links
- 238000000034 method Methods 0.000 title claims abstract description 54
- 238000012544 monitoring process Methods 0.000 claims abstract description 21
- 238000004422 calculation algorithm Methods 0.000 claims description 24
- 230000006870 function Effects 0.000 claims description 19
- 239000013598 vector Substances 0.000 claims description 13
- 238000000605 extraction Methods 0.000 claims description 11
- 238000013507 mapping Methods 0.000 claims description 11
- 238000004590 computer program Methods 0.000 claims description 10
- 238000009432 framing Methods 0.000 claims description 3
- 230000008569 process Effects 0.000 abstract description 12
- 238000013473 artificial intelligence Methods 0.000 abstract description 7
- 238000005516 engineering process Methods 0.000 abstract description 4
- 238000004891 communication Methods 0.000 description 8
- 238000007726 management method Methods 0.000 description 5
- 238000010586 diagram Methods 0.000 description 4
- 238000013500 data storage Methods 0.000 description 3
- 238000012545 processing Methods 0.000 description 3
- 239000004973 liquid crystal related substance Substances 0.000 description 2
- 230000003287 optical effect Effects 0.000 description 2
- 238000012795 verification Methods 0.000 description 2
- 238000004458 analytical method Methods 0.000 description 1
- 230000005540 biological transmission Effects 0.000 description 1
- 238000004364 calculation method Methods 0.000 description 1
- 230000008859 change Effects 0.000 description 1
- 238000001514 detection method Methods 0.000 description 1
- 238000011161 development Methods 0.000 description 1
- 230000000694 effects Effects 0.000 description 1
- 238000010191 image analysis Methods 0.000 description 1
- 230000006872 improvement Effects 0.000 description 1
- 230000007246 mechanism Effects 0.000 description 1
- 238000012986 modification Methods 0.000 description 1
- 230000004048 modification Effects 0.000 description 1
- 230000002093 peripheral effect Effects 0.000 description 1
- 230000003252 repetitive effect Effects 0.000 description 1
- 238000006467 substitution reaction Methods 0.000 description 1
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06Q—INFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
- G06Q10/00—Administration; Management
- G06Q10/08—Logistics, e.g. warehousing, loading or distribution; Inventory or stock management
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F18/00—Pattern recognition
- G06F18/20—Analysing
- G06F18/22—Matching criteria, e.g. proximity measures
Landscapes
- Engineering & Computer Science (AREA)
- Business, Economics & Management (AREA)
- Theoretical Computer Science (AREA)
- Physics & Mathematics (AREA)
- Data Mining & Analysis (AREA)
- Economics (AREA)
- General Physics & Mathematics (AREA)
- Computer Vision & Pattern Recognition (AREA)
- Entrepreneurship & Innovation (AREA)
- Evolutionary Biology (AREA)
- General Engineering & Computer Science (AREA)
- Bioinformatics & Computational Biology (AREA)
- Bioinformatics & Cheminformatics (AREA)
- Artificial Intelligence (AREA)
- Development Economics (AREA)
- Life Sciences & Earth Sciences (AREA)
- Evolutionary Computation (AREA)
- Human Resources & Organizations (AREA)
- Marketing (AREA)
- Operations Research (AREA)
- Quality & Reliability (AREA)
- Strategic Management (AREA)
- Tourism & Hospitality (AREA)
- General Business, Economics & Management (AREA)
- Image Analysis (AREA)
Abstract
The invention relates to an artificial intelligence technology, and discloses an article signing method based on image identification, which comprises the following steps: the method comprises the steps of obtaining monitoring pictures of a preset area at a first moment and a second moment, respectively carrying out area division and corresponding coding on the two monitoring pictures, selecting two areas with corresponding codes one by one, respectively extracting global features and local features of the two areas, calculating difference values of the two areas with the corresponding codes according to the extracted global features and local features, further determining that articles in the areas are not signed when the difference values are smaller than a difference threshold value, determining that the articles in the areas are signed when the difference values are larger than or equal to the difference threshold value, and reminding a user. In addition, the invention also relates to a block chain technology, and the monitoring picture can be stored in the node of the block chain. The invention also provides an article signing device based on image recognition, electronic equipment and a storage medium. The invention can simplify the process of signing for the article.
Description
Technical Field
The invention relates to the technical field of artificial intelligence, in particular to an article signing method and device based on image recognition, electronic equipment and a computer readable storage medium.
Background
With the rapid development of the internet economy and logistics industry, people carry out online shopping and transport various goods by logistics more and more commonly, so that a large amount of logistics objects are required to sign, when people sign the logistics objects, people often need to manually sign or use verification codes and the like to verify the identity of the logistics objects, and users are required to actively execute a relatively complicated signing process.
In the existing signing method, because a user is required to sign for an object manually or by using active modes such as a verification code and the like, and the user cannot be reminded in time after signing for the object, the signing process is long, and the user experience is reduced, so that how to simplify the signing process of the object becomes a key point for people to pay attention to.
Disclosure of Invention
The invention provides an article signing method and device based on image recognition and a computer readable storage medium, and mainly aims to solve the problem of long process for signing an article.
In order to achieve the above object, the present invention provides an article signing method based on image recognition, comprising:
the method comprises the steps of obtaining a monitoring picture of a preset area at a first moment as a first picture, dividing the first picture into a plurality of first image areas according to a preset size, and coding the plurality of first image areas according to a preset coding mode;
selecting one of the first image areas as a target area one by one, and extracting image features of the target area;
acquiring a monitoring picture of the preset area at a second moment as a second picture, dividing the second picture into a plurality of second image areas according to the preset size, and coding the plurality of second image areas according to the preset coding mode;
selecting a region with the same number as the target region from the second image region as a region to be compared, and extracting image features of the region to be compared;
calculating a difference value between the image characteristics of the target area and the image characteristics of the area to be compared, and judging whether the difference value is greater than a preset difference threshold value;
when the difference value is smaller than or equal to the difference threshold value, determining that goods stored in the target area are not signed;
and when the difference value is larger than the difference threshold value, determining that the goods stored in the target area are signed, inquiring the information of recipients of the goods stored in the target area, and reminding the recipients of the goods according to the information of the recipients.
Optionally, the dividing the first screen into a plurality of first image areas according to a preset size includes:
generating an image frame according to the preset size;
and repeatedly performing framing on the areas in the first picture by using the image frames until all the areas in the first picture are framed and selected, so as to obtain a plurality of first image areas.
In detail, the preset size may be data of a length and a width of the area stored in each article in the first frame, which are acquired in advance.
Optionally, the encoding the plurality of first image regions according to a preset encoding manner includes:
selecting a column of image areas from the plurality of first image areas one by one as a target column according to the sequence from top to bottom;
each first image region in the target column is incrementally encoded in left-to-right order.
Optionally, the extracting the image feature of the target region includes:
generating global features of the target region according to the pixel gradient in the target region;
performing frame selection on the regions in the target region one by using a preset sliding window to obtain a pixel window;
generating local features of the target region according to the pixel values in each pixel window;
and collecting the global features and the local features as the image features of the target area.
Optionally, the generating a global feature of the target region according to the pixel gradient in the target region includes:
counting the pixel value of each pixel point in the target area;
taking the maximum pixel value and the minimum pixel value in the pixel values as parameters of a preset mapping function, and mapping the pixel value of each pixel point in the target area to a preset range by using the preset function;
calculating the pixel gradient of each line of pixels in the mapped target area, converting the pixel gradient of each line of pixels into a line vector, and splicing the line vector into the global feature of the target area.
Optionally, the generating a local feature of the target region according to the pixel value in each of the pixel windows includes:
selecting one pixel point from the pixel window one by one as a target pixel point;
judging whether the pixel value of the target pixel point is an extreme value in the pixel window;
when the pixel value of the target pixel point is not an extreme value in the pixel window, returning to the step of selecting one pixel point from the pixel window one by one as the target pixel point;
when the pixel value of the target pixel point is an extreme value in the pixel window, determining the target pixel point as a key point;
vectorizing the pixel values of all key points in all the pixel windows, and collecting the obtained vectors as the local features of the target area.
Optionally, the calculating a difference value between the image feature of the target region and the image feature of the to-be-compared region includes:
calculating a first difference value between the global feature of the target area and the global feature of the area to be compared by using a preset first distance algorithm;
calculating a second difference value between the local feature of the target region and the local feature of the region to be compared by using a preset second distance algorithm;
and calculating to obtain a difference value between the image characteristic of the target area and the image characteristic of the area to be compared according to the first difference value and the second difference value by using a preset weight algorithm.
In order to solve the above problem, the present invention further provides an article signing apparatus based on image recognition, the apparatus comprising:
the first image dividing module is used for acquiring a monitoring picture of a preset area at a first moment as a first picture, dividing the first picture into a plurality of first image areas according to a preset size, and coding the plurality of first image areas according to a preset coding mode;
the first feature extraction module is used for selecting one of the first image areas as a target area one by one and extracting image features of the target area;
the second image dividing module is used for acquiring a monitoring picture of the preset area at a second moment as a second picture, dividing the second picture into a plurality of second image areas according to the preset size, and coding the plurality of second image areas according to the preset coding mode;
the second feature extraction module is used for selecting a region with the same number as the target region from the second image region as a region to be compared and extracting the image features of the region to be compared;
the sign-in judging module is used for calculating a difference value between the image characteristics of the target area and the image characteristics of the area to be compared and judging whether the difference value is greater than a preset difference threshold value or not; when the difference value is smaller than or equal to the difference threshold value, determining that goods stored in the target area are not signed; and when the difference value is larger than the difference threshold value, determining that the goods stored in the target area are signed, inquiring the information of recipients of the goods stored in the target area, and reminding the recipients of the goods according to the information of the recipients.
In order to solve the above problem, the present invention also provides an electronic device, including:
at least one processor; and the number of the first and second groups,
a memory communicatively coupled to the at least one processor; wherein,
the memory stores a computer program executable by the at least one processor, the computer program being executable by the at least one processor to enable the at least one processor to perform the image recognition-based item signing method described above.
In order to solve the above problem, the present invention further provides a computer-readable storage medium, in which at least one computer program is stored, the at least one computer program being executed by a processor in an electronic device to implement the method for signing an article based on image recognition.
According to the embodiment of the invention, the images of the successive time points of the article storage area can be subjected to feature extraction, and then whether the article stored in the article storage area is signed by the user is judged according to the image features corresponding to the images captured on the successive time points, so that the user is directly reminded to sign, the user does not need to confirm or operate, the non-feeling sign-in is realized, and the article sign-in process is simplified. Therefore, the method, the device, the electronic equipment and the computer readable storage medium for signing and receiving the article based on the image recognition can solve the problem of long process for signing and receiving the article.
Drawings
Fig. 1 is a schematic flowchart of an article signing method based on image recognition according to an embodiment of the present invention;
fig. 2 is a schematic flowchart of generating global features of a target area according to an embodiment of the present invention;
FIG. 3 is a flowchart illustrating a process of generating local features of a target region according to an embodiment of the present invention;
FIG. 4 is a functional block diagram of an article signing apparatus based on image recognition according to an embodiment of the present invention;
fig. 5 is a schematic structural diagram of an electronic device for implementing the method for signing an article based on image recognition according to an embodiment of the present invention.
The implementation, functional features and advantages of the objects of the present invention will be further explained with reference to the accompanying drawings.
Detailed Description
It should be understood that the specific embodiments described herein are merely illustrative of the invention and are not intended to limit the invention.
The embodiment of the application provides an article signing method based on image recognition. The execution subject of the article signing method based on image recognition includes, but is not limited to, at least one of the electronic devices of a server, a terminal and the like which can be configured to execute the method provided by the embodiment of the application. In other words, the item signing method based on image recognition may be executed by software or hardware installed in a terminal device or a server device, and the software may be a block chain platform. The server includes but is not limited to: a single server, a server cluster, a cloud server or a cloud server cluster, and the like. The server may be an independent server, or may be a cloud server that provides basic cloud computing services such as a cloud service, a cloud database, cloud computing, a cloud function, cloud storage, a Network service, cloud communication, a middleware service, a domain name service, a security service, a Content Delivery Network (CDN), a big data and artificial intelligence platform, and the like.
Fig. 1 is a schematic flow chart of an article signing method based on image recognition according to an embodiment of the present invention. In this embodiment, the method for signing on an article based on image recognition includes:
s1, acquiring a monitoring picture of a preset area at a first moment as a first picture, dividing the first picture into a plurality of first image areas according to a preset size, and coding the plurality of first image areas according to a preset coding mode.
In the embodiment of the invention, the preset area can be an area for storing logistics articles such as logistics storage, express delivery collection points and the like, and the face change of the preset area captured by equipment with an image capturing function such as a camera or a video recorder and the like which is installed in advance at a first moment can be acquired as a first picture.
For example, the first picture is grabbed from a data storage area corresponding to a pre-installed device with an image capturing function by using a computer sentence with a data grabbing function (such as a java sentence, a python sentence, and the like), wherein the data storage area includes but is not limited to a database, a block chain node, and a network cache.
In one practical application scenario of the present invention, because the first picture of the acquired preset area may include storage areas of the multiple articles, and areas for storing logistics articles such as logistics storage, express delivery points, and the like are regular in general, and each article has a separate storage area (for example, each article grid on the shelf), the first picture can be divided into multiple first image areas according to a preset size, so as to realize division of each article in the picture, avoid detailed image analysis on the first picture, and facilitate improvement of efficiency of analyzing whether the article is signed for later.
In an embodiment of the present invention, the dividing the first picture into a plurality of first image areas according to a preset size includes:
generating an image frame according to the preset size;
and repeatedly performing framing on the areas in the first picture by using the image frames until all the areas in the first picture are framed and selected, so as to obtain a plurality of first image areas.
In detail, the preset size may be data of a length and a width of the area stored in each article in the first frame, which are acquired in advance.
Specifically, the image frame may be generated according to the preset size, and the generated image frame may be used to perform non-repetitive selection in the first screen to obtain a plurality of first image regions.
For example, if the length of the first screen is 10cm and the width of the first screen is 10cm, and the length of the image frame generated according to the preset size is 2cm and the width of the image frame is 2cm, 25 first image areas with the length of 2cm and the width of 2cm can be obtained by using the image frame to perform frame selection in the first image area.
In an embodiment of the present invention, the encoding the plurality of first image regions according to a preset encoding method includes:
selecting a column of image areas from the plurality of first image areas one by one as a target column according to the sequence from top to bottom;
each first image region in the target column is incrementally encoded in left-to-right order.
For example, the first image includes 5 rows and 5 columns, and there are 25 first image regions, the first column including 5 first image regions is selected from top to bottom as the target column, and each first image region in the column is encoded according to the sequence from left to right (e.g. 1, 2, 3, 4, 5), and so on until the encoding of each first image region in the first image is completed.
In the embodiment of the invention, each first image area in the first image is coded, so that each first image area can be distinguished, and further, the accurate judgment on whether each article in the first image is signed or not can be realized subsequently.
S2, one of the first image areas is selected as a target area one by one, and the image characteristics of the target area are extracted.
In the embodiment of the invention, in order to accurately judge whether the articles in different first image areas are signed or not, one of the areas can be selected from the plurality of first image areas one by one as a target area, and each selected first image area is further analyzed respectively to judge whether the articles in the area are signed or not.
In an embodiment of the present invention, the extracting image features of the target region includes:
generating global features of the target region according to the pixel gradient in the target region;
performing frame selection on the regions in the target region one by using a preset sliding window to obtain a pixel window;
generating local features of the target region according to the pixel values in each pixel window;
and collecting the global features and the local features as the image features of the target area.
In one embodiment of the present invention, the global features of the target region may be generated by using a Histogram of Oriented Gradients (HOG), a Deformable Part Model (DPM), a Local Binary Patterns (LBP), or the like, or may be extracted by using an artificial intelligence Model with a pre-trained specific image feature extraction function, where the artificial intelligence Model includes, but is not limited to, a VGG-net Model and a U-net Model.
In another embodiment of the present invention, referring to fig. 2, the generating the global feature of the target region according to the pixel gradient in the target region includes:
s21, counting the pixel value of each pixel point in the target area;
s22, taking the maximum pixel value and the minimum pixel value in the pixel values as parameters of a preset mapping function, and mapping the pixel value of each pixel point in the target area to a preset range by using the preset function;
s23, calculating the pixel gradient of each line of pixels in the target area after mapping, converting the pixel gradient of each line of pixels into a line vector, and splicing the line vector into the global feature of the target area.
Illustratively, the preset mapping function may be:
wherein, YiMapping the ith pixel point in the target region to the pixel value, x, within the preset rangeiThe pixel value of the ith pixel point in the target region, max (x) is the maximum pixel value in the target region, and min (x) is the minimum pixel value in the target region.
Further, a preset gradient algorithm can be used for calculating the pixel gradient of each line of pixels in the target area after mapping, wherein the gradient algorithm includes, but is not limited to, a two-dimensional discrete derivative algorithm, a cable operator and the like.
In the embodiment of the present application, the pixel gradient of each row of pixels may be converted into a row vector, and the row vector may be spliced into a global feature of the target region.
For example, the selected target region includes three rows of pixels, the pixel gradient of the first row of pixels is q, w, e, the pixel gradient of the first row of pixels is a, s, d, and the pixel gradient of the first row of pixels is z, x, c, and then the pixel gradient of each row of pixels can be respectively used as a row vector to be spliced into the following global features:
further, referring to fig. 3, the generating the local feature of the target region according to the pixel value in each pixel window includes:
s31, selecting one pixel point from the pixel window one by one as a target pixel point;
s32, judging whether the pixel value of the target pixel point is an extreme value in the pixel window;
when the pixel value of the target pixel point is not an extreme value in the pixel window, returning to S31;
when the pixel value of the target pixel point is an extreme value in the pixel window, executing S33 and determining the target pixel point as a key point;
and S34, vectorizing the pixel values of all key points in all the pixel windows, and collecting the obtained vectors as the local features of the target area.
In this embodiment of the application, the sliding window may be a pre-constructed selection box with a certain area, and may be used to frame pixels in the target region, for example, a square selection box constructed with 10 pixels as height and 10 pixels as width.
In detail, the extreme value includes a maximum value and a minimum value, and when the pixel value of the target pixel point is the maximum value or the minimum value in the pixel window, the target pixel point is determined to be the key point of the pixel window.
Specifically, the step of vectorizing the pixel values of all the key points in the pixel window is consistent with the step of calculating and mapping the pixel gradient of each line of pixels in the target area, and the step of converting the pixel gradient of each line of pixels into a line vector is not repeated again.
And S3, acquiring a monitoring picture of the preset area at a second moment as a second picture, dividing the second picture into a plurality of second image areas according to the preset size, and encoding the plurality of second image areas according to the preset encoding mode.
In this embodiment of the present invention, the step of acquiring the monitoring picture of the preset region at the second time as the second picture, dividing the second picture into a plurality of second image regions according to the preset size, and encoding the plurality of second image regions according to the preset encoding mode is consistent with the step of acquiring the monitoring picture of the preset region at the first time as the first picture in S1, dividing the first picture into a plurality of first image regions according to the preset size, and encoding the plurality of first image regions according to the preset encoding mode, and details are not repeated herein.
S4, selecting the area with the same number as the target area from the second image area as the area to be compared, and extracting the image characteristics of the area to be compared.
In this embodiment of the present invention, the step of selecting, from the second image region, a region having the same number as that of the target region as a region to be compared and extracting image features of the region to be compared is consistent with the step of selecting, in S2, one region from the plurality of image regions as a target region one by one and extracting image features of the target region, and details are not repeated here.
S5, calculating a difference value between the image characteristics of the target area and the image characteristics of the area to be compared.
In the embodiment of the invention, whether the article in the target area is signed or not can be judged according to the difference value by calculating the difference value between the image characteristic of the target silence and the image characteristic of the area to be compared.
In an embodiment of the present invention, the calculating a difference value between the image feature of the target region and the image feature of the region to be compared includes:
calculating a first difference value between the global feature of the target area and the global feature of the area to be compared by using a preset first distance algorithm;
calculating a second difference value between the local feature of the target region and the local feature of the region to be compared by using a preset second distance algorithm;
and calculating to obtain a difference value between the image characteristic of the target area and the image characteristic of the area to be compared according to the first difference value and the second difference value by using a preset weight algorithm.
In detail, the calculating a first difference value between the global feature of the target region and the global feature of the region to be compared by using a preset first distance algorithm includes:
calculating a first difference value between the global feature of the target area and the global feature of the area to be compared by using a distance value algorithm as follows:
wherein D is1And taking the first difference value as a, wherein a is the global feature of the target area, and b is the global feature of the area to be compared.
In other embodiments of the present invention, a first difference value between the global feature of the target region and the global feature of the region to be compared may also be calculated by using an euclidean distance algorithm, a cosine distance algorithm, or other algorithms.
In the embodiment of the present invention, the step of calculating the second difference value between the local feature of the target region and the local feature of the region to be compared by using the preset second distance algorithm is consistent with the step of calculating the first difference value between the global feature of the target region and the global feature of the region to be compared by using the preset first distance algorithm, which is not described herein again, where the second distance algorithm may be the same as the first distance algorithm.
In an embodiment of the present invention, the calculating, by using a preset weight algorithm, a difference value between the image feature of the target region and the image feature of the region to be compared according to the first difference value and the second difference value includes:
calculating a difference value between the image feature of the target area and the image feature of the area to be compared according to the first difference value and the second difference value by using the following weight calculation method:
L=α*D1+β*D2
wherein L is a difference value between the image characteristics of the target area and the image characteristics of the area to be compared, D1Is the first difference value, D2Is the second difference value.
And S6, judging whether the difference value is larger than a preset difference threshold value.
In the embodiment of the invention, the calculated difference value can be compared with a preset difference threshold value so as to judge whether goods stored in the target area are signed or not according to a comparison result in the following.
In the embodiment of the invention, the first difference value and the second difference value between the global feature of the target area and the global feature and the local feature of the area to be compared are calculated by utilizing the preset first distance algorithm respectively, and the difference value between the image feature of the target area and the image feature of the area to be compared is calculated by utilizing the first difference value and the second difference value, so that the global and local analysis of the target area and the area to be compared is realized, and the accuracy of judging whether goods stored in the target area are signed or not is improved.
And when the difference value is smaller than or equal to the difference threshold value, executing S7 to determine that the goods stored in the target area are not signed.
In the embodiment of the present invention, when the difference value is smaller than or equal to the difference threshold, it is determined that the goods in the image of the target area are not changed, that is, it is determined that the goods stored in the target area are not signed.
And when the difference value is larger than the difference threshold value, executing S8, determining that the goods stored in the target area are signed, inquiring the information of the addressees of the goods stored in the target area, and reminding the addressees of the goods according to the information of the addressees.
In the embodiment of the present invention, when the difference value is greater than the difference threshold, it is determined that the goods in the image of the target area are changed, that is, it is determined that the goods stored in the target area have been signed.
In the embodiment of the invention, after the goods stored in the target area are confirmed to be signed, the information of the addressee corresponding to the goods stored in the target area is inquired from the pre-acquired information table, and the addressee of the goods is reminded in the modes of short messages, telephones and the like according to the information of the addressee.
According to the embodiment of the invention, the images of the successive time points of the article storage area can be subjected to feature extraction, and then whether the article stored in the article storage area is signed by the user is judged according to the image features corresponding to the images captured on the successive time points, so that the user is directly reminded to sign, the user does not need to confirm or operate, the non-feeling sign-in is realized, and the article sign-in process is simplified. Therefore, the object signing method based on image recognition can solve the problem of long process for signing the object.
Fig. 4 is a functional block diagram of an article signing apparatus based on image recognition according to an embodiment of the present invention.
The article signing apparatus 100 based on image recognition according to the present invention can be installed in an electronic device. According to the realized functions, the article signing-in device 100 based on image recognition may comprise a first image dividing module 101, a first feature extraction module 102, a second image dividing module 103, a second feature extraction module 104 and a signing-in judgment module 105. The module of the present invention, which may also be referred to as a unit, refers to a series of computer program segments that can be executed by a processor of an electronic device and that can perform a fixed function, and that are stored in a memory of the electronic device.
In the present embodiment, the functions regarding the respective modules/units are as follows:
the first image dividing module 101 is configured to acquire a monitoring picture of a preset area at a first moment as a first picture, divide the first picture into a plurality of first image areas according to a preset size, and encode the plurality of first image areas according to a preset encoding mode;
the first feature extraction module 102 is configured to select one of the plurality of first image regions one by one as a target region, and extract an image feature of the target region;
the second image dividing module 103 is configured to acquire a monitoring picture of the preset area at a second time as a second picture, divide the second picture into a plurality of second image areas according to the preset size, and encode the plurality of second image areas according to the preset encoding mode;
the second feature extraction module 104 is configured to select, from the second image region, a region with the same number as the target region as a region to be compared, and extract an image feature of the region to be compared;
the sign-in judging module 105 is configured to calculate a difference value between the image feature of the target area and the image feature of the area to be compared, and judge whether the difference value is greater than a preset difference threshold; when the difference value is smaller than or equal to the difference threshold value, determining that goods stored in the target area are not signed; and when the difference value is larger than the difference threshold value, determining that the goods stored in the target area are signed, inquiring the information of recipients of the goods stored in the target area, and reminding the recipients of the goods according to the information of the recipients.
In detail, when the modules in the article signing apparatus 100 based on image recognition in the embodiment of the present invention are used, the same technical means as the article signing method based on image recognition described in fig. 1 to fig. 3 is adopted, and the same technical effects can be produced, which is not described herein again.
Fig. 5 is a schematic structural diagram of an electronic device for implementing an article signing method based on image recognition according to an embodiment of the present invention.
The electronic device 1 may comprise a processor 10, a memory 11, a communication bus 12 and a communication interface 13, and may further comprise a computer program, such as an item signing program based on image recognition, stored in the memory 11 and executable on the processor 10.
In some embodiments, the processor 10 may be composed of an integrated circuit, for example, a single packaged integrated circuit, or may be composed of a plurality of integrated circuits packaged with the same function or different functions, and includes one or more Central Processing Units (CPUs), a microprocessor, a digital Processing chip, a graphics processor, a combination of various control chips, and the like. The processor 10 is a Control Unit (Control Unit) of the electronic device, connects various components of the whole electronic device by using various interfaces and lines, and executes various functions and processes data of the electronic device by running or executing programs or modules stored in the memory 11 (for example, executing an article signing program based on image recognition, etc.), and calling data stored in the memory 11.
The memory 11 includes at least one type of readable storage medium including flash memory, removable hard disks, multimedia cards, card-type memory (e.g., SD or DX memory, etc.), magnetic memory, magnetic disks, optical disks, etc. The memory 11 may in some embodiments be an internal storage unit of the electronic device, for example a removable hard disk of the electronic device. The memory 11 may also be an external storage device of the electronic device in other embodiments, such as a plug-in mobile hard disk, a Smart Media Card (SMC), a Secure Digital (SD) Card, a Flash memory Card (Flash Card), and the like, which are provided on the electronic device. Further, the memory 11 may also include both an internal storage unit and an external storage device of the electronic device. The memory 11 may be used not only to store application software installed in the electronic device and various types of data, such as codes of an article receipt program based on image recognition, etc., but also to temporarily store data that has been output or is to be output.
The communication bus 12 may be a Peripheral Component Interconnect (PCI) bus or an Extended Industry Standard Architecture (EISA) bus. The bus may be divided into an address bus, a data bus, a control bus, etc. The bus is arranged to enable connection communication between the memory 11 and at least one processor 10 or the like.
The communication interface 13 is used for communication between the electronic device and other devices, and includes a network interface and a user interface. Optionally, the network interface may include a wired interface and/or a wireless interface (e.g., WI-FI interface, bluetooth interface, etc.), which are typically used to establish a communication connection between the electronic device and other electronic devices. The user interface may be a Display (Display), an input unit such as a Keyboard (Keyboard), and optionally a standard wired interface, a wireless interface. Alternatively, in some embodiments, the display may be an LED display, a liquid crystal display, a touch-sensitive liquid crystal display, an OLED (Organic Light-Emitting Diode) touch device, or the like. The display, which may also be referred to as a display screen or display unit, is suitable, among other things, for displaying information processed in the electronic device and for displaying a visualized user interface.
Fig. 5 only shows an electronic device with components, and it will be understood by a person skilled in the art that the structure shown in fig. 5 does not constitute a limitation of the electronic device 1, and may comprise fewer or more components than shown, or a combination of certain components, or a different arrangement of components.
For example, although not shown, the electronic device may further include a power supply (such as a battery) for supplying power to each component, and preferably, the power supply may be logically connected to the at least one processor 10 through a power management device, so that functions of charge management, discharge management, power consumption management and the like are realized through the power management device. The power supply may also include any component of one or more dc or ac power sources, recharging devices, power failure detection circuitry, power converters or inverters, power status indicators, and the like. The electronic device may further include various sensors, a bluetooth module, a Wi-Fi module, and the like, which are not described herein again.
It is to be understood that the described embodiments are for purposes of illustration only and that the scope of the appended claims is not limited to such structures.
The memory 11 in the electronic device 1 stores an article signing program based on image recognition, which is a combination of instructions that, when executed in the processor 10, may implement:
the method comprises the steps of obtaining a monitoring picture of a preset area at a first moment as a first picture, dividing the first picture into a plurality of first image areas according to a preset size, and coding the plurality of first image areas according to a preset coding mode;
selecting one of the first image areas as a target area one by one, and extracting image features of the target area;
acquiring a monitoring picture of the preset area at a second moment as a second picture, dividing the second picture into a plurality of second image areas according to the preset size, and coding the plurality of second image areas according to the preset coding mode;
selecting a region with the same number as the target region from the second image region as a region to be compared, and extracting image features of the region to be compared;
calculating a difference value between the image characteristics of the target area and the image characteristics of the area to be compared, and judging whether the difference value is greater than a preset difference threshold value;
when the difference value is smaller than or equal to the difference threshold value, determining that goods stored in the target area are not signed;
and when the difference value is larger than the difference threshold value, determining that the goods stored in the target area are signed, inquiring the information of recipients of the goods stored in the target area, and reminding the recipients of the goods according to the information of the recipients.
Specifically, the specific implementation method of the instruction by the processor 10 may refer to the description of the relevant steps in the embodiment corresponding to the drawings, which is not described herein again.
Further, the integrated modules/units of the electronic device 1, if implemented in the form of software functional units and sold or used as separate products, may be stored in a computer readable storage medium. The computer readable storage medium may be volatile or non-volatile. For example, the computer-readable medium may include: any entity or device capable of carrying said computer program code, recording medium, U-disk, removable hard disk, magnetic disk, optical disk, computer Memory, Read-Only Memory (ROM).
The present invention also provides a computer-readable storage medium, storing a computer program which, when executed by a processor of an electronic device, may implement:
the method comprises the steps of obtaining a monitoring picture of a preset area at a first moment as a first picture, dividing the first picture into a plurality of first image areas according to a preset size, and coding the plurality of first image areas according to a preset coding mode;
selecting one of the first image areas as a target area one by one, and extracting image features of the target area;
acquiring a monitoring picture of the preset area at a second moment as a second picture, dividing the second picture into a plurality of second image areas according to the preset size, and coding the plurality of second image areas according to the preset coding mode;
selecting a region with the same number as the target region from the second image region as a region to be compared, and extracting image features of the region to be compared;
calculating a difference value between the image characteristics of the target area and the image characteristics of the area to be compared, and judging whether the difference value is greater than a preset difference threshold value;
when the difference value is smaller than or equal to the difference threshold value, determining that goods stored in the target area are not signed;
and when the difference value is larger than the difference threshold value, determining that the goods stored in the target area are signed, inquiring the information of recipients of the goods stored in the target area, and reminding the recipients of the goods according to the information of the recipients.
In the embodiments provided in the present invention, it should be understood that the disclosed apparatus, device and method can be implemented in other ways. For example, the above-described apparatus embodiments are merely illustrative, and for example, the division of the modules is only one logical functional division, and other divisions may be realized in practice.
The modules described as separate parts may or may not be physically separate, and parts displayed as modules may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of the present embodiment.
In addition, functional modules in the embodiments of the present invention may be integrated into one processing unit, or each unit may exist alone physically, or two or more units are integrated into one unit. The integrated unit can be realized in a form of hardware, or in a form of hardware plus a software functional module.
It will be evident to those skilled in the art that the invention is not limited to the details of the foregoing illustrative embodiments, and that the present invention may be embodied in other specific forms without departing from the spirit or essential attributes thereof.
The present embodiments are therefore to be considered in all respects as illustrative and not restrictive, the scope of the invention being indicated by the appended claims rather than by the foregoing description, and all changes which come within the meaning and range of equivalency of the claims are therefore intended to be embraced therein. Any reference signs in the claims shall not be construed as limiting the claim concerned.
The block chain is a novel application mode of computer technologies such as distributed data storage, point-to-point transmission, a consensus mechanism, an encryption algorithm and the like. A block chain (Blockchain), which is essentially a decentralized database, is a series of data blocks associated by using a cryptographic method, and each data block contains information of a batch of network transactions, so as to verify the validity (anti-counterfeiting) of the information and generate a next block. The blockchain may include a blockchain underlying platform, a platform product service layer, an application service layer, and the like.
The embodiment of the application can acquire and process related data based on an artificial intelligence technology. Among them, Artificial Intelligence (AI) is a theory, method, technique and application system that simulates, extends and expands human Intelligence using a digital computer or a machine controlled by a digital computer, senses the environment, acquires knowledge and uses the knowledge to obtain the best result.
Furthermore, it is obvious that the word "comprising" does not exclude other elements or steps, and the singular does not exclude the plural. A plurality of units or means recited in the system claims may also be implemented by one unit or means in software or hardware. The terms first, second, etc. are used to denote names, but not any particular order.
Finally, it should be noted that the above embodiments are only for illustrating the technical solutions of the present invention and not for limiting, and although the present invention is described in detail with reference to the preferred embodiments, it should be understood by those skilled in the art that modifications or equivalent substitutions may be made on the technical solutions of the present invention without departing from the spirit and scope of the technical solutions of the present invention.
Claims (10)
1. An article signing method based on image recognition, the method comprising:
the method comprises the steps of obtaining a monitoring picture of a preset area at a first moment as a first picture, dividing the first picture into a plurality of first image areas according to a preset size, and coding the plurality of first image areas according to a preset coding mode;
selecting one of the first image areas as a target area one by one, and extracting image features of the target area;
acquiring a monitoring picture of the preset area at a second moment as a second picture, dividing the second picture into a plurality of second image areas according to the preset size, and coding the plurality of second image areas according to the preset coding mode;
selecting a region with the same number as the target region from the second image region as a region to be compared, and extracting image features of the region to be compared;
calculating a difference value between the image characteristics of the target area and the image characteristics of the area to be compared, and judging whether the difference value is greater than a preset difference threshold value;
when the difference value is smaller than or equal to the difference threshold value, determining that goods stored in the target area are not signed;
and when the difference value is larger than the difference threshold value, determining that the goods stored in the target area are signed, inquiring the information of recipients of the goods stored in the target area, and reminding the recipients of the goods according to the information of the recipients.
2. The method for signing an article based on image recognition as claimed in claim 1, wherein said dividing said first picture into a plurality of first image areas according to a preset size comprises:
generating an image frame according to the preset size;
and repeatedly performing framing on the areas in the first picture by using the image frames until all the areas in the first picture are framed and selected, so as to obtain a plurality of first image areas.
In detail, the preset size may be data of a length and a width of the area stored in each article in the first frame, which are acquired in advance.
3. The method for signing an article based on image recognition as claimed in claim 1, wherein said encoding said plurality of first image areas according to a preset encoding mode comprises:
selecting a column of image areas from the plurality of first image areas one by one as a target column according to the sequence from top to bottom;
each first image region in the target column is incrementally encoded in left-to-right order.
4. The method for signing an article based on image recognition as claimed in claim 1, wherein the extracting the image feature of the target area comprises:
generating global features of the target region according to the pixel gradient in the target region;
performing frame selection on the regions in the target region one by using a preset sliding window to obtain a pixel window;
generating local features of the target region according to the pixel values in each pixel window;
and collecting the global features and the local features as the image features of the target area.
5. The image recognition-based item sign-on method of claim 4, wherein the generating global features of the target region from pixel gradients in the target region comprises:
counting the pixel value of each pixel point in the target area;
taking the maximum pixel value and the minimum pixel value in the pixel values as parameters of a preset mapping function, and mapping the pixel value of each pixel point in the target area to a preset range by using the preset function;
calculating the pixel gradient of each line of pixels in the mapped target area, converting the pixel gradient of each line of pixels into a line vector, and splicing the line vector into the global feature of the target area.
6. The image recognition-based item signing method of claim 4, wherein said generating local features of the target region from pixel values in each of the pixel windows comprises:
selecting one pixel point from the pixel window one by one as a target pixel point;
judging whether the pixel value of the target pixel point is an extreme value in the pixel window;
when the pixel value of the target pixel point is not an extreme value in the pixel window, returning to the step of selecting one pixel point from the pixel window one by one as the target pixel point;
when the pixel value of the target pixel point is an extreme value in the pixel window, determining the target pixel point as a key point;
vectorizing the pixel values of all key points in all the pixel windows, and collecting the obtained vectors as the local features of the target area.
7. The method according to any one of claims 1 to 6, wherein the calculating a difference value between the image feature of the target area and the image feature of the area to be compared comprises:
calculating a first difference value between the global feature of the target area and the global feature of the area to be compared by using a preset first distance algorithm;
calculating a second difference value between the local feature of the target region and the local feature of the region to be compared by using a preset second distance algorithm;
and calculating to obtain a difference value between the image characteristic of the target area and the image characteristic of the area to be compared according to the first difference value and the second difference value by using a preset weight algorithm.
8. An article signing device based on image recognition, the device comprising:
the first image dividing module is used for acquiring a monitoring picture of a preset area at a first moment as a first picture, dividing the first picture into a plurality of first image areas according to a preset size, and coding the plurality of first image areas according to a preset coding mode;
the first feature extraction module is used for selecting one of the first image areas as a target area one by one and extracting image features of the target area;
the second image dividing module is used for acquiring a monitoring picture of the preset area at a second moment as a second picture, dividing the second picture into a plurality of second image areas according to the preset size, and coding the plurality of second image areas according to the preset coding mode;
the second feature extraction module is used for selecting a region with the same number as the target region from the second image region as a region to be compared and extracting the image features of the region to be compared;
the sign-in judging module is used for calculating a difference value between the image characteristics of the target area and the image characteristics of the area to be compared and judging whether the difference value is greater than a preset difference threshold value or not; when the difference value is smaller than or equal to the difference threshold value, determining that goods stored in the target area are not signed; and when the difference value is larger than the difference threshold value, determining that the goods stored in the target area are signed, inquiring the information of recipients of the goods stored in the target area, and reminding the recipients of the goods according to the information of the recipients.
9. An electronic device, characterized in that the electronic device comprises:
at least one processor; and the number of the first and second groups,
a memory communicatively coupled to the at least one processor; wherein,
the memory stores a computer program executable by the at least one processor to enable the at least one processor to perform the method of image recognition based item signoff of any of claims 1 to 7.
10. A computer-readable storage medium, in which a computer program is stored, which, when being executed by a processor, implements the image recognition-based item signing method according to any one of claims 1 to 7.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202111148147.1A CN113888086B (en) | 2021-09-29 | 2021-09-29 | Article signing method, device, equipment and storage medium based on image recognition |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202111148147.1A CN113888086B (en) | 2021-09-29 | 2021-09-29 | Article signing method, device, equipment and storage medium based on image recognition |
Publications (2)
Publication Number | Publication Date |
---|---|
CN113888086A true CN113888086A (en) | 2022-01-04 |
CN113888086B CN113888086B (en) | 2024-06-28 |
Family
ID=79007698
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202111148147.1A Active CN113888086B (en) | 2021-09-29 | 2021-09-29 | Article signing method, device, equipment and storage medium based on image recognition |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN113888086B (en) |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN115187930A (en) * | 2022-09-13 | 2022-10-14 | 广州科弗联信息科技有限公司 | Reservoir safety monitoring method and device |
Citations (8)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20110243376A1 (en) * | 2007-08-04 | 2011-10-06 | Continental Teves Ag & Ohg | Method and a device for detecting objects in an image |
US20120288189A1 (en) * | 2011-05-13 | 2012-11-15 | Tsinghua University | Image processing method and image processing device |
JP2016181211A (en) * | 2015-03-25 | 2016-10-13 | 日本電気株式会社 | Label area detection device, label area detection method, label area detection program, and label area detection system |
US20180150974A1 (en) * | 2015-06-12 | 2018-05-31 | Sony Corporation | Image processing apparatus, method, and program |
CN109766956A (en) * | 2018-07-19 | 2019-05-17 | 西北工业大学 | Method for detecting abnormality based on express delivery big data |
CN109934218A (en) * | 2019-01-22 | 2019-06-25 | 阿里巴巴集团控股有限公司 | A kind of recognition methods and device for logistics single image |
CN113112323A (en) * | 2021-03-16 | 2021-07-13 | 中国平安财产保险股份有限公司 | Abnormal order identification method, device, equipment and medium based on data analysis |
CN113298453A (en) * | 2020-08-28 | 2021-08-24 | 阿里巴巴集团控股有限公司 | Data processing method and system and electronic equipment |
-
2021
- 2021-09-29 CN CN202111148147.1A patent/CN113888086B/en active Active
Patent Citations (8)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20110243376A1 (en) * | 2007-08-04 | 2011-10-06 | Continental Teves Ag & Ohg | Method and a device for detecting objects in an image |
US20120288189A1 (en) * | 2011-05-13 | 2012-11-15 | Tsinghua University | Image processing method and image processing device |
JP2016181211A (en) * | 2015-03-25 | 2016-10-13 | 日本電気株式会社 | Label area detection device, label area detection method, label area detection program, and label area detection system |
US20180150974A1 (en) * | 2015-06-12 | 2018-05-31 | Sony Corporation | Image processing apparatus, method, and program |
CN109766956A (en) * | 2018-07-19 | 2019-05-17 | 西北工业大学 | Method for detecting abnormality based on express delivery big data |
CN109934218A (en) * | 2019-01-22 | 2019-06-25 | 阿里巴巴集团控股有限公司 | A kind of recognition methods and device for logistics single image |
CN113298453A (en) * | 2020-08-28 | 2021-08-24 | 阿里巴巴集团控股有限公司 | Data processing method and system and electronic equipment |
CN113112323A (en) * | 2021-03-16 | 2021-07-13 | 中国平安财产保险股份有限公司 | Abnormal order identification method, device, equipment and medium based on data analysis |
Non-Patent Citations (1)
Title |
---|
殷聿明;: "基于物联网的智能快递签收系统设计", 中外企业家, no. 05, 15 February 2020 (2020-02-15) * |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN115187930A (en) * | 2022-09-13 | 2022-10-14 | 广州科弗联信息科技有限公司 | Reservoir safety monitoring method and device |
Also Published As
Publication number | Publication date |
---|---|
CN113888086B (en) | 2024-06-28 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN112100425B (en) | Label labeling method and device based on artificial intelligence, electronic equipment and medium | |
CN112396005A (en) | Biological characteristic image recognition method and device, electronic equipment and readable storage medium | |
CN113283446A (en) | Method and device for identifying target object in image, electronic equipment and storage medium | |
CN111695609A (en) | Target damage degree determination method, target damage degree determination device, electronic device, and storage medium | |
CN113705461A (en) | Face definition detection method, device, equipment and storage medium | |
CN113887408B (en) | Method, device, equipment and storage medium for detecting activated face video | |
CN114550051A (en) | Vehicle loss detection method and device, computer equipment and storage medium | |
CN114049568A (en) | Object shape change detection method, device, equipment and medium based on image comparison | |
CN115471775A (en) | Information verification method, device and equipment based on screen recording video and storage medium | |
CN113888086B (en) | Article signing method, device, equipment and storage medium based on image recognition | |
CN113627394A (en) | Face extraction method and device, electronic equipment and readable storage medium | |
CN113723280A (en) | Static face-based confrontation sample detection method, device, equipment and medium | |
CN114463685B (en) | Behavior recognition method, behavior recognition device, electronic equipment and storage medium | |
CN113255456B (en) | Inactive living body detection method, inactive living body detection device, electronic equipment and storage medium | |
CN116340537A (en) | Character relation extraction method and device, electronic equipment and storage medium | |
CN115098644A (en) | Image and text matching method and device, electronic equipment and storage medium | |
CN115205758A (en) | Intelligent conversion method and device based on video and text, electronic equipment and medium | |
CN113918769A (en) | Method, device and equipment for marking key actions in video and storage medium | |
CN114187476A (en) | Vehicle insurance information checking method, device, equipment and medium based on image analysis | |
CN114882420A (en) | Reception people counting method and device, electronic equipment and readable storage medium | |
CN113705459A (en) | Face snapshot method and device, electronic equipment and storage medium | |
CN112541436A (en) | Concentration degree analysis method and device, electronic equipment and computer storage medium | |
CN114049676A (en) | Fatigue state detection method, device, equipment and storage medium | |
CN114186540A (en) | Mail content intelligent filling method and device, electronic equipment and storage medium | |
CN113887384A (en) | Pedestrian trajectory analysis method, device, equipment and medium based on multi-trajectory fusion |
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 | ||
GR01 | Patent grant | ||
GR01 | Patent grant |