JP2019067373A - Feature image generation device, inspection equipment, feature image generation method and feature image generation program - Google Patents

Feature image generation device, inspection equipment, feature image generation method and feature image generation program Download PDF

Info

Publication number
JP2019067373A
JP2019067373A JP2018158436A JP2018158436A JP2019067373A JP 2019067373 A JP2019067373 A JP 2019067373A JP 2018158436 A JP2018158436 A JP 2018158436A JP 2018158436 A JP2018158436 A JP 2018158436A JP 2019067373 A JP2019067373 A JP 2019067373A
Authority
JP
Japan
Prior art keywords
image
binarized
feature
template
edge
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
JP2018158436A
Other languages
Japanese (ja)
Other versions
JP6665903B2 (en
Inventor
秀人 松井
Hideto Matsui
秀人 松井
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.)
Dai Nippon Printing Co Ltd
Original Assignee
Dai Nippon Printing 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 Dai Nippon Printing Co Ltd filed Critical Dai Nippon Printing Co Ltd
Publication of JP2019067373A publication Critical patent/JP2019067373A/en
Application granted granted Critical
Publication of JP6665903B2 publication Critical patent/JP6665903B2/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Accessory Devices And Overall Control Thereof (AREA)
  • Investigating Materials By The Use Of Optical Means Adapted For Particular Applications (AREA)
  • Image Processing (AREA)
  • Image Analysis (AREA)

Abstract

To provide a feature image generation device capable of appropriately generating, from a reference image, a feature image to be used in matching for alignment of the reference image and a comparison image of high resolution.SOLUTION: When a difference satisfies a prescribed condition, the difference between a first cutout image obtained from an image binarizing, at a first gradation, an edge image in which an edge is extracted from a reference image, and a second cutout image obtained from an image binarizing the edge image at a second gradation, a feature image is obtained by cutting out a same location from an image binarizing the edge image at a gradation between the first gradation and the second gradation.SELECTED DRAWING: Figure 3

Description

本発明は、基準となる対象物を撮像した基準画像と、比較対象物を撮像した比較画像を比較する際の両画像の位置合わせを行うための技術に関する。   The present invention relates to a technique for aligning a reference image obtained by imaging an object serving as a reference with a comparison image obtained by imaging a comparison object.

従来、印刷機で印刷された印刷物について、色調の良否、汚れの有無、抜けの有無等の検査を印刷機上で自動的に行う方法として、カメラで印刷物を撮像して得た被検査画像と、一定の基準を満たした基準画像を比較する方法がある。   Conventionally, an inspection image obtained by capturing an image of a printed matter with a camera is used as a method of automatically performing an inspection such as goodness of color tone, presence or absence of stain, presence or absence of omission, etc. of printed matter printed by a printing machine. There is a method of comparing reference images that satisfy certain criteria.

このような検査方法では、基準画像と被検査画像を比較する際に、正確な位置合わせを行う必要がある。例えば、輪転印刷ではロール紙などの連続シートに印刷が行われるが、印刷後の連続シートを搬送中に撮像して被検査画像を得る場合、連続シートは搬送方向に収縮したり幅方向に蛇行したりするため比較検査前に位置合わせを行うが必要となる。また、枚葉印刷では枚葉紙などのカットシートに印刷が行われるが、カットシートを印刷後に撮像して被検査画像を得る場合、カットシートは縦方向、横方向、回転方向に不規則にズレるため位置合わせが必要となる。   In such an inspection method, when the reference image and the inspection image are compared, accurate alignment needs to be performed. For example, in rotary printing, printing is performed on a continuous sheet such as roll paper, but when imaging the continuous sheet after printing to obtain an image to be inspected, the continuous sheet shrinks in the conveying direction or meanders in the width direction It is necessary to perform alignment before comparison inspection in order to In sheet-fed printing, printing is performed on a cut sheet such as a sheet, but if the cut sheet is imaged after printing to obtain an image to be inspected, the cut sheet is irregular in the vertical direction, horizontal direction, and rotational direction. Alignment is necessary because of misalignment.

特許文献1−3には、基準画像と比較できるように被検査画像の位置合わせ(位置補正という場合がある)を行う技術が開示されている。これらは、被検査画像及び基準画像を複数のブロックに細分化し、ブロック毎に画像のズレ量を算出し、全体的な位置補正を行う技術である。また、ブロック毎に特徴的な図柄(特徴部)を含む画像を切り出して特徴画像を生成して、被検査画像及び基準画像とでマッチングを行い特徴部がどれだけズレているかによって位置補正を行うことも知られている。   Patent Literatures 1 to 3 disclose a technique for performing alignment (sometimes referred to as position correction) of an image to be inspected so that it can be compared with a reference image. These are techniques for subdividing the inspection image and the reference image into a plurality of blocks, calculating the amount of image shift for each block, and performing overall position correction. In addition, an image including a distinctive pattern (feature portion) is cut out for each block to generate a feature image, matching is performed between the inspection image and the reference image, and position correction is performed depending on how much the feature portion is shifted. It is also known.

特許第3916596号公報Patent No. 3916596 特許第4163199号公報Patent No. 4163199 特許第5061543号公報Patent No. 5061543 gazette

一方で、カメラ等の技術進歩により高解像度の画像を用いて、より精密に印刷物検査が行えるようになってきている。しかしながら、特許文献1−3の技術は低解像度の画像に適した技術であり高解像度の画像については充分に位置補正ができない場合がある。また、特徴部を用いて位置補正する方法についても、高解像度画像ではブロック内で、位置補正に適当な特徴部を選択することができないという問題がある。これは、高解像度化により、細分化されたブロックにおいて図柄が相対的に大きくなって抽象的になることや、ブロックサイズが小さくなって図柄のないブロックが多数存在してしまうことが原因として考えられる。   On the other hand, with technological advances such as cameras, it has become possible to more precisely inspect printed matter using high resolution images. However, the techniques of Patent Documents 1 to 3 are techniques suitable for low-resolution images, and there are cases where sufficient position correction can not be performed for high-resolution images. In addition, also in the method of position correction using a feature, there is a problem that a high resolution image can not select a feature suitable for position correction in a block. This is thought to be caused by the fact that the design becomes relatively large and abstract in the subdivided blocks due to the increase in resolution, and that there are a large number of blocks with no design because the block size becomes small. Be

本発明は、このような問題に鑑みて為されたもので、その課題の一例は、高解像度の基準画像と比較画像の位置合わせを行うためのマッチングに用いる特徴画像を基準画像から適切に生成することができる特徴画像生成装置等を提供することを課題とする。   The present invention has been made in view of such problems, and one example of the problem is appropriately generating from a reference image a feature image used for matching for aligning a high-resolution reference image and a comparison image. It is an object of the present invention to provide a feature image generating apparatus and the like that can be performed.

上記課題を解決するために、請求項1に記載の発明は、基準画像からエッジを抽出したエッジ画像を生成するエッジ抽出部と、前記エッジ画像を第1の階調で二値化した第1二値化画像と、前記エッジ画像を前記第1の階調よりも低い第2の階調で二値化した第2二値化画像と、前記エッジ画像を前記第1の階調と前記第2の階調の間の第3の階調で二値化した第3二値化画像と、を生成する二値化部と、前記第1二値化画像における水平の直線と垂直の直線の交点座標を取得する交点取得部と、前記第1二値化画像及び前記第2二値化画像から前記交点座標を含む画像を切り出して、それぞれ第1切り出し画像及び第2切り出し画像を生成する切り出し画像生成部と、前記第1切り出し画像と第2切り出し画像の差分画素数が所定の条件を満たす場合に、前記第3二値化画像から前記交点座標を含む画像を切り出した特徴画像を生成する特徴画像生成部と、を備えることを特徴とする。   In order to solve the above problems, the invention according to claim 1 is an edge extraction unit for generating an edge image in which an edge is extracted from a reference image, and a first obtained by binarizing the edge image with a first tone. A binarized image, a second binarized image obtained by binarizing the edge image with a second tone lower than the first tone, the edge image with the first tone and the second tone A binarization unit for generating a third binarized image binarized at a third gradation between two gradations, and a horizontal straight line and a vertical straight line in the first binarized image An intersection acquiring unit for acquiring intersection coordinates, and an image including the intersection coordinates cut out from the first binarized image and the second binarized image, and cut out to generate a first cutout image and a second cutout image respectively The image generation unit, and the difference pixel number of the first cut-out image and the second cut-out image is a predetermined condition If the plus, characterized in that it and a feature image generation unit for generating feature images cut out an image including the intersection coordinates from said third binary image.

請求項2に記載の発明は、請求項1に記載の特徴画像生成装置であって、前記第1二値化画像から水平の直線を抽出した第1水平画像と、前記第1二値化画像から垂直の直線を抽出した第1垂直画像を合成し、第1合成画像を生成する第1合成部と、前記第2二値化画像から水平の直線を抽出した第2水平画像と、前記第2二値化画像から垂直の直線を抽出した第2垂直画像を合成し、第2合成画像を生成する第2合成部と、を更に備え、前記交点取得部は、前記第1二値化画像から生成された前記第1合成画像に基づいて、前記交点座標を取得し、前記切り出し画像生成部は、前記第1二値化画像から生成された前記第1合成画像及び前記第2二値化画像から生成された前記第2合成画像から、それぞれ前記第1切り出し画像及び前記第2切り出し画像を生成することを特徴とする。   The invention according to claim 2 is the feature image generating device according to claim 1, wherein a first horizontal image obtained by extracting a horizontal straight line from the first binarized image, and the first binarized image A first combining unit that combines a first vertical image in which vertical straight lines are extracted from the second to generate a first combined image; a second horizontal image in which a horizontal straight line is extracted from the second binarized image; And a second combining unit that combines a second vertical image obtained by extracting a vertical straight line from the binary image and generates a second combined image, and the intersection acquiring unit further includes the first binarized image. The intersection coordinates are acquired based on the first composite image generated from the image, and the cut-out image generation unit is configured to generate the first composite image and the second binarization generated from the first binarized image. The first cutout image and the second are respectively generated from the second composite image generated from the image. And generating an image Eject and.

請求項3に記載の発明は、請求項2に記載の特徴画像生成装置であって、前記第1合成部は、前記第1二値化画像から水平の直線を抽出し、水平方向に拡大させた前記第1水平画像と、前記第1二値化画像から垂直の直線を抽出し、垂直方向に拡大させた前記第1垂直画像を合成し、前記第1合成画像を生成し、前記第2合成部は、前記第2二値化画像から水平の直線を抽出し、水平方向に拡大させた前記第2水平画像と、前記第2二値化画像から垂直の直線を抽出し、垂直方向に拡大させた前記第2垂直画像を合成し、前記第2合成画像を生成することを特徴とする。   The invention according to claim 3 is the feature image generating apparatus according to claim 2, wherein the first combining unit extracts a horizontal straight line from the first binarized image and enlarges it in the horizontal direction. A vertical straight line is extracted from the first horizontal image and the first binarized image, and the first vertical image enlarged in the vertical direction is synthesized to generate the first synthesized image; The synthesizing unit extracts a horizontal straight line from the second binarized image, extracts a vertical straight line from the second horizontal image expanded in the horizontal direction, and the second binarized image, and extends the vertical straight direction. The enlarged second vertical image may be combined to generate the second combined image.

請求項4に記載の発明は、請求項1乃至3の何れか一項に記載の特徴画像生成装置であって、前記基準画像を複数のブロックに分割する分割部を更に備え、前記交点取得部は、前記ブロック毎に交点座標を取得し、前記切り出し画像生成部は、前記ブロック毎に前記第1切り出し画像及び第2切り出し画像を生成し、前記特徴画像生成部は、前記ブロック毎に前記特徴画像を生成することを特徴とする。   The invention according to claim 4 is the feature image generating device according to any one of claims 1 to 3, further comprising: a dividing unit for dividing the reference image into a plurality of blocks, the intersection acquiring unit The intersection point coordinate is acquired for each of the blocks, the cutout image generation unit generates the first cutout image and the second cutout image for each of the blocks, and the feature image generation unit generates the feature for each of the blocks. Generating an image.

請求項5に記載の発明は、請求項4に記載の特徴画像生成装置であって、前記基準画像が連続シートを長手方向に沿って搬送している際に当該連続シートの一部を撮影した画像である場合に、一の前記ブロックに対して一つの特徴画像を生成することを特徴とする。   The invention according to claim 5 is the feature image generating apparatus according to claim 4, wherein the reference image is used to capture a part of the continuous sheet while the continuous sheet is being conveyed along the longitudinal direction. In the case of an image, one feature image is generated for one of the blocks.

請求項6に記載の発明は、請求項4に記載の特徴画像生成装置であって、前記基準画像が連続シートを枚葉単位に切断したカットシートを撮影した画像である場合に、一の前記ブロックに対して二つの特徴画像を生成することを特徴とする。   The invention according to claim 6 is the feature image generating apparatus according to claim 4, wherein the reference image is an image obtained by photographing a cut sheet obtained by cutting a continuous sheet into single sheet units. Two feature images are generated for the block.

請求項7に記載の発明は、請求項1乃至6の何れか一項に記載の特徴画像生成装置であって、前記第3二値化画像における前記交点座標を基準とする検証領域内を、前記特徴画像を移動させつつ第3二値化画像と比較し、前記交点座標以外で一致する場合に、当該特徴画像を不適切な特徴画像と判定する判定部を更に備えることを特徴とする。   The invention according to claim 7 is the feature image generating device according to any one of claims 1 to 6, wherein a verification region based on the intersection coordinates in the third binarized image is referred to as: The feature image is compared with the third binarized image while being moved, and the feature image is further provided with a determination unit that determines the feature image as an inappropriate feature image when they match other than the intersection coordinates.

請求項8に記載の発明は、請求項1乃至7の何れか一項に記載の特徴画像生成装置が作成した前記特徴画像を用いて被検査画像の位置補正を行い、前記基準画像と当該被検査画像の比較検査を行う検査装置であって、前記被検査画像における前記特徴画像に対応する座標を特定し、前記交点取得部が取得した前記交点座標との差であるズレ量を算出するズレ量算出部と、前記ズレ量に基づいて前記被検査画像の位置補正を行う位置補正部と、前記位置補正が行われた前記被検査画像と前記基準画像とを比較する比較部と、を備えることを特徴とする。   The invention according to claim 8 performs position correction of the inspection image using the feature image created by the feature image generation device according to any one of claims 1 to 7, and the reference image and the subject An inspection apparatus which performs comparison inspection of inspection images, and specifies a coordinate corresponding to the feature image in the inspection image, and calculates a deviation amount that is a difference from the intersection coordinates acquired by the intersection acquisition unit An amount calculation unit, a position correction unit that performs position correction of the inspection image based on the displacement amount, and a comparison unit that compares the inspection image that has been subjected to the position correction with the reference image It is characterized by

請求項9に記載の発明は、基準画像からエッジを抽出したエッジ画像を生成するエッジ抽出工程と、前記エッジ画像を第1の階調で二値化した第1二値化画像と、前記エッジ画像を前記第1の階調よりも低い第2の階調で二値化した第2二値化画像と、前記エッジ画像を前記第1の階調と前記第2の階調の間の第3の階調で二値化した第3二値化画像と、を生成する二値化工程と、前記第1二値化画像における水平の直線と垂直の直線の交点座標を取得する交点取得工程と、前記第1二値化画像及び前記第2二値化画像から前記交点座標を含む画像を切り出して、それぞれ第1切り出し画像及び第2切り出し画像を生成する切り出し画像生成工程と、前記第1切り出し画像と第2切り出し画像の差分画素数が所定の条件を満たす場合に、前記第3二値化画像から前記交点座標を含む画像を切り出した特徴画像を生成する特徴画像生成工程と、を含むことを特徴とする。   The invention according to claim 9 is an edge extraction step of generating an edge image in which an edge is extracted from a reference image, a first binarized image obtained by binarizing the edge image with a first gradation, and the edge A second binarized image obtained by binarizing the image with a second tone lower than the first tone, and a second between the first tone and the second tone, the second binarized image being binarized at a second tone lower than the first tone. A binarization step of generating a third binarized image binarized with 3 gradations, and an intersection point acquisition step of acquiring intersection coordinates of a horizontal straight line and a vertical straight line in the first binarized image Cutting out an image including the intersection coordinates from the first binarized image and the second binarized image, and generating a first cutout image and a second cutout image, respectively; When the difference pixel number between the cutout image and the second cutout image satisfies a predetermined condition, And wherein the image generating step from the 3 binary image to generate a feature image cut out an image including the intersection coordinates, characterized in that it comprises a.

請求項10に記載の発明は、コンピュータを、基準画像からエッジを抽出したエッジ画像を生成するエッジ抽出部、前記エッジ画像を第1の階調で二値化した第1二値化画像と、前記エッジ画像を前記第1の階調よりも低い第2の階調で二値化した第2二値化画像と、前記エッジ画像を前記第1の階調と前記第2の階調の間の第3の階調で二値化した第3二値化画像と、を生成する二値化部、前記第1二値化画像における水平の直線と垂直の直線の交点座標を取得する交点取得部、前記第1二値化画像及び前記第2二値化画像から前記交点座標を含む画像を切り出して、それぞれ第1切り出し画像及び第2切り出し画像を生成する切り出し画像生成部、前記第1切り出し画像と第2切り出し画像の差分画素数が所定の条件を満たす場合に、前記第3二値化画像から前記交点座標を含む画像を切り出した特徴画像を生成する特徴画像生成部、として機能させることを特徴とする。   According to a tenth aspect of the present invention, there is provided an edge extraction unit that generates an edge image in which an edge is extracted from a reference image, a first binarized image in which the edge image is binarized with a first gradation. A second binarized image obtained by binarizing the edge image with a second tone lower than the first tone, and the edge image between the first tone and the second tone A binarization unit for generating a third binarized image binarized with the third gradation of the second gradation, acquiring an intersection point for acquiring an intersection coordinate of a horizontal straight line and a vertical straight line in the first binarized image A cutout image generation unit that cuts out an image including the intersection coordinates from the first binarized image and the second binarized image, and generates a first cutout image and a second cutout image, and the first cutout If the difference pixel number between the image and the second cutout image satisfies a predetermined condition, Feature image generation unit for generating feature images cut out an image including the intersection coordinates from the third binarized image, characterized in that to function as a.

本発明によれば、基準画像からエッジを抽出したエッジ画像を、第1の階調で二値化した画像から得られた第1切り出し画像と、エッジ画像を第2の階調で二値化した画像から得られた第2切り出し画像の差が所定の条件を満たしている場合に、エッジ画像を第3の階調で二値化した画像から同じ位置を切り出して特徴画像とすることから、基準画像と比較する画像のエッジ画像における階調が第1の階調と第2の階調の間であれば、基準画像と比較画像の位置合わせを行うことができる。すなわち、高解像度の基準画像と比較画像の位置合わせを行うためのマッチングに用いる特徴画像を基準画像から適切に生成することができる。   According to the present invention, an edge image obtained by extracting an edge from a reference image is binarized with a first cut-out image obtained from an image binarized with a first tone and an edge image with a second tone. Since the same position is cut out from the image obtained by binarizing the edge image with the third gradation when the difference between the second cut-out images obtained from the shot images satisfies the predetermined condition, and the feature image is obtained. If the gradation in the edge image of the image to be compared with the reference image is between the first gradation and the second gradation, the reference image and the comparison image can be aligned. That is, a feature image used for matching for aligning the high-resolution reference image and the comparison image can be appropriately generated from the reference image.

第1実施形態における印刷機Sの一例を示す図である。It is a figure showing an example of printing machine S in a 1st embodiment. 第1実施形態における検査装置Tの構成の一例を示すブロック図である。It is a block diagram showing an example of composition of inspection device T in a 1st embodiment. 第1実施形態における検査装置Tによる連続シート用テンプレート画像作成処理の一例を示すフローチャートである。It is a flowchart which shows an example of the template image creation process for continuous sheets by the test | inspection apparatus T in 1st Embodiment. 第1実施形態における基準画像200を複数ブロックに分割した一例を示す図である。It is a figure which shows an example which divided | segmented the reference | standard image 200 in 1st Embodiment into several blocks. R成分画像のA画像の例である。It is an example of A image of R component image. G成分画像のA画像の例である。It is an example of A image of G component image. B成分画像のA画像の例である。It is an example of A image of B component image. (A)はR成分画像のB画像の例であり、(B)はG成分画像のB画像の例であり、(C)はB成分画像のB画像の例であり、(D)はRGB成分画像のB画像の例である。(A) is an example of B image of R component image, (B) is an example of B image of G component image, (C) is an example of B image of B component image, (D) is RGB It is an example of B image of a component image. (A)はR成分画像のC画像の例であり、(B)はG成分画像のC画像の例であり、(C)はB成分画像のC画像の例であり、(D)はRGB成分画像のC画像の例である。(A) is an example of a C image of an R component image, (B) is an example of a C image of a G component image, (C) is an example of a C image of a B component image, (D) is an RGB It is an example of C image of a component image. (A)はC1画像の例であり、(B)はC2画像の例であり、(C)はC1画像とC2画像を合成した画像の例である。(A) is an example of a C1 image, (B) is an example of a C2 image, and (C) is an example of an image obtained by combining the C1 image and the C2 image. (A)はB1画像の例であり、(B)はB2画像の例であり、(C)はB1画像とB2画像を合成した画像の例である。(A) is an example of a B1 image, (B) is an example of a B2 image, and (C) is an example of an image obtained by combining the B1 image and the B2 image. (A)はC3画像の例であり、(B)はB3画像の例であり、(C)はC’画像の例であり、(D)はB’画像の例である。(A) is an example of a C3 image, (B) is an example of a B3 image, (C) is an example of a C 'image, and (D) is an example of a B' image. D画像の例である。It is an example of D image. 第1実施形態における検査装置Tによる連続シート検査処理の一例を示すフローチャートである。It is a flowchart which shows an example of the continuous sheet test | inspection process by the test | inspection apparatus T in 1st Embodiment. 第1実施形態における検査装置Tによる連続シート・ズレ量算出処理の一例を示すフローチャートである。It is a flowchart which shows an example of a continuous sheet and deviation | shift amount calculation process by the test | inspection apparatus T in 1st Embodiment. 第1実施形態における検査装置Tによる連続シート・テンプレート有りブロック処理の一例を示すフローチャートである。It is a flowchart which shows an example of the continuous sheet and template presence block process by the test | inspection apparatus T in 1st Embodiment. 第2実施形態における検査装置Tによる枚葉紙用テンプレート画像作成処理の一例を示すフローチャートである。It is a flowchart which shows an example of the template image creation process for sheets by the test | inspection apparatus T in 2nd Embodiment. 第2実施形態における検査装置Tによる枚葉紙検査処理の一例を示すフローチャートである。It is a flowchart which shows an example of the sheet inspection process by the inspection apparatus T in 2nd Embodiment. 第2実施形態における検査装置Tによる枚葉紙・ズレ量算出処理の一例を示すフローチャートである。It is a flowchart which shows an example of the sheet | seat / deviation | shift amount calculation process by the inspection apparatus T in 2nd Embodiment. 第2実施形態における検査装置Tによる枚葉紙・テンプレート有りブロック処理の一例を示すフローチャートである。It is a flowchart which shows an example of the block process with sheets and a template by the inspection apparatus T in 2nd Embodiment.

[1.第1実施形態]
以下、図面を参照して本発明の第1実施形態について説明する。なお、以下に説明する実施の形態は、オフセット輪転印刷機に設置された検査装置に対して本発明を適用した場合の実施形態である。
[1. First embodiment]
Hereinafter, a first embodiment of the present invention will be described with reference to the drawings. The embodiment described below is an embodiment in which the present invention is applied to an inspection device installed in a rotary offset printing press.

[1.1.オフセット輪転印刷機及び検査装置の構成]
図1及び図2を用いて本実施形態におけるオフセット輪転印刷機S(以下、「印刷機S」という)及び検査装置Tの構成について説明する。
[1.1. Configuration of offset rotary printing press and inspection device]
The configuration of the rotary offset printing press S (hereinafter referred to as "printing press S") and the inspection device T in the present embodiment will be described using Figs. 1 and 2.

[1.1.1.印刷機Sの構成]
まず、図1を用いて印刷機Sの構成について説明する。印刷機Sは、多色刷りの印刷機であり、インキ色(C(シアン)、M(マゼンタ)、Y(イエロー)、K(ブラック))毎に、印刷ユニットU1−U4が設けられている。印刷機Sは両面印刷機のため、各印刷ユニットU1−U4は、紙の搬送経路を挟むようにブランケット胴(上胴、下胴)が備えられ、各ブランケット胴に対して版胴(上胴、下胴)及びインキ供給装置(上胴側、下胴側)が設けられている。版胴には1シート分の絵柄の版が形成されており、ブランケット胴には2シート分の絵柄のインキが乗るようになっており、版胴が2回転するとき、ブランケット胴は1回転する(いわゆる「倍胴型のブランケット胴」)。つまり、ブランケット胴が1回転する間に2カットシート分の絵柄が印刷される。なお、本実施形態では被印刷物が帯状のロール紙(「連続シート」の一例)である場合について説明するが、ロール紙以外の連続シートについても適用できる。連続シートの素材は印刷が可能なものであれば、布やビニール等であってもよい。また、連続シートを枚葉単位で切断したもの(例えば枚葉紙)をカットシートという。
[1.1.1. Configuration of Printing Machine S]
First, the configuration of the printing press S will be described with reference to FIG. The printing machine S is a multicolor printing machine, and printing units U1-U4 are provided for each of ink colors (C (cyan), M (magenta), Y (yellow), K (black)). Since the printing machine S is a double-sided printing press, each printing unit U1-U4 is provided with a blanket cylinder (upper cylinder, lower cylinder) so as to sandwich the paper conveyance path, and the printing cylinder (upper cylinder) , Lower cylinder) and an ink supply device (upper cylinder side, lower cylinder side). The printing plate cylinder is formed with a printing plate for one sheet, and the printing blanket cylinder is made to carry two sheets of printing ink. When the printing cylinder is rotated twice, the blanket cylinder rotates one revolution. (The so-called "double-body type blanket cylinder"). That is, during one rotation of the blanket cylinder, a pattern of two cut sheets is printed. In the present embodiment, although the case where the printed material is a band-like roll paper (an example of a "continuous sheet") will be described, the present invention can be applied to continuous sheets other than roll paper. The material of the continuous sheet may be cloth, vinyl or the like as long as it can be printed. Moreover, what cut | disconnected the continuous sheet per sheet (for example, a sheet) is called cut sheet.

印刷ユニットU1−U4の下流には乾燥機U5が設けられている。また、乾燥機U5の下流には被印刷物であるロール紙に印刷された絵柄(記号、図形、写真、模様等)を含む検査対象領域(絵柄を構成する画線部及び非画線部を含む。例えば、新聞の紙面1ページ)を撮像するために、表面カメラ31A及び表面照明32Aと、裏面カメラ31B及び裏面照明32Bとが設けられている。表面カメラ31A及び裏面カメラ31B(以下、まとめて「カメラ31」という場合がある)は、例えば、25μ秒毎に4096画素のライン画像を撮像が可能なラインセンサカメラであり、シート毎に絵柄が印刷されたロール紙を撮像して得られたカメラ信号を出力する。表面照明32A及び裏面照明32B(以下、まとめて「照明32」という場合がある)は、それぞれ、表面カメラ31A及び裏面カメラ31Bが高解像度画像を撮像するために充分な光を照射する。   A dryer U5 is provided downstream of the printing units U1-U4. Further, downstream of the dryer U5, there is an inspection target area (image portion and non-image portion constituting a pattern) including a pattern (symbol, figure, photograph, pattern, etc.) printed on roll paper which is a substrate. For example, in order to pick up an image on a page 1 of a newspaper, a front camera 31A and a front illumination 32A, and a rear camera 31B and a rear illumination 32B are provided. The front surface camera 31A and the rear surface camera 31B (hereinafter, sometimes collectively referred to as "camera 31") are line sensor cameras capable of capturing a line image of 4096 pixels every 25 μs, for example. A camera signal obtained by imaging the printed roll paper is output. The front surface illumination 32A and the rear surface illumination 32B (hereinafter sometimes collectively referred to as "the illumination 32") respectively emit light sufficient for the front surface camera 31A and the rear surface camera 31B to capture a high resolution image.

カメラ31及び照明32が設置されている部分の更に下流には、絵柄が印刷されたロール紙を折り畳むための折り機U6が設けられている。   Further downstream of the portion where the camera 31 and the illumination 32 are installed, a folding machine U6 is provided for folding the roll paper on which the design is printed.

[1.1.2.検査装置Tの構成]
次に、図2を用いて検査装置Tの構成について説明する。検査装置Tは、システムコントローラ11、パイプライン画像処理部12、並列画像処理部13、表カメラ分岐ボード14、裏カメラ分岐ボード15、エンコーダ分岐ボード16、HUB17、カメラ31、照明32及びエンコーダ33を含んで構成されている。また、検査装置Tは、検査サーバ20、製版サーバSV及びオフセット印刷機Sと接続されている。
[1.1.2. Configuration of inspection apparatus T]
Next, the configuration of the inspection apparatus T will be described using FIG. The inspection apparatus T includes a system controller 11, pipeline image processing unit 12, parallel image processing unit 13, front camera branch board 14, back camera branch board 15, encoder branch board 16, HUB 17, camera 31, illumination 32, and encoder 33. It is comprised including. Further, the inspection device T is connected to the inspection server 20, the plate making server SV, and the offset printing machine S.

システムコントローラ11は、印刷機Sや検査装置T内部の各部から各種信号を受け取り、検査装置Tの各部を制御するPLC(Programmable logic controller)である。   The system controller 11 is a programmable logic controller (PLC) that receives various signals from the printing machine S and each unit in the inspection apparatus T and controls each unit in the inspection apparatus T.

パイプライン画像処理部12は、表面用と裏面用にそれぞれ2セット、合計4枚の画像処理ボード(表用画像処理ボード121A、表用画像処理ボード122A、裏用画像処理ボード121B、裏用画像処理ボード122B)を搭載している。表用画像処理ボード121Aと表用画像処理ボード122Aは交互に動作が切り替わる(裏用画像処理ボード121Bと裏用画像処理ボード122Bも同様)。各画像処理ボードは複数個の並列処理チップを搭載し、例えば、1000万×3色の画像の処理を45m秒毎に行う。表用画像処理ボード121Aと表用画像処理ボード122Aは、表カメラ分岐ボード14を介して、表面カメラ31Aからカメラ信号を受け取り、エンコーダ分岐ボード16から受け取ったパルス信号に基づいて表面について高解像度画像を生成し(具体的な生成方法については、特許3811565号公報を参照)、高解像度画像を用いて全数検査(全ての印刷物を対象とする検査)を行う。同様に、裏用画像処理ボード121Bと裏用画像処理ボード122Bも、裏カメラ分岐ボード15を介して、裏面カメラ31Bからカメラ信号を受け取り、全数検査を行う。   The pipeline image processing unit 12 has a total of four image processing boards (two sets for the front and the back) (the front image processing board 121A, the front image processing board 122A, the back image processing board 121B, and the back image A processing board 122B) is mounted. The operation of the front image processing board 121A and the front image processing board 122A is switched alternately (the same applies to the rear image processing board 121B and the rear image processing board 122B). Each image processing board mounts a plurality of parallel processing chips, and for example, performs processing of an image of 10,000,000 × 3 colors every 45 ms. The front image processing board 121A and the front image processing board 122A receive camera signals from the front camera 31A via the front camera branch board 14, and high resolution images of the front surface based on the pulse signals received from the encoder branch board 16 (For a specific generation method, refer to Japanese Patent No. 3811565), and 100% inspection (inspection for all printed matter) is performed using the high resolution image. Similarly, the back image processing board 121B and the back image processing board 122B also receive camera signals from the back camera 31B via the back camera branch board 15, and perform 100% inspection.

次に、全数検査の内容について説明する。パイプライン画像処理部12は、予めオペレータが問題無しと判断した高解像度画像を基準画像として、全数検査開始後に撮像された画像(被検査画像という場合がある)に基づいて全数検査を行う。具体的には、被検査画像から基準画像を引いた差分画像や、基準画像から被検査画像を引いた差分画像を、閾値画像と比較することにより不良を検出する。   Next, the contents of the exhaustive inspection will be described. The pipeline image processing unit 12 performs an exhaustive inspection based on an image (sometimes referred to as an inspection image) captured after the exhaustion inspection starts, using the high resolution image that the operator has determined in advance to have no problem as a reference image. Specifically, a defect is detected by comparing the difference image obtained by subtracting the reference image from the image to be inspected and the difference image obtained by subtracting the image to be inspected from the reference image with the threshold image.

パイプライン画像処理部12は、被検査画像と基準画像を比較する検査を行うに当たり、比較を適切に行えるように両画像の位置合わせを行う。そのために、パイプライン画像処理部12は、画像を複数のブロックに分割し、ブロック毎に両画像のズレ量を算出するズレ量算出処理を行う。ズレ量算出処理において、パイプライン画像処理部12は、基準画像及び被検査画像をブロックに分けて、基準画像を基に当該ブロック毎に作成したテンプレート画像により、被検査画像の対応するブロック内をサーチすることにより一致する箇所を探索し、一致した座標とテンプレート画像の座標との差をズレ量として算出する。   The pipeline image processing unit 12 aligns the two images so that the comparison can be appropriately performed when the inspection is performed to compare the inspection image and the reference image. Therefore, the pipeline image processing unit 12 divides the image into a plurality of blocks, and performs a shift amount calculation process of calculating the shift amount of both images for each block. In the shift amount calculation process, the pipeline image processing unit 12 divides the reference image and the inspection image into blocks, and uses the template image created for each block based on the reference image to generate the inside of the corresponding block of the inspection image. The matching portion is searched by searching, and the difference between the coincident coordinates and the coordinates of the template image is calculated as the amount of deviation.

パイプライン画像処理部12は、被印刷物が連続シートである第1実施形態では、一ブロックについて一枚のテンプレート画像を作成して、一枚のテンプレート画像により被検査画像の対応するブロック内をサーチする。なお、テンプレート画像の作成処理については、フローチャートを用いて後述する。   In the first embodiment, in which the substrate to be printed is a continuous sheet, the pipeline image processing unit 12 creates one template image for one block and searches the corresponding block of the inspection image with one template image. Do. The process of creating a template image will be described later using a flowchart.

パイプライン画像処理部12は、テンプレート画像の作成処理において、特徴部の少ないブロックについてはテンプレート画像を作成できない場合がある。パイプライン画像処理部12は、テンプレート画像を作成できたブロック(「テンプレート有りブロック」)については、テンプレート画像に基づいてズレ量を算出する一方、テンプレート画像を作成できなかったブロック(「テンプレート無しブロック」)については、ズレ量が決定している上下左右のブロック又は同行/同列のブロックのズレ量に基づいてズレ量を決定する。   The pipeline image processing unit 12 may not be able to create a template image for a block having a small number of feature portions in the process of creating a template image. The pipeline image processing unit 12 calculates the amount of deviation based on the template image for the block for which the template image has been created (“block with template”), while the block for which the template image could not be created (“block without template In the case of “)”, the amount of deviation is determined based on the amount of deviation of upper, lower, left, and right blocks or blocks in the same row / in the same row for which the amount of shift is determined.

また、パイプライン画像処理部12は、ブロック毎にテンプレート画像と被検査画像を比較する際には、被検査画像についてもブロック毎にテンプレート画像と同様の手法によりブロック画像を作成し、テンプレート画像により、対応するブロック画像内をサーチすることにより一致する箇所を探索する。このように同様の手法で作成した画像同士を比較することで、より正確に一致点を探索することができる。   Also, when comparing the template image and the inspection image for each block, the pipeline image processing unit 12 creates a block image for the inspection image by the same method as the template image for each block, and uses the template image Search for a matching location by searching in the corresponding block image. As described above, by comparing the images created by the same method, it is possible to search for a matching point more accurately.

パイプライン画像処理部12は、ブロック毎に算出したズレ量に基づいて被検査画像の位置補正を行うことにより、基準画像と被検査画像の位置合わせを行う。   The pipeline image processing unit 12 performs position correction of the image to be inspected based on the displacement amount calculated for each block, thereby aligning the reference image and the image to be inspected.

並列画像処理部13は、表面用と裏面用にそれぞれ1枚、合計2枚の画像処理ボード(表用画像処理ボード131A、裏用画像処理ボード131B)を搭載しており、パイプライン画像処理部12と並列に動作する。各画像処理ボードは複数個の並列処理チップを搭載し、例えば、1000万×3色の画像の処理を45m秒毎に行う。表用画像処理ボード131Aは、表カメラ分岐ボード14を介して、表面カメラ31Aからカメラ信号を受け取り、エンコーダ分岐ボード16から受け取ったパルス信号に基づいて表面について高解像度画像を生成し、製版データ(製版データにより表される画像)との照合検査と、倍胴間検査を行う。製版データは版胴に取り付ける刷版を生成する際の元データであり、製版データとの照合検査では、面付け、寸法、校正、版傷、ゴミ付き(版胴やブランケット胴にゴミが付いていないか)について検査を行う。   The parallel image processing unit 13 has a total of two image processing boards (a front image processing board 131A and a rear image processing board 131B), one for the front and one for the back, and a pipeline image processing unit Operates in parallel with 12 Each image processing board mounts a plurality of parallel processing chips, and for example, performs processing of an image of 10,000,000 × 3 colors every 45 ms. The front image processing board 131A receives a camera signal from the front camera 31A through the front camera branch board 14, generates a high resolution image of the surface based on the pulse signal received from the encoder branch board 16, and makes the plate making data ( Verification inspection with an image represented by plate making data and inspection between double cylinders are performed. The plate-making data is the original data when generating the plate to be attached to the plate cylinder, and in the matching inspection with the plate-making data, imposition, size, calibration, plate damage, with dust (the plate cylinder and blanket cylinder have dust Do not check for

一方、倍胴間検査は、ブランケット胴が一回転する際に印刷される2枚のシート(印刷物)をそれぞれ撮像した高解像度画像(すなわち、連続する高解像度画像)を比較する検査である。例えば、画像が一致しない場合には、ブランケット胴の一部に傷やゴミが付いている不良が検出される。   On the other hand, an inspection between double cylinders is an inspection that compares high-resolution images (that is, continuous high-resolution images) obtained by imaging two sheets (printed matter) printed when the blanket cylinder rotates once. For example, if the images do not match, a defect in which a part of the blanket cylinder is scratched or dust is detected.

表カメラ分岐ボード14は、表面カメラ31Aからのカメラ信号を表用画像処理ボード121A、表用画像処理ボード122A、表用画像処理ボード131Aへ同時に分岐して送る。   The front camera branch board 14 simultaneously branches and sends camera signals from the front surface camera 31A to the front image processing board 121A, the front image processing board 122A and the front image processing board 131A.

裏カメラ分岐ボード15は、裏面カメラ31Bからのカメラ信号を裏用画像処理ボード121B、裏用画像処理ボード122B、表用画像処理ボード131Bへ同時に分岐して送る。   The back camera branch board 15 simultaneously branches and sends camera signals from the back camera 31B to the back image processing board 121B, the back image processing board 122B, and the front image processing board 131B.

エンコーダ分岐ボード16は、オフセット印刷機Sにおける版胴に取り付けられ、版胴に連動(版の回転と1:1で連動)するエンコーダ33から出力されるエンコーダパルス信号(A、B、Z相)を受信し、パイプライン画像処理部12、並列画像処理部13に0.05〜0.1mmのエンコーダパルス信号(A、B、Z相)を分岐して出力する。   The encoder branch board 16 is attached to the plate cylinder in the offset printing press S, and encoder pulse signals (A, B, Z phases) output from the encoder 33 interlocked with the plate cylinder (1: 1 interlocked with the rotation of the plate) , And branches and outputs 0.05 to 0.1 mm encoder pulse signals (A, B, and Z phases) to the pipeline image processing unit 12 and the parallel image processing unit 13.

HUB17は、システムコントローラ11、パイプライン画像処理部12、並列画像処理部13、検査サーバ20、製版サーバSV及び印刷機SとのLAN接続用のHUBである。   The HUB 17 is a HUB for LAN connection with the system controller 11, the pipeline image processing unit 12, the parallel image processing unit 13, the inspection server 20, the plate making server SV, and the printing machine S.

検査サーバ20は、基準画像の保存、不良検出時における不良画像の保存、検査開始時や停止時における稼働記録や検査ログデータの保存といった機能を果たす。また、検査サーバ20は必要に応じてLAN経由で検査結果を閲覧する際に用いられる。製版サーバSVは、製版データ等を記憶しており、オペレータが新たな絵柄の印刷物を印刷するために印刷機Sの設定を行うと、その設定の内容を取得して、検査装置Tによる検査に必要な情報(製版データを含む)を検査装置Tに設定する。   The inspection server 20 performs functions such as storage of reference images, storage of defective images at the time of defect detection, storage of operation records at the start and stop of inspection, and inspection log data. In addition, the inspection server 20 is used when viewing inspection results via the LAN as needed. The plate making server SV stores plate making data and the like, and when the operator performs setting of the printing machine S to print a new printed matter of pattern, the contents of the setting are acquired, and inspection by the inspection device T is performed. Necessary information (including plate making data) is set in the inspection apparatus T.

[1.2.連続シート用テンプレート画像作成処理の動作]
図3を用いて、パイプライン画像処理部12による連続シート用テンプレート画像作成処理について説明する。なお、図3は、連続シート用テンプレート画像作成処理の一例を示すフローチャートである。
[1.2. Operation of Template Image Creation Process for Continuous Sheet]
The continuous sheet template image creation processing by the pipeline image processing unit 12 will be described using FIG. 3. FIG. 3 is a flowchart showing an example of the continuous sheet template image creation process.

まず、パイプライン画像処理部12は、オペレータが製品として問題無しと判断した印刷物を撮像した基準画像を取得する(ステップS1)。基準画像は、画素毎にRGB(Red、Green、Blue)成分を持つRGB画像であり、各成分は濃度の段階を意味する階調を示す値(例えば、256階調であれば「0〜255」の値)で示される。   First, the pipeline image processing unit 12 acquires a reference image obtained by imaging a printed material that the operator has determined that there is no problem as a product (step S1). The reference image is an RGB image having RGB (Red, Green, Blue) components for each pixel, and each component is a value indicating a gradation that means a step of density (for example, “0 to 255 in the case of 256 gradations It is shown by "value".

次に、パイプライン画像処理部12は、基準画像について、RGB毎に白紙部に対応する各画素の輝度(白紙部輝度)を取得する(ステップS2)。白紙部とは、インキが付着していない用紙部分のことである。   Next, the pipeline image processing unit 12 acquires, for the reference image, the luminance (white portion luminance) of each pixel corresponding to the white portion for each of RGB (step S2). The blank portion is a portion of the paper to which the ink is not attached.

次に、パイプライン画像処理部12は、基準画像について、RGB毎に、白紙部輝度が目標白紙部輝度になるように補正係数を算出し、各画素を補正する(ステップS3)。目標白紙部輝度は、例えば、予めオペレータ等によって設定されているものとする。   Next, the pipeline image processing unit 12 calculates a correction coefficient for the reference image so that the white area brightness becomes the target white area brightness for each of RGB, and corrects each pixel (step S3). The target blank area brightness is, for example, set in advance by an operator or the like.

次に、パイプライン画像処理部12は、基準画像(例えば、幅方向1030mm×搬送方向625mmの大きさの印刷物を撮像した画像)を複数ブロックに分割する(ステップS4)。分割するブロック数は、オペレータが任意に設定することとする。例えば、図4に示すように、基準画像200を64行8列の512ブロックに分割する。但し、行数は用紙1ピッチのサイズにより変更するのが好ましい(1行80画素)。また、パイプライン画像処理部12は、各ブロックの範囲(4隅のXY座標)をパイプライン画像処理部12内の記憶部(図示しない)に記憶させておく。   Next, the pipeline image processing unit 12 divides the reference image (for example, an image obtained by imaging a printed matter having a size of 1030 mm in the width direction × 625 mm in the conveyance direction) into a plurality of blocks (step S4). The number of blocks to be divided is arbitrarily set by the operator. For example, as shown in FIG. 4, the reference image 200 is divided into 512 blocks of 64 rows and 8 columns. However, it is preferable to change the number of lines according to the size of one paper pitch (one line 80 pixels). Further, the pipeline image processing unit 12 stores the range (X and Y coordinates of the four corners) of each block in a storage unit (not shown) in the pipeline image processing unit 12.

次に、パイプライン画像処理部12は、基準画像について、RGB毎に、ソーベルフィルタやエッジ抽出フィルタによりエッジ抽出を行う(ステップS5)。具体的には、基準画像(RGB)をR成分画像、G成分画像、B成分画像に分割して、それぞれの画像についてエッジ抽出を行う。RGB毎にエッジ抽出を行う理由は、より多くのエッジを抽出するためである。エッジを抽出した画像(エッジ画像)を、以下「A画像」という。図5は、R成分画像のA画像の例であり、図6は、G成分画像のA画像の例であり、図7は、B成分画像のA画像の例である。なお、エッジは、画像における濃度が急激に変化している箇所のことであり、例えば、画像中の物体の輪郭や線などが該当する。   Next, the pipeline image processing unit 12 performs edge extraction on the reference image for each RGB using a Sobel filter or an edge extraction filter (step S5). Specifically, the reference image (RGB) is divided into an R component image, a G component image, and a B component image, and edge extraction is performed on each image. The reason for performing edge extraction for each RGB is to extract more edges. The image from which the edge has been extracted (edge image) is hereinafter referred to as "A image". FIG. 5 shows an example of the A image of the R component image, FIG. 6 shows an example of the A image of the G component image, and FIG. 7 shows an example of the A image of the B component image. The edge is a portion where the density in the image changes rapidly, and corresponds to, for example, the contour or line of an object in the image.

次に、パイプライン画像処理部12は、A画像を階調a(本実施形態では「90」)で二値化する(ステップS6)。具体的には、ステップS5の処理で生成されたR成分画像のA画像、G成分画像のA画像、B成分画像のA画像それぞれについて階調aで二値化する。二値化して得た画像を、以下「B画像」という。図8(A)は、R成分画像のB画像の例であり、図8(B)は、G成分画像のB画像の例であり、図8(C)は、B成分画像のB画像の例であり、図8(D)は、これらのB画像を合成したRGB成分のB画像である。   Next, the pipelined image processing unit 12 binarizes the A image with gradation a ("90" in the present embodiment) (step S6). Specifically, the A image of the R component image, the A image of the G component image, and the A image of the B component image generated in the process of step S5 are binarized with the gradation a. The image obtained by binarization is hereinafter referred to as "B image". 8A shows an example of the B image of the R component image, FIG. 8B shows an example of the B image of the G component image, and FIG. 8C shows the B image of the B component image. This is an example, and FIG. 8D is a B image of an RGB component obtained by combining these B images.

次に、パイプライン画像処理部12は、A画像を階調b(本実施形態では「130」)で二値化する(ステップS7)。具体的には、ステップS5の処理で生成されたR成分画像のA画像、G成分画像のA画像、B成分画像のA画像それぞれについて階調bで二値化する。二値化して得た画像を、以下「C画像」という。図9(A)は、R成分画像のC画像の例であり、図9(B)は、G成分画像のC画像の例であり、図9(C)は、B成分画像のC画像の例であり、図9(D)は、これらのC画像を合成したRGB成分のC画像である。   Next, the pipelined image processing unit 12 binarizes the A image with the gradation b (“130” in the present embodiment) (step S7). Specifically, the A image of the R component image, the A image of the G component image, and the A image of the B component image generated in the process of step S5 are binarized with the gradation b. The image obtained by binarization is hereinafter referred to as "C image". FIG. 9 (A) is an example of a C image of an R component image, FIG. 9 (B) is an example of a C image of a G component image, and FIG. 9 (C) is a C image of the B component image. This is an example, and FIG. 9D is a C image of an RGB component obtained by combining these C images.

次に、パイプライン画像処理部12は、C画像を水平微分(水平微分することにより図柄のエッジの水平線のみを抽出する)した後、2画素分水平方向へ膨張させた画像(以下「C1画像」という)を生成する(ステップS8)。2画素分水平方向へ膨張とは、画像全体を水平方向に拡大することを意味する。水平方向へ膨張させることにより後述するステップS10の処理において交点を求めやすくする。なお、図10(A)は、C1画像の例である。   Next, the pipeline image processing unit 12 horizontally differentiates the C image (extracts only the horizontal line of the edge of the pattern by performing horizontal differentiation), and then expands the image in the horizontal direction by two pixels (hereinafter referred to as “C1 image (Step S8). Expansion in the horizontal direction by two pixels means expanding the entire image in the horizontal direction. The expansion in the horizontal direction makes it easier to obtain the intersection point in the process of step S10 described later. FIG. 10A is an example of the C1 image.

次に、パイプライン画像処理部12は、C画像を垂直微分した後、2画素分垂直方向へ膨張させた画像(以下「C2画像」という)を生成する(ステップS9)。2画素分垂直方向へ膨張とは、画像全体を垂直方向に拡大することを意味する。垂直方向へ膨張させることにより後述するステップS10の処理において交点を求めやすくする。なお、図10(B)は、C2画像の例である。   Next, after vertically differentiating the C image, the pipeline image processing unit 12 generates an image (hereinafter referred to as “C2 image”) expanded in the vertical direction by two pixels (step S9). Expansion in the vertical direction by two pixels means expanding the entire image in the vertical direction. The expansion in the vertical direction makes it easier to obtain the intersection point in the process of step S10 described later. FIG. 10B is an example of the C2 image.

次に、パイプライン画像処理部12は、C1画像とC2画像を合成してC中間画像を生成し、水平・垂直とも8画素以上連続する直線であって、垂直に交差する直線のみを残した画像(以下「C3画像という)を生成し、交点のXYアドレスを取得する(ステップS10)。なお、図10(C)は、C1画像とC2画像を合成した画像の例であり、図12(A)は、C3画像の例である。図12(A)に示すように、交点が複数ある場合にはそれぞれのXYアドレスを取得する。   Next, the pipeline image processing unit 12 combines the C1 image and the C2 image to generate a C intermediate image, and is a straight line that is continuous for eight or more pixels both horizontally and vertically, and only a straight line that intersects vertically is left. An image (hereinafter referred to as “C3 image” is generated, and the XY address of the intersection is obtained (step S10). Note that FIG. 10C is an example of an image obtained by combining the C1 image and the C2 image. A) is an example of a C3 image, as shown in FIG.12A, when there are a plurality of intersections, respective XY addresses are acquired.

次に、パイプライン画像処理部12は、B画像を水平微分した後、2画素分水平方向へ膨張させた画像(以下「B1画像」という)を生成する(ステップS11)。なお、図11(A)は、B1画像の例である。   Next, the pipeline image processing unit 12 horizontally differentiates the B image, and then generates an image (hereinafter referred to as “B1 image”) expanded in the horizontal direction by two pixels (step S11). FIG. 11A is an example of the B1 image.

次に、パイプライン画像処理部12は、B画像を垂直微分した後、2画素分垂直方向へ膨張させた画像(以下「B2画像」という)を生成する(ステップS12)。なお、図11(B)は、B2画像の例である。   Next, the pipeline image processing unit 12 vertically differentiates the B image, and then generates an image (hereinafter referred to as “B2 image”) expanded in the vertical direction by two pixels (step S12). FIG. 11B is an example of the B2 image.

次に、パイプライン画像処理部12は、B1画像とB2画像を合成してB中間画像を生成し、水平・垂直とも8画素以上連続する直線であって、垂直に交差する直線のみを残した画像(以下「B3画像という)を生成する(ステップS13)。なお、図11(C)は、B1画像とB2画像を合成した画像の例であり、図12(B)は、B3画像の例である。   Next, the pipeline image processing unit 12 combines the B1 image and the B2 image to generate a B intermediate image, and leaves only straight lines that are straight lines that are continuous for eight or more pixels in both horizontal and vertical directions and that cross vertically An image (hereinafter referred to as "B3 image" is generated (step S13) Note that Fig. 11C is an example of an image obtained by combining the B1 image and the B2 image, and Fig. 12B is an example of the B3 image. It is.

次に、パイプライン画像処理部12は、C3画像(図12(A)参照)から、ステップS10で取得したXYアドレスを中心とする32画素×32画素の切り出し画像(C’画像)を生成する(ステップS14)。なお、切り出し画像(C’画像)のサイズは任意であり、例えば、64画素×64画素の切り出し画像(C’画像)を生成することとしてもよい。図12(C)は、C’画像の例である。   Next, the pipeline image processing unit 12 generates, from the C3 image (see FIG. 12A), a cutout image (C ′ image) of 32 × 32 pixels centered on the XY address acquired in step S10. (Step S14). The size of the cutout image (C 'image) is arbitrary, and for example, a cutout image (C' image) of 64 pixels x 64 pixels may be generated. FIG. 12C is an example of a C ′ image.

次に、パイプライン画像処理部12は、B3画像(図12(B)参照)から、ステップS13の処理で切り出し画像を切り出した際に中心としたXYアドレスと同じXYアドレスを中心とする32画素×32画素の切り出し画像(B’画像)を生成する(ステップS15)。なお、ステップS13の処理と同様に64画素×64画素の切り出し画像(B’画像)を生成することとしてもよい(但し、C’画像と同じサイズとする)。図12(D)は、B’画像の例である。   Next, the pipeline image processing unit 12 generates 32 pixels centered on the same XY address as the XY address that is the center when the cutout image is cut out from the B3 image (see FIG. 12B) in the process of step S13. A cutout image (B ′ image) of × 32 pixels is generated (step S15). Note that it is also possible to generate a cutout image (B ′ image) of 64 pixels × 64 pixels in the same manner as the process of step S13 (however, the same size as the C ′ image). FIG. 12D is an example of the B ′ image.

次に、パイプライン画像処理部12は、C’画像とB’画像の差分が1画素から8画素の範囲内であれば、これらの画像の中心アドレス(ステップS10の処理で取得したXYアドレス)について「テンプレート適性有り」と判定する(ステップS16)。なお、C’画像とB’画像の差分が0画素(完全に一致)の場合も「テンプレート適性有り」と判定してもよい。一方、パイプライン画像処理部12は、C’画像とB’画像の差分が1画素から8画素の範囲内でなければ、これらの画像の中心アドレスについて「テンプレート適性無し」と判定する。すなわち、C’画像とB’画像の差分が、例えば、本実施形態のように9画素以上ある場合には違いがあり過ぎるので「テンプレート適性無し」と判定する。なお、本実施形態では差分が1画素から8画素の範囲内である場合にのみ「テンプレート適性有り」と判定することとしたが、これは一例であって閾値は適宜変更してもよい。   Next, if the difference between the C ′ image and the B ′ image is within the range of 1 pixel to 8 pixels, the pipeline image processing unit 12 determines the center address of these images (the XY address acquired in the process of step S10) It is determined that “appropriate of template suitability” (step S16). In addition, when the difference between the C ′ image and the B ′ image is 0 pixel (completely matched), it may be determined as “with template suitability”. On the other hand, if the difference between the C 'image and the B' image is not within the range of 1 pixel to 8 pixels, the pipeline image processing unit 12 determines that the center address of these images is "no template suitability". That is, when the difference between the C ′ image and the B ′ image is, for example, 9 pixels or more as in the present embodiment, the difference is too much, so it is determined that “no template suitability”. In the present embodiment, it is determined that “the template suitability is present” only when the difference is in the range of 1 pixel to 8 pixels, but this is an example, and the threshold may be changed as appropriate.

なお、ステップS10の処理で複数のXYアドレスを取得した場合には、その数分だけ、ステップS14及びステップS15の処理を行い、C’画像及びB’画像を生成する。このとき、同じXYアドレスから切り出したC’画像及びB’画像を組にして記憶しておく。そして、それぞれの組のC’画像及びB’画像についてステップS16の処理を行う。   When a plurality of XY addresses are acquired in the process of step S10, the processes of steps S14 and S15 are performed by the number of X and Y addresses to generate a C 'image and a B' image. At this time, a C 'image and a B' image cut out from the same XY address are stored as a set. Then, the process of step S16 is performed on each set of C 'and B' images.

次に、パイプライン画像処理部12は、ステップS4の処理で分割した一のブロックを選択する(ステップS17)。   Next, the pipelined image processing unit 12 selects one block divided in the process of step S4 (step S17).

次に、パイプライン画像処理部12は、ステップS17の処理で選択したブロック内に、「テンプレート適性有り」と判定したXYアドレスがないかサーチする(ステップS18)。具体的には、ブロック内の始点(例えば、左下隅)からX方向に一画素ずつずらしながら「テンプレート適性有り」と判定したXYアドレスがないかサーチする。ブロック端までいっても見つからない場合には、Y方向に1画素ずらし再度、X方向に一画素ずつずらしながら「テンプレート適性有り」と判定したXYアドレスがないかサーチする。「テンプレート適性有り」と判定したXYアドレスが1つ見つかった時点でサーチを終了する。   Next, the pipelined image processing unit 12 searches the block selected in the process of step S17 for an XY address determined to be “with template suitability” (step S18). Specifically, it is searched whether or not there is an XY address determined as “with template suitability” while shifting one pixel at a time in the X direction from the start point (for example, the lower left corner) in the block. If the block end is not found, the pixel is shifted by one pixel in the Y direction, and while shifting the pixel by one pixel in the X direction again, a search is made for an XY address determined to be "template appropriate". The search is ended when one XY address determined to be "appropriate for template" is found.

そして、パイプライン画像処理部12は、ブロック内に「テンプレート適性有り」のXYアドレスがあったか否かを判定する(ステップS19)。具体的には、「テンプレート適性有り」のXYアドレスがそのブロック内に一つでも含まれていれば「YES」と判定する。   Then, the pipeline image processing unit 12 determines whether or not there is an XY address of “with template suitability” in the block (step S19). Specifically, it is determined as "YES" if at least one of the XY addresses "with template suitability" is included in the block.

パイプライン画像処理部12は、ブロック内に「テンプレート適性有り」のXYアドレスがないと判定した場合には(ステップS19:NO)、当該ブロックを「テンプレート無しブロック」と判定し(ステップS20)、ステップS26の処理に移行する。一方、パイプライン画像処理部12は、ブロック内に「テンプレート適性有り」のXYアドレスがあると判定した場合には(ステップS19:YES)、当該ブロックを「テンプレート有りブロック」と判定し(ステップS21)、ステップS22の処理に移行する。   If the pipelined image processing unit 12 determines that there is no XY address of “with template suitability” in the block (step S19: NO), the pipeline image processing unit 12 determines that the block is “block without template” (step S20), It transfers to the process of step S26. On the other hand, when the pipeline image processing unit 12 determines that there is an XY address of “with template suitability” in the block (step S19: YES), the pipeline image processing unit 12 determines that the block is “block with template” (step S21). And the process of step S22.

次に、パイプライン画像処理部12は、ステップS6の処理と同様にRGB毎にA画像を階調((a+b)/2)(本実施形態では「(90+130)/2=110」)で二値化し、ステップS11〜ステップS13の処理においてB画像について行ったのと同様の処理を行い、D画像を生成する(ステップS22)。図13は、D画像の例である。   Next, the pipeline image processing unit 12 performs gradation ((a + b) / 2) ("(90 + 130) / 2 = 110" in this embodiment) of the A image for each RGB as in the process of step S6. The image is binarized, and the same processing as that performed for the B image in the processing of steps S11 to S13 is performed to generate a D image (step S22). FIG. 13 is an example of the D image.

次に、パイプライン画像処理部12は、D画像から、「テンプレート適性有り」のXYアドレスを中心アドレスとする32画素×32画素を切り出し、テンプレート画像(D’画像)(図13におけるD’画像300参照)を生成する(ステップS23)。なお、D’画像のサイズも64画素×64画素としてもよい。   Next, the pipeline image processing unit 12 cuts out 32 pixels × 32 pixels whose center address is the XY address “with template suitability” from the D image, and a template image (D ′ image) (D ′ image in FIG. 13) 300) is generated (step S23). The size of the D ′ image may also be 64 pixels × 64 pixels.

次に、パイプライン画像処理部12は、テンプレート画像(D’画像)のチェックを行う(ステップS24)。このチェックでは、テンプレート検証範囲(テンプレート画像(D’画像)の中心アドレスを基準とするX方向±64画素、Y方向±128画素の範囲)内を、D’画像を1画素ずつずらしていき、何れの位置でも(但し、中心アドレスを除く)D画像とD’画像の差分が1画素以上であることを検証する。すなわち、テンプレート画像(D’画像)がその周囲(テンプレート検証範囲内)でユニークであることを検証する。   Next, the pipeline image processing unit 12 checks the template image (D 'image) (step S24). In this check, the D 'image is shifted by one pixel at a time in the template verification range (a range of ± 64 pixels in the X direction and ± 128 pixels in the Y direction with respect to the center address of the template image (D ′ image)). It is verified that the difference between the D image and the D ′ image at any position (except for the center address) is one pixel or more. That is, it is verified that the template image (D 'image) is unique around it (within the template verification range).

そして、パイプライン画像処理部12は、チェックの結果、テンプレート検証範囲内でテンプレート画像(D’画像)がユニークでない場合には、当該テンプレート画像(D’画像)は不合格として、ステップS18に戻り、同じブロック内の他の「テンプレート適性有り」のXYアドレスをサーチし、当該XYアドレスについて、ステップS19〜ステップS24の処理を行う。ステップS18〜ステップS24の処理を2回やり直してもチェックの結果が変わらない場合には、ステップS20の処理に移行する。一方、パイプライン画像処理部12は、チェックの結果、テンプレート検証範囲内でテンプレート画像(D’画像)がユニークである場合には、ステップS25の処理に移行する。   Then, if the template image (D 'image) is not unique within the template verification range as a result of the check, the pipeline image processing unit 12 rejects the template image (D' image), and returns to step S18. The other "template suitability" XY addresses in the same block are searched, and the processes in steps S19 to S24 are performed on the XY addresses. If the result of the check does not change even if the process of step S18 to step S24 is repeated twice, the process proceeds to step S20. On the other hand, if the template image (D 'image) is unique within the template verification range as a result of the check, the pipeline image processing unit 12 proceeds to the process of step S25.

次に、パイプライン画像処理部12は、直近のステップS17の処理で選択した一のブロックの識別情報(例えば、ブロックID)と、テンプレート画像(D’画像)と、中心アドレス(テンプレート画像(D’画像)をD画像から切り取った際のXYアドレス)とを対応付けてテンプレートテーブル(図示しない)に登録し(ステップS25)、ステップS26の処理に移行する。   Next, the pipeline image processing unit 12 determines identification information (for example, a block ID) of one block selected in the process of the latest step S17, a template image (D 'image), and a center address (template image (D The "image" is registered in the template table (not shown) in association with the XY address) when the "image" is cut out from the D image (step S25), and the process proceeds to step S26.

パイプライン画像処理部12は、ステップS20又はステップS25の処理を終えると、次いで、全てのブロックを選択したか否かを判定する(ステップS26)。すなわち、パイプライン画像処理部12は、ステップS4の処理で分割した全ブロックをステップS17の処理により選択したか否かを判定する。このとき、パイプライン画像処理部12は、全てのブロックを選択していないと判定した場合には(ステップS26:NO)、ステップS17の処理に移行し、それまでに選択していない一のブロックを選択する。一方、パイプライン画像処理部12は、全てのブロックを選択したと判定した場合には(ステップS26:YES)、連続シート用テンプレート画像作成処理を終了する。   After completing the process of step S20 or step S25, the pipelined image processing unit 12 then determines whether all blocks have been selected (step S26). That is, the pipelined image processing unit 12 determines whether all the blocks divided in the process of step S4 have been selected by the process of step S17. At this time, when the pipeline image processing unit 12 determines that all the blocks are not selected (step S26: NO), the process proceeds to step S17, and one block which has not been selected so far Choose On the other hand, when determining that all the blocks have been selected (step S26: YES), the pipeline image processing unit 12 ends the continuous sheet template image creation process.

本実施形態において、パイプライン画像処理部12は、A画像を階調aで二値化したB画像と、A画像を階調bで二値化したC画像のそれぞれから切り出し画像(B’画像及びC’画像)を比較して、差分が一定の範囲(1画素〜8画素)である場合に、B’画像及びC’画像を切り出した際のXYアドレスをテンプレートの適性有りと判断とする。これにより、一定の階調の範囲(階調a〜bの範囲)の特徴点を見つけることができる。また、パイプライン画像処理部12は、A画像を階調(a+b)/2で二値化したD画像から、テンプレート適性有りと判断したXYアドレスに基づいて、テンプレート画像(D’画像)を生成する。これにより、被検査画像の階調が階調a〜bの範囲で変化してもテンプレート画像(D’画像)と適切にマッチングすることができる。   In the present embodiment, the pipeline image processing unit 12 extracts an image (B ′ image) from each of a B image obtained by binarizing the A image with gradation a and a C image obtained by binarizing the A image with gradation b. And C 'images) and if the difference is within a certain range (1 pixel to 8 pixels), it is determined that the XY address at the time of cutting out the B' image and the C 'image is the suitability of the template . This makes it possible to find feature points in a certain gradation range (a range of gradations a to b). Also, the pipeline image processing unit 12 generates a template image (D ′ image) from the D image obtained by binarizing the A image with gradation (a + b) / 2, based on the XY address determined as having the template suitability. Do. Thereby, even if the gradation of the image to be inspected changes in the range of gradation a to b, matching with the template image (D 'image) can be appropriately performed.

[1.3.連続シート検査処理の動作]
次に、図14を用いて、パイプライン画像処理部12による連続シート検査処理について説明する。なお、図14は、連続シート検査処理の一例を示すフローチャートである。連続シート検査処理は、基準画像と被検査画像の比較処理を行う全数検査である。
[1.3. Operation of continuous sheet inspection process]
Next, continuous sheet inspection processing by the pipeline image processing unit 12 will be described using FIG. FIG. 14 is a flowchart showing an example of the continuous sheet inspection process. The continuous sheet inspection process is an exhaustive inspection that compares the reference image and the inspection image.

まず、パイプライン画像処理部12は、連続シート・ズレ量算出処理を行う(ステップS31)。なお、連続シート・ズレ量算出処理については後述する。   First, the pipeline image processing unit 12 performs a continuous sheet shift amount calculation process (step S31). Note that the continuous sheet displacement amount calculation process will be described later.

次に、パイプライン画像処理部12は、連続シート・ズレ量算出処理により、ブロック毎に算出したズレ量に基づいて、被検査画像の位置補正を行う(ステップS32)。   Next, the pipeline image processing unit 12 corrects the position of the image to be inspected based on the displacement amount calculated for each block by the continuous sheet displacement amount calculation process (step S32).

次に、パイプライン画像処理部12は、位置補正した被検査画像と基準画像を比較する検査を行う(ステップS33)。   Next, the pipeline image processing unit 12 performs an inspection for comparing the position-corrected inspection image with the reference image (step S33).

次に、パイプライン画像処理部12は、ステップS33の処理で行った比較検査の結果を出力し(ステップS34)、連続シート検査処理を終了する。ステップS34の処理において、パイプライン画像処理部12は、例えば、比較検査の結果を示す結果データを作成して検査サーバ20に送信したり(不良検出時における不良画像、検査開始時や停止時における稼働記録や検査ログデータとともに送信してもよい)、検査結果を表示装置(例えば、検査サーバ20に接続された表示装置等)に表示させたりしてもよい。   Next, the pipeline image processing unit 12 outputs the result of the comparison inspection performed in the processing of step S33 (step S34), and ends the continuous sheet inspection processing. In the process of step S34, for example, the pipeline image processing unit 12 creates result data indicating the result of the comparison inspection and transmits it to the inspection server 20 (a defective image at the time of defect detection, at the start or stop of the inspection). The inspection result may be displayed on a display device (e.g., a display device connected to the inspection server 20, etc.).

[1.4.連続シート・ズレ量算出処理の動作]
次に、図15を用いて、パイプライン画像処理部12による連続シート・ズレ量算出処理について説明する。
[1.4. Operation of continuous sheet / displacement amount calculation processing]
Next, the continuous sheet / displacement amount calculation process by the pipeline image processing unit 12 will be described with reference to FIG.

まず、パイプライン画像処理部12は、全数検査の対象となる印刷物を撮像した被検査画像を取得する(ステップS51)。被検査画像はRGB画像であり、各成分は「0〜255」の階調を示す値で示される。   First, the pipeline image processing unit 12 acquires an inspection image obtained by imaging a printed matter to be an object of exhaustive inspection (step S51). An inspection image is an RGB image, and each component is indicated by a value indicating a gradation of “0 to 255”.

次に、パイプライン画像処理部12は、被検査画像について、RGB毎に白紙部に対応する各画素の輝度(白紙部輝度)を取得する(ステップS52)。   Next, the pipeline image processing unit 12 obtains the luminance (white portion brightness) of each pixel corresponding to the white portion for each of RGB in the inspection image (step S52).

次に、パイプライン画像処理部12は、被検査画像について、RGB毎に、白紙部輝度が目標白紙部輝度になるように補正係数を算出し、各画素を補正する(ステップS53)。目標白紙部輝度は、連続シート用テンプレート画像作成処理のステップS3と同じ値が予めオペレータ等によって設定されているものとする。   Next, the pipeline image processing unit 12 calculates a correction coefficient for each white color of the inspection image so that the white area brightness becomes the target white area brightness for each RGB, and corrects each pixel (step S53). The target blank area brightness is assumed to be set in advance by the operator or the like in the same value as in step S3 of the continuous sheet template image creation process.

次に、パイプライン画像処理部12は、基準画像と同様に被検査画像を複数ブロックに分割する(ステップS54)。   Next, the pipeline image processing unit 12 divides the inspection image into a plurality of blocks in the same manner as the reference image (step S54).

次に、パイプライン画像処理部12は、基準画像と同様に被検査画像について、RGB毎に、ソーベルフィルタによりエッジ抽出を行う(ステップS55)。なお、連続シート検査処理においてもエッジ抽出した画像を「A画像」という。   Next, the pipeline image processing unit 12 performs edge extraction with the Sobel filter for each of the R, G, and B images with respect to the inspection image as in the reference image (step S55). In addition, the image which edge-extracted also in a continuous sheet test | inspection process is called "A image."

次に、パイプライン画像処理部12は、連続シート用テンプレート画像作成処理のステップS22と同様に、A画像を階調((a+b)/2)(本実施形態では「(90+130)/2=110」)で二値化した画像に対して、連続シート用テンプレート画像作成処理のステップS11〜ステップS13の処理においてB画像について行ったのと同様の処理を行い、D画像を生成する(ステップS56)。なお、aとbは、連続シート用テンプレート画像作成処理における値と同じ値を用いる。   Next, as in step S22 of the continuous sheet template image creation process, the pipeline image processing unit 12 applies the gradation ((a + b) / 2) ((90 + 130) / 2 in the present embodiment) to the A image. The same processing as that performed for the B image in the processing of steps S11 to S13 of the continuous sheet template image creation processing is performed on the image binarized at = 110 ′ ′) to generate a D image (step S56). As a and b, the same values as in the continuous sheet template image creation process are used.

次に、パイプライン画像処理部12は、連続シート・テンプレート有りブロック処理を行う(ステップS57)。なお、連続シート・テンプレート有りブロック処理については後述する。連続シート・テンプレート有りブロック処理は、テンプレート有りブロックについてズレ量を決定する処理である。   Next, the pipeline image processing unit 12 performs block processing with continuous sheet / template (step S57). The continuous sheet / template with block process will be described later. The continuous sheet / template / block process is a process of determining the amount of deviation for the template / block.

次に、パイプライン画像処理部12は、ズレ量が決定していないブロックがあるか否かを判定する(ステップS58)。連続シート・テンプレート有りブロック処理では、テンプレート有りブロックについてズレ量を決定するので、ここでズレ量が決定していないブロックはテンプレート無しブロックが該当する。パイプライン画像処理部12は、ズレ量が決定していないブロックがないと判定した場合には(ステップS58:NO)、連続シート・ズレ量算出処理を終了する。一方、パイプライン画像処理部12は、ズレ量が決定していないブロックがあると判定した場合には(ステップS58:YES)、一のテンプレート無しブロックを選択し(ステップS59)、ズレ量が決定している上下左右のブロック又は同行/同列のブロックのズレ量に基づいてズレ量を決定し(ステップS60)、ステップS58の処理に移行する。そして、パイプライン画像処理部12は、全ての「テンプレート無しブロック」を選択するまで(全てのテンプレート無しブロックについてズレ量を決定するまで)、ステップS58〜ステップS60の処理を繰り返す。   Next, the pipelined image processing unit 12 determines whether there is a block for which the shift amount has not been determined (step S58). In the continuous sheet / template present block processing, since the shift amount is determined for the template present block, the block for which the shift amount is not determined here corresponds to the template absent block. If the pipeline image processing unit 12 determines that there is no block for which the amount of deviation has not been determined (step S58: NO), the continuous sheet / amount of deviation calculation process ends. On the other hand, when the pipeline image processing unit 12 determines that there is a block for which the amount of shift has not been determined (step S58: YES), one non-template block is selected (step S59), and the amount of shift is determined. The amount of deviation is determined based on the amount of deviation of upper, lower, left, and right blocks or blocks in the same row / in the same row (step S60), and the process proceeds to step S58. Then, the pipeline image processing unit 12 repeats the processing of steps S58 to S60 until all “blocks without template” are selected (until the amount of deviation is determined for all blocks without template).

[1.5.連続シート・テンプレート有りブロック処理の動作]
次に、図16を用いて、パイプライン画像処理部12による連続シート・テンプレート有りブロック処理について説明する。
[1.5. Operation of block processing with continuous sheet / template]
Next, block processing with continuous sheets and templates by the pipeline image processing unit 12 will be described with reference to FIG.

まず、パイプライン画像処理部12は、連続シート用テンプレート画像作成処理のステップS21の処理で「テンプレート有りブロック」と判定した一のブロックを選択する(ステップS101)。   First, the pipelined image processing unit 12 selects one block that has been determined as the “template present block” in the process of step S21 of the continuous sheet template image creation process (step S101).

次に、パイプライン画像処理部12は、テンプレートテーブル(連続シート用テンプレート画像作成処理のステップS25を参照)から、ステップS101の処理で選択したブロックに含まれるテンプレート画像(D’画像)と中心アドレスを取得する(ステップS102)。   Next, the pipeline image processing unit 12 determines from the template table (see step S25 of the continuous sheet template image creating process) the template image (D 'image) and the center address included in the block selected in step S101. Are acquired (step S102).

次に、パイプライン画像処理部12は、ステップS102の処理で取得した中心アドレスを基準とする予め設定された設定範囲(例えば、X方向±64画素、Y方向±128画素の範囲)内を、ステップS56の処理で生成したD画像に対してD’画像を1画素ずつずらしていき、D画像とD’画像の差分を算出する(ステップS103)。   Next, the pipelined image processing unit 12 sets a preset range (for example, a range of ± 64 pixels in the X direction and a range of ± 128 pixels in the Y direction) based on the center address acquired in the process of step S102. The D ′ image is shifted by one pixel with respect to the D image generated in the process of step S56, and the difference between the D image and the D ′ image is calculated (step S103).

次に、パイプライン画像処理部12は、差分が最小であった位置を特定する(ステップS104)。なお、差分が最小である位置が同じ値で複数ある場合には最も中心アドレスに近い位置を一つ特定する。   Next, the pipeline image processing unit 12 specifies the position at which the difference is the smallest (step S104). Note that if there are a plurality of positions with the smallest difference and the same value, one position closest to the center address is identified.

次に、パイプライン画像処理部12は、ステップS104の処理で特定した位置と、ステップS102の処理で取得した中心アドレスの差をズレ量(dx,dy)として決定する(ステップS105)。なお、決定したズレ量は、当該中心アドレスを含むブロックの識別情報(例えば、ブロックID)と対応付けて記憶させておくものとする。   Next, the pipelined image processing unit 12 determines the difference between the position identified in the process of step S104 and the center address acquired in the process of step S102 as the deviation amount (dx, dy) (step S105). The determined amount of deviation is stored in association with identification information (for example, a block ID) of a block including the center address.

次に、パイプライン画像処理部12は、全ての「テンプレート有りブロック」を選択したか否かを判定する(ステップS106)。このとき、パイプライン画像処理部12は、全ての「テンプレート有りブロック」を選択していないと判定した場合には(ステップS106:NO)、ステップS101の処理に移行し、それまでに選択していない一の「テンプレート有りブロック」を選択する。そして、全ての「テンプレート有りブロック」を選択するまで、ステップS101〜ステップS106の処理を繰り返す。一方、パイプライン画像処理部12は、全ての「テンプレート有りブロック」を選択したと判定した場合には(ステップS106:YES)、連続シート・テンプレート有りブロック処理を終了し、連続シート・ズレ量算出処理に戻る。   Next, the pipelined image processing unit 12 determines whether or not all the "template present blocks" have been selected (step S106). At this time, when the pipeline image processing unit 12 determines that not all “blocks with template” have been selected (step S106: NO), the process proceeds to step S101, and selection has been made by that time. Select one non-template block. Then, the processing of steps S101 to S106 is repeated until all the "template present blocks" are selected. On the other hand, if the pipeline image processing unit 12 determines that all "blocks with template" have been selected (step S106: YES), the continuous sheet / template with block processing is ended, and the continuous sheet / displacement amount is calculated. Return to processing.

[2.第2実施形態]
次に、図面を参照して本発明の第2実施形態について説明する。なお、第2実施形態は、オフセット枚葉印刷機に設置された検査装置に対して本発明を適用した場合の実施形態である。なお、第2実施形態は、第1実施形態と共通する部分が多いので、ここでは、その差異点を中心に説明する。
[2. Second embodiment]
Next, a second embodiment of the present invention will be described with reference to the drawings. The second embodiment is an embodiment in which the present invention is applied to an inspection apparatus installed in an offset sheet-fed printing press. In the second embodiment, there are many parts in common with the first embodiment, and therefore, the differences will be mainly described here.

[2.1.オフセット枚葉印刷機及び検査装置の構成]
第2実施形態におけるオフセット枚葉印刷機の構成は、本発明と直接的に関係しないので説明を省略する。
[2.1. Configuration of offset sheet-fed printing press and inspection apparatus]
The configuration of the offset sheet-fed printing press according to the second embodiment is not directly related to the present invention, and thus the description thereof is omitted.

次に、第2実施形態における検査装置Tの構成について説明する。第2実施形態における検査装置Tは、基本的に第1実施形態における検査装置Tと同様の構成を有している。   Next, the configuration of the inspection apparatus T in the second embodiment will be described. The inspection apparatus T in the second embodiment basically has the same configuration as the inspection apparatus T in the first embodiment.

パイプライン画像処理部12は、表面用と裏面用にそれぞれ2セット、合計4枚の画像処理ボード(表用画像処理ボード121A、表用画像処理ボード122A、裏用画像処理ボード121B、裏用画像処理ボード122B)を搭載している。表用画像処理ボード121Aと表用画像処理ボード122Aは交互に動作が切り替わる(裏用画像処理ボード121Bと裏用画像処理ボード122Bも同様)。各画像処理ボードは複数個の並列処理チップを搭載し、例えば、1000万×3色の画像の処理を180msec毎に行う。表用画像処理ボード121Aと表用画像処理ボード122Aは、表カメラ分岐ボード14を介して、表面カメラ31Aからカメラ信号を受け取り、エンコーダ分岐ボード16から受け取ったパルス信号に基づいて表面について高解像度画像を生成し(具体的な生成方法については、特許3811565号公報を参照)、高解像度画像を用いて全数検査(全ての印刷物を対象とする検査)を行う。同様に、裏用画像処理ボード121Bと裏用画像処理ボード122Bも、裏カメラ分岐ボード15を介して、裏面カメラ31Bからカメラ信号を受け取り、全数検査を行う。   The pipeline image processing unit 12 has a total of four image processing boards (two sets for the front and the back) (the front image processing board 121A, the front image processing board 122A, the back image processing board 121B, and the back image A processing board 122B) is mounted. The operation of the front image processing board 121A and the front image processing board 122A is switched alternately (the same applies to the rear image processing board 121B and the rear image processing board 122B). Each image processing board carries a plurality of parallel processing chips, and for example, performs processing of an image of 10,000,000 × 3 colors every 180 msec. The front image processing board 121A and the front image processing board 122A receive camera signals from the front camera 31A via the front camera branch board 14, and high resolution images of the front surface based on the pulse signals received from the encoder branch board 16 (For a specific generation method, refer to Japanese Patent No. 3811565), and 100% inspection (inspection for all printed matter) is performed using the high resolution image. Similarly, the back image processing board 121B and the back image processing board 122B also receive camera signals from the back camera 31B via the back camera branch board 15, and perform 100% inspection.

パイプライン画像処理部12は、第1実施形態と同様に、全数検査において被検査画像と基準画像を比較する検査を行うに当たり、比較を適切に行えるように両画像の位置合わせを行う。そのために、パイプライン画像処理部12は、画像を複数のブロックに分割し、ブロック毎に両画像のズレ量を算出するズレ量算出処理を行う。   As in the first embodiment, the pipeline image processing unit 12 aligns both images so that the comparison can be appropriately performed when performing an inspection for comparing the inspection image and the reference image in the exhaustive inspection. Therefore, the pipeline image processing unit 12 divides the image into a plurality of blocks, and performs a shift amount calculation process of calculating the shift amount of both images for each block.

被印刷物がカットシートの一例である枚葉紙である第2実施形態では、印刷がなされたそれぞれの枚葉紙をカメラ31で次々に撮影すると、各枚葉紙が不規則な方向(縦方向、横方向或いは回転方向)にズレて撮影されるため、連続する被検査画像の向きも不規則となる。一ブロックについて二枚のテンプレート画像を作成して、二枚のテンプレート画像により被検査画像の対応するブロック内をサーチする。なお、テンプレート画像の作成処理については、フローチャートを用いて後述する。一方、連続する被検査画像の向き(ズレ)に関連性があり、且つ、印刷速度が速く全数検査にも速度が求められる第1実施形態では、上述したように、一ブロックについて一枚のテンプレート画像により位置合わせを行う。   In the second embodiment in which the printed material is a sheet as an example of a cut sheet, when the printed sheets are photographed one after another by the camera 31, the individual sheets have irregular directions (longitudinal direction Because the image is captured with a shift in the lateral direction or the rotational direction, the direction of the continuous inspection image also becomes irregular. Two template images are created for one block, and two template images search the corresponding block of the inspection image. The process of creating a template image will be described later using a flowchart. On the other hand, in the first embodiment, in which the orientation (shift) of consecutive inspection images is related and the printing speed is high and the speed is also required for 100% inspection, as described above, one template for one block is used. Align with the image.

パイプライン画像処理部12は、テンプレート画像の作成処理において、特徴部の少ないブロックについてはテンプレート画像を二枚作成できない場合がある。パイプライン画像処理部12は、テンプレート画像を二枚作成できたブロック(「テンプレート有りブロック」)については、二枚のテンプレート画像に基づいてズレ量を算出する(2つの一致点についてズレ量を算出し、その平均をそのブロックのズレ量とする)一方、テンプレート画像を作成できなかったブロック(「テンプレート無しブロック」)については、ズレ量が決定している上下左右のブロック又は同行/同列のブロックのズレ量に基づいてズレ量を決定する。   The pipeline image processing unit 12 may not be able to create two template images for a block having a small number of feature portions in the template image creation processing. The pipeline image processing unit 12 calculates the amount of deviation based on the two template images for the block in which two sheets of template images can be created ("block with template") (calculates the amount of deviation for two coincident points) And the average is taken as the shift amount of that block). On the other hand, for the block where the template image can not be created (“block without template”), the block of the top, bottom, left and right or the same row The amount of deviation is determined based on the amount of deviation of

また、パイプライン画像処理部12は、ブロック毎にテンプレート画像と被検査画像を比較する際には、被検査画像についてもブロック毎にテンプレート画像と同様の手法によりブロック画像を作成し、テンプレート画像により、対応するブロック画像内をサーチすることにより一致する箇所を探索する。このように同様の手法で作成した画像同士を比較することで、より正確に一致点を探索することができる。   Also, when comparing the template image and the inspection image for each block, the pipeline image processing unit 12 creates a block image for the inspection image by the same method as the template image for each block, and uses the template image Search for a matching location by searching in the corresponding block image. As described above, by comparing the images created by the same method, it is possible to search for a matching point more accurately.

パイプライン画像処理部12は、ブロック毎に算出したズレ量に基づいて被検査画像の位置補正を行うことにより、基準画像と被検査画像の位置合わせを行う。   The pipeline image processing unit 12 performs position correction of the image to be inspected based on the displacement amount calculated for each block, thereby aligning the reference image and the image to be inspected.

[2.2.枚葉紙用テンプレート画像作成処理の動作]
図17を用いて、パイプライン画像処理部12による枚葉紙用テンプレート画像作成処理について説明する。なお、図17は、枚葉紙用テンプレート画像作成処理の一例を示すフローチャートである。
[2.2. Operation of Template Image Creation Processing for Sheet Sheets]
The sheet template image creation processing by the pipeline image processing unit 12 will be described using FIG. 17. FIG. 17 is a flowchart showing an example of the sheet template image creation processing.

枚葉紙用テンプレート画像作成処理の冒頭の処理は、連続シート用テンプレート画像作成処理(図3参照)のステップS1〜ステップS16と同様である。   The process at the beginning of the sheet template image creation process is the same as steps S1 to S16 of the continuous sheet template image creation process (see FIG. 3).

パイプライン画像処理部12は、ステップS16の処理を終えると、次いで、ステップS4の処理で分割した一のブロックを選択する(ステップS201)。   After completing the process of step S16, the pipelined image processing unit 12 next selects one block divided in the process of step S4 (step S201).

次に、パイプライン画像処理部12は、ステップS17の処理で選択したブロック内に「テンプレート適性有り」と判定したXYアドレスがないかサーチする(ステップS202)。具体的には、ブロック内の始点(例えば、左下隅)からX方向に一画素ずつずらしながら「テンプレート適性有り」と判定したXYアドレスがないかサーチする。ブロック端までいっても見つからない場合には、Y方向に1画素ずらし再度、X方向に一画素ずつずらしながら「テンプレート適性有り」と判定したXYアドレスがないかサーチする。「テンプレート適性有り」と判定したXYアドレスが2つ見つかった時点でサーチを終了する。   Next, the pipelined image processing unit 12 searches the block selected in the process of step S17 for an XY address determined to be “with template suitability” (step S202). Specifically, it is searched whether or not there is an XY address determined as “with template suitability” while shifting one pixel at a time in the X direction from the start point (for example, the lower left corner) in the block. If the block end is not found, the pixel is shifted by one pixel in the Y direction, and while shifting the pixel by one pixel in the X direction again, a search is made for an XY address determined to be "template appropriate". The search is ended when two XY addresses determined to be "appropriate for template" are found.

そして、パイプライン画像処理部12は、ブロック内に「テンプレート適性有り」のXYアドレスが2つあったか否かを判定する(ステップS203)。パイプライン画像処理部12は、「テンプレート適性有り」のXYアドレスが2つなかったと判定した場合には(ステップS203:NO)、当該ブロックを「テンプレート無しブロック」と判定し(ステップS204)、ステップS210の処理に移行する。一方、パイプライン画像処理部12は、「テンプレート適性有り」のXYアドレスが2つあったと判定した場合には(ステップS203:YES)、当該ブロックを「テンプレート有りブロック」と判定し(ステップS205)、ステップS206の処理に移行する。   Then, the pipeline image processing unit 12 determines whether or not there are two XY addresses of “with template suitability” in the block (step S203). If the pipeline image processing unit 12 determines that two XY addresses “with template suitability” are not present (step S203: NO), the pipeline image processing unit 12 determines that the block is “block without template” (step S204). It transfers to the process of S210. On the other hand, when the pipeline image processing unit 12 determines that there are two XY addresses of “template appropriate” (step S203: YES), the pipeline image processing unit 12 determines that the block is a “template present block” (step S205). Then, the process proceeds to step S206.

次に、パイプライン画像処理部12は、連続シート用テンプレート画像作成処理のステップS22と同様に、A画像を階調((a+b)/2)(本実施形態では「(90+130)/2=110」)で二値化した画像に対して、連続シート用テンプレート画像作成処理のステップS11〜ステップS13の処理においてB画像について行ったのと同様の処理を行い、D画像を生成する(ステップS206)。   Next, as in step S22 of the continuous sheet template image creation process, the pipeline image processing unit 12 applies the gradation ((a + b) / 2) ((90 + 130) / 2 in the present embodiment) to the A image. The same processing as that performed for the B image in the processing of steps S11 to S13 of the continuous sheet template image creation processing is performed on the image binarized at = 110 ′ ′) to generate a D image (step S206).

次に、パイプライン画像処理部12は、D画像から、「テンプレート適性有り」のXYアドレスを中心とする32画素×32画素を切り出し、テンプレート画像(D’画像)を生成する(ステップS207)。なお、第2実施形態では一のブロックにつき「テンプレート適性有り」のXYアドレスは2つあるので、パイプライン画像処理部12は、それぞれについてステップS207の処理を行い、2枚のテンプレート画像(D’画像)を生成する。   Next, the pipeline image processing unit 12 cuts out 32 pixels × 32 pixels centered on the XY address of “with template suitability” from the D image, and generates a template image (D ′ image) (step S207). In the second embodiment, since there are two XY addresses “with template suitability” for one block, the pipeline image processing unit 12 performs the process of step S207 for each of the two template images (D ′ Generate an image).

次に、パイプライン画像処理部12は、テンプレート画像(D’画像)のチェックを行う(ステップS208)。このチェックでは、テンプレート検証範囲(テンプレート画像(D’画像)の中心アドレスを基準とするX方向±64画素、Y方向±128画素の範囲)内を、D’画像を1画素ずつずらしていき、何れの位置でも(但し、中心アドレスを除く)D画像とD’画像の差分が1画素以上あることを検証する。すなわち、テンプレート画像(D’画像)がその周囲(テンプレート検証範囲内)でユニークであることを検証する。なお、第2実施形態では一のブロックにつきD’画像は2枚あるので、パイプライン画像処理部12は、ステップS208の処理においてそれぞれのD’画像について検証を行う。   Next, the pipeline image processing unit 12 checks the template image (D 'image) (step S208). In this check, the D 'image is shifted by one pixel at a time in the template verification range (a range of ± 64 pixels in the X direction and ± 128 pixels in the Y direction with respect to the center address of the template image (D ′ image)). It is verified that at any position (except for the center address), the difference between the D image and the D 'image is at least one pixel. That is, it is verified that the template image (D 'image) is unique around it (within the template verification range). In the second embodiment, since there are two D 'images per block, the pipeline image processing unit 12 verifies each D' image in the process of step S208.

そして、パイプライン画像処理部12は、チェックの結果、テンプレート検証範囲内でテンプレート画像(D’画像)がユニークでない場合には、当該テンプレート画像(D’画像)は不合格として、他の画像と差し替えるためにステップS202に戻り、同じブロック内の他の「テンプレート適性有り」のXYアドレスをサーチし、当該XYアドレスについて、ステップS203〜ステップS208の処理を行う。ステップS202〜ステップS208の処理を2回やり直しても、2枚のテンプレート画像(D’画像)が合格とならない場合には、ステップS204の処理に移行する。一方、パイプライン画像処理部12は、チェックの結果、テンプレート検証範囲内でテンプレート画像(D’画像)がユニークである場合には合格とする。パイプライン画像処理部12は、2枚のテンプレート画像(D’画像)が合格である場合には、ステップS209の処理に移行する。   Then, as a result of the check, when the template image (D ′ image) is not unique within the template verification range, the pipeline image processing unit 12 rejects the template image (D ′ image) and determines that the template image (D ′ image) is rejected. In order to replace, the process returns to step S202, another "template suitability" XY address in the same block is searched, and the process of step S203 to step S208 is performed on the XY address. If the two template images (D 'images) do not pass even if the processes in steps S202 to S208 are repeated twice, the process proceeds to step S204. On the other hand, the pipeline image processing unit 12 passes if the template image (D ′ image) is unique within the template verification range as a result of the check. When the two template images (D 'images) pass, the pipeline image processing unit 12 proceeds to the process of step S209.

次に、パイプライン画像処理部12は、直近のステップS201の処理で選択した一のブロックの識別情報(例えば、ブロックID)と、2枚のテンプレート画像(D’画像)と、各テンプレート画像(D’画像)の中心アドレスと、その平均座標と、ブロックの中心アドレスとを、対応付けてテンプレートテーブル(図示しない)に登録し(ステップS209)、ステップS210の処理に移行する。   Next, the pipeline image processing unit 12 identifies the identification information (for example, block ID) of one block selected in the process of the most recent step S201, two template images (D 'images), and each template image ( The center address of the D ′ image), the average coordinates thereof, and the center address of the block are associated with each other and registered in a template table (not shown) (step S 209), and the process proceeds to step S 210.

パイプライン画像処理部12は、ステップS204又はステップS209の処理を終えると、次いで、全てのブロックを選択したか否かを判定する(ステップS210)。すなわち、パイプライン画像処理部12は、ステップS4の処理で分割した全ブロックをステップS201の処理により選択したか否かを判定する。このとき、パイプライン画像処理部12は、全てのブロックを選択していないと判定した場合には(ステップS210:NO)、ステップS201の処理に移行し、それまでに選択していない一のブロックを選択する。そして、全てのブロックを選択するまで、ステップS201〜ステップS210の処理を繰り返す。一方、パイプライン画像処理部12は、全てのブロックを選択したと判定した場合には(ステップS210:YES)、枚葉紙用テンプレート画像作成処理を終了する。   After completing the process of step S204 or step S209, the pipelined image processing unit 12 then determines whether all blocks have been selected (step S210). That is, the pipelined image processing unit 12 determines whether all the blocks divided in the process of step S4 have been selected by the process of step S201. At this time, when the pipeline image processing unit 12 determines that all the blocks have not been selected (step S210: NO), the process proceeds to step S201, and one block which has not been selected so far Choose And the process of step S201-step S210 is repeated until all the blocks are selected. On the other hand, when determining that all the blocks have been selected (step S210: YES), the pipeline image processing unit 12 ends the sheet template image creation processing.

第2実施形態において、パイプライン画像処理部12は、A画像を階調aで二値化したB画像と、A画像を階調bで二値化したC画像のそれぞれから切り出し画像(B’画像及びC’画像)を比較して、差分が一定の範囲(1画素〜8画素)である場合に、B’画像及びC’画像を切り出した際のXYアドレスをテンプレートの適性有りと判断とする。これにより、一定の階調の範囲(階調a〜bの範囲)の特徴点を見つけることができる。また、パイプライン画像処理部12は、A画像を階調(a+b)/2で二値化したD画像から、テンプレート適性有りと判断したXYアドレスに基づいて、テンプレート画像(D’画像)を2枚生成する。これにより、被検査画像の階調が階調a〜bの範囲で変化してもテンプレート画像(D’画像)と適切にマッチングすることができ、また、一ブロック当たり、2枚のテンプレート画像によりズレ量を算出して位置補正を行うことから、第1実施形態より高精度に位置補正を行うことができる。   In the second embodiment, the pipelined image processing unit 12 extracts an image (B ′ from the B image obtained by binarizing the A image with gradation a and the C image obtained by binarizing the A image with gradation b (B ′ Compare the image and the C 'image, and if the difference is within a certain range (1 pixel to 8 pixels), determine the XY address at the time of cutting out the B' image and the C 'image as the suitability of the template Do. This makes it possible to find feature points in a certain gradation range (a range of gradations a to b). The pipeline image processing unit 12 also generates a template image (D 'image) 2 based on the XY address determined to be template suitability from the D image obtained by binarizing the A image with gradation (a + b) / 2. Generate a sheet. Thereby, even if the gradation of the inspection image changes in the range of gradations a to b, matching with the template image (D 'image) can be appropriately performed, and two template images per block can be used. Since the displacement amount is calculated and the position correction is performed, the position correction can be performed with higher accuracy than in the first embodiment.

[2.3.枚葉紙検査処理の動作]
次に、図18を用いて、パイプライン画像処理部12による枚葉紙検査処理について説明する。なお、図18は、枚葉紙検査処理の一例を示すフローチャートである。枚葉紙検査処理は、基準画像と被検査画像の比較処理を行う全数検査である。
[2.3. Operation of sheet inspection process]
Next, a sheet inspection process by the pipeline image processing unit 12 will be described with reference to FIG. FIG. 18 is a flowchart showing an example of the sheet inspection process. The sheet inspection process is a 100% inspection that compares the reference image and the inspection image.

まず、パイプライン画像処理部12は、枚葉紙・ズレ量算出処理を行う(ステップS231)。なお、枚葉紙・ズレ量算出処理については後述する。   First, the pipeline image processing unit 12 performs sheet / sheet shift amount calculation processing (step S231). The sheet / sheet shift amount calculation process will be described later.

次に、パイプライン画像処理部12は、連続シート検査処理(図14参照)のステップS32〜ステップS34と同様の処理を行い、枚葉紙検査処理を終了する。   Next, the pipeline image processing unit 12 performs the same process as steps S32 to S34 of the continuous sheet inspection process (see FIG. 14), and ends the sheet inspection process.

[2.4.枚葉紙・ズレ量算出処理の動作]
次に、図19を用いて、パイプライン画像処理部12による枚葉紙・ズレ量算出処理について説明する。
[2.4. Operation of sheet / sheet and shift amount calculation processing]
Next, sheet / sheet shift amount calculation processing by the pipeline image processing unit 12 will be described using FIG.

枚葉紙・ズレ量算出処理の冒頭の処理は、連続シート・ズレ量算出処理(図15参照)のステップS51〜ステップS56と同様である。   The process at the beginning of the sheet / sheet shift amount calculation process is the same as steps S51 to S56 of the continuous sheet / displacement amount calculation process (see FIG. 15).

次に、パイプライン画像処理部12は、枚葉紙・テンプレート有りブロック処理を行う(ステップS251)。なお、枚葉紙・テンプレート有りブロック処理については後述する。   Next, the pipeline image processing unit 12 performs block processing with a sheet / template (step S251). The sheet / template / block processing will be described later.

次に、パイプライン画像処理部12は、連続シート・ズレ量算出処理(図15参照)のステップS58〜ステップS60と同様の処理を行い、枚葉紙・ズレ量算出処理を終了する。   Next, the pipeline image processing unit 12 performs the same process as step S58 to step S60 of the continuous sheet / displacement amount calculation process (see FIG. 15), and ends the sheet / displacement amount calculation process.

[2.5.枚葉紙・テンプレート有りブロック処理の動作]
次に、図20を用いて、パイプライン画像処理部12による枚葉紙・テンプレート有りブロック処理について説明する。
[2.5. Operation of block processing with sheet and template]
Next, block processing with a sheet / template with the pipeline image processing unit 12 will be described with reference to FIG.

まず、パイプライン画像処理部12は、枚葉紙用テンプレート画像作成処理のステップS205の処理で「テンプレート有りブロック」として判定した一のブロックを選択する(ステップS301)。   First, the pipeline image processing unit 12 selects one block determined as a “template present block” in the process of step S205 of the sheet template image creation process (step S301).

次に、パイプライン画像処理部12は、テンプレートテーブルから、ステップS301の処理で選択したブロックに含まれるテンプレート画像(D’画像)と中心アドレスを2組取得する(ステップS302)。   Next, the pipeline image processing unit 12 acquires two sets of a template image (D ′ image) and a center address included in the block selected in the process of step S301 from the template table (step S302).

次に、パイプライン画像処理部12は、ステップS302の処理で取得した一組目の中心アドレスを基準とする予め設定された設定範囲(X方向±64画素、Y方向±128画素の範囲)内を、D画像に対して一組目のD’画像を1画素ずつずらしていき、D画像とD’画像の差分を算出する(ステップS303)。   Next, the pipelined image processing unit 12 sets a preset range (a range of ± 64 pixels in the X direction, a range of ± 128 pixels in the Y direction) based on the first set of center addresses acquired in the process of step S302. The first set of D 'images is shifted by one pixel with respect to the D image, and the difference between the D and D' images is calculated (step S303).

次に、パイプライン画像処理部12は、差分が最小であった位置を特定する(ステップS304)。なお、差分が最小である位置が同じ値で複数ある場合には最も中心アドレスに近い位置を一つ特定する。   Next, the pipeline image processing unit 12 specifies the position at which the difference is the smallest (step S304). Note that if there are a plurality of positions with the smallest difference and the same value, one position closest to the center address is identified.

次に、パイプライン画像処理部12は、ステップS302の処理で取得した二組目の中心アドレスを基準とする予め設定された設定範囲(X方向±64画素、Y方向±128画素の範囲)内を、D画像に対して二組目のD’画像を1画素ずつずらしていき、D画像とD’画像の差分を算出する(ステップS305)。   Next, the pipelined image processing unit 12 sets a preset range (a range of ± 64 pixels in the X direction, a range of ± 128 pixels in the Y direction) based on the second set of center addresses acquired in the process of step S302. The second set of D 'images is shifted by one pixel with respect to the D image, and the difference between the D and D' images is calculated (step S305).

次に、パイプライン画像処理部12は、差分が最小であった位置を特定する(ステップS306)。なお、差分が最小である位置が同じ値で複数ある場合には最も中心アドレスに近い位置を一つ特定する。   Next, the pipeline image processing unit 12 specifies the position at which the difference is the smallest (step S306). Note that if there are a plurality of positions with the smallest difference and the same value, one position closest to the center address is identified.

次に、パイプライン画像処理部12は、2つのテンプレート画像(D’画像)についてそれぞれ、ズレ量を算出する(ステップS307)。具体的には、ステップS304の処理で特定した位置と、ステップS302の処理で取得した一組目の中心アドレスの差を一つ目のズレ量(dx1,dy1)として算出し、ステップS306の処理で特定した位置と、ステップS302の処理で取得した二組目の中心アドレスの差を二つ目のズレ量(dx2,dy2)として算出する。   Next, the pipeline image processing unit 12 calculates the amount of deviation for each of the two template images (D 'images) (step S307). Specifically, the difference between the position specified in the process of step S304 and the first set of center addresses acquired in the process of step S302 is calculated as the first shift amount (dx1, dy1), and the process of step S306 is performed. The difference between the position identified in step S2 and the second set of center addresses acquired in the process of step S302 is calculated as a second deviation amount (dx2, dy2).

次に、パイプライン画像処理部12は、ステップS307の処理で算出した2つのズレ量の平均値をそのブロックのズレ量(dx,dy)として決定する(ステップS308)。なお、決定したズレ量は、当該ブロックの識別情報(例えば、ブロックID)と対応付けて記憶させておくものとする。   Next, the pipelined image processing unit 12 determines the average value of the two shift amounts calculated in the process of step S307 as the shift amount (dx, dy) of the block (step S308). The determined amount of displacement is stored in association with identification information (for example, block ID) of the block.

次に、パイプライン画像処理部12は、全ての「テンプレート有りブロック」を選択したか否かを判定する(ステップS309)。このとき、パイプライン画像処理部12は、全ての「テンプレート有りブロック」を選択していないと判定した場合には(ステップS309:NO)、ステップS301の処理に移行し、それまでに選択していない一の「テンプレート有りブロック」を選択する。そして、全ての「テンプレート有りブロック」を選択するまで、ステップS301〜ステップS309の処理を繰り返す。一方、パイプライン画像処理部12は、全ての「テンプレート有りブロック」を選択したと判定した場合には(ステップS309:YES)、枚葉紙・テンプレート有りブロック処理を終了し、枚葉紙・ズレ量算出処理に戻る。   Next, the pipelined image processing unit 12 determines whether or not all “blocks with template” have been selected (step S309). At this time, if the pipeline image processing unit 12 determines that not all “blocks with template” have been selected (step S309: NO), the process proceeds to step S301, and the process has been selected so far. Select one non-template block. Then, the processing of steps S301 to S309 is repeated until all “template present blocks” are selected. On the other hand, if the pipeline image processing unit 12 determines that all the "blocks with template" have been selected (step S309: YES), the block processing with sheet and template ends, and the sheet and slippage are shifted. It returns to quantity calculation processing.

以上説明したように、第1実施形態及び第2実施形態の検査装置T(「特徴画像生成装置」の一例)は、パイプライン画像処理部12(「エッジ抽出部」、「二値化部」、「第1合成部」、「交点取得部」、「第2合成部」、「切り出し画像生成部」、「特徴画像生成部」の一例)が、基準画像からエッジを抽出したA画像(「エッジ画像」の一例)を生成し、A画像を階調b(「第1の階調」の一例)で二値化したC画像(「第1二値化画像」の一例)と、エッジ画像を階調bよりも低い階調a(「第2の階調」の一例)で二値化したB画像(「第2二値化画像」の一例)と、エッジ画像を階調aと階調bの中間の階調で二値化したD画像(「第3二値化画像」の一例)と、を生成し、C画像から水平の直線を抽出したC1画像(「第1水平画像」の一例)と、C画像から垂直の直線を抽出したC2画像(「第1垂直画像」の一例)を合成し、C3画像(「第1合成画像」の一例)を生成し、C3画像における水平の直線と垂直の直線のXYアドレス(「交点座標」の一例)を取得し、B画像から水平の直線を抽出したB1画像(「第2水平画像」の一例)と、B画像から垂直の直線を抽出したB2画像(「第2垂直画像」の一例)を合成し、B3画像(「第2合成画像」の一例)を生成し、C3画像及びB3画像からXYアドレスを含む画像を切り出して、それぞれC’画像(「第1切り出し画像」の一例)及びB’画像(「第2切り出し画像」の一例)を生成し、C’画像とB’画像の差分画素数が1画素から8画素の範囲内である場合(「所定の条件を満たす場合」の一例)に、D画像からXYアドレスを含む画像を切り出したテンプレート画像(D’画像。「特徴画像」の一例)を生成する。   As described above, the inspection apparatus T (an example of the “feature image generation apparatus”) according to the first and second embodiments includes the pipeline image processing unit 12 (“edge extraction unit”, “binarization unit”) , An example of an edge image extracted from the reference image by the “first combining unit”, the “intersection obtaining unit”, the “second combining unit”, the “cut-out image generating unit”, and the “feature image generating unit”; C image (an example of “first binarized image”) obtained by generating “an edge image” and binarizing the A image with gradation b (an example of “first gradation”), and an edge image Of a B image (an example of a “second binarized image”) binarized with a gradation a (an example of a “second gradation”) lower than the gradation b C1 image (“first water” generated by generating a D image (an example of “third binarized image”) binarized with an intermediate gradation of tone b and extracting a horizontal straight line from the C image Image) and a C2 image (an example of a "first vertical image") obtained by extracting a vertical straight line from the C image, to generate a C3 image (an example of a "first composite image"), and a C3 image B1 image (an example of "second horizontal image") obtained by acquiring the XY addresses (an example of "intersection coordinates") of the horizontal straight line and the vertical straight line in the image B and the horizontal straight line extracted from the B image The B2 image (an example of the "second vertical image") from which the straight line is extracted is synthesized, the B3 image (an example of the "second synthesized image") is generated, and the image including the XY address is cut out from the C3 image and the B3 image To generate the C 'image (an example of the "first cutout image") and the B' image (an example of the "second cutout image"), and the difference pixel number between the C 'image and the B' image is 1 pixel to 8 In the case of being within the range of pixels (in the case of satisfying a predetermined condition) To generate a template image cut out an image including an XY address from D images (D 'image. An example of the "feature image").

したがって、検査装置Tによれば、基準画像からエッジを抽出したA画像を、階調bで二値化した画像から得られたC’画像と、エッジ画像を階調aで二値化した画像から得られたB’画像の差分画素数が1画素から8画素の範囲内である場合に、A画像を階調aと階調bの中間の階調で二値化したD画像から同じ位置を切り出してテンプレート画像(D’画像)とすることから、基準画像と比較する比較画像のエッジ画像における階調が階調bと階調aの間であれば、基準画像と被検査画像の位置合わせを行うことができる。すなわち、高解像度の基準画像と被検査画像の位置合わせを行うためのマッチングに用いるテンプレート画像(D’画像)を基準画像から適切に生成することができる。   Therefore, according to the inspection apparatus T, the image A obtained by extracting the edge from the reference image, the image C ′ obtained from the image obtained by binarizing with the tone b, and the image obtained by binarizing the edge image with the tone a The same position from the D image obtained by binarizing the A image at a middle gradation between the gradation a and the gradation b when the number of difference pixels of the B ′ image obtained from is within the range of 1 pixel to 8 pixels. Of the edge image of the comparison image to be compared with the reference image if the gradation is between the gradation b and the gradation a, the positions of the reference image and the inspection image It can be done. That is, a template image (D 'image) used for matching for aligning the high-resolution reference image and the inspection image can be appropriately generated from the reference image.

このように、階調aと階調bで二値化した画像(B画像とC画像)の双方で検出されるエッジに基づいてテンプレート画像(D’画像)を生成することから、被検査画像全体の階調が印刷過程で低下するなどの変化があっても、テンプレート画像を生成する際の基となったエッジはその階調が階調a〜bの範囲内で変化する分には検出可能となるため位置補正を行うことができる。すなわち、階調a〜bの範囲内でエッジ部の階調変化があっても適切に位置合わせが行われることが保証される。仮に1つの階調で二値化した画像で検出されるエッジに基づいてテンプレート画像を生成した場合、当該エッジが何れの階調の範囲で検出可能かが不明であり、印刷過程で当該エッジの階調が検出不可能な階調に変化にすると突然に位置合わせを行うことができなくなり、検査を停止せざるを得なくなる。   As described above, since the template image (D ′ image) is generated based on the edge detected in both the image (B image and C image) binarized with the gradation a and the gradation b, the inspection image Even if there is a change such as a decrease in the entire gradation in the printing process, the edge on which the template image is generated is detected when the gradation changes within the range of gradation a to b. Position correction can be performed because this becomes possible. That is, it is ensured that the alignment is properly performed even if there is a tone change of the edge portion within the range of the tones a to b. If a template image is generated based on an edge detected in an image binarized with one gradation, it is unclear in which gradation range the relevant edge can be detected, and the printing process does not If the gray level changes to an undetectable gray level, alignment can not be performed suddenly and the inspection must be stopped.

なお、検査装置Tのパイプライン画像処理部12は、基準画像からエッジを抽出したA画像を生成し、A画像を階調bで二値化したC画像と、エッジ画像を階調bよりも低い階調aで二値化したB画像と、エッジ画像を階調aと階調bの間の階調で二値化したD画像と、を生成し、C画像における水平の直線と垂直の直線のXYアドレス(「交点座標」の一例)を取得し、C画像及びB画像からXYアドレスを含む画像を切り出して、それぞれC’画像(「第1切り出し画像」の一例)及びB’画像(「第2切り出し画像」の一例)を生成し、C’画像とB’画像の差分画素数が1画素から8画素の範囲内である場合(「所定の条件を満たす場合」の一例)に、D画像からXYアドレスを含む画像を切り出したテンプレート画像(D’画像。「特徴画像」の一例)を生成することとしてもよい。   The pipeline image processing unit 12 of the inspection apparatus T generates an A image in which the edge is extracted from the reference image, and the C image obtained by binarizing the A image with gradation b and the edge image more than gradation b A B image binarized with low gradation a and a D image binarized with gradation between gradation a and gradation b are generated, and the horizontal straight line and vertical in the C image are generated. Acquire the XY address (an example of “intersection coordinates”) of a straight line, cut out an image including the XY address from the C image and the B image, and respectively obtain a C ′ image (an example of “first cut image”) and a B ′ image An example of the “second cut-out image” is generated, and the difference pixel number between the C ′ image and the B ′ image is in the range of 1 pixel to 8 pixels (an example of “when the predetermined condition is satisfied”) Template image (D 'image) which cut out the image containing XY address from D image. It may be generated an example) of a feature image. "

また、第1実施形態及び第2実施形態の検査装置Tは、パイプライン画像処理部12(「分割部」の一例)が基準画像を複数ブロックに分割し、ブロック毎にテンプレート画像(D’画像)を生成する。これにより、基準画像と被検査画像についてブロック毎にズレ量を算出することができ、延いてはブロック毎に位置合わせを行うことができる。   Further, in the inspection apparatus T according to the first and second embodiments, the pipeline image processing unit 12 (an example of the “division unit”) divides the reference image into a plurality of blocks, and the template image (D ′ image) Generate). As a result, the shift amount can be calculated for each block for the reference image and the inspection image, and alignment can be performed for each block.

更に、第1実施形態の検査装置Tは、パイプライン画像処理部12が、基準画像が連続シートを長手方向に沿って搬送している際に当該連続シートの一部を撮影した画像である場合に、一のブロックに対して一つのテンプレート画像(D’画像)を生成する。   Furthermore, in the inspection apparatus T according to the first embodiment, the pipeline image processing unit 12 is an image obtained by capturing a part of the continuous sheet while the reference image transports the continuous sheet in the longitudinal direction. Then, one template image (D 'image) is generated for one block.

更にまた、第2実施形態の検査装置Tは、パイプライン画像処理部12が、基準画像が枚葉紙(「カットシート」の一例)を撮影した画像である場合に、一のブロックに対して二つのテンプレート画像(D’画像)を生成する。枚葉紙を印刷後に撮像する場合、枚葉紙は縦方向、横方向、回転方向に不規則にズレるが、第2実施形態の検査装置Tによれば、一ブロック当たり2枚のテンプレート画像によりズレ量を算出することから、高精度に位置合わせをすることができる。   Furthermore, in the inspection apparatus T according to the second embodiment, when the pipeline image processing unit 12 is an image obtained by capturing a sheet of paper (an example of a “cut sheet”), one block is processed for one block. Generate two template images (D 'images). When imaging a sheet after printing, the sheet is irregularly displaced in the longitudinal direction, the lateral direction, and the rotational direction, but according to the inspection apparatus T of the second embodiment, two template images per block are used. Since the shift amount is calculated, alignment can be performed with high accuracy.

更にまた、第1実施形態及び第2実施形態の検査装置Tは、パイプライン画像処理部12(「判定部」の一例)が、D画像におけるXYアドレスを基準とするテンプレート検証範囲(「検証領域内」の一例)を、テンプレート画像(D’画像)を移動させつつD画像と比較し、XYアドレス以外の位置で一致する場合に、テンプレート画像(D’画像)を不適切なテンプレート画像(D’画像)と判定する。これにより、その周囲(テンプレート検証範囲内)に類似する図柄(特徴)のない画像をテンプレート画像(D’画像)として採用することができる。   Furthermore, in the inspection apparatus T according to the first embodiment and the second embodiment, the pipeline image processing unit 12 (an example of the “determination unit”) generates a template verification range (“verification area” based on the XY address in the D image. The template image (D 'image) is inappropriate if the template image (D' image) is compared with the D image while moving the template image (D 'image) and matches at a position other than the XY address 'Image'. Thereby, an image without a pattern (feature) similar to its surroundings (within the template verification range) can be adopted as a template image (D 'image).

なお、印刷物の検査のために行う画像比較処理に限らず、様々な目的で画像比較処理を行うに当たり、一方の画像に歪み、伸び・縮み、回転等が生じるなどの理由から適切に比較を行うことができない場合に、両画像の位置合わせを行うために本発明のズレ量算出処理を利用することができる。   In addition, when performing image comparison processing for various purposes as well as image comparison processing performed for inspection of printed matter, comparison is appropriately performed because one of the images is distorted, stretched, shrunk, or the like. When it is not possible, the shift amount calculation process of the present invention can be used to align the two images.

また、第1実施形態及び第2実施形態において階調aと階調bの真ん中の階調((a+b)/2)で二値化した画像(D画像)に基づいてテンプレート画像(D’画像)を生成することとしたが、必ずしも真ん中の階調で二値化した画像に基づいてテンプレート画像を生成しなくてもよい。テンプレート画像を切り出す画像(D画像)は、真ん中の階調より高低にずらした階調で二値化した画像であってもよいし、印刷過程で被検査画像の階調が低下することが想定されるのであれば、真ん中よりも高めの階調で二値化した画像であってもよい。   In the first embodiment and the second embodiment, a template image (D ′ image) is generated based on an image (D image) binarized by the middle gradation ((a + b) / 2) of the gradation a and the gradation b in the first embodiment and the second embodiment. However, the template image may not necessarily be generated based on the image binarized at the middle gradation. The image from which the template image is cut out (D image) may be an image binarized with gradations shifted to a higher or lower than the middle gradation, and it is assumed that the gradation of the image to be inspected is lowered in the printing process As long as it is possible, it may be an image binarized with a higher tone than the middle.

T 検査装置
11 システムコントローラ
12 パイプライン画像処理部
13 並列画像処理部
14 表カメラ分岐ボード
15 裏カメラ分岐ボード
16 エンコーダ分岐ボード
17 HUB
31A 表面カメラ
31B 裏面カメラ
32A 表面照明
32B 裏面照明
33 エンコーダ
S オフセット輪転印刷機
U1−U4 印刷ユニット
U5 乾燥機
U6 折り機
T inspection apparatus 11 system controller 12 pipeline image processing unit 13 parallel image processing unit 14 front camera branch board 15 back camera branch board 16 encoder branch board 17 HUB
31A front camera 31B back camera 32A front lighting 32B back lighting 33 encoder S web offset printing press U1-U4 printing unit U5 dryer U6 folding machine

Claims (10)

基準画像からエッジを抽出したエッジ画像を生成するエッジ抽出部と、
前記エッジ画像を第1の階調で二値化した第1二値化画像と、前記エッジ画像を前記第1の階調よりも低い第2の階調で二値化した第2二値化画像と、前記エッジ画像を前記第1の階調と前記第2の階調の間の第3の階調で二値化した第3二値化画像と、を生成する二値化部と、
前記第1二値化画像における水平の直線と垂直の直線の交点座標を取得する交点取得部と、
前記第1二値化画像及び前記第2二値化画像から前記交点座標を含む画像を切り出して、それぞれ第1切り出し画像及び第2切り出し画像を生成する切り出し画像生成部と、
前記第1切り出し画像と第2切り出し画像の差分画素数が所定の条件を満たす場合に、前記第3二値化画像から前記交点座標を含む画像を切り出した特徴画像を生成する特徴画像生成部と、
を備えることを特徴とする特徴画像生成装置。
An edge extraction unit that generates an edge image in which an edge is extracted from a reference image;
A first binarized image obtained by binarizing the edge image with a first tone, and a second binarized image obtained by binarizing the edge image with a second tone lower than the first tone A binarization unit configured to generate an image and a third binarized image obtained by binarizing the edge image at a third gradation between the first gradation and the second gradation;
An intersection acquiring unit that acquires intersection coordinates of a horizontal straight line and a vertical straight line in the first binarized image;
A cutout image generation unit that cuts out an image including the intersection coordinates from the first binarized image and the second binarized image, and generates a first cutout image and a second cutout image, respectively.
A feature image generation unit that generates a feature image obtained by cutting out an image including the intersection coordinates from the third binarized image, when the difference pixel number between the first cutout image and the second cutout image satisfies a predetermined condition; ,
A feature image generating apparatus comprising:
請求項1に記載の特徴画像生成装置であって、
前記第1二値化画像から水平の直線を抽出した第1水平画像と、前記第1二値化画像から垂直の直線を抽出した第1垂直画像を合成し、第1合成画像を生成する第1合成部と、
前記第2二値化画像から水平の直線を抽出した第2水平画像と、前記第2二値化画像から垂直の直線を抽出した第2垂直画像を合成し、第2合成画像を生成する第2合成部と、
を更に備え、
前記交点取得部は、
前記第1二値化画像から生成された前記第1合成画像に基づいて、前記交点座標を取得し、
前記切り出し画像生成部は、
前記第1二値化画像から生成された前記第1合成画像及び前記第2二値化画像から生成された前記第2合成画像から、それぞれ前記第1切り出し画像及び前記第2切り出し画像を生成することを特徴とする特徴画像生成装置。
The feature image generation apparatus according to claim 1, wherein
A first horizontal image in which a horizontal straight line is extracted from the first binarized image and a first vertical image in which a vertical straight line is extracted from the first binarized image to generate a first combined image; 1 synthesis unit,
A second horizontal image obtained by extracting a horizontal straight line from the second binarized image and a second vertical image obtained by extracting a vertical straight line from the second binarized image to generate a second composite image 2 synthesis unit,
And further
The intersection acquisition unit
Acquiring the intersection coordinates based on the first composite image generated from the first binarized image;
The cutout image generation unit
Generating the first clipped image and the second clipped image from the first composite image generated from the first binarized image and the second composite image generated from the second binarized image A feature image generating apparatus characterized in that.
請求項2に記載の特徴画像生成装置であって、
前記第1合成部は、前記第1二値化画像から水平の直線を抽出し、水平方向に拡大させた前記第1水平画像と、前記第1二値化画像から垂直の直線を抽出し、垂直方向に拡大させた前記第1垂直画像を合成し、前記第1合成画像を生成し、
前記第2合成部は、前記第2二値化画像から水平の直線を抽出し、水平方向に拡大させた前記第2水平画像と、前記第2二値化画像から垂直の直線を抽出し、垂直方向に拡大させた前記第2垂直画像を合成し、前記第2合成画像を生成することを特徴とする特徴画像生成装置。
The feature image generation apparatus according to claim 2,
The first combining unit extracts a horizontal straight line from the first binarized image, and extracts a vertical straight line from the first horizontal image expanded in the horizontal direction and the first binarized image. Combining the first vertically magnified image in the vertical direction to generate the first combined image;
The second combining unit extracts a horizontal straight line from the second binarized image, and extracts a vertical straight line from the second horizontal image expanded in the horizontal direction and the second binarized image. A feature image generating apparatus, comprising: synthesizing the second vertical image enlarged in the vertical direction; and generating the second combined image.
請求項1乃至3の何れか一項に記載の特徴画像生成装置であって、
前記基準画像を複数のブロックに分割する分割部を更に備え、
前記交点取得部は、前記ブロック毎に交点座標を取得し、
前記切り出し画像生成部は、前記ブロック毎に前記第1切り出し画像及び第2切り出し画像を生成し、
前記特徴画像生成部は、前記ブロック毎に前記特徴画像を生成することを特徴とする特徴画像生成装置。
The feature image generation apparatus according to any one of claims 1 to 3, wherein
The image processing apparatus further comprises a division unit that divides the reference image into a plurality of blocks,
The intersection acquisition unit acquires intersection coordinates for each of the blocks.
The cutout image generation unit generates the first cutout image and the second cutout image for each of the blocks,
The feature image generating device is characterized in that the feature image is generated for each of the blocks.
請求項4に記載の特徴画像生成装置であって、
前記基準画像が連続シートを長手方向に沿って搬送している際に当該連続シートの一部を撮影した画像である場合に、一の前記ブロックに対して一つの特徴画像を生成することを特徴とする特徴画像生成装置。
The feature image generation apparatus according to claim 4, wherein
When the reference image is an image obtained by capturing a part of the continuous sheet while conveying the continuous sheet along the longitudinal direction, one feature image is generated for one block. Feature image generation device to be.
請求項4に記載の特徴画像生成装置であって、
前記基準画像が連続シートを枚葉単位に切断したカットシートを撮影した画像である場合に、一の前記ブロックに対して二つの特徴画像を生成することを特徴とする特徴画像生成装置。
The feature image generation apparatus according to claim 4, wherein
A feature image generating apparatus characterized by generating two feature images for one of the blocks when the reference image is an image obtained by photographing a cut sheet obtained by cutting a continuous sheet into individual sheets.
請求項1乃至6の何れか一項に記載の特徴画像生成装置であって、
前記第3二値化画像における前記交点座標を基準とする検証領域内を、前記特徴画像を移動させつつ第3二値化画像と比較し、前記交点座標以外で一致する場合に、当該特徴画像を不適切な特徴画像と判定する判定部を更に備えることを特徴とする特徴画像生成装置。
The feature image generation apparatus according to any one of claims 1 to 6, wherein
The inside of the verification area on the basis of the intersection coordinates in the third binarized image is compared with the third binarized image while moving the feature image, and in the case where they match other than the intersection coordinates, the characteristic image A feature image generation apparatus, further comprising a determination unit that determines that the image is an inappropriate feature image.
請求項1乃至7の何れか一項に記載の特徴画像生成装置が作成した前記特徴画像を用いて被検査画像の位置補正を行い、前記基準画像と当該被検査画像の比較検査を行う検査装置であって、
前記被検査画像における前記特徴画像に対応する座標を特定し、前記交点取得部が取得した前記交点座標との差であるズレ量を算出するズレ量算出部と、
前記ズレ量に基づいて前記被検査画像の位置補正を行う位置補正部と、
前記位置補正が行われた前記被検査画像と前記基準画像とを比較する比較部と、
を備えることを特徴とする検査装置。
The inspection apparatus which performs position correction of a to-be-inspected image using the said characteristic image which the characteristic image generation apparatus as described in any one of Claims 1 thru | or 7 produced, and compares and checks the said reference image and the said to-be-tested image And
A shift amount calculation unit that specifies coordinates corresponding to the feature image in the inspection image, and calculates a shift amount that is a difference from the intersection coordinates acquired by the intersection acquisition unit;
A position correction unit that corrects the position of the inspection image based on the displacement amount;
A comparison unit that compares the inspection image subjected to the position correction with the reference image;
An inspection apparatus comprising:
基準画像からエッジを抽出したエッジ画像を生成するエッジ抽出工程と、
前記エッジ画像を第1の階調で二値化した第1二値化画像と、前記エッジ画像を前記第1の階調よりも低い第2の階調で二値化した第2二値化画像と、前記エッジ画像を前記第1の階調と前記第2の階調の間の第3の階調で二値化した第3二値化画像と、を生成する二値化工程と、
前記第1二値化画像における水平の直線と垂直の直線の交点座標を取得する交点取得工程と、
前記第1二値化画像及び前記第2二値化画像から前記交点座標を含む画像を切り出して、それぞれ第1切り出し画像及び第2切り出し画像を生成する切り出し画像生成工程と、
前記第1切り出し画像と第2切り出し画像の差分画素数が所定の条件を満たす場合に、前記第3二値化画像から前記交点座標を含む画像を切り出した特徴画像を生成する特徴画像生成工程と、
を含むことを特徴とする特徴画像生成方法。
An edge extraction step of generating an edge image obtained by extracting an edge from a reference image;
A first binarized image obtained by binarizing the edge image with a first tone, and a second binarized image obtained by binarizing the edge image with a second tone lower than the first tone A binarization step of generating an image and a third binarized image in which the edge image is binarized at a third gradation between the first gradation and the second gradation;
An intersection point acquiring step of acquiring an intersection coordinate of a horizontal straight line and a vertical straight line in the first binarized image;
A cutout image generating step of cutting out an image including the intersection coordinates from the first binarized image and the second binarized image, and generating a first cutout image and a second cutout image, respectively;
A feature image generating step of generating a feature image obtained by cutting out an image including the intersection coordinates from the third binarized image, when the number of difference pixels of the first cutout image and the second cutout image satisfies a predetermined condition; ,
A method of generating a feature image comprising:
コンピュータを、
基準画像からエッジを抽出したエッジ画像を生成するエッジ抽出部、
前記エッジ画像を第1の階調で二値化した第1二値化画像と、前記エッジ画像を前記第1の階調よりも低い第2の階調で二値化した第2二値化画像と、前記エッジ画像を前記第1の階調と前記第2の階調の間の第3の階調で二値化した第3二値化画像と、を生成する二値化部、
前記第1二値化画像における水平の直線と垂直の直線の交点座標を取得する交点取得部、
前記第1二値化画像及び前記第2二値化画像から前記交点座標を含む画像を切り出して、それぞれ第1切り出し画像及び第2切り出し画像を生成する切り出し画像生成部、
前記第1切り出し画像と第2切り出し画像の差分画素数が所定の条件を満たす場合に、前記第3二値化画像から前記交点座標を含む画像を切り出した特徴画像を生成する特徴画像生成部、
として機能させることを特徴とする特徴画像生成プログラム。
Computer,
An edge extraction unit that generates an edge image obtained by extracting an edge from a reference image;
A first binarized image obtained by binarizing the edge image with a first tone, and a second binarized image obtained by binarizing the edge image with a second tone lower than the first tone A binarization unit for generating an image and a third binarized image in which the edge image is binarized at a third gradation between the first gradation and the second gradation,
An intersection acquiring unit for acquiring intersection coordinates of a horizontal straight line and a vertical straight line in the first binarized image;
A cutout image generation unit that cuts out an image including the intersection coordinates from the first binary image and the second binary image, and generates a first cutout image and a second cutout image, respectively.
A feature image generation unit that generates a feature image in which an image including the intersection coordinates is cut out from the third binarized image, when the difference pixel number between the first cut-out image and the second cut-out image satisfies a predetermined condition;
A feature image generation program characterized by functioning as
JP2018158436A 2017-10-02 2018-08-27 Feature image generation device, inspection device, feature image generation method, and feature image generation program Active JP6665903B2 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
JP2017193033 2017-10-02
JP2017193033 2017-10-02

Publications (2)

Publication Number Publication Date
JP2019067373A true JP2019067373A (en) 2019-04-25
JP6665903B2 JP6665903B2 (en) 2020-03-13

Family

ID=66340625

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2018158436A Active JP6665903B2 (en) 2017-10-02 2018-08-27 Feature image generation device, inspection device, feature image generation method, and feature image generation program

Country Status (1)

Country Link
JP (1) JP6665903B2 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111062941A (en) * 2019-12-31 2020-04-24 深圳爱克莱特科技股份有限公司 Point light source lamp point fault detection device and method

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH0789063A (en) * 1993-09-24 1995-04-04 Toshiba Corp Printed matter inspecting system
JPH07175926A (en) * 1993-12-20 1995-07-14 Toppan Printing Co Ltd Pattern inspection device
JP2006090921A (en) * 2004-09-27 2006-04-06 Sharp Corp Visual examination device, threshold determining method visual examination method and program for functionalizing computer as visual examination device
JP2007026255A (en) * 2005-07-20 2007-02-01 East Japan Railway Co Method for extracting progress of defective point inside image

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH0789063A (en) * 1993-09-24 1995-04-04 Toshiba Corp Printed matter inspecting system
JPH07175926A (en) * 1993-12-20 1995-07-14 Toppan Printing Co Ltd Pattern inspection device
JP2006090921A (en) * 2004-09-27 2006-04-06 Sharp Corp Visual examination device, threshold determining method visual examination method and program for functionalizing computer as visual examination device
JP2007026255A (en) * 2005-07-20 2007-02-01 East Japan Railway Co Method for extracting progress of defective point inside image

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111062941A (en) * 2019-12-31 2020-04-24 深圳爱克莱特科技股份有限公司 Point light source lamp point fault detection device and method
CN111062941B (en) * 2019-12-31 2024-04-19 深圳爱克莱特科技股份有限公司 Point light source fault detection device and method

Also Published As

Publication number Publication date
JP6665903B2 (en) 2020-03-13

Similar Documents

Publication Publication Date Title
US6874420B2 (en) System and method for register mark recognition
JP2015189216A (en) Inspection apparatus and inspection method
JP2007293809A (en) Displacement detecting device, displacement detecting method, displacement detecting program, and recording medium
JP6180674B1 (en) Image inspection method with multiple cameras
US8359976B2 (en) Method and machine for aligning flexographic printing plates on printing cylinders
JP2007168449A (en) Method for creating reference model designed to be used for automatically checking print quality of image on paper sheet
JP7350637B2 (en) High-speed image distortion correction for image inspection
JP2000113198A (en) Method for automatically inspecting print quality using elastic model
JP6665903B2 (en) Feature image generation device, inspection device, feature image generation method, and feature image generation program
JP5852641B2 (en) Automatic inspection device and alignment method in automatic inspection device
JPH1166381A (en) Method and device for checking valuable or guarantee product, especially bank note
US11135833B2 (en) Method for verifying a printing plate, specifically a gravure cylinder
JP6357864B2 (en) Printing inspection apparatus and printing inspection method
KR100421266B1 (en) Automatic evaluation method by optoelectronic device
JP3768216B2 (en) Printed product inspection apparatus and method
JP5710101B2 (en) Printed matter inspection apparatus and printed matter inspection method
KR101559941B1 (en) A system for detecting fault of print pattern
JP3589756B2 (en) Inspection set value input display method and device for defect inspection
CN114037688A (en) Intelligent printed matter image detection method and system
JPH09226098A (en) Print check method, device therefor and monitoring device for print check device
JPH07249122A (en) Method and device for inspecting picture
JP3557814B2 (en) Image inspection apparatus and method
JPH08138049A (en) Method and device for checking dot character
JPH07200792A (en) Printed matter inspection device
JP2000182114A (en) Watermark inspecting device

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20180827

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20190815

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20190820

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20191002

TRDD Decision of grant or rejection written
A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

Effective date: 20200121

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20200203

R150 Certificate of patent or registration of utility model

Ref document number: 6665903

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150