Image processing device, image processing method, and program

The image processing apparatus addresses the issue of inaccurate defect detection at the ends of printed media by employing region-specific alignment and inspection methods, ensuring reliable detection of defects in both pattern and end regions despite printing position shifts.

JP7716183B2Active Publication Date: 2025-07-31CANON KK
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
JP2020064202
Authority / Receiving Office
JP · JP
Patent Type
Patents
Current Assignee / Owner
Priority Date
2020-02-26
Filing Date
2020-03-31
Publication Date
2025-07-31
Estimated Expiration
2040-03-31

AI Technical Summary

Technical Problem

Existing printing defect inspection systems fail to accurately detect defects at the ends of printed media due to fluctuations in printing position, leading to potential misalignment and incorrect inspection results.

Method used

An image processing apparatus that differentiates between the pattern area and end region of printed media, employing distinct alignment and inspection methods for each area to ensure accurate defect detection, even when printing position shifts occur.

Benefits of technology

Enables precise inspection of printed matter by accurately detecting defects in both the pattern and end regions, enhancing the reliability of defect detection even in the presence of printing position deviations.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure 0007716183000003
    Figure 0007716183000003
  • Figure 0007716183000004
    Figure 0007716183000004
  • Figure 0007716183000005
    Figure 0007716183000005
Patent Text Reader

Abstract

To perform a proper inspection of a printed matter even when print position deviation occurs.SOLUTION: A first image which is a read image of a printed medium to be inspected, and a second image which is a read image of a reference medium showing the target print result are acquired. An inspection for defects in the medium to be inspected is performed based on the first image and the second image. The inspection is performed according to different inspection settings for the print area and the edge area of the medium to be inspected.SELECTED DRAWING: Figure 2
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to a technique for detecting defects in printed matter.

Background Art

[0002] Printed matter output by a printing apparatus may have stains caused by the adhesion of coloring material to unintended locations, or color bleeding caused by insufficient adhesion of coloring material to locations where an image should be formed. By inspecting for the presence or absence of these printing defects, it is required to guarantee the quality of the printed matter. Since visual inspection by an inspector requires a lot of time and cost, in recent years, inspection systems that automatically perform inspection have been proposed. Such an inspection system can detect the presence or absence of printing defects in an object to be inspected based on the difference between a reference image, which is image data of a printed matter showing no defects, and an object image, which is image data of the printed matter to be inspected.

[0003] Generally, due to fluctuations in the printing position associated with misalignment of the media conveyance position in a printing apparatus, or fluctuations in the size of the media associated with misalignment of the cutting position, etc., the positional relationship between the media and the pattern printed on the media varies slightly for each print. Therefore, when automatically inspecting printed matter, it is necessary to perform alignment so that the patterns of the reference image and the object image match. For example, Patent Document 1 discloses an apparatus for inspecting printed matter by comparing a read image of the printed matter with a master image. In Patent Document 1, a read image of a preprint paper before printing and a printed image printed on the preprint paper are aligned with the read image of the printed matter based on reference points such as edge points and then synthesized to obtain a master image.

Prior Art Documents

Patent Documents

[0004]

Patent Document 1

Summary of the Invention

Problems to be Solved by the Invention

[0005] In Citation Document 1, a master image based on print image data used for printing is compared with a read image of a printed matter. However, in order to guarantee the quality of an actual printed matter, it is desirable to use a read image of a printed matter without defects as a reference image. However, when the positional relationship between the medium and the pattern printed on the medium fluctuates as described above, when alignment is performed to match the printed pattern between the target image and the reference image, the position of the end portion of the medium may shift, and the difference in the vicinity of the end portion of the medium may increase. For this reason, there is a possibility that a correct inspection result cannot be obtained at the end portion of the medium.

[0006] An object of the present invention is to appropriately inspect a printed matter even when a printing position shift occurs.

Means for Solving the Problems

[0007] In order to achieve the object of the present invention, an image processing apparatus according to an embodiment of the present invention includes the following configuration. That is, a first image that is a read image of an inspection target medium on which printing has been performed, and In the inspection an acquisition unit that acquires a second image that is a reference image indicating a reference printing result, and defects in the printed area of the inspection target medium are detected by comparing the first image and the second image aligned by a first method, and defects in the end region of the inspection target medium are detected by comparing the first image and the second image aligned by a second method different from the first method an inspection unit, and is provided.

Effects of the Invention

[0008] Even when a printing position shift occurs, an appropriate inspection of the printed matter can be performed.

Brief Description of the Drawings

[0009]

Figure 1

Figure 2

Figure 3

Figure 4

Figure 5

Figure 6

Figure 7

Figure 8

Figure 9

Figure 10

Figure 11

Figure 12

Figure 13

Mode for Carrying Out the Invention

[0010] Hereinafter, embodiments will be described in detail with reference to the accompanying drawings. Note that the following embodiments do not limit the invention according to the claims. Although a plurality of features are described in the embodiments, not all of these plurality of features are essential to the invention, and the plurality of features may be arbitrarily combined. Further, in the accompanying drawings, the same or similar configurations are denoted by the same reference numerals, and redundant descriptions are omitted.

[0011] [Embodiment 1] The image processing apparatus according to Embodiment 1 inspects whether there are defects in the inspection target medium on which printing has been performed. In this embodiment, among the inspection target media, the area where printing has been performed (the area where the colorant is fixed and the pattern is formed, abbreviated as the pattern area) and the area at the end of the medium where no printing has been performed (abbreviated as the end area) are determined, and inspection processing corresponding to the area is selected. According to this embodiment, even when a printing position deviation has occurred, defects at the end of the medium can be detected more accurately.

[0012] (Configuration of the printing system) FIG. 1 is a diagram showing the configuration of an entire printing system that performs output and inspection of printed matter, including the image processing apparatus 100 which is an image processing apparatus according to Embodiment 1. The printing system according to Embodiment 1 includes the image processing apparatus 100 and the printing apparatus 190. The printing system according to Embodiment 1 may further include a printing server 180.

[0013] The printing server 180 generates a printing job including the manuscript to be printed and inputs the printing job to the printing apparatus 190. The printing apparatus 190 forms an image on the printing medium based on the printing job input from the printing server 180. The printing apparatus 190 has a paper feeding unit 191, and the user can supply printing paper to the paper feeding unit 191 in advance. When the printing job is input, the printing apparatus 190 conveys the printing medium supplied to the paper feeding unit 191 along the conveyance path 192, forms an image on one or both sides of the printing medium, and sends it to the image processing apparatus 100.

[0014] The image processing apparatus 100 inspects for defects in a printed print medium (inspection target medium). The inspection target medium is obtained by the printing apparatus 190 forming an image on the print medium and is conveyed through the conveyance path 192 inside the printing apparatus 190. The image processing apparatus 100 may have a CPU 101, a RAM 102, and a ROM 103 inside. Further, the image processing apparatus 100 may have an image reading apparatus 105, a printing apparatus interface (I / F) 106, a general-purpose interface (I / F) 107, a user interface (UI) panel 108, and a main bus 109. Furthermore, the image processing apparatus 100 may have a conveyance path 110 for the print medium connected to the conveyance path 192 of the printing apparatus 190. Also, the image processing apparatus 100 may include an output tray 111 from which the inspection target medium determined to be qualified by the inspection is output, and an output tray 112 from which the inspection target medium determined to be unqualified by the inspection is output. In the example of FIG. 1, the output tray 111 and the output tray 112 are connected to the CPU 101 via the main bus 109. Depending on the inspection result for the inspection target medium, the conveyance destination of the inspection target medium is set to the output tray 111 or the output tray 112.

[0015] The image processing apparatus according to each of the embodiments described later can be realized by a computer including a processor and a memory. For example, a processor such as the CPU 101 can realize the functions of each part shown in FIGS. 2, 6, etc. described later by executing a program stored in a memory such as the RAM 102 or the ROM 103. A processor such as the CPU 101 can also control each module in the image processing apparatus 100 as necessary. Note that the image processing apparatus according to an embodiment of the present invention may be configured by a plurality of processing apparatuses connected via a network, for example.

[0016] The CPU 101 is a processor that controls each part within the image processing apparatus 100. The RAM 102 temporarily holds an application executed by the CPU 101, data used for image processing, or the like. The ROM 103 stores a group of programs executed by the CPU 101.

[0017] The image reading device 105 reads one side or both sides of the print medium sent from the printing device 190 on the conveyance path 110 and acquires it as image data. Since the conveyance path 110 serves as the background when the image reading device 105 reads the image of the print medium, the conveyance path 110 can be configured to have a color (e.g., black) that is easily distinguishable from the print medium on the image. The printing device I / F 106 is connected to the printing device 190, and the image processing device 100 can communicate with the printing device 190 through the printing device I / F 106. For example, through the printing device I / F 106, the printing device 190 and the image processing device 100 can be synchronized and their operating statuses can be notified to each other. The UI panel 108 can output information to the user. The UI panel 108 may be a display device such as a liquid crystal display and can function as a user interface of the image processing device 100. The UI panel 108 can, for example, convey the current status or settings of the image processing device 100 to the user. Further, the UI panel 108 may be provided with an input device such as a touch panel or buttons, and thus can receive instructions from the user. The main bus 109 is a transmission path that connects each module of the image processing device 100.

[0018] While the conveyance path 110 conveys the print medium output from the printing device 190, the image processing device 100 performs an inspection process to examine the presence or absence of defects in the print medium based on the image data of the print medium acquired by the image reading device 105. As a result of the inspection process, if it is determined to be qualified, the print medium is conveyed to the output tray 111. As a result of the inspection process, if it is determined to be unqualified, the print medium is conveyed to the output tray 112. By such an operation, only the print media determined to have no defects are output onto the output tray 111.

[0019] (Functional Configuration of Image Processing Device) FIG. 2 is a block diagram showing the functional configuration of the image processing apparatus 100 according to the present embodiment. The rectangular frames represent the functional modules that perform the respective processes according to the present embodiment, and the arrows indicate the data flow. The configuration in FIG. 2 is an example, and the image processing apparatus 100 according to the present embodiment is not limited to that illustrated in FIG. 2.

[0020] The image acquisition unit 201 acquires a first image that is a read image of the inspection target medium on which printing has been performed, and a second image that is a read image of a reference medium indicating a target printing result. In the present embodiment, the image acquisition unit 201 acquires image data obtained by the image reading device 105 reading the print medium on the conveyance path 110. The image reading device 105 reads the print medium at at least two different times and generates image data of each print medium. Hereinafter, the image obtained by the image reading device 105 reading the reference medium at the first time is referred to as a reference image 301, and the image obtained by reading the inspection target medium after the second time is referred to as a target image 302.

[0021] The region determination unit 202 determines the pattern region 305 and the end region 306 in the reference image 301 and the target image 302 acquired by the image acquisition unit 201. The region determination unit 202 can determine the region to which each pixel of the image data belongs. In the present embodiment, the region determination unit 202 divides the target image 302 into a pattern region 305 and an end region 306. Further, the region determination unit 202 can also divide the reference image 301 into a pattern region 305 and an end region 306.

[0022] The process selection unit 203 sets the inspection to be performed by the inspection processing unit 205 according to the type of the region determined by the region determination unit 202. In the present embodiment, the process selection unit 203 selects the inspection process to be used for each of the pattern region 305 and the end region 306.

[0023] The alignment unit 204 aligns the reference image 301 and the target image 302. The alignment unit 204 can perform alignment of the images according to the luminance of the images. For example, the alignment unit 204 can align the reference image 301 and the target image 302 based on the objects in the images. Specifically, the alignment unit 204 can calculate the parameters of geometric correction such that when geometric correction is performed on one image, the object in one image approaches the object in the other image.

[0024] The alignment unit 204 according to the present embodiment performs alignment of the pattern area 305 of the target image 302 with the reference image 301. For example, the alignment unit 204 can calculate the amount of positional displacement between the images in the pattern area 305 of the target image 302 and the reference image 301 based on the luminance of the pattern area 305 observed from the target image 302 and the reference image 301 respectively. The amount of positional displacement calculated in the present embodiment can include the amount of translation, the amount of rotation, and the amount of enlargement and reduction.

[0025] The inspection processing unit 205 inspects for defects in the inspection target medium based on the reference image 301 and the target image 302. In the present embodiment, the inspection processing unit 205 performs inspection according to different inspection settings for each of the printing area and the end area of the inspection target medium. The inspection settings are performed by the processing selection unit 203. In the present embodiment, for the printing area of the inspection target medium (i.e., the pattern area 305 of the target image 302), the inspection processing unit 205 determines defects based on the comparison between the target image 302 and the reference image 301. For example, the inspection processing unit 205 can calculate the difference between the reference image 301 and the target image 302 in the state aligned by the alignment unit 204 and perform the inspection. The inspection processing unit 205 can determine that the part where the difference between the reference image 301 and the target image 302 is large is the defective part. On the other hand, for the end area of the inspection target medium (i.e., the end area 306 of the target image 302), the inspection processing unit 205 determines defects according to inspection settings different from those of the printing area. The detailed method will be described later.

[0026] (Processing performed by the image processing apparatus) Regarding the processing performed by the image processing apparatus 100 according to this embodiment having the above configuration, the following description will be given. FIG. 3 is a flowchart showing the flow of processing performed by the image processing apparatus 100.

[0027] In step S1010, the image acquisition unit 201 acquires the reference image 301 obtained by the image reading device 105 reading the reference medium on the conveyance path 110 as described above, and stores it in the RAM 102. The reference image 301 is used in subsequent processing for the inspection of each target image 302.

[0028] In step S1020, the image acquisition unit 201 acquires the target image 302 obtained by the image reading device 105 reading the inspection target medium on the conveyance path 110 as described above, and stores it in the RAM 102. In subsequent steps S1030 to 1070, an inspection of the target image 302 acquired in step S1020 is performed.

[0029] The image reading device 105 can generate the reference image 301 by reading the reference medium in step S1010. Also, the image reading device 105 can generate the target image 302 by reading the inspection target medium in step S1020. On the other hand, this embodiment is also applicable when using the reference image 301 or the target image 302 acquired using another device. For example, the reference image 301 or the target image 302 obtained by a device different from the image reading device 105 may be stored in an auxiliary storage device (not shown). In this case, the image acquisition unit 201 can acquire the reference image 301 or the target image 302 from the auxiliary storage device 107 in step S1010 or S1020.

[0030] FIG. 4(A) is a diagram showing an example of a target image 302. The target image 302 includes a print medium area 304 in which the print medium is shown and a background area 303 in which the print medium is not shown. In the example of FIG. 4, the image reading device 105 reads the target image 302 so that the conveyance path 110 appears as a background around the print medium area 304 in order to acquire an image of the entire print medium. Since the conveyance path 110 has a black color in the present embodiment, the background area 303 is black. The reference image 301 also includes a print medium area in which the print medium is shown and a background area in which the print medium is not shown, similarly to the target image 302.

[0031] In step S1030, the area determination unit 202 detects a pattern area 305 and an end area 306 in the target image 302 by performing area determination on the target image 302. In this example, the area determination unit 202 first extracts the print medium area 304 from the target image 302. The area determination unit 202 can extract the print medium area 304 as follows. The area determination unit 202 first binarizes the target image 302 and linearly approximates four sides indicating the contour of the print medium by tracking pixels that are boundaries between white pixels and black pixels. Thus, four straight lines indicating the contour of the print medium area 304 are estimated. Next, the area determination unit 202 calculates the intersection points of the four straight lines. These intersection points correspond to the vertices 308a to 308d of the print medium area 304 shown in FIG. 4(A). However, the method for extracting the print medium area 304 is not limited to the above method, and other methods may be used.

[0032] Next, the area determination unit 202 detects the pattern area 305 and the end area 306 from the print medium area 304 of the target image 302. In the present embodiment, the area determination unit 202 determines to which of the pattern area 305 and the end area 306 each pixel constituting the print medium area 304 belongs. FIG. 4(B) shows the relationship between the target image 302, the print medium area 304, the pattern area 305 (represented as an area where white and a pattern exist in FIG. 4(B)), and the end area 306 (indicated by hatching in FIG. 4(B)). In the example of FIG. 4(B), the inside of the print medium area 304 belongs to either the pattern area 305 or the end area 306.

[0033] In this embodiment, the area determination unit 202 can determine an area within a predetermined distance from the contour of the medium on the reference image 301 or the target image 302 as the end area 306. For example, the area determination unit 202 can extract an area within a predetermined distance from the contour of the print medium area 304 as the end area 306, and extract the other areas as the pattern area 305. The predetermined distance for defining the end area 306 can be referred to as an end margin, and can be set in advance by the user prior to processing.

[0034] The method for detecting the end area 306 is not limited to the above method. For example, the area determination unit 202 can detect an index given to the medium on the reference image 301 or the target image 302, and determine the end area 306 based on the coordinates of the index. As a specific example, when an alignment index such as an arrow is printed on the print medium, the area determination unit 202 may set the end margin based on the coordinates of the alignment index. Also, the end margin may be determined based on the amount of margin or the amount of printing position deviation when the printing device 190 performs printing on the medium on the reference image 301 or the target image 302. For example, the area determination unit 202 may acquire information indicating the average value of the margin size and the printing deviation amount during printing from the printing device 190, and set the total value of the average value of the margin size and the printing deviation amount as the end margin. Further, the area determination unit 202 may determine the blank area of the print medium area 304 as the end area 306 and the other areas as the pattern area 305, respectively.

[0035] Also, in this embodiment, the area determination unit 202 calculates feature information (average luminance in this example) about the end area 306 detected from the reference image 301. This feature information is used in step S1060. Details will be described later.

[0036] The area determination unit 202 can extract the print medium area 304 of the reference image 301 by performing the same processing on the reference image 301, and can also extract the pattern area 305 and the end area 306 of the reference image 301. In step S1010, the image acquisition unit 201 may extract the print medium area 304, the pattern area 305, and the end area 306 of the reference image 301.

[0037] In step S1040, the process selection unit 203 selects the content of the detection process for the pattern area 305 performed in step S1060 and the inspection process for the end area 306 performed in step S1070. In step S1060, a defect determination for the pattern area 305 is performed according to the setting selected by the process selection unit 203. In step S1070, a defect determination for the end area 306 is performed according to the setting selected by the process selection unit 203. The content of the inspection process selected by the process selection unit 203 can be set in advance by the user before the process. In the present embodiment, the process selection unit 203 selects a defect determination process based on the comparison between the reference image 301 and the target image 302 for the pattern area 305, and a defect determination process based on the comparison between the target image 302 and the feature information for the end area 306, respectively.

[0038] In step S1050, the alignment unit 204 aligns the reference image 301 and the target image 302. In the present embodiment, a defect determination process based on the comparison between the reference image 301 and the target image 302 is performed only on the pattern area 305. Therefore, the alignment unit 204 aligns the reference image 301 and the target image 302 based on the pattern area 305.

[0039] Next, an example of the process performed by the alignment unit 204 will be described with reference to FIG. 5 showing an overview of the alignment process. FIG. 5(A) shows a pattern area 305 and reference points 307a to 307c in the reference image 301, and FIG. 5(B) shows a pattern area 305 and reference points 307a to 307c in the target image 302. The reference points 307 are points indicating the same part of the same object in the pattern area 305 in both the reference image 301 and the target image 302, and are also called feature points. In the present embodiment, three reference points 307a to 307c are set and used for alignment. In FIGS. 5(A) and (B), the corresponding reference points are assigned the same reference numerals. For example, although the coordinates of the reference point 307a in the reference image 301 and the reference point 307a in the target image 302 are different in each image, they represent the same part of the pattern. The same applies to the reference points 307b and 307c.

[0040] In the present embodiment, the positions of the reference points 307a to 307c with respect to the pattern printed by the printing device 190 are determined in advance. Note that the reference points 307a to 307c may be manually set by the user while viewing the pattern. Also, the reference points 307a to 307c may be automatically set by using image feature amounts such as SIFT or SURF. The alignment unit 204 can detect the reference points 307a to 307c thus determined by performing image analysis on the pattern areas 305 in the reference image 301 and the target image 302. In the present embodiment, since printing on the inspection target medium is performed according to predetermined print data, the approximate appearance positions of the reference points can be predicted. Therefore, the alignment unit 204 can set a window of a predetermined size (for example, 32×32 pixels) in the vicinity of the predicted positions of the reference points 307a to 307c and detect the reference points 307a to 307c by performing template matching. As another method, the alignment unit 204 may detect the reference points 307a to 307c by using a process of detecting image feature amounts such as SIFT or SURF described above.

[0041] By detecting the reference points 307a to 307c with the alignment unit 204, for each of the reference image 301 and the target image 302, the coordinates of each of the reference points 307a to 307c are obtained. Hereinafter, the coordinates of the reference points 307a, 307b, 307c in the reference image 301 are denoted as (x1a, y1a), (x1b, y1b), (x1c, y1c), respectively. Also, the coordinates of the reference points 307a, 307b, 307c in the target image 302 are denoted as (x2a, y2a), (x2b, y2b), (x2c, y2c), respectively.

[0042] Next, the alignment unit 204 aligns the reference image 301 and the target image 302 based on the positions of the corresponding reference points 307a to 307c detected from the reference image 301 and the target image 302. For example, when the alignment unit 204 applies a geometric transformation to the reference image 301, it can calculate a geometric transformation for alignment so that the positions of the reference points 307a to 307c coincide between the reference image 301 and the target image 302. In the present embodiment, the alignment unit 204 obtains the transformation X of the pattern area 305 from the reference image 301 to the target image 302 according to the following formula (1). AX = B ……(1) However,

Equation

[0043] X in formula (1) is an affine transformation, which represents the displacement amount synthesized by the translation, rotation, scaling, and shear from the reference image 301 to the target image 302. The transformation X can be calculated by multiplying the inverse matrix of A in formula (1) on the right side of B.

[0044] Next, the alignment unit 204 generates a transformed image 309 by applying the calculated transformation X to each pixel constituting the print media area 304 in the reference image 301. As shown in FIG. 5(C), in the transformed image 309 thus generated, the pattern within the pattern area 305 is aligned with the target image 302. That is, the positions of the reference points 307a to 307c coincide between the transformed image 309 and the target image 302. In this way, the alignment unit 204 can align the reference image 301 and the target image 302.

[0045] In step S1060, the inspection processing unit 205 performs the inspection process selected by the processing selection unit 203 in step S1040 on the end region 306. As described above, in the present embodiment, the inspection processing unit 205 performs a defect determination process based on the comparison between the target image 302 and the feature information on the end region 306. More specifically, the inspection processing unit 205 can detect defects in the end region 306 of the inspection target medium by comparing the image information at each position in the end region 306 of the target image 302 with the feature information having a certain value.

[0046] The image information at each position in the end region 306 of the target image 302 may be the luminance of each pixel. Also, the feature information having a certain value (hereinafter referred to as a feature value) may be the feature information about the end region 306. This feature information may be, for example, the representative luminance of the pixels belonging to the end region 306. The representative luminance refers to the luminance representing the end region 306. For example, when the print media is white paper, the representative luminance may be the typical luminance of the white paper read by the image acquisition unit 201.

[0047] In this embodiment, the inspection processing unit 205 uses, as a feature value, the feature information about the end region 306 of the reference image 301 acquired by the image acquisition unit 201. In this embodiment, the inspection processing unit 205 uses, as a feature value, the average luminance of the end region 306 detected from the reference image 301 in step S1030. Then, the inspection processing unit 205 calculates the difference between the pixel value and the feature value for each pixel in the end region 306 of the target image 302. The inspection processing unit 205 can determine a pixel for which the calculated difference is greater than the threshold value as a defective pixel.

[0048] Note that the inspection processing unit 205 may use a preset specified value as a feature value instead of the representative luminance of the end region 306 detected from the reference image 301. For example, the feature value can be determined in advance according to the type of the printing medium. According to such a configuration, since the process in which the region determination unit 202 detects the end region 306 of the reference image 301 can be omitted, an appropriate inspection of the printed matter can be performed even when a printing position shift occurs.

[0049] In step S1070, the inspection processing unit 205 performs the inspection process selected by the process selection unit 203 in step S1040 on the pattern region 305. As described above, in this embodiment, the inspection processing unit 205 performs a defect determination process based on the comparison between the reference image 301 and the target image 302 on the pattern region 305. More specifically, the inspection processing unit 205 compares the target image 302 and the reference image 301 that are aligned based on the object in the image, thereby detecting a defect in the pattern region 305 of the inspection target medium. As described above, in step S1050, the alignment unit 204 generates the converted image 309 by performing the alignment process of the reference image 301 to the target image 302. Therefore, the inspection processing unit 205 calculates the difference between the target image 302 and the converted image 309 for each pixel in the pattern region 305 in the target image 302. The inspection processing unit 205 can determine a pixel for which the calculated difference is greater than the threshold value as a defective pixel.

[0050] As described above, when the inspection processing unit 205 detects a defective pixel in step S1060 or step S1070, the inspection target medium is determined to be non-conforming. At this time, the CPU 101 included in the image processing apparatus 100 controls to convey this inspection target medium to the output tray 112. Also, when the inspection processing unit 205 does not detect a defective pixel, the inspection target medium is determined to be conforming. At this time, the CPU 101 included in the image processing apparatus 100 controls to convey this inspection target medium to the output tray 111.

[0051] In step S1080, the inspection processing unit 205 determines whether the next inspection target medium is conveyed to the image processing apparatus 100. If further printing on the printing medium is performed in the printing apparatus 190 and the inspection target medium is conveyed to the image processing apparatus 100, the process returns to step S1020 and the process of FIG. 3 continues. When printing and inspection are completed, the process of FIG. 3 ends.

[0052] In the above example, in step S1050, the alignment unit 204 aligns the reference image 301 and the target image 302 by converting the reference image 301 using the transformation X. On the other hand, the alignment unit 204 may align the target image 302 with respect to the reference image 301 by converting the target image 302. For example, a converted image can be generated by converting the target image 302 using a different transformation Y. Such a transformation Y can be represented by Equation (2). In Equation (2), the matrices A and B are the same as in Equation (1). BY = A ……(2) In this converted image, the pattern within the pattern region 305 is aligned with respect to the reference image 301. In this case, in step S1070, the inspection processing unit 205 can calculate the difference between the reference image 301 and the converted image.

[0053] According to such Embodiment 1, for each of the pattern region and the end region in the medium to be inspected, inspection processing according to the region is performed. With such a configuration, even when printing position deviation occurs, defects at the end of the medium can be detected more accurately.

[0054] (Modification Example of Embodiment 1) In Embodiment 1, for the pattern region 305, defect determination processing based on the comparison between the reference image 301 and the target image 302 is used, and for the end region 306, defect determination processing based on the comparison between the target image 302 and the feature information is used. On the other hand, the combination of the inspection settings used for defect determination in the pattern region 305 and the inspection settings used for defect determination in the end region 306 is not limited to this. For example, the processing selection unit 203 may select defect determination processing based on the comparison between the reference image 301 and the target image 302 also for the end region 306. In this case, the processing selection unit 203 can set different values for the threshold used by the inspection processing unit 205 for defect determination between the inspection of the pattern region 305 and the inspection of the end region 306. For example, the inspection processing unit 205 can detect defects in the pattern region 305 of the medium to be inspected by comparing the difference between the converted image 309 and the target image 302 in the pattern region 305 with a first threshold. On the other hand, the inspection processing unit 205 can detect defects in the end region 306 of the medium to be inspected by comparing the difference between the converted image 309 and the target image 302 in the end region 306 with a second threshold different from the first threshold. Even with such a configuration, inspections according to different inspection settings are performed between the pattern region 305 and the end region 306.

[0055] Also, while the processing selection unit 203 detects defects in the pattern area 305 of the medium to be inspected, it can omit the detection of defects in the end area 306 of the medium to be inspected. For example, based on an input or setting from the user, the inspection method may be set so as not to perform defect determination on the end area 306. Even with such a configuration, inspections are performed according to different inspection settings between the pattern area 305 and the end area 306. Further, the processing selection unit 203 may be able to set the inspection method so as to use defect determination using the same method between the pattern area 305 and the end area 306 based on an input or setting from the user.

[0056] [Embodiment 2] In Embodiment 2, similar to Embodiment 1, the presence or absence of defects in the medium to be inspected is inspected using inspection processing corresponding to each of the pattern area and the end area. In Embodiment 2, in particular, for the end area of the medium to be inspected, defects are determined based on a comparison between the reference image and the target image. On the other hand, in Embodiment 2, by performing alignment processing corresponding to each of the pattern area and the end area, defects are determined according to different inspection settings for the pattern area and the end area. Since the functional configuration of the image processing apparatus 100 according to the present embodiment is similar to the functional configuration of the image processing apparatus 100 according to Embodiment 1 shown in FIG. 2, the differences from Embodiment 1 will be described below.

[0057] The processing selection unit 203 selects inspection settings for the pattern area 305 and the end area 306. In Embodiment 2, the processing selection unit 203 selects the content of the alignment processing for inspecting the pattern area 305 and the content of the alignment processing for inspecting the end area 306.

[0058] The alignment unit 204 aligns the reference image 301 and the target image 302 in a first method for inspecting the pattern area 305. In the present embodiment, the alignment unit 204 aligns the reference image 301 and the target image 302 based on the pattern area 305 in the same manner as in the first embodiment for inspecting the pattern area 305. By comparing the thus-aligned reference image 301 and target image 302 by the inspection processing unit 205, defects in the pattern area 305 of the inspection target medium are detected. On the other hand, the alignment unit 204 aligns the reference image 301 and the target image 302 in a second method for inspecting the end area 306. In the present embodiment, the alignment unit 204 aligns the reference image 301 and the target image 302 based on the end positions of the inspection target medium and the reference medium for inspecting the end area 306. By comparing the thus-aligned reference image 301 and target image 302 by the inspection processing unit 205, defects in the end area 306 of the inspection target medium are detected. Details will be described later.

[0059] The processing performed by the image processing apparatus 100 according to the present embodiment will be described with reference to the flowchart of FIG. 3. The processing in steps S1010 to S1030 is the same as in the first embodiment. In step S1040, the processing selection unit 203 selects, as described above, the content of the alignment processing for the pattern area 305 and the alignment processing for the end area 306 to be performed in step S1050. In the present embodiment, for the pattern area 305, the alignment processing using the affine transformation based on the reference points 307a to c is selected in the same manner as in the first embodiment. On the other hand, for the end area 306, the alignment processing using the affine transformation based on the positions of the four vertices of the print medium is selected.

[0060] The alignment of the reference image 301 and the target image 302 based on the pattern area 305 in step S1050 is performed in the same manner as in Embodiment 1. That is, the alignment unit 204 can calculate the transformation X based on the reference points 307a to 307c with respect to the reference image 301, and can generate the transformed image 309 by applying the transformation X to the reference image 301. On the other hand, in step S1050, the alignment unit 204 further aligns the reference image 301 and the target image 302 based on the end area 306.

[0061] FIG. 8 is a diagram for explaining the outline of the alignment process based on the end area 306. FIGS. 8(A) and 8(B) show the relationship between the reference image 301, the target image 302, the pattern area 305, the end area 306, and the vertices 308a to 308d of the print medium area 304. The alignment unit 204 aligns the reference image 301 and the target image 302 based on the coordinates of the vertices 308a to 308d of the respective print medium areas 304 of the reference image 301 and the target image 302 detected in step S1030. For example, when the alignment unit 204 applies a geometric transformation to the reference image 301, it can calculate the geometric transformation for alignment so that the positions of the vertices 308a to 308d match between the reference image 301 and the target image 302. In the present embodiment, the alignment unit 204 can obtain the transformation X' of the end area 306 from the reference image 301 to the target image 302 according to the following formula (3). Since A' and B' in formula (3) are not square matrices, the alignment unit 204 can obtain the Moore-Penrose pseudo-inverse matrix of matrix A' and calculate X'. A’X’=B’ ……(3) However,

Equation

[0062] Furthermore, the alignment unit 204 generates an end-converted image 310 by applying the transformation X' calculated for each pixel in the print media area 304 of the reference image 301. FIG. 8(C) shows a state in which the end-converted image 310 obtained by converting the reference image 301 using the transformation X' by the alignment process and the target image 302 are aligned. At this stage, between the end-converted image 310 and the target image 302, the positions of the vertices 308a to 308d of the print media area 304 and the position of the end area 306 match. On the other hand, between the end-converted image 310 and the target image 302, the positions of the pattern areas 305 may not match.

[0063] Finally, the alignment unit 204 generates an overall converted image 311 by combining the end-converted image 310 and the converted image 309. FIGS. 9(A) to (C) are diagrams for explaining the overall converted image 311. The alignment unit 204 generates the overall converted image 311 by combining the image corresponding to the position of the pattern area 305 of the target image 302 in the converted image 309 and the image corresponding to the position of the end area 306 of the target image 302 in the end-converted image 310. Since the pattern area 305 and the end area 306 of the target image 302 do not overlap with each other, the alignment unit 204 can generate a unique overall converted image 311. The overall converted image 311 thus generated corresponds to the result of aligning the entire reference image 301 with the target image 302.

[0064] In this embodiment, the processes of steps S1060 and S1070 can be performed simultaneously. That is, the inspection processing unit 205 can calculate the difference between the target image 302 and the overall converted image 311 for each pixel of the target image 302. Then, the inspection processing unit 205 can determine the pixels for which the calculated difference is greater than the threshold as defective pixels. The process of step S1080 is the same as in the first embodiment. In this way, the processing according to the second embodiment can be performed.

[0065] Note that it is not essential to generate the overall converted image 311 in step S1050. For example, for the pattern area 305 and the end area 306, defect detection may be performed using different converted images. In this case, in step S1060, the inspection processing unit 205 can calculate the difference between the end converted image 310 and the target image 302 for each pixel in the end area 306 and compare the difference with a threshold value. Also, in step S1070, the inspection processing unit 205 can calculate the difference between the converted image 309 and the target image 302 for each pixel in the pattern area 305 and compare the difference with a threshold value.

[0066] Also according to such Embodiment 2, inspection processing using different alignment processes according to regions is performed for each of the pattern area and the end area in the inspection target medium. With such a configuration, even when printing position misalignment occurs, defects at the end of the medium can be detected more accurately. In particular, in this embodiment, since image comparison is also performed in the end area, it becomes possible to more accurately detect defects near the end of the medium.

[0067] [Embodiment 3] In Embodiments 1 and 2, defects in the target image were detected by comparing the reference image and the target image at least in the pattern area. Also, in the prior art, defects in the target image have been detected by comparing the reference image and the target image. By the way, in Embodiment 1, the reference image was obtained by reading the reference medium. In Embodiment 3, the reference image is generated based on a plurality of reading results of the reference medium. For example, in Embodiment 3, the reference image can be generated based on the read images obtained by reading each of the plurality of reference media. According to such a configuration, since the S / N ratio of the reference image is improved, it is expected that the accuracy of defect inspection is improved.

[0068] On the other hand, if there is a printing position deviation in each of the plurality of reference media, it is necessary to align the read images before synthesizing the plurality of read images. Also in this case, as in Embodiments 1 and 2, if alignment is performed to match the patterns, the mismatch at the end of the media becomes large, and there is a possibility that an appropriate reference image cannot be synthesized. Therefore, in Embodiment 3, the pattern region and the end region in the reference media are determined, and a reference image is synthesized from a plurality of read images by a synthesis process according to the region. By using the reference image thus generated, the accuracy of the inspection according to Embodiments 1 and 2 can be improved. On the other hand, the reference image generated according to Embodiment 3 can also be used in the inspection according to the prior art.

[0069] FIG. 6 is a block diagram showing the functional configuration of the image processing apparatus 100 according to Embodiment 3. Since the functional configuration of the image processing apparatus 100 according to Embodiment 3 is similar to the functional configuration of the image processing apparatus 100 according to Embodiment 1 shown in FIG. 2, the differences from Embodiment 1 will be described below.

[0070] The image acquisition unit 201 acquires a first image that is a read image of a reference medium indicating a target printing result, and a second image that is different from the first image. In the present embodiment, the image obtained by the image reading apparatus 105 reading the reference medium at the first time point is called the first read image, and the image obtained by reading another reference medium after the second time point is called the second read image. The image acquisition unit 201 is the same as in Embodiment 1 except that it acquires the first read image and the second read image instead of the reference image 301 and the target image 302. The image acquisition unit 201 can acquire a plurality of second read images obtained by reading each of the plurality of reference images. A plurality of second read images can be sequentially synthesized with respect to the first read image. Hereinafter, the first read image, or the first read image after one or more second read images are synthesized, may be referred to as a processed image.

[0071] The area determination unit 202, the process selection unit 203, and the alignment unit 204 are the same as those in the first embodiment, except that they process the processed image and the second read image instead of the reference image 301 and the target image 302.

[0072] The composition processing unit 206 composes the first read image and the second read image. Thus, the composition processing unit 206 can generate a reference image to be compared with the read image of the inspection target medium in order to detect defects in the inspected target medium on which printing has been performed. Here, the composition processing unit 206 performs composition according to different composition settings for each of the pattern area 305 and the end area 306 of the medium. In the case of the present embodiment, the composition processing unit 206 can generate a reference image by repeatedly composing the second read image with the processed image. Hereinafter, an image obtained by composing one second read image with the processed image may be referred to as a composite image.

[0073] In the present embodiment, the composition processing unit 206 generates an image of the pattern area 305 of the composite image by composing the processed image and the second read image. For this purpose, the composition processing unit 206 generates an image in the pattern area 305 of the composite image by composing the processed image and the second read image in accordance with the alignment by the alignment unit 204. In the case of the present embodiment, the composition processing unit 206 generates an image in the pattern area 305 of the composite image by composing the processed image and the second read image that are aligned based on the object in the image.

[0074] Further, the composition processing unit 206 generates information used to inspect the end region 306 in the inspection target medium according to a composition setting different from that of the pattern region 305. For this purpose, the composition processing unit 206 composes the feature information of each of the images of the end region 306 of the medium in the processed image and the second read image. Such feature information can be used to inspect the end region in the inspection target medium (target image 302) in the first embodiment. In the present embodiment, the composition processing unit 206 sets the pixel value in the end region 306 of the composite image to the feature value obtained by composing the feature value of the end region 306 of the processed image and the feature value of the end region 306 of the second read image. The composite image having the pattern region 305 in which the aligned processed image and the second read image are composed and the end region 306 having a certain pixel value can be used as the reference image in the first and second embodiments.

[0075] The processing performed by the image processing apparatus 100 according to the present embodiment having the above configuration will be described below. FIG. 7 is a flowchart showing the flow of the processing performed by the image processing apparatus 100. In the processing shown in FIG. 7, each of a plurality of second read images is sequentially composed with the first read image.

[0076] In step S1010, the image acquisition unit 201 acquires the first read image in the same manner as in the first embodiment, except that the first read image is acquired instead of the reference image 301. The first read image thus acquired is used as the processed image. In step S1020, the image acquisition unit acquires the second read image in the same manner as in the first embodiment, except that one of the second read images is acquired instead of the target image 302.

[0077] In step S1030, similar to the first embodiment, the region determination unit 202 detects the pattern region 305 and the end region 306 in the processing image by performing region determination on the processing image. Similarly, the region determination unit 202 detects the pattern region 305 and the end region 306 in the second read image by performing region determination on the second read image. Further, the region determination unit 202 calculates a feature value for the end region 306 of the second read image. This feature value is used in step S1100. Also, the region determination unit 202 replaces the pixel values of all the pixels belonging to the end region 306 of the first read image (=processing image) with the feature value for the end region 306 only in the first loop. Although the feature value will be described later, in this example, the feature value for the end region 306 is the average luminance of the pixels belonging to the end region 306.

[0078] In step S1040, the process selection unit 203 selects the content of the composition process for the pattern region 305 performed in step S1100 and the composition process for the end region 306 performed in step S1110. In the present embodiment, for the pattern region 305, a composition process by the weighted average of the processing image and the second read image is selected, and for the end region 306, a composition process of the feature value is selected. The specific process selection method is the same as in the first embodiment.

[0079] In step S1050, the alignment unit 204 aligns the processing image and the second read image. Also in the present embodiment, similar to the first embodiment, alignment of the processing image and the second read image is performed based on the pattern region 305. For example, the alignment unit 204 can obtain the transformation X of the pattern region 305 from the processing image to the second read image based on the reference point. Next, the alignment unit 204 generates a transformed image by applying the calculated transformation X to each pixel constituting the print medium region 304 in the processing image, similar to the first embodiment. In this way, the alignment unit 204 can align the processing image and the second read image.

[0080] In step S1100, the inspection processing unit 205 performs the synthesis process selected by the process selection unit 203 in step S1040 on the end region 306. As described above, in the present embodiment, the synthesis processing unit 206 performs the synthesis process of feature values on the end region 306. The feature value in the present embodiment is the representative luminance of the pixels belonging to the end region 306. The meaning of the feature value may be the same as that in Embodiment 1. In this example, the average luminance of the pixels belonging to the end region 306 is used as the feature value.

[0081] For example, the synthesis processing unit 206 performs a synthesis process using the feature value for each pixel in the end region 306 of the second read image. More specifically, the synthesis processing unit 206 calculates the weighted average of the feature value (in this example, the average luminance of the end region 306) in the second read image and the feature value in the processed image for each pixel in the end region 306.

[0082] As an example of the process by the synthesis processing unit 206, the synthesis processing unit 206 can first replace the pixel values of all the pixels belonging to the end region 306 of the second read image with the feature value for the end region 306. In this example, the feature value is the average luminance of all the pixels belonging to the end region 306 of the second read image. Then, the synthesis processing unit 206 can calculate the weighted average according to Equation (4). I3(x,y)=(N×I1(x,y)+I2(x,y)) / (N + 1) ……(4) Here, x and y represent the indices of each pixel in the end region 306. Also, I1(x,y), I2(x,y), and I3(x,y) represent the pixel values at the pixel (x,y) of the processed image, the second read image, and the synthesized image, respectively. Further, N represents the number of the second read images to be synthesized. When processing the third second read image, N = 3.

[0083] As described above, the pixel values in the end region 306 of the first read image are replaced with the average luminance of the end region 306 of the first read image in step S1030. Also, the pixel values in the end region 306 of the second read image are replaced with the average luminance of the end region 306 of the second read image in step S1100. Therefore, all pixels (x, y) belonging to the end region 306 of the first read image and the second read image have the same value. As a result, in the composite image obtained from the first read image (= processed image) and the second read image according to equation (4), all the pixel values in the end region 306 are the same. Since the composite image thus obtained is used as the processed image in the next processing loop, the pixel values in the end region 306 of the composite image will also be the same in subsequent processing loops. The value of I3(x, y) obtained by equation (4) is the average value of the average luminance (I1(x, y)) of the processed image weighted by the number of composite read images and the average luminance (I2(x, y)) of the second read image. In other words, the value of I3(x, y) is the average luminance of the end region 306 of the first read image and the second read image processed so far.

[0084] In step S1110, the composite processing unit 206 performs the composite processing selected by the processing selection unit 203 in step S1040 on the pattern region 305. As described above, in the present embodiment, the composite processing unit 206 performs composite processing by the additive average of the processed image and the second read image on the pattern region 305. For example, the composite processing unit 206 can composite the converted image obtained from the processed image by the alignment processing in step S1050 and the second read image for each pixel in the pattern region 305 of the second read image. As a specific example, the composite processing unit 206 can calculate the pixel value of each pixel (x, y) in the pattern region 305 of the composite image using the above equation (4) (in this case, I1(x, y) is the pixel value of the converted image). By steps S1100 and S1110, a composite image including the pattern region 305 and the end region 306 is generated.

[0085] In step S1120, the composition processing unit 206 determines whether there is a read image of a reference medium that has not been composed yet. When composing the next read image of the reference medium, the image acquisition unit 201 replaces the processed image with the composed image. Then, the process returns to step S1020, and the composed image is composed with the second read image of the new reference medium. In steps S1100 and S1110 in the next processing loop, the value of N used in formula (4) increases by 1.

[0086] On the other hand, in step S1120, when it is determined that all the read images of the reference media have been composed, the generated composed image is output to an auxiliary storage device (not shown), and the process of FIG. 7 ends. As already described, the composed image output here can be used as the reference image 301 in Embodiments 1 and 2. By using the composed image generated in this way as the reference image 301, it is expected that the accuracy of the inspection process in Embodiments 1 and 2 will be improved.

[0087] In the above example, the composition processing unit 206 generated a composed image by sequentially obtaining an addition average according to formula (4) while repeating steps S1020 to S1120. However, the method for generating the composed image is not limited to this method. For example, in step S1020, the image acquisition unit 201 can acquire a plurality of second read images that are the read results of a plurality of reference media. Then, in steps S1100 and S1110, the composition processing unit 206 may compose all the first read images and the second read images. For example, the composition processing unit 206 can calculate the addition average using formula (5) instead of formula (4). I3(x,y)=(I1(x,y)+I 21 (x,y)+I 22 (x,y)+...+I 2N-1 (x,y)) / N ……(5) In formula (5), N is the total number of read images, I1(x,y) is the pixel value of the first read image, I 21 (x,y)~I 2N-1(x, y) represents the pixel value of each pixel in the second read image. Also in this case, the pixel value of the end region 306 of the composite image is the average of the feature values of the end region 306 in the first read image and the second read image. Further, the pixel value of the pattern region 305 of the composite image is the average pixel value for each pixel after aligning the first read image and the second read image based on the pattern in the pattern region 305.

[0088] Also, the composite processing unit 206 may adopt the median value of each pixel in the first read image and the second read image as the pixel value of the composite image. In this case, the composite processing unit 206 can calculate the pixel value of the composite image using Equation (6) instead of Equation (5). In Equation (6), median is a function for calculating the median value. I3(x, y) = median(I1(x, y), I 21 (x, y), I 22 (x, y),..., I 2N-1 (x, y)) ……(6)

[0089] In this embodiment, the pixel values in the end region 306 of the read image are replaced with the average luminance of the end region 306. Then, by synthesizing the read image according to Equation (4) or the like, a synthesized image in which the end region 306 has a constant pixel value is generated. However, the synthesis processing unit 206 may generate feature information about the end region 306 of the reference image by another method. For example, the synthesis processing unit 206 may calculate the average luminance of the end regions 306 of the first read image and the second read image and output it as feature information about the end region 306 of the reference image. Such feature information can be used as feature information about the end region 306 having a constant value, which is compared with the image information at each position of the end region 306 of the target image 302 in Embodiment 1. In this case, the synthesis processing unit 206 can output a reference image generated by synthesizing a processed image aligned based on the object in the pattern region 305 and the second read image, and the feature information about the end region 306 of the reference image. As another example, the synthesis processing unit 206 may synthesize a processed image aligned based on the object in the pattern region 305 and the second read image, and replace the pixel values in the end region 306 of the obtained image with the above feature information to generate a reference image.

[0090] According to this embodiment, the pattern region and the end region of the reference medium are determined, and a reference image is obtained by synthesizing the read images of a plurality of reference media using synthesis processing according to each region. With such a configuration, even when printing position deviation occurs, it is possible to generate a more appropriate inspection reference image.

[0091] [Embodiment 4] Also in Embodiment 4, the pattern area and the end area in the reference medium are determined, and a reference image is synthesized from a plurality of read images by a synthesis process according to the area. In Embodiment 4, in particular, by performing alignment processing according to each of the pattern area and the end area, the reference image is synthesized according to different synthesis settings for the pattern area and the end area. Since the functional configuration of the image processing apparatus 100 according to the present embodiment is similar to the functional configuration of the image processing apparatus 100 according to Embodiment 3 shown in FIG. 6, the differences from Embodiment 3 will be described below.

[0092] The process selection unit 203 selects the content of the synthesis process for the pattern area 305 and the end area 306. In the present embodiment, the process selection unit 203 selects, as the content of the alignment process performed for the synthesis of the pattern area 305, the alignment process based on the reference points in the pattern area 305 similar to Embodiment 2. Further, the process selection unit 203 selects, as the content of the alignment process performed for the synthesis of the end area 306, the alignment process based on the positions of the four vertices of the print medium in the end area 306 similar to Embodiment 2. The content of the alignment process performed by the alignment unit 204 is the same as in Embodiment 2.

[0093] Also in the present embodiment, the synthesis processing unit 206 generates a synthesized image. The pattern area 305 of this synthesized image is, as in Embodiment 3, a synthesized image of the processed image aligned based on the object in the image and the second read image. On the other hand, the end area 306 of this synthesized image is a synthesized image of the processed image aligned based on the end position of the medium and the second read image. The synthesized image thus obtained can also be used as the reference image in Embodiments 1 and 2.

[0094] The processing performed by the image processing apparatus 100 according to the present embodiment having the above configuration will be described with reference to the flowchart of FIG. 7. The processing in steps S1010 to S1030 is the same as in Embodiment 3. The processing in step S1040 is also the same as in Embodiment 3 except that the process selection unit 203 selects the content of the synthesis process as described above.

[0095] In step S1050, the alignment unit 204 performs processing in the same manner as in Embodiment 2, except for aligning the processed image and the second read image. Through the processing in step S1050, the conversion X' of the end region 306 from the processed image to the second read image and the conversion X of the pattern region 305 from the processed image to the second read image are obtained. The overall converted image obtained by the processing in step S1050 has an end-converted image obtained by converting the processed image using the conversion X' in the region corresponding to the position of the end region 306 of the second read image. Further, this overall converted image has a converted image obtained by converting the processed image using the conversion X in the region corresponding to the position of the pattern region 305 of the second read image.

[0096] In step S1100, the composition processing unit 206 generates a composite image by composing the overall converted image obtained in step S1050 and the second read image. In this embodiment, the composition processing unit 206 can perform an operation according to Equation (4) for each pixel in the print medium region 304 (i.e., both the pattern region 305 and the end region 306) of the second read image. In this case, I1(x, y) represents the pixel value of the overall converted image. In this way, a composite image having the pixel value I3(x, y) obtained by Equation (4) can be generated. The processing in step S1120 is the same as in Embodiment 3.

[0097] Also according to this embodiment, when print position misalignment occurs, it is possible to generate a more appropriate inspection reference image. In particular, in this embodiment, since image composition is also performed in the end region, it is possible to more accurately detect defects near the end of the medium.

[0098] [Embodiment 5] In Embodiment 2, as an alignment method when inspecting the end region 306, alignment processing based on the positions of the four vertices of the print medium in the end region 306 was performed. In Embodiment 5, although details will be described later, as shown in FIG. 10(B), when comparing the pixel values of the target image and the reference image, the pixel values within a predetermined search range are compared with each other. For this purpose, the inspection of the end region 306 can be performed using images of the inspection range cut out from the reference image and the target image so as to have a region with a predetermined number of pixels around the print medium region 304.

[0099] According to such a configuration, it is possible to improve the defect detection accuracy in the case where there is a wrinkle or distortion at the end of the print medium. For example, as shown in the enlarged view of FIG. 10(A), the reference image 2011 obtained by synthesizing the read images of a plurality of reference media may have a brightness reduction portion generated by synthesizing the paper white and the black background at the image end. Also, there may be a possibility that a black background portion is reflected in the end portion of the target image 2020 corresponding to the paper white portion of the print medium region 304. According to the present embodiment, when a black region or a brightness reduction region occurs in the end region of the reference image or the target image in this way, it is possible to suppress the detection of these regions as defects.

[0100] First, a method for generating a reference image by synthesizing the read images of a plurality of reference media in the present embodiment will be described. According to the following method, a reference image can be generated so as to include a background region at the end. However, it is not essential to use the reference image generated as described below for the inspection of the inspection target medium.

[0101] The processing in Embodiment 5 is different from that in Embodiment 4 in the process of synthesizing the end regions of a plurality of reference images. Hereinafter, this processing in Embodiment 5 will be described with reference to the flowchart of FIG. 11. The processing described below can be used in combination with the processing such as alignment and synthesis of the pattern regions in Embodiment 4. That is, while synthesizing the end region 306 and the margin region according to steps S1180 to S1210 in FIG. 11, a composite image can be generated by synthesizing the pattern region 305 according to steps S1030 to S1110 in FIG. 7.

[0102] In step S1170, the image acquisition unit 201 acquires a second read image in the same manner as step S1020 in Embodiment 4. In step S1180, the region determination unit 202 extracts a margin region in addition to the end region 306. The margin region is a region with a predetermined pixel width provided on the top, bottom, left, and right of the outer edge of the end region 306 (or the print medium region 304). The size of the pixel width is not particularly limited, but in the following description, the predetermined pixel width is set to 20 pixels. On the other hand, similar to the end margin already described, the predetermined pixel width may be determined based on the amount of margin or the amount of printing position deviation when the printing device 190 performs printing. For example, since the margin region can be extracted to include the black region of the background, if the printing position deviation of the printing device with respect to the print medium is about 10 pixels, the width of the margin region can be set to about 10 pixels. Further, a mechanism for the user to set a predetermined pixel width may be provided separately.

[0103] In step S1190, the alignment unit 204 performs alignment between the processed image based on the end region 306 and the second read image in the same manner as step S1050 in Embodiment 4. That is, the alignment unit 204 can perform alignment processing based on the positions of the four vertices of the print medium in the end region 306. Here, the alignment unit 204 can convert the processed image so as to align the processed image with the second read image, in the same manner as in Embodiment 4.

[0104] In step S1200, the alignment unit 204 acquires regions corresponding to the end region 306 and the margin region from the processed image after conversion obtained in step S1190. The image acquired here includes black pixels corresponding to the background region outside the print medium region 304, similar to the reference image 2030 in FIG. 10(B).

[0105] In step S1210, the composition processing unit 206 composes the processed image after conversion obtained in step S1190 and the second read image in the end region 306 and the margin region. In this way, the composition processing unit 206 can generate the end region 306 and the margin region of the composite image, which is a composite image of the processed image aligned based on the end position of the medium and the second read image. The composition processing unit 206 can generate a composite image by sequentially obtaining an addition average according to formula (4) in the same manner as in Embodiment 4 for both the end region 306 and the margin region. In this embodiment, in order to maintain the contrast between the margin region at the image end and the paper white, the composition processing unit 206 calculates the difference in pixel values between the images, and when the difference exceeds a predetermined threshold, it may adopt the pixel value of the image with the smaller pixel value without performing an addition average. Also, instead of calculating the difference in pixel values, the composition processing unit 206 may use another method, such as replacing the pixel value with a predetermined pixel value representing a black region when the pixel value of the second read image is smaller than a predetermined threshold.

[0106] As described above, further similar to Embodiment 4, the composition processing unit 206 can generate the pattern region 305 and the margin region of the composite image, which is a composite image of the processed image aligned based on the pattern region 305 and the second read image. In this way, a composite image including the pattern region 305, the end region 306, and the margin region can be generated.

[0107] The processing of step S1220 is the same as that of Embodiment 4. When the synthesis of the read images of all the reference media is completed, the generated synthesized image is output to an auxiliary storage device (not shown), and the processing ends. By such processing, a reference image in which read images of reference media including a background area at the end are synthesized can be obtained.

[0108] Next, the processing in Embodiment 5 for inspecting the inspection target medium by comparing the reference image including the background area at the end and the target image will be described with reference to the flowchart of FIG. 12. In step S1230, the image acquisition unit 201 acquires a reference image including a background area at the end. This reference image may be a synthesized image obtained by synthesizing read images of a plurality of reference media generated by the method described above. In step S1240, the image acquisition unit 201 acquires a target image in the same manner as step S1020 of Embodiment 2.

[0109] In step S1250, the inspection processing unit 205 extracts a pattern area 305, an end area 306, and a margin area from the target image. The extraction methods of the pattern area 305 and the end area 306 are the same as those of Embodiment 2. Also, the extraction method of the margin area is as described above. Thus, the inspection processing unit 205 can generate an image in which a margin area is provided at the end of the printed media area 304.

[0110] In step S1260, the inspection processing unit 205 performs alignment between the reference image acquired in step S1230 and the processed image acquired in step S1250 in the same manner as in Embodiment 2. For example, the inspection processing unit 205 can convert the reference image into an overall transformed image by performing alignment for the pattern area 305 and alignment for the end area 306 respectively. Note that the inspection processing unit 205 can also perform alignment based on the positions of the four vertices of the printed media for the margin area in the same manner as the end area 306.

[0111] In step S1270, the inspection processing unit 205 determines a search range used when comparing the pixel values of the reference image and the target image. In the present embodiment, since the margin area outside the print medium area 304 is also extracted, false detection in the end area can be suppressed by comparing pixel values within a predetermined range. The size of the search range is not particularly limited, but in the following description, it can be set to 20 pixels, which is the same as the width of the margin area. On the other hand, similar to the width of the margin area, the size of the search range may be determined based on the amount of margin or the amount of print position deviation when the printing device 190 performs printing.

[0112] In step S1280, the inspection processing unit 205 calculates the difference value between the pixel values of the target image and the reference image in the end area 306. As shown in FIG. 10(B), the inspection processing unit 205 can calculate the difference value between the pixel value of the target pixel of the target image 2040 and the pixel values of each pixel of the reference image 2030 within the search range corresponding to the target pixel. This search range may be an area in the reference image where the vertical and horizontal distances from the pixel corresponding to the target pixel are less than or equal to the number of pixels determined in step S1270. In the present embodiment, the inspection processing unit 205 scans the reference image vertically and horizontally by the number of pixels according to the search range, calculates the difference value for each pixel, and can adopt the difference value with the minimum value as the difference value used for defect determination.

[0113] In step S1290, the inspection processing unit 205 determines whether the calculation of the difference value for all pixels of the target image has been completed. If not, the process returns to S1280, and the difference value is calculated for other pixels. If it has been completed, the inspection processing unit 205 determines whether the pixels in the end area 306 of the target image are defective pixels based on the difference value, in the same manner as in Embodiment 2. Thus, the inspection process ends.

[0114] In this embodiment, an inspection image having a margin area at the outer edge of the print media area is used. Also, when comparing the pixel values of the end regions, the minimum value of the difference values for the pixels within a predetermined range is adopted as the difference value used for defect determination. For example, even when the pixel of interest in the target image represents paper white and the corresponding pixel in the reference image represents the background, if there is a pixel of the same color as the pixel of interest (a pixel representing paper white) near the corresponding pixel in the reference image, it is not determined as a defect. Further, even when the pixel of interest in the target image represents the background and the corresponding pixel in the reference image represents paper white, if there is a pixel of the same color as the pixel of interest (a pixel representing the background) near the corresponding pixel in the reference image, it is not determined as a defect. With such a configuration, it becomes possible to detect defects near the media edge with higher accuracy while suppressing false detection.

[0115] [Embodiment 6] In the above-described embodiment, inspection and composition were performed for each of the pattern area and the end area. However, inspection or composition may be performed according to the inspection settings or composition settings for three or more areas. In Embodiment 6, a method of newly adding a pre-print area to the inspection target area and dividing the image of the print media into three areas for processing will be described. The pre-print area refers to the area of the image that has been pre-printed on the print media before the main printing by the printing device. Note that the pre-print area may be present at the center of the print media.

[0116] Hereinafter, the alignment and inspection processing of the pre-print area in Embodiment 6, which is a difference from Embodiment 2, will be described with reference to the flowchart of FIG. 13. Since the alignment and inspection processing of the pattern area and the end area in Embodiment 6 are the same as those in Embodiment 2, the description thereof will be omitted.

[0117] In step S1300, the image acquisition unit 201 acquires a reference image, which is a read image of a reference medium indicating a target print result, in the same manner as step S1010 in Embodiment 2. In step S1310, the image acquisition unit 201 acquires a target image, which is a read image of an inspection target medium on which printing has been performed, in the same manner as step S1020 in Embodiment 2.

[0118] In step S1320, the area determination unit 202 performs area determination on the target image. In this embodiment, the area determination unit 202 extracts a pattern area, an end area, and a pre-print area from the target image. The area determination unit 202 can extract the pattern area, the end area, and the pre-print area with reference to an area map image. The area map image is used to discriminate the pre-print area and can be created by the user in advance. The area map image is an image having the same vertical and horizontal widths as the processed image, and different pixel values are stored in each area. For example, the pixels in the pattern area may have a pixel value of (R, G, B) = (255, 255, 255), the pixels in the end area may have a pixel value of (R, G, B) = (0, 0, 0), and the pre-print area may have a pixel value of (R, G, B) = (128, 128, 128). However, the pixel values of the pixels in each area are not limited to these values. In this case, the area determination unit 202 may extract a print medium area from the target image in the same manner as in Embodiment 2, and extract a pattern area, an end area, and a pre-print area from the print medium area based on the area map image. Further, instead of using the area map image, the area determination unit 202 may perform area determination based on the feature information of the image in the same manner as in Embodiment 2.

[0119] In step S1330, the process selection unit 203 selects inspection settings for each area. In the present embodiment, inspections are performed according to the inspection settings for each of the pre-print area pre-printed on the inspection target medium in advance, the print area of the inspection target medium, and the end area. For example, similar to Embodiment 2, the process selection unit 203 can select alignment based on the pattern area (i.e., the object in the image) for the pattern area and alignment based on the end position of the medium for the end area, respectively. Also, the process selection unit 203 can select alignment based on the end position of the medium for the pre-print area as well.

[0120] In step S1340, the alignment unit 204 performs alignment processing according to the inspection settings for the end area in the same manner as in Embodiment 2. In step S1350, the alignment unit 204 performs alignment according to the inspection settings for the pattern area in the same manner as in Embodiment 2.

[0121] In step S1360, the alignment unit 204 performs alignment according to the inspection settings for the pre-print area. In the present embodiment, for the pre-print area as well, alignment based on the end position of the reference medium is performed in the same manner as in step S1350. When the error in the printing position of the pre-print with respect to the reference medium is smaller than the alignment error based on the feature points of the pre-print pattern, the alignment accuracy can be improved by using such settings. On the other hand, when the error in the printing position of the pre-print with respect to the reference medium is larger than the alignment error based on the feature points of the pre-print pattern, alignment based on the pre-print area may be adopted.

[0122] In step S1370, the alignment unit 204 generates an overall transformed image by combining the results of the alignment processing for each of the pattern area, end area, and pre-print area of the reference image 301 in the same manner as in step S1050 of Embodiment 2.

[0123] In step S1380, the inspection processing unit 205 inspects for defects in the inspection target medium by comparing the target image and the overall conversion image in the same manner as in steps S1060 and S1070 of Embodiment 2. In this embodiment, for defect detection in the pre-print area, a reference image aligned based on the edge position of the medium is used.

[0124] In step S1390, the inspection processing unit 205 determines whether the inspection has been completed for all target images. If not, the process returns to step S1310, and if so, the inspection process ends.

[0125] According to this embodiment, for the pre-print area as well, inspection can be performed according to the inspection settings for the pre-print area. As an example, in the inspection process for the pre-print area, by using a reference image aligned based on the edge position of the medium, it becomes possible to accurately detect defects in the pre-print area. In this way, not only different inspection settings are used for the pattern area and the edge area, but also different inspection settings are used for the first area (pattern area) and the second area (pre-print area) of the image, thereby improving the inspection accuracy. Of course, for the pre-print area, different inspection settings from those of the pattern area and the edge area may be used.

[0126] Also, by using a similar method, the read image of the reference medium can be synthesized according to the synthesis settings for each of the pattern area, the edge area, and the pre-print area. For example, synthesis is performed according to Embodiment 4 for the pattern area and the edge area, and after alignment as described above for the pre-print area and then synthesis, a synthesized image for inspection can be generated. For the pre-print area, for example, a synthesis process by addition average may be selected in the same manner as for the pattern area.

[0127] (Other Examples) The configurations of the image acquisition unit 201 and the image reading device 105 are not particularly limited. For example, the type of image acquired by the image acquisition unit 201 is not limited, and the image may be an RGB color image, a grayscale image, or a black-and-white image.

[0128] In Embodiments 1 and 2, the image reading device 105 first reads a reference medium and then reads an inspection target medium. However, the order of generating the reference image and the target image by the image reading device is not particularly limited. Also, in each embodiment, the image acquisition unit 201 may acquire a reference image, a target image, or a read image from an auxiliary storage device (not shown). As the reference image and the target image, any image capable of calculating a difference between the reference image and the target image for the inspection of the target image can be used. Also, as the read image, any image capable of creating a reference image for the inspection of the target image can be used.

[0129] The present invention can also be realized by supplying a program that realizes one or more functions of the above-described embodiments to a system or device via a network or a storage medium, and having one or more processors in a computer of the system or device read and execute the program. Also, it can be realized by a circuit (for example, ASIC) that realizes one or more functions.

[0130] The invention is not limited to the above-described embodiments, and various changes and modifications are possible without departing from the spirit and scope of the invention. Therefore, claims are attached to disclose the scope of the invention.

Description of Reference Numerals

[0131] 105: Image reading device, 100: Image processing device, 190: Printing device, 201: Image acquisition unit, 202: Region determination unit, 203: Processing selection unit, 204: Alignment unit, 205: Inspection processing unit, 206: Composition processing unit

Claims

1. An acquisition unit that acquires a first image which is a read image of an inspection target medium on which printing has been performed, and a second image which is a reference image serving as a reference for inspection; An inspection unit that detects a defect in a printed area of the inspection target medium by comparing the first image and the second image aligned by a first method, and detects a defect in an end area of the inspection target medium by comparing the first image and the second image aligned by a second method different from the first method; An image processing apparatus, characterized by comprising the above.

2. The inspection unit is characterized in that it detects a defect in the end area of the inspection target medium by comparing the image information at each position in the end area of the first image with feature information having a certain value. The image processing apparatus according to Claim 1.

3. The image processing apparatus according to Claim 2, wherein the feature information is feature information about the end area of the second image.

4. The image processing apparatus according to Claim 3, wherein the image information at each position in the end area of the first image is the luminance of each pixel, and the feature information is the average luminance about the end area of the second image.

5. The inspection unit is characterized in that it detects a defect in the end area of the inspection target medium by comparing the first image and the second image aligned by alignment by the second method based on the end positions of the inspection target medium and a reference medium shown in the reference image. The image processing apparatus according to Claim 1.

6. The inspection unit is characterized in that it detects a defect in the printed area of the inspection target medium by comparing the first image and the second image aligned by alignment by the first method based on an object in the image. The image processing apparatus according to Claim 1 or 5.

7. The inspection unit is characterized in that it detects a defect in the printed area of the inspection target medium by comparing the difference between the first image and the second image in the printed area with a first threshold value, and detects a defect in the end area of the inspection target medium by comparing the difference between the first image and the second image in the end area with a second threshold value different from the first threshold value. The image processing apparatus according to Claim 1.

8. The image processing apparatus according to any one of claims 1 to 7, further comprising determination means for determining the printing area and the end area in the first or second image.

9. The image processing apparatus according to claim 8, wherein the determination means determines an area within a predetermined distance from the contour of the medium on the first or second image as the end area.

10. The image processing apparatus according to claim 9, wherein the predetermined distance is determined based on the amount of margin or the amount of printing position deviation when the printing apparatus performs printing on the medium on the first or second image.

11. The image processing apparatus according to any one of claims 8 to 10, wherein the determination means detects an index given to the medium on the first or second image and determines the end area based on the coordinates of the index.

12. An acquisition means for acquiring a first image which is a read image of an inspection target medium on which printing has been performed, and a second image which is a reference image serving as a reference for inspection; An inspection means for inspecting a defect of the inspection target medium based on the first image and the second image, the inspection being performed according to an inspection setting for each of a region pre-printed on the inspection target medium, a printing region of the inspection target medium, and an end region. An image processing apparatus, characterized by comprising:

13. The inspection means according to claim 12, wherein the inspection means detects a defect in the printing area of the inspection target medium by comparing the first image and the second image aligned based on an object in the image, and compares the first image and the second image aligned based on the end position of the inspection target medium to detect a defect in the end area of the inspection target medium and a defect in a region pre-printed on the inspection target medium.

14. An acquisition means for acquiring a first image which is a read image of an inspection target medium on which printing has been performed, and a second image which is a reference image serving as a reference for inspection; An inspection means for detecting a defect in the printing area of the inspection target medium based on the first image and the second image, and omitting the detection of a defect in the end area of the inspection target medium. An image processing apparatus, characterized by comprising:

15. A step of obtaining a first image which is a read image of an inspection target medium on which printing has been performed and a second image which is a reference image serving as a reference for inspection; A step of detecting a defect in a printed area of the inspection target medium by comparing the first image aligned by a first method and the second image, and detecting a defect in an end area of the inspection target medium by comparing the first image aligned by a second method different from the first method and the second image; An image processing method, characterized by comprising the above.

16. A program for causing a computer to function as each means of the image processing apparatus according to any one of Claims 1 to 14.

Citation Information

Patent Citations

  • Image processing system

    JP2013046092A

  • Image inspection device, image forming system, and image inspection method

    JP2015065647A