CN115817939B - Control method and device of packaging equipment, computer equipment and storage medium - Google Patents

Control method and device of packaging equipment, computer equipment and storage medium Download PDF

Info

Publication number
CN115817939B
CN115817939B CN202211130881.XA CN202211130881A CN115817939B CN 115817939 B CN115817939 B CN 115817939B CN 202211130881 A CN202211130881 A CN 202211130881A CN 115817939 B CN115817939 B CN 115817939B
Authority
CN
China
Prior art keywords
identified
image
product
product type
line scanning
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.)
Active
Application number
CN202211130881.XA
Other languages
Chinese (zh)
Other versions
CN115817939A (en
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.)
Fengjurui Suzhou Technology Co ltd
Original Assignee
Fengjurui Suzhou Technology 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 Fengjurui Suzhou Technology Co ltd filed Critical Fengjurui Suzhou Technology Co ltd
Priority to CN202211130881.XA priority Critical patent/CN115817939B/en
Publication of CN115817939A publication Critical patent/CN115817939A/en
Application granted granted Critical
Publication of CN115817939B publication Critical patent/CN115817939B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Abstract

The invention discloses a control method and device of packaging equipment, computer equipment and a storage medium, wherein the method comprises the following steps: after receiving a packaging instruction of a target order, acquiring product information of the target order, wherein the product information comprises product types of a plurality of products; according to standard appearance information of a plurality of products in a target order, imaging parameters of a line scanning camera in packaging equipment are adjusted, and after adjustment is completed, the line scanning camera is controlled to acquire images of conveying objects on a conveying belt to obtain images to be identified; carrying out product identification on the image to be identified to obtain a product type corresponding to the image to be identified; and when the product type corresponding to the image to be identified is not the product type in the target order, controlling the packaging machine positioned at the tail end of the conveyor belt to stop working, and carrying out product error early warning. The invention can improve the accuracy of product identification, and can more efficiently, accurately and intelligently finish the task of product information correction compared with manual work.

Description

Control method and device of packaging equipment, computer equipment and storage medium
Technical Field
The invention relates to the field of intelligent manufacturing, in particular to the technical field of automatic control, and specifically relates to a control method and device of packaging equipment, computer equipment and a storage medium.
Background
With the rapid development of electronic commerce, the market has continuously increased efficiency requirements for various links of a product supply chain, such as product production, packaging, distribution, transportation, and the like. In the whole process of a product supply chain, product information proofreading is an essential important link, and is a key for ensuring that various information such as product types, appearances, structures, quantity, numbers and the like are correct in the production circulation process.
The traditional supply chain links mainly rely on manual work to correct product information, and the method is time-consuming and labor-consuming, is a short plate for reducing the efficiency of the supply chain, is influenced by subjective factors of people, and is difficult to ensure accuracy. And moreover, product information is manually checked, so that real-time uploading of data and timely monitoring of production circulation states are difficult to achieve, production automation management of enterprises is affected, and digital construction of the industry is not facilitated.
Disclosure of Invention
The invention provides a control method, a control device, computer equipment and a storage medium of packaging equipment, which are used for solving the problems of time consumption, labor consumption and low accuracy of the existing supply chain link in a way of manually checking product information.
There is provided a control method of a packaging apparatus, including:
After receiving a packaging instruction of a target order, acquiring product information of the target order, wherein the product information comprises product types of a plurality of products;
according to standard appearance information of a plurality of products in a target order, imaging parameters of a line scanning camera in packaging equipment are adjusted, and after adjustment is completed, the line scanning camera is controlled to acquire images of conveying objects on a conveying belt to obtain images to be identified;
carrying out product identification on the image to be identified to obtain a product type corresponding to the image to be identified;
and when the product type corresponding to the image to be identified is not the product type in the target order, controlling the packaging machine positioned at the tail end of the conveyor belt to stop working, and carrying out product error early warning.
Further, after product identification is performed on the image to be identified to obtain the product type corresponding to the image to be identified, the method further comprises the steps of:
when the product type corresponding to the image to be identified is determined to be the product type in the target order, recording the transmission object as the product to be processed, and recording the product type of the product to be processed and the product quantity of the product type;
determining the product type of the product to be processed and the product quantity of the product type, and whether the product requirement of the target order is met or not;
And if the product requirement of the target order is met, controlling the packaging machine to package all the current products to be processed.
Further, product identification is carried out on the image to be identified to obtain a product type corresponding to the image to be identified, and the method comprises the following steps:
when the image to be identified is the first image to be identified acquired by the line scanning camera, carrying out product identification on the first image to be identified by adopting a preset identification model to obtain a product type corresponding to the first image to be identified.
When the image to be identified is not the first image to be identified acquired by the line scanning camera, carrying out product identification on the current image to be identified according to the last image to be identified, and obtaining the product type corresponding to the current image to be identified.
Further, product identification is carried out on the current image to be identified according to the last image to be identified, so as to obtain the product type corresponding to the current image to be identified, which comprises the following steps:
performing background modeling on the previous image to be identified to obtain a background model, and inputting the current image to be identified into the background model to perform foreground identification to obtain the foreground image area of the current image to be identified;
determining whether the foreground image area of the current image to be identified is smaller than a preset area;
and if the foreground area of the current image to be identified is smaller than the preset area, taking the product type corresponding to the last image to be identified as the product type corresponding to the current image to be identified.
Further, after determining whether the foreground area of the current image to be identified is smaller than the preset area, the method further includes:
and if the foreground area of the current image to be identified is larger than or equal to the preset area, classifying and identifying the current image to be identified by adopting a preset identification model to obtain the product type corresponding to the current image to be identified.
Further, product identification is carried out on the current image to be identified by adopting a preset identification model, so as to obtain the product type corresponding to the current image to be identified, and the method comprises the following steps:
positioning a transmission object on the current image to be identified and cutting out a target image of the transmission object;
inputting the target image into a preset recognition model to recognize the product, and acquiring the type of the product output by the preset recognition model;
and marking the product type output by the preset identification model as the product type corresponding to the current image to be identified.
Further, the control line scanning camera performs image acquisition on a conveying object on a conveying belt to obtain an image to be identified, and the method comprises the following steps:
detecting the state of the conveyor belt through a detection structure to obtain the state of the conveyor belt;
when the state of the conveyor belt is an operation state, the line scanning camera is controlled to be started so as to acquire images of the conveyed objects on the conveyor belt and obtain images to be identified;
When the state of the conveyor belt is in a stop state, the control line scanning camera is turned off so as to stop image acquisition of the conveyed objects on the conveyor belt.
Further, before the control line scanning camera is turned on, the method further comprises:
determining whether a first signal output by a preset sensor is received or not, wherein the first signal is used for indicating that the preset sensor detects that a conveying object exists on a conveying belt;
and if the first signal output by the preset sensor is received, controlling the line scanning camera to be started.
Further, after the control line scanning camera is turned on, the method further comprises:
determining whether a second preset signal output by a preset sensor is received;
and if the second signal output by the preset sensor is received, the line scanning camera is controlled to be turned off.
Further, the method for positioning the transmission object on the current image to be identified and cutting out the target image of the transmission object comprises the following steps:
converting the current image to be identified into an image matrix, and carrying out normalization processing on the image matrix to obtain an image to be processed;
inputting the image to be processed into a target detection network, and positioning a transmission object in the image to be processed through the target detection network to obtain an area where the transmission object is located;
And cutting out the region where the transmission object is located from the image to be processed to obtain a target image of the transmission object.
There is provided a control device of a packaging apparatus, characterized by comprising:
the acquisition module is used for acquiring product information of the target order after receiving a packaging instruction of the target order, wherein the product information comprises product types of a plurality of products;
the first control module is used for adjusting imaging parameters of the line scanning camera in the packaging equipment according to standard appearance information of a plurality of products in the target order, and controlling the line scanning camera to acquire images of the conveying objects on the conveying belt to obtain images to be identified after the adjustment is completed;
the identification module is used for carrying out product identification on the image to be identified to obtain a product type corresponding to the image to be identified;
and the second control module is used for controlling the packaging machine positioned at the tail end of the conveyor belt to stop working and carrying out product error early warning when the product type corresponding to the image to be identified is not the product type in the target order.
There is provided a computer device comprising a memory, a processor and a computer program stored in the memory and executable on the processor, the processor executing the computer program to carry out the steps of the control method of the packaging device described above.
There is provided a computer readable storage medium storing a computer program which, when executed by a processor, implements the steps of the control method of a packaging apparatus as described above.
In one scheme provided by the control method, the control device, the computer equipment and the storage medium of the packaging equipment, after receiving the packaging instruction of the target order, obtaining the product information of the target order, wherein the product information comprises the product types of a plurality of products; according to standard appearance information of a plurality of products in a target order, imaging parameters of a line scanning camera in packaging equipment are adjusted, and after adjustment is completed, the line scanning camera is controlled to acquire images of conveying objects on a conveying belt to obtain images to be identified; carrying out product identification on the image to be identified to obtain a product type corresponding to the image to be identified; and when the product type corresponding to the image to be identified is not the product type in the target order, controlling the packaging machine positioned at the tail end of the conveyor belt to stop working, and carrying out product error early warning. According to the invention, imaging parameters of the line scanning camera are adjusted according to standard appearance information of a target order, and then the line scanning camera is used for identifying products of a conveying object on the conveyor belt, so that the imaging effect of the line scanning camera can be effectively improved, the accuracy of subsequent product identification is further improved, packaging and early warning can be timely stopped when the fact that the product information on the conveyor belt is inconsistent with the order requirement is identified, the production process can be timely corrected, and compared with manual work, the product information correction task can be more efficiently, accurately and intelligently completed.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings that are needed in the description of the embodiments of the present invention will be briefly described below, it being obvious that the drawings in the following description are only some embodiments of the present invention, and that other drawings may be obtained according to these drawings without inventive effort for a person skilled in the art.
FIG. 1 is a schematic view of a packaging apparatus according to an embodiment of the present invention;
FIG. 2 is a flow chart of a control method of a packaging apparatus according to an embodiment of the present invention;
FIG. 3 is another flow chart of a control method of a packaging device according to an embodiment of the present invention;
FIG. 4 is another flow chart of a control method of a packaging device according to an embodiment of the present invention;
FIG. 5 is a schematic view showing a structure of a control device of a packaging apparatus according to an embodiment of the present invention;
FIG. 6 is a schematic diagram of a computer device according to an embodiment of the invention.
Wherein, each reference sign in the figure:
1-conveying an object; 2-control means of the packaging device; 3-line scan camera; 4-a conveyor belt; 41-a roller; 5-a light source; 61-a detection wheel; 62-an encoder; 7-fixing the bracket.
Detailed Description
The following description of the embodiments of the present invention will be made clearly and fully with reference to the accompanying drawings, in which it is evident that the embodiments described are some, but not all embodiments of the invention. All other embodiments, which can be made by those skilled in the art based on the embodiments of the invention without making any inventive effort, are intended to be within the scope of the invention.
The control method of the packaging device provided by the embodiment of the invention can be applied to the packaging device shown in fig. 1, wherein the packaging device comprises a conveying mechanism, a line scanning camera 3, a packaging machine (not shown) and a control device 2 of the packaging device. Wherein the conveyor comprises a conveyor belt 4 for moving a plurality of conveying objects 1, and an associated drive motor (not shown). The packing machine is located at the end of the conveyor belt 4 for palletizing and packing the conveyed objects 1 conveyed by the conveyor belt 4. The optical recognition component comprises a line scanning camera 3 arranged above a conveyor belt 4, the line scanning camera 3 is an industrial camera for detecting continuous materials, the detected objects generally move at a uniform speed, and the line scanning camera 3 continuously scans the detected objects line by line so as to achieve the purpose of uniformly detecting the whole surface of the detected objects. The lens of the line scanning camera 3 is directed to the detection station on the conveyor belt 4, and the line scanning camera 3 collects image data of the conveyed object 1 passing through the detection station on the conveyor belt 4 in real time while the conveyor belt 4 is running. The control device 2 of the packaging apparatus communicates with the line scanning camera 3 to acquire image data (image to be recognized) collected by the line scanning camera 3 in real time, and recognizes information such as the product type (brand), number, etc. of the conveying object 1 on the conveying belt based on the image to be recognized.
After receiving a packaging instruction of a target order, acquiring product information of the target order, wherein the product information comprises product types of a plurality of products; according to standard appearance information of a plurality of products in a target order, imaging parameters of a line scanning camera 3 in packaging equipment are adjusted, and after adjustment is completed, the line scanning camera 3 is controlled to acquire images of a conveying object 1 on a conveying belt 4 to obtain an image to be identified; carrying out product identification on the image to be identified to obtain a product type corresponding to the image to be identified; and when the product type corresponding to the image to be identified is not the product type in the target order, controlling the packaging machine positioned at the tail end of the conveyor belt 4 to stop working, and carrying out product error early warning. In this embodiment, the imaging parameters of the line scanning camera are adjusted according to the standard appearance information of the target order, and then the line scanning camera 3 is used for identifying the product of the conveying object 1 on the conveyor belt 4, so that the imaging effect of the line scanning camera can be effectively improved, the accuracy of subsequent product identification is further improved, when the fact that the product information on the conveyor belt 4 does not accord with the order requirement is identified, packaging and early warning can be timely stopped, the production process can be timely corrected, the purpose of efficiently and quickly inspecting the error products is achieved, and economic losses caused by shipping errors are reduced. Compared with manual work, the embodiment can more efficiently, accurately and intelligently finish the product information calibration task, thereby improving the product production and circulation efficiency and the economic benefit.
In addition, the line scanning camera 3 is adopted to continuously collect and identify the images of the conveying objects 1 on the conveying belt 4, so that the problems of limited imaging field of view, shielding of a spatial mechanism, uneven illumination of the object moving direction and the like caused by the traditional use of the area array camera in image collection can be reduced, the conditions of low identification rate and frequent false alarm can be avoided, and the identification accuracy and the early warning accuracy can be improved.
In the present embodiment, the packaging apparatus including the conveying mechanism, the line scanning camera 3, the packaging machine, and the control device 2 of the packaging apparatus are merely illustrative, and in other embodiments, the packaging apparatus may further include other devices, such as a light source, and a warning device such as a buzzer, an indicator light, and the like.
The control device of the packaging device can be various personal computers, notebook computers, smart phones, tablet computers and other devices, and can also be realized by an independent server or a server cluster formed by a plurality of servers.
In an embodiment, as shown in fig. 2, a control method of a packaging apparatus is provided, and an example of a control device of the packaging apparatus to which the method is applied in fig. 1 is described, including the steps of:
s10: and after receiving the packaging instruction of the target order, acquiring product information of the target order, wherein the product information comprises product types of a plurality of products.
After receiving the product order, the information of the product is required to be checked according to the product information in the target order, and the checked product is packaged to obtain the packaging box of the product order. After checking the products, when packing the products in the target order, a packing instruction of the target order needs to be sent to a control device of the packing equipment, so that the control device of the packing equipment controls the corresponding device to pack the products in the target order according to the packing instruction.
After receiving a packaging instruction of a target order, a control device of the packaging equipment needs to acquire product information of the target order, wherein the product information comprises product types of a plurality of products and product data of each product type.
S20: and adjusting imaging parameters of the line scanning camera in the packaging equipment according to the standard appearance information of a plurality of products in the target order, and controlling the line scanning camera to acquire images of the conveying objects on the conveying belt after finishing adjustment to obtain images to be identified.
In order to ensure the accuracy of packaged products, the control device of the packaging equipment needs to acquire images of the conveying objects on the conveying belt through the line scanning camera to obtain images to be identified. Wherein, in order to improve imaging effect, the control device of the packaging equipment needs to adjust imaging parameters of the linear scanning camera before image acquisition. Therefore, after the product information of the target order is acquired, standard appearance information of multiple types of products in the target order is required to be acquired from a database, and then imaging parameters of the line scanning camera in the packaging equipment are adjusted according to the standard appearance information of the multiple products in the target order, so that the imaging effect of the line scanning camera reaches the optimal state suitable for detecting all types of products of the target order, and the image precision of the image to be identified acquired by the line scanning camera is improved. After the adjustment is completed, the control device of the packaging equipment controls the line scanning camera to acquire images of the conveying objects on the conveying belt to obtain images to be identified.
The standard appearance information of the product is information for standardized expression of the appearance of the type of product. The standard appearance information of the product can be appearance image information of the corresponding type of product or appearance text description image information of the corresponding type of product. Or other data containing product appearance information, in other embodiments, the standard appearance information for the product may also be other data containing product appearance information.
For example, imaging parameters of a line scan camera include exposure values, image gain, gamma values, and the like. The control device of the packaging equipment calls out standard appearance information of the corresponding product from the database according to the product requirement of the target order. For example, the product requirement (product information) of the target order is a smoke of a 10, a smoke of b 6 and a smoke of c 9, and then standard appearance information of three kinds of cigarettes of a, b and c is called out from the database, and the standard appearance information can be a standard appearance picture of three kinds of cigarettes of a, b and c, and also can be an appearance text description of three kinds of cigarettes of a, b and c, such as a: black; b, a step of: yellow blue; and C: and (3) red.
The adjusting of imaging parameters of the line scanning camera in the packaging equipment according to the standard appearance information of a plurality of products in the target order can be as follows: carrying out algorithm analysis on the standard appearance information of the plurality of products in the target order to obtain the color classification of the plurality of products in the target order; and increasing or decreasing the exposure value and the image gain of the line scanning camera according to the color classification of the products in the target order.
For example, the product requirements for the target order are a 10 cigarettes, b 6 cigarettes, and c 9 cigarettes; the standard appearance information of the products in the target order is respectively as follows: nail (A): black, b: blue yellow, c: the method comprises the steps that if the imaging parameters of a current line scanning camera are smaller, the exposure value and the image gain imaging parameters of the line scanning camera are increased to improve the imaging effect; and otherwise, reducing the exposure value and the image gain imaging parameters of the line scanning camera to ensure that the imaging effect of the line scanning camera reaches the optimal state suitable for detecting all types of products of the target order.
S30: and carrying out product identification on the image to be identified to obtain the product type corresponding to the image to be identified.
After the image to be identified acquired by the line scanning camera is obtained, the control device of the packaging device needs to identify the image to be identified, and identify the product type (brand) of the conveying object so as to determine whether the conveying object on the conveying belt is a product in the target order. If the product type corresponding to the image to be identified is determined to be the product type in the target order, namely the conveying object is the product in the target order, the packaging machine is controlled to stack the conveying object, the next conveying object is continuously identified until the target order is determined to be completed, and the packaging machine is controlled to package the product required in the target order.
For example, the image to be identified is directly input into a preset identification model, the product identification is carried out on the image to be identified through the preset identification model, the identification product output by the preset identification model is obtained, and whether the identification product output by the preset identification model is the product in the target order is judged. The preset recognition model is a neural network model obtained by performing deep learning training according to image data acquired by the line scanning camera. The network of the preset recognition model can be a classification network such as resnet, vggnet, mobilenet, shufflenet, googlenet, in the training process, the model is continuously converged in a random gradient descent mode, and the softmax cross entropy loss function is used as a loss function of the preset recognition model.
S40: and when the product type corresponding to the image to be identified is not the product type in the target order, controlling the packaging machine positioned at the tail end of the conveyor belt to stop working, and carrying out product error early warning.
When the product type corresponding to the image to be identified is determined not to be the product type in the target order, namely, the conveying object on the conveying belt is not the product in the target order, the control device of the packaging equipment controls the packaging machine at the tail end of the conveying belt to stop working so as to prevent the wrong product from being packaged, and meanwhile, product error early warning is carried out. When the product type corresponding to the image to be identified is determined not to be the product type in the target order, the control device of the packaging equipment needs to send a packaging machine stopping instruction to the packaging machine, and the packaging machine stops working after receiving the packaging machine stopping instruction; meanwhile, the control device of the packaging equipment performs product error early warning to prompt related staff to have product errors, so that the related staff can timely learn the problem of the product errors and perform related operations, and the related staff intervenes in adjusting the products to enable the packaging machine to correctly package target orders.
For example, the product in the target order is a cigarette packet of a certain brand, and because the outer package of the plastic package product such as the cigarette packet is plastic package, strong light reflection easily occurs when the light irradiates to the plastic package surface of the plastic package product, accurate judgment of the brand of the cigarette packet is affected, and mismatching products are easily packaged into the target order during packaging. In this embodiment, before packaging, a line scanning camera is used to collect images of a conveying object on a conveyor belt to obtain an image to be identified, product identification is performed on the image to be identified, whether the conveying object is a cigarette packet of the brand or not is determined, if the conveying object is not a cigarette packet or is not a cigarette packet of the brand, the packaging machine is controlled to stop working if the conveying object indicates that the product is wrong, and product error early warning is performed, so that whether wrong cigarette packets are mixed in batch products can be timely found, and the purpose of efficiently and quickly checking the wrong cigarette packets is achieved.
If a single light source is used for irradiating plastic package products such as cigarette packets and the like for image acquisition, the problem of overexposure caused by local over-brightness or the problem of local over-darkness caused by insufficient light rays may exist. In other embodiments, as shown in fig. 1, when the online scanning camera performs image acquisition, the packaging device may further be provided with a plurality of light sources 5 on two sides of the conveyor belt, where the light rays of each light source 5 are converged at a detection station on the conveyor belt. Under the irradiation of light rays emitted by a plurality of light sources 5 from multiple angles, the plastic package products such as cigarette packets passing through a detection station can be illuminated, the plastic package products such as the cigarette packets are illuminated by the multiple angles and the multiple light sources, the problem of overexposure can be avoided during image acquisition, the accuracy of an image to be identified is improved, the image identification accuracy is improved, and error products are further arranged. Wherein in certain embodiments the plurality of light sources 5 may be a plurality of bar lamps. The strip lamp can output strip-shaped light, and irradiates on a conveying object 1 (such as a cigarette packet) to form strip-shaped light spots. The product is generally rectangular after being packaged (namely, the object is conveyed), and when the image acquisition is carried out on the upper surface of the product, the strip-shaped light spots can adapt to the shape of the product, so that the product (namely, the object is conveyed) is always in an illuminated state in the process of moving and acquiring the image. The strip lamps are respectively positioned at two sides of the conveyor belt 4, and can emit light from the two sides of the conveyor belt 4 to irradiate the surface of the conveyed object. Moreover, at least two strip lamps are symmetrically arranged on two sides of the detection station, and the opposite surfaces of the two strip lamps are set to be light-emitting surfaces, so that the two strip lamps can be parallel and opposite, diffuse reflection is formed on the whole surface of a conveying object more easily, and local overexposure is avoided.
In this embodiment, after receiving a packaging instruction of a target order, product information of the target order is obtained, where the product information includes product types of a plurality of products; according to standard appearance information of a plurality of products in a target order, imaging parameters of a line scanning camera in packaging equipment are adjusted, and after adjustment is completed, the line scanning camera is controlled to acquire images of conveying objects on a conveying belt to obtain images to be identified; carrying out product identification on the image to be identified to obtain a product type corresponding to the image to be identified; and when the product type corresponding to the image to be identified is not the product type in the target order, controlling the packaging machine positioned at the tail end of the conveyor belt to stop working, and carrying out product error early warning. The line scanning camera is used for identifying the products of the conveying objects on the conveying belt, when the products on the conveying belt are not products in the target order form, the control is performed to stop the packaging machine and perform product error early warning, the non-order products can be timely found, the purpose of efficiently and quickly checking the error products is achieved, and therefore the problem of economic loss caused by delivery errors is solved. In addition, the line scanning camera is adopted to collect and identify the image of the conveying object on the conveying belt, so that the problems of limited imaging field of view, shielding of a space mechanism, uneven illumination of the object moving direction and the like caused by the traditional use of the area array camera during image collection can be reduced, the conditions of low identification rate and frequent false alarm are avoided, and the identification accuracy and the early warning accuracy are improved.
Meanwhile, imaging parameters of the line scanning camera are adjusted according to standard appearance information of a target order, the line scanning camera is used for identifying products of conveying objects on the conveying belt, imaging effect of the line scanning camera can be effectively improved, further follow-up product identification accuracy is improved, packaging and early warning can be timely stopped when product information on the conveying belt is not matched with order requirements, production processes can be timely corrected, and compared with manual work, product information calibration tasks can be more efficiently, accurately and intelligently completed, so that product production and circulation efficiency is improved, and economic benefit is improved.
In an embodiment, after the image to be identified is identified to obtain the product type corresponding to the image to be identified, if the product type corresponding to the image to be identified is determined not to be the product type in the target order, that is, if the transmission object is determined not to be the product in the target order, the image to be identified is stored, and the image to be identified is sent to the terminal equipment of the related personnel, so that the related personnel can judge whether the image to be identified is the image of the new product type (i.e. the product which does not participate in model training), and receive the new product type feedback information sent by the terminal equipment; if the new product type feedback information is a non-new product type, the image to be identified is not a newly added product image, but an original product type image, and then the image to be identified is used as an untrained sample image, and the on-line update training is performed on the preset identification model to obtain the preset identification model with higher precision. If the new product type feedback information is a new product type, the image to be identified is a newly added product image, the image to be identified is stored as a new sample, and when the new product type corresponds to the new sample and reaches the preset number, a preset identification model is trained according to the new sample with the preset number, so that a new preset identification model is obtained, the subsequent preset identification model can identify the image of the new product type, and the identification product type range and the accuracy of the preset identification model are updated continuously.
In an embodiment, as shown in fig. 3, after step S30, that is, after the image to be identified is identified, the method further specifically includes the following steps:
s40: when the product type corresponding to the image to be identified is determined to be the product type in the target order, recording the transmission object as the product to be processed, and recording the product type of the product to be processed and the product quantity of the product type.
The method comprises the steps of identifying an image to be identified in a control device of packaging equipment to obtain a product type corresponding to the image to be identified, determining whether the product type corresponding to the image to be identified is a product type in a target order, if the product type corresponding to the image to be identified is the product type in the target order, namely determining that a conveying object on a conveying belt is a product in the target order, indicating that no product error exists temporarily, recording the conveying object as a product to be processed, and recording the product type of the product to be processed and the product quantity of the product type in real time.
S50: determining whether the product type of the product to be processed and the product quantity of the product type meet the product requirement of the target order.
After the product type and the product quantity of the product type of the product to be processed are recorded, the packaging machine is controlled to stack the product to be processed (namely, the product type and the product quantity of the product type of the product to be processed are orderly stacked), whether the product type and the product quantity of the product type of the product to be processed meet the product requirement of a target order or not is determined in real time, if the product type and the product quantity of the product type of the product to be processed do not meet the product requirement of the target order, the target order is not completed, and the object to be conveyed is continuously identified, so that packaging is carried out according to the identification result until the order is completed.
Wherein, the product information of the target order not only comprises the product type of each product, but also comprises the required quantity (product quantity) of different product types.
In an embodiment, after recording the product types of the products to be processed and the corresponding quantity thereof, if the quantity of any product type does not reach the required quantity of the corresponding product type in the target order, continuing to identify the conveying object, and if the quantity of any product type is greater than the required quantity of the corresponding product type in the target order in the process of continuing to identify, indicating that the products are wrong, controlling the packaging machine positioned at the tail end of the conveying belt to stop working, and carrying out product error early warning so as to enable related personnel to find problems in time and to conduct investigation. In this embodiment, when the number of any product type is found to be greater than the required number of the corresponding product type in the target order, the packaging machine at the end of the conveyor belt is controlled to stop working, and product error early warning is performed, so that relevant personnel can find problems in time and perform troubleshooting, the possibility of shipping errors caused by continued stacking and packaging when the conveyed object is identified as the product in the target order is avoided, and economic loss caused by packaging and shipping errors is further reduced.
S60: and if the product requirement of the target order is met, controlling the packaging machine to package all the current products to be processed.
After determining the product type and the product quantity of the product type of the product to be processed, whether the product requirement of the target order is met or not, if the product type and the product quantity of the product type of the product to be processed are determined to meet the product requirement of the target order, and the target order is completed, controlling the packaging machine to package all the current products to be processed (namely the piled products to be processed).
For example, the target order includes three types (brands) of cigarettes, namely, a first type, a second type and a third type, wherein the required quantity of the three types is 10, 8 and 5 respectively. After the product types of the products to be processed and the corresponding quantity thereof are recorded, the quantity of the first type cigarette packets is 10, the quantity of the second type cigarette packets is 8, the quantity of the third type cigarette packets is 5, then the packer is controlled to stop stacking, and the stacked products to be processed are packed, namely 10 first type cigarette packets, 8 second type cigarette packets and 5 third type cigarette packets, so that a packing box corresponding to the target order is formed for subsequent delivery. After the product types of the products to be processed and the corresponding quantity thereof are recorded, if the quantity of any type of cigarette packet does not reach the required quantity of the corresponding type of cigarette packet in the target order, the conveying object is continuously identified, and in the process of continuously identifying, if the quantity of any type of cigarette packet is greater than the required quantity of the corresponding product types in the target order, for example, the quantity of the first type of cigarette packet exceeds 10, or the quantity of the second type of cigarette packet exceeds 8, or the quantity of the third type of cigarette packet exceeds 5, namely, the product is indicated to be wrong, the packaging machine positioned at the tail end of the conveying belt is controlled to stop working, and product error early warning is carried out, so that related personnel can find problems in time and conduct investigation.
In this embodiment, after identifying a product in an image to be identified to obtain a product type corresponding to the image to be identified, when determining that the product type corresponding to the image to be identified is a product type in a target order, recording a transmission object as a product to be processed, and recording the product type of the product to be processed and the product number of the product types; determining the product type of the product to be processed and the product quantity of the product type, and whether the product requirement of the target order is met or not; and if the product requirement of the target order is met, controlling the packaging machine to package all the current products to be processed. The method has the advantages that the product types and the corresponding quantity of the products are recorded, whether the product types and the corresponding quantity meet the target order requirements or not is determined, the target order is determined to be completed and packaged when the target order requirements are met, the accuracy of product information checking is further improved, abnormal conditions such as wrong parts, omission and multiple parts in the product packaging process are avoided, the accuracy of order product packaging is provided, and therefore economic losses are reduced.
In an embodiment, after the packaging machine is controlled to package all the current products to be processed and each target order is completed, log information of images to be identified, identification results, early warning information and the like in the process of completing the target order needs to be synchronously stored, so that information tracing and analysis can be performed by subsequent related personnel.
In an embodiment, the packaging device further comprises a detection structure for detecting the running state of the conveyor belt. In step S20, the control line scanning camera performs image acquisition on the conveying object on the conveying belt to obtain an image to be identified, which specifically includes the following steps:
s21: the state of the conveyor belt is detected through the detection structure, and the state of the conveyor belt is obtained.
In this embodiment, the packaging apparatus further comprises a detection structure. The control device of the packaging equipment detects the state of the conveyor belt through the detection structure to obtain the state of the conveyor belt.
S22: when the state of the conveyor belt is in an operating state, the line scanning camera is controlled to be started so as to acquire images of the conveyed objects on the conveyor belt and obtain images to be identified.
After the state of the conveyor belt is detected by the detection structure, and the state of the conveyor belt is obtained, when the state of the conveyor belt is in a running state, the conveyor belt is used for transporting the conveying objects, and the line scanning camera is controlled to be started so as to acquire images of the conveying objects on the conveyor belt and obtain images to be identified.
S23: when the state of the conveyor belt is in a stop state, the control line scanning camera is turned off so as to stop image acquisition of the conveyed objects on the conveyor belt.
When the state of the conveyor belt is in a stop state, the conveyor belt stops transporting the conveying objects, and the control line scanning camera is turned off to stop image acquisition of the conveying objects on the conveyor belt.
In a specific embodiment, as shown in FIG. 1, the detection structure includes a detection wheel 61 and an encoder 62. The detection wheel 61 may be disposed to abut against the conveyor belt 4, directly monitoring the running state of the conveyor belt 4. In other embodiments, the edge of the detection wheel 61 abuts against the roller 41 of the conveyor belt 4, and the roller 41 may be a driving wheel directly driven by a motor or may be a driven wheel for stretching the conveyor belt 4. The encoder 62 can detect the rotation angle/number of turns of the detection wheel 61 while the roller 41 rotates, thereby obtaining the rotation state of the roller 41. When the roller 41 rotates, the conveyor belt 4 is known to be in operation. When the conveyor belt 4 runs, the detection wheel 61 rolls, the encoder 62 sends a pulse signal, after the control device 2 of the packaging equipment receives the pulse signal sent by the encoder 62, the conveyor belt is determined to be in a running state, the line scanning camera 3 is controlled to be started, and the line scanning camera 3 starts to collect images of detection stations on the conveyor belt 4; after the conveyor belt 4 stops, the encoder 62 stops sending the pulse signal, determines that the conveyor belt 4 is in a stopped state, and the line scanning camera 3 stops collecting. Wherein, the packaging equipment still includes fixed bolster 7, and fixed bolster 7 are located the top of conveyer belt 4 to fixed bolster 7 is perpendicular with conveyer belt 4, and detection wheel 61 is rotatable to be installed on fixed bolster 7, makes the pivot axis of detection wheel 61 and the plane parallel that conveyer belt 4 is located, and detection wheel 61 can be parallel with gyro wheel 41 axis promptly. The encoder 62 is attached to the fixed bracket 7, and can detect and know the rotation angle of the detection wheel 61.
In the embodiment, the state of the conveyor belt is detected through the detection structure to obtain the state of the conveyor belt, and when the state of the conveyor belt is an operation state, the line scanning camera is controlled to be started so as to acquire images of the conveyed objects on the conveyor belt to obtain images to be identified; when the state of the conveyor belt is in a stop state, the line scanning camera is controlled to be closed so as to stop image acquisition of the conveying objects on the conveyor belt, and the specific step of acquiring the image of the conveying objects on the conveyor belt through the line scanning camera to obtain the image to be identified is clarified. The running state of the conveyor belt can be judged through the detection mechanism, so that the line scanning camera is only started when the conveyor belt runs, and is closed when the conveyor belt stops running, the line scanning camera does not need to be manually controlled to be started or stopped, the automation is improved, and frequent image data acquisition is reduced.
In an embodiment, after the line scanning camera is controlled to be started, a plurality of light sources of the packaging equipment and the line scanning camera are required to be adjusted, the brightness of the light sources, the definition of the line scanning camera and the visual field of the line scanning camera are adjusted, so that each conveying object passing through the detection station can be completely collected in the visual field of the line scanning camera, and the quality of the collected image to be identified is guaranteed.
In an embodiment, the packaging device further comprises a preset sensor for detecting the presence of a conveying object on the conveyor belt. Before step S22, i.e. before the control line scanning camera is turned on, the method further specifically includes the following steps:
s201: it is determined whether a first signal output by a preset sensor is received.
In this embodiment, the packaging apparatus further includes a preset sensor capable of detecting a conveying object on the conveyor belt, the preset sensor is located before the detection station of the conveyor belt, and when the conveyor belt conveys the conveying object, the conveying object passes through the detection area of the preset sensor before entering the detection station. If the preset sensor detects that the conveying object passes by, a related signal (such as a first signal) is transmitted. For example, the preset sensor may be a photoelectric switch, and a light beam is set in a detection area of the preset sensor, and when the light beam is blocked, the preset sensor determines that a conveying object exists in the detection area, that is, a conveying object exists on the conveying belt.
After the state of the conveyor belt is detected through the detection structure to obtain the state of the conveyor belt, if the state of the conveyor belt is an operation state, in order to ensure that the conveyor belt conveys objects, whether the conveyor belt has the objects or not needs to be determined through a preset sensor. I.e. before the control line scan camera is turned on, it is necessary to determine whether a first signal output by a preset sensor is received. The first signal is used for indicating that a preset sensor detects that a conveying object exists on the conveying belt and approaches to a detection station of the line scanning camera.
S202: and if the first signal output by the preset sensor is received, controlling the line scanning camera to be started.
After determining whether the first signal output by the preset sensor is received, if the first signal output by the preset sensor is received, which indicates that the conveyor belt is working and the conveyor belt is conveying objects, the line scanning camera is controlled to be started.
In this embodiment, before the control line scanning camera is turned on, by determining whether a first signal output by a preset sensor is received, the first signal is used to indicate that the preset sensor detects that a conveying object exists on the conveying belt; and if the first signal output by the preset sensor is received, controlling the line scanning camera to be started. After receiving a first signal of a preset sensor, the line scanning camera is controlled to be started to acquire images, so that the running time of the line scanning camera can be reduced, the data processing amount can be reduced, and the service life can be prolonged.
In an embodiment, after step S22 or step S202, i.e. after the control line scanning camera is turned on, the method further specifically includes the following steps:
s211: it is determined whether a second preset signal output by the preset sensor is received.
After the line scanning camera is controlled to be started, whether a second preset signal output by the preset sensor is received or not is determined, wherein the second signal indicates that the preset sensor does not detect that a transmission object approaches to a detection station of the line scanning camera.
S212: and if the second signal output by the preset sensor is received, the line scanning camera is controlled to be turned off.
After determining whether a second preset signal output by the preset sensor is received or not, if the second signal output by the preset sensor is received, which indicates that no transmission object exists on the conveyor belt or the transmission object is not close to a detection station of the line scanning camera, the line scanning camera is controlled to be closed, and the electric quantity consumption of the line scanning camera is reduced.
After the conveyor belt is started (in an operating state), when the control device of the packaging equipment receives a first signal of a preset sensor, the control device of the packaging equipment sends a high-level signal to the line scanning camera, and the line scanning camera starts to collect images after receiving the high-level signal; after the preset time length is continued, presetting a second signal sent by the sensor, and sending a low-level signal to the line scanning camera by the control device of the packaging equipment, and closing the line scanning camera after receiving the low-level signal to stop image acquisition; and repeatedly acquiring images after receiving the first signal again, and acquiring one image by one conveying object. Wherein the preset time length is determined according to the interval between two adjacent conveying objects, the preset time length is smaller than (interval between two adjacent conveying objects)/the speed of the conveying belt, and the preset time length is longer than (length of the conveying objects)/the speed of the conveying belt. The line scanning camera is controlled to be turned on only when the conveyed object approaches the detection station of the line scanning camera, and the line scanning camera is controlled to be turned off when the conveyed object does not approach the detection station of the line scanning camera, so that the running time of the line scanning camera can be reduced, and the data processing capacity can be reduced.
In other embodiments, if the second signal sent by the preset sensor is received when the preset time period is not reached, the line scanning camera is not controlled to be turned off, but is re-clocked until the re-clocked time period is the preset time period, the line scanning camera is controlled to be turned off, namely a low-level signal is sent to the line scanning camera, and the line scanning camera is turned off after receiving the low-level signal, so that image acquisition is stopped. In this embodiment, the image height that the line scan camera gathered needs to be set large, avoiding missing the acquisition.
In this embodiment, after the control line scanning camera is turned on, it is required to determine whether a second preset signal output by a preset sensor is received; if the second signal output by the preset sensor is received, the line scanning camera is controlled to be turned off, and when the transmitted object is not close to the detection station of the line scanning camera, the line scanning camera is controlled to be turned off, so that the running time of the line scanning camera can be further reduced, and the data processing capacity is reduced.
In an embodiment, as shown in fig. 4, in step S30, product identification is performed on an image to be identified to obtain a product type corresponding to the image to be identified, which specifically includes the following steps:
s31: when the image to be identified is the first image to be identified acquired by the line scanning camera, carrying out product identification on the first image to be identified by adopting a preset identification model to obtain a product type corresponding to the first image to be identified.
After the image to be identified acquired by the line scanning camera is acquired, whether the image to be identified is the first image to be identified acquired by the line scanning camera in the current target order is required to be judged, so that different product identification logics can be executed later according to the judgment result.
When the image to be identified is the first image to be identified acquired by the line scanning camera, the image comparison standard indicating that the current target order is not available is adopted, and the product classification identification is required to be carried out on the first image to be identified by adopting a preset identification model, so that the product type corresponding to the first image to be identified is obtained. The preset recognition model can be a general product classification model; in other embodiments, the preset recognition model may also be a deep learning model obtained by training in advance according to a history to-be-recognized image acquired by the line scanning camera, so as to improve the recognition accuracy of the to-be-recognized image by the model.
The method for identifying the product of the first image to be identified by adopting the preset identification model comprises the following steps of: positioning a transmission object on the first image to be identified and cutting out a target image of the transmission object; inputting the target image into a preset recognition model to carry out product recognition, and obtaining the type of the product output by the preset recognition model; and marking the product type output by the preset identification model as the product type corresponding to the first image to be identified.
S32: when the image to be identified is not the first image to be identified acquired by the line scanning camera, carrying out product identification on the current image to be identified according to the last image to be identified, and obtaining the product type corresponding to the current image to be identified.
When the image to be identified is not the first image to be identified acquired by the line scanning camera, the image comparison standard indicating that the current target order exists can be used for carrying out product identification on the current image to be identified according to the last image to be identified, and the product type corresponding to the current image to be identified is obtained. For example, the image change of the last image to be identified and the current image to be identified can be compared, if the image change is smaller (smaller than a certain threshold value), the two images to be identified are the product images of the same product type, the product type corresponding to the last image to be identified is used as the product type corresponding to the current image to be identified, and the method is simple and convenient.
It will be appreciated that since the same type of product is typically from the same store, the sequence of delivery on the conveyor belt is also highly probable, such as 10 a cigarettes, 6 b cigarettes and 9 c cigarettes, then 10 a cigarettes would be delivered in succession. When the same kind of product is photographed for different times, the images are basically consistent, and the change quantity between the two adjacent images to be identified can be detected by comparing the two adjacent images to be identified (such as similarity comparison), so that the product type of the images to be identified can be rapidly determined, and the product identification detection efficiency is improved.
In this embodiment, when the image to be identified is the first image to be identified acquired by the line scanning camera, a preset identification model is adopted to identify the product of the first image to be identified, so as to obtain the product type corresponding to the first image to be identified; when the image to be identified is not the first image to be identified acquired by the line scanning camera, carrying out product identification on the current image to be identified according to the last image to be identified, and obtaining the product type corresponding to the current image to be identified; the specific step of carrying out product identification on the image to be identified to obtain the product type corresponding to the image to be identified is clarified, when the image to be identified is not the first image to be identified acquired by the line scanning camera, the image comparison standard of the current target order is shown, then the current image to be identified can be subjected to product identification according to the last image to be identified to obtain the product type corresponding to the current image to be identified, and the product identification efficiency is improved on the basis of ensuring the identification accuracy.
In one embodiment, in step S32, product identification is performed on the current image to be identified according to the previous image to be identified, so as to obtain a product type corresponding to the current image to be identified, which specifically includes the following steps:
S321: and carrying out background modeling on the last image to be identified to obtain a background model, and inputting the current image to be identified into the background model to carry out foreground identification to obtain the foreground image area of the current image to be identified.
When the image to be identified is not the first image to be identified acquired by the line scanning camera, performing background modeling on the last image to be identified to obtain a background model, and inputting the current image to be identified into the background model to perform foreground identification to obtain a foreground image of the current image to be identified and the area of the foreground image.
S322: and determining whether the foreground area of the current image to be identified is smaller than a preset area.
After the foreground area of the current image to be identified is obtained, a preset area is obtained, and then whether the foreground area of the current image to be identified is smaller than the preset area is determined.
S323: and if the foreground area of the current image to be identified is larger than or equal to the preset area, taking the product type corresponding to the last image to be identified as the product type corresponding to the current image to be identified.
After determining whether the foreground area of the current image to be identified is smaller than the preset area, if the foreground area of the current image to be identified is smaller than the preset area, the image change between the last image to be identified and the current image to be identified is smaller, the last image to be identified and the current image to be identified are product images of the same line type, the product type corresponding to the last image to be identified is used as the product type corresponding to the current image to be identified, and the method is simple and rapid, does not need to use a preset identification model with large data quantity to carry out product identification, reduces the data processing amount, and reduces the load.
S324: and if the foreground area of the current image to be identified is larger than or equal to the preset area, classifying and identifying the current image to be identified by adopting a preset identification model to obtain the product type corresponding to the current image to be identified.
After determining whether the foreground area of the current image to be identified is smaller than the preset area or not, the foreground area of the current image to be identified is larger than or equal to the preset area, which means that the image change between the last image to be identified and the current image to be identified is larger, and the last image to be identified and the current image to be identified are possibly not product images of the same line type, the preset identification model is adopted to conduct classification identification on the current image to be identified, and the product type corresponding to the current image to be identified is obtained.
In the embodiment, background modeling is performed on the previous image to be identified to obtain a background model, and the current image to be identified is input into the background model to perform foreground identification to obtain the foreground image area of the current image to be identified; determining whether the foreground area of the current image to be identified is smaller than a preset area, and if the foreground area of the current image to be identified is smaller than the preset area, taking the product type corresponding to the last image to be identified as the product type corresponding to the current image to be identified; if the foreground area of the current image to be identified is larger than or equal to the preset area, classifying and identifying the current image to be identified by adopting a preset identification model to obtain a product type corresponding to the current image to be identified, and determining the step of carrying out product identification on the current image to be identified according to the last image to be identified to obtain the product type corresponding to the current image to be identified. In the embodiment, only when the first product of various products in the same target order is subjected to image recognition, model recognition is adopted, and the remaining continuous identical products can quickly determine the product types by using a background modeling mechanism, so that the product recognition accuracy is high and the efficiency is high.
In an embodiment, in step S31 or step S324, product identification is performed on the current image to be identified by using a preset identification model to obtain a product type corresponding to the current image to be identified, which specifically includes the following steps:
s3241: and positioning the transmission object on the current image to be identified and cutting out a target image of the transmission object.
After the image to be identified acquired by the line scanning camera is acquired, the current image to be identified is positioned by the conveying object, and the target image of the conveying object is cut out.
S3242: inputting the target image into a preset recognition model to recognize the product, and obtaining the type of the product output by the preset recognition model.
Inputting the target image into a preset recognition model to carry out product classification recognition so as to recognize the product type (such as a cigarette packet of a certain brand) of the transmission object, and then obtaining the product type output by the preset recognition model.
S3243: and marking the product type output by the preset identification model as the product type corresponding to the current image to be identified.
After the product type output by the preset identification model is obtained, the product type output by the preset identification model is marked as the product type corresponding to the current image to be identified.
For example, the products in the target order include only a brand A tobacco package; after inputting the target image into a preset recognition model for product recognition, if the recognition product output by the preset recognition model is a first brand cigarette packet, marking the product type corresponding to the current image to be recognized as the first brand cigarette packet, and determining that the transmission object is a product in the target order; if the identification product output by the preset identification model is the brand B tobacco bale, marking the product type corresponding to the current image to be identified as the brand B tobacco bale, and determining that the transmission object is not the product in the target order.
In the embodiment, the object to be transmitted is positioned and the target image of the object to be transmitted is cut out by carrying out the object to be transmitted on the current image to be recognized; inputting the target image into a preset recognition model to recognize the product, and acquiring the type of the product output by the preset recognition model; the product type output by the preset recognition model is recorded as the product type corresponding to the current image to be recognized, the specific step of carrying out product recognition on the current image to be recognized by adopting the preset recognition model to obtain the product type corresponding to the current image to be recognized is clarified, before the image recognition is carried out, the image is positioned and cut, the data processing capacity of the model can be reduced, and an accurate basis is provided for subsequent product error judgment.
In one embodiment, in step S3241, the method for positioning the transfer object on the current image to be identified and cutting out the target image of the transfer object specifically includes the following steps:
s32411: converting the current image to be identified into an image matrix, and carrying out normalization processing on the image matrix to obtain an image to be processed.
After the image to be identified acquired by the line scanning camera is acquired, the current image to be identified is required to be converted into an image matrix, and normalization processing is carried out on the image matrix to obtain the image to be processed, so that the standardization of the image is improved, and the subsequent image identification is facilitated.
S32412: inputting the image to be processed into a target detection network, and positioning a transmission object in the image to be processed through the target detection network to obtain an area where the transmission object is located.
After the image matrix is normalized to obtain an image to be processed, the image to be processed is input into a target detection network, object information of the image to be processed is identified through the target detection network, so that a transmission object in the image to be processed is positioned, and an area where the transmission object is located is obtained.
The target detection network may be a yolo, fast rcnn, ssd detection network, etc., the image to be processed is input into the target detection network, each candidate target area of the image to be processed and the corresponding confidence coefficient are output, and an area with the confidence coefficient greater than or equal to a preset value (e.g. 0.8) is selected as the area where the transmission object is located in each candidate target area.
S32413: and cutting out the region where the transmission object is located from the image to be processed to obtain a target image of the transmission object.
And cutting out the region where the transmission object is located from the image to be processed after the region where the transmission object is located is obtained, and obtaining a target image of the transmission object.
In this embodiment, the current image to be identified is converted into the image matrix, the image matrix is normalized to obtain the image to be processed, then the image to be processed is input into the target detection network, the transmission object in the image to be processed is positioned through the target detection network to obtain the region where the transmission object is located, the region where the transmission object is located is cut out in the image to be processed to obtain the target image of the transmission object, the specific process of positioning the transmission object of the image to be identified and cutting out the target image of the transmission object is clarified, a basis is provided for the subsequent image identification, and the calibration treatment is performed before positioning cutting, so that the image processing effect is improved.
It should be understood that the sequence number of each step in the foregoing embodiment does not mean that the execution sequence of each process should be determined by the function and the internal logic, and should not limit the implementation process of the embodiment of the present invention.
In an embodiment, a control device of a packaging apparatus is provided, where the control device of the packaging apparatus corresponds to the control method of the packaging apparatus in the above embodiment one by one. As shown in fig. 5, the control device of the packaging apparatus includes an acquisition module 501, a first control module 502, an identification module 503, and a second control module 504. The functional modules are described in detail as follows:
the obtaining module 501 is configured to obtain product information of a target order after receiving a packaging instruction of the target order, where the product information includes product types of a plurality of products;
the first control module 502 is configured to adjust imaging parameters of a line scanning camera in the packaging device according to standard appearance information of a plurality of products in the target order, and after the adjustment is completed, control the line scanning camera to acquire images of a conveying object on a conveyor belt to obtain an image to be identified;
the identifying module 503 is configured to identify a product of the image to be identified, so as to obtain a product type corresponding to the image to be identified;
And the second control module 504 is configured to control the packaging machine at the end of the conveyor belt to stop working and perform product error pre-warning when it is determined that the product type corresponding to the image to be identified is not the product type in the target order.
Further, after the image to be identified is identified to obtain the product type corresponding to the image to be identified, the second control module 504 is further configured to:
when the product type corresponding to the image to be identified is determined to be the product type in the target order, recording the transmission object as the product to be processed, and recording the product type of the product to be processed and the product quantity of the product type;
determining the product type of the product to be processed and the product quantity of the product type, and whether the product requirement of the target order is met or not;
and if the product requirement of the target order is met, controlling the packaging machine to package all the current products to be processed.
Further, the identification module 503 is specifically configured to:
when the image to be identified is the first image to be identified acquired by the line scanning camera, carrying out product identification on the first image to be identified by adopting a preset identification model to obtain a product type corresponding to the first image to be identified.
When the image to be identified is not the first image to be identified acquired by the line scanning camera, carrying out product identification on the current image to be identified according to the last image to be identified, and obtaining the product type corresponding to the current image to be identified.
Further, the identifying module 503 is specifically further configured to:
performing background modeling on the previous image to be identified to obtain a background model, and inputting the current image to be identified into the background model to perform foreground identification to obtain the foreground image area of the current image to be identified;
determining whether the foreground image area of the current image to be identified is smaller than a preset area;
and if the foreground area of the current image to be identified is smaller than the preset area, taking the product type corresponding to the last image to be identified as the product type corresponding to the current image to be identified.
Further, after determining whether the foreground area of the current image to be identified is smaller than the preset area, the identifying module 503 is specifically further configured to:
and if the foreground area of the current image to be identified is larger than or equal to the preset area, classifying and identifying the current image to be identified by adopting a preset identification model to obtain the product type corresponding to the current image to be identified.
Further, the identifying module 503 is specifically further configured to:
positioning a transmission object on the current image to be identified and cutting out a target image of the transmission object;
inputting the target image into a preset recognition model to recognize the product, and acquiring the type of the product output by the preset recognition model;
And marking the product type output by the preset identification model as the product type corresponding to the current image to be identified.
Further, the identifying module 503 is specifically further configured to:
converting the current image to be identified into an image matrix, and carrying out normalization processing on the image matrix to obtain an image to be processed;
inputting the image to be processed into a target detection network, and positioning a transmission object in the image to be processed through the target detection network to obtain an area where the transmission object is located;
and cutting out the region where the transmission object is located from the image to be processed to obtain a target image of the transmission object.
Further, the first control module 502 is specifically further configured to:
detecting the state of the conveyor belt through a detection structure to obtain the state of the conveyor belt;
when the state of the conveyor belt is an operation state, the line scanning camera is controlled to be started so as to acquire images of the conveyed objects on the conveyor belt and obtain images to be identified;
when the state of the conveyor belt is in a stop state, the control line scanning camera is turned off so as to stop image acquisition of the conveyed objects on the conveyor belt.
Further, before the control line scan camera is turned on, the first control module 502 is specifically further configured to:
determining whether a first signal output by a preset sensor is received or not, wherein the first signal is used for indicating that the preset sensor detects that a conveying object exists on a conveying belt;
And if the first signal output by the preset sensor is received, controlling the line scanning camera to be started.
Further, after the control line scan camera is turned on, the first control module 502 is specifically further configured to:
determining whether a second preset signal output by a preset sensor is received;
and if the second signal output by the preset sensor is received, the line scanning camera is controlled to be turned off.
The specific limitations regarding the control means of the packaging device may be referred to above as limitations regarding the control method of the packaging device, and will not be described in detail herein. The respective modules in the control device of the above-described packaging apparatus may be implemented in whole or in part by software, hardware, and a combination thereof. The above modules may be embedded in hardware or may be independent of a processor in the computer device, or may be stored in software in a memory in the computer device, so that the processor may call and execute operations corresponding to the above modules.
In one embodiment, a computer device is provided, which may be a terminal or a server. The computer device includes a processor, a memory, and a network interface connected by a system bus. Wherein the processor of the computer device is configured to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system and a computer program. The internal memory provides an environment for the operation of the operating system and computer programs in the non-volatile storage media. The network interface of the computer device is for communicating with an external server via a network connection. The computer program, when executed by a processor, implements a method of controlling a packaging device.
In one embodiment, as shown in fig. 6, a computer device is provided, comprising a memory, a processor, and a computer program stored on the memory and executable on the processor, the processor implementing the following steps when executing the computer program:
after receiving a packaging instruction of a target order, acquiring product information of the target order, wherein the product information comprises product types of a plurality of products;
according to standard appearance information of a plurality of products in a target order, imaging parameters of a line scanning camera in packaging equipment are adjusted, and after adjustment is completed, the line scanning camera is controlled to acquire images of conveying objects on a conveying belt to obtain images to be identified;
carrying out product identification on the image to be identified to obtain a product type corresponding to the image to be identified;
and when the product type corresponding to the image to be identified is not the product type in the target order, controlling the packaging machine positioned at the tail end of the conveyor belt to stop working, and carrying out product error early warning.
In one embodiment, a computer readable storage medium is provided having a computer program stored thereon, which when executed by a processor, performs the steps of:
after receiving a packaging instruction of a target order, acquiring product information of the target order, wherein the product information comprises product types of a plurality of products;
According to standard appearance information of a plurality of products in a target order, imaging parameters of a line scanning camera in packaging equipment are adjusted, and after adjustment is completed, the line scanning camera is controlled to acquire images of conveying objects on a conveying belt to obtain images to be identified;
carrying out product identification on the image to be identified to obtain a product type corresponding to the image to be identified;
and when the product type corresponding to the image to be identified is not the product type in the target order, controlling the packaging machine positioned at the tail end of the conveyor belt to stop working, and carrying out product error early warning.
Those skilled in the art will appreciate that implementing all or part of the above described methods may be accomplished by way of a computer program stored on a non-transitory computer readable storage medium, which when executed, may comprise the steps of the embodiments of the methods described above. Any reference to memory, storage, database, or other medium used in embodiments provided herein may include non-volatile and/or volatile memory. The nonvolatile memory can include Read Only Memory (ROM), programmable ROM (PROM), electrically Programmable ROM (EPROM), electrically Erasable Programmable ROM (EEPROM), or flash memory. Volatile memory can include Random Access Memory (RAM) or external cache memory. By way of illustration and not limitation, RAM is available in a variety of forms such as Static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double Data Rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronous Link DRAM (SLDRAM), memory bus direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM), among others.
It will be apparent to those skilled in the art that, for convenience and brevity of description, only the above-described division of the functional units and modules is illustrated, and in practical application, the above-described functional distribution may be performed by different functional units and modules according to needs, i.e. the internal structure of the apparatus is divided into different functional units or modules to perform all or part of the above-described functions.
The above embodiments are only for illustrating the technical solution of the present invention, and not for limiting the same; although the invention has been described in detail with reference to the foregoing embodiments, it will be understood by those of ordinary skill in the art that: the technical scheme described in the foregoing embodiments can be modified or some technical features thereof can be replaced by equivalents; such modifications and substitutions do not depart from the spirit and scope of the technical solutions of the embodiments of the present invention, and are intended to be included in the scope of the present invention.

Claims (9)

1. A control method of a packaging apparatus, comprising:
after receiving a packaging instruction of a target order, acquiring product information of the target order, wherein the product information comprises product types of a plurality of products and product data of each product type;
According to standard appearance information of a plurality of products in the target order, imaging parameters of a line scanning camera in packaging equipment are adjusted, and after adjustment is completed, the line scanning camera is controlled to acquire images of conveying objects on a conveying belt to obtain images to be identified, wherein the standard appearance information comprises appearance image information and text description image information;
carrying out product identification on the image to be identified to obtain a product type corresponding to the image to be identified;
when the product type corresponding to the image to be identified is not the product type in the target order, controlling a packaging machine positioned at the tail end of the conveyor belt to stop working, and carrying out product error early warning;
when the image to be identified is not the first image to be identified acquired by the line scanning camera, product identification is performed on the current image to be identified according to the previous image to be identified, so as to obtain the product type corresponding to the current image to be identified, and the method comprises the following steps:
performing background modeling on the previous image to be identified to obtain a background model, and inputting the current image to be identified into the background model to perform foreground identification to obtain the foreground image area of the current image to be identified;
Determining whether the foreground image area of the current image to be identified is smaller than a preset area;
and if the foreground area of the current image to be identified is smaller than the preset area, taking the product type corresponding to the last image to be identified as the product type corresponding to the current image to be identified.
2. The method for controlling a packaging apparatus according to claim 1, wherein after the product identification is performed on the image to be identified to obtain the product type corresponding to the image to be identified, the method further comprises:
when the product type corresponding to the image to be identified is determined to be the product type in the target order, recording the transmission object as a product to be processed, and recording the product type of the product to be processed and the product quantity of the product type;
determining whether the product type of the product to be processed and the product quantity of the product type meet the product requirement of the target order;
and if the product requirement of the target order is met, controlling the packaging machine to package all the current products to be processed.
3. The method for controlling a packaging apparatus according to claim 1, wherein the performing product identification on the image to be identified to obtain a product type corresponding to the image to be identified includes:
When the image to be identified is the first image to be identified acquired by the line scanning camera, carrying out product identification on the first image to be identified by adopting a preset identification model to obtain a product type corresponding to the first image to be identified.
4. A control method of a packaging apparatus according to claim 3, wherein after said determining whether the foreground area of the current image to be identified is smaller than a preset area, the method further comprises:
and if the foreground area of the current image to be identified is larger than or equal to the preset area, classifying and identifying the current image to be identified by adopting the preset identification model to obtain the product type corresponding to the current image to be identified.
5. The method for controlling a packaging device according to claim 4, wherein the step of performing product identification on the current image to be identified using the preset identification model to obtain a product type corresponding to the current image to be identified comprises:
positioning a transmission object on the current image to be identified and cutting out a target image of the transmission object;
inputting the target image into a preset recognition model to carry out product recognition, and obtaining the product type output by the preset recognition model;
And marking the product type output by the preset identification model as the product type corresponding to the current image to be identified.
6. The method for controlling a packaging apparatus according to any one of claims 1 to 5, wherein the controlling the line scanning camera to acquire an image of a conveying object on a conveyor belt to obtain an image to be recognized includes:
detecting the state of the conveyor belt through a detection structure to obtain the state of the conveyor belt;
when the state of the conveyor belt is an operation state, controlling the line scanning camera to be started so as to acquire images of the objects conveyed on the conveyor belt to obtain the images to be identified;
and when the state of the conveyor belt is in a stop state, controlling the line scanning camera to be closed so as to stop image acquisition of the conveying object on the conveyor belt.
7. A control device of a packaging apparatus, characterized by comprising:
the system comprises an acquisition module, a storage module and a storage module, wherein the acquisition module is used for acquiring product information of a target order after receiving a packaging instruction of the target order, wherein the product information comprises product types of a plurality of products and product data of each product type;
the first control module is used for adjusting imaging parameters of a line scanning camera in the packaging equipment according to standard appearance information of a plurality of products in the target order, and controlling the line scanning camera to acquire images of the conveying objects on the conveying belt to obtain images to be identified after finishing adjustment, wherein the standard appearance information comprises appearance image information and text description image information;
The identification module is used for carrying out product identification on the image to be identified to obtain a product type corresponding to the image to be identified;
the second control module is used for controlling the packaging machine at the tail end of the conveyor belt to stop working and carrying out product error early warning when the product type corresponding to the image to be identified is not the product type in the target order;
when the image to be identified is not the first image to be identified acquired by the line scanning camera, product identification is performed on the current image to be identified according to the previous image to be identified, so as to obtain the product type corresponding to the current image to be identified, and the method comprises the following steps:
performing background modeling on the previous image to be identified to obtain a background model, and inputting the current image to be identified into the background model to perform foreground identification to obtain the foreground image area of the current image to be identified;
determining whether the foreground image area of the current image to be identified is smaller than a preset area;
and if the foreground area of the current image to be identified is smaller than the preset area, taking the product type corresponding to the last image to be identified as the product type corresponding to the current image to be identified.
8. A computer device comprising a memory, a processor and a computer program stored in the memory and executable on the processor, characterized in that the processor, when executing the computer program, realizes the steps of the control method of the packaging device according to any one of claims 1 to 6.
9. A computer-readable storage medium storing a computer program, characterized in that the computer program, when being executed by a processor, implements the steps of the control method of a packaging apparatus according to any one of claims 1 to 6.
CN202211130881.XA 2022-09-16 2022-09-16 Control method and device of packaging equipment, computer equipment and storage medium Active CN115817939B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202211130881.XA CN115817939B (en) 2022-09-16 2022-09-16 Control method and device of packaging equipment, computer equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202211130881.XA CN115817939B (en) 2022-09-16 2022-09-16 Control method and device of packaging equipment, computer equipment and storage medium

Publications (2)

Publication Number Publication Date
CN115817939A CN115817939A (en) 2023-03-21
CN115817939B true CN115817939B (en) 2023-11-17

Family

ID=85523675

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202211130881.XA Active CN115817939B (en) 2022-09-16 2022-09-16 Control method and device of packaging equipment, computer equipment and storage medium

Country Status (1)

Country Link
CN (1) CN115817939B (en)

Citations (11)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104574027A (en) * 2015-01-29 2015-04-29 中国烟草总公司北京市公司物流中心 Tobacco logistics distribution system and method
CN106403819A (en) * 2016-10-12 2017-02-15 颐中(青岛)烟草机械有限公司 Irregular cigarette carton measurement positioning detection apparatus
CN108961302A (en) * 2018-07-16 2018-12-07 Oppo广东移动通信有限公司 Image processing method, device, mobile terminal and computer readable storage medium
CN208248658U (en) * 2018-05-18 2018-12-18 莆田烟草物流有限公司 A kind of special-shaped cigarette sorting line
WO2019039039A1 (en) * 2017-08-22 2019-02-28 株式会社イシダ Apparatus management system
US10248981B1 (en) * 2018-04-10 2019-04-02 Prisma Systems Corporation Platform and acquisition system for generating and maintaining digital product visuals
CN111846465A (en) * 2020-07-22 2020-10-30 中国烟草总公司深圳市公司 Tobacco strip cigarette brand sorting, checking and tracing system and method
CN112111613A (en) * 2020-09-16 2020-12-22 杭州爱科科技股份有限公司 Automatic cutting method, device and system for leather and readable storage medium
CN113781460A (en) * 2021-09-16 2021-12-10 北京远舢智能科技有限公司 Cigarette packet appearance defect online detection method and device, electronic equipment and storage medium
CN114067346A (en) * 2021-11-29 2022-02-18 拉扎斯网络科技(上海)有限公司 Order processing method, device, equipment, storage medium and program product
CN114455255A (en) * 2022-01-27 2022-05-10 山东仁功智能科技有限公司 Abnormal cigarette sorting error detection method based on multi-feature recognition

Patent Citations (11)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104574027A (en) * 2015-01-29 2015-04-29 中国烟草总公司北京市公司物流中心 Tobacco logistics distribution system and method
CN106403819A (en) * 2016-10-12 2017-02-15 颐中(青岛)烟草机械有限公司 Irregular cigarette carton measurement positioning detection apparatus
WO2019039039A1 (en) * 2017-08-22 2019-02-28 株式会社イシダ Apparatus management system
US10248981B1 (en) * 2018-04-10 2019-04-02 Prisma Systems Corporation Platform and acquisition system for generating and maintaining digital product visuals
CN208248658U (en) * 2018-05-18 2018-12-18 莆田烟草物流有限公司 A kind of special-shaped cigarette sorting line
CN108961302A (en) * 2018-07-16 2018-12-07 Oppo广东移动通信有限公司 Image processing method, device, mobile terminal and computer readable storage medium
CN111846465A (en) * 2020-07-22 2020-10-30 中国烟草总公司深圳市公司 Tobacco strip cigarette brand sorting, checking and tracing system and method
CN112111613A (en) * 2020-09-16 2020-12-22 杭州爱科科技股份有限公司 Automatic cutting method, device and system for leather and readable storage medium
CN113781460A (en) * 2021-09-16 2021-12-10 北京远舢智能科技有限公司 Cigarette packet appearance defect online detection method and device, electronic equipment and storage medium
CN114067346A (en) * 2021-11-29 2022-02-18 拉扎斯网络科技(上海)有限公司 Order processing method, device, equipment, storage medium and program product
CN114455255A (en) * 2022-01-27 2022-05-10 山东仁功智能科技有限公司 Abnormal cigarette sorting error detection method based on multi-feature recognition

Also Published As

Publication number Publication date
CN115817939A (en) 2023-03-21

Similar Documents

Publication Publication Date Title
KR20220070313A (en) AA Visual Inspection System and Method
US20210133666A1 (en) Profiling pallets and goods in a warehouse environment
CN109772724B (en) Flexible detection and analysis system for major surface and internal defects of castings
CN112150439B (en) Automatic sorting equipment and sorting method for injection molding parts
CN109693140A (en) A kind of intelligent flexible production line and its working method
CN110927167A (en) Egg detection method and device, electronic equipment and storage medium
CN115817939B (en) Control method and device of packaging equipment, computer equipment and storage medium
US20220284699A1 (en) System and method of object detection using ai deep learning models
CN111806944B (en) Material transportation system that intellectual detection system and intelligence are hierarchical to be stored
CN108465644B (en) Artificial intelligent wheat quality inspection robot and quality inspection method
US20230186454A1 (en) Machine vision system for inspecting quality of various non-woven materials
CN117057630A (en) Intelligent management method and system for production line of food packaging workshop
CN111861324A (en) Big data cloud analysis-based feeding system of material grading system
TWI788175B (en) Leather defect detection system
CN108875845B (en) Medicine sorting device
CN111790639B (en) Poultry egg transportation is with assembly line turnover case letter sorting system
CN112474401A (en) Visual inspection classification method and system for ceramic resistor substrate size
CN111351754A (en) Bottle bottom defect detection system and method
Kumarasinghe et al. A Combination of Deep Learning and Segmentation Algorithms applied to Appearance Inspection Problem
CN117686424B (en) Meat broken bone intelligent detection system and method based on machine vision
Sathe et al. Automated visual quality inspection and sorting
TWI815318B (en) Warehousing automatic sorting system
RU2759174C1 (en) System and method for controlling and adjusting a decorator for containers
US20230245133A1 (en) Systems and methods for assessing quality of retail products
US20240046617A1 (en) Machine Learning-Based Generation of Rule-Based Classification Recipes for Inspection System

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