JP2021184517A - Image reading device - Google Patents

Image reading device Download PDF

Info

Publication number
JP2021184517A
JP2021184517A JP2020088618A JP2020088618A JP2021184517A JP 2021184517 A JP2021184517 A JP 2021184517A JP 2020088618 A JP2020088618 A JP 2020088618A JP 2020088618 A JP2020088618 A JP 2020088618A JP 2021184517 A JP2021184517 A JP 2021184517A
Authority
JP
Japan
Prior art keywords
edge
image
straight line
approximate straight
section
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
JP2020088618A
Other languages
Japanese (ja)
Inventor
貴博 南
Takahiro Minami
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Kyocera Document Solutions Inc
Original Assignee
Kyocera Document Solutions Inc
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Kyocera Document Solutions Inc filed Critical Kyocera Document Solutions Inc
Priority to JP2020088618A priority Critical patent/JP2021184517A/en
Priority to US17/321,322 priority patent/US11399108B2/en
Priority to CN202110553055.5A priority patent/CN113489856B/en
Publication of JP2021184517A publication Critical patent/JP2021184517A/en
Pending legal-status Critical Current

Links

Images

Landscapes

  • Image Input (AREA)
  • Facsimile Scanning Arrangements (AREA)

Abstract

To provide an image reading device that appropriately detects a defect in an original image with a relatively small amount of calculation.SOLUTION: An edge shape detection unit 23 detects the edge shape of the front edge and/or the trailing edge of an original image in a target image. A defect determination unit 24 determines whether the original image is defective on the basis of the detected edge shape. Then, a defect determination unit 24 identifies the defect area on the basis of the detected edge shape, and determines whether the original image is defective on the basis of the defect area. The defect area is the area of a region sandwiched between the approximate straight line of the edge of a specific partial short section in the predetermined direction of the target image and the edge specified by the edge shape.SELECTED DRAWING: Figure 1

Description

本発明は、画像読取装置に関するものである。 The present invention relates to an image reader.

ある帳票読取装置は、読取画像内の帳票部分の周囲のすべてのエッジを抽出して帳票部分の外形を特定し、その外形に基づいて、帳票の紙折れが発生しているか否かを判定している(例えば特許文献1参照)。 A form reading device extracts all the edges around the form part in the scanned image, identifies the outer shape of the form part, and determines whether or not the form is folded based on the outer shape. (See, for example, Patent Document 1).

ある画像読取装置は、あるエッジにおいて、複数のエッジ点Eについての傾きの分散を特定し、その傾きの分散に基づいて、複数のエッジ点Eの直進性を判定している(例えば特許文献2参照)。なお、2つのエッジ点の上下距離を左右距離で除して得られた値が傾きとされ、最小二乗法で傾きの分散が特定される。 An image reader identifies the variance of the slope for a plurality of edge points E at a certain edge, and determines the straightness of the plurality of edge points E based on the variance of the slope (for example, Patent Document 2). reference). The value obtained by dividing the vertical distance between the two edge points by the left-right distance is taken as the slope, and the variance of the slope is specified by the least squares method.

特開2010−204906号公報Japanese Unexamined Patent Publication No. 2010-204906 特開2016−086217号公報Japanese Unexamined Patent Publication No. 2016-08627

しかしながら、上述の帳票読取装置では、読取画像内の帳票部分の周囲のすべてのエッジを抽出して外形を特定しているため、1画素ずつエッジを抽出する場合には計算量が大きくなり処理時間が長くなってしまい、離散的にエッジ位置を抽出する場合には、外形が誤って特定され正確に紙折れが検出されない可能性がある。また、上述の画像読取装置では、複数のエッジ点のすべてに対して傾きと分散を計算する必要があるため、計算量が大きくなり処理時間が長くなってしまう。 However, in the above-mentioned form reading device, since all the edges around the form portion in the scanned image are extracted to specify the outer shape, the calculation amount becomes large and the processing time becomes large when the edges are extracted one pixel at a time. If the edge positions are extracted discretely, the outer shape may be erroneously specified and the paper fold may not be detected accurately. Further, in the above-mentioned image reading device, since it is necessary to calculate the slope and the variance for all of the plurality of edge points, the amount of calculation becomes large and the processing time becomes long.

本発明は、上記の問題に鑑みてなされたものであり、比較的少ない計算量で適切に原稿画像の欠損を検出する画像読取装置を得ることを目的とする。 The present invention has been made in view of the above problems, and an object of the present invention is to obtain an image reader that appropriately detects defects in an original image with a relatively small amount of calculation.

本発明に係る画像読取装置は、原稿の画像読取によって得られる読取画像または前記読取画像に対して所定の画像処理を実行して得られた画像を対象画像とし、前記対象画像内の原稿画像の先端エッジおよび後端エッジの少なくとも一方のエッジ形状を検出するエッジ形状検出部と、検出された前記エッジ形状に基づいて、前記原稿画像に欠損が発生しているか否かを判定する欠損判定部とを備える。前記欠損判定部は、検出された前記エッジ形状に基づいて欠損面積を特定し、前記欠損面積に基づいて、前記原稿画像に欠損が発生しているか否かを判定する。ここで、前記欠損面積は、前記対象画像の所定方向における特定の部分短区間のエッジの近似直線と前記エッジ形状で特定されるエッジとに挟まれる領域の面積である。 The image reading device according to the present invention uses a scanned image obtained by scanning an image of a document or an image obtained by performing predetermined image processing on the scanned image as a target image, and the original image in the target image. An edge shape detection unit that detects at least one edge shape of the front end edge and the rear end edge, and a defect determination unit that determines whether or not a defect has occurred in the original image based on the detected edge shape. To prepare for. The defect determination unit identifies the defect area based on the detected edge shape, and determines whether or not the original image has a defect based on the defect area. Here, the defect area is the area of the region sandwiched between the approximate straight line of the edge of the specific partial short section in the predetermined direction of the target image and the edge specified by the edge shape.

本発明によれば、比較的少ない計算量で適切に原稿画像の欠損を検出する画像読取装置が得られる。 According to the present invention, it is possible to obtain an image reading device that appropriately detects defects in a document image with a relatively small amount of calculation.

本発明の上記又は他の目的、特徴および優位性は、添付の図面とともに以下の詳細な説明から更に明らかになる。 The above or other objects, features and advantages of the present invention will be further demonstrated from the following detailed description, along with the accompanying drawings.

図1は、本発明の実施の形態に係る画像読取装置の構成を示すブロック図である。FIG. 1 is a block diagram showing a configuration of an image reading device according to an embodiment of the present invention. 図2は、非端部区間について説明する図である。FIG. 2 is a diagram illustrating a non-end section. 図3は、非端部区間のエッジに対応する近似直線について説明する図である。FIG. 3 is a diagram illustrating an approximate straight line corresponding to the edge of the non-end section. 図4は、部分短区間に対応する区分形状について説明する図である。FIG. 4 is a diagram illustrating a division shape corresponding to a partial short section. 図5は、欠損面積について説明する図である。FIG. 5 is a diagram illustrating a defect area. 図6は、実施の形態1に係る画像処理装置の動作について説明するフローチャートである。FIG. 6 is a flowchart illustrating the operation of the image processing apparatus according to the first embodiment. 図7は、図6における検査処理(ステップS13,S16)について説明するフローチャートである。FIG. 7 is a flowchart illustrating the inspection process (steps S13, S16) in FIG. 図8は、実施の形態2における画像読取部11を示す図である。FIG. 8 is a diagram showing an image reading unit 11 according to the second embodiment.

以下、図に基づいて本発明の実施の形態を説明する。 Hereinafter, embodiments of the present invention will be described with reference to the drawings.

実施の形態1. Embodiment 1.

図1は、本発明の実施の形態に係る画像読取装置の構成を示すブロック図である。図1に示す画像読取装置は、画像読取機能を有する複合機、コピー機、スキャナー機などである。図1に示す画像読取装置は、画像読取部11、プリント装置12、ファクシミリ装置13、通信装置14、操作パネル15、コントローラー16、記憶装置17などを備える。 FIG. 1 is a block diagram showing a configuration of an image reading device according to an embodiment of the present invention. The image reading device shown in FIG. 1 is a multifunction device, a copying machine, a scanner machine, or the like having an image reading function. The image reading device shown in FIG. 1 includes an image reading unit 11, a printing device 12, a facsimile device 13, a communication device 14, an operation panel 15, a controller 16, a storage device 17, and the like.

画像読取部11は、プラテングラスに載置された原稿や、自動原稿送り装置によりフィードされた原稿から原稿画像を光学的に読み取り、その原稿画像の画像データを生成する内部装置である。 The image reading unit 11 is an internal device that optically reads a document image from a document placed on a platen glass or a document fed by an automatic document feeder and generates image data of the document image.

プリント装置12は、原稿画像などをプリントする内部装置である。ファクシミリ装置13は、画像読取部11により得られた画像データなどをファクシミリ信号に変換し、そのファクシミリ信号を送信するとともに、ファクシミリ信号を受信して画像データを生成する内部装置である。通信装置14は、ネットワークインターフェイスなどであって、図示せぬ端末装置やサーバーとデータ通信を行う内部装置である。 The printing device 12 is an internal device for printing an original image or the like. The facsimile device 13 is an internal device that converts image data or the like obtained by the image reading unit 11 into a facsimile signal, transmits the facsimile signal, and receives the facsimile signal to generate image data. The communication device 14 is an internal device such as a network interface that performs data communication with a terminal device or a server (not shown).

操作パネル15は、当該画像読取装置の筺体上面側に配置され、ユーザーに対して操作画面を表示する表示装置15aおよびユーザー操作を受け付ける入力装置15bを有する内部装置である。表示装置15aは、液晶ディスプレイなどである。また、入力装置15bは、ハードキー、表示装置15aとともにソフトキーを実現するタッチパネルなどである。 The operation panel 15 is an internal device arranged on the upper surface side of the housing of the image reading device and having a display device 15a for displaying an operation screen to the user and an input device 15b for receiving the user operation. The display device 15a is a liquid crystal display or the like. Further, the input device 15b is a touch panel or the like that realizes a soft key together with a hard key and a display device 15a.

コントローラー16は、CPU(Central Processing Unit)、ROM(Read Only Memory)、RAM(Random Access Memory)などを有するコンピューター、ASIC(Application Specific Integrated Circuit)などを備え、各種処理部として動作する。つまり、コントローラー16は、ROMや記憶装置17に記憶されているプログラムをRAMにロードしてCPUで実行して、ソフトウェアによって各種処理部として動作したり、ASICなどで、ハードウェアによって各種処理部として動作したりする。また、記憶装置17は、フラッシュメモリーなどの不揮発性の記憶装置であって、データやプログラムを記憶する。 The controller 16 includes a computer having a CPU (Central Processing Unit), a ROM (Read Only Memory), a RAM (Random Access Memory), an ASIC (Application Specific Integrated Circuit), and the like, and operates as various processing units. That is, the controller 16 loads the program stored in the ROM or the storage device 17 into the RAM and executes it in the CPU to operate as various processing units by software, or as various processing units by hardware in ASIC or the like. It works. Further, the storage device 17 is a non-volatile storage device such as a flash memory, and stores data and programs.

ここでは、コントローラー16は、制御部21、対象画像取得部22、エッジ形状検出部23、および欠損判定部24として動作する。 Here, the controller 16 operates as a control unit 21, a target image acquisition unit 22, an edge shape detection unit 23, and a defect determination unit 24.

制御部21は、操作パネル15に対するユーザー操作に基づくジョブ要求および通信装置14によりホスト装置などから受信されたジョブ要求(スキャンジョブ、コピージョブ、ファクシミリ送信ジョブなどの要求)を受け付け、内部装置を使用して、ジョブ要求によって指定されたジョブを実行する。 The control unit 21 receives a job request based on a user operation for the operation panel 15 and a job request (request for a scan job, a copy job, a facsimile transmission job, etc.) received from a host device or the like by the communication device 14, and uses the internal device. And execute the job specified by the job request.

また、スキャンジョブ、コピージョブ、ファクシミリ送信ジョブなどの原稿の画像読取を伴うジョブの場合、制御部21は、画像読取部11から読取画像の画像データを取得してRAMや記憶装置17に保存するとともに、対象画像取得部22、エッジ形状検出部23、および欠損判定部24を使用して、原稿の紙折れや欠損に起因する原稿画像の欠損が発生しているか否かを判定する。原稿画像の欠損が発生している場合には、制御部21は、その旨をユーザーに報知するためのメッセージを表示装置15aに表示する。なお、自動原稿送り装置で複数ページの原稿の画像読取を連続的に行っている場合において原稿画像の欠損が発生しているページを検出したときには、制御部21は、そのページで原稿の画像読取を中断してもよいし、そのページを表示装置15aに表示しつつ原稿の画像読取を継続するようにしてもよい。 Further, in the case of a job involving image reading of a document such as a scan job, a copy job, or a facsimile transmission job, the control unit 21 acquires image data of the scanned image from the image reading unit 11 and stores it in the RAM or the storage device 17. At the same time, the target image acquisition unit 22, the edge shape detection unit 23, and the defect determination unit 24 are used to determine whether or not the original image is defective due to paper creases or defects in the original. When the original image is missing, the control unit 21 displays a message on the display device 15a to notify the user to that effect. When the automatic document feeder detects a page in which the original image is missing when the image of the original of a plurality of pages is continuously read, the control unit 21 reads the image of the original on that page. May be interrupted, or the image reading of the original may be continued while displaying the page on the display device 15a.

対象画像取得部22は、内包する原稿画像の欠損を発見すべき対象画像を取得する。この実施の形態では、対象画像取得部22は、原稿の画像読取によって得られた読取画像に対して所定の画像処理を実行して得られた画像を対象画像とする。なお、読取画像は、画像読取部11により所定サイズの領域(原稿を含む)の画像を読み取ることで得られた画像である。 The target image acquisition unit 22 acquires a target image for which a defect in the included original image should be found. In this embodiment, the target image acquisition unit 22 uses an image obtained by performing a predetermined image process on the scanned image obtained by scanning the image of the original as the target image. The scanned image is an image obtained by scanning an image in a region (including a document) of a predetermined size by the image scanning unit 11.

具体的には、対象画像取得部22は、原稿の画像読取によって得られた読取画像に対して、縮小処理(解像度変換)、グレースケール画像への変換、エッジ強調処理、および膨張収縮処理を行う。なお、グレースケール画像への変換は、読取画像が輝度データを含んでいる場合(読取画像がグレースケール画像である場合など)には省略される。また、エッジ強調処理は、縮小処理により読取画像から得られた縮小画像において、各画素の画素値を空間的に(隣接する画素との)輝度差が所定閾値より大きいか否かで2値化することでエッジ画像を生成する。膨張収縮処理は、エッジ画像に対して膨張処理を行った後に収縮処理を行うことで、エッジの不適切な途切れを抑制する。ここでは、エッジ画像に対して膨張収縮処理を行うことで得られた2値画像が、対象画像とされる。 Specifically, the target image acquisition unit 22 performs reduction processing (resolution conversion), conversion to a grayscale image, edge enhancement processing, and expansion / contraction processing on the scanned image obtained by scanning the image of the original. .. The conversion to a grayscale image is omitted when the scanned image contains luminance data (for example, when the scanned image is a grayscale image). Further, in the edge enhancement processing, in the reduced image obtained from the scanned image by the reduction processing, the pixel value of each pixel is binarized depending on whether or not the luminance difference (with the adjacent pixel) is spatially larger than a predetermined threshold value. By doing so, an edge image is generated. The expansion / contraction treatment suppresses inappropriate breaks in the edges by performing the expansion / contraction processing after the expansion processing on the edge image. Here, the binary image obtained by performing the expansion / contraction processing on the edge image is regarded as the target image.

なお、対象画像取得部22は、原稿の画像読取によって得られた読取画像を対象画像としてもよい。 The target image acquisition unit 22 may use the scanned image obtained by scanning the image of the original as the target image.

エッジ形状検出部23は、対象画像内の原稿画像の先端エッジおよび後端エッジの少なくとも一方(つまり、主走査方向に沿って延びるエッジ)のエッジ形状を検出する。 The edge shape detecting unit 23 detects the edge shape of at least one of the front end edge and the rear end edge (that is, the edge extending along the main scanning direction) in the target image.

図2は、対象画像における非端部区間について説明する図である。図3は、非端部区間のエッジに対応する近似直線について説明する図である。 FIG. 2 is a diagram illustrating a non-end section in the target image. FIG. 3 is a diagram illustrating an approximate straight line corresponding to the edge of the non-end section.

また、エッジ形状検出部23は、例えば図2に示すように、対象画像の全幅W(主走査方向の幅)から対象画像における両側の所定幅dWの端部を除外した非端部区間VWにおいて、対象画像内の原稿画像の先端エッジおよび後端エッジの少なくとも一方のエッジ形状を検出する。具体的には、エッジ形状検出部23は、(a)対象画像における両側の所定幅dWの端部を除外した非端部区間VWのエッジに対応する近似直線を特定し、(b)非端部区間のエッジに対応する近似直線が所定閾値以上の正解率で得られるか否かを判定する。さらに、エッジ形状検出部23は、(a)非端部区間のエッジに対応する近似直線が所定閾値以上の正解率で得られる場合、後述の区分形状探索処理を行わず、(b)非端部区間のエッジに対応する近似直線が所定閾値以上の正解率で得られない場合、後述の区分形状探索処理を行う。 Further, as shown in FIG. 2, for example, the edge shape detecting unit 23 is in the non-end section VW in which the ends of the predetermined width dW on both sides of the target image are excluded from the total width W (width in the main scanning direction) of the target image. , Detects at least one edge shape of the front edge and the trailing edge of the original image in the target image. Specifically, the edge shape detection unit 23 identifies (a) an approximate straight line corresponding to the edge of the non-end section VW excluding the ends of the predetermined width dW on both sides in the target image, and (b) the non-end. It is determined whether or not an approximate straight line corresponding to an edge of a section can be obtained with a correct answer rate equal to or higher than a predetermined threshold value. Further, the edge shape detection unit 23 does not perform the divisional shape search process described later when (a) an approximate straight line corresponding to the edge of the non-end section is obtained with a correct answer rate equal to or higher than a predetermined threshold value, and (b) the non-end section. When the approximate straight line corresponding to the edge of the section cannot be obtained with the correct answer rate equal to or higher than the predetermined threshold value, the division shape search process described later is performed.

なお、近似直線は、当該区間において主走査方向に沿って所定間隔でサンプリングされた複数のエッジ点の座標値に基づいて最小二乗法によって導出される(以下の近似直線も同様に導出される)。 The approximate straight line is derived by the least squares method based on the coordinate values of a plurality of edge points sampled at predetermined intervals along the main scanning direction in the section (the following approximate straight line is also derived). ..

ここで、エッジ画像に対して膨張収縮処理を行うことで得られた2値画像が対象画像とされている場合、エッジ点は、その2値のうち、エッジ位置を示す値を有するエッジ画素であって、先端エッジについては対象画像の上端から探索して最初に検出されるエッジ画素であり、後端エッジについては対象画像の下端から探索して最初に検出されるエッジ画素である。 Here, when the binary image obtained by performing the expansion / contraction processing on the edge image is the target image, the edge point is an edge pixel having a value indicating the edge position among the binary values. The leading edge is the edge pixel searched from the upper end of the target image and detected first, and the trailing edge is the edge pixel searched from the lower end of the target image and detected first.

また、対象画像が2値化されておらず、読取画像と同様の多階調を有する画像である場合、エッジ点は、副走査方向において隣接する画素との輝度差が所定閾値以上であるエッジ画素であって、先端エッジについては対象画像の上端から探索して最初に検出されるエッジ画素であり、後端エッジについては対象画像の下端から探索して最初に検出されるエッジ画素である。 Further, when the target image is not binarized and has the same multi-gradation as the scanned image, the edge point is an edge whose brightness difference from the adjacent pixel in the sub-scanning direction is equal to or more than a predetermined threshold value. The pixel is an edge pixel that is first detected by searching from the upper end of the target image for the front edge, and is an edge pixel that is first detected by searching from the lower end of the target image for the rear end edge.

また、上述の所定幅dWは、次式に従って、原稿の画像読取時の斜行における所定の最大斜行角度θに対応して定数として設定されている。 Further, the predetermined width dW described above is set as a constant corresponding to a predetermined maximum skew angle θ in skew when reading an image of a document according to the following equation.

dW=H×sin(θ) dW = H × sin (θ)

ここで、Hは、原稿画像の高さであり、画像読取対象の原稿のサイズから予め特定される。 Here, H is the height of the original image, and is specified in advance from the size of the original to be read.

また、上述の正解率は、特定区間(ここでは、非端部区間)においてサンプリングされたエッジ点のうち、近似直線から所定範囲(副走査方向における所定範囲)内に位置するエッジ点の割合である(以下の正解率も同様である)。 Further, the above-mentioned correct answer rate is the ratio of the edge points sampled in the specific section (here, the non-end section), which are located within a predetermined range (predetermined range in the sub-scanning direction) from the approximate straight line. Yes (the same applies to the correct answer rate below).

画像欠損がない場合には、例えば図3に示すエッジ点P1〜P9のように、直線状に位置するエッジ点が検出されるので、近似直線からの距離が短いエッジ点が多くなり正解率が高くなる。一方、画像欠損がある場合には、例えば図3に示すエッジ点P1〜P6,Pa,Pb,Pcのように、直線状に位置していないエッジ点が検出されるので、近似直線からの距離が短いエッジ点が少なくなり正解率が低くなる。 When there is no image defect, edge points located in a straight line are detected, for example, edge points P1 to P9 shown in FIG. 3, so that the number of edge points having a short distance from the approximate straight line increases and the accuracy rate increases. It gets higher. On the other hand, when there is an image defect, edge points that are not located in a straight line, such as edge points P1 to P6, Pa, Pb, and Pc shown in FIG. 3, are detected, so that the distance from the approximate straight line is detected. However, the number of short edge points decreases and the accuracy rate decreases.

図4は、部分短区間に対応する区分形状について説明する図である。 FIG. 4 is a diagram illustrating a division shape corresponding to a partial short section.

さらに、エッジ形状検出部23は、対象画像の所定方向(ここでは主走査方向)における最初の部分短区間を設定してから、部分短区間に対応する区分形状を導出する区分形状探索処理を繰り返して実行することで、エッジ形状を特定する。 Further, the edge shape detection unit 23 repeats the division shape search process for deriving the division shape corresponding to the partial short section after setting the first partial short section in a predetermined direction (here, the main scanning direction) of the target image. By executing this, the edge shape is specified.

区分形状探索処理において、エッジ形状検出部23は、例えば図4に示すように、(a)(現時点で設定されている)部分短区間#iのエッジに対応する近似直線#i(図4では近似直線#1)を特定して、その近似直線#iを、部分短区間#iについての区分形状とし、(b)その部分短区間#iの外側に向かって(つまり、部分短区間#iの少なくとも一方の側から対象画像の主走査方向における端部に向かって)所定間隔でエッジ点PEi−jをサンプリングして検出していき、その近似直線#iからエッジ点PEi−jまでの距離dEが所定範囲TH(副走査方向における所定範囲)内にあるか否かを判定し、その近似直線からエッジ点PEi−jまでの距離dEが所定範囲THを超えた場合には、そのエッジ点Pi−jの位置に対応して次の部分短区間#(i+1)(図4では近似直線#2)を設定する。 In the division shape search process, the edge shape detection unit 23, as shown in FIG. 4, for example, (a) is an approximate straight line # i (in FIG. 4) corresponding to the edge of the partial short section #i (currently set). An approximate straight line # 1) is specified, and the approximate straight line #i is used as a division shape for the partial short section #i, and (b) toward the outside of the partial short section #i (that is, the partial short section #i). Edge point PEi-j is sampled and detected at predetermined intervals (from at least one side of the target image toward the end in the main scanning direction of the target image), and the distance from the approximate straight line #i to the edge point PEi-j. It is determined whether or not dE is within the predetermined range TH (predetermined range in the sub-scanning direction), and if the distance dE from the approximate straight line to the edge point PEi-j exceeds the predetermined range TH, the edge point The next partial short section # (i + 1) (approximate straight line # 2 in FIG. 4) is set corresponding to the position of Pi−j.

1つの部分短区間について得られる区分形状は、近似直線の(一次式)(あるいは、その数式および区間の端点座標)で示され、エッジ形状情報に含められて記憶装置17やコントローラー16のRAMに記憶される。 The division shape obtained for one partial short interval is indicated by an approximate straight line (linear equation) (or the equation and the end point coordinates of the interval), is included in the edge shape information, and is stored in the RAM of the storage device 17 or the controller 16. It will be remembered.

図4に示す場合では、部分短区間#1(最初の部分短区間)の一方の外側(主走査方向の正方向)に向かってエッジ点PE1−jがサンプリングされていき、部分短区間#1に対応する近似直線#1からエッジ点PE1−7までの距離dEが所定範囲TH外となったため、エッジ点PE1−7の位置から所定幅の部分短区間#2が設定される。そして、部分短区間#2に対応する近似直線#2が導出され、同一の方向に向かって、エッジ点PE2−jがサンプリングされ検出されていき、側端エッジの位置となりエッジ点が検出されなくなるため、この方向(一方の外側方向)についての区分形状(近似直線)の探索が終了する。同様に、部分短区間#1(最初の部分短区間)の他方の外側(主走査方向の負方向)についても、区分形状(近似直線)の探索が行われる。そして、両方向への探索で検出された区分形状(近似直線)が、先端エッジのエッジ形状を構成する複数の区分形状(近似直線)としてエッジ形状情報に含められる。 In the case shown in FIG. 4, the edge point PE1-j is sampled toward the outside (positive direction in the main scanning direction) of the partial short section # 1 (first partial short section), and the partial short section # 1 is sampled. Since the distance dE from the approximate straight line # 1 corresponding to the edge point PE1-7 is out of the predetermined range TH, a partial short section # 2 having a predetermined width is set from the position of the edge point PE1-7. Then, an approximate straight line # 2 corresponding to the partial short interval # 2 is derived, and the edge point PE2-j is sampled and detected in the same direction, and the position of the side edge is reached so that the edge point cannot be detected. Therefore, the search for the divided shape (approximate straight line) in this direction (one outer direction) is completed. Similarly, the division shape (approximate straight line) is searched for the other outside (negative direction in the main scanning direction) of the partial short section # 1 (first partial short section). Then, the divided shape (approximate straight line) detected by the search in both directions is included in the edge shape information as a plurality of divided shapes (approximate straight line) constituting the edge shape of the tip edge.

なお、上述の部分短区間は、原稿の上辺または下辺の10分の1程度の幅に対応する区間であって、上述の最初の部分短区間#1は、ここでは約2cmであり、上述の次の部分短区間#i(i>1)は、最初の部分短区間より短く、ここでは約1.5cmである。 The above-mentioned partial short section corresponds to a width of about 1/10 of the upper side or the lower side of the document, and the above-mentioned first partial short section # 1 is about 2 cm here, and is described above. The next partial short section #i (i> 1) is shorter than the first partial short section, which is about 1.5 cm here.

また、上述の最初の部分短区間について、エッジ形状検出部23は、(a)最初の部分短区間の候補として、対象画像の所定方向(ここでは、主走査方向)における所定区間を選択し、(b)その所定区間のエッジに対応する近似直線が所定閾値以上の正解率で得られるか否かを判定し、(c)その所定区間のエッジに対応する近似直線が所定閾値以上の正解率で得られる場合には、その所定区間を最初の部分短区間とし、(d)その所定区間のエッジに対応する近似直線が所定閾値以上の正解率で得られない場合には、その所定区間とは別の区間を選択し、その別の区間のエッジに対応する近似直線が所定閾値以上の正解率で得られる場合には、その別の区間を最初の部分短区間とする。ここでの正解率は、所定区間において、近似直線から所定範囲(副走査方向における所定範囲)内にあるエッジ点の割合である。 Further, with respect to the above-mentioned first partial short section, the edge shape detection unit 23 (a) selects a predetermined section in a predetermined direction (here, the main scanning direction) of the target image as a candidate for the first partial short section. (B) It is determined whether or not the approximate straight line corresponding to the edge of the predetermined section can be obtained with the correct answer rate of the predetermined threshold or more, and (c) the approximate straight line corresponding to the edge of the predetermined section has the correct answer rate of the predetermined threshold or more. If it is obtained in, the predetermined section is set as the first partial short section, and (d) if the approximate straight line corresponding to the edge of the predetermined section cannot be obtained with the correct answer rate equal to or higher than the predetermined threshold, the predetermined section is used. Selects another section, and if an approximate straight line corresponding to the edge of the other section is obtained with a correct answer rate equal to or higher than a predetermined threshold, the other section is set as the first partial short section. The correct answer rate here is the ratio of edge points within a predetermined range (predetermined range in the sub-scanning direction) from the approximate straight line in a predetermined section.

つまり、近似直線が所定閾値以上の正解率で得られる区間(部分短区間と同一幅を有する区間)が探索される。ここでは、まず、最初の区間(上述の所定区間)として、対象画像において主走査方向における中央の区間が選択される。この区間で上述のような近似直線が得られない場合には、最初の区間の、右および左のうちの一方に隣接する区間(上述の別の区間)が選択される。この区間で上述のような近似直線が得られない場合には、最初の区間の、右および左のうちの他方に隣接する区間(上述の別の区間)が選択される。 That is, a section (a section having the same width as the partial short section) in which the approximate straight line is obtained with a correct answer rate of a predetermined threshold value or more is searched. Here, first, as the first section (predetermined section described above), the central section in the main scanning direction is selected in the target image. If the approximate straight line as described above cannot be obtained in this section, the section adjacent to one of the right and left of the first section (another section described above) is selected. If the approximate straight line as described above is not obtained in this section, the section adjacent to the other of the right and left of the first section (another section described above) is selected.

なお、区分形状探索処理における所定範囲は、正解率を導出する際に使用する所定範囲と同じでもよいし、異なっていてもよい。 The predetermined range in the division shape search process may be the same as or different from the predetermined range used when deriving the correct answer rate.

また、欠損判定部24は、検出されたエッジ形状に基づいて、原稿画像の欠損が発生しているか否かを判定する。具体的には、欠損判定部24は、検出されたエッジ形状に基づいて欠損面積を特定し、欠損面積に基づいて、原稿画像に欠損が発生しているか否かを判定する。 Further, the defect determination unit 24 determines whether or not the original image is defective based on the detected edge shape. Specifically, the defect determination unit 24 identifies the defect area based on the detected edge shape, and determines whether or not the original image has a defect based on the defect area.

図5は、欠損面積について説明する図である。ここで、欠損面積は、例えば図5に示すように、対象画像の所定方向における特定の部分短区間のエッジの近似直線(ここでは、最初の部分短区間#1に対応する近似直線#1)とエッジ形状で特定されるエッジとに挟まれる1または複数の領域の面積である。 FIG. 5 is a diagram illustrating a defect area. Here, the defect area is, for example, as shown in FIG. 5, an approximate straight line of an edge of a specific partial short section in a predetermined direction of a target image (here, an approximate straight line # 1 corresponding to the first partial short section # 1). It is the area of one or more regions sandwiched between the edge and the edge specified by the edge shape.

例えば、図5に示すように3つの近似直線#1,#2,#3が検出された場合、まず、最初の部分短区間についての近似直線#1と隣接する部分短区間についての近似直線#2,#3との交点C1,C2の座標値がそれぞれ導出される。図5では、近似直線#2,#3の外側に近似直線はないが、近似直線#2,#3の外側に近似直線がある場合には、順次、近似直線の交点の座標値が導出される。他方、側端エッジあるいは非端部区間の端点に接続する区分形状の近似直線#2,#3については、区分形状の近似直線#2,#3と、側端エッジあるいは非端部区間の端点との交点Ce1,Ce2の座標値がそれぞれ導出される。このようにして得られた交点C1,C2,・・・,Ce1,Ce2と、近似直線#1とに基づき、ここでは2つの欠損領域の形状が特定され、その欠損領域の面積A1,A2が導出される。そして、上述の欠損面積Aは、欠損領域の面積A1,A2の総和とされる。 For example, when three approximate straight lines # 1, # 2, and # 3 are detected as shown in FIG. 5, first, the approximate straight line # 1 for the first partial short interval and the approximate straight line # for the adjacent partial short interval # The coordinate values of the intersections C1 and C2 with 2 and # 3 are derived, respectively. In FIG. 5, there is no approximate straight line outside the approximate straight lines # 2 and # 3, but when there is an approximate straight line outside the approximate straight lines # 2 and # 3, the coordinate values of the intersections of the approximate straight lines are sequentially derived. NS. On the other hand, for the approximate straight lines # 2 and # 3 of the division shape connected to the end points of the side edge or the non-end section, the approximation straight lines # 2 and # 3 of the division shape and the end points of the side end edge or the non-end section are used. The coordinate values of the intersections Ce1 and Ce2 with and are derived respectively. Based on the intersections C1, C2, ..., Ce1, Ce2 thus obtained and the approximate straight line # 1, the shapes of the two defective regions are specified here, and the areas A1 and A2 of the defective regions are determined. Derived. The defect area A described above is the sum of the areas A1 and A2 of the defect region.

また、欠損判定部24は、先端エッジまたは後端エッジについて、非端部区間のエッジに対応する近似直線が所定閾値以上の正解率で得られない場合、そのエッジについて、区分形状探索処理によって検出されたエッジ形状に基づいて、原稿画像に欠損が発生しているか否かを判定する。 Further, when the approximate straight line corresponding to the edge of the non-end portion section cannot be obtained with the correct answer rate of a predetermined threshold value or more for the front end edge or the rear end edge, the defect determination unit 24 detects the edge by the division shape search process. It is determined whether or not the original image has a defect based on the edge shape.

また、欠損判定部24は、先端エッジおよび後端エッジの両方について、非端部区間のエッジに対応する近似直線が所定閾値以上の正解率で得られる場合において、先端エッジの近似直線と後端エッジの近似直線とが略平行であるときには、原稿画像に欠損が発生していないと判定し、先端エッジの近似直線と後端エッジの近似直線とが略平行ではないときには、原稿画像に欠損が発生していると判定する。 Further, the defect determination unit 24 determines the approximate straight line and the rear end of the tip edge when the approximate straight line corresponding to the edge of the non-end portion section can be obtained with a correct answer rate of a predetermined threshold value or more for both the tip edge and the rear end edge. When the approximate straight line of the edge is substantially parallel, it is determined that the original image has no defect, and when the approximate straight line of the leading edge and the approximate straight line of the trailing edge are not substantially parallel, the original image has a defect. Judge that it has occurred.

次に、実施の形態1に係る画像処理装置の動作について説明する。図6は、実施の形態1に係る画像処理装置の動作について説明するフローチャートである。図7は、図6における検査処理(ステップS13,S16)について説明するフローチャートである。 Next, the operation of the image processing apparatus according to the first embodiment will be described. FIG. 6 is a flowchart illustrating the operation of the image processing apparatus according to the first embodiment. FIG. 7 is a flowchart illustrating the inspection process (steps S13, S16) in FIG.

制御部21は、画像読取を伴うジョブのジョブ要求を受け付けると、まず、画像読取部11に、原稿の画像読取を実行させ、画像読取部11から読取画像の画像データを取得して保存するとともに、対象画像取得部22、エッジ形状検出部23、および欠損判定部24に、以下のように検査処理を実行させる。 When the control unit 21 receives a job request for a job accompanied by image reading, first, the image reading unit 11 causes the image reading unit 11 to read the image of the original, acquires the image data of the scanned image from the image reading unit 11, and saves the image data. , The target image acquisition unit 22, the edge shape detection unit 23, and the defect determination unit 24 are made to execute the inspection process as follows.

まず、対象画像取得部22は、読取画像に対して前処理(上述の縮小処理など)を実行して対象画像を生成する(ステップS11)。 First, the target image acquisition unit 22 executes preprocessing (such as the reduction process described above) on the scanned image to generate the target image (step S11).

次に、制御部21は、まず、原稿の上辺(先端エッジ)を検査対象として選択し(ステップS12)、対象画像取得部22、エッジ形状検出部23、および欠損判定部24に、先端エッジについての検査処理を実行させる(ステップS13)。 Next, the control unit 21 first selects the upper side (tip edge) of the document as an inspection target (step S12), and causes the target image acquisition unit 22, the edge shape detection unit 23, and the defect determination unit 24 to display the tip edge. (Step S13).

制御部21は、上辺(先端エッジ)についての検査処理(ステップS13)の検査結果に基づいて、上辺(先端エッジ)において画像欠損が検出されたか否かを判定する(ステップS14)。 The control unit 21 determines whether or not an image defect is detected on the upper side (tip edge) based on the inspection result of the inspection process (step S13) for the upper side (tip edge) (step S14).

上辺(先端エッジ)において画像欠損が発生していないと判定した場合、制御部21は、原稿の下辺(後端エッジ)を検査対象として選択し(ステップS15)、対象画像取得部22、エッジ形状検出部23、および欠損判定部24に、後端エッジについての検査処理を実行させる(ステップS16)。 When it is determined that no image defect has occurred on the upper side (tip edge), the control unit 21 selects the lower side (rear end edge) of the document as an inspection target (step S15), and the target image acquisition unit 22, edge shape. The detection unit 23 and the defect determination unit 24 are made to execute the inspection process for the rear end edge (step S16).

制御部21は、下辺(後端エッジ)についての検査処理(ステップS16)の検査結果に基づいて、下辺(後端エッジ)において画像欠損が検出されたか否かを判定する(ステップS17)。 The control unit 21 determines whether or not an image defect is detected on the lower side (rear end edge) based on the inspection result of the inspection process (step S16) for the lower side (rear end edge) (step S17).

下辺(後端エッジ)において画像欠損が発生していないと判定された場合、欠損判定部24は、先端エッジのエッジ形状(近似直線)と後端エッジのエッジ形状(近似直線)とを参照し、両者が略平行であるか否かを判定する(ステップS18)。ここで、両者間の角度が所定閾値未満であれば、両者が略平行であると判定される。 When it is determined that no image defect has occurred on the lower edge (rear end edge), the defect determination unit 24 refers to the edge shape (approximate straight line) of the tip edge and the edge shape (approximate straight line) of the rear end edge. , It is determined whether or not both are substantially parallel (step S18). Here, if the angle between the two is less than a predetermined threshold value, it is determined that the two are substantially parallel.

なお、エッジ形状が複数の区分形状(つまり、複数の近似直線)を有する場合には、例えば、複数の区分形状のうちの最も長い区分形状の近似直線や、対象画像の中央に位置する区分形状の近似直線を使用して、先端エッジの近似直線の傾き角と後端エッジ近似直線の傾き角との差分が導出され、その差分に基づいて、両者が略平行であるか否かが判定される。 When the edge shape has a plurality of divided shapes (that is, a plurality of approximate straight lines), for example, an approximate straight line of the longest divided shape among the plurality of divided shapes or a divided shape located in the center of the target image. Using the approximate straight line of, the difference between the inclination angle of the approximate straight line of the leading edge and the tilt angle of the approximate straight line of the trailing edge is derived, and based on the difference, it is determined whether or not the two are substantially parallel. NS.

ここで、両者が略平行であると判定された場合、制御部21は、当該対象画像に画像欠損が発生していないと判定する(ステップS19)。 Here, when it is determined that the two are substantially parallel, the control unit 21 determines that no image defect has occurred in the target image (step S19).

一方、ステップS14またはステップS17において画像欠損が検出されたと判定された場合、およびステップS18において先端エッジのエッジ形状および後端エッジのエッジ形状が略平行ではないと判定された場合、制御部21は、当該対象画像に画像欠損が発生していると判定する(ステップS20)。 On the other hand, when it is determined in step S14 or step S17 that an image defect is detected, and when it is determined in step S18 that the edge shape of the tip edge and the edge shape of the trailing edge are not substantially parallel, the control unit 21 , It is determined that an image defect has occurred in the target image (step S20).

ここで、図7を参照して、ステップS13およびステップS16の検査処理について説明する。 Here, the inspection process of step S13 and step S16 will be described with reference to FIG. 7.

まず、エッジ形状検出部23は、検査対象のエッジ(先端エッジまたは後端エッジ)について、非端部区間VWを設定し(ステップS41)、非端部区間VWにおいて所定間隔でエッジ点をサンプリングし、エッジ点の座標値に基づいて近似直線を導出し(ステップS42)、非端部区間VWにおける正解率が所定閾値以上であるか否かを判定する(ステップS43)。なお、この所定間隔は、区分形状探索処理におけるエッジ点の間隔より広く設定される。 First, the edge shape detecting unit 23 sets a non-end section VW for the edge to be inspected (tip edge or trailing edge) (step S41), and samples edge points at predetermined intervals in the non-end section VW. , An approximate straight line is derived based on the coordinate values of the edge points (step S42), and it is determined whether or not the correct answer rate in the non-end section VW is equal to or greater than a predetermined threshold value (step S43). It should be noted that this predetermined interval is set wider than the interval between the edge points in the division shape search process.

正解率が所定閾値以上であると判定された場合、エッジ形状検出部23は、当該近似直線を1つの区分形状として含むエッジ形状情報を記憶し(ステップS44)、欠損判定部24は、当該検査対象のエッジでは画像欠損が検出されなかったと判定し(ステップS45)、検査処理を終了する。 When it is determined that the correct answer rate is equal to or higher than a predetermined threshold value, the edge shape detection unit 23 stores the edge shape information including the approximate straight line as one division shape (step S44), and the defect determination unit 24 performs the inspection. It is determined that no image defect is detected at the target edge (step S45), and the inspection process is terminated.

一方、正解率が所定閾値未満であると判定された場合、エッジ形状検出部23は、まず、部分短区間設定処理を行い、最初の部分短区間の設定を試みる(ステップS46)。 On the other hand, when it is determined that the correct answer rate is less than the predetermined threshold value, the edge shape detection unit 23 first performs the partial short section setting process and tries to set the first partial short section (step S46).

具体的には、部分短区間設定処理では、エッジ形状検出部23は、上述のように、部分短区間の候補となる区間を設定し、その区間でサンプリングされたエッジ点に基づく近似直線を導出し、正解率が所定閾値以上である近似直線が得られる区間を、最初の部分短区間とする。そして、所定回数の候補区間を設定して最初の部分短区間を探索したにも拘わらず、正解率が所定閾値以上である近似直線が得られる区間が発見されなかった場合には、エッジ形状検出部23は、最初の部分短区間を設定せずに、部分短区間設定処理を終了する。 Specifically, in the partial short section setting process, the edge shape detection unit 23 sets a section that is a candidate for the partial short section as described above, and derives an approximate straight line based on the edge points sampled in that section. Then, the section in which the approximate straight line having the correct answer rate equal to or higher than the predetermined threshold value is obtained is defined as the first partial short section. Then, when a section in which an approximate straight line having a correct answer rate equal to or higher than a predetermined threshold value is not found even though the candidate sections are set a predetermined number of times and the first partial short section is searched, the edge shape is detected. The unit 23 ends the partial short section setting process without setting the first partial short section.

そして、欠損判定部24は、部分短区間設定処理において、最初の部分短区間が設定されたか否かを判定し(ステップS47)、最初の部分短区間が設定されなかった場合には、欠損判定部24は、当該検査対象のエッジについて画像欠損が検出されたと判定し(ステップS48)、検査処理を終了する。 Then, the defect determination unit 24 determines whether or not the first partial short section is set in the partial short section setting process (step S47), and if the first partial short section is not set, the defect determination unit 24 determines whether or not the first partial short section is set. The unit 24 determines that an image defect has been detected for the edge to be inspected (step S48), and ends the inspection process.

一方、最初の部分短区間が設定された場合、エッジ形状検出部23は、その部分短区間についての近似直線(ここでは、部分短区間設定処理(ステップS46)で当該区間について特定されたもの)を1つの区分形状として当該検査対象のエッジのエッジ形状情報に追加する(ステップS49)。 On the other hand, when the first partial short section is set, the edge shape detection unit 23 uses an approximate straight line for the partial short section (here, the section specified in the partial short section setting process (step S46)). Is added to the edge shape information of the edge to be inspected as one division shape (step S49).

次に、エッジ形状検出部23は、当該区分形状に別の区分形状が連続しているか否かを判定する(ステップS50)。 Next, the edge shape detection unit 23 determines whether or not another division shape is continuous with the division shape (step S50).

具体的には、エッジ形状検出部23は、エッジ点がサンプリングされなくなるか、近似直線からの距離が所定範囲外となるエッジ点(以下、範囲外エッジ点という)が現れるまで、部分短区間の端点から所定間隔でエッジ点をサンプリングしていき、(a)近似直線からの距離が所定範囲外となるエッジ点が現れた場合、当該区分形状に別の区分形状が連続していると判定し、(b)近似直線からの距離が所定範囲外となるエッジ点が現れずにエッジ点がサンプリングされなくなった場合(つまり、ここでは非端部区間の端点まですべてのエッジ点が近似直線から所定範囲内の距離に位置している場合)、当該区分形状に別の区分形状が連続していないと判定する。 Specifically, the edge shape detecting unit 23 is a partial short section until the edge points are no longer sampled or an edge point (hereinafter referred to as an out-of-range edge point) whose distance from the approximate straight line is out of the predetermined range appears. Edge points are sampled at predetermined intervals from the end points, and (a) when an edge point whose distance from the approximate straight line is out of the predetermined range appears, it is determined that another division shape is continuous with the division shape. , (B) When the edge points are not sampled without the appearance of the edge points whose distance from the approximate straight line is out of the predetermined range (that is, here, all the edge points from the approximate straight line to the end points of the non-end section are predetermined. If it is located at a distance within the range), it is determined that another division shape is not continuous with the division shape.

当該区分形状に別の区分形状が連続していると判定した場合、エッジ形状検出部23は、検出した範囲外エッジ点に基づいて、次の部分短区間(そのエッジ点から所定幅の区間)の設定を試みる(ステップS51)。 When it is determined that another division shape is continuous with the division shape, the edge shape detection unit 23 determines the next partial short section (a section having a predetermined width from the edge point) based on the detected out-of-range edge point. Attempts to set (step S51).

具体的には、エッジ形状検出部23は、その範囲外エッジ点から所定幅の区間を次の部分短区間の候補とし、部分短区間設定処理(ステップS46)と同様に、その区間についての近似直線を導出し正解率を導出し、その正解率が所定閾値以上であれば、その候補区間を次の部分短区間として設定し、その正解率が所定閾値未満であれば、次の部分短区間を設定しない。 Specifically, the edge shape detecting unit 23 sets a section having a predetermined width from the edge point outside the range as a candidate for the next partial short section, and approximates the section in the same manner as in the partial short section setting process (step S46). A straight line is derived to derive the correct answer rate, and if the correct answer rate is equal to or higher than the predetermined threshold value, the candidate section is set as the next partial short section, and if the correct answer rate is less than the predetermined threshold value, the next partial short section is set. Do not set.

そして、エッジ形状検出部23は、次の部分短区間が設定されたか否かを判定し(ステップS52)、次の部分短区間が設定された場合には、設定した当該次の部分短区間についてステップS49以降の処理を同様に実行する。一方、次の部分短区間が設定されなかった場合には、欠損判定部24は、当該検査対象のエッジについて画像欠損が検出されたと判定し(ステップS48)、検査処理を終了する。 Then, the edge shape detection unit 23 determines whether or not the next partial short section is set (step S52), and if the next partial short section is set, the set next partial short section is about. The processing after step S49 is executed in the same manner. On the other hand, when the next partial short section is not set, the defect determination unit 24 determines that an image defect has been detected for the edge to be inspected (step S48), and ends the inspection process.

このようにして、エッジ形状検出部23は、別の区分形状が連続しなくなるまで区分形状探索処理を実行して、エッジ形状を特定する。 In this way, the edge shape detection unit 23 executes the division shape search process until another division shape is no longer continuous, and specifies the edge shape.

そして、現時点の区分形状に別の区分形状が連続していないと判定された場合、欠損判定部24は、特定されたエッジ形状に基づいて、上述の欠損面積が所定閾値以上であるか否かを判定(ステップS53)。そして、欠損面積が所定閾値以上である場合、欠損判定部24は、画像欠損が検出されたと判定し(ステップS48)、検査処理を終了する。一方、欠損面積が所定閾値未満である場合、欠損判定部24は、画像欠損が検出されなかったと判定し(ステップS45)、検査処理を終了する。 Then, when it is determined that another division shape is not continuous with the current division shape, the defect determination unit 24 determines whether or not the above-mentioned defect area is equal to or larger than a predetermined threshold value based on the specified edge shape. Is determined (step S53). Then, when the defect area is equal to or larger than a predetermined threshold value, the defect determination unit 24 determines that an image defect has been detected (step S48), and ends the inspection process. On the other hand, when the defect area is less than a predetermined threshold value, the defect determination unit 24 determines that no image defect has been detected (step S45), and ends the inspection process.

以上のように、上記実施の形態1によれば、エッジ形状検出部23は、対象画像内の原稿画像の先端エッジおよび後端エッジの少なくとも一方のエッジ形状を検出する。欠損判定部24は、検出されたエッジ形状に基づいて、原稿画像の欠損が発生しているか否かを判定する。そして、エッジ形状検出部23は、対象画像の所定方向における最初の部分短区間を設定してから、部分短区間に対応する区分形状を導出する区分形状探索処理を繰り返して実行することで、エッジ形状を特定する。さらに、エッジ形状検出部23は、区分形状探索処理において、(a)部分短区間のエッジに対応する近似直線を特定して、特定した近似直線を区分形状とし、(b)部分短区間の少なくとも一方の側からその所定方向における端部に向かって所定間隔でエッジ点を検出していき、近似直線からエッジ点までの距離が所定範囲外となった場合には、エッジ点に対応して次の部分短区間を設定する。 As described above, according to the first embodiment, the edge shape detecting unit 23 detects at least one edge shape of the front end edge and the rear end edge of the original image in the target image. The defect determination unit 24 determines whether or not the original image is defective based on the detected edge shape. Then, the edge shape detection unit 23 sets the first partial short section in a predetermined direction of the target image, and then repeatedly executes the section shape search process for deriving the section shape corresponding to the partial short section, thereby performing the edge. Identify the shape. Further, the edge shape detection unit 23 specifies (a) an approximate straight line corresponding to the edge of the partial short section in the section shape search process, and uses the specified approximate straight line as the section shape, and (b) at least the partial short section. Edge points are detected at predetermined intervals from one side toward the end in the predetermined direction, and if the distance from the approximate straight line to the edge point is out of the predetermined range, the next is corresponding to the edge point. Set the partial short section of.

これにより、サンプリングするエッジ点が比較的少なくて済むため、比較的少ない計算量で適切に原稿画像の欠損が検出される。 As a result, since the number of edge points to be sampled is relatively small, defects in the original image can be appropriately detected with a relatively small amount of calculation.

また、上記実施の形態1によれば、エッジ形状検出部23は、対象画像における両側の所定幅の端部を除外した非端部区間において、対象画像内の原稿画像の先端エッジおよび後端エッジの少なくとも一方のエッジ形状を検出する。ここで、その所定幅は、原稿の画像読取時の斜行における所定の最大斜行角度に対応して設定されている。 Further, according to the first embodiment, the edge shape detecting unit 23 has the front end edge and the rear end edge of the original image in the target image in the non-end portion section excluding the ends of the predetermined widths on both sides of the target image. Detects at least one edge shape of. Here, the predetermined width is set corresponding to a predetermined maximum skew angle in skew when scanning an image of a document.

これにより、サンプリングするエッジ点が比較的少なくて済むとともに、画像読取時の原稿の斜行に起因して側端エッジが誤ってエッジ点としてサンプリングされることが抑制されるため、比較的少ない計算量で適切に原稿画像の欠損が検出される。 As a result, the number of edge points to be sampled is relatively small, and the side edge edge is prevented from being erroneously sampled as an edge point due to the skew of the original during image scanning, so that the calculation is relatively small. Defects in the original image are detected appropriately by the amount.

また、上記実施の形態1によれば、最初の部分短区間を設定する際に、エッジ形状検出部23は、(a)最初の部分短区間の候補として、対象画像の所定方向における所定区間を選択し、(b)所定区間のエッジに対応する近似直線が所定閾値以上の正解率で得られるか否かを判定し、(c)所定区間のエッジに対応する近似直線が所定閾値以上の正解率で得られる場合には、その所定区間を最初の部分短区間とし、(d)その所定区間のエッジに対応する近似直線が所定閾値以上の正解率で得られない場合には、その所定区間とは別の区間を選択し、その別の区間のエッジに対応する近似直線が所定閾値以上の正解率で得られる場合には、その別の区間を最初の部分短区間とする。 Further, according to the first embodiment, when setting the first partial short section, the edge shape detecting unit 23 (a) sets a predetermined section in a predetermined direction of the target image as a candidate for the first partial short section. Select, (b) determine whether or not the approximate straight line corresponding to the edge of the predetermined section can be obtained with the correct answer rate of the predetermined threshold or more, and (c) the approximate straight line corresponding to the edge of the predetermined section is the correct answer of the predetermined threshold or more. When it is obtained by a rate, the predetermined section is set as the first partial short section, and (d) when the approximate straight line corresponding to the edge of the predetermined section cannot be obtained with a correct answer rate equal to or higher than the predetermined threshold, the predetermined section is obtained. When a section different from the above is selected and an approximate straight line corresponding to the edge of the other section is obtained with a correct answer rate equal to or higher than a predetermined threshold value, the other section is set as the first partial short section.

これにより、最初の部分短区間が得られやすくなり、区分形状探索処理によってサンプリングするエッジ点が比較的少なくて済むため、比較的少ない計算量で適切に原稿画像の欠損が検出される。 As a result, the first partial short section can be easily obtained, and the number of edge points sampled by the section shape search process can be relatively small, so that the defect of the original image can be appropriately detected with a relatively small amount of calculation.

また、上記実施の形態1によれば、欠損判定部24は、検出されたエッジ形状に基づいて欠損面積を特定し、その欠損面積に基づいて、原稿画像に欠損が発生しているか否かを判定する。ここで、欠損面積は、対象画像の所定方向における特定の部分短区間のエッジの近似直線とエッジ形状で特定されるエッジとに挟まれる領域の面積である。 Further, according to the first embodiment, the defect determination unit 24 identifies the defect area based on the detected edge shape, and determines whether or not the original image has a defect based on the defect area. judge. Here, the defect area is the area of the region sandwiched between the approximate straight line of the edge of the specific partial short section in the predetermined direction of the target image and the edge specified by the edge shape.

これにより、比較的少ない計算量でエッジ形状情報から、エッジ形状が複雑であっても適切に原稿画像の欠損が検出される。 As a result, even if the edge shape is complicated, the defect of the original image can be appropriately detected from the edge shape information with a relatively small amount of calculation.

実施の形態2. Embodiment 2.

図8は、実施の形態2における画像読取部11を示す図である。 FIG. 8 is a diagram showing an image reading unit 11 according to the second embodiment.

実施の形態2において、画像読取部11は、例えば図8に示すように、原稿のおもて面の画像読取を実行する第1画像読取部11aと、原稿の裏面の画像読取を実行する第2画像読取部11bとを備える。第1画像読取部11aおよび第2画像読取部11bは、1回の原稿搬送で両面スキャンが可能なように配置されており、制御部21は、両面スキャンジョブのジョブ要求を受け付けた場合、画像読取部11に、原稿の両面スキャンを実行させる。 In the second embodiment, as shown in FIG. 8, for example, the image reading unit 11 has a first image reading unit 11a that reads an image on the front surface of the document and a second image reading unit 11a that reads an image on the back surface of the document. 2 It is provided with an image reading unit 11b. The first image reading unit 11a and the second image reading unit 11b are arranged so that double-sided scanning can be performed in one document transfer, and the control unit 21 receives an image when a job request for a double-sided scanning job is received. Have the reading unit 11 perform double-sided scanning of the original.

第1画像読取部11aは、光源41aと、光源41aによって画像読取位置に照射された光の反射光を検出する光学系42aとを備える。第2画像読取部11bは、光源41bと、光源41bによって画像読取位置に照射された光の反射光を検出する光学系42bとを備える。なお、光学系42a,42bは、レンズなどの導光部材、導光部材を介して入射する反射光を検出するイメージングセンサーなどを含む。 The first image reading unit 11a includes a light source 41a and an optical system 42a that detects the reflected light of the light emitted to the image reading position by the light source 41a. The second image reading unit 11b includes a light source 41b and an optical system 42b for detecting the reflected light of the light emitted to the image reading position by the light source 41b. The optical systems 42a and 42b include a light guide member such as a lens, an imaging sensor that detects reflected light incident through the light guide member, and the like.

第1画像読取部11aおよび第2画像読取部11bの一方(ここでは、第1画像読取部11a)は、原稿の搬送方向における画像読取位置より上流側に光源41aを備える。第1画像読取部11aおよび第2画像読取部11bの他方(ここでは、第2画像読取部11b)は、原稿の搬送方向における画像読取位置より下流側に光源41bを備える。 One of the first image reading unit 11a and the second image reading unit 11b (here, the first image reading unit 11a) includes a light source 41a on the upstream side of the image reading position in the document transport direction. The other side of the first image reading unit 11a and the second image reading unit 11b (here, the second image reading unit 11b) includes a light source 41b on the downstream side of the image reading position in the document transport direction.

実施の形態2では、対象画像取得部22は、第1画像読取部11aによる原稿のおもて面の読取画像について上述の対象画像と同様に第1対象画像を取得し、第2画像読取部11bによる原稿の裏面の読取画像について上述の対象画像と同様に第2対象画像を取得する。 In the second embodiment, the target image acquisition unit 22 acquires the first target image for the image read by the first image reading unit 11a on the front surface of the document in the same manner as the above-mentioned target image, and the second image reading unit 22. The second target image is acquired in the same manner as the above-mentioned target image for the scanned image of the back surface of the document by 11b.

エッジ形状検出部23は、画像内の原稿画像の先端エッジおよび後端エッジの両方のエッジ形状を検出する。実施の形態2では、エッジ形状検出部23は、(a)第1対象画像内の原稿画像の先端エッジおよび後端エッジのエッジ形状の一方(ここでは、第1画像読取部11aによって影のできやすい先端エッジのエッジ形状)を検出し、(b)第2対象画像内の原稿画像の先端エッジおよび後端エッジのエッジ形状の他方(ここでは、第2画像読取部11bによって影のできやすい後端エッジのエッジ形状)を検出する。 The edge shape detection unit 23 detects the edge shapes of both the front end edge and the rear end edge of the original image in the image. In the second embodiment, the edge shape detecting unit 23 is formed by (a) one of the edge shapes of the front end edge and the rear end edge of the original image in the first target image (here, a shadow is formed by the first image reading unit 11a). (Easy edge shape of the tip edge) is detected, and (b) the other edge shape of the tip edge and the trailing edge of the original image in the second target image (here, after the shadow is likely to be formed by the second image reading unit 11b). The edge shape of the edge edge) is detected.

実施の形態2では、制御部21は、片面スキャンジョブのジョブ要求を受け付けた場合でも、画像読取部11に、原稿のおもて面および裏面の両方の画像読取を実行させて、対象画像取得部22、エッジ形状検出部23、および欠損判定部24に、先端エッジおよび後端エッジの両方についての画像欠損の検査を行わせる。 In the second embodiment, the control unit 21 causes the image reading unit 11 to read both the front side and the back side of the original even when the job request of the single-sided scan job is received, and acquires the target image. A unit 22, an edge shape detection unit 23, and a defect determination unit 24 are made to inspect for image defects on both the front end edge and the rear end edge.

なお、実施の形態2に係る画像読取装置のその他の構成および動作については実施の形態1と同様であるので、その説明を省略する。 Since other configurations and operations of the image reading device according to the second embodiment are the same as those of the first embodiment, the description thereof will be omitted.

以上のように、上記実施の形態2によれば、画像読取部11は、原稿のおもて面の画像読取を実行する第1画像読取部11aと、原稿の裏面の画像読取を実行する第2画像読取部11bとを備える。そして、第1画像読取部11aおよび第2画像読取部11bの一方は、原稿の搬送方向における画像読取位置より上流側に光源を備え、他方は、原稿の搬送方向における画像読取位置より下流側に光源を備える。そして、エッジ形状検出部23は、(a)おもて面についての第1対象画像内の原稿画像の先端エッジおよび後端エッジのエッジ形状の一方を検出し、(b)裏面についての第2対象画像内の原稿画像の先端エッジおよび後端エッジのエッジ形状の他方を検出する。 As described above, according to the second embodiment, the image reading unit 11 has a first image reading unit 11a that reads an image on the front surface of the document and an image reading unit 11a that reads an image on the back surface of the document. 2 It is provided with an image reading unit 11b. One of the first image reading unit 11a and the second image reading unit 11b is provided with a light source on the upstream side of the image reading position in the document transport direction, and the other is on the downstream side of the image reading position in the document transport direction. Equipped with a light source. Then, the edge shape detection unit 23 detects (a) one of the edge shapes of the front end edge and the rear end edge of the original image in the first target image for the front surface, and (b) the second for the back surface. Detects the other edge shape of the front edge and the trailing edge of the original image in the target image.

これにより、先端エッジおよび後端エッジのいずれも第1対象画像および第2対象画像のいずれかにおいて明確に現れ、適切に検出されやすくなるため、適切に原稿画像の欠損が検出される。 As a result, both the front end edge and the rear end edge clearly appear in either the first target image or the second target image, and it is easy to detect them appropriately, so that the defect of the original image is appropriately detected.

なお、上述の実施の形態に対する様々な変更および修正については、当業者には明らかである。そのような変更および修正は、その主題の趣旨および範囲から離れることなく、かつ、意図された利点を弱めることなく行われてもよい。つまり、そのような変更および修正が請求の範囲に含まれることを意図している。 It should be noted that various changes and modifications to the above-described embodiments will be apparent to those skilled in the art. Such changes and modifications may be made without departing from the intent and scope of the subject and without diminishing the intended benefits. That is, it is intended that such changes and amendments are included in the claims.

本発明は、例えば、画像読取装置に適用可能である。 The present invention is applicable to, for example, an image reader.

11 画像読取部
11a 第1画像読取部
11b 第2画像読取部
21 制御部
22 対象画像取得部
23 エッジ形状検出部
24 欠損判定部
11 Image reading unit 11a First image reading unit 11b Second image reading unit 21 Control unit 22 Target image acquisition unit 23 Edge shape detection unit 24 Defect determination unit

Claims (5)

原稿の画像読取によって得られる読取画像または前記読取画像に対して所定の画像処理を実行して得られた画像を対象画像とし、前記対象画像内の原稿画像の先端エッジおよび後端エッジの少なくとも一方のエッジ形状を検出するエッジ形状検出部と、
検出された前記エッジ形状に基づいて、前記原稿画像に欠損が発生しているか否かを判定する欠損判定部とを備え、
前記欠損判定部は、検出された前記エッジ形状に基づいて欠損面積を特定し、前記欠損面積に基づいて、前記原稿画像に欠損が発生しているか否かを判定し、
前記欠損面積は、前記対象画像の所定方向における特定の部分短区間のエッジの近似直線と前記エッジ形状で特定されるエッジとに挟まれる領域の面積であること、
を特徴とする画像読取装置。
A scanned image obtained by scanning an image of a document or an image obtained by performing predetermined image processing on the scanned image is set as a target image, and at least one of the front end edge and the rear end edge of the document image in the target image. The edge shape detection unit that detects the edge shape of
A defect determination unit for determining whether or not a defect has occurred in the original image based on the detected edge shape is provided.
The defect determination unit identifies the defect area based on the detected edge shape, and determines whether or not the original image has a defect based on the defect area.
The defect area is the area of the region sandwiched between the approximate straight line of the edge of the specific partial short section in the predetermined direction of the target image and the edge specified by the edge shape.
An image reader characterized by.
前記エッジ形状検出部は、前記対象画像の所定方向における最初の部分短区間を設定してから、前記部分短区間に対応する区分形状を導出する区分形状探索処理を繰り返して実行することで、前記エッジ形状を特定し、
前記エッジ形状検出部は、前記区分形状探索処理において、(a)前記部分短区間のエッジに対応する近似直線を特定して、特定した前記近似直線を前記区分形状とし、(b)前記部分短区間の少なくとも一方の側から前記対象画像の前記所定方向における端部に向かって所定間隔でエッジ点を検出していき、前記近似直線から前記エッジ点までの距離が所定範囲外となった場合には、前記エッジ点に対応して次の部分短区間を設定すること、
を特徴とする請求項1記載の画像読取装置。
The edge shape detecting unit sets the first partial short section in a predetermined direction of the target image, and then repeatedly executes the section shape search process for deriving the section shape corresponding to the partial short section. Identify the edge shape,
In the division shape search process, the edge shape detection unit specifies (a) an approximate straight line corresponding to the edge of the partial short section, and the specified approximate straight line is used as the division shape, and (b) the partial short section. When edge points are detected at predetermined intervals from at least one side of the section toward the end portion of the target image in the predetermined direction, and the distance from the approximate straight line to the edge point is out of the predetermined range. Is to set the next partial short section corresponding to the edge point,
The image reading device according to claim 1.
前記エッジ形状検出部は、(a)前記対象画像における両側の所定幅の端部を除外した非端部区間のエッジに対応する近似直線を特定し、(b)前記非端部区間のエッジに対応する近似直線が所定閾値以上の正解率で得られるか否かを判定し、
前記エッジ形状検出部は、(a)前記非端部区間のエッジに対応する近似直線が所定閾値以上の正解率で得られる場合、前記区分形状探索処理を行わず、(b)前記非端部区間のエッジに対応する近似直線が所定閾値以上の正解率で得られない場合、前記区分形状探索処理を行い、
前記欠損判定部は、前記先端エッジおよび前記後端エッジの一方のエッジについて、前記非端部区間のエッジに対応する近似直線が所定閾値以上の正解率で得られない場合、前記一方のエッジについて、前記区分形状探索処理によって検出された前記エッジ形状に基づいて、前記原稿画像に欠損が発生しているか否かを判定し、
前記正解率は、前記非端部区間においてサンプリングされたエッジ点のうち、前記近似直線から所定範囲内に位置するエッジ点の割合であること、
を特徴とする請求項1または請求項2記載の画像読取装置。
The edge shape detection unit (a) identifies an approximate straight line corresponding to the edge of the non-end section excluding the ends of predetermined widths on both sides in the target image, and (b) determines the edge of the non-end section. It is determined whether or not the corresponding approximate straight line can be obtained with a correct answer rate equal to or higher than a predetermined threshold value.
The edge shape detection unit does not perform the division shape search process when (a) an approximate straight line corresponding to the edge of the non-end portion section is obtained with a correct answer rate equal to or higher than a predetermined threshold value, and (b) the non-end portion. If an approximate straight line corresponding to the edge of the section cannot be obtained with a correct answer rate equal to or higher than a predetermined threshold value, the division shape search process is performed.
When the approximate straight line corresponding to the edge of the non-end portion section cannot be obtained with a correct answer rate of a predetermined threshold value or more for one edge of the front end edge and the rear end edge, the defect determination unit obtains the one edge. Based on the edge shape detected by the section shape search process, it is determined whether or not the original image has a defect.
The correct answer rate is the ratio of the edge points sampled in the non-end section to the edge points located within a predetermined range from the approximate straight line.
The image reading apparatus according to claim 1 or 2.
前記欠損判定部は、前記先端エッジおよび前記後端エッジの両方について、前記非端部区間のエッジに対応する近似直線が所定閾値以上の正解率で得られる場合において、前記先端エッジの前記近似直線と前記後端エッジの前記近似直線とが略平行であるときには、前記原稿画像に欠損が発生していないと判定し、前記先端エッジの前記近似直線と前記後端エッジの前記近似直線とが略平行ではないときには、前記原稿画像に欠損が発生していると判定することを特徴とする請求項3記載の画像読取装置。 The defect determination unit is the approximate straight line of the tip edge when an approximate straight line corresponding to the edge of the non-end section is obtained with a correct answer rate of a predetermined threshold value or more for both the tip edge and the rear end edge. When the approximate straight line of the rear end edge is substantially parallel to the approximate straight line, it is determined that no defect has occurred in the original image, and the approximate straight line of the front end edge and the approximate straight line of the rear end edge are substantially parallel. The image reading device according to claim 3, wherein when the original images are not parallel to each other, it is determined that the original image has a defect. 前記エッジ形状検出部は、前記対象画像における両側の所定幅の端部を除外した非端部区間において、前記対象画像内の原稿画像の先端エッジおよび後端エッジの少なくとも一方のエッジ形状を検出し、
前記所定範囲は、前記原稿の画像読取時の斜行における所定の最大斜行角度に対応して設定されていること、
を特徴とする請求項1から請求項4のうちのいずれか1項記載の画像読取装置。
The edge shape detecting unit detects at least one edge shape of the front end edge and the rear end edge of the original image in the target image in the non-end section excluding the ends of predetermined widths on both sides of the target image. ,
The predetermined range is set corresponding to a predetermined maximum skew angle in skew when scanning an image of the document.
The image reading device according to any one of claims 1 to 4, wherein the image reading device is characterized.
JP2020088618A 2020-05-21 2020-05-21 Image reading device Pending JP2021184517A (en)

Priority Applications (3)

Application Number Priority Date Filing Date Title
JP2020088618A JP2021184517A (en) 2020-05-21 2020-05-21 Image reading device
US17/321,322 US11399108B2 (en) 2020-05-21 2021-05-14 Image reading apparatus capable of determining whether missing part of document image occurs based on edge shape of at least one of leading and trailing edges of document image
CN202110553055.5A CN113489856B (en) 2020-05-21 2021-05-20 Image reading apparatus

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2020088618A JP2021184517A (en) 2020-05-21 2020-05-21 Image reading device

Publications (1)

Publication Number Publication Date
JP2021184517A true JP2021184517A (en) 2021-12-02

Family

ID=78767631

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2020088618A Pending JP2021184517A (en) 2020-05-21 2020-05-21 Image reading device

Country Status (1)

Country Link
JP (1) JP2021184517A (en)

Similar Documents

Publication Publication Date Title
US8064729B2 (en) Image skew detection apparatus and methods
US9179035B2 (en) Method of editing static digital combined images comprising images of multiple objects
EP2449531B1 (en) Skew detection
US11004194B2 (en) Inspection device, image forming apparatus, and inspection method
US7991244B2 (en) Variable skew correction system and method
US9554014B2 (en) Image processing apparatus for detecting and removing a document wrinkle area in a scanned image
JP4853555B2 (en) Image reading device
JPH08123900A (en) Method and apparatus for decision of position for line scanning image
US9826118B2 (en) Image formation apparatus
CN113489856B (en) Image reading apparatus
KR20120138642A (en) Image processing method and image processing apparatus
US11153447B2 (en) Image processing apparatus and non-transitory computer readable medium storing program
JP7474411B2 (en) Image reader
JP7474410B2 (en) Image reader
JP2021184517A (en) Image reading device
JP2021184515A (en) Image reading device
JP2021184518A (en) Image reading device
KR20130010833A (en) Method for editing static digital combined images comprising images of multiple objects
CN115187989A (en) Image processing method and device, electronic equipment, scanning pen and storage medium
JP4285253B2 (en) Image inspection device with tilt detection function
JP2009284190A (en) Image reading apparatus and image reading system
US11316995B2 (en) Bending detection device and image processing apparatus
JP2023033152A (en) Inspection device, control method for inspection device, and program
JP2020198559A (en) Image reading device
JP5594012B2 (en) Image processing system, image processing apparatus, and program

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20230427

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20240216

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20240314

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20240425

A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

Effective date: 20240523