CN107507204A - A kind of method that detection zone is automatically extracted in cigarette bag defects detection - Google Patents

A kind of method that detection zone is automatically extracted in cigarette bag defects detection Download PDF

Info

Publication number
CN107507204A
CN107507204A CN201710637493.3A CN201710637493A CN107507204A CN 107507204 A CN107507204 A CN 107507204A CN 201710637493 A CN201710637493 A CN 201710637493A CN 107507204 A CN107507204 A CN 107507204A
Authority
CN
China
Prior art keywords
image
product
region
detection
area
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN201710637493.3A
Other languages
Chinese (zh)
Inventor
王岩松
方志斌
都卫东
夏子涛
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Sign New Map (jiangsu) Technology Co Ltd
Focusight Technology Co Ltd
Original Assignee
Sign New Map (jiangsu) 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 Sign New Map (jiangsu) Technology Co Ltd filed Critical Sign New Map (jiangsu) Technology Co Ltd
Priority to CN201710637493.3A priority Critical patent/CN107507204A/en
Publication of CN107507204A publication Critical patent/CN107507204A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/10Segmentation; Edge detection
    • G06T7/12Edge-based segmentation
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/0002Inspection of images, e.g. flaw detection
    • G06T7/0004Industrial image inspection
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/10Segmentation; Edge detection
    • G06T7/136Segmentation; Edge detection involving thresholding
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/10Segmentation; Edge detection
    • G06T7/155Segmentation; Edge detection involving morphological operators

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • Quality & Reliability (AREA)
  • Image Analysis (AREA)

Abstract

The present invention relates to a kind of method that detection zone is automatically extracted in cigarette bag defects detection, including:1) image for needing to detect is classified;All there is coloured image and black white image per a kind of image;2) product profile is extracted respectively to sorted coloured image and black white image;3) step such as classification extraction detection zone;The present invention can extract product profile exactly in modeling process, extract the detection zone of different product;Modelling operability is enormously simplify, has saved the time.

Description

A kind of method that detection zone is automatically extracted in cigarette bag defects detection
Technical field
The present invention relates to printed matter surface detection technique field, detection is automatically extracted in especially a kind of cigarette bag defects detection The method in area.
Background technology
Printed matter detects in the specific implementation, is generally divided into two steps:It is that detection prepares first, i.e., by qualified products IMAQ, standard printed matter image is obtained, template is established to standard picture and learnt;Next to that it is actually detected, it will treat The printed matter image of detection is compared with standard form, so as to determine whether there is defect and defect letter according to comparative result Breath.Traditional template procedure of establishing is:1. gather image;2. detection range delimited, i.e. product profile (product in picture to be detected Complete polygon shape region) minimum enclosed rectangle;3. delimiting the detection zone of each detection object manually and to detection object Configure detection method, the parameter of detection method and positioning core.
But the imaging effect of different station is inconsistent, such as the imaging of dome light source station in printing checking Effects Contrast is preferable, image clearly, is relatively adapted to extraction detection zone;And the imaging effect of reflection source, laser source station Fruit contrast is reported to the leadship after accomplishing a task, image also Relative Fuzzy, so the detection zone extracting mode and ability under different image-forming conditions have difference It is different;Therefore, good Detection results can not be reached by using conventional methods.
The content of the invention
The technical problem to be solved in the present invention is:A kind of method for proposing to automatically extract detection zone in cigarette bag defects detection,.
The technical solution adopted in the present invention is:A kind of method that detection zone is automatically extracted in cigarette bag defects detection, including Following steps,
1) image for needing to detect is classified;All there is coloured image and black white image per a kind of image;
2) product profile is extracted respectively to sorted coloured image and black white image;
3) classification extraction detection zone.
Further, in step 1) of the present invention, image is divided into the class of A, B, C tri-;Carried in described A class images When taking product contour area, the image product region of a passage is at least needed with belt area grayscale jump more than 30; In described B class images when extracting product contour area, the image overwhelming majority product area of a passage is at least needed With belt area grayscale jump more than 30, small part area grayscale is differential to be less than 30 more than 10;Exist in described C class images The gray-level difference that large stretch of color is approximate with belt or all channel images have bulk region is less than 10.
Further say, in step 2) of the present invention, for coloured image, take some different detection product samples Figure graph theory split plot design coarse segmentation goes out product area and background belt region, and the region of each sample is sent into machine learning, instruction Practice result to preserve, follow-up loading training result and parameter xml cut zone every time;For black white image, edge image, connection are extracted Logical profile, extraction maximum close profile is product area profile.
Further say, in step 3) of the present invention, the extraction for coloured image comprises the following steps:
A, input color image RGB information and ROI region;
B, coloured image is decomposed into R, G, B tri- and opens image and smooth respectively to every figure, and seek fringe region respectively;
C, fringe region of R, G, B figure in ROI is calculated respectively;And it is converted into binary edge figure;
D, by gray scale morphology expansion process UNICOM edge, row threshold division of going forward side by side, zonule is screened out;
E, the patch whether contained more than threshold area according to each region is screened;
F, combined region information and final output target detection area.
The beneficial effects of the invention are as follows:Detection zone can be automatically extracted in modeling process using the present invention, greatly simplified Modeling work has saved the time.
Brief description of the drawings
The present invention is further described with reference to the accompanying drawings and examples.
Fig. 1 is A class image schematic diagrames;
Fig. 2 is B class image schematic diagrames;
Fig. 3 is C class image schematic diagrames;
Fig. 4 is coloured image product area outline segmentation flow chart;
Fig. 5 is coloured image product area contours segmentation design sketch;
Fig. 6 is black white image product contours segmentation flow chart
Fig. 7 is black white image product contours segmentation design sketch;
Fig. 8 is Color images detecting area extraction algorithm flow chart;
Fig. 9 is Color images detecting area extraction effect figure.
Embodiment
Presently in connection with accompanying drawing and preferred embodiment, the present invention is further detailed explanation.These accompanying drawings are simplified Schematic diagram, only illustrate the basic structure of the present invention in a schematic way, therefore it only shows the composition relevant with the present invention.
A kind of method that detection zone is automatically extracted in cigarette bag defects detection, is comprised the step of:
1st, image is classified, image is divided into the class image of A, B, C tri-;
As shown in figure 1, in A class images when extracting product contour area, the image product of a passage is at least needed With belt area grayscale jump more than 30, dome station and radium-shine station image are more conform with A class image requests in region.
Coloured image, product contour area, contrast is high, larger discrimination be present with belt background color, and belt is carried on the back The disturbance patch in addition to belt circular hole is not present in scape;Product objective detection zone, contrast is high, product flat site and other several classes Object detection area boundary is clear, adhesion, does not interfere with patch, striped.
Black white image, product contour area contrast is high, big with belt background grey-scale contrast, and belt background is not present Disturbance patch in addition to belt circular hole;Product objective detection zone, contrast is high, and product flat site is examined with other a few class targets Survey area limit is clear, adhesion, does not interfere with patch, striped.
As shown in Fig. 2 in B class images when extracting product contour area, the image at least needing a passage is big absolutely With belt area grayscale jump more than 30, small part area grayscale is differential to be less than 30 more than 10 in portioned product region.
Coloured image, product contour area, subregion contrast is relatively low, the approximate area in part be present with belt background color The less disturbance patch in addition to belt circular hole be present in domain, belt background;Product objective detection zone, subregion contrast compared with Low, there is unintelligible, the adhesion region of less boundary in product flat site, a small amount of interference be present with other a few class object detection areas Patch, striped.
Black white image, product contour area, subregion contrast is relatively low, differs smaller with belt background gray scale, and skin Band background, which exists, less removes circular hole disturbance patch;Product objective detection zone, subregion contrast is relatively low, product flat site Unintelligible, the adhesion region of less boundary be present with other a few class object detection areas, a small amount of disturbance patch, striped be present.
As shown in figure 3, having that large stretch of color is approximate with belt in C class images or all channel images have the ash of bulk region Spend and differential be less than 10.
Coloured image, product contour area, it is very low large area contrast to be present, belt close with belt background color The more disturbance patch in addition to belt circular hole be present in background;Product objective detection zone, it is very low large area contrast to be present, production Product flat site and other a few class object detection area boundary are unintelligible, more adhesion region or disturbance patch striate region be present Domain.
Black white image, product contour area, it is very low large area contrast to be present, and very little is differed with belt background gray scale, The more disturbance patch in addition to belt circular hole be present in belt background;Product objective detection zone, large area contrast be present very Low, product flat site and other a few class object detection area boundary are unintelligible, more adhesion region or disturbance patch be present Fringe area.
2nd, product profile is extracted.
For coloured image, some different detection product sample figure graph theory split plot design coarse segmentations are taken to go out product area and the back of the body Scape belt region, machine learning is sent into the region of each sample, training result preserves, follow-up loading training result and ginseng every time Number xml cut zone.It is as shown in Figure 4 to split flow chart.Segmentation effect is as shown in Figure 5.
For black white image, edge image is extracted, UNICOM's profile, extraction maximum close profile is product area profile.Point It is as shown in Figure 6 to cut flow chart.Segmentation effect is as shown in Figure 7.
3rd, classification extraction detection zone.
It is as shown in Figure 8 for coloured image, flow chart.Input RGB image and ROI region;It is decomposed into R, G, B tri- and opens figure Picture;R, G, B figure are smooth respectively;R, smoothly figure seeks fringe region respectively by G, B;Marginal zone of R, G, B figure in ROI is calculated respectively Domain;Triple channel fringe region or computing;Be converted to binary edge figure;Gray scale morphology expansion process UNICOM edge;Threshold segmentation; Screen out zonule;Whether contained according to the boundary rectangle form, region compactness, region in each region more than threshold area Patch screened;Merge output target detection area.
The embodiment of the simply present invention described in description above, various illustrations are not to the reality of the present invention Matter Composition of contents limits, and person of an ordinary skill in the technical field can be to described in the past specific after specification has been read Embodiment is made an amendment or deformed, without departing from the spirit and scope of the invention.

Claims (4)

1. the method for detection zone is automatically extracted in a kind of cigarette bag defects detection, it is characterised in that:Comprise the following steps,
1) image for needing to detect is classified;All there is coloured image and black white image per a kind of image;
2) product profile is extracted respectively to sorted coloured image and black white image;
3) classification extraction detection zone.
2. the method for detection zone is automatically extracted in a kind of cigarette bag defects detection as claimed in claim 1, it is characterised in that:It is described Step 1) in, image is divided into the class of A, B, C tri-;In described A class images when extracting product contour area, one is at least needed The image product region of individual passage is with belt area grayscale jump more than 30;In extraction product profile in described B class images During region, the image overwhelming majority product area of a passage is at least needed with belt area grayscale jump more than 30, it is few Subregion gray-level difference is more than 10 less than 30;Have that large stretch of color is approximate with belt or all passages in described C class images The gray-level difference that image has bulk region is less than 10.
3. the method for detection zone is automatically extracted in a kind of cigarette bag defects detection as claimed in claim 1, it is characterised in that:It is described Step 2) in, for coloured image, take some different detection product sample figure graph theory split plot design coarse segmentations to go out product area With background belt region, machine learning is sent into the region of each sample, training result preserves, follow-up loading training result every time With parameter xml cut zone;For black white image, edge image is extracted, UNICOM's profile, extraction maximum close profile is product zone Domain profile.
4. the method for detection zone is automatically extracted in a kind of cigarette bag defects detection as claimed in claim 1, it is characterised in that:It is described Step 3) in, the extraction for coloured image comprises the following steps:
A, input color image RGB information and ROI region;
B, coloured image is decomposed into R, G, B tri- and opens image and smooth respectively to every figure, and seek fringe region respectively;
C, fringe region of R, G, B figure in ROI is calculated respectively;And it is converted into binary edge figure;
D, by gray scale morphology expansion process UNICOM edge, row threshold division of going forward side by side, zonule is screened out;
E, the patch whether contained more than threshold area according to each region is screened;
F, combined region information and final output target detection area.
CN201710637493.3A 2017-07-31 2017-07-31 A kind of method that detection zone is automatically extracted in cigarette bag defects detection Pending CN107507204A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201710637493.3A CN107507204A (en) 2017-07-31 2017-07-31 A kind of method that detection zone is automatically extracted in cigarette bag defects detection

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201710637493.3A CN107507204A (en) 2017-07-31 2017-07-31 A kind of method that detection zone is automatically extracted in cigarette bag defects detection

Publications (1)

Publication Number Publication Date
CN107507204A true CN107507204A (en) 2017-12-22

Family

ID=60690240

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201710637493.3A Pending CN107507204A (en) 2017-07-31 2017-07-31 A kind of method that detection zone is automatically extracted in cigarette bag defects detection

Country Status (1)

Country Link
CN (1) CN107507204A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110632094A (en) * 2019-07-24 2019-12-31 北京中科慧眼科技有限公司 Pattern quality detection method, device and system based on point-by-point comparison analysis

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103900499A (en) * 2014-02-27 2014-07-02 中国烟草总公司北京市公司 Cigarette packing warning zone area measuring method based on computer visual technology
CN106650553A (en) * 2015-10-30 2017-05-10 比亚迪股份有限公司 License plate recognition method and system
EP2748796B1 (en) * 2011-08-22 2018-05-30 Focke & Co. (GmbH & Co.) Method and apparatus for testing rod-shaped tobacco products

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP2748796B1 (en) * 2011-08-22 2018-05-30 Focke & Co. (GmbH & Co.) Method and apparatus for testing rod-shaped tobacco products
CN103900499A (en) * 2014-02-27 2014-07-02 中国烟草总公司北京市公司 Cigarette packing warning zone area measuring method based on computer visual technology
CN106650553A (en) * 2015-10-30 2017-05-10 比亚迪股份有限公司 License plate recognition method and system

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110632094A (en) * 2019-07-24 2019-12-31 北京中科慧眼科技有限公司 Pattern quality detection method, device and system based on point-by-point comparison analysis
CN110632094B (en) * 2019-07-24 2022-04-19 北京中科慧眼科技有限公司 Pattern quality detection method, device and system based on point-by-point comparison analysis

Similar Documents

Publication Publication Date Title
CN110274908B (en) Defect inspection apparatus, defect inspection method, and computer-readable recording medium
US10565479B1 (en) Identifying and excluding blurred areas of images of stained tissue to improve cancer scoring
JP6869490B2 (en) Defect inspection equipment, defect inspection methods, and their programs
Aleixos et al. Multispectral inspection of citrus in real-time using machine vision and digital signal processors
CN115082683A (en) Injection molding defect detection method based on image processing
Hatanaka et al. Automated microaneurysm detection method based on double-ring filter and feature analysis in retinal fundus images
CN109377485A (en) A kind of instant noodles packaging defect machine vision detection method
CN111507932B (en) High-specificity diabetic retinopathy characteristic detection method and storage device
CN109087286A (en) A kind of detection method and application based on Computer Image Processing and pattern-recognition
CN113109348B (en) Paddle image transfer printing defect identification method based on machine vision
CN106780465A (en) Retinal images aneurysms automatic detection and recognition methods based on gradient vector analysis
Xiao et al. Retinal hemorrhage detection by rule-based and machine learning approach
Elbalaoui et al. Segmentation and detection of diabetic retinopathy exudates
CN117541588B (en) Printing defect detection method for paper product
CN113256624A (en) Continuous casting round billet defect detection method and device, electronic equipment and readable storage medium
CN112132821B (en) Cotter pin loss detection method based on image processing
CN107507204A (en) A kind of method that detection zone is automatically extracted in cigarette bag defects detection
Fan et al. Automated blood vessel segmentation in fundus image based on integral channel features and random forests
Sulaiman et al. Automatic grading system for oil palm fruit ripeness
MUSTAFA et al. Automatic blood vessel detection on retinal image using hybrid combination techniques
Gao et al. Full-automatic optic disc boundary extraction based on active contour model with multiple energies
CN115393589A (en) Universal DCS process flow chart identification conversion method, system and medium
Saad et al. Automated vision based defect detection using gray level co-occurrence matrix for beverage manufacturing industry
Menon et al. Digital grading and sorting of fruits
Remeseiro et al. Tear film maps based on the lipid interference patterns

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
CB02 Change of applicant information
CB02 Change of applicant information

Address after: 213161 No. 258-6 Jinhua Road, West Taihu Lake, Wujin District, Changzhou City, Jiangsu Province

Applicant after: Zhengtu Xinshi (Jiangsu) Science and Technology Co., Ltd.

Address before: 213161 No. 258-6 Jinhua Road, West Taihu Lake, Wujin District, Changzhou City, Jiangsu Province

Applicant before: Sign new map (Jiangsu) Technology Co. Ltd.

RJ01 Rejection of invention patent application after publication
RJ01 Rejection of invention patent application after publication

Application publication date: 20171222