JP5791475B2 - Image processing apparatus, image processing method, and image processing program - Google Patents

Image processing apparatus, image processing method, and image processing program Download PDF

Info

Publication number
JP5791475B2
JP5791475B2 JP2011255928A JP2011255928A JP5791475B2 JP 5791475 B2 JP5791475 B2 JP 5791475B2 JP 2011255928 A JP2011255928 A JP 2011255928A JP 2011255928 A JP2011255928 A JP 2011255928A JP 5791475 B2 JP5791475 B2 JP 5791475B2
Authority
JP
Japan
Prior art keywords
workpiece
edge
image processing
unit
original image
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.)
Expired - Fee Related
Application number
JP2011255928A
Other languages
Japanese (ja)
Other versions
JP2013109691A (en
Inventor
貴文 丸塚
貴文 丸塚
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Canon Inc
Original Assignee
Canon 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 Canon Inc filed Critical Canon Inc
Priority to JP2011255928A priority Critical patent/JP5791475B2/en
Publication of JP2013109691A publication Critical patent/JP2013109691A/en
Application granted granted Critical
Publication of JP5791475B2 publication Critical patent/JP5791475B2/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Manipulator (AREA)
  • Image Analysis (AREA)

Description

本発明は、ワークが撮像された画像からワークの輪郭線を抽出する画像処理装置、画像処理方法及び画像処理プログラムに関する。   The present invention relates to an image processing apparatus, an image processing method, and an image processing program that extract a contour line of a workpiece from an image obtained by imaging the workpiece.

一般に、マシンビジョンの分野においては、エッジ検出フィルタを用いて検出対象となるワークの輪郭線を抽出し、抽出された輪郭線でワークの位置姿勢や寸法等の計測を行うことが実施されている。   In general, in the field of machine vision, an outline of a workpiece to be detected is extracted using an edge detection filter, and the position, orientation, dimensions, and the like of the workpiece are measured using the extracted outline. .

ここで、検出対象となるワークは、樹脂成型や金属プレス等により形成された部品であることが多く、成型ムラや表面処理のバラつき、傷、汚れ等により表面に微小な凹凸が存在する。そのため、撮像したワークの画像から輪郭線を抽出しようとすると、輪郭線以外のエッジ(以下、「ノイズエッジ」という)が数多く検出され、ノイズエッジによりワークの輪郭線を誤検知してしまう場合がある。   Here, the workpiece to be detected is often a part formed by resin molding, metal press, or the like, and there are minute irregularities on the surface due to molding unevenness, surface treatment variations, scratches, dirt, and the like. For this reason, when trying to extract a contour line from an image of a captured workpiece, many edges (hereinafter referred to as “noise edges”) other than the contour line are detected, and the contour line of the workpiece may be erroneously detected due to the noise edge. is there.

これに対しては、輪郭線を含む最小の範囲にエッジ検出フィルタの検出範囲を限定し、輪郭線に相当するエッジのみを抽出するように調整することで、ノイズエッジの抽出を抑制することができる。更に、エッジの形状の特徴や長さからノイズエッジを特定する幾何学的手法やロバスト推定などの統計的手法を用いてノイズエッジを特定し、除去することで、ノイズエッジの抽出を抑制することができる。   For this, the detection range of the edge detection filter is limited to the minimum range including the contour line, and the adjustment of extracting only the edge corresponding to the contour line can suppress the extraction of the noise edge. it can. In addition, the noise edge is identified and removed using a geometric method that identifies the noise edge from the feature and length of the edge and statistical methods such as robust estimation, thereby suppressing noise edge extraction. Can do.

しかしながら、エッジ検出フィルタの検出範囲に制限を設ける場合、ワークの位置や姿勢の変動を考慮した範囲を設定しなければならず、輪郭線に相当するエッジのみを検出するための範囲設定は困難である。また、幾何学的手法や統計的手法においては、輪郭線に酷似したノイズエッジを検出する場合があり、この場合、ノイズエッジを含む輪郭線情報に基づいた計測になり、精密に輪郭線を抽出できない場合が生じ得る。   However, when limiting the detection range of the edge detection filter, it is necessary to set a range that takes into account variations in the position and orientation of the workpiece, and it is difficult to set a range for detecting only edges corresponding to contour lines. is there. In geometric and statistical methods, noise edges that closely resemble contour lines may be detected. In this case, measurement is based on contour information that includes noise edges, and the contour lines are extracted accurately. There may be cases where it cannot be done.

これに対しては、様々な形状に対応させた複数のテンプレートを揃え、複数のテンプレートをワークの輪郭にマッチングさせながら輪郭を抽出することにより、容易にワークの輪郭を抽出可能な輪郭の抽出方法が提案されている(特許文献1参照)。   For this, a contour extraction method that can easily extract the contour of a workpiece by aligning a plurality of templates corresponding to various shapes and extracting the contour while matching the plurality of templates with the contour of the workpiece. Has been proposed (see Patent Document 1).

特開2003−16463号公報JP 2003-16463 A

しかしながら、特許文献1に記載の抽出方法においては、対応するテンプレートを有する既知の形状のワークに対しては有効であるが、検出対象の形状がテンプレートに対応しないものや柔軟物等の輪郭線の抽出には用いることができない。   However, the extraction method described in Patent Document 1 is effective for a workpiece having a known shape and having a corresponding template. However, the shape of the object to be detected does not correspond to the template or the outline of a flexible object or the like. It cannot be used for extraction.

そこで、本発明は、様々な位置姿勢や形状のワークの輪郭線を、精度良く抽出可能な画像処理装置及び画像処理方法並びに画像処理プログラムを提供することを目的とする。   Therefore, an object of the present invention is to provide an image processing apparatus, an image processing method, and an image processing program capable of accurately extracting contour lines of workpieces having various positions and orientations and shapes.

本発明は、撮像部により撮像されたワークの元画像を取得する元画像取得手段と、該元画像取得手段により取得された前記元画像を2値化して、該元画像からワークの概略領域を特定する領域特定手段と、該領域特定手段により特定された前記概略領域を膨張処理する膨張処理手段と、前記膨張処理手段により抽出された概略領域の境界線上に、複数の基準点を設定する基準点設定手段と、前記元画像からコントラスト差に基づき、ワークの輪郭に重なるエッジを含む複数のエッジを抽出するエッジ抽出手段と、該エッジ抽出手段により抽出された複数のエッジと前記基準点設定手段により設定された前記複数の基準点とを合成し、前記エッジ抽出手段により抽出された前記複数のエッジの中から前記複数の基準点のそれぞれに対して予め定められた位置にあるエッジを選択するエッジ選択手段と、該エッジ選択手段により選択された複数のエッジから連続したワークの輪郭線を抽出する輪郭線抽出手段と、を備えた、ことを特徴とする。   The present invention provides an original image acquisition unit that acquires an original image of a work imaged by an imaging unit, and binarizes the original image acquired by the original image acquisition unit, so that an approximate area of the workpiece is obtained from the original image. A region specifying unit to be specified, an expansion processing unit for expanding the approximate region specified by the region specifying unit, and a reference for setting a plurality of reference points on the boundary line of the approximate region extracted by the expansion processing unit Point setting means, edge extraction means for extracting a plurality of edges including edges overlapping with the contour of the workpiece based on the contrast difference from the original image, the plurality of edges extracted by the edge extraction means, and the reference point setting means Are combined with the plurality of reference points set in advance, and predetermined for each of the plurality of reference points from among the plurality of edges extracted by the edge extraction means. Edge selection means for selecting an edge at a specified position; and contour line extraction means for extracting a contour line of a continuous workpiece from a plurality of edges selected by the edge selection means. .

本発明によれば、2値化して得られるワークの概略領域を膨張処理して設定する複数の基準点のそれぞれに対して予め定められた位置にあるエッジを選択することで、様々な位置姿勢や形状のワークの輪郭線を精度よく抽出することができる。   According to the present invention, various positions and orientations can be obtained by selecting an edge at a predetermined position with respect to each of a plurality of reference points set by performing an expansion process on a schematic area of a workpiece obtained by binarization. It is possible to accurately extract a contour line of a workpiece having a shape.

本発明の実施形態に係るロボットステーションを示す斜視図である。It is a perspective view which shows the robot station which concerns on embodiment of this invention. 本実施形態に係る画像処理装置のハード構成を示すブロック図である。It is a block diagram which shows the hardware constitutions of the image processing apparatus which concerns on this embodiment. 本実施形態に係る画像処理装置の内部構成を示すブロック図である。It is a block diagram which shows the internal structure of the image processing apparatus which concerns on this embodiment. 本実施形態に係る画像処理装置による位置姿勢計測処理を示すフローチャートである。It is a flowchart which shows the position and orientation measurement process by the image processing apparatus which concerns on this embodiment. 本実施形態に係る画像処理装置の輪郭エッジ選択部による輪郭エッジ選択処理を示すフローチャートである。It is a flowchart which shows the contour edge selection process by the contour edge selection part of the image processing apparatus which concerns on this embodiment. (a)は、本実施形態における画像処理装置による円環部品の輪郭エッジ選択処理を説明するための図であり、(b)は、(a)における(F)の状態を説明するための部分拡大図である。(A) is a figure for demonstrating the outline edge selection process of the annular component by the image processing apparatus in this embodiment, (b) is a part for demonstrating the state of (F) in (a). It is an enlarged view. (a)は、本実施形態における画像処理装置による不定型部品の輪郭エッジ選択処理を説明するための図であり、(b)は、(a)における(F)の状態を説明するための部分拡大図である。(A) is a figure for demonstrating the outline edge selection process of the indeterminate part by the image processing apparatus in this embodiment, (b) is a part for demonstrating the state of (F) in (a). It is an enlarged view.

以下、本発明の実施形態に係る画像処理装置を有するロボットシステムとしてのロボットステーション1について、図面を参照しながら説明する。まず、本実施形態に係るロボットステーション1の概略構成について、図1から図3を参照しながら説明する。図1は、本発明の実施形態に係るロボットステーション1を示す斜視図である。図2は、本実施形態に係る画像処理装置3のハード構成を示すブロック図である。図3は、本実施形態に係る画像処理装置3の内部構成を示すブロック図である。   Hereinafter, a robot station 1 as a robot system having an image processing apparatus according to an embodiment of the present invention will be described with reference to the drawings. First, a schematic configuration of the robot station 1 according to the present embodiment will be described with reference to FIGS. 1 to 3. FIG. 1 is a perspective view showing a robot station 1 according to an embodiment of the present invention. FIG. 2 is a block diagram showing a hardware configuration of the image processing apparatus 3 according to the present embodiment. FIG. 3 is a block diagram showing an internal configuration of the image processing apparatus 3 according to the present embodiment.

図1から図3に示すように、ロボットステーション1は、ワークWを撮像する撮像部2と、撮像部2により撮像された元画像からワークWの位置姿勢を計測する画像処理装置3と、ワークWを把持するロボットアーム4,5と、を備えている。本実施形態においては、ロボットアーム4,5は、剛性を持つ支柱により形成されたブース6の架台7の上に配設されており、ロボットアーム4,5の上方に配設された照明8,8の間に撮像部2が配設されている。   As shown in FIGS. 1 to 3, the robot station 1 includes an imaging unit 2 that images the workpiece W, an image processing device 3 that measures the position and orientation of the workpiece W from the original image captured by the imaging unit 2, And robot arms 4 and 5 for gripping W. In the present embodiment, the robot arms 4 and 5 are disposed on the stand 7 of the booth 6 formed by a rigid support column, and the lights 8 and 5 disposed above the robot arms 4 and 5 are arranged. The image pickup unit 2 is disposed between 8.

撮像部2は、架台7の上に搬送あるいは載置された検査対象となるワークWの全体を撮像する。撮像部2は、デジタルカメラ等により構成されており、デジタルカメラの場合には、CCDイメージセンサあるいはCMOSイメージセンサ等の固体撮像素子と、撮像レンズと、を備えて構成され、撮像によって画像データを取得することができる。   The imaging unit 2 captures an image of the entire workpiece W to be inspected that is conveyed or placed on the gantry 7. The imaging unit 2 is configured by a digital camera or the like. In the case of a digital camera, the imaging unit 2 includes a solid-state imaging device such as a CCD image sensor or a CMOS image sensor and an imaging lens, and captures image data by imaging. Can be acquired.

図2に示すように、画像処理装置3は、制御部としてのCPU3aを備えており、CPU3aには、バス10に接続されたインターフェイス11を介して、撮像部2、キーボード12及びマウス13が接続されている。キーボード12及びマウス13は、ワークWの輪郭線の抽出や位置姿勢の計測に必要な指定情報、あるいはその他の指示等の入力を可能としている。画像データは、固体撮像素子のピクセル毎に生成された点の集合の情報として取得される。ワークWの輪郭を含む領域を撮像することにより生成された点の集合を認識し、取得した画像データからワークWの輪郭に対応した輪郭線を抽出することができる。輪郭線は点の集合として処理してもよいし、各点同士を連結して、「線」情報に変換して処理したり、後述の複数のエッジから生成される線情報にして処理することもできる。したがって、以下では「輪郭線」の語を点の集合もしくは線情報のいずれの場合も含むものとして説明する。   As illustrated in FIG. 2, the image processing apparatus 3 includes a CPU 3 a as a control unit, and the imaging unit 2, the keyboard 12, and the mouse 13 are connected to the CPU 3 a via an interface 11 connected to the bus 10. Has been. The keyboard 12 and the mouse 13 can input designation information necessary for extracting the outline of the workpiece W and measuring the position and orientation, or other instructions. The image data is acquired as information on a set of points generated for each pixel of the solid-state imaging device. A set of points generated by imaging an area including the contour of the workpiece W can be recognized, and a contour line corresponding to the contour of the workpiece W can be extracted from the acquired image data. The contour line may be processed as a set of points, connected to each other, converted into "line" information, or processed as line information generated from a plurality of edges described later. You can also. Therefore, hereinafter, the term “contour line” will be described as including both cases of a set of points and line information.

また、CPU3aには、画像を表示するディスプレイ14及び音声を出力するスピーカ15がバスを介して接続されている。ディスプレイ14は、撮像部2により撮像され、CPU3aで所定の処理が行われたワークW等を表示可能としている。スピーカ15は、CPU3aで生成された音声等を出力可能としている。   Further, a display 14 for displaying an image and a speaker 15 for outputting sound are connected to the CPU 3a via a bus. The display 14 can display a work W or the like that has been imaged by the imaging unit 2 and that has been subjected to predetermined processing by the CPU 3a. The speaker 15 can output sound generated by the CPU 3a.

更に、CPU3aには、ROM17及びRAM16がバス10を介して接続されている。ROM16には、画像処理装置3の基本制御に必要なプログラムやワークWの3次元モデル情報等が格納されている。RAM16には、後述する輪郭抽出処理等の作業領域が確保されている。また、バス10には、記録媒体読取部18が接続されており、ワークWの輪郭を抽出する画像処理プログラムやワークWの3次元モデル情報等を記録した記録媒体Dを読み込み、例えばROM17に格納できるようになっている。   Further, a ROM 17 and a RAM 16 are connected to the CPU 3 a via the bus 10. The ROM 16 stores programs necessary for basic control of the image processing apparatus 3, 3D model information of the workpiece W, and the like. The RAM 16 has a work area for contour extraction processing, which will be described later. Further, a recording medium reading unit 18 is connected to the bus 10, and an image processing program for extracting the contour of the work W, a recording medium D on which the three-dimensional model information of the work W is recorded, and stored in the ROM 17, for example. It can be done.

また、バス10には、通信装置19が接続されており、上述したような記録媒体Dを使用せずに、通信装置19を介してインターネット等から配信される画像処理プログラムやワークWの3次元モデル情報等をダウンロード可能に構成されている。なお、画像処理装置3は、通信装置19を介して端末機からの入力を受信し、この端末機からの要求に基づいて画像処理プログラムを実行(演算)し、実行(演算)結果を端末機に送信するサ−バー機として機能するように構成されてもよい。   A communication device 19 is connected to the bus 10, and the three-dimensional image processing program or work W distributed from the Internet or the like via the communication device 19 without using the recording medium D as described above. Model information etc. can be downloaded. The image processing apparatus 3 receives an input from the terminal via the communication device 19, executes (calculates) an image processing program based on a request from the terminal, and outputs the execution (calculation) result to the terminal. It may be configured to function as a server machine that transmits to the network.

図3に示すように、画像処理装置3のCPU3aは、元画像取得手段としての元画像取得部31と、領域特定手段としての領域特定部32と、エッジ抽出手段としてのエッジ抽出部33と、膨張処理手段としての領域膨張処理部34と、を備えている。また、画像処理装置3のCPU3aは、基準点設定手段としての基準点設定部35と、エッジ選択手段としての輪郭エッジ選択部36と、輪郭線抽出手段としての輪郭線抽出部37と、位置姿勢計測部38と、を備えている。   As shown in FIG. 3, the CPU 3a of the image processing apparatus 3 includes an original image acquisition unit 31 as an original image acquisition unit, an area specification unit 32 as an area specification unit, an edge extraction unit 33 as an edge extraction unit, And an area expansion processing unit 34 as expansion processing means. Further, the CPU 3a of the image processing apparatus 3 includes a reference point setting unit 35 serving as a reference point setting unit, a contour edge selecting unit 36 serving as an edge selecting unit, a contour line extracting unit 37 serving as a contour line extracting unit, and a position and orientation. And a measuring unit 38.

元画像取得部31は、撮像部2によりワークWが撮像された元画像を取得し、領域特定部32及びエッジ抽出部33に元画像を出力する。領域特定部32は、元画像取得部31から出力された元画像を2値化して、ワークWの概略を構成する概略領域を特定し、特定した概略領域の領域情報を領域膨張処理部34に出力する。エッジ抽出部33は、元画像取得部31から出力された元画像のエッジを抽出する。   The original image acquisition unit 31 acquires an original image in which the workpiece W is imaged by the imaging unit 2 and outputs the original image to the area specifying unit 32 and the edge extraction unit 33. The area specifying unit 32 binarizes the original image output from the original image acquiring unit 31, specifies the outline area constituting the outline of the workpiece W, and supplies the area information of the specified outline area to the area expansion processing unit 34. Output. The edge extraction unit 33 extracts the edge of the original image output from the original image acquisition unit 31.

なお、ここでいうエッジは、ワークW表面に現れるコントラスト差に基づいてこれを繋げてなるコントラスト線として現れるものであり、例えば、ワークWの輪郭に重なるエッジの他に、これ以外を示すエッジ(以下、「偽エッジ」という)を含んでいる。つまり、ここでいうエッジとは、ワークWの輪郭に重なるエッジや偽エッジを含む、元画像に現れる全エッジをいう。   Note that the edge here appears as a contrast line that is connected based on the contrast difference that appears on the surface of the workpiece W. For example, in addition to the edge that overlaps the contour of the workpiece W, the edge ( Hereinafter, it is referred to as “false edge”. That is, the edge here means all edges appearing in the original image including edges and false edges that overlap the outline of the workpiece W.

領域膨張処理部34は、領域特定部32から出力された領域情報から特定した概略領域を所定量膨張させる膨張処理を行う。なお、所定量膨張させるための膨張処理の回数は、特に決められているものではなく、2値化した概略領域の状態により異なる。基準点設定部35は、膨張処理した概略領域の境界線上に、エッジ検索の起点となる複数の基準点を設定する。   The region expansion processing unit 34 performs expansion processing for expanding the approximate region specified from the region information output from the region specifying unit 32 by a predetermined amount. Note that the number of expansion processes for expanding a predetermined amount is not particularly determined, and differs depending on the state of the binarized general area. The reference point setting unit 35 sets a plurality of reference points as starting points for edge search on the boundary line of the expanded approximate area.

輪郭エッジ選択部36は、エッジ抽出部33により抽出された複数のエッジと、基準点設定部35により設定された複数の基準点を合成し、複数の基準点それぞれと最短距離にあるエッジを検索し、これを選択する。輪郭線抽出部37は、輪郭エッジ選択部36により選択された複数のエッジから連続したワークWの輪郭線を抽出する。なお、輪郭エッジ選択部36は、基準点に対して所定の検索範囲内にエッジが存在しない場合には、エッジの検索を終了するように構成されている。   The contour edge selection unit 36 combines the plurality of edges extracted by the edge extraction unit 33 and the plurality of reference points set by the reference point setting unit 35, and searches for the edge at the shortest distance from each of the plurality of reference points. And select this. The contour line extraction unit 37 extracts a contour line of a continuous workpiece W from a plurality of edges selected by the contour edge selection unit 36. Note that the contour edge selection unit 36 is configured to end the edge search when there is no edge within a predetermined search range with respect to the reference point.

位置姿勢計測部38は、ROM16に記憶されたワークWの三次元モデル情報と、輪郭線抽出部37により抽出されたワークWの輪郭線とをフィッティング(照合)させて、ワークWの位置姿勢を計測する(三次元モデルフィッティング処理)。なお、ここでいうワークWの位置姿勢とは、ワークWの位置及びワークWの姿勢を示すものである。   The position / orientation measurement unit 38 fits (collates) the three-dimensional model information of the workpiece W stored in the ROM 16 with the contour line of the workpiece W extracted by the contour line extraction unit 37 to determine the position / orientation of the workpiece W. Measure (3D model fitting process). Here, the position and orientation of the workpiece W indicate the position of the workpiece W and the posture of the workpiece W.

ロボットアーム4,5は、6軸制御可能なロボットアームであり、先端部には、各種作業に応じて様々なエンドエフェクタを取り付け可能に形成されている。エンドエフェクタは、人間の手、指に相当する部分である。本実施形態においては、ロボットアーム4,5の一方のロボットアーム4には細かい作業を可能にする小型のエンドエフェクタが装着され、他方のロボットアーム5には比較的大きな部材を扱うエンドエフェクタが装着されている。また、ロボットステーション1内で使用されるコントローラや電源等は、架台7の下部から引き出し可能に収納された電源コントローラボックス9に収納されている。   The robot arms 4 and 5 are 6-axis controllable robot arms, and are formed so that various end effectors can be attached to the tip portion according to various operations. The end effector is a part corresponding to a human hand or finger. In this embodiment, one of the robot arms 4 and 5 is equipped with a small end effector that enables fine work, and the other robot arm 5 is equipped with an end effector that handles a relatively large member. Has been. Further, a controller, a power source, and the like used in the robot station 1 are stored in a power controller box 9 which is stored so as to be able to be pulled out from the lower portion of the gantry 7.

次に、本実施形態に係る画像処理装置3によるワークWの位置姿勢計測処理(位置姿勢計測方法)について、図4から図7(b)を参照しながら説明する。なお、以下においては、撮像部2によりグレースケールにて撮像されたワークWの元画像(以下、「元グレイ画像」という)から位置姿勢を計測する位置姿勢計測処理を用いて説明する。   Next, the position / orientation measurement process (position / orientation measurement method) of the workpiece W by the image processing apparatus 3 according to the present embodiment will be described with reference to FIGS. 4 to 7B. In the following, description will be made using a position / orientation measurement process for measuring a position / orientation from an original image (hereinafter referred to as an “original gray image”) of the workpiece W imaged in gray scale by the imaging unit 2.

まず、円環形状のワーク(以下、「円環部品」という)の輪郭線を抽出して、円環部品の位置姿勢を計測する位置姿勢計測処理について、図4から図6(b)を参照しながら説明する。図4は、本実施形態に係る画像処理装置3による位置姿勢計測処理を示すフローチャートである。図5は、本実施形態に係る画像処理装置3の輪郭エッジ選択部36による輪郭エッジ選択処理を示すフローチャートである。図6(a)は、本実施形態における画像処理装置3による円環部品の輪郭線抽出処理を説明するための図である。図6(b)は、図6(a)における(F)の状態を説明するための部分拡大図である。   First, refer to FIGS. 4 to 6B for position and orientation measurement processing for extracting the contour line of an annular workpiece (hereinafter referred to as “annular part”) and measuring the position and orientation of the annular part. While explaining. FIG. 4 is a flowchart showing position and orientation measurement processing by the image processing apparatus 3 according to the present embodiment. FIG. 5 is a flowchart showing a contour edge selection process by the contour edge selection unit 36 of the image processing apparatus 3 according to the present embodiment. FIG. 6A is a diagram for explaining the contour extraction processing of the ring component by the image processing apparatus 3 in the present embodiment. FIG. 6B is a partially enlarged view for explaining the state (F) in FIG.

まず、元画像取得部31により、撮像部2により円環部品を撮像して得られた8bitの元グレイ画像40a(図6(a)に示す(A)参照)を取得する元画像取得処理(元画像取得工程)が行われる(ステップST10)。次に、領域特定部32により、元グレイ画像40aの背景領域と検出対象(円環部品)の領域とを分離している輝度値の差を閾値として、元グレイ画像40aを2値化する領域特定処理(領域特定工程)が行われる。この領域特定処理により、円環部品の概略領域41a(図6(a)に示す(B)参照)が特定される(ステップST20)。このとき、元グレイ画像40aの有するノイズにより生成された孤立点としての空胞領域が存在する場合には、2値化した後に、例えば、モルフォロジー処理等により、空胞領域を消失させておいてもよい。   First, the original image acquisition unit 31 acquires an original image acquisition process for acquiring an 8-bit original gray image 40a (see (A) shown in FIG. 6A) obtained by imaging an annular component by the imaging unit 2. An original image acquisition step) is performed (step ST10). Next, the area specifying unit 32 binarizes the original gray image 40a using a difference between luminance values separating the background area of the original gray image 40a and the area of the detection target (ring component) as a threshold value. A specific process (region specifying step) is performed. By this area specifying process, the general area 41a of the annular part (see (B) shown in FIG. 6A) is specified (step ST20). At this time, if there is an vacuole region as an isolated point generated by the noise of the original gray image 40a, after binarization, the vacuole region is erased by, for example, morphological processing. Also good.

領域特定部32により概略領域41aが特定されると、領域膨張処理部34により概略領域41aの膨張処理(膨張処理工程)が行われる(ステップST30)。領域膨張処理部34は、概略領域41aを所定回数(所定量)膨張処理し、膨張領域42a(図6(a)に示す(C)参照)を生成する。なお、膨張処理は、元グレイ画像40aを2値化した際に概略領域41aに孤立点が発生した場合に、孤立点を消失させて、概略領域41aを平滑化させるのにも有効となる。   When the approximate area 41a is specified by the area specifying unit 32, the expansion process (expansion process step) of the approximate area 41a is performed by the area expansion processing unit 34 (step ST30). The region expansion processing unit 34 expands the general region 41a a predetermined number of times (predetermined amount) to generate an expansion region 42a (see (C) shown in FIG. 6A). It should be noted that the dilation processing is also effective for smoothing the approximate region 41a by eliminating the isolated points when an isolated point occurs in the approximate region 41a when the original gray image 40a is binarized.

次に、基準点設定部35により、膨張領域42aの境界線43a,44a上に基準点としての局所エッジの探索点100〜102、200〜202(図6(a)に示す(D)参照)を設定する基準点設定処理(基準点設定工程)が行われる(ステップST40)。探索点100〜102、200〜202は、1隣接画素毎、若しくは所定の間隔で設定される。   Next, the reference point setting unit 35 causes the search points 100 to 102 and 200 to 202 for local edges as reference points on the boundary lines 43a and 44a of the expansion region 42a (see (D) shown in FIG. 6A). A reference point setting process (reference point setting step) is set (step ST40). Search points 100 to 102 and 200 to 202 are set for each adjacent pixel or at predetermined intervals.

ここで、元画像取得部31により取得された元グレイ画像40aに対し、エッジ抽出部33により、元グレイ画像40aからエッジ(図6(a)に示す(E)参照)を抽出するエッジ抽出処理(エッジ抽出工程)が行われる(ステップST50)。エッジ抽出処理は、ケニーフィルタやソーベルフィルタ等のエッジ検出により行われる。エッジ抽出処理は、例えば、円環部品の表面上に現れるコントラスト差に基づいて、複数の閾値を設定し、複数の閾値のそれぞれに基づいて仕切られるコントラスト線により現れる線を抽出する。そのため、このエッジには、偽エッジが含まれている。   Here, with respect to the original gray image 40a acquired by the original image acquisition unit 31, the edge extraction unit 33 extracts an edge (see (E) shown in FIG. 6A) from the original gray image 40a by the edge extraction unit 33. (Edge extraction process) is performed (step ST50). The edge extraction process is performed by edge detection such as a Kenny filter or a Sobel filter. In the edge extraction process, for example, a plurality of threshold values are set based on the contrast difference appearing on the surface of the annular component, and lines appearing by contrast lines partitioned based on each of the plurality of threshold values are extracted. Therefore, this edge includes a false edge.

エッジ抽出処理により偽エッジを含む複数のエッジが抽出されると、輪郭エッジ選択部36により、輪郭エッジ選択処理(輪郭エッジ選択工程)が行われる(ステップST60)。輪郭エッジ選択部36は、まず、エッジ抽出部33により抽出された複数のエッジと基準点設定部35により設定された複数の探索点100〜102、200〜202とを合成する(図6(a)に示す(F)参照)。そして、図5に示すように、エッジ抽出部33により抽出された複数のエッジの中から基準点設定部35により設定された複数の探索点100〜102、200〜202のそれぞれと例えば最短距離にあるエッジを探索する(ステップST61)。ここで、図6(b)に示すように、複数の探索点100〜102、200〜202のそれぞれと最短距離にあるエッジがあれば、これを選択し、エッジ情報として登録する(ステップST62、ステップST63)。エッジの選択は、全基準点の探索が終了するまで繰り返し行われる(ステップST64)。なお、エッジを探索するにあたり最短距離にあるエッジを探索する場合を説明したが、ワークの形状によっては基準点に対して予め定められた位置にあるエッジを選択すればよい。例えば、最短距離、基準点からの距離等、エッジの選択の規則を定めて探索の仕方を変えてもよい。以下、他の実施例の場合でも同様である。   When a plurality of edges including false edges are extracted by the edge extraction process, the contour edge selection unit 36 performs a contour edge selection process (contour edge selection process) (step ST60). The contour edge selection unit 36 first combines the plurality of edges extracted by the edge extraction unit 33 and the plurality of search points 100 to 102 and 200 to 202 set by the reference point setting unit 35 (FIG. 6A (See (F)). Then, as shown in FIG. 5, for example, at the shortest distance from each of the plurality of search points 100 to 102 and 200 to 202 set by the reference point setting unit 35 from among the plurality of edges extracted by the edge extraction unit 33. A certain edge is searched (step ST61). Here, as shown in FIG. 6B, if there is an edge at the shortest distance from each of the plurality of search points 100 to 102 and 200 to 202, this is selected and registered as edge information (step ST62, Step ST63). The selection of the edge is repeated until the search for all reference points is completed (step ST64). In addition, although the case where an edge at the shortest distance is searched for searching for an edge has been described, an edge located at a predetermined position with respect to a reference point may be selected depending on the shape of the workpiece. For example, the search method may be changed by defining rules for selecting edges such as the shortest distance and the distance from the reference point. The same applies to the other embodiments.

全基準点のエッジの探索が終了すると、輪郭線抽出部37により、選択された複数の基準点から連続した円環部材の輪郭線を抽出する輪郭線抽出処理(図6(a)に示す(G)参照)が行われる(ステップST70)。例えば、輪郭線抽出部37は、選択されたエッジの端部同士を所定の補正処理により繋げて、連続した輪郭線とする。これにより、円環部材の輪郭線が特定される。   When the search for the edges of all the reference points is completed, the contour extraction unit 37 extracts a contour line of a continuous annular member from the selected reference points (shown in FIG. 6A). G)) is performed (step ST70). For example, the contour line extraction unit 37 connects the end portions of the selected edges by a predetermined correction process to obtain a continuous contour line. Thereby, the outline of an annular member is specified.

輪郭線抽出部37により円環部材の輪郭線が特定されると、次に、位置姿勢計測部38により、円環部材の位置姿勢が計測される(ステップST80)。円環部材の位置姿勢は、ROM16に記憶された円環部材の三次元モデル情報と、輪郭線抽出部37により抽出された円環部材の輪郭線とをフィッティング(三次元モデルフィッティング処理)させることにより行われる。円環部材の三次元モデル情報と円環部材の輪郭線との三次元モデルフィッティング処理により、円環部材の位置姿勢が精密に計測される。なお、ここでは、三次元モデルフィッティング処理の具体的な説明は省略する。   If the contour line of the annular member is specified by the contour line extraction unit 37, then the position and orientation of the annular member is measured by the position and orientation measurement unit 38 (step ST80). The position and orientation of the annular member is obtained by fitting (three-dimensional model fitting process) the three-dimensional model information of the annular member stored in the ROM 16 and the contour of the annular member extracted by the contour extracting unit 37. Is done. The position and orientation of the annular member are accurately measured by the three-dimensional model fitting process of the three-dimensional model information of the annular member and the contour line of the annular member. Here, a specific description of the 3D model fitting process is omitted.

次に、非対称形状のワーク(以下、「非対称部品」という)の輪郭線を抽出して、非対称部品の位置姿勢を計測する位置姿勢計測処理について、図4及び図5を援用すると共に、図7(a)及び図7(b)を参照しながら説明する。図7(a)は、本実施形態における画像処理装置3による非対称部品の輪郭エッジ選択処理を説明するための図である。図7(b)は、図7(a)における(F)の状態を説明するための部分拡大図である。なお、ここでいう非対称部品には、例えば、歪形状や不定型部品等も含むものとする。   Next, a position and orientation measurement process for extracting the outline of an asymmetrical workpiece (hereinafter referred to as “asymmetric part”) and measuring the position and orientation of the asymmetric part will be described with reference to FIGS. This will be described with reference to (a) and FIG. FIG. 7A is a diagram for explaining a contour edge selection process of an asymmetric part by the image processing apparatus 3 in the present embodiment. FIG.7 (b) is the elements on larger scale for demonstrating the state of (F) in Fig.7 (a). Note that the asymmetric part here includes, for example, a distorted shape and an indeterminate part.

まず、元画像取得部31により、撮像部2により非対称部品を撮像して得られた8bitの元グレイ画像40b(図7(a)に示す(A)参照)を取得する元画像取得処理(元画像取得工程)が行われる(ステップST10)。次に、領域特定部32により、元グレイ画像40bの背景領域と検出対象(非対称部品)の領域とを分離している輝度値の差を閾値として、元グレイ画像40bを2値化する領域特定処理(領域特定工程)が行われる。この領域特定処理により、非対称部品の概略領域41b(図7(a)に示す(B)参照)が特定される(ステップST20)。このとき、元グレイ画像40bの有するノイズにより生成された孤立点としての空胞領域が存在する場合には、2値化した後に、例えば、モルフォロジー処理等により空胞領域を消失させておいてもよい。   First, the original image acquisition unit 31 acquires an original image acquisition process (original) of acquiring an 8-bit original gray image 40b (see (A) shown in FIG. 7A) obtained by imaging an asymmetric part by the imaging unit 2. An image acquisition step) is performed (step ST10). Next, the region specifying unit 32 binarizes the original gray image 40b using the difference between the luminance values separating the background region of the original gray image 40b and the detection target (asymmetric part) region as a threshold value. Processing (region specifying step) is performed. By this area specifying process, the approximate area 41b of the asymmetric part (see (B) shown in FIG. 7A) is specified (step ST20). At this time, in the case where the vacuole region as an isolated point generated by the noise of the original gray image 40b exists, after the binarization, for example, the vacuole region may be eliminated by morphological processing or the like. Good.

領域特定部32により概略領域41bが特定されると、領域膨張処理部34により概略領域41bの膨張処理(膨張処理工程)が行われる(ステップST30)。領域膨張処理部34は、概略領域41bを所定回数(所定量)膨張処理し、膨張領域42b(図7(a)に示す(C)参照)を生成する。なお、膨張処理は、元グレイ画像40bを2値化した際に概略領域41bに孤立点が発生した場合に、孤立点を消失させて、概略領域41bを平滑化させるのにも有効となる。   When the approximate area 41b is specified by the area specifying unit 32, the expansion process (expansion process step) of the approximate area 41b is performed by the area expansion processing unit 34 (step ST30). The area expansion processing unit 34 expands the approximate area 41b a predetermined number of times (predetermined amount) to generate an expansion area 42b (see (C) in FIG. 7A). It should be noted that the dilation processing is also effective for smoothing the approximate region 41b by eliminating the isolated points when an isolated point occurs in the approximate region 41b when the original gray image 40b is binarized.

次に、基準点設定部35により、膨張領域42bの境界線43b上に基準点としての局所エッジの探索点300〜302(図7(a)に示す(D)参照)を設定する基準点設定処理(基準点設定工程)が行われる(ステップST40)。探索点300〜302は、1隣接画素毎、若しくは所定の間隔で設定される。   Next, a reference point setting for setting local edge search points 300 to 302 (see (D) shown in FIG. 7A) as reference points on the boundary line 43b of the expansion region 42b by the reference point setting unit 35. Processing (reference point setting step) is performed (step ST40). Search points 300 to 302 are set for each adjacent pixel or at predetermined intervals.

ここで、元画像取得部31により取得された元グレイ画像40bに対し、エッジ抽出部33により、元グレイ画像40bからエッジ(図7(a)に示す(E)参照)を抽出するエッジ抽出処理(エッジ抽出工程)が行われる(ステップST50)。エッジ抽出処理は、ケニーフィルタやソーベルフィルタ等のエッジ検出により行われる。エッジ抽出処理は、例えば、非対称部品の表面上に現れるコントラスト差に基づいて、複数の閾値を設定し、複数の閾値のそれぞれに基づいて仕切られるコントラスト線により現れる線を抽出する。そのため、このエッジには、偽エッジが含まれている。   Here, with respect to the original gray image 40b acquired by the original image acquisition unit 31, the edge extraction unit 33 extracts an edge (see (E) shown in FIG. 7A) from the original gray image 40b by the edge extraction unit 33. (Edge extraction process) is performed (step ST50). The edge extraction process is performed by edge detection such as a Kenny filter or a Sobel filter. In the edge extraction process, for example, a plurality of threshold values are set based on the contrast difference appearing on the surface of the asymmetric part, and lines appearing by contrast lines partitioned based on each of the plurality of threshold values are extracted. Therefore, this edge includes a false edge.

エッジ抽出処理により偽エッジを含む複数のエッジが抽出されると、輪郭エッジ選択部36により、輪郭エッジ選択処理(輪郭エッジ選択工程)が行われる(ステップST60)。輪郭エッジ選択部36は、まず、エッジ抽出部33により抽出された複数のエッジと基準点設定部35により設定された複数の探索点300〜302とを合成する(図7(a)に示す(F)参照)。そして、図5に示すように、エッジ抽出部33により抽出された複数のエッジの中から基準点設定部35により設定された複数の探索点300〜302のそれぞれと最短距離にあるエッジを探索する(ステップST61)。ここで、図7(b)に示すように、複数の探索点300〜302のそれぞれと最短距離にあるエッジがあれば、これを選択し、エッジ情報として登録する(ステップST62、ステップST63)。エッジの選択は、全基準点の探索が終了するまで繰り返し行われる(ステップST64)。   When a plurality of edges including false edges are extracted by the edge extraction process, the contour edge selection unit 36 performs a contour edge selection process (contour edge selection process) (step ST60). The contour edge selection unit 36 first combines a plurality of edges extracted by the edge extraction unit 33 and a plurality of search points 300 to 302 set by the reference point setting unit 35 (shown in FIG. 7A). F)). Then, as shown in FIG. 5, the edge having the shortest distance from each of the plurality of search points 300 to 302 set by the reference point setting unit 35 is searched from among the plurality of edges extracted by the edge extraction unit 33. (Step ST61). Here, as shown in FIG. 7B, if there is an edge at the shortest distance from each of the plurality of search points 300 to 302, this is selected and registered as edge information (step ST62, step ST63). The selection of the edge is repeated until the search for all reference points is completed (step ST64).

全基準点のエッジの探索が終了すると、輪郭線抽出部37により、選択された複数の基準点から連続した非対称部品の輪郭線を抽出する輪郭線抽出処理(図7(a)に示す(G)参照)が行われる(ステップST70)。例えば、輪郭線抽出部37は、選択されたエッジの端部同士を所定の補正処理により繋げて、連続した輪郭線とする。これにより、非対称部品の輪郭線が特定される。   When the search for the edges of all the reference points is completed, the contour extraction unit 37 extracts contour lines of continuous asymmetric parts from a plurality of selected reference points (shown in FIG. 7A) (G )) Is performed (step ST70). For example, the contour line extraction unit 37 connects the end portions of the selected edges by a predetermined correction process to obtain a continuous contour line. Thereby, the outline of the asymmetric part is specified.

輪郭線抽出部37により非対称部品の輪郭線が特定されると、次に、位置姿勢計測部38により、非対称部品の位置姿勢が計測される(ステップST80)。非対称部品の位置姿勢は、ROM16に記憶された非対称部品の三次元モデル情報と、輪郭線抽出部37により抽出された非対称部品の輪郭線とをフィッティング(三次元モデルフィッティング処理)させることにより行われる。非対称部品の三次元モデル情報と非対称部品の輪郭線との三次元モデルフィッティング処理により、非対称部品の位置姿勢が精密に計測される。なお、ここでは、三次元モデルフィッティング処理の具体的な説明は省略する。   When the contour line of the asymmetric part is specified by the contour line extraction unit 37, the position and orientation of the asymmetric part is then measured by the position and orientation measurement unit 38 (step ST80). The position and orientation of the asymmetric part is performed by fitting the three-dimensional model information of the asymmetric part stored in the ROM 16 and the outline of the asymmetric part extracted by the outline extraction unit 37 (three-dimensional model fitting process). . The position and orientation of the asymmetric part is accurately measured by the three-dimensional model fitting process using the three-dimensional model information of the asymmetric part and the contour line of the asymmetric part. Here, a specific description of the 3D model fitting process is omitted.

以上説明した位置姿勢計測処理(位置姿勢計測方法)は、上記手順に応じたプログラムとして形成し、CPU等のコンピュータで実行するように構成することも可能である。また、このようなプログラムは、半導体メモリ、磁気ディスク、光ディスク、フロッピー(登録商標)ディスク等の記録媒体、この記録媒体をセットしたコンピュータによりアクセスし、上記プログラムを実行するように構成することも可能である。   The position / orientation measurement processing (position / orientation measurement method) described above can be formed as a program corresponding to the above-described procedure and executed by a computer such as a CPU. In addition, such a program can be configured to be accessed by a recording medium such as a semiconductor memory, a magnetic disk, an optical disk, a floppy (registered trademark) disk, or a computer in which the recording medium is set and to execute the program. It is.

上述したように、実際のワークの表面は、一見フラットな表面状態であっても、微小な凹凸形状が存在し、照明との相乗作用により、急しゅんな輝度変動が現れ、エッジとして検出される場合がある。そのため、画像のエッジ抽出処理を行うと、輪郭を構成するエッジ以外のノイズエッジが検出される。そして、ノイズエッジを含むエッジ情報を元に、三次元モデルフィッティング処理などの演算を行うと、誤差を含む計測結果となり、正確な位置姿勢の検出ができない場合がある。   As described above, even if the surface of the actual work is a flat surface at first glance, there is a minute uneven shape, and sudden brightness fluctuations appear due to synergistic effects with illumination, and are detected as edges. There is a case. For this reason, when the edge extraction process of the image is performed, noise edges other than the edges constituting the contour are detected. If a calculation such as a three-dimensional model fitting process is performed based on edge information including a noise edge, a measurement result including an error may be obtained, and an accurate position and orientation may not be detected.

これに対し、本実施形態に係る画像処理装置3は、2値化などの領域特定処理によりワークの概略領域を特定し、これを膨張処理してワークの輪郭線と膨張処理した概略領域の境界線との間にギャップを与える。そして、膨張処理した概略領域の境界線上に、所定の間隔でエッジの探索点(基準点)を設定し、この探索点から最少距離にあるエッジを、ワークの輪郭を構成するエッジとして選択する。そのため、ノイズエッジの影響を少なくした輪郭線の抽出が可能となる。これにより、輪郭線を精度よく抽出することができる。   On the other hand, the image processing apparatus 3 according to the present embodiment specifies an outline area of a work by an area specifying process such as binarization, and expands the outline of the work to define the boundary between the outline of the work and the approximate area. Give a gap between the lines. Then, edge search points (reference points) are set at predetermined intervals on the boundary line of the expanded general area, and the edge at the minimum distance from the search point is selected as the edge constituting the contour of the workpiece. Therefore, it is possible to extract a contour line with less influence of noise edges. Thereby, an outline can be extracted with high accuracy.

また、膨張処理した概略領域の境界線上にエッジの探索点を設定し、探索点から最少距離にあるエッジをワークの輪郭を構成するエッジとして選択することで、様々な形状のワークに対応させることができる。   Also, by setting a search point for the edge on the boundary line of the expanded approximate area, and selecting the edge that is the minimum distance from the search point as the edge constituting the contour of the work, it is possible to correspond to workpieces of various shapes Can do.

更に、ノイズエッジが除去された精度の高いエッジ情報を元に、三次元モデルフィッティング処理などの演算が可能になり、ワークの正確な位置姿勢の検出を行うことができる。   Furthermore, calculation such as a three-dimensional model fitting process can be performed based on highly accurate edge information from which noise edges have been removed, and the accurate position and orientation of the workpiece can be detected.

以上、本発明の実施形態について説明したが、本発明は上述した実施形態に限定されるものではない。また、本発明の実施形態に記載された効果は、本発明から生じる最も好適な効果を列挙したに過ぎず、本発明による効果は、本発明の実施形態に記載されたものに限定されない。   As mentioned above, although embodiment of this invention was described, this invention is not limited to embodiment mentioned above. In addition, the effects described in the embodiments of the present invention only list the most preferable effects resulting from the present invention, and the effects of the present invention are not limited to those described in the embodiments of the present invention.

例えば、本実施形態においては、ワークを概略領域として特定し、膨張処理した概略領域との境界に基準点を設定したが、本発明においてはこれに限定されない。例えば、背景を背景領域として特定し、背景領域を収縮させて背景領域との境界に基準点を設けるようにしてもよい。   For example, in the present embodiment, the workpiece is specified as the approximate area, and the reference point is set at the boundary with the expanded approximate area. However, the present invention is not limited to this. For example, the background may be specified as the background region, and the reference region may be provided at the boundary with the background region by contracting the background region.

また、本実施形態においては、概略領域41aを所定回数膨張処理して、膨張領域42aを生成したが、本発明においてはこれに限定されない。例えば、膨張処理と収縮処理とを繰り返し行いながら膨張領域42aを生成してもよい。   In the present embodiment, the general region 41a is expanded a predetermined number of times to generate the expanded region 42a. However, the present invention is not limited to this. For example, the expansion region 42a may be generated while repeating the expansion process and the contraction process.

1 ロボットステーション(ロボットシステム)
2 撮像部
3 画像処理装置
3a CPU(制御部)
4 ロボットアーム
5 ロボットアーム
31 元画像取得部(元画像取得手段)
32 領域特定部(領域特定手段)
33 エッジ抽出部(エッジ抽出手段)
34 領域膨張処理部(膨張処理手段)
35 基準点設定部(基準点設定手段)
36 輪郭エッジ選択部(エッジ選択手段)
37 輪郭線抽出部(輪郭線抽出手段)
38 位置姿勢計測部(位置姿勢計測手段)
D 記録媒体
W ワーク
1 Robot station (robot system)
2 Imaging unit 3 Image processing device 3a CPU (control unit)
4 Robot arm 5 Robot arm 31 Original image acquisition unit (original image acquisition means)
32 area specifying part (area specifying means)
33 Edge extraction unit (edge extraction means)
34 Region expansion processing unit (expansion processing means)
35 Reference point setting section (reference point setting means)
36 Contour edge selection unit (edge selection means)
37 Outline extraction unit (contour extraction means)
38 Position and orientation measurement unit (position and orientation measurement means)
D Recording medium W Work

Claims (7)

撮像部により撮像されたワークの元画像を取得する元画像取得手段と、
該元画像取得手段により取得された前記元画像を2値化して、該元画像からワークの概略領域を特定する領域特定手段と、
該領域特定手段により特定された前記概略領域を膨張処理する膨張処理手段と、
前記膨張処理手段により抽出された概略領域の境界線上に、複数の基準点を設定する基準点設定手段と、
前記元画像からコントラスト差に基づき、ワークの輪郭に重なるエッジを含む複数のエッジを抽出するエッジ抽出手段と、
該エッジ抽出手段により抽出された複数のエッジと前記基準点設定手段により設定された前記複数の基準点とを合成し、前記エッジ抽出手段により抽出された前記複数のエッジの中から前記複数の基準点のそれぞれに対して予め定められた位置にあるエッジを選択するエッジ選択手段と、
該エッジ選択手段により選択された複数のエッジから連続したワークの輪郭線を抽出する輪郭線抽出手段と、を備えた、
ことを特徴とする画像処理装置。
Original image acquisition means for acquiring an original image of the work imaged by the imaging unit;
Area specifying means for binarizing the original image acquired by the original image acquiring means and specifying an approximate area of the workpiece from the original image;
Expansion processing means for expanding the approximate area specified by the area specifying means;
A reference point setting means for setting a plurality of reference points on the boundary line of the approximate area extracted by the expansion processing means;
Edge extraction means for extracting a plurality of edges including edges overlapping the outline of the workpiece based on the contrast difference from the original image;
The plurality of edges extracted by the edge extraction unit and the plurality of reference points set by the reference point setting unit are combined, and the plurality of reference points are extracted from the plurality of edges extracted by the edge extraction unit. Edge selection means for selecting an edge at a predetermined position for each of the points;
Contour line extracting means for extracting a contour line of a continuous workpiece from a plurality of edges selected by the edge selecting means,
An image processing apparatus.
前記膨張処理手段は、前記概略領域を膨張処理する際に、2値化した際に発生した孤立点を平滑化して消失させる、
ことを特徴とする請求項1に記載の画像処理装置。
The expansion processing means smoothes and eliminates isolated points generated when binarization is performed when expanding the approximate region.
The image processing apparatus according to claim 1.
前記輪郭線抽出手段により抽出されたワークの輪郭線に、予め記憶された該ワークの三次元モデル情報を照らし合わせて、該ワークの位置姿勢を計測する位置姿勢計測手段と、を備えた、
ことを特徴とする請求項1又は2に記載の画像処理装置。
A position / orientation measuring unit that measures the position / orientation of the workpiece by comparing the three-dimensional model information of the workpiece stored in advance with the outline of the workpiece extracted by the contour extracting unit;
The image processing apparatus according to claim 1, wherein the image processing apparatus is an image processing apparatus.
搬送されてくるワークを撮像する撮像部と、
該撮像部により撮像されたワークの位置姿勢を計測する請求項3に記載の画像処理装置と、
前記画像処理装置により計測されたワークの位置姿勢に基づいて、ワークを把持するロボットアームと、を備えた、
ことを特徴とするロボットシステム。
An imaging unit for imaging the workpiece being conveyed;
The image processing apparatus according to claim 3, which measures the position and orientation of a workpiece imaged by the imaging unit;
A robot arm for gripping the workpiece based on the position and orientation of the workpiece measured by the image processing apparatus,
A robot system characterized by this.
制御部が撮像部により撮像されたワークの元画像を取得する元画像取得工程と、
前記制御部が前記元画像取得工程により取得された前記元画像を2値化して、該元画像からワークの概略領域を特定する領域特定工程と、
前記制御部が前記領域特定工程により特定された前記概略領域を膨張処理する膨張処理工程と、
前記制御部が前記膨張処理工程により膨張処理された概略領域の境界線上に、複数の基準点を設定する基準点設定工程と、
前記制御部が前記元画像からコントラスト差に基づき、ワークの輪郭に重なるエッジを含む複数のエッジを抽出するエッジ抽出工程と、
前記制御部が前記エッジ抽出工程により抽出された複数のエッジと前記基準点設定工程により設定された前記複数の基準点とを合成し、前記エッジ抽出工程により抽出された前記複数のエッジの中から前記複数の基準点のそれぞれに対して予め定められた位置にあるエッジを選択するエッジ選択工程と、
前記制御部が前記エッジ選択工程により選択された複数のエッジから連続したワークの輪郭線を抽出する輪郭線抽出工程と、を備えた、
ことを特徴とする画像処理方法。
An original image acquisition step in which the control unit acquires an original image of the workpiece imaged by the imaging unit;
A region specifying step in which the control unit binarizes the original image acquired by the original image acquisition step, and specifies a schematic region of a workpiece from the original image;
An expansion processing step in which the control unit expands the schematic region identified by the region identification step;
A reference point setting step in which the control unit sets a plurality of reference points on the boundary line of the approximate region expanded by the expansion processing step;
An edge extraction step in which the control unit extracts a plurality of edges including edges overlapping with a contour of a workpiece based on a contrast difference from the original image;
The control unit synthesizes the plurality of edges extracted by the edge extraction step and the plurality of reference points set by the reference point setting step, and from among the plurality of edges extracted by the edge extraction step An edge selection step of selecting an edge at a predetermined position with respect to each of the plurality of reference points;
An outline extraction step in which the control unit extracts an outline of a continuous workpiece from a plurality of edges selected in the edge selection step, and
An image processing method.
請求項5に記載の各工程をコンピュータに実行させるための画像処理プログラム。   An image processing program for causing a computer to execute each step according to claim 5. 請求項6に記載の画像処理プログラムを記録したコンピュータ読み取り可能な記録媒体。
A computer-readable recording medium on which the image processing program according to claim 6 is recorded.
JP2011255928A 2011-11-24 2011-11-24 Image processing apparatus, image processing method, and image processing program Expired - Fee Related JP5791475B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2011255928A JP5791475B2 (en) 2011-11-24 2011-11-24 Image processing apparatus, image processing method, and image processing program

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2011255928A JP5791475B2 (en) 2011-11-24 2011-11-24 Image processing apparatus, image processing method, and image processing program

Publications (2)

Publication Number Publication Date
JP2013109691A JP2013109691A (en) 2013-06-06
JP5791475B2 true JP5791475B2 (en) 2015-10-07

Family

ID=48706354

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2011255928A Expired - Fee Related JP5791475B2 (en) 2011-11-24 2011-11-24 Image processing apparatus, image processing method, and image processing program

Country Status (1)

Country Link
JP (1) JP5791475B2 (en)

Families Citing this family (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP6415026B2 (en) * 2013-06-28 2018-10-31 キヤノン株式会社 Interference determination apparatus, interference determination method, and computer program
JP6099686B2 (en) * 2015-03-20 2017-03-22 株式会社Pfu Image processing apparatus, region detection method, and computer program
JP2016192138A (en) * 2015-03-31 2016-11-10 株式会社オートネットワーク技術研究所 Manufacturing method of wire harness and image processing method
US20180282681A1 (en) * 2015-10-20 2018-10-04 Rohto Pharmaceutical Co., Ltd. Cell treatment apparatus
JP6632656B2 (en) * 2018-05-14 2020-01-22 キヤノン株式会社 Interference determination device, interference determination method, and computer program
JP7271685B2 (en) * 2019-03-21 2023-05-11 ザ プロクター アンド ギャンブル カンパニー Method for automatically transferring pouches with spouts and automatic pouch transfer assembly
JP7066671B2 (en) * 2019-12-11 2022-05-13 キヤノン株式会社 Interference determination device, interference determination method, program and system
JP7470427B2 (en) 2021-08-25 2024-04-18 株式会社ノート GOODS ORDER SUPPORT DEVICE, GOODS ORDER SUPPORT SYSTEM, GOODS ORDER SUPPORT METHOD, AND COMPUTER PROGRAM
CN115661437B (en) * 2022-10-20 2024-01-26 陕西学前师范学院 Image processing system and method

Family Cites Families (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH04308981A (en) * 1991-04-05 1992-10-30 Sony Corp Shape recognizing method
JPH07225848A (en) * 1994-02-10 1995-08-22 Fujitsu General Ltd Image extracting method
JPH08322913A (en) * 1995-05-30 1996-12-10 Sanyo Electric Co Ltd Tablet inspection system
JP2000216979A (en) * 1999-01-22 2000-08-04 Canon Inc Image extraction method and device and storage medium
JP2002269539A (en) * 2000-12-01 2002-09-20 Shigehiro Masui Image processor, image processing method, and computer- readable storage medium with image processing program stored therein, and diagnosis support system using them
JP4044059B2 (en) * 2004-02-25 2008-02-06 株式会社東芝 Separation edge detection apparatus and method
JP4715539B2 (en) * 2006-02-15 2011-07-06 トヨタ自動車株式会社 Image processing apparatus, method thereof, and image processing program
US8374892B2 (en) * 2010-01-25 2013-02-12 Amcad Biomed Corporation Method for retrieving a tumor contour of an image processing system
CN102236784A (en) * 2010-05-07 2011-11-09 株式会社理光 Screen area detection method and system

Also Published As

Publication number Publication date
JP2013109691A (en) 2013-06-06

Similar Documents

Publication Publication Date Title
JP5791475B2 (en) Image processing apparatus, image processing method, and image processing program
JP6125188B2 (en) Video processing method and apparatus
US9330325B2 (en) Apparatus and method for reducing noise in fingerprint images
CN110926330B (en) Image processing apparatus, image processing method, and program
JP6483168B2 (en) System and method for efficiently scoring a probe in an image with a vision system
JP6570370B2 (en) Image processing method, image processing apparatus, program, and recording medium
JP6197340B2 (en) Image processing apparatus, image processing method, and program
JP2010082245A (en) Hair information measuring method
JP6659098B2 (en) Image processing method, image processing apparatus, program, and recording medium
JP2017117341A (en) Object detection method, device and program
JP2017173142A (en) Image processing device, image processing method and micro joint cutting system
US9305235B1 (en) System and method for identifying and locating instances of a shape under large variations in linear degrees of freedom and/or stroke widths
JP6863946B2 (en) Image processing device
JP5160366B2 (en) Pattern matching method for electronic parts
JP5217917B2 (en) Object detection and tracking device, object detection and tracking method, and object detection and tracking program
JP2017102061A (en) Measurement device, measurement method, and manufacturing method of article
JP2013109692A (en) Image processing device, image processing method, and image processing program
JP5545564B2 (en) Cloth product gripping system
JP2005078445A (en) Image processing system
JP2009236550A (en) Flaw detection method
JP2008146132A (en) Image detection device, program, and image detection method
JP2013019845A (en) Image processing device, method and program for calculating shape of spiral spring
JP2005332229A (en) Attitude detector, attitude detection method, and program for the method
JP2021140405A (en) Image search device, image search method and image search program
JP4458210B2 (en) Object detection method

Legal Events

Date Code Title Description
RD04 Notification of resignation of power of attorney

Free format text: JAPANESE INTERMEDIATE CODE: A7424

Effective date: 20130228

A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20141113

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20150702

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

Free format text: JAPANESE INTERMEDIATE CODE: A01

Effective date: 20150707

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20150804

R151 Written notification of patent or utility model registration

Ref document number: 5791475

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R151

LAPS Cancellation because of no payment of annual fees