CN112024448B - Method for detecting cigarette mouth building foreign matter based on machine vision - Google Patents

Method for detecting cigarette mouth building foreign matter based on machine vision Download PDF

Info

Publication number
CN112024448B
CN112024448B CN202010887061.XA CN202010887061A CN112024448B CN 112024448 B CN112024448 B CN 112024448B CN 202010887061 A CN202010887061 A CN 202010887061A CN 112024448 B CN112024448 B CN 112024448B
Authority
CN
China
Prior art keywords
cigarette
image
pixel point
end pixel
foreign matter
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
CN202010887061.XA
Other languages
Chinese (zh)
Other versions
CN112024448A (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.)
China Tobacco Zhejiang Industrial Co Ltd
Original Assignee
China Tobacco Zhejiang Industrial 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 China Tobacco Zhejiang Industrial Co Ltd filed Critical China Tobacco Zhejiang Industrial Co Ltd
Priority to CN202010887061.XA priority Critical patent/CN112024448B/en
Publication of CN112024448A publication Critical patent/CN112024448A/en
Application granted granted Critical
Publication of CN112024448B publication Critical patent/CN112024448B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • BPERFORMING OPERATIONS; TRANSPORTING
    • B07SEPARATING SOLIDS FROM SOLIDS; SORTING
    • B07CPOSTAL SORTING; SORTING INDIVIDUAL ARTICLES, OR BULK MATERIAL FIT TO BE SORTED PIECE-MEAL, e.g. BY PICKING
    • B07C5/00Sorting according to a characteristic or feature of the articles or material being sorted, e.g. by control effected by devices which detect or measure such characteristic or feature; Sorting by manually actuated devices, e.g. switches
    • B07C5/34Sorting according to other particular properties
    • BPERFORMING OPERATIONS; TRANSPORTING
    • B07SEPARATING SOLIDS FROM SOLIDS; SORTING
    • B07CPOSTAL SORTING; SORTING INDIVIDUAL ARTICLES, OR BULK MATERIAL FIT TO BE SORTED PIECE-MEAL, e.g. BY PICKING
    • B07C5/00Sorting according to a characteristic or feature of the articles or material being sorted, e.g. by control effected by devices which detect or measure such characteristic or feature; Sorting by manually actuated devices, e.g. switches
    • B07C5/02Measures preceding sorting, e.g. arranging articles in a stream orientating
    • BPERFORMING OPERATIONS; TRANSPORTING
    • B07SEPARATING SOLIDS FROM SOLIDS; SORTING
    • B07CPOSTAL SORTING; SORTING INDIVIDUAL ARTICLES, OR BULK MATERIAL FIT TO BE SORTED PIECE-MEAL, e.g. BY PICKING
    • B07C5/00Sorting according to a characteristic or feature of the articles or material being sorted, e.g. by control effected by devices which detect or measure such characteristic or feature; Sorting by manually actuated devices, e.g. switches
    • B07C5/36Sorting apparatus characterised by the means used for distribution
    • B07C5/361Processing or control devices therefor, e.g. escort memory
    • BPERFORMING OPERATIONS; TRANSPORTING
    • B07SEPARATING SOLIDS FROM SOLIDS; SORTING
    • B07CPOSTAL SORTING; SORTING INDIVIDUAL ARTICLES, OR BULK MATERIAL FIT TO BE SORTED PIECE-MEAL, e.g. BY PICKING
    • B07C5/00Sorting according to a characteristic or feature of the articles or material being sorted, e.g. by control effected by devices which detect or measure such characteristic or feature; Sorting by manually actuated devices, e.g. switches
    • B07C5/36Sorting apparatus characterised by the means used for distribution
    • B07C5/363Sorting apparatus characterised by the means used for distribution by means of air
    • GPHYSICS
    • G01MEASURING; TESTING
    • G01NINVESTIGATING OR ANALYSING MATERIALS BY DETERMINING THEIR CHEMICAL OR PHYSICAL PROPERTIES
    • G01N21/00Investigating or analysing materials by the use of optical means, i.e. using sub-millimetre waves, infrared, visible or ultraviolet light
    • G01N21/84Systems specially adapted for particular applications
    • G01N21/88Investigating the presence of flaws or contamination
    • G01N21/94Investigating contamination, e.g. dust
    • GPHYSICS
    • G01MEASURING; TESTING
    • G01NINVESTIGATING OR ANALYSING MATERIALS BY DETERMINING THEIR CHEMICAL OR PHYSICAL PROPERTIES
    • G01N21/00Investigating or analysing materials by the use of optical means, i.e. using sub-millimetre waves, infrared, visible or ultraviolet light
    • G01N21/84Systems specially adapted for particular applications
    • G01N21/88Investigating the presence of flaws or contamination
    • G01N21/94Investigating contamination, e.g. dust
    • G01N2021/945Liquid or solid deposits of macroscopic size on surfaces, e.g. drops, films, or clustered contaminants

Abstract

The invention belongs to the field of cigarette quality detection methods, and discloses a method for detecting a cigarette mouth building foreign matter based on machine vision.A transposition module is adopted to enable the outer surfaces of all angles of a cigarette to be presented to an image collector, and the cigarette is dynamically transmitted; qualified cigarettes pass through the transposition module smoothly, unqualified cigarettes are ejected out for rejection by positive pressure generated by the adsorption column, and the method is particularly suitable for large-scale detection of a large number of cigarettes; the image processor collects images of cigarettes to be detected on the transposition module, the foreign matter and the cigarette opening are synchronously detected in the adopted mode, if the position of the foreign matter is coincident with the position of the cigarette opening, the foreign matter is removed from the cigarette opening by using the airflow ejector, whether the foreign matter still exists is identified for the second time, the technical scheme can accurately identify the defective or unqualified cigarettes, and unnecessary consumption is avoided.

Description

Method for detecting cigarette mouth building foreign matter based on machine vision
Technical Field
The invention belongs to the field of cigarette quality detection methods, and relates to a method for detecting cigarette mouth building foreign matters based on machine vision.
Background
In the production process of the current cigarette making machine, tobacco shreds enter a rolling connection part from a tobacco shred supply part, and are rolled into a long rod shape in a gluing and pasting mode after being pressed into cigarette paper through a mechanical structure, wherein the overlapping and pasting part of the cigarette paper is a lap joint. In the rolling and forming process, due to the influence of various factors such as sealing and the like, at the time of glue supply and adhesion, partial tobacco powder is adhered to the lap to form defective cigarettes, the defects are also divided into two types, one type is that the tobacco powder is simply adhered to the surface of the lap, the possibility of falling off is also existed in subsequent processing, the other type is that one part of the tobacco powder is embedded into the inner side of the cigarette paper and is exposed out of the lap, the defect enables the tobacco powder not to fall off from the lap, and only the cigarettes can be removed; in addition, when the tobacco powder is adsorbed at a non-overlapping position on the surface of a cigarette, the tobacco powder can naturally fall off in the subsequent processes of conveying, packaging and the like, so that the defective cigarette is not in a common meaning and does not need to be specially treated. If the cigarettes with the lapping defects and the cigarettes with the non-defects cannot be accurately distinguished, the cigarettes with the non-defects can be mistakenly rejected and unnecessary consumption is caused, or the cigarettes with the lapping defects flow into the consumption market to influence the reputation of products. Therefore, in order to improve the product quality, it is necessary to detect such defects.
Disclosure of Invention
Aiming at the defects of the prior art, the invention provides a method for detecting the foreign matters on the cigarette lap based on machine vision, which can quickly and automatically detect a large number of cigarettes and eliminate the cigarettes with foreign matters on the lap, and adopts the following technical scheme in order to realize the aim:
a method for detecting cigarette lap foreign bodies based on machine vision comprises the following steps:
the method comprises the following steps: the transposition module dynamically adjusts the angle of the acquired image of the cigarette; the cigarette to be detected is adsorbed on the outer edges of a plurality of adsorption columns which are distributed circumferentially by negative pressure, all the adsorption columns rotate around the common circumferential center of the adsorption columns, all the adsorption columns also rotate around respective shafts, gaps among the adsorption columns are smaller than the diameter of the cross section of the cigarette, and the adsorption effect of each adsorption column is independently controlled by a controller;
step two: the image collector is arranged close to the transposition module, and the transposition module enables the outer surfaces of all angles of the cigarette to be presented to the image collector;
step three: the image processor performs primary processing on the outer surface image of the cigarette acquired by the image acquirer, the primary processing comprises image denoising processing, image filtering processing, image binarization processing and image difference processing, morphological processing is performed on the image after the primary processing by adopting a corrosion and expansion method in sequence, the image of each frame of outer surface curved surface of the cigarette is converted and spliced into a plane image through curve field restoration, image communication and region marking, and the plane image continuously extends along with the dynamic acquisition of the acquirer and the dynamic processing of the image processor;
step four: the image recognizer recognizes the cigarette lap position and the foreign matter position according to the generated plane image; searching a first end pixel point and a second end pixel point with the same gray value in the plane image, equally dividing the straight line distance between the first end pixel point and the second end pixel point to obtain at least one node, and judging whether the image gray values of all the nodes are the same as the gray values of the first end pixel point or the second end pixel point;
if the gray values of the images of all the nodes are the same as the gray values of the first end pixel points or the second end pixel points; taking a first end pixel point as a starting point to make a first ray towards a second end pixel point, stopping the first ray at a third end pixel point with a different gray value from the first end pixel point, taking the third end pixel point as the starting point to make a second ray towards the first end pixel point, stopping the second ray at a fourth end pixel point with a different gray value from the first end pixel point, measuring a quasi-junction line distance between the third end pixel point and the fourth end pixel point, and judging the third end pixel point and the fourth end pixel point as two end points of cigarette junction if the quasi-junction line distance is within an actual junction line interval;
if the quasi lap line distance is not in the actual lap line interval, newly selecting a first-end pixel point and a second-end pixel point;
if the gray value of the image with the node is different from the gray value of the first end pixel point or the second end pixel point, one of the first end pixel point or the second end pixel point is abandoned, and the other pixel point is selected from the plane image to replace the abandoned pixel point;
the image recognizer recognizes the position of the foreign matter while recognizing the cigarette lap, if the foreign matter is overlapped with the cigarette lap position, the image processor transmits a first instruction to the controller, so that the controller opens an airflow injector for cleaning the foreign matter at the cigarette lap position, the foreign matter on the cigarette lap is recognized again, and if the foreign matter on the cigarette lap disappears, the image acquisition and the image processing of the qualified cigarette are cancelled; if the foreign matter on the cigarette lap still exists, the image processor transmits a second instruction to the controller, so that the adsorption column generates positive pressure on the cigarette.
Furthermore, every time one node is taken, gray level connected domain extraction is carried out on the node in the neighborhood range, and the extracted gray level connected domain area is compared with the preset gray level connected domain area.
Further, the image filtering process adopts a total variation method to perform filtering process.
Further, the actual lap line interval is an axial length value of 64 +/-1 mm.
Furthermore, the image collector is matched with an independent light source, the light source is controlled by the controller, and the irradiation angle of the light source is dynamically adjusted according to the position change of the cigarette.
Further, the following processing is performed on the image gray value: f (x, y) ═ max { F (x, y), K } where F (x, y) is the gray scale value of the pixel, K is the gray scale value range, and F (x, y) is the gray scale value of the processed pixel; automatically determining a threshold, selecting a maximum inter-class variance method to automatically determine the threshold, carrying out binarization processing on the image, calculating an optimal threshold Th by using the maximum inter-class variance method, and dividing the image into a cigarette part and a background part according to the following formula: in the formula, G (x, y) represents a pixel value of the coordinate point (x, y), G (x, y) is 0 as a background, and G (x, y) is 255 as a cigarette.
Further, in the first step: the cigarette on one adsorption column rotates around the central shaft of the adsorption column, when the cigarette rotates to a position close to the adjacent adsorption column, the controller controls the adsorption column to close the adsorption effect on the cigarette, and the adjacent adsorption column opens the adsorption effect on the cigarette.
Further, the angle that the image collector gathered and the angle that the air current sprayer jetted gas carry out the coincidence setting each other, and the image collector in case detects the cigarette that the place ahead was taken a mouthful position and the position coincidence that the foreign matter was located, and the air current sprayer sprays immediately, just sprays to corresponding cigarette on.
The invention has the following beneficial effects:
the invention discloses a method for detecting a cigarette lap foreign matter based on machine vision, wherein the adopted transposition module enables the outer surfaces of all angles of a cigarette to be presented to an image collector, and the cigarette is dynamically transmitted; qualified cigarettes pass through the transposition module smoothly, unqualified cigarettes are ejected out for rejection by positive pressure generated by the adsorption column, and the method is particularly suitable for large-scale detection of a large number of cigarettes; the image processor collects images of cigarettes to be detected and to be positioned on the transposition module, the foreign matter at the searched position is judged while the position of the cigarette opening is searched by adopting a method for synchronously detecting the foreign matter and the cigarette opening, if the position of the foreign matter is superposed with the position of the cigarette opening, the foreign matter is removed from the cigarette opening by using the airflow injector, and whether the foreign matter still exists or not is identified for the second time.
Drawings
FIG. 1 is a schematic view of a cigarette landing position and shape;
FIG. 2 is a schematic diagram of a method for detecting foreign matters on cigarette seams based on machine vision;
FIG. 3 is a schematic diagram of the principle of detecting the cigarette lap position;
fig. 4 is a schematic diagram of the working principle of the image collector and the transposition module.
The attached drawings are as follows: 1-adsorption tank, 2-autorotation shaft, 3-cigarette, 4-revolution shaft, 5-image collector and 6-adsorption column.
Detailed Description
Reference will now be made in detail to embodiments of the present invention, examples of which are illustrated in the accompanying drawings, wherein like or similar reference numerals refer to the same or similar elements or elements having the same or similar function throughout. The embodiments described below with reference to the drawings are illustrative and intended to be illustrative of the invention and are not to be construed as limiting the invention.
In the description of the present invention, it is to be understood that the terms "length", "width", "upper", "lower", "front", "rear", "left", "right", "vertical", "horizontal", "top", "bottom", "inner", "outer", and the like, indicate orientations or positional relationships based on the orientations or positional relationships illustrated in the drawings, and are used merely for convenience in describing the present invention and for simplicity in description, and do not indicate or imply that the devices or elements referred to must have a particular orientation, be constructed in a particular orientation, and be operated, and thus, are not to be construed as limiting the present invention.
Furthermore, the terms "first", "second" and "first" are used for descriptive purposes only and are not to be construed as indicating or implying relative importance or implicitly indicating the number of technical features indicated. Thus, a feature defined as "first" or "second" may explicitly or implicitly include one or more of that feature. In the description of the present invention, "a plurality" means two or more unless specifically defined otherwise.
In the embodiments of the present invention, unless otherwise explicitly specified or limited, the terms "mounted," "connected," "fixed," and the like are to be construed broadly, e.g., as being fixedly connected, detachably connected, or integrated; can be mechanically or electrically connected; either directly or indirectly through intervening media, either internally or in any other relationship. The specific meanings of the above terms in the present invention can be understood by those skilled in the art according to specific situations.
Referring to fig. 1 to 4, a method for detecting a cigarette mouth building foreign matter based on machine vision includes:
the method comprises the following steps: the transposition module dynamically adjusts the angle of the acquired image of the cigarette; the cigarette to be detected is adsorbed on the outer edges of a plurality of adsorption columns 6 which are distributed circumferentially by negative pressure, all the adsorption columns 6 rotate around the common circumferential center of the adsorption columns, all the adsorption columns 6 also rotate around respective shafts, the gaps among the adsorption columns 6 are smaller than the diameter of the cross section of the cigarette, and the adsorption effect of each adsorption column 6 is independently controlled by a controller; the conversion module has the functions of: each adsorption column 6 has revolution around the common circumference center and rotation around the axis, and the cigarettes adsorbed on the adsorption columns 6 show all angles of the cigarettes under the combination of the revolution and the rotation, but when the positions where the adsorption columns 6 and the cigarettes adsorb each other are just cigarette openings, the cigarette openings cannot be exposed for the collection of the image collector 5 no matter how the adsorption columns 6 revolve and rotate; in order to solve this problem, the cigarette on one adsorption column 6 provided in this embodiment rotates around the central axis of the adsorption column 6, and when the cigarette rotates to a position close to the adjacent adsorption column 6, the controller controls the adsorption column 6 to close the adsorption on the cigarette, and the adjacent adsorption column 6 to open the adsorption on the cigarette, as a result: the adjacent adsorption columns 6 are connected with the transferred cigarettes, and the combination part of the adjacent adsorption columns 6 and the cigarettes is different from the combination part of the upper adsorption column 6 for adsorbing the cigarettes; thus, the cigarette holder can ensure that the cigarette holder is not blocked due to the adsorption and fixation with the adsorption column 6; in this embodiment, the distance between two adjacent adsorption columns 6 should not be too large, so that the reliability of the transfer of the cigarettes between the adsorption columns 6 can be ensured; in this embodiment, the adsorption column 6 is provided with at least one adsorption tank 1, the adsorption tanks 1 are used for fixing cigarettes, and the airflow adsorption in each adsorption tank 1 is independent; the adsorption columns 6 rotate around the rotation shaft 2, and each adsorption column 6 rotates around the revolution shaft 4; for example, the a direction is the revolution direction of the adsorption column 6, and the B direction is the rotation direction of the adsorption column 6;
step two: arranging the image collector 5 close to the transposition module, wherein the transposition module enables the outer surfaces of all angles of the cigarette to be presented to the image collector 5; preferably, two image collectors 5 are arranged beside each adsorption column 6, and appearance images of the cigarettes are collected from two sides of the cigarettes respectively;
step three: the image processor performs primary processing on the cigarette outer surface image acquired by the image acquirer 5, wherein the primary processing comprises image denoising processing, image filtering processing, image binarization processing and image difference processing, morphological processing is performed on the image subjected to the primary processing by adopting a swelling and corrosion method in sequence, the image of each frame of outer surface curved surface of the cigarette is converted and spliced into a plane image through curved field restoration, image communication and region marking, and the plane image continuously extends along with dynamic acquisition of the acquirer and dynamic processing of the image processor; the process of expansion followed by erosion is called closed-loop operation. It has the functions of filling fine cavities in the object, connecting the adjacent object and smoothing the boundary; the outer surface of the cigarette is a cylindrical surface, the cylindrical surface is a curved surface, the acquired image also has a curved surface effect, and in order to ensure that the image recognition effect is better, each acquired frame image is subjected to primary processing and reduced into a continuously extended plane image;
step four: the image recognizer recognizes the cigarette lap position and the foreign matter position according to the generated plane image; searching a first end pixel point and a second end pixel point with the same gray value in the plane image, equally dividing the straight line distance between the first end pixel point and the second end pixel point to obtain at least one node, and judging whether the image gray values of all the nodes are the same as the gray values of the first end pixel point or the second end pixel point; in the embodiment, the gray values are not the same in numerical value strictly, so that the judgment of the cigarette lap position cannot be realized in order to avoid the situation that the cigarette lap line is broken or blocked by foreign matters, and the gray values are the same, namely the gray values of two pixel points are in a preset range close to each other;
if the gray values of the images of all the nodes are the same as the gray values of the first end pixel points or the second end pixel points; taking a first end pixel point as a starting point to make a first ray towards a second end pixel point, stopping the first ray at a third end pixel point with a different gray value from the first end pixel point, taking the third end pixel point as the starting point to make a second ray towards the first end pixel point, stopping the second ray at a fourth end pixel point with a different gray value from the first end pixel point, measuring a quasi-junction line distance between the third end pixel point and the fourth end pixel point, and judging the third end pixel point and the fourth end pixel point as two end points of cigarette junction if the quasi-junction line distance is within an actual junction line interval; the quasi-lap line distance is actually used for predicting whether the collected third-end pixel point and the fourth-end pixel point fall on the cigarette lap position, because the cigarette lap position has a clear outline, and the length of the outline is basically fixed on each cigarette;
if the distance of the quasi lap line is not in the actual lap line interval, reselecting a first-end pixel point and a second-end pixel point;
if the gray value of the image with the node is different from the gray value of the first end pixel point or the second end pixel point, one of the first end pixel point or the second end pixel point is abandoned, and the other pixel point is selected from the plane image to replace the abandoned pixel point; the abandoning of the first end pixel point and the second end pixel point is random, if the selected first end pixel point and the selected second end pixel point do not fall on the cigarette lap position, accurate pixel points can be finally selected after the judgment and the abandoning are continuously repeated;
the image recognizer recognizes the position of the foreign matter while recognizing the cigarette lap, if the foreign matter is overlapped with the cigarette lap position, the image processor transmits a first instruction to the controller, so that the controller opens an airflow injector for cleaning the foreign matter at the cigarette lap position, the foreign matter on the cigarette lap is recognized again, and if the foreign matter on the cigarette lap disappears, the image acquisition and the image processing of the qualified cigarette are cancelled; if the foreign matters on the cigarette lap still exist, the image processor transmits a second instruction to the controller, so that the adsorption column 6 generates positive pressure on the cigarettes. In the embodiment, the airflow ejector is arranged for cleaning foreign matters which can be naturally separated from the cigarette opening, if the foreign matters exist at the cigarette opening position after the processing of the airflow ejector, the foreign matters are proved to be incapable of naturally falling off, the cigarette is removed, if the foreign matters are not detected, the cigarette can be judged to be a qualified product, and the image acquisition and the image processing of the qualified cigarette are cancelled for saving energy and the memory of the image recognizer; in an embodiment, the angle acquired by the image acquisition device 5 and the angle of the air ejected by the air ejector are overlapped with each other, for example, the two are integrated together, once a certain image acquisition device 2 detects that the cigarette lap position in front is overlapped with the position of the foreign matter, the air ejector immediately ejects the air to the corresponding cigarette, and the two cooperate with each other to work cooperatively; if the foreign matters on the cigarette lap still exist, the image processor transmits a second instruction to the controller, so that positive pressure appears in the corresponding adsorption tank 1, and unqualified cigarettes are ejected.
In the embodiment, each node is taken to extract the gray level connected domain of the node in the neighborhood range, and the extracted gray level connected domain area is compared with the preset gray level connected domain area. The method mainly comprises the steps of judging whether foreign matters exist in the field of the node or not, if the foreign matters exist, and finally obtaining the conclusion that the node is also located at the cigarette lap position, concluding that the foreign matters exist in the cigarette lap, and if the foreign matters exist in the field of the node and the node is not located at the cigarette lap position, obtaining the conclusion that the foreign matters exist at the non-lap position of the cigarette.
In an embodiment, in order to obtain a better picture processing effect, the image filtering processing adopts a total variation method to perform filtering processing.
Referring to fig. 1, in the embodiment, the actual lap line interval has an axial length value of 64 ± 1mm, and the actual lap line interval can be adjusted according to the specification of the cigarette.
In the embodiment, the image collector 5 is provided with an independent light source, the light source is controlled by a controller, and the irradiation angle of the light source is dynamically adjusted according to the position change of the cigarette. Preferably, the image collector 5 is a CCD camera.
In the embodiment, the following processing is performed on the image gray value: f (x, y) ═ max { F (x, y), K } where F (x, y) is the gray scale value of the pixel, K is the gray scale value range, and F (x, y) is the gray scale value of the processed pixel; automatically determining a threshold, selecting a maximum inter-class variance method to automatically determine the threshold, carrying out binarization processing on the image, calculating an optimal threshold Th by using the maximum inter-class variance method, and dividing the image into a cigarette part and a background part according to the following formula: in the formula, G (x, y) represents a pixel value of the coordinate point (x, y), G (x, y) is 0 as a background, and G (x, y) is 255 as a cigarette.
The above-described embodiments are only one of the preferred embodiments of the present invention, and general changes and substitutions by those skilled in the art within the technical scope of the present invention are included in the protection scope of the present invention.

Claims (8)

1. A method for detecting cigarette mouth building foreign bodies based on machine vision is characterized by comprising the following steps:
the method comprises the following steps: the transposition module dynamically adjusts the angle of the acquired image of the cigarette; the cigarette to be detected is adsorbed on the outer edges of a plurality of adsorption columns which are distributed circumferentially by negative pressure, all the adsorption columns rotate around the common circumferential center of the adsorption columns, all the adsorption columns also rotate around respective shafts, gaps among the adsorption columns are smaller than the diameter of the cross section of the cigarette, and the adsorption effect of each adsorption column is independently controlled by a controller;
step two: the image collector is arranged close to the transposition module, and the transposition module enables the outer surfaces of all angles of the cigarette to be presented to the image collector;
step three: the image processor performs primary processing on the outer surface image of the cigarette acquired by the image acquirer, the primary processing comprises image denoising processing, image filtering processing, image binarization processing and image difference processing, morphological processing is performed on the image after the primary processing by adopting a corrosion and expansion method in sequence, the image of each frame of outer surface curved surface of the cigarette is converted and spliced into a plane image through curve field restoration, image communication and region marking, and the plane image continuously extends along with the dynamic acquisition of the acquirer and the dynamic processing of the image processor;
step four: the image recognizer recognizes the cigarette lap position and the foreign matter position according to the generated plane image; searching a first end pixel point and a second end pixel point with the same gray value in the plane image, equally dividing the straight line distance between the first end pixel point and the second end pixel point to obtain at least one node, and judging whether the image gray values of all the nodes are the same as the gray values of the first end pixel point or the second end pixel point;
if the gray values of the images of all the nodes are the same as the gray values of the first end pixel points or the second end pixel points; taking a first end pixel point as a starting point to make a first ray towards a second end pixel point, stopping the first ray at a third end pixel point with a different gray value from the first end pixel point, taking the third end pixel point as the starting point to make a second ray towards the first end pixel point, stopping the second ray at a fourth end pixel point with a different gray value from the first end pixel point, measuring a quasi-junction line distance between the third end pixel point and the fourth end pixel point, and judging the third end pixel point and the fourth end pixel point as two end points of cigarette junction if the quasi-junction line distance is within an actual junction line interval;
if the quasi lap line distance is not in the actual lap line interval, newly selecting a first-end pixel point and a second-end pixel point;
if the gray value of the image with the node is different from the gray value of the first end pixel point or the second end pixel point, one of the first end pixel point or the second end pixel point is abandoned, and the other pixel point is selected from the plane image to replace the abandoned pixel point;
the image recognizer recognizes the position of the foreign matter while recognizing the cigarette lap, if the foreign matter is overlapped with the cigarette lap position, the image processor transmits a first instruction to the controller, so that the controller opens an airflow injector for cleaning the foreign matter at the cigarette lap position, the foreign matter on the cigarette lap is recognized again, and if the foreign matter on the cigarette lap disappears, the image acquisition and the image processing of the qualified cigarette are cancelled; if the foreign matter on the cigarette lap still exists, the image processor transmits a second instruction to the controller, so that the adsorption column generates positive pressure on the cigarette.
2. The machine vision-based cigarette lap foreign matter detection method according to claim 1, characterized in that every time a node is taken, a gray level connected domain extraction is performed on the node in a neighborhood range, and the extracted gray level connected domain area is compared with a preset gray level connected domain area.
3. The machine vision-based cigarette holder foreign matter detection method according to claim 1, wherein the image filtering process adopts a total variation method to perform filtering process.
4. The machine vision-based cigarette lap foreign matter detection method according to claim 1, wherein the actual lap line interval is an axial length value of 64 ± 1 mm.
5. The machine vision-based detection method for the cigarette lap foreign matter according to claim 1, wherein the image collector is matched with an independent light source, the light source is controlled by a controller, and the irradiation angle of the light source is dynamically adjusted according to the position change of the cigarette.
6. The machine vision-based cigarette lap foreign matter detection method according to claim 1, characterized in that the following processing is performed on image gray values: f (x, y) ═ max { F (x, y), K } where F (x, y) is the gray scale value of the pixel, K is the gray scale value range, and F (x, y) is the gray scale value of the processed pixel; automatically determining a threshold, selecting a maximum inter-class variance method to automatically determine the threshold, carrying out binarization processing on the image, calculating an optimal threshold Th by using the maximum inter-class variance method, and dividing the image into a cigarette part and a background part: g (x, y) represents a pixel value of the coordinate point (x, y), and G (x, y) is 0 as a background and G (x, y) is 255 as a cigarette.
7. The machine vision-based cigarette holder foreign matter detection method according to claim 1, characterized in that in the first step: the cigarette on one adsorption column rotates around the central shaft of the adsorption column, when the cigarette rotates to a position close to the adjacent adsorption column, the controller controls the adsorption column to close the adsorption effect on the cigarette, and the adjacent adsorption column opens the adsorption effect on the cigarette.
8. The machine vision-based cigarette landing foreign matter detection method according to claim 1, wherein the angle acquired by the image acquirer and the angle of the gas sprayed by the gas sprayer are overlapped with each other, and once the image acquirer detects that the position of the cigarette landing in front is overlapped with the position of the foreign matter, the gas sprayer immediately sprays the foreign matter to the corresponding cigarette.
CN202010887061.XA 2020-08-28 2020-08-28 Method for detecting cigarette mouth building foreign matter based on machine vision Active CN112024448B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010887061.XA CN112024448B (en) 2020-08-28 2020-08-28 Method for detecting cigarette mouth building foreign matter based on machine vision

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010887061.XA CN112024448B (en) 2020-08-28 2020-08-28 Method for detecting cigarette mouth building foreign matter based on machine vision

Publications (2)

Publication Number Publication Date
CN112024448A CN112024448A (en) 2020-12-04
CN112024448B true CN112024448B (en) 2021-11-12

Family

ID=73586226

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010887061.XA Active CN112024448B (en) 2020-08-28 2020-08-28 Method for detecting cigarette mouth building foreign matter based on machine vision

Country Status (1)

Country Link
CN (1) CN112024448B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117115082B (en) * 2023-07-12 2024-04-05 钛玛科(北京)工业科技有限公司 Method and equipment for detecting overlap quality of tire

Family Cites Families (13)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
ES2120481T3 (en) * 1992-05-15 1998-11-01 Philip Morris Prod APPARATUS AND METHOD FOR OPTICALLY INSPECTING CYLINDRICAL SURFACES.
IT1299859B1 (en) * 1998-02-23 2000-04-04 Gd Spa ELECTRO-OPTICAL UNIT FOR DETECTION OF THE ENTIRE SIDE SURFACE OF SUBSTANTIALLY CYLINDRICAL SHAPE ARTICLES.
DE19921721A1 (en) * 1999-05-12 2000-11-16 Focke & Co Method and device for checking cigarette heads
JP4025291B2 (en) * 2001-09-25 2007-12-19 日本たばこ産業株式会社 Device for inspecting the appearance of rod-shaped articles
CN103910077B (en) * 2014-03-17 2015-10-07 东南大学 Full-automatic cigarette rejects collating unit and method of work thereof
CN103995007B (en) * 2014-05-06 2017-03-22 湖南润普科技发展有限公司 Total cigarette appearance quality detection device
CN104432498B (en) * 2014-10-23 2017-04-05 阚晖 Cigarette making machine apparent visual detection means based on machine vision
CN104957766A (en) * 2015-06-01 2015-10-07 龙岩烟草工业有限责任公司 Cigarette appearance inspection method, device and system and rolling and connecting machine
CN107080285B (en) * 2017-04-21 2018-08-21 广东省韶关烟草机械配件厂有限公司 cigarette recycling and processing device
CN109827969B (en) * 2019-01-28 2024-02-20 重庆中烟工业有限责任公司 Negative pressure adsorption rotary type cigarette hole size detection device
CN210038861U (en) * 2019-08-23 2020-02-07 上海傲仁高新科技有限公司 Online detection device for laser drilling of cigarette filter tip
CN111000286A (en) * 2019-12-18 2020-04-14 阚晖 Anti-interference cigarette appearance quality online detection device and method
CN111202263A (en) * 2020-02-12 2020-05-29 河南中烟工业有限责任公司 Double-length cigarette appearance detection device and method

Also Published As

Publication number Publication date
CN112024448A (en) 2020-12-04

Similar Documents

Publication Publication Date Title
CN207730680U (en) A kind of quick-fried pearl cigarette filter quality detection device
CN112024448B (en) Method for detecting cigarette mouth building foreign matter based on machine vision
CN102636490A (en) Method for detecting surface defects of dustproof cover of bearing based on machine vision
CN105548212A (en) System and method for online automatically detecting defects on glass surface of touch screen
CN106469804B (en) A kind of electrodes of lithium-ion batteries brush dust and defects detection integrated device
CN103364400A (en) Multistation intelligent syncretic bottled beer online detection device
CN104438945A (en) Lock cylinder cover cap riveting device and riveting method thereof
CN106475327B (en) A kind of color selector dust suction converting interface, dust exhaust apparatus and color selector
CN103051872A (en) Method for detecting conveyor belt deviation based on image edge extraction
CN104266615A (en) Visual detection device and method for pipeline inner wall
CN212349500U (en) Ceramic flaw recognition device
CN106670637A (en) Automatic grinding and compensating system for robot welding electrode cap
CN109975318A (en) A kind of plastic bottle open defect detection method and equipment
CN105728339A (en) Visual automatic detecting system for ceramic cartridge
CN113791080A (en) Automobile parts processing is with high anti-part flaw detection device of hi-lite
CN113843178A (en) Bottle inspection machine and glass bottle defect detection method
CN105093584B (en) Color film repair machine and color film restorative procedure
CN111000286A (en) Anti-interference cigarette appearance quality online detection device and method
CN207964668U (en) A kind of Flexible tube printing Surface Quality Inspection System
CN102539445A (en) Paper cup detector
CN106442555A (en) Imaging device and imaging method for detecting surface defects of cylindrical workpieces
CN104316531A (en) Imaging detector for jacket of cup or barrel container
CN101125332A (en) Cup-bowl online high-speed detecting machine
CN209513642U (en) A kind of big mouth plastic bottle defect Automatic Visual Inspection device
CN206213260U (en) Cigarette making machine appearance delection device

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