JP2020064034A - Measurement device, calibration method thereof, and program - Google Patents

Measurement device, calibration method thereof, and program Download PDF

Info

Publication number
JP2020064034A
JP2020064034A JP2018197843A JP2018197843A JP2020064034A JP 2020064034 A JP2020064034 A JP 2020064034A JP 2018197843 A JP2018197843 A JP 2018197843A JP 2018197843 A JP2018197843 A JP 2018197843A JP 2020064034 A JP2020064034 A JP 2020064034A
Authority
JP
Japan
Prior art keywords
exposure time
unit
imaging
imaging unit
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.)
Pending
Application number
JP2018197843A
Other languages
Japanese (ja)
Inventor
島田 卓也
Takuya Shimada
卓也 島田
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 JP2018197843A priority Critical patent/JP2020064034A/en
Publication of JP2020064034A publication Critical patent/JP2020064034A/en
Pending legal-status Critical Current

Links

Images

Abstract

To provide an advantageous technique for accurately measuring a position and posture of an object.SOLUTION: A measurement device for measuring a position and posture of an object includes: a first imaging unit for imaging the object while illuminating the object with first light; a second imaging unit for imaging the object while illuminating the object with second light; and a processing unit for obtaining a position and posture of the object based on each image obtained by each of the first imaging unit and the second imaging unit. The processing unit sets a common exposure time for the first and the second imaging units to adjust first light intensity and second light intensity for illuminating the object so that a target light quantity can be obtained in the first and the second imaging units, respectively.SELECTED DRAWING: Figure 2A

Description

本発明は、対象物の位置姿勢を計測する計測装置、その校正方法、およびプログラムに関する。   The present invention relates to a measuring device that measures the position and orientation of an object, a calibration method thereof, and a program.

近年、ばら積みされた複数のワーク(対象物)をロボットハンドで1個ずつ取り出すピッキング作業の自動化が進められており、該ワークの位置姿勢を精度よく計測することが求められている。特許文献1には、照明光源と撮像素子とを含む撮像部を2つ備え、一方の撮像部で得られた被測定物の濃淡画像と、他方の撮像部で得られた被測定物のパターン投影画像とに基づいて、被測定物の3次元形状を測定する方法が開示されている。   In recent years, automation of picking work for taking out a plurality of workpieces (objects) stacked in bulk one by one with a robot hand has been advanced, and it is required to accurately measure the position and orientation of the workpieces. Patent Document 1 includes two image pickup units including an illumination light source and an image pickup device, and a grayscale image of the DUT obtained by one image pickup unit and a pattern of the DUT obtained by the other image pickup unit. A method of measuring a three-dimensional shape of a measured object based on a projected image is disclosed.

特許第5122729号公報Japanese Patent No. 51222729

複数の撮像部を用いてワークの位置姿勢を計測する計測装置では、ロボットハンドに取り付けられる場合、ロボットハンドの移動中に(すなわち、ワークと計測装置とが相対的に移動している状態で)ワークの撮像を行うことが求められる。そのため、複数の撮像部間において撮像位置のずれが生じ、撮像画像の像ぶれ(ボケ)が互いに異なってしまうと、ワークの位置姿勢を精度よく計測することが困難になりうる。   In a measuring device that measures the position and orientation of a work using a plurality of imaging units, when attached to a robot hand, the robot hand is moving (that is, in the state where the work and the measuring device are moving relative to each other). It is required to image the work. Therefore, if the image pickup positions are displaced between the plurality of image pickup units and the image blurs (blurring) of the picked-up images are different from each other, it may be difficult to accurately measure the position and orientation of the work.

そこで、本発明は、対象物の位置姿勢を精度よく計測するために有利な技術を提供することを目的とする。   Therefore, it is an object of the present invention to provide an advantageous technique for accurately measuring the position and orientation of an object.

上記目的を達成するために、本発明の一側面としての計測装置は、対象物の位置姿勢を計測する計測装置であって、第1光で前記対象物を照明しながら前記対象物を撮像する第1撮像部と、第2光で前記対象物を照明しながら前記対象物を撮像する第2撮像部と、前記第1撮像部および前記第2撮像部でそれぞれ得られた画像に基づいて、前記対象物の位置姿勢を求める処理部と、を含み、前記処理部は、前記第1撮像部および前記第2撮像部に対して共通の露光時間を設定し、前記共通の露光時間に基づいて、前記第1撮像部および前記第2撮像部でそれぞれ目標光量が得られるように、前記対象物を照明する前記第1光の強度および前記第2光の強度をそれぞれ調整する、ことを特徴とする。   In order to achieve the above object, a measuring device according to one aspect of the present invention is a measuring device that measures the position and orientation of an object, and images the object while illuminating the object with a first light. Based on a first image capturing unit, a second image capturing unit that captures the object while illuminating the target with second light, and images obtained by the first image capturing unit and the second image capturing unit, respectively, A processing unit for determining the position and orientation of the object, wherein the processing unit sets a common exposure time for the first imaging unit and the second imaging unit, and based on the common exposure time. Adjusting the intensity of the first light and the intensity of the second light for illuminating the target object so that the target light amounts can be obtained by the first imaging unit and the second imaging unit, respectively. To do.

本発明の更なる目的又はその他の側面は、以下、添付図面を参照して説明される好ましい実施形態によって明らかにされるであろう。   Further objects and other aspects of the present invention will be made clear by the preferred embodiments described below with reference to the accompanying drawings.

本発明によれば、例えば、対象物の位置姿勢を精度よく計測するために有利な技術を提供することができる。   According to the present invention, for example, an advantageous technique for accurately measuring the position and orientation of a target object can be provided.

計測装置が搭載されたロボットシステム100の一例を示す図である。It is a figure which shows an example of the robot system 100 with which the measuring device was mounted. 撮像装置を示す模式図である。It is a schematic diagram which shows an imaging device. ワークに投影されるパターン像の一例を示す模式図である。It is a schematic diagram which shows an example of the pattern image projected on a work. 第1実施形態に係る計測処理装置のハードウエア構成を示すブロック図である。It is a block diagram which shows the hardware constitutions of the measurement processing apparatus which concerns on 1st Embodiment. 第1実施形態に係る計測処理装置の機能構成を示すブロック図である。It is a block diagram which shows the functional structure of the measurement processing apparatus which concerns on 1st Embodiment. 第1実施形態に係る計測装置による計測方法を示すフローチャートである。It is a flow chart which shows the measuring method by the measuring device concerning a 1st embodiment. 基準露光時間の設定方法の一例を示すフローチャートである。9 is a flowchart showing an example of a method of setting a reference exposure time. 基準露光時間の設定方法の一例を示すフローチャートである。9 is a flowchart showing an example of a method of setting a reference exposure time. 第1実施形態の変形例に係る計測処理装置の機能構成を示すブロック図である。It is a block diagram which shows the functional structure of the measurement processing apparatus which concerns on the modification of 1st Embodiment. 撮像情報の一例を示す模式図である。It is a schematic diagram which shows an example of imaging information. 第1実施形態の変形例に係る計測装置による計測方法を示すフローチャートである。It is a flow chart which shows the measuring method by the measuring device concerning the modification of a 1st embodiment. 第2実施形態に係る計測処理装置の機能構成を示すブロック図である。It is a block diagram which shows the functional structure of the measurement processing apparatus which concerns on 2nd Embodiment. 第2実施形態に係る計測装置による計測方法を示すフローチャートである。It is a flowchart which shows the measuring method by the measuring device which concerns on 2nd Embodiment. 第2実施形態の変形例1に係る計測処理装置の機能構成を示すブロック図である。It is a block diagram which shows the function structure of the measurement processing apparatus which concerns on the modification 1 of 2nd Embodiment. 第2実施形態の変形例1に係る計測装置による計測方法を示すフローチャートである。It is a flowchart which shows the measuring method by the measuring device which concerns on the modification 1 of 2nd Embodiment. 第2実施形態の変形例3に係る計測処理装置の機能構成を示すブロック図である。It is a block diagram which shows the functional structure of the measurement processing apparatus which concerns on the modification 3 of 2nd Embodiment. 距離−撮像情報の一例を示す模式図である。It is a schematic diagram which shows an example of distance-imaging information. 第2実施形態の変形例3に係る計測装置による計測方法を示すフローチャートである。It is a flowchart which shows the measuring method by the measuring device which concerns on the modification 3 of 2nd Embodiment. 距離−撮像情報の取得方法を示すフローチャートである。It is a flowchart which shows the acquisition method of distance-imaging information.

以下、添付図面を参照して、本発明の好適な実施の形態について説明する。なお、各図において、同一の部材ないし要素については同一の参照番号を付し、重複する説明は省略する。   Hereinafter, preferred embodiments of the present invention will be described with reference to the accompanying drawings. In each drawing, the same members or elements are designated by the same reference numerals, and duplicated description will be omitted.

<第1実施形態>
本発明に係る第1実施形態について説明する。図1は、対象物としてのワーク106の位置姿勢を計測する計測装置が搭載されたロボットシステム100の一例であり、パレットの中にばら積みされた複数のワーク106を1個ずつ取り出すピッキングシステムの模式図である。
<First Embodiment>
A first embodiment according to the present invention will be described. FIG. 1 is an example of a robot system 100 equipped with a measuring device that measures the position and orientation of a workpiece 106 as an object, and is a schematic diagram of a picking system that takes out a plurality of workpieces 106 stacked in a pallet one by one. It is a figure.

ワーク106の位置姿勢を計測する計測装置は、撮像装置104と計測処理装置105(処理部)とから成り、撮像装置104は、ロボットアーム101の先端にあるハンド102に固定して取り付けられている。ロボット制御装置103は、ロボットアーム101を制御して、パレット107の中にばら積みされたワーク106が撮像装置104の視野に入るようにハンド102を移動させる。次に、ロボット制御装置103は、計測処理装置105にワーク106の位置姿勢の計測を指示する。このとき、ロボット制御装置103は、ハンド102の位置姿勢に関する情報を計測処理装置105に送信する。   The measuring device for measuring the position and orientation of the work 106 is composed of an image pickup device 104 and a measurement processing device 105 (processing unit), and the image pickup device 104 is fixedly attached to the hand 102 at the tip of the robot arm 101. . The robot control device 103 controls the robot arm 101 to move the hand 102 so that the workpieces 106 stacked in the pallet 107 are in the visual field of the imaging device 104. Next, the robot control device 103 instructs the measurement processing device 105 to measure the position and orientation of the work 106. At this time, the robot control device 103 transmits information about the position and orientation of the hand 102 to the measurement processing device 105.

計測処理装置105は、計測指示を受信すると、撮像装置104を制御してワーク106を撮像させる。そして、計測処理装置105は、撮像装置104で得られた画像とハンド102の位置姿勢とに基づいて、ワーク106の位置姿勢を求め(計算し)、ロボット制御装置103に送信する。ロボット制御装置103は、計測されたワーク106の位置姿勢に基づいてロボットアーム101を制御し、ハンド102でワーク106を把持してパレット107から取り出す。そして、ロボットアーム101は、ワーク106を他の部品に組み付けることにより、複数の部品で構成された物品、例えば電子回路基板や機械などを製造することができる。また、移動されたワーク106を加工することにより、物品を製造することができる。このような作業は、例えば、パレット107にワーク106が無くなるまで繰り返し行われる。ここで、計測処理装置105は、撮像装置104に組み込まれて一体で計測装置を構成する形態であってもよいし、ロボット制御装置103に組み込まれてロボット制御装置の一部を構成する形態であってもよい。   Upon receiving the measurement instruction, the measurement processing device 105 controls the imaging device 104 to image the work 106. Then, the measurement processing device 105 obtains (calculates) the position and orientation of the work 106 based on the image obtained by the imaging device 104 and the position and orientation of the hand 102, and transmits the position and orientation to the robot control device 103. The robot control device 103 controls the robot arm 101 based on the measured position and orientation of the work 106, holds the work 106 with the hand 102, and takes it out from the pallet 107. Then, the robot arm 101 can manufacture an article composed of a plurality of parts, such as an electronic circuit board or a machine, by assembling the work 106 with other parts. Further, an article can be manufactured by processing the moved work 106. Such work is repeatedly performed until, for example, the work 106 is left on the pallet 107. Here, the measurement processing device 105 may be incorporated in the imaging device 104 to integrally form a measurement device, or may be incorporated in the robot control device 103 to form a part of the robot control device. It may be.

撮像装置の構成例
次に、撮像装置104の構成例について説明する
図2Aは、撮像装置104を示す模式図である。本実施形態の撮像装置104は、パターン投影部201と、濃淡画像用の照明光源202と、センサ部203とを含みうる。パターン投影部201は、例えば、第1波長の光(第1光)を射出するパターン投影画像用の照明光源204と、パターンマスク205と、投影レンズ206とから成り、パターンマスク205のパターン像を計測対象物としてのワーク106に投影する。濃淡画像用の照明光源202は、第1波長とは異なる第2波長の光(第2光)を射出する光源であり、計測対象物としてのワーク106を照明する。センサ部203は、例えば、分光プリズム207と、結像レンズ208と、パターン投影画像用の撮像センサ209と、濃淡画像用の撮像センサ210とから成る。分光プリズム207は、計測対象物としてのワーク106からの反射光を波長別に分割し、結像レンズ208は、計測対象物としてのワーク106の像を各撮像センサ上に結像する。
Configuration Example of Imaging Device Next, a configuration example of the imaging device 104 will be described. FIG. 2A is a schematic diagram showing the imaging device 104. The imaging device 104 of the present embodiment can include a pattern projection unit 201, a grayscale image illumination light source 202, and a sensor unit 203. The pattern projection unit 201 includes, for example, an illumination light source 204 for a pattern projection image that emits light of a first wavelength (first light), a pattern mask 205, and a projection lens 206, and displays a pattern image of the pattern mask 205. The image is projected on the work 106 as a measurement object. The grayscale image illumination light source 202 is a light source that emits light (second light) having a second wavelength different from the first wavelength, and illuminates the workpiece 106 as a measurement target. The sensor unit 203 includes, for example, a spectral prism 207, an imaging lens 208, an image pickup sensor 209 for a pattern projection image, and an image pickup sensor 210 for a grayscale image. The spectroscopic prism 207 divides the reflected light from the work 106 as the measurement target according to wavelength, and the imaging lens 208 forms an image of the work 106 as the measurement target on each image sensor.

ここで、第1光は、例えば青色の光であり、パターン投影画像用の照明光源204としては青色のLEDが用いられうる。第2光は、例えば赤色の光であり、濃淡画像用の照明光源202としては赤色のLEDが用いられうる。分光プリズム207は、例えば、青色の光を透過し、赤色の光を反射するダイクロイックプリズムである。パターン投影画像用の撮像センサ209および濃淡画像用の撮像センサ210はそれぞれ、CMOSやCCDなどの2次元センサであり、受光した光量に対応する信号で構成される画像を形成する。画像を構成する信号は、例えば16ビットで表現される0から65535の値であり、値が大きいほど光量が大きいことを示す。図2Bは、パターンマスク205に形成されたパターン、すなわち、ワーク106に投影されるパターン像220の一例を示す模式図である。本実施形態で用いられるパターン像220は、等間隔にライン221が配置されたラインパターンであって、各ライン上にドット222が離散的に配置されたパターンである。   Here, the first light is, for example, blue light, and a blue LED can be used as the illumination light source 204 for the pattern projection image. The second light is, for example, red light, and a red LED can be used as the illumination light source 202 for the grayscale image. The spectral prism 207 is, for example, a dichroic prism that transmits blue light and reflects red light. The image sensor 209 for pattern projection image and the image sensor 210 for grayscale image are each a two-dimensional sensor such as CMOS or CCD, and form an image composed of signals corresponding to the amount of received light. The signal forming the image has a value of 0 to 65535 represented by, for example, 16 bits, and a larger value indicates a larger light amount. FIG. 2B is a schematic diagram showing an example of a pattern formed on the pattern mask 205, that is, an example of the pattern image 220 projected on the work 106. The pattern image 220 used in this embodiment is a line pattern in which lines 221 are arranged at equal intervals, and dots 222 are discretely arranged on each line.

パターン投影部201およびセンサ部203(撮像センサ209)は、1つの撮像部(以下、第1撮像部と呼ぶ)を構成し、パターン光としての第1光でワーク106を照明しながら該ワーク106を撮像することでパターン投影画像を得ることができる。具体的には、第1撮像部では、パターン投影部201によってパターン光(第1光)がワーク106に投影され、ワーク106での反射光が分光プリズム207を透過して撮像センサ209で受光されることにより、該ワーク106のパターン投影画像が得られる。また、濃淡画像用の照明光源202およびセンサ部203(撮像センサ210)は、他の1つの撮像部(以下、第2撮像部と呼ぶ)を構成し、第2光でワーク106を照明しながら該ワーク106を撮像することで濃淡画像を得ることができる。具体的には、第2撮像部では、照明光源202によってワーク106が第2光で照明され、ワーク106での反射光が分光プリズム207で反射されて撮像センサ210で受光されることにより、該ワーク106の濃淡画像が得られる。   The pattern projection unit 201 and the sensor unit 203 (imaging sensor 209) constitute one imaging unit (hereinafter referred to as a first imaging unit), and the workpiece 106 is illuminated with the first light as pattern light while illuminating the workpiece 106. A pattern projection image can be obtained by capturing. Specifically, in the first image pickup unit, the pattern light (first light) is projected onto the work 106 by the pattern projection unit 201, and the reflected light from the work 106 is transmitted through the spectral prism 207 and received by the image sensor 209. By doing so, a pattern projection image of the work 106 is obtained. Further, the illumination light source 202 for the grayscale image and the sensor unit 203 (imaging sensor 210) constitute another one imaging unit (hereinafter, referred to as a second imaging unit), while illuminating the work 106 with the second light. A grayscale image can be obtained by imaging the work 106. Specifically, in the second image pickup unit, the illumination light source 202 illuminates the work 106 with the second light, and the light reflected by the work 106 is reflected by the spectral prism 207 and received by the image sensor 210. A grayscale image of the work 106 is obtained.

計測処理装置の構成例
次に、計測処理装置105の構成例について説明する
図3は、計測処理装置105のハードウエア構成を示すブロック図である。本実施形態の計測処理装置105は、例えばコンピュータであり、マイクロプロセッサ(CPU)301と、ランダムアクセスメモリなどのメモリ302とを備える。また、キーボードなどの入力部303、ハードディスクドライブなどの記憶装置304を備える。また、撮像装置104に対する通信インタフェース(以下、撮像I/Fと呼ぶ)305と、ロボット制御装置103に対する通信インタフェース(以下、RC I/Fと呼ぶ)306とを備える。
Configuration Example of Measurement Processing Device Next, a configuration example of the measurement processing device 105 will be described. FIG. 3 is a block diagram showing a hardware configuration of the measurement processing device 105. The measurement processing device 105 of this embodiment is, for example, a computer, and includes a microprocessor (CPU) 301 and a memory 302 such as a random access memory. Further, it is provided with an input unit 303 such as a keyboard and a storage device 304 such as a hard disk drive. Further, a communication interface (hereinafter, referred to as an imaging I / F) 305 for the imaging device 104 and a communication interface (hereinafter, referred to as an RC I / F) 306 for the robot control device 103 are provided.

CPU301は、メモリ302に格納されたプログラムに従って種々の処理を実行するものであり、特に、後述する露光時間設定処理や、光強度設定処理、位置姿勢の計算処理を実行する。これらのプログラムは、記憶装置304に記憶しておくか、あるいは不図示の外部装置から供給されうる。計測処理装置105は、撮像I/F305を介して、照明光源の光強度や露光時間などの撮像条件を撮像装置104に送信する。また、撮像I/F305を介して、撮像の実施を指示するとともに、撮像装置104で得られた画像を受信する。また、計測処理装置105は、RCI/F306を介して、ロボット制御装置103から計測指示を受信すると共に、計算した計測対象の位置姿勢をロボット制御装置103へ送信する。さらに、計測処理装置105は、ビデオI/F307を介してモニタ308(表示部)に種々の情報を出力すると共に、入力部303を通じて各種情報を入力する。   The CPU 301 executes various processes according to programs stored in the memory 302, and particularly executes an exposure time setting process, a light intensity setting process, and a position / orientation calculation process which will be described later. These programs can be stored in the storage device 304 or supplied from an external device (not shown). The measurement processing device 105 transmits the imaging conditions such as the light intensity of the illumination light source and the exposure time to the imaging device 104 via the imaging I / F 305. In addition, the image capturing I / F 305 is instructed to perform image capturing, and the image obtained by the image capturing apparatus 104 is received. Further, the measurement processing device 105 receives a measurement instruction from the robot control device 103 via the RCI / F 306, and also transmits the calculated position and orientation of the measurement target to the robot control device 103. Further, the measurement processing device 105 outputs various information to the monitor 308 (display unit) via the video I / F 307 and inputs various information via the input unit 303.

図4は、計測処理装置105の機能構成を示すブロック図である。本実施形態に係る計測処理装置105は、制御部401と、RC通信部402と、入出力部403と、撮像制御部404とを備える。また、第1撮像部431および第2撮像部432の撮像条件(照明光源の光強度、露光時間など)を設定する撮像条件設定部410と、撮像画像に基づいて対象物(ワーク106)の位置姿勢を計算する位置姿勢計算部420とを備える。ここで、第1撮像部431および第2撮像部432は、撮像条件を個別に調整可能に構成される。これにより、第1撮像部431および第2撮像部432において、撮像条件を並行して設定(調整)することができるため、撮像条件の設定に要する時間を短縮することができる。   FIG. 4 is a block diagram showing a functional configuration of the measurement processing device 105. The measurement processing device 105 according to this embodiment includes a control unit 401, an RC communication unit 402, an input / output unit 403, and an imaging control unit 404. Further, an imaging condition setting unit 410 that sets imaging conditions (light intensity of an illumination light source, exposure time, etc.) of the first imaging unit 431 and the second imaging unit 432, and the position of the target object (workpiece 106) based on the captured image. A position / orientation calculation unit 420 for calculating the orientation. Here, the 1st imaging part 431 and the 2nd imaging part 432 are comprised so that imaging conditions can be adjusted individually. Accordingly, the imaging conditions can be set (adjusted) in parallel in the first imaging unit 431 and the second imaging unit 432, and thus the time required to set the imaging conditions can be shortened.

制御部401は、各部を制御して、撮像条件の設定と対象物の位置姿勢の計算を行う。RC通信部402は、ロボット制御装置103からの計測指示を待ち受けするとともに、計算した計測対象の位置姿勢をロボット制御装置103へ送信する。入出力部403は、処理に係る各種条件を外部から入力し、設定した撮像条件や対象物の位置姿勢の計算結果を外部へ出力する。撮像制御部404は、撮像条件設定部410で設定した撮像条件に基づいて撮像装置104を制御して撮像を実施し、撮像画像を撮像装置104から受信して位置姿勢計算部420に格納する。   The control unit 401 controls each unit to set imaging conditions and calculate the position and orientation of the object. The RC communication unit 402 waits for a measurement instruction from the robot control device 103 and transmits the calculated position and orientation of the measurement target to the robot control device 103. The input / output unit 403 inputs various conditions related to the process from the outside, and outputs the calculation result of the set imaging condition and the position / orientation of the object to the outside. The image capturing control unit 404 controls the image capturing apparatus 104 based on the image capturing condition set by the image capturing condition setting unit 410 to capture an image, receives a captured image from the image capturing device 104, and stores the captured image in the position and orientation calculation unit 420.

本実施形態において、撮像制御部404は、第1光強度格納部417に格納された目標光強度になるように第1撮像部431の照明光源204(第1光の強度)を調整する。そして、露光時間格納部415に格納された露光時間で撮像センサ209に対象物を撮像させるように、第1撮像部431を制御する。第1撮像部431で得られたパターン投影画像は、パターン投影画像格納部421に格納される。また、撮像制御部404は、第2光強度格納部418に格納された目標光強度になるように第2撮像部432の照明光源202(第2光の強度)を調整する。そして、露光時間格納部415に格納された露光時間で撮像センサ210に対象物を撮像させるように、第2撮像部432を制御する。第2撮像部432で得られた濃淡画像は、濃淡画像格納部422に格納される。ここで、撮像制御部404は、第1撮像部431と第2撮像部432とを同期制御し、第1撮像部431および第2撮像部432に対象物を同時に撮像させる。つまり、撮像制御部404は、同じタイミングで対象物の撮像を開始するように第1撮像部431および第2撮像部432を制御する。   In the present embodiment, the imaging control unit 404 adjusts the illumination light source 204 (first light intensity) of the first imaging unit 431 so that the target light intensity stored in the first light intensity storage unit 417 is achieved. Then, the first image capturing unit 431 is controlled so that the image sensor 209 captures an image of the object with the exposure time stored in the exposure time storage unit 415. The pattern projection image obtained by the first imaging unit 431 is stored in the pattern projection image storage unit 421. Further, the imaging control unit 404 adjusts the illumination light source 202 (second light intensity) of the second imaging unit 432 so that the target light intensity stored in the second light intensity storage unit 418 becomes the target light intensity. Then, the second imaging unit 432 is controlled so that the imaging sensor 210 images the object for the exposure time stored in the exposure time storage unit 415. The grayscale image obtained by the second imaging unit 432 is stored in the grayscale image storage unit 422. Here, the image capturing control unit 404 synchronously controls the first image capturing unit 431 and the second image capturing unit 432, and causes the first image capturing unit 431 and the second image capturing unit 432 to simultaneously image the object. That is, the imaging control unit 404 controls the first imaging unit 431 and the second imaging unit 432 so as to start imaging the target object at the same timing.

撮像条件設定部410は、制御部401の指示により、撮像装置104における第1撮像部431および第2撮像部432の撮像条件を設定する。撮像条件とは、露光時間と照明光源の光強度とを含みうる。撮像装置104では、第1撮像部431および第2撮像部432の各々において、撮像画像が適切な明るさでないと位置姿勢の計測精度は低下する。つまり、各撮像センサ(209、210)での受光光量が、撮像画像を適切な明るさにするための目標光量になるように、第1撮像部431および第2撮像部432を制御することが好ましい。よって、撮像条件設定部410は、対象物の撮像に先立って、第1撮像部431および第2撮像部432でそれぞれ目標光量が得られるように、対象物に応じて撮像条件を設定する。ここで、「目標光量」とは、各撮像部について、撮像画像を適切な明るさ(目標明るさ)にするための撮像センサでの受光光量の目標値のことを示し、「光量」は、光強度の時間積分によって表されうる。また、「露光時間」とは、各撮像部の撮像センサを露光している期間、すなわち、対象物からの反射光が各撮像部の撮像センサに入射している期間を示す。「露光時間」は、撮像センサにおける電荷蓄積時間、露出時間、撮像時間とも呼ばれることもある。   The image capturing condition setting unit 410 sets the image capturing conditions of the first image capturing unit 431 and the second image capturing unit 432 in the image capturing apparatus 104 according to an instruction from the control unit 401. The imaging condition may include the exposure time and the light intensity of the illumination light source. In the image capturing apparatus 104, the accuracy of position / orientation measurement decreases in each of the first image capturing unit 431 and the second image capturing unit 432 unless the captured image has appropriate brightness. That is, it is possible to control the first imaging unit 431 and the second imaging unit 432 so that the amount of light received by each of the imaging sensors (209, 210) is the target amount of light for making the captured image have appropriate brightness. preferable. Therefore, the image capturing condition setting unit 410 sets the image capturing condition according to the target object so that the first image capturing unit 431 and the second image capturing unit 432 can obtain the respective target light amounts prior to capturing the target object. Here, the "target light amount" refers to a target value of the amount of light received by the image sensor for making the captured image have appropriate brightness (target brightness) for each imaging unit, and the "light amount" is It can be represented by the time integral of the light intensity. In addition, the “exposure time” indicates a period during which the image sensor of each image capturing unit is exposed, that is, a period during which the reflected light from the object is incident on the image sensor of each image capturing unit. The “exposure time” may also be referred to as a charge accumulation time, an exposure time, or an imaging time in the image sensor.

基準露光時間取得部411は、第1撮像部431に予め設定された第1基準露光時間と、第2撮像部432に予め設定された第2基準露光時間とを取得して、第1基準露光時間格納部412および第2基準露光時間格納部413にそれぞれ格納する。第1基準露光時間とは、照明光源204(第1光)の光強度を基準光強度としたときに第1撮像部431で目標光量(第1目標光量)が得られる露光時間である。同様に、第2基準露光時間とは、照明光源202(第2光)の光強度を基準光強度としたときに第2撮像部432で目標光量(第2目標光量)が得られる露光時間である。すなわち、基準露光時間は、照明光源の光強度を基準光強度に設定した条件下において、目標光量(または目標明るさの撮像画像)を得ることができる最短の露光時間を示す。基準光強度は、撮像部ごとに異なっていてもよい。例えば、第1撮像部431で用いられる基準光強度は、照明光源204に設定可能(実現可能)な第1光の最大強度であり、第2撮像部432で用いられる基準光強度は、照明光源202に設定可能(実現可能)な第2光の最大強度でありうる。基準露光時間の取得方法の詳細は後述する。   The reference exposure time acquisition unit 411 acquires the first reference exposure time preset in the first imaging unit 431 and the second reference exposure time preset in the second imaging unit 432 to obtain the first reference exposure time. The time is stored in the time storage unit 412 and the second reference exposure time storage unit 413, respectively. The first reference exposure time is an exposure time at which the first image pickup unit 431 obtains a target light amount (first target light amount) when the light intensity of the illumination light source 204 (first light) is used as the reference light intensity. Similarly, the second reference exposure time is an exposure time at which the second imaging unit 432 obtains the target light amount (second target light amount) when the light intensity of the illumination light source 202 (second light) is used as the reference light intensity. is there. That is, the reference exposure time indicates the shortest exposure time that can obtain the target light amount (or the captured image of the target brightness) under the condition that the light intensity of the illumination light source is set to the reference light intensity. The reference light intensity may be different for each imaging unit. For example, the reference light intensity used in the first imaging unit 431 is the maximum intensity of the first light that can be set (realizable) in the illumination light source 204, and the reference light intensity used in the second imaging unit 432 is the illumination light source. It can be the maximum intensity of the second light that can be set (realizable) to 202. Details of the method of acquiring the reference exposure time will be described later.

露光時間設定部414は、複数の撮像部に対して共通の露光時間(以下、共通露光時間と呼ぶことがある)を設定し、設定した共通露光時間を露光時間格納部415に格納する。例えば、露光時間設定部414は、複数の撮像部のうち基準露光時間が最も長い撮像部を基準撮像部とし、基準撮像部の基準露光時間を、共通露光時間として設定する。本実施形態において、第1撮像部431の基準露光時間が第2撮像部432の基準露光時間よりも長い場合、露光時間設定部414は、第1撮像部431を基準撮像部に決定する。そして、第1撮像部431から取得した基準露光時間を、第1撮像部431と第2撮像部432との双方で適用される共通露光時間として設定する。   The exposure time setting unit 414 sets a common exposure time (hereinafter, may be referred to as a common exposure time) for a plurality of imaging units, and stores the set common exposure time in the exposure time storage unit 415. For example, the exposure time setting unit 414 sets the image pickup unit having the longest reference exposure time among the plurality of image pickup units as the reference image pickup unit, and sets the reference exposure time of the reference image pickup unit as the common exposure time. In the present embodiment, when the reference exposure time of the first imaging unit 431 is longer than the reference exposure time of the second imaging unit 432, the exposure time setting unit 414 determines the first imaging unit 431 as the reference imaging unit. Then, the reference exposure time acquired from the first imaging unit 431 is set as the common exposure time applied by both the first imaging unit 431 and the second imaging unit 432.

照明光強度設定部416は、第1撮像部431および第2撮像部432の各々について照明光源の目標光強度を個別に決定し、第1光強度格納部417および第2光強度格納部418にそれぞれ格納する。照明光源の目標光強度は、以下の式(1)によって算出されうる。   The illumination light intensity setting unit 416 individually determines the target light intensity of the illumination light source for each of the first imaging unit 431 and the second imaging unit 432, and stores the target light intensity in the first light intensity storage unit 417 and the second light intensity storage unit 418. Store each. The target light intensity of the illumination light source can be calculated by the following equation (1).

Figure 2020064034
Figure 2020064034

例えば、第1撮像部431の第1基準露光時間の方が第2撮像部432の第2基準露光時間よりも長い場合、第1撮像部431が基準撮像部に決定され、第1基準露光時間が共通露光時間に決定される。そして、第1撮像部431における照明光源204の目標光強度は、以下の式(2)により決定される。この例の場合、第1撮像部431に設定される露光時間(共通露光時間)は、第1撮像部431に既に設定されている第1基準露光時間と同じとなるため、第1撮像部431の目標光強度は、第1撮像部431に既に設定されている基準光強度と同じとなる。よって、第1撮像部431では、このように決定された共通露光時間および目標光強度を有する撮像条件で対象物を撮像することにより、撮像センサ209で目標光量(第1目標光量)を得ることができる。   For example, when the first reference exposure time of the first imaging unit 431 is longer than the second reference exposure time of the second imaging unit 432, the first imaging unit 431 is determined as the reference imaging unit and the first reference exposure time Is determined as the common exposure time. Then, the target light intensity of the illumination light source 204 in the first imaging unit 431 is determined by the following equation (2). In the case of this example, the exposure time (common exposure time) set in the first imaging unit 431 is the same as the first reference exposure time already set in the first imaging unit 431, so the first imaging unit 431 The target light intensity of is the same as the reference light intensity that is already set in the first imaging unit 431. Therefore, in the first image capturing unit 431, the target light amount (first target light amount) is obtained by the image sensor 209 by capturing an image of the object under the image capturing condition having the common exposure time and the target light intensity thus determined. You can

Figure 2020064034
Figure 2020064034

一方、第2撮像部432に設定される露光時間(共通露光時間)は、第2撮像部432に既に設定されている第2基準露光時間に対し、(第1撮像部431の基準露光時間/第2撮像部432の基準露光時間)倍だけ長い時間に設定される。そのため、第2撮像部432における照明光源202の目標光強度は、以下の式(3)により、第2撮像部432に既に設定されている基準光強度より小さい値に決定される。よって、第2撮像部432では、このように決定された共通露光時間および目標光強度を有する撮像条件で対象物を撮像することにより、撮像センサ210で目標光量(第2目標光量)を得ることができる。   On the other hand, the exposure time (common exposure time) set in the second imaging unit 432 is (reference exposure time of the first imaging unit 431 / reference exposure time / common exposure time) set in the second imaging unit 432. The reference exposure time of the second image capturing unit 432) is set to a time longer than the reference exposure time. Therefore, the target light intensity of the illumination light source 202 in the second image pickup section 432 is determined to be a value smaller than the reference light intensity already set in the second image pickup section 432 by the following equation (3). Therefore, the second image capturing section 432 obtains the target light amount (second target light amount) by the image sensor 210 by capturing an image of the object under the image capturing condition having the common exposure time and the target light intensity thus determined. You can

Figure 2020064034
Figure 2020064034

位置姿勢計算部420は、制御部401の指示により、第1撮像部431で得られたパターン投影画像と、第2撮像部432で得られた濃淡画像とに基づいて、対象物の位置姿勢を計算する。   The position / orientation calculation unit 420 determines the position / orientation of the target object based on the pattern projection image obtained by the first imaging unit 431 and the grayscale image obtained by the second imaging unit 432 according to an instruction from the control unit 401. calculate.

距離画像生成部423は、第1撮像部431で得られてパターン投影画像格納部421に格納されたパターン投影画像に基づいて距離画像を生成し、距離画像格納部424に格納する。距離画像は、パターン投影部201により対象物に投影されるパターン像220と、該パターン像220を対象物に投影して第1撮像部432で得られた画像のパターンとの対応付けによる公知の三角測量を利用して生成される。すなわち、距離画像は次の手順で生成される。まず、第1撮像部432で得られてパターン投影画像格納部421に格納されたパターン投影画像から、ラインが抽出される。次に、抽出されたラインからドットが抽出される。そして、抽出された各ドットについて、パターン像220上で対応するドットが探索される。当該対応するドットは、パターン投影画像から抽出されたドットの位置に対応する、パターン像220のエピポーラ線上から探索される。次に、パターン投影画像上のドットとパターン像220上のドットの対応関係から、パターン投影画像から抽出されたライン上の各点とパターン像のライン上の各点とが対応付けられる。そして、対応する点の画像上の位置に基づいて、三角測量の原理により、パターン投影画像から抽出されたライン上の各点に対応する3次元座標が計算される。そして、この3次元座標から距離画像が生成される。   The distance image generation unit 423 generates a distance image based on the pattern projection image obtained by the first imaging unit 431 and stored in the pattern projection image storage unit 421, and stores the distance image in the distance image storage unit 424. The range image is known by associating the pattern image 220 projected on the object by the pattern projection unit 201 with the pattern of the image obtained by the first imaging unit 432 by projecting the pattern image 220 on the object. Generated using triangulation. That is, the range image is generated by the following procedure. First, a line is extracted from the pattern projection image obtained by the first imaging unit 432 and stored in the pattern projection image storage unit 421. Next, dots are extracted from the extracted line. Then, for each extracted dot, a corresponding dot is searched for on the pattern image 220. The corresponding dot is searched for on the epipolar line of the pattern image 220, which corresponds to the position of the dot extracted from the pattern projection image. Next, from the correspondence relationship between the dots on the pattern projection image and the dots on the pattern image 220, each point on the line extracted from the pattern projection image is associated with each point on the line of the pattern image. Then, based on the position of the corresponding point on the image, three-dimensional coordinates corresponding to each point on the line extracted from the pattern projection image are calculated by the principle of triangulation. Then, a distance image is generated from the three-dimensional coordinates.

輪郭画像生成部425は、第2撮像部432で得られて濃淡画像格納部422に格納された濃淡画像に基づいて輪郭画像を生成し、輪郭画像格納部426に格納する。輪郭画像は、公知のエッジ抽出法を利用して生成される。エッジ抽出法は、例えばCanny法である。モデルフィッティング部428は、CADモデル格納部427に格納された対象物のモデルを距離画像と輪郭画像とにフィッティングする公知の方法によって対象物の位置姿勢を求める。すなわち、モデルが仮の位置姿勢にあるときの距離画像および輪郭画像をシミュレーションによって生成し、このシミュレーションで生成した画像と、撮像画像から生成した画像との差異を計算する。そして、仮の位置姿勢を変化させて、当該差異が最も小さくなる位置姿勢を探索する。撮像画像から生成した画像とは、距離画像格納部424に格納された距離画像と、輪郭画像格納部426に格納された輪郭画像である。   The contour image generation unit 425 generates a contour image based on the grayscale image obtained by the second imaging unit 432 and stored in the grayscale image storage unit 422, and stores the contour image in the contour image storage unit 426. The contour image is generated by using a known edge extraction method. The edge extraction method is, for example, the Canny method. The model fitting unit 428 obtains the position and orientation of the object by a known method of fitting the model of the object stored in the CAD model storage unit 427 to the range image and the contour image. That is, the distance image and the contour image when the model is in the temporary position and orientation are generated by simulation, and the difference between the image generated by this simulation and the image generated from the captured image is calculated. Then, the temporary position and orientation are changed to search for the position and orientation in which the difference is the smallest. The images generated from the captured image are the distance image stored in the distance image storage unit 424 and the contour image stored in the contour image storage unit 426.

計測装置での計測方法
次に、上述した計測装置(撮像装置104、計測処理装置105)による対象物(ワーク106)の位置姿勢の計測方法について説明する。図5は、本実施形態の計測装置による計測方法を示すフローチャートである。本実施形態の計測装置は、次の手順で対象物の位置姿勢を計測する。
Measuring Method by Measuring Device Next , a measuring method of the position and orientation of the object (workpiece 106) by the above-described measuring device (imaging device 104, measurement processing device 105) will be described. FIG. 5 is a flowchart showing a measuring method by the measuring device of this embodiment. The measuring device according to the present embodiment measures the position and orientation of an object according to the following procedure.

ステップS501では、各撮像部において、基準光強度の照明光源で照明したときの光量が目標光量となる基準露光時間を取得する。各撮像部の基準光強度は、各撮像部の最大光強度とすることが好ましく、また、各撮像部の基準露光時間の取得は、並行して実施することが好ましい。例えば、ステップS501では、基準露光時間取得部411が、第1撮像部431に予め設定された第1基準露光時間と、第2撮像部432に予め設定された第2基準露光時間とを取得する。ステップS502では、各撮像部の基準露光時間に基づいて、複数の撮像部で共通の露光時間を設定する。例えば、ステップS502では、露光時間設定部414が、第1撮像部431および第2撮像部432に対して共通の露光時間を設定する。また、ステップS503では、ステップS502で設定された共通の露光時間に基づいて、各撮像部の照明光源の光強度を設定する。例えば、ステップS503では、照明光強度設定部416が、第1撮像部431および第2撮像部432の各々について照明光源の目標光強度を個別に決定する。ここまでのステップS501〜S503が、計測装置の校正(キャリブレーション)を行う工程である。   In step S501, the reference exposure time at which the light amount when illuminated by the illumination light source having the reference light intensity is the target light amount is acquired in each imaging unit. The reference light intensity of each image pickup unit is preferably the maximum light intensity of each image pickup unit, and the reference exposure time of each image pickup unit is preferably acquired in parallel. For example, in step S501, the reference exposure time acquisition unit 411 acquires the first reference exposure time preset in the first imaging unit 431 and the second reference exposure time preset in the second imaging unit 432. . In step S502, an exposure time common to a plurality of image pickup units is set based on the reference exposure time of each image pickup unit. For example, in step S502, the exposure time setting unit 414 sets a common exposure time for the first imaging unit 431 and the second imaging unit 432. Further, in step S503, the light intensity of the illumination light source of each imaging unit is set based on the common exposure time set in step S502. For example, in step S503, the illumination light intensity setting unit 416 individually determines the target light intensity of the illumination light source for each of the first imaging unit 431 and the second imaging unit 432. Steps S501 to S503 up to this point are steps for calibrating the measuring device.

ステップS504では、ステップS503で各撮像部の照明光源に設定された光強度で対象物を照明し、ステップS502で設定された共通の露光時間で該対象物を撮像する。例えば、ステップS504では、撮像制御部404が、S502で設定した共通の露光時間と、S503で設定した照明光源の目標光強度とに基づいて、第1撮像部431および第2撮像部432に対象物を撮像させる。このとき、撮像制御部404は、対象物を同時に撮像させるように、第1撮像部431と第2撮像部432とを同期制御する。ステップS505では、位置姿勢計算部420が、第1撮像部431で得られたパターン投影画像と、第2撮像部432で得られた濃淡画像とに基づいて、対象物の位置姿勢を計算する。ステップS506では、RC通信部402が、S505で算出された対象物の位置姿勢をロボット制御装置103に送信する。このとき、入出力部403が、S505で算出された対象物の位置姿勢を出力してもよい。ステップS507では、制御部401が、対象物の位置姿勢の計測を同じ撮像条件で続けるか否かを判断する。計測を引き続き行う場合にはステップS504に戻り、計測を引き続き行わない場合には処理を終了する。   In step S504, the object is illuminated with the light intensity set in the illumination light source of each imaging unit in step S503, and the object is imaged with the common exposure time set in step S502. For example, in step S504, the imaging control unit 404 targets the first imaging unit 431 and the second imaging unit 432 based on the common exposure time set in S502 and the target light intensity of the illumination light source set in S503. Image an object. At this time, the imaging control unit 404 synchronously controls the first imaging unit 431 and the second imaging unit 432 so that the object is imaged at the same time. In step S505, the position / orientation calculation unit 420 calculates the position / orientation of the target object based on the pattern projection image obtained by the first imaging unit 431 and the grayscale image obtained by the second imaging unit 432. In step S506, the RC communication unit 402 transmits the position and orientation of the target object calculated in step S505 to the robot controller 103. At this time, the input / output unit 403 may output the position and orientation of the object calculated in S505. In step S507, the control unit 401 determines whether to continue measuring the position and orientation of the object under the same imaging condition. If the measurement is to be continued, the process returns to step S504, and if the measurement is not to be continued, the process ends.

基準露光時間の設定方法
次に、第1撮像部431および第2撮像部432の各々に対し、基準露光時間(第1基準露光時間、第2基準露光時間)を設定する方法について説明する
図6Aは、基準露光時間の設定方法の一例を示すフローチャートである。本実施形態の計測装置は、対象物の位置姿勢を計測する前(図5のフローチャートを開始する前)に、次の手順で各撮像部の基準露光時間を事前に設定する。なお、図6Aのフローチャートに示す基準露光時間の設定は、計測処理装置105により、第1撮像部431および第2撮像部432の各々に対して個別に行われ、好ましくは、第1撮像部431および第2撮像部432で並行して行われうる。以下では、第1撮像部431および第2撮像部432のうち基準露光時間を設定する対象の撮像部を、単に「撮像部」と呼ぶことがある。
Method of Setting Reference Exposure Time Next, a method of setting the reference exposure time (first reference exposure time, second reference exposure time) for each of the first imaging unit 431 and the second imaging unit 432 will be described. 3 is a flowchart showing an example of a method of setting a reference exposure time. The measuring apparatus of this embodiment sets the reference exposure time of each imaging unit in advance by the following procedure before measuring the position and orientation of the target object (before starting the flowchart of FIG. 5). The setting of the reference exposure time shown in the flowchart of FIG. 6A is individually performed by the measurement processing device 105 for each of the first imaging unit 431 and the second imaging unit 432, and preferably the first imaging unit 431. And it can be performed in parallel in the second imaging unit 432. Hereinafter, the image pickup unit of the first image pickup unit 431 and the second image pickup unit 432 for which the reference exposure time is set may be simply referred to as an “image pickup unit”.

ステップS601では、撮像部における照明光源(第1光、または第2光)の光強度を、該撮像部の基準光強度に設定する。基準光強度は、例えば、上述したように、撮像部の照明光源に設定可能な最大光強度に設定されうる。ステップS602では、撮像部の露光時間Tを初期値T0に設定する。ステップS603では、設定した撮像条件(基準光強度、露光時間T)で撮像部に対象物を撮像させる。このときに用いられる対象物は、図5のフローチャートで位置姿勢を計測する対象物と同じものであることが好ましいが、異なるものであってもよい。ステップS604では、S603で得られた撮像画像から、該撮像画像の明るさを評価する評価値Qeを計算する。評価値Qeは、例えば、画素値の90パーセンタイルとする。90パーセンタイルは、画素値をソートしたときに、全画素数の90%に相当する順位の画素値である。全画素数が100画素であれば、90番目の画素値を示す。90パーセンタイルによれば、画像の明るさを画素値の平均値で評価する場合と比べて、画素値分布の明るい側をより正確に制御することができる。   In step S601, the light intensity of the illumination light source (first light or second light) in the imaging unit is set to the reference light intensity of the imaging unit. The reference light intensity can be set to, for example, the maximum light intensity that can be set for the illumination light source of the imaging unit, as described above. In step S602, the exposure time T of the imaging unit is set to the initial value T0. In step S603, the image capturing unit captures an image of the object under the set image capturing conditions (reference light intensity, exposure time T). The target used at this time is preferably the same as the target whose position and orientation are measured in the flowchart of FIG. 5, but may be different. In step S604, an evaluation value Qe that evaluates the brightness of the captured image is calculated from the captured image obtained in step S603. The evaluation value Qe is, for example, the 90th percentile of the pixel value. The 90th percentile is a pixel value in a rank corresponding to 90% of the total number of pixels when the pixel values are sorted. If the total number of pixels is 100, the 90th pixel value is indicated. According to the 90th percentile, the bright side of the pixel value distribution can be controlled more accurately than in the case where the brightness of the image is evaluated by the average value of the pixel values.

ステップS605では、撮像画像から計算した評価値Qeと目標評価値Qtとを比較する。両者の差が所定の閾値Δ以下であればステップS608に進む。一方、当該差が所定の閾値Δより大きい場合において、Qeが(Qt−Δ)よりも小さければステップS606に進み、Qeが(Qt+Δ)よりも大きければステップS607に進む。なお、目標評価値Qtは、撮像画像が目標明るさになる目標光量が得られるときの評価値である。また、目標明るさは、例えば、位置姿勢を所定の精度で得るために必要な最低の明るさ以上に設定されるとよく、撮像部ごとに異なる値に設定されてもよい。ステップS606では、露光時間Tに所定の時間ΔTを加えてステップS603に戻る。ステップS607では、露光時間Tに所定の時間ΔTを減じてステップS603に戻る。時間ΔTは、評価値Qeと目標評価値Qtとの差に応じて任意に設定することができる。ステップS608では、評価値Qeと目標評価値Qtとの差が閾値Δ以下となったときの露光時間を、基準露光時間として設定し、処理を終了する。   In step S605, the evaluation value Qe calculated from the captured image is compared with the target evaluation value Qt. If the difference between the two is less than or equal to the predetermined threshold Δ, the process proceeds to step S608. On the other hand, when the difference is larger than the predetermined threshold Δ, if Qe is smaller than (Qt−Δ), the process proceeds to step S606, and if Qe is larger than (Qt + Δ), the process proceeds to step S607. It should be noted that the target evaluation value Qt is an evaluation value when the target light amount that brings the captured image to the target brightness is obtained. Further, the target brightness may be set to, for example, the minimum brightness required to obtain the position and orientation with a predetermined accuracy or higher, and may be set to a different value for each imaging unit. In step S606, a predetermined time ΔT is added to the exposure time T, and the process returns to step S603. In step S607, the exposure time T is reduced by a predetermined time ΔT, and the process returns to step S603. The time ΔT can be arbitrarily set according to the difference between the evaluation value Qe and the target evaluation value Qt. In step S608, the exposure time when the difference between the evaluation value Qe and the target evaluation value Qt becomes equal to or less than the threshold value Δ is set as the reference exposure time, and the process ends.

また、図6Bは、基準露光時間の設定方法の他の一例を示すフローチャートである。前述した図6Aでは、各撮像部に対して基準露光時間の設定を個別に行う方法について説明したが、図6Bでは、複数の撮像部(第1撮像部431、第2撮像部432)に対して基準露光時間の設定を並行して行う方法について説明する。   FIG. 6B is a flowchart showing another example of the method of setting the reference exposure time. Although the method of individually setting the reference exposure time for each image capturing unit has been described with reference to FIG. 6A described above, in FIG. 6B, a plurality of image capturing units (first image capturing unit 431 and second image capturing unit 432) are used. A method of setting the reference exposure time in parallel will be described.

ステップS611では、第i撮像部における照明光源の光強度を、該第i撮像部の基準光強度Sに設定する。「i」は、撮像部の番号を示しており、本実施形態では「1」および「2」に設定される。即ち、本実施形態では、第1撮像部431における照明光源の光強度を該第1撮像部431の基準光強度Sに設定するとともに、第2撮像部432における照明光源の光強度を該第2撮像部432の基準光強度Sに設定する。ステップS612では、第i撮像部の露光時間Tを初期値T0に設定する。即ち、本実施形態では、第1撮像部431の露光時間Tを初期値T0に設定するとともに、第2撮像部432の露光時間Tを初期値T0に設定する。ステップS613では、設定した撮像条件(基準光強度、露光時間)で、各撮像部に対象物を同時に撮像させる。ステップS614では、ステップS613において各撮像部で得られた撮像画像から、該撮像画像の明るさを評価する評価値Qeを算出する。本実施形態では、第1撮像部431で得られた撮像画像から評価値Qeを計算するとともに、第2撮像部432で得られた撮像画像から評価値Qeを算出する。 In step S611, the light intensity of the illumination light source in the i-th imaging unit is set to the reference light intensity S i of the i-th imaging unit. “I” indicates the number of the imaging unit, and is set to “1” and “2” in this embodiment. That is, in the present embodiment, the light intensity of the illumination light source in the first image pickup unit 431 is set to the reference light intensity S 1 of the first image pickup unit 431, and the light intensity of the illumination light source in the second image pickup unit 432 is set to the reference light intensity S 1 . 2 The reference light intensity S 2 of the imaging unit 432 is set. In step S612, the exposure time T i of the i-th imaging unit is set to the initial value T0 i . That is, in the present embodiment, the exposure time T 1 of the first imaging unit 431 is set to the initial value T0 1, and the exposure time T 2 of the second imaging unit 432 is set to the initial value T0 2 . In step S <b> 613, the respective image capturing units simultaneously capture the object under the set image capturing conditions (reference light intensity and exposure time). In step S614, an evaluation value Qe i for evaluating the brightness of the captured image is calculated from the captured image obtained by each imaging unit in step S613. In the present embodiment, the evaluation value Qe 1 is calculated from the captured image obtained by the first imaging unit 431, and the evaluation value Qe 2 is calculated from the captured image obtained by the second imaging unit 432.

ステップS615では、各撮像部について、撮像画像から算出された評価値Qeと目標評価値Qtとを比較する。「Δ」を所定の許容閾値とするとき、評価値Qeと目標評価値Qtとの関係が(Qe<Qt−Δ)となる場合にはステップS616に進む。ステップS616では、露光時間Tに所定の時間ΔTを加えてステップS613に戻る。一方、評価値Qeと目標評価値Qtとの関係が(Qe>Qt+Δ)となる場合にはステップS617に進む。ステップS617では、露光時間Tに所定の時間ΔTを減じてステップS603に戻る。また、評価値Qeと目標評価値Qtとの差が(|Qe−Qt|≦Δ)の条件を満たす場合にはステップS618に進む。 In step S615, the evaluation value Qe i calculated from the captured image and the target evaluation value Qt i are compared for each imaging unit. When “Δ” is a predetermined allowable threshold value and the relationship between the evaluation value Qe i and the target evaluation value Qt i is (Qe i <Qt i −Δ), the process proceeds to step S616. In step S616, a predetermined time ΔT is added to the exposure time T i, and the process returns to step S613. On the other hand, when the relationship between the evaluation value Qe i and the target evaluation value Qt i is (Qe i > Qt i + Δ), the process proceeds to step S617. In step S617, the exposure time T is reduced by a predetermined time ΔT, and the process returns to step S603. If the difference between the evaluation value Qe i and the target evaluation value Qt i satisfies the condition of (| Qe i −Qt i | ≦ Δ), the process proceeds to step S618.

ステップS618では、各撮像部において、評価値Qeと目標評価値Qtとの差が(|Qe−Qt|≦Δ)の条件を満たすか否かを判定する。即ち、本実施形態では、第1撮像部431において(|Qe−Qt|≦Δ)の条件を満たし、且つ、第2撮像部432において(|Qe−Qt|≦Δ)の条件を満たすか否かを判定する。上記条件を共に満たす場合にはステップS619に進み、上記条件を共に満たさない場合には、露光時間Tを変更せずにステップS613に戻る。ステップS619では、評価値Qeiと目標評価値Qtiとの差が許容閾値Δ以下となったときの露光時間Tiを、基準露光時間として設定し、処理を終了する。 In step S618, each imaging unit determines whether or not the difference between the evaluation value Qe i and the target evaluation value Qt i satisfies the condition of (| Qe i −Qt i | ≦ Δ). That is, in the present embodiment, the condition of (| Qe 1 −Qt 1 | ≦ Δ) is satisfied in the first imaging unit 431, and the condition of (| Qe 2 −Qt 2 | ≦ Δ) is satisfied in the second imaging unit 432. It is determined whether or not the condition is satisfied. If both of the above conditions are satisfied, the process proceeds to step S619, and if both of the conditions are not satisfied, the process returns to step S613 without changing the exposure time T i . In step S619, the exposure time Ti when the difference between the evaluation value Qei and the target evaluation value Qti becomes less than or equal to the allowable threshold value Δ is set as the reference exposure time, and the process ends.

以上説明したように、本実施形態の計測装置は、複数の撮像部で共通の露光時間を設定する露光時間設定部414と、設定された共通の露光時間に基づいて、各撮像部の照明光源の光強度を設定する照明光強度設定部416とを備える。この構成によれば、各撮像部で適切な明るさの画像を得ることと、撮像部間の露光時間の差を小さくすることとを両立することができる。その結果、計測装置(撮像装置104)を対象物に対して相対的に移動させている状態においても、複数の撮像部間における撮像画像の像ぶれ(ボケ)の差を抑制し、対象物の位置姿勢を精度よく計測することができる。   As described above, the measuring apparatus of the present embodiment is configured such that the exposure time setting unit 414 that sets a common exposure time for a plurality of image capturing units and the illumination light source of each image capturing unit based on the set common exposure time. And an illumination light intensity setting unit 416 for setting the light intensity. With this configuration, it is possible to achieve both obtaining an image with appropriate brightness in each image capturing unit and reducing the difference in exposure time between the image capturing units. As a result, even when the measuring device (imaging device 104) is relatively moved with respect to the target object, a difference in image blur (blur) of the captured images between the plurality of imaging units is suppressed, and the target object is suppressed. Position and orientation can be measured accurately.

また、本実施形態の計測装置は、照明光源の光強度を基準光強度に設定した条件下において目標光量が得られる最短の露光時間である基準露光時間を撮像部ごとに取得し、この基準露光時間に基づいて、複数の撮像部に対する共通の露光時間を設定する。この構成によれば、複数の撮像部間における撮像画像の像ぶれ(ボケ)の差を抑制することができるとともに、各撮像部で得られる撮像画像が目標明るさとなる範囲内で露光時間を最短化することができる。また、本実施形態の計測装置は、基準撮像部の基準露光時間と各撮像部の基準露光時間との比率に基づいて、露光時間を共通化したときの各撮像部における照明光源の光量を決定する。この構成によれば、露光時間を共通化したときに目標光量が得られる照明光源の目標光強度を、各撮像部について再探索する必要がなくなるため、目標光強度の設定処理を迅速に行うことができる。さらに、本実施形態の計測装置では、複数の撮像部において互いに波長の異なる照明光源が用いられる。この構成によれば、複数の撮像部で同じ対象物(すなわち、同じ領域)の位置姿勢を計測する場合においても、各撮像部の撮像センサで得られる光量を各々の照明光源の光強度によって制御することができる。   Further, the measuring apparatus of the present embodiment acquires a reference exposure time, which is the shortest exposure time for obtaining the target light amount under the condition where the light intensity of the illumination light source is set to the reference light intensity, for each image capturing unit, and the reference exposure time is obtained. A common exposure time is set for a plurality of image pickup units based on the time. With this configuration, it is possible to suppress the difference in image blurring (blur) of the captured images between the plurality of imaging units, and minimize the exposure time within the range in which the captured images obtained by the respective imaging units have the target brightness. Can be converted. Further, the measurement apparatus of the present embodiment determines the light amount of the illumination light source in each image capturing unit when the exposure time is shared, based on the ratio of the reference exposure time of the reference image capturing unit and the reference exposure time of each image capturing unit. To do. According to this configuration, it is not necessary to re-search for the target light intensity of the illumination light source that obtains the target light amount when the exposure time is shared, so that the setting process of the target light intensity can be performed quickly. You can Further, in the measuring device of the present embodiment, illumination light sources having different wavelengths are used in the plurality of image capturing units. According to this configuration, even when the positions and orientations of the same object (that is, the same region) are measured by the plurality of image capturing units, the amount of light obtained by the image capturing sensor of each image capturing unit is controlled by the light intensity of each illumination light source. can do.

[変形例]
第1実施形態では、照明光源の光強度を基準光強度として各撮像部に予め設定された基準露光時間に基づいて、複数の撮像部で共通の露光時間を設定し、各撮像部における照明光源の目標光強度を個別に設定する構成について説明した。本変形例では、目標光量を得ることができる照明光源の光強度と露光時間との対応関係を示す情報を各撮像部について取得し、当該情報に基づいて、共通の露光時間と各照明光源の目標光強度とを設定する構成について説明する。例えば、本変形例では、離散的な複数の露光時間の各々について、目標光量を得ることができる照明光源の光強度を各撮像部について取得し、この露光時間と光強度との対応関係を示す情報に基づいて、共通の露光時間と各照明光源の目標光強度とが設定される。なお、上記の実施形態と同じ構成については同じ番号を付与し、説明を省略する。また、以下では、目標光量を得ることができる照明光源の光強度と露光時間との対応関係を示す情報を、「撮像情報」と呼ぶことがある。
[Modification]
In the first embodiment, an exposure time common to a plurality of image pickup units is set based on a reference exposure time preset in each image pickup unit with the light intensity of the illumination light source as the reference light intensity, and the illumination light source in each image pickup unit is set. The configuration for individually setting the target light intensities has been described. In this modification, the information indicating the correspondence between the light intensity of the illumination light source that can obtain the target light amount and the exposure time is obtained for each imaging unit, and based on the information, the common exposure time and the illumination light of each illumination light source are acquired. A configuration for setting the target light intensity will be described. For example, in the present modification, for each of a plurality of discrete exposure times, the light intensity of the illumination light source that can obtain the target light amount is acquired for each imaging unit, and the correspondence relationship between the exposure time and the light intensity is shown. The common exposure time and the target light intensity of each illumination light source are set based on the information. It should be noted that the same numbers are given to the same configurations as those of the above-described embodiment, and the description thereof will be omitted. In the following, information indicating the correspondence relationship between the light intensity of the illumination light source that can obtain the target light amount and the exposure time may be referred to as “imaging information”.

計測処理装置の構成例
図7は、本変形例に係る計測処理装置105の機能構成を示すブロック図である。本変形例に係る計測処理装置105は、各撮像部から撮像情報を取得する撮像情報取得部701を備える。例えば、撮像情報取得部701は、第1撮像部431から第1撮像情報を取得して第1撮像情報格納部702に格納するとともに、第2撮像部432から第2撮像情報を取得して第2撮像情報格納部703に格納する。ここで、第1撮像情報は、第1撮像部431で目標光量(第1目標光量)を得ることができる照明光源204(第1光)の光強度と露光時間との対応関係を示す情報である。また、第2撮像情報は、第2撮像部432で目標光量(第2目標光量)を得ることができる照明光源202(第2光)の光強度と露光時間との対応関係を示す情報である。
Configuration Example of Measurement Processing Device FIG. 7 is a block diagram showing the functional configuration of the measurement processing device 105 according to the present modification. The measurement processing device 105 according to this modification includes an imaging information acquisition unit 701 that acquires imaging information from each imaging unit. For example, the imaging information acquisition unit 701 acquires the first imaging information from the first imaging unit 431 and stores the first imaging information in the first imaging information storage unit 702, and the second imaging information from the second imaging unit 432 to acquire the first imaging information. 2 stored in the imaging information storage unit 703. Here, the first imaging information is information indicating the correspondence relationship between the light intensity of the illumination light source 204 (first light) and the exposure time with which the first imaging unit 431 can obtain the target light amount (first target light amount). is there. Further, the second image pickup information is information indicating a correspondence relationship between the light intensity of the illumination light source 202 (second light) and the exposure time with which the second image pickup unit 432 can obtain the target light amount (second target light amount). .

図8は、撮像情報の一例を示す模式図であり、図8(a)は、第1撮像部431から取得される第1撮像情報を示し、図8(b)は、第2撮像部から取得される第2撮像情報を示す。図8に示す撮像情報は、離散的な複数の露光時間の各々について、目標光量が得られる照明光源の光強度を示すデータテーブルである。撮像情報取得部701は、例えば、データテーブルに示された各露光時間について、照明光源の光強度が互いに異なる複数の状態で撮像をそれぞれ実施し、目標光量が得られる照明光源の光強度を探索することで、撮像情報を取得することができる。図8に示す撮像情報では、照明光源の光強度を調整しても目標光量を得ることができなかった露光時間については、照明光源の光強度を設定不可能であるとして「FALSE」が記述される。   8A and 8B are schematic diagrams showing an example of the image pickup information. FIG. 8A shows the first image pickup information acquired from the first image pickup unit 431, and FIG. 8B shows the second image pickup unit. The 2nd imaging information acquired is shown. The imaging information shown in FIG. 8 is a data table showing the light intensity of the illumination light source that obtains the target light amount for each of a plurality of discrete exposure times. The imaging information acquisition unit 701 performs imaging in a plurality of states in which the light intensity of the illumination light source is different from each other for each exposure time shown in the data table, and searches for the light intensity of the illumination light source that obtains the target light amount. By doing so, the imaging information can be acquired. In the imaging information shown in FIG. 8, “FALSE” is described as the light intensity of the illumination light source cannot be set for the exposure time in which the target light amount could not be obtained even if the light intensity of the illumination light source was adjusted. It

本変形例の露光時間設定部704は、各撮像部の撮像情報(第1撮像情報、第2撮像情報)を参照して、複数の撮像部で共通の露光時間を設定し、露光時間格納部415に格納する。例えば、第1撮像情報において、第1目標光量を得るための照明光源の光強度を実現可能な露光時間の範囲と、第2撮像情報において、第2目標光量を得るための照明光源の光強度を実現可能な露光時間の範囲との重複部分の中から、共通の露光時間を設定する。すなわち、いずれの撮像部の撮像情報においても照明光源の光強度が「FALSE」でない露光時間の範囲内(重複部分)から、共通の露光時間を設定する。好適には、いずれの撮像部の撮像情報においても照明光学系の光強度が「FALSE」でない露光時間の範囲内のうち最小の露光時間を、共通の露光時間として設定する。図8に示す例では、第1撮像情報(図8(a))および第2撮像情報(図8(b))において、どちらも「FALSE」でない最小の露光時間「3.0」が、共通の露光時間として設定される。   The exposure time setting unit 704 of the present modified example refers to the imaging information (first imaging information, second imaging information) of each imaging unit to set the exposure time common to the plurality of imaging units, and the exposure time storage unit 415. For example, in the first imaging information, the range of the exposure time that can realize the light intensity of the illumination light source for obtaining the first target light amount, and in the second imaging information, the light intensity of the illumination light source for obtaining the second target light amount. The common exposure time is set from the overlapping portion with the range of the exposure time that can realize. That is, the common exposure time is set within the range of the exposure time (overlapping portion) where the light intensity of the illumination light source is not “FALSE” in the imaging information of any of the imaging units. Preferably, the minimum exposure time within the range of the exposure time in which the light intensity of the illumination optical system is not “FALSE” in the image pickup information of any of the image pickup units is set as the common exposure time. In the example shown in FIG. 8, the minimum exposure time “3.0” that is not “FALSE” is common in both the first imaging information (FIG. 8A) and the second imaging information (FIG. 8B). Exposure time.

また、本実施形態の照明光強度設定部705は、第1撮像部431および第2撮像部432の各々について、各撮像部の撮像情報を参照して、露光時間設定部704により設定された共通の露光時間に対応する照明光源の光強度を目標光強度として設定する。そして、第1撮像部431および第2撮像部432の各々について設定した目標光強度を、第1光強度格納部417および第2光強度格納部418にそれぞれ格納する。図8に示す例では、共通の露光時間が「3.0」に設定されるため、露光時間設定部704は、第1撮像部431の照明光源の光強度を「99」に設定し、第2撮像部432の照明光源の光強度を「64」に設定する。ここで、撮像制御部404と位置姿勢計算部420は、撮像条件が設定された後、上記の実施形態と同様の処理を行う。すなわち、撮像制御部404は、設定された撮像条件に基づいて撮像装置104を制御して撮像を実施し、位置姿勢計算部420は、各撮像部で得られた撮像画像に基づいて対象物の位置姿勢を計算する。   Further, the illumination light intensity setting unit 705 of the present embodiment refers to the image pickup information of each image pickup unit for each of the first image pickup unit 431 and the second image pickup unit 432, and sets the common value set by the exposure time setting unit 704. The light intensity of the illumination light source corresponding to the exposure time is set as the target light intensity. Then, the target light intensity set for each of the first image pickup unit 431 and the second image pickup unit 432 is stored in the first light intensity storage unit 417 and the second light intensity storage unit 418, respectively. In the example shown in FIG. 8, since the common exposure time is set to “3.0”, the exposure time setting unit 704 sets the light intensity of the illumination light source of the first imaging unit 431 to “99”, 2 The light intensity of the illumination light source of the imaging unit 432 is set to “64”. Here, the imaging control unit 404 and the position / orientation calculation unit 420 perform the same processing as that in the above embodiment after the imaging conditions are set. That is, the image capturing control unit 404 controls the image capturing apparatus 104 based on the set image capturing condition to perform image capturing, and the position / orientation calculating unit 420 causes the target object to be captured based on the image captured by each image capturing unit. Calculate position and orientation.

計測装置での計測方法
次に、本変形例の計測装置による対象物の位置姿勢の計測方法について説明する。図9は、本変形例の計測装置による計測方法を示すフローチャートである。本変形例の計測装置は、次の手順で対象物の位置姿勢を計測する。
Measuring Method by Measuring Device Next , a measuring method of the position and orientation of the object by the measuring device of this modification will be described. FIG. 9 is a flowchart showing a measuring method by the measuring device of this modification. The measuring device according to the present modification measures the position and orientation of the target object in the following procedure.

ステップS901では、撮像情報取得部701が、第1撮像部431および第2撮像部432の各々について撮像情報を取得する。ステップS902では、露光時間設定部704が、第1撮像部431および第2撮像部432に対して共通の露光時間を設定する。ステップS903では、照明光強度設定部705が、第1撮像部431および第2撮像部432の各々について照明光源の目標光強度を個別に決定する。ここまでのステップS901〜S903が、計測装置の校正(キャリブレーション)を行う工程である。また、ステップS904〜S907は、図5に示すフローチャートのS504〜S507と同様の工程であるため、ここでの説明を省略する。   In step S901, the imaging information acquisition unit 701 acquires imaging information for each of the first imaging unit 431 and the second imaging unit 432. In step S902, the exposure time setting unit 704 sets a common exposure time for the first imaging unit 431 and the second imaging unit 432. In step S903, the illumination light intensity setting unit 705 individually determines the target light intensity of the illumination light source for each of the first imaging unit 431 and the second imaging unit 432. The steps S901 to S903 up to this point are steps for calibrating the measuring device. Further, steps S904 to S907 are the same steps as steps S504 to S507 of the flowchart shown in FIG. 5, and thus the description thereof is omitted here.

以上説明したように、本変形例の計測装置は、各撮像部から取得した撮像情報に基づいて、複数の撮像部で共通の露光時間を設定するとともに、各撮像部における照明光源の目標光強度を個別に設定する。この構成においても、第1実施形態と同様に、計測装置(撮像装置104)を対象物に対して相対的に移動させている状態においても、複数の撮像部間における撮像画像の像ぶれ(ボケ)の差を抑制し、対象物の位置姿勢を精度よく計測することができる。   As described above, the measurement device of the present modification sets the exposure time common to a plurality of image capturing units based on the image capturing information acquired from each image capturing unit, and also sets the target light intensity of the illumination light source in each image capturing unit. Are set individually. Also in this configuration, similarly to the first embodiment, even when the measuring device (imaging device 104) is relatively moved with respect to the target object, image blurring (blur) of the captured images among the plurality of imaging units is caused. It is possible to measure the position and orientation of the target object with high accuracy by suppressing the difference in).

<第2実施形態>
本発明に係る第2実施形態について説明する。対象物の位置姿勢を計測する計測装置では、撮像装置104と対象物(ワーク106)との距離が変化すると、それに応じて、撮像センサでの光量(即ち、撮像画像の明るさ)が変化しうる。したがって、撮像装置104と対象物との距離が変化したとしても撮像センサでの光量を一定に保つため(即ち、適切な明るさの撮像画像を得るため)には、当該距離に応じて撮像条件を変更することが好ましい。そこで、本実施形態では、撮像装置104と対象物との距離に応じて撮像条件を変更する。具体的には、撮像装置104と対象物との距離に応じて、該距離が長くなるにつれて共通露光時間が長くなるように、該共通露光時間を変更し、変更後の共通露光時間に基づいて、各撮像部における照明光源の目標強度を変更する。なお、前述した実施形態と同じ構成については同じ番号を付与し、説明を省略する。
<Second Embodiment>
A second embodiment according to the present invention will be described. In the measuring device that measures the position and orientation of the target object, when the distance between the image capturing device 104 and the target object (workpiece 106) changes, the light amount at the image sensor (that is, the brightness of the captured image) changes accordingly. sell. Therefore, even if the distance between the imaging device 104 and the object changes, in order to keep the amount of light at the imaging sensor constant (that is, in order to obtain a captured image with appropriate brightness), the imaging condition is changed according to the distance. Is preferably changed. Therefore, in the present embodiment, the imaging condition is changed according to the distance between the imaging device 104 and the object. Specifically, the common exposure time is changed according to the distance between the imaging device 104 and the object so that the common exposure time becomes longer as the distance becomes longer, and the common exposure time is changed based on the changed common exposure time. , The target intensity of the illumination light source in each imaging unit is changed. It should be noted that the same numbers are given to the same configurations as the above-described embodiment, and the description thereof will be omitted.

計測処理装置の構成例
図10は、本実施形態に係る計測処理装置105の機能構成を示すブロック図である。本実施形態に係る計測処理装置105は、計測距離取得部1001と、撮像条件設定部1010と、撮像条件補正部1020と、撮像制御部1404とを備える。
Configuration Example of Measurement Processing Device FIG. 10 is a block diagram showing a functional configuration of the measurement processing device 105 according to the present embodiment. The measurement processing device 105 according to this embodiment includes a measurement distance acquisition unit 1001, an imaging condition setting unit 1010, an imaging condition correction unit 1020, and an imaging control unit 1404.

計測距離取得部1001は、撮像条件設定部1010の指示により、基準露光時間を設定したときの撮像装置104と対象物(ワーク106)との距離L0を取得し、設定時距離格納部1011に格納する。距離L0は、例えば、撮像装置104(第1撮像部431、第2撮像部432)により、基準露光時間および基準光強度で対象物の位置姿勢(3次元位置)を計測した結果から取得されうる。   The measurement distance acquisition unit 1001 acquires the distance L0 between the imaging device 104 and the target object (workpiece 106) when the reference exposure time is set according to an instruction from the imaging condition setting unit 1010, and stores it in the setting distance storage unit 1011. To do. The distance L0 can be obtained from, for example, the result of measuring the position and orientation (three-dimensional position) of the object by the reference exposure time and the reference light intensity by the imaging device 104 (first imaging unit 431, second imaging unit 432). .

また、計測距離取得部1001は、撮像条件補正部1020の指示により、撮像装置104により対象物を撮像する際の撮像装置104と対象物との距離の推定値L1を取得して、計測時距離格納部1021に格納する。例えば、バラ積みされたワーク106の取り出しにおいて、ワーク106を撮像する際の撮像装置104の位置(撮像位置)が常に同じである場合、ワークの取り出しに応じて、撮像装置104と対象物としてのワーク106との距離が徐々に長くなっていく。よって、計測距離取得部1001は、直前に得られた撮像画像から求められる撮像装置104とワーク106との距離に、ワークを1つ取り出したことによる距離の増加分(例えば、ワークの厚さ分)を加えた値を、距離の推定値L1として取得することができる。ここで、計測距離取得部1001は、例えば、ワークを1つ取り出したことによる距離の増加分が小さい場合には、直前に得られた撮像画像から求められる撮像装置104とワーク106との距離自体を、距離の推定値L1として取得してもよい。また、直前の撮像と次回の撮像とで撮像装置104の位置が異なる場合には、例えば、直前の撮像で得られたワークの位置と、次回の撮像における計測装置の位置とから計算される両者の距離を、距離の推定値L1としてもよい。   In addition, the measurement distance acquisition unit 1001 acquires an estimated value L1 of the distance between the imaging device 104 and the object when the imaging device 104 images the object according to an instruction from the imaging condition correction unit 1020, and measures the measured distance. It is stored in the storage unit 1021. For example, when the workpieces 106 piled up in bulk are taken out and the position of the image pickup device 104 (image pickup position) at the time of picking up the images of the works 106 is always the same, the image pickup device 104 and the object as an object are picked up depending on the taking out of the works. The distance from the work 106 gradually increases. Therefore, the measurement distance acquisition unit 1001 increases the distance (for example, the thickness of the work) due to the removal of one work from the distance between the imaging device 104 and the work 106 obtained from the captured image obtained immediately before. ) Can be obtained as the estimated value L1 of the distance. Here, for example, when the increment of the distance due to the removal of one work is small, the measurement distance acquisition unit 1001 itself calculates the distance between the imaging device 104 and the work 106 obtained from the captured image obtained immediately before. May be acquired as the estimated value L1 of the distance. Further, when the position of the image pickup device 104 is different between the immediately previous image pickup and the next image pickup, for example, both calculated from the position of the work obtained in the immediately previous image pickup and the position of the measuring device in the next image pickup. The distance may be the estimated value L1 of the distance.

撮像条件設定部1010は、制御部401の指示により、対象物の位置姿勢の計測に先立って、撮像条件に関する情報として、各撮像部の基準露光時間と設定時距離L0とを設定する。時間のかかる基準露光時間の取得を予め実施しておくことで、対象物の位置姿勢の計測時には補正処理のみを短時間に行って、最終的な撮像条件を設定することができる。基準露光時間は、第1実施形態と同様に設定される。すなわち、第1撮像部431の第1基準露光時間と第2撮像部432の第2基準露光時間とが、基準露光時間取得部411により取得され、第1基準露光時間格納部412と第2基準露光時間格納部413とにそれぞれ格納される。また、設定時距離L0は、撮像条件設定部1010の指示により、計測距離取得部1001により取得されて、設定時距離格納部1011に格納される。   The image capturing condition setting unit 1010 sets the reference exposure time and the set distance L0 of each image capturing unit as the information regarding the image capturing condition prior to the measurement of the position and orientation of the object according to the instruction of the control unit 401. By previously acquiring the time-consuming reference exposure time, it is possible to set the final imaging condition by performing only the correction process in a short time when measuring the position and orientation of the object. The reference exposure time is set similarly to the first embodiment. That is, the first reference exposure time of the first image pickup unit 431 and the second reference exposure time of the second image pickup unit 432 are acquired by the reference exposure time acquisition unit 411, and the first reference exposure time storage unit 412 and the second reference exposure time are acquired. The exposure time is stored in the exposure time storage unit 413. The set distance L0 is acquired by the measured distance acquisition unit 1001 according to an instruction from the imaging condition setting unit 1010 and stored in the set distance storage unit 1011.

撮像条件補正部1020は、制御部401の指示により、対象物の撮像の度に、撮像装置104と対象物との距離に応じた撮像条件の補正を行い、当該撮像のための撮像条件を確定する。基準露光時間補正部1022は、設定時距離格納部1011に格納された距離L0と、計測時距離格納部1021に格納された距離の推定値L1とに基づいて、撮像条件設定部1010が設定した基準露光時間を補正する。具体的には、距離L0と距離の推定値L1とに基づいて、第1基準露光時間格納部412に格納された第1基準露光時間T1を以下の式(4)で補正し、補正後の第1基準露光時間T1cを第1補正時間格納部1023に格納する。同様に、距離L0と距離の推定値L1とに基づいて、第2基準露光時間格納部413に格納された第2基準露光時間T2を以下の式(5)で補正し、補正後の第2基準露光時間T2cを第2補正時間格納部1024に格納する。このように、基準露光時間補正部1022は、撮像装置104と対象物との距離が長くなるにつれて基準露光時間が長くなるように、距離L0と推定値L1とに基づいて、基準露光時間を補正する。
T1c=T1×(L1/L0) ・・・(4)
T2c=T2×(L1/L0) ・・・(5)
The imaging condition correction unit 1020 corrects the imaging condition according to the distance between the imaging device 104 and the object every time the object is imaged by the instruction of the control unit 401, and determines the imaging condition for the imaging. To do. The reference exposure time correction unit 1022 is set by the imaging condition setting unit 1010 based on the distance L0 stored in the set distance storage unit 1011 and the estimated value L1 of the distance stored in the measurement distance storage unit 1021. Correct the reference exposure time. Specifically, based on the distance L0 and the estimated value L1 of the distance, the first reference exposure time T1 stored in the first reference exposure time storage unit 412 is corrected by the following equation (4), and after the correction, The first reference exposure time T1c is stored in the first correction time storage unit 1023. Similarly, based on the distance L0 and the estimated value L1 of the distance, the second reference exposure time T2 stored in the second reference exposure time storage unit 413 is corrected by the following equation (5), and the corrected second The reference exposure time T2c is stored in the second correction time storage unit 1024. In this way, the reference exposure time correction unit 1022 corrects the reference exposure time based on the distance L0 and the estimated value L1 so that the reference exposure time becomes longer as the distance between the imaging device 104 and the object becomes longer. To do.
T1c = T1 × (L1 / L0) 2 (4)
T2c = T2 × (L1 / L0) 2 (5)

上限処理部1025は、補正後の基準露光時間に上限処理を実施する。すなわち、補正後の第1基準露光時間T1cが、撮像装置104に予め設定された露光時間の許容範囲における上限露光時間を超える場合には、補正後の第1基準露光時間T1cを上限露光時間に置き換えて第1補正時間格納部1023に格納する。同様に、補正後の第2基準露光時間T2cが上限露光時間を超える場合には、補正後の第2基準露光時間T2cを上限露光時間に置き換えて第2補正時間格納部1024に格納する。   The upper limit processing unit 1025 performs the upper limit processing on the corrected reference exposure time. That is, when the corrected first reference exposure time T1c exceeds the upper limit exposure time within the allowable exposure time range set in advance in the imaging device 104, the corrected first reference exposure time T1c is set as the upper limit exposure time. It is replaced and stored in the first correction time storage unit 1023. Similarly, when the corrected second reference exposure time T2c exceeds the upper limit exposure time, the corrected second reference exposure time T2c is replaced with the upper limit exposure time and stored in the second correction time storage unit 1024.

露光時間設定部1026は、複数の撮像部に対して共通の露光時間を設定し、設定した露光時間を露光時間格納部415に格納する。例えば、露光時間設定部1026は、複数の撮像部のうち上限処理後の基準露光時間が最も長い撮像部を基準撮像部とし、基準撮像部の補正後の基準露光時間(または上限露光時間)を、該共通の露光時間として設定する。第1実施形態の露光時間設定部414との違いは、露光時間設定部414が基準露光時間に基づいて共通の露光時間を設定するのに対し、本実施形態の露光時間設定部1026は、補正後の基準露光時間に基づいて共通の露光時間を設定することである。   The exposure time setting unit 1026 sets a common exposure time for a plurality of image capturing units, and stores the set exposure time in the exposure time storage unit 415. For example, the exposure time setting unit 1026 sets the image pickup unit having the longest reference exposure time after the upper limit processing among the plurality of image pickup units as the reference image pickup unit, and sets the corrected reference exposure time (or the upper limit exposure time) of the reference image pickup unit. , The common exposure time is set. The difference from the exposure time setting unit 414 of the first embodiment is that the exposure time setting unit 414 sets a common exposure time based on the reference exposure time, whereas the exposure time setting unit 1026 of the present embodiment is The common exposure time is set based on the subsequent reference exposure time.

照明光強度設定部1027は、第1撮像部431および第2撮像部432の各々について照明光源の目標光強度を個別に設定し、第1光強度格納部417と第2光強度格納部418にそれぞれ格納する。照明光源の目標光強度は、以下の式(6)によって算出される。第1実施形態の照明光強度設定部416との違いは、照明光強度設定部416が基準露光時間に基づいて照明光源の目標光強度を設定するのに対し、照明光強度設定部1027は、補正後の基準露光時間に基づいて照明光源の目標光強度を設定することである。また、本実施形態に係る撮像制御部1404は、撮像条件補正部1020で設定した撮像条件に基づいて撮像装置104を制御して撮像を実施し、位置姿勢計算部420は、各撮像部で得られた撮像画像に基づいて対象物の位置姿勢を計算する。その処理内容は第1実施形態と同じであるため、説明を省略する。   The illumination light intensity setting unit 1027 individually sets the target light intensity of the illumination light source for each of the first imaging unit 431 and the second imaging unit 432, and sets them in the first light intensity storage unit 417 and the second light intensity storage unit 418. Store each. The target light intensity of the illumination light source is calculated by the following equation (6). The difference from the illumination light intensity setting unit 416 of the first embodiment is that the illumination light intensity setting unit 416 sets the target light intensity of the illumination light source based on the reference exposure time, whereas the illumination light intensity setting unit 1027 is That is, the target light intensity of the illumination light source is set based on the corrected reference exposure time. Further, the imaging control unit 1404 according to the present embodiment controls the imaging device 104 based on the imaging conditions set by the imaging condition correction unit 1020 to perform imaging, and the position and orientation calculation unit 420 obtains in each imaging unit. The position and orientation of the target object is calculated based on the captured image. Since the processing content is the same as that of the first embodiment, the description is omitted.

Figure 2020064034
Figure 2020064034

計測装置での計測方法
次に、本実施形態の計測装置による対象物の位置姿勢の計測方法について説明する。図11は、本実施形態の計測装置による計測方法を示すフローチャートである。本実施形態に係る計測装置は、次の手順で対象物の位置姿勢を計測する。
Measuring Method by Measuring Device Next , a measuring method of the position and orientation of the object by the measuring device of the present embodiment will be described. FIG. 11 is a flowchart showing a measuring method by the measuring device of this embodiment. The measuring device according to the present embodiment measures the position and orientation of an object according to the following procedure.

ステップS1101では、基準露光時間取得部411が、第1撮像部431に予め設定された第1基準露光時間と、第2撮像部432に予め設定された第2基準露光時間とを取得する。ステップS1102では、計測距離取得部1001が、基準露光時間を設定したときの撮像装置104と対象物との距離L0を取得する。ステップS1103では、計測距離取得部1001が、これから撮像装置104により対象物を撮像する際の撮像装置104と対象物との距離の推定値L1を取得する。ステップS1104では、基準露光時間補正部1022が、S1102で取得した距離L0と、S1103で取得した距離の推定値L1とに基づいて、第1基準露光時間および第2基準露光時間をそれぞれ補正する。   In step S1101, the reference exposure time acquisition unit 411 acquires the first reference exposure time preset in the first imaging unit 431 and the second reference exposure time preset in the second imaging unit 432. In step S1102, the measurement distance acquisition unit 1001 acquires the distance L0 between the imaging device 104 and the object when the reference exposure time is set. In step S1103, the measurement distance acquisition unit 1001 acquires an estimated value L1 of the distance between the imaging device 104 and the object when the imaging device 104 images the object. In step S1104, the reference exposure time correction unit 1022 corrects the first reference exposure time and the second reference exposure time based on the distance L0 acquired in S1102 and the estimated value L1 of the distance acquired in S1103.

ステップS1105では、上限処理部1025が、補正後の基準露光時間に対して上限処理を行う。ステップS1106では、露光時間設定部1026が、第1撮像部431および第2撮像部432に対して共通の露光時間を設定する。ステップS1107では、照明光強度設定部1027が、第1撮像部431および第2撮像部432の各々について照明光源の目標光強度を個別に決定する。ここまでのステップS1101〜S1107が、計測装置の校正(キャリブレーション)を行う工程である。また、ステップS1108〜S1111は、図5に示すフローチャートのS504〜S507と同様の工程であるため、ここでの説明を省略する。   In step S1105, the upper limit processing unit 1025 performs the upper limit processing on the corrected reference exposure time. In step S1106, the exposure time setting unit 1026 sets a common exposure time for the first imaging unit 431 and the second imaging unit 432. In step S1107, the illumination light intensity setting unit 1027 individually determines the target light intensity of the illumination light source for each of the first imaging unit 431 and the second imaging unit 432. Steps S1101 to S1107 up to this point are steps for calibrating the measuring device. Further, steps S1108 to S1111 are the same steps as steps S504 to S507 of the flowchart shown in FIG. 5, and thus the description thereof is omitted here.

以上説明したように、本実施形態の計測装置は、撮像装置104と対象物との距離に応じて、基準露光時間を補正することにより、共通の露光時間および照明光源の光強度を変更する。具体的には、基準露光時間を設定したときの撮像装置104と対象物との距離L0と、これから撮像装置104により対象物を撮像する際の撮像装置104と対象物との距離の推定値L1とを取得する。そして、距離L0と推定値L1とに基づいて基準露光時間を補正し、補正後の基準露光時間に基づいて、複数の撮像部に対して共通の露光時間を設定する。また、設定された共通の露光時間に基づいて、各撮像部の照明光源の目標光強度を設定して調整する。この構成によれば、撮像装置104と対象物との距離が変化しても、撮像センサでの目標光量が一定になるように共通の露光時間と照明光源の光強度とを短時間に設定することができ、対象物の位置精度を精度よく計測することができる。   As described above, the measuring device according to the present embodiment changes the common exposure time and the light intensity of the illumination light source by correcting the reference exposure time according to the distance between the imaging device 104 and the object. Specifically, the distance L0 between the imaging device 104 and the object when the reference exposure time is set, and the estimated value L1 of the distance between the imaging device 104 and the object when the imaging device 104 images the object. And get. Then, the reference exposure time is corrected based on the distance L0 and the estimated value L1, and the common exposure time is set for the plurality of imaging units based on the corrected reference exposure time. Further, the target light intensity of the illumination light source of each imaging unit is set and adjusted based on the set common exposure time. According to this configuration, the common exposure time and the light intensity of the illumination light source are set to a short time so that the target light amount at the image sensor becomes constant even if the distance between the image pickup device 104 and the object changes. Therefore, the positional accuracy of the object can be measured with high accuracy.

[変形例1]
第2実施形態では、撮像装置104と対象物との距離に応じて、基準露光時間を補正することにより、共通の露光時間および照明光源の光強度を変更する構成について説明した。変形例1では、照明光源の光量を固定し(一定とし)、撮像装置104と対象物との距離に応じて、共通の露光時間のみを変更する構成について説明する。なお、上記の実施形態と同じ構成については同じ番号を付与し、説明を省略する。
[Modification 1]
In the second embodiment, the configuration has been described in which the common exposure time and the light intensity of the illumination light source are changed by correcting the reference exposure time according to the distance between the imaging device 104 and the object. In the first modification, a configuration will be described in which the light amount of the illumination light source is fixed (constant) and only the common exposure time is changed according to the distance between the imaging device 104 and the object. It should be noted that the same numbers are given to the same configurations as those of the above-described embodiment, and the description thereof will be omitted.

計測処理装置の構成例
図12は、本変形例に係る計測処理装置105の機能構成を示すブロック図である。本変形例に係る計測処理装置105は、撮像条件設定部1010および撮像条件補正部1020の構成が第2実施形態と異なる。本変形例の撮像条件設定部1010は、前述した基準露光時間補正部1022と、上限処理部1200とを備える。さらに、露光時間設定部1201と、露光時間格納部1202とを備える。
Configuration Example of Measurement Processing Device FIG. 12 is a block diagram showing a functional configuration of the measurement processing device 105 according to the present modification. The measurement processing device 105 according to the present modification is different from the second embodiment in the configurations of the imaging condition setting unit 1010 and the imaging condition correction unit 1020. The imaging condition setting unit 1010 of this modification includes the reference exposure time correction unit 1022 described above and the upper limit processing unit 1200. Furthermore, it comprises an exposure time setting unit 1201 and an exposure time storage unit 1202.

本変形例の基準露光時間補正部1022は、計測装置で計測可能な距離範囲における最短距離Lnに基づいて基準露光時間を補正する。具体的には、設定時距離格納部1011に格納された距離L0と、最短距離Lnとに基づいて、第1基準露光時間格納部412に格納された第1基準露光時間T1を以下の式(7)で補正する。そして、補正後の第1基準露光時間T1nを第1基準露光時間格納部412に格納する。同様に、距離L0と最短距離Lnとに基づいて、第2基準露光時間格納部413に格納された第2基準露光時間T2を以下の式(8)で補正する。そして、補正後の第2基準露光時間T2cを第2基準露光時間格納部413に格納する。さらに、設定時距離格納部1011に最短距離Lnを格納する。
T1n=T1×(Ln/L0) ・・・(7)
T2n=T2×(Ln/L0) ・・・(8)
The reference exposure time correction unit 1022 of the present modification corrects the reference exposure time based on the shortest distance Ln in the distance range measurable by the measuring device. Specifically, based on the distance L0 stored in the set distance storage unit 1011 and the shortest distance Ln, the first reference exposure time T1 stored in the first reference exposure time storage unit 412 is calculated by the following formula ( Correct in 7). Then, the corrected first reference exposure time T1n is stored in the first reference exposure time storage unit 412. Similarly, based on the distance L0 and the shortest distance Ln, the second reference exposure time T2 stored in the second reference exposure time storage unit 413 is corrected by the following equation (8). Then, the corrected second reference exposure time T2c is stored in the second reference exposure time storage unit 413. Furthermore, the shortest distance Ln is stored in the set distance storage unit 1011.
T1n = T1 × (Ln / L0) 2 (7)
T2n = T2 × (Ln / L0) 2 (8)

上限処理部1200は、補正後の基準露光時間に対して上限処理を実施する。すなわち、補正後の第1基準露光時間T1nが、撮像装置104に予め設定された露光時間の許容範囲における上限露光時間を超える場合には、補正後の第1基準露光時間T1nを上限露光時間に置き換えて第1基準露光時間格納部412に格納する。同様に、補正後の第2基準露光時間T1nが上限露光時間を超える場合には、補正後の第2基準露光時間T1nを上限露光時間に置き換えて第2基準露光時間格納部413に格納する。   The upper limit processing unit 1200 performs the upper limit processing on the corrected reference exposure time. That is, if the corrected first reference exposure time T1n exceeds the upper limit exposure time within the allowable range of the exposure time preset in the imaging device 104, the corrected first reference exposure time T1n is set as the upper limit exposure time. It is replaced and stored in the first reference exposure time storage unit 412. Similarly, when the corrected second reference exposure time T1n exceeds the upper limit exposure time, the corrected second reference exposure time T1n is replaced with the upper limit exposure time and stored in the second reference exposure time storage unit 413.

露光時間設定部1201は、複数の撮像部に対して共通の露光時間を設定し、露光時間格納部1202に格納する。例えば、露光時間設定部1201は、複数の撮像部のうち上限処理後の基準露光時間が最も長い撮像部を基準撮像部とし、基準撮像部の補正後の基準露光時間(または上限露光時間)を、共通の露光時間として設定する。例えば、第1撮像部の基準露光時間が第2撮像部の基準露光時間よりも長い場合、第1撮像部を基準撮像部とし、第1撮像部の補正後の基準露光時間を共通の露光時間として設定する。以下では、共通の露光時間を、「共通露光時間」と呼ぶことがある。   The exposure time setting unit 1201 sets a common exposure time for a plurality of imaging units and stores it in the exposure time storage unit 1202. For example, the exposure time setting unit 1201 sets the image pickup unit having the longest reference exposure time after the upper limit processing among the plurality of image pickup units as the reference image pickup unit, and sets the corrected reference exposure time (or the upper limit exposure time) of the reference image pickup unit. , Common exposure time is set. For example, when the reference exposure time of the first image capturing unit is longer than the reference exposure time of the second image capturing unit, the first image capturing unit is set as the reference image capturing unit, and the corrected reference exposure time of the first image capturing unit is set as the common exposure time. Set as. Hereinafter, the common exposure time may be referred to as “common exposure time”.

照明光強度設定部416は、第1撮像部431および第2撮像部432の各々について照明光源の目標光強度を個別に決定し、第1光強度格納部417と第2光強度格納部418にそれぞれ格納する。照明光源の目標光強度は、上述した式(1)によって算出される。ただし、式(1)の基準露光時間には、基準露光時間補正部1022で補正され、上限処理部1200で上限処理された後の基準露光時間が使用される。
本変形例の撮像条件補正部1020は、露光時間格納部1202に格納された共通露光時間を補正する露光時間補正部1203と、補正後の共通露光時間の上限処理を行う上限処理部1204を備える。露光時間補正部1203は、設定時距離格納部1011に格納された最短距離Lnと、計測時距離格納部1021に格納された距離の推定値L1とに基づいて、共通露光時間Tpを以下の式(9)で補正する。そして、補正後の共通露光時間Tpcを露光時間格納部415に格納する。このように、撮像条件補正部1020は、撮像装置104と対象物との距離が長くなるにつれて共通露光時間が長くなるように、最短距離Lnと距離の推定値L1とに基づいて共通露光時間を補正する。
Tpc=Tp×(L1/Ln) ・・・(9)
The illumination light intensity setting unit 416 individually determines the target light intensity of the illumination light source for each of the first imaging unit 431 and the second imaging unit 432, and stores the target light intensity in the first light intensity storage unit 417 and the second light intensity storage unit 418. Store each. The target light intensity of the illumination light source is calculated by the above equation (1). However, as the reference exposure time of the equation (1), the reference exposure time after being corrected by the reference exposure time correction unit 1022 and subjected to the upper limit processing by the upper limit processing unit 1200 is used.
The imaging condition correction unit 1020 of this modification includes an exposure time correction unit 1203 that corrects the common exposure time stored in the exposure time storage unit 1202, and an upper limit processing unit 1204 that performs an upper limit process of the corrected common exposure time. . The exposure time correction unit 1203 calculates the common exposure time Tp based on the shortest distance Ln stored in the set time distance storage unit 1011 and the estimated value L1 of the distance stored in the measurement time distance storage unit 1021 by the following formula. Correct in (9). Then, the corrected common exposure time Tpc is stored in the exposure time storage unit 415. In this way, the imaging condition correction unit 1020 sets the common exposure time based on the shortest distance Ln and the estimated value L1 of the distance so that the common exposure time becomes longer as the distance between the imaging device 104 and the object becomes longer. to correct.
Tpc = Tp × (L1 / Ln) 2 (9)

上限処理部1204は、露光時間格納部415に格納された補正後の共通露光時間Tpcに上限処理を実施する。すなわち、補正後の共通露光時間Tpcが、撮像装置104に予め設定された露光時間の許容範囲における上限露光時間を超える場合には、補正後の共通露光時間Tpcを上限露光時間に置き換えて露光時間格納部415に格納する。ここで、撮像制御部404と位置姿勢計算部420は、撮像条件が設定された後、上記の実施形態と同様の処理を行う。すなわち、撮像制御部404は、設定された撮像条件に基づいて撮像装置104を制御して撮像を実施し、位置姿勢計算部420は、各撮像部で得られた撮像画像に基づいて対象物の位置姿勢を計算する。   The upper limit processing unit 1204 performs the upper limit processing on the corrected common exposure time Tpc stored in the exposure time storage unit 415. That is, when the corrected common exposure time Tpc exceeds the upper limit exposure time in the allowable exposure time range set in advance in the imaging device 104, the corrected common exposure time Tpc is replaced with the upper limit exposure time. It is stored in the storage unit 415. Here, the imaging control unit 404 and the position / orientation calculation unit 420 perform the same processing as that in the above embodiment after the imaging conditions are set. That is, the image capturing control unit 404 controls the image capturing apparatus 104 based on the set image capturing condition to perform image capturing, and the position / orientation calculating unit 420 causes the target object to be captured based on the image captured by each image capturing unit. Calculate position and orientation.

計測装置での計測方法
次に、本変形例の計測装置による対象物の位置姿勢の計測方法について説明する。図13は、本変形例の計測装置による計測方法を示すフローチャートである。本変形例の計測装置は、次の手順で対象物の位置姿勢を計測する。
Measuring Method by Measuring Device Next , a measuring method of the position and orientation of the object by the measuring device of this modification will be described. FIG. 13 is a flowchart showing a measuring method by the measuring device of this modification. The measuring device according to the present modification measures the position and orientation of the target object in the following procedure.

ステップS1301〜S1302は、図9のフローチャートにおけるステップS901〜S902と同様の工程である。ステップS1303では、基準露光時間補正部1022が、計測可能な距離範囲の最短距離Lnに基づいて基準露光時間を補正する。ステップS1304では、最短距離Lnを設定時距離格納部1011に格納する。ステップS1305では、上限処理部1200が、補正後の基準露光時間(第1基準露光時間、第2基準露光時間)の上限処理を行う。ステップS1306では、露光時間設定部1201が、第1撮像部431および第2撮像部432に対して共通の露光時間(共通露光時間)を設定する。ステップS1307では、照明光強度設定部416が、第1撮像部431および第2撮像部432の各々について照明光源の目標光強度を個別に決定する。   Steps S1301 to S1302 are the same steps as steps S901 to S902 in the flowchart of FIG. In step S1303, the reference exposure time correction unit 1022 corrects the reference exposure time based on the shortest distance Ln of the measurable distance range. In step S1304, the shortest distance Ln is stored in the set distance storage unit 1011. In step S1305, the upper limit processing unit 1200 performs the upper limit process of the corrected reference exposure time (first reference exposure time, second reference exposure time). In step S1306, the exposure time setting unit 1201 sets a common exposure time (common exposure time) for the first imaging unit 431 and the second imaging unit 432. In step S1307, the illumination light intensity setting unit 416 individually determines the target light intensity of the illumination light source for each of the first imaging unit 431 and the second imaging unit 432.

引き続いてステップS1308では、計測距離取得部1001が、これから撮像装置104により対象物を撮像する際の撮像装置104と対象物との距離の推定値L1を取得する。ステップS1309では、露光時間補正部1203が、最短距離Lnと距離の推定値L1とに基づいて、S1306で設定された共通露光時間を補正する。ステップS1310では、上限処理部1204が、補正後の共通露光時間に対して上限処理を行う。ここまでのステップS1301〜S1310が、計測装置の校正(キャリブレーション)を行う工程であり、これにより、撮像装置104と対象物との距離に応じた撮像条件の補正が完了し、撮像条件が確定する。また、ステップS1311〜S1314は、図5に示すフローチャートのS504〜S507と同様の工程であるため、ここでの説明を省略する。   Subsequently, in step S1308, the measurement distance acquisition unit 1001 acquires an estimated value L1 of the distance between the imaging device 104 and the object when the imaging device 104 images the object. In step S1309, the exposure time correction unit 1203 corrects the common exposure time set in step S1306 based on the shortest distance Ln and the distance estimated value L1. In step S1310, the upper limit processing unit 1204 performs the upper limit processing on the corrected common exposure time. Steps S1301 to S1310 up to this point are steps for calibrating the measurement device, and as a result, the correction of the imaging condition according to the distance between the imaging device 104 and the object is completed, and the imaging condition is determined. To do. Further, steps S1311 to S1314 are the same steps as steps S504 to S507 in the flowchart shown in FIG. 5, and thus the description thereof is omitted here.

以上説明したように、本変形例に係る計測装置は、対象物の位置姿勢の計測に先立って、複数の撮像部に対して共通の露光時間(共通露光時間)を設定するとともに、各撮像部に対して照明光源の目標光強度を個別に設定する。そして、計測時には、撮像装置104と対象物との距離に応じて共通露光時間のみを補正し、照明光源の目標光強度については補正せず、計測前に設定された目標光強度を使用する。この構成によれば、計測時の処理が削減され、より短時間で対象物の位置姿勢を精度よく計測することができる。   As described above, the measurement apparatus according to the present modification sets the common exposure time (common exposure time) for a plurality of image capturing units before measuring the position and orientation of the target object, and also the image capturing units. With respect to, the target light intensity of the illumination light source is individually set. Then, at the time of measurement, only the common exposure time is corrected according to the distance between the imaging device 104 and the object, the target light intensity of the illumination light source is not corrected, and the target light intensity set before the measurement is used. According to this configuration, the processing at the time of measurement is reduced, and the position and orientation of the object can be accurately measured in a shorter time.

また、本変形例に係る計測装置は、計測可能な距離範囲の最短距離Lnに基づいて補正した基準露光時間に対して上限処理を実施し、補正後の基準露光時間(または上限露光時間)に基づいて、複数の撮像部に対し共通の露光時間(共通露光時間)を設定する。上限処理で基準露光時間が上限露光時間に置き換えられる場合、撮像画像が目標明るさよりも暗くなりうる。そして、計測時における共通露光時間の補正は、共通露光時間を設定したときの撮像画像の明るさを維持するように処理される。すなわち、共通露光時間を最短距離Ln以外で設定した場合、より対象物に近づけば、適切な明るさの撮像画像が得られる場合であっても、暗い画像で撮像することになる。本変形例の構成によれば、撮像装置104と対象物との最短距離Lnに基づいて共通露光時間が設定されるため、暗い画像で撮像されることを抑制できる。その結果、対象物の位置姿勢を精度よく計測することができる。   Further, the measuring apparatus according to the present modification performs the upper limit process on the reference exposure time corrected based on the shortest distance Ln of the measurable distance range, and sets the corrected reference exposure time (or the upper limit exposure time). Based on this, a common exposure time (common exposure time) is set for the plurality of imaging units. When the reference exposure time is replaced by the upper limit exposure time in the upper limit processing, the captured image may be darker than the target brightness. Then, the correction of the common exposure time at the time of measurement is processed so as to maintain the brightness of the captured image when the common exposure time is set. That is, when the common exposure time is set to a value other than the shortest distance Ln, if the object is brought closer to the object, a dark image is captured even if a captured image with appropriate brightness can be obtained. According to the configuration of the present modification, since the common exposure time is set based on the shortest distance Ln between the image pickup device 104 and the object, it is possible to suppress the image pickup in a dark image. As a result, the position and orientation of the object can be accurately measured.

[変形例2]
変形例1では、計測可能な距離範囲の最短距離Lnに基づいて共通露光時間を設定する構成について説明した。変形例2では、計測可能な距離範囲の最長距離に基づいて共通露光時間を設定する構成について説明する。
[Modification 2]
In the first modification, the common exposure time is set based on the shortest distance Ln of the measurable distance range. In the second modification, a configuration in which the common exposure time is set based on the longest distance in the measurable distance range will be described.

本変形例の計測処理装置の機能構成は、上限処理部1204を備えないことと、基準露光時間補正部1022の処理が異なることを除いて、変形例1の計測処理装置105の機能構成(図12)と同じである。本変形例の基準露光時間補正部1022は、計測装置で計測可能な距離範囲における最短距離Lnの代わりに、最長距離Lfに基づいて基準露光時間を補正する。具体的には、設定時距離格納部1011に格納された距離L0と、最長距離Lfとに基づいて、第1基準露光時間格納部412に格納された第1基準露光時間T1を以下の式(10)で補正する。そして、補正後の第1基準露光時間T1fを第1基準露光時間格納部412に格納する。同様に、同様に、距離L0と最長距離Lfとに基づいて、第2基準露光時間格納部413に格納された第2基準露光時間T2を以下の式(11)で補正する。そして、補正後の第2基準露光時間T2fを第2基準露光時間格納部413に格納する。さらに、設定時距離格納部1011に最長距離Lfを格納する。
T1f=T1×(Lf/L0) ・・・(10)
T2f=T2×(Lf/L0) ・・・(11)
The functional configuration of the measurement processing apparatus of this modification is the same as that of the measurement processing apparatus 105 of Modification 1 except that the upper limit processing unit 1204 is not provided and the processing of the reference exposure time correction unit 1022 is different (see FIG. Same as 12). The reference exposure time correction unit 1022 of the present modification corrects the reference exposure time based on the longest distance Lf instead of the shortest distance Ln in the distance range measurable by the measuring device. Specifically, based on the distance L0 stored in the set distance storage unit 1011 and the longest distance Lf, the first reference exposure time T1 stored in the first reference exposure time storage unit 412 is calculated by the following formula ( Correct in 10). Then, the corrected first reference exposure time T1f is stored in the first reference exposure time storage unit 412. Similarly, based on the distance L0 and the longest distance Lf, the second reference exposure time T2 stored in the second reference exposure time storage unit 413 is similarly corrected by the following formula (11). Then, the corrected second reference exposure time T2f is stored in the second reference exposure time storage unit 413. Further, the longest distance Lf is stored in the set distance storage unit 1011.
T1f = T1 × (Lf / L0) 2 (10)
T2f = T2 × (Lf / L0) 2 (11)

また、上限処理部1200は、補正後の基準露光時間に対して上限処理を実施する。そして、露光時間設定部1201は、複数の撮像部に対して共通の露光時間(共通露光時間)を設定する。このように、本変形例の共通露光時間は、計測可能な距離範囲で最も光強度の小さい最長距離Lfに基づいて共通露光時間が設定される。よって、計測時に露光時間補正部1203で実施される共通露光時間の補正において、補正後の共通露光時間は上限を超えることがない。そのため、上限処理部1204は不要となる。本変形例の計測方法は、ステップS1310をスキップすることを除いて、変形例1の計測方法と同じである。以上説明したように、本変形例に係る計測装置は、計測時の上限処理が不要となるため、より短時間で対象物の位置姿勢を精度よく計測することができる。   In addition, the upper limit processing unit 1200 performs the upper limit processing on the corrected reference exposure time. Then, the exposure time setting unit 1201 sets a common exposure time (common exposure time) for the plurality of imaging units. As described above, the common exposure time of this modification is set based on the longest distance Lf having the smallest light intensity in the measurable distance range. Therefore, in the correction of the common exposure time performed by the exposure time correction unit 1203 at the time of measurement, the corrected common exposure time does not exceed the upper limit. Therefore, the upper limit processing unit 1204 becomes unnecessary. The measurement method of this modification is the same as the measurement method of modification 1 except that step S1310 is skipped. As described above, the measuring device according to the present modification does not need the upper limit process at the time of measurement, and thus can accurately measure the position and orientation of the object in a shorter time.

[変形例3]
変形例3では、撮像装置104と対象物との距離に対する共通露光時間および照明光源の目標光強度の対応関係を示す情報を取得し、当該情報に基づいて、共通露光時間を当該距離に応じて変更する構成について説明する。例えば、本変形例では、前述した第2実施形態の構成において、離散的な複数の距離の各々に対応する撮像条件(共通露光時間、目標光強度)を示す情報をデータテーブルとして予め取得しておき、計測時には、このデータテーブルを参照して撮像条件を設定する。なお、前記実施形態と同じ構成については同じ番号を付与し、説明を省略する。また、以下では、撮像装置104と対象物との距離を、単に「距離」と呼ぶことがあり、該距離に対する共通露光時間および照明光源の目標光強度の対応関係を示す情報を、「距離−撮像情報」と呼ぶことがある。
[Modification 3]
In the third modification, information indicating the correspondence relationship between the common exposure time and the target light intensity of the illumination light source with respect to the distance between the imaging device 104 and the object is acquired, and the common exposure time is determined according to the distance based on the information. The configuration to be changed will be described. For example, in this modification, in the configuration of the second embodiment described above, information indicating the imaging conditions (common exposure time, target light intensity) corresponding to each of a plurality of discrete distances is acquired in advance as a data table. Every time, at the time of measurement, the imaging condition is set with reference to this data table. It should be noted that the same components as those in the above-mentioned embodiment are designated by the same reference numerals and the description thereof will be omitted. In the following, the distance between the imaging device 104 and the object may be simply referred to as “distance”, and information indicating the correspondence relationship between the common exposure time and the target light intensity of the illumination light source with respect to the distance may be referred to as “distance- It may be referred to as “imaging information”.

計測処理装置の構成例
図14は、本変形例に係る計測処理装置105の機能構成を示すブロック図である。本変形例に係る計測処理装置105は、撮像情報設定部1401と撮像情報格納部1402とを含む撮像条件設定準備部1410を備える。また、露光時間設定部1403と照明光強度設定部1404とを含む撮像条件設定部1420を備える。
Configuration Example of Measurement Processing Device FIG. 14 is a block diagram showing the functional configuration of the measurement processing device 105 according to the present modification. The measurement processing device 105 according to the present modification includes an imaging condition setting preparation unit 1410 including an imaging information setting unit 1401 and an imaging information storage unit 1402. Further, the imaging condition setting unit 1420 including the exposure time setting unit 1403 and the illumination light intensity setting unit 1404 is provided.

撮像情報設定部1401は、各撮像部の基準露光時間と、基準露光時間を設定したときの撮像装置104と対象物との距離とに基づいて距離−撮像情報を設定し、撮像情報格納部1402に格納する。図15は、本変形例の距離−撮像情報の一例を示す模式図である。本変形例の距離−撮像情報は、離散的な複数の距離に対応した、複数の撮像部における共通の露光時間(共通露光時間)と、各撮像部における照明光源の目標光強度とを示すデータテーブルである。距離−撮像情報の設定方法の詳細は後述する。   The imaging information setting unit 1401 sets the distance-imaging information based on the reference exposure time of each imaging unit and the distance between the imaging device 104 and the object when the reference exposure time is set, and the imaging information storage unit 1402. To store. FIG. 15 is a schematic diagram showing an example of the distance-imaging information of this modification. The distance-imaging information of the present modification is data indicating a common exposure time (common exposure time) in a plurality of image capturing units and a target light intensity of an illumination light source in each image capturing unit corresponding to a plurality of discrete distances. It's a table. Details of the method of setting the distance-imaging information will be described later.

露光時間設定部1403は、撮像情報格納部1402に格納された距離−撮像情報を参照して、公知の補間方法によって、計測時距離格納部1021に格納された計測時距離に対応する共通露光時間を求め、露光時間格納部415に格納する。また、照明光強度設定部1404は、距離−撮像情報を参照して、公知の補間方法で計測距離に対応する各撮像部の照明光源の目標光強度を求め、第1光強度格納部417と第2光強度格納部418とにそれぞれ格納する。ここで、撮像制御部1040と位置姿勢計算部420は、撮像条件が設定された後、上記の実施形態と同様の処理を行う。すなわち、撮像制御部404は、設定された撮像条件に基づいて撮像装置104を制御して撮像を実施し、位置姿勢計算部420は、各撮像部で得られた撮像画像に基づいて対象物の位置姿勢を計算する。   The exposure time setting unit 1403 refers to the distance-imaging information stored in the imaging information storage unit 1402, and the common exposure time corresponding to the measurement time distance stored in the measurement time distance storage unit 1021 by a known interpolation method. Is stored in the exposure time storage unit 415. Further, the illumination light intensity setting unit 1404 refers to the distance-imaging information, obtains the target light intensity of the illumination light source of each imaging unit corresponding to the measured distance by a known interpolation method, and determines the first light intensity storage unit 417. They are stored in the second light intensity storage unit 418 and respectively. Here, the imaging control unit 1040 and the position / orientation calculation unit 420 perform the same processing as that in the above embodiment after the imaging conditions are set. That is, the image capturing control unit 404 controls the image capturing apparatus 104 based on the set image capturing condition to perform image capturing, and the position / orientation calculating unit 420 causes the target object to be captured based on the image captured by each image capturing unit. Calculate position and orientation.

計測装置での計測方法
次に、本変形例の計測装置による対象物の位置姿勢の計測方法について説明する。図16は、本変形例の計測装置による計測方法を示すフローチャートである。本変形例の計測装置は、次の手順で対象物の位置姿勢を計測する。
Measuring Method by Measuring Device Next , a measuring method of the position and orientation of the object by the measuring device of this modification will be described. FIG. 16 is a flowchart showing a measuring method by the measuring device of this modification. The measuring device according to the present modification measures the position and orientation of the target object in the following procedure.

ステップS1601〜S1602は、図11のフローチャートにおけるステップS1101〜S1102と同様の工程である。ステップS1603では、撮像情報設定部1401が、距離−撮像情報を取得して撮像情報格納部1402に格納する。距離−撮像情報の取得方法の詳細は後述する。ステップS1604では、計測距離取得部1001が、これから撮像装置104により対象物を撮像する際の撮像装置104と対象物との距離の推定値L1を取得する。ステップS1605では、露光時間設定部1403が、S1603で設定された距離−撮像情報に基づいて、S1604で取得された距離の推定値L1から、第1撮像部431および第2撮像部432に対して共通露光時間を設定する。ステップS1606では、照明光強度設定部1404が、S1603で設定された距離−撮像情報に基づいて、第1撮像部431および第2撮像部432の各々について照明光源の目標光強度を個別に決定する。ここまでのステップS1601〜S1606が、計測装置の校正(キャリブレーション)を行う工程である。また、ステップS1607〜S1610は、図5に示すフローチャートのS504〜S507と同様の工程であるため、ここでの説明を省略する。   Steps S1601 to S1602 are the same steps as steps S1101 to S1102 in the flowchart of FIG. In step S1603, the imaging information setting unit 1401 acquires the distance-imaging information and stores it in the imaging information storage unit 1402. Details of the method of acquiring the distance-imaging information will be described later. In step S1604, the measurement distance acquisition unit 1001 acquires an estimated value L1 of the distance between the imaging device 104 and the object when the imaging device 104 images the object. In step S1605, the exposure time setting unit 1403 uses the distance-imaging information set in S1603 to estimate the distance L1 acquired in S1604 from the first imaging unit 431 and the second imaging unit 432. Set the common exposure time. In step S1606, the illumination light intensity setting unit 1404 individually determines the target light intensity of the illumination light source for each of the first imaging unit 431 and the second imaging unit 432 based on the distance-imaging information set in S1603. . Steps S1601 to S1606 up to this point are steps for calibrating the measuring device. Further, steps S1607 to S1610 are the same steps as steps S504 to S507 of the flowchart shown in FIG. 5, and thus the description thereof is omitted here.

距離−撮像情報の取得方法
次に、図16のフローチャートにおけるS1603で行われる「距離−撮像情報の取得」について説明する。図17は、距離−撮像情報の取得方法を示すフローチャートである。距離−撮像情報は、撮像情報設定部1401により、次の手順で取得される。
Distance-Imaging Information Acquisition Method Next, "distance-imaging information acquisition" performed in S1603 in the flowchart of FIG. 16 will be described. FIG. 17 is a flowchart showing a method of acquiring distance-imaging information. The distance-imaging information is acquired by the imaging information setting unit 1401 in the following procedure.

ステップS1701では、撮像装置104と対象物との距離の初期値(図15に示す例では「200」)を設定する。ステップS1702では、設定された距離に対応する共通露光時間と各撮像部の照明光源の目標光強度とを決定する。共通露光時間と各撮像部の照明光源の目標光強度は、前述した第2実施形態の構成によって取得することができる。すなわち、設定した距離を計測時距離とすれば、基準露光時間補正部1022によって、各撮像部の基準露光時間が補正され、設定した距離における基準露光時間が求められる。さらに、上限処理部1025によって上限処理が実施され、基準露光時間が露光時間の上限を超えないように調整される。そして、上限処理後の基準露光時間に基づいて、露光時間設定部1026および照明光強度設定部1027によって、共通露光時間と各撮像部の照明光源の目標光強度とが決定される。   In step S1701, an initial value (“200” in the example shown in FIG. 15) of the distance between the imaging device 104 and the object is set. In step S1702, the common exposure time corresponding to the set distance and the target light intensity of the illumination light source of each imaging unit are determined. The common exposure time and the target light intensity of the illumination light source of each imaging unit can be acquired by the configuration of the second embodiment described above. That is, assuming that the set distance is the measurement time distance, the reference exposure time correction unit 1022 corrects the reference exposure time of each imaging unit, and obtains the reference exposure time at the set distance. Further, the upper limit processing unit 1025 performs the upper limit processing, and adjusts the reference exposure time so as not to exceed the upper limit of the exposure time. Then, based on the reference exposure time after the upper limit processing, the exposure time setting unit 1026 and the illumination light intensity setting unit 1027 determine the common exposure time and the target light intensity of the illumination light source of each imaging unit.

ステップ1703では、撮像装置104と対象物との距離が所定の上限値を超えた否かを判断し、上限値を超えた場合には処理を終了する。一方、上限値を超えていない場合にはステップS1704に進む。ステップS1704では、撮像装置104と対象物との距離を所定の量(図15に示す例では「10」)だけ増加させて更新し、ステップS1702へ戻る。このように、撮像装置104と対象物との距離を変更した複数の状態の各々について、共通露光時間と各撮像部の照明光源の目標光強度とを決定することにより、距離−撮像情報を取得することができる。   In step 1703, it is determined whether or not the distance between the imaging device 104 and the object exceeds a predetermined upper limit value, and if it exceeds the upper limit value, the process ends. On the other hand, if it does not exceed the upper limit, the process advances to step S1704. In step S1704, the distance between the imaging device 104 and the object is increased by a predetermined amount (“10” in the example shown in FIG. 15) and updated, and the process returns to step S1702. In this way, the distance-imaging information is acquired by determining the common exposure time and the target light intensity of the illumination light source of each imaging unit for each of the plurality of states in which the distance between the imaging device 104 and the object is changed. can do.

以上説明したように、本変形例の計測装置は、撮像装置104と対象物との距離に対する共通露光時間および照明光源の目標光強度の対応関係を示す情報(た距離−撮像情報)を事前に取得しておく。そして、計測時には、距離−撮像情報を参照して、撮像装置104と対象物との距離に対応する撮像条件を補間で求める。本変形例の構成によれば、より短時間で対象物の位置姿勢を精度よく計測することができる。また、距離−撮像情報に記述された離散的な複数の距離の中で、撮像装置104と対象物との距離に最も近い距離に対応する撮像条件を設定するようにしてもよい。この場合、補間処理も不要になり、距離−撮像情報を参照するだけで撮像条件が設定できるため、さらに短時間での計測を行うことができる。   As described above, the measurement apparatus according to the present modification provides in advance information (distance-imaging information) indicating the correspondence relationship between the common exposure time and the target light intensity of the illumination light source with respect to the distance between the imaging apparatus 104 and the object. Get it. Then, at the time of measurement, the imaging condition corresponding to the distance between the imaging device 104 and the object is obtained by interpolation with reference to the distance-imaging information. According to the configuration of this modification, the position and orientation of the target object can be accurately measured in a shorter time. Further, the imaging condition corresponding to the distance closest to the distance between the imaging device 104 and the object may be set among the plurality of discrete distances described in the distance-imaging information. In this case, interpolation processing is not necessary, and the imaging condition can be set only by referring to the distance-imaging information, so that the measurement can be performed in a shorter time.

<その他の実施形態>
前述の実施形態では、撮像部が2個の例について説明したが、撮像部の数は2個に限らない。3個以上の撮像部を利用した計測装置にも本発明を適用することができる。また、照明光源の波長が互いに異なる複数の撮像部によって、同一の対象物(同一領域)を撮像する例について説明したが、これに限らず、照明光源の波長が同一である複数の撮像部によって、対象物の異なる領域を撮像する構成であってもよい。
<Other embodiments>
In the above-described embodiment, an example in which there are two image capturing units has been described, but the number of image capturing units is not limited to two. The present invention can also be applied to a measuring device that uses three or more imaging units. Also, an example has been described in which the same object (same region) is imaged by a plurality of imaging units having different illumination light source wavelengths, but the present invention is not limited to this, and a plurality of imaging units having the same illumination light source wavelengths is used. The configuration may be such that different regions of the object are imaged.

また、撮像装置104と対象物との距離に応じて撮像条件を変更する構成の例では、撮像(計測)ごとに撮像条件を更新する例を説明したが、n回の計測毎に撮像条件を更新する構成や、外部からの指示に応じて撮像条件を更新する構成でもよい。さらに、目標明るさは、位置姿勢を所定の精度で得るために必要な最低の明るさに限らず、位置姿勢を所定の精度で得ることができる明るさの範囲内における中央値や、撮像画像のコントラストが最大となる明るさなどに設定してもよい。最低の明るさとした場合は、精度を満足する範囲で露光時間を最短化できる。中央値とした場合は、撮像画像の明るさがばらついたとしても、安定して精度を満足できる。コントラストが最大となる明るさとした場合は、投影パターンやエッジが明瞭になるため、パターンやエッジがぼけやすい高速に移動しながらの計測でも安定した計測ができる。   Further, in the example of the configuration in which the imaging condition is changed according to the distance between the imaging device 104 and the target object, the example in which the imaging condition is updated for each imaging (measurement) has been described, but the imaging condition is updated for every n measurements. The configuration may be updated or the imaging condition may be updated according to an instruction from the outside. Further, the target brightness is not limited to the minimum brightness required to obtain the position and orientation with a predetermined accuracy, but is a median value within the range of brightness where the position and orientation can be obtained with a predetermined accuracy, and the captured image. The brightness may be set to the maximum contrast. When the brightness is set to the minimum, the exposure time can be minimized within the range where the accuracy is satisfied. With the median value, the accuracy can be stably satisfied even if the brightness of the captured image varies. When the brightness is such that the contrast becomes maximum, the projected pattern and edges become clear, so stable measurement can be performed even when moving at high speed, where patterns and edges are easily blurred.

また、撮像画像の明るさ評価値も90パーセンタイルに限らず、画素値の平均値や中央値や、他の統計量であってもよい。また、第2実施形態では、撮像装置104と対象物との距離に応じた補正と、露光時間の上限処理とを共に備える構成について説明したが、露光時間の上限処理を備えない構成であっても、本発明を実現することができる。さらに、第2実施形態の変形例3では、撮像情報を第2実施形態の構成によって設定する例を説明したが、これに限らない。例えば、各距離における共通露光時間と各撮像部の照明光源の目標光強度とは、第1実施形態の変形例の構成によって設定してもよい。   Further, the brightness evaluation value of the captured image is not limited to the 90th percentile, and may be the average value or the median value of the pixel values, or another statistic. In addition, in the second embodiment, the configuration including both the correction according to the distance between the imaging device 104 and the object and the upper limit process of the exposure time has been described, but the configuration does not include the upper limit process of the exposure time. Also, the present invention can be realized. Furthermore, in the modified example 3 of the second embodiment, an example in which the imaging information is set by the configuration of the second embodiment has been described, but the present invention is not limited to this. For example, the common exposure time at each distance and the target light intensity of the illumination light source of each imaging unit may be set according to the configuration of the modification of the first embodiment.

また、本発明は、前述の実施形態の計測装置を搭載したロボットとして実現することも可能である。また、当該ロボットを利用したワーク取り出し装置として実現することも可能である。さらに、本発明は、前述の計測装置の機能を実現するロボット制御部として実現することも可能である。   The present invention can also be realized as a robot equipped with the measuring device according to the above-described embodiment. Further, it can be realized as a work picking device using the robot. Furthermore, the present invention can also be realized as a robot controller that realizes the functions of the above-described measuring device.

本発明は、上述の実施形態の1以上の機能を実現するプログラムを、ネットワーク又は記憶媒体を介してシステム又は装置に供給し、そのシステム又は装置のコンピュータにおける1つ以上のプロセッサーがプログラムを読出し実行する処理でも実現可能である。また、1以上の機能を実現する回路(例えば、ASIC)によっても実現可能である。   The present invention supplies a program that realizes one or more functions of the above-described embodiments to a system or apparatus via a network or a storage medium, and one or more processors in a computer of the system or apparatus read and execute the program. It can also be realized by the processing. It can also be realized by a circuit (for example, ASIC) that realizes one or more functions.

以上、本発明の好ましい実施形態について説明したが、本発明はこれらの実施形態に限定されないことはいうまでもなく、その要旨の範囲内で種々の変形および変更が可能である。   Although the preferred embodiments of the present invention have been described above, it goes without saying that the present invention is not limited to these embodiments, and various modifications and changes can be made within the scope of the gist thereof.

100:ロボットシステム、101:ロボットアーム、103:ロボット制御装置、104:撮像装置、105:計測処理装置、106:ワーク(対象物) 100: Robot system, 101: Robot arm, 103: Robot control device, 104: Imaging device, 105: Measurement processing device, 106: Work (object)

Claims (18)

対象物の位置姿勢を計測する計測装置であって、
第1光で前記対象物を照明しながら前記対象物を撮像する第1撮像部と、
第2光で前記対象物を照明しながら前記対象物を撮像する第2撮像部と、
前記第1撮像部および前記第2撮像部でそれぞれ得られた画像に基づいて、前記対象物の位置姿勢を求める処理部と、
を含み、
前記処理部は、前記第1撮像部および前記第2撮像部に対して共通の露光時間を設定し、前記共通の露光時間に基づいて、前記第1撮像部および前記第2撮像部でそれぞれ目標光量が得られるように、前記対象物を照明する前記第1光の強度および前記第2光の強度をそれぞれ調整する、ことを特徴とする計測装置。
A measuring device for measuring the position and orientation of an object,
A first imaging unit that images the object while illuminating the object with first light;
A second imaging unit that images the object while illuminating the object with second light;
A processing unit that obtains the position and orientation of the target object based on the images respectively obtained by the first imaging unit and the second imaging unit;
Including,
The processing unit sets a common exposure time for the first imaging unit and the second imaging unit, and sets a target for each of the first imaging unit and the second imaging unit based on the common exposure time. A measuring device, characterized in that the intensity of the first light and the intensity of the second light for illuminating the object are respectively adjusted so as to obtain a light amount.
前記処理部は、前記第1撮像部に設定された第1基準露光時間、および前記第2撮像部に設定された第2基準露光時間のうち長い方を、前記共通の露光時間として設定する、ことを特徴とする請求項1に記載の計測装置。   The processing unit sets, as the common exposure time, the longer one of the first reference exposure time set in the first image pickup unit and the second reference exposure time set in the second image pickup unit. The measuring device according to claim 1, wherein 前記処理部は、前記共通の露光時間を設定する前に、前記第1基準露光時間および前記第2基準露光時間を設定する、ことを特徴とする請求項2に記載の計測装置。   The measuring device according to claim 2, wherein the processing unit sets the first reference exposure time and the second reference exposure time before setting the common exposure time. 前記処理部は、
前記第1基準露光時間を、前記第1光を最大強度としたときに前記第1撮像部で第1目標光量が得られる露光時間に設定し、
前記第2基準露光時間を、前記第2光を最大強度としたときに前記第2撮像部で第2目標光量が得られる露光時間に設定する、ことを特徴とする請求項2に記載の計測装置。
The processing unit is
The first reference exposure time is set to an exposure time at which the first image pickup unit obtains a first target light amount when the first light has a maximum intensity,
The measurement according to claim 2, wherein the second reference exposure time is set to an exposure time at which the second target light amount is obtained by the second imaging unit when the second light has the maximum intensity. apparatus.
前記処理部は、前記第1撮像部で第1目標光量が得られる前記第1光の強度と露光時間との対応関係を示す第1情報、および、前記第2撮像部で第2目標光量が得られる前記第2光の強度と露光時間との対応関係を示す第2情報に基づいて、前記共通の露光時間を設定する、ことを特徴とする請求項1に記載の計測装置。   The processing unit outputs the first information indicating the correspondence relationship between the intensity of the first light and the exposure time at which the first target light amount is obtained by the first image pickup unit, and the second target light amount by the second image pickup unit. The measuring device according to claim 1, wherein the common exposure time is set based on second information indicating a correspondence relationship between the obtained intensity of the second light and the exposure time. 前記処理部は、前記第1情報および前記第2情報に基づいて、前記第1撮像部で前記第1目標光量を得るための前記第1光の強度を実現可能な露光時間の範囲と、前記第2撮像部で前記第2目標光量を得るための前記第2光の強度を実現可能な露光時間の範囲との重複部分のうち、最小の露光時間を前記共通の露光時間として設定する、ことを特徴とする請求項5に記載の計測装置。   The processing unit, based on the first information and the second information, a range of an exposure time capable of realizing the intensity of the first light for obtaining the first target light amount in the first imaging unit; The minimum exposure time is set as the common exposure time in the overlapping portion with the range of the exposure time at which the intensity of the second light for obtaining the second target light amount in the second imaging unit can be realized. The measuring device according to claim 5. 前記第1撮像部の目標光量は、前記第1撮像部で得られた画像が目標明るさになるように設定され、前記第2撮像部の目標光量は、前記第2撮像部で得られた画像が目標明るさになるように設定されている、ことを特徴とする請求項1乃至6のいずれか1項に記載の計測装置。   The target light amount of the first image pickup unit is set so that the image obtained by the first image pickup unit has the target brightness, and the target light amount of the second image pickup unit is obtained by the second image pickup unit. The measuring device according to any one of claims 1 to 6, wherein the image is set to have a target brightness. 前記処理部は、前記計測装置と前記対象物との距離に応じて、前記共通の露光時間を変更する、ことを特徴とする請求項1乃至7のいずれか1項に記載の計測装置。   8. The measuring device according to claim 1, wherein the processing unit changes the common exposure time according to a distance between the measuring device and the object. 前記処理部は、前記距離が長くなるにつれて前記共通の露光時間が長くなるように、前記共通の露光時間を変更する、ことを特徴とする請求項8に記載の計測装置。   The measuring device according to claim 8, wherein the processing unit changes the common exposure time so that the common exposure time becomes longer as the distance becomes longer. 前記処理部は、前記第1撮像部に予め設定された第1基準露光時間と前記第2撮像部に予め設定された第2基準露光時間とに基づいて決定された前記共通の露光時間を、前記距離に基づいて補正することにより、前記共通の露光時間を変更する、ことを特徴とする請求項8又は9に記載の計測装置。   The processing unit sets the common exposure time determined based on a first reference exposure time preset in the first imaging unit and a second reference exposure time preset in the second imaging unit, The measurement device according to claim 8, wherein the common exposure time is changed by correcting the exposure time based on the distance. 前記処理部は、補正後の前記共通の露光時間が上限露光時間を超える場合、補正後の前記共通の露光時間の代わりに前記上限露光時間を用いて、前記第1撮像部および前記第2撮像部に前記対象物を撮像させる、ことを特徴とする請求項10に記載の計測装置。   When the common exposure time after correction exceeds the upper limit exposure time, the processing unit uses the upper limit exposure time instead of the common exposure time after correction to use the first imaging unit and the second imaging unit. The measuring device according to claim 10, wherein a part is made to image the object. 前記処理部は、前記第1撮像部に予め設定された第1基準露光時間と、前記第2撮像部に予め設定された第2基準露光時間とを前記距離に基づいてそれぞれ補正し、補正後の前記第1基準露光時間および前記第2基準露光時間に基づいて前記共通の露光時間を決定することにより、前記共通の露光時間を変更する、ことを特徴とする請求項8又は9に記載の計測装置。   The processing unit respectively corrects a first reference exposure time preset in the first imaging unit and a second reference exposure time preset in the second imaging unit based on the distance, and after correction. 10. The common exposure time is changed by determining the common exposure time based on the first reference exposure time and the second reference exposure time of. Measuring device. 前記処理部は、補正後の前記第1基準露光時間および前記第2基準露光時間のうち少なくとも一方が上限露光時間を超える場合、前記少なくとも一方の代わりに前記上限露光時間を用いて前記共通の露光時間を決定する、ことを特徴とする請求項12に記載の計測装置。   When at least one of the corrected first reference exposure time and the second reference exposure time exceeds the upper limit exposure time, the processing unit uses the upper limit exposure time instead of the at least one of the common exposures. The measuring device according to claim 12, wherein the time is determined. 前記処理部は、変更後の前記共通の露光時間に基づいて、前記第1撮像部および前記第2撮像部でそれぞれ目標光量が得られるように、前記第1光の強度および前記第2光の強度をそれぞれ調整する、ことを特徴とする請求項12又は13に記載の計測装置。   Based on the common exposure time after the change, the processing unit may adjust the intensity of the first light and the second light so that target light amounts are obtained by the first imaging unit and the second imaging unit, respectively. The measuring device according to claim 12, wherein the strength is adjusted respectively. 前記第1光および前記第2光は、互いに波長が異なる、ことを特徴とする請求項1乃至14のいずれか1項に記載の計測装置。   The measuring device according to any one of claims 1 to 14, wherein the first light and the second light have different wavelengths from each other. 前記第1撮像部および前記第2撮像部は、前記共通の露光時間で同時に前記対象物を撮像する、ことを特徴とする請求項1乃至15のいずれか1項に記載の計測装置。   The measuring device according to claim 1, wherein the first imaging unit and the second imaging unit simultaneously image the object with the common exposure time. 第1光で対象物を照明しながら前記対象物を撮像する第1撮像部と、第2光で前記対象物を照明しながら前記対象物を撮像する第2撮像部とを有し、前記第1撮像部および前記第2撮像部でそれぞれ得られた画像に基づいて前記対象物の位置姿勢を計測する計測装置の校正方法であって、
前記第1撮像部および前記第2撮像部に対して共通の露光時間を設定する設定工程と、
前記設定工程で設定した前記共通の露光時間に基づいて、前記第1撮像部および前記第2撮像部でそれぞれ目標光量が得られるように、前記対象物を照明する前記第1光の強度および前記第2光の強度をそれぞれ調整する調整工程と、
を含むことを特徴とする校正方法。
A first imaging unit that images the object while illuminating the object with a first light; and a second imaging unit that images the object while illuminating the object with a second light, A calibration method of a measuring device for measuring the position and orientation of the target object based on the images respectively obtained by the first imaging unit and the second imaging unit,
A setting step of setting a common exposure time for the first imaging unit and the second imaging unit;
Based on the common exposure time set in the setting step, the intensity of the first light illuminating the object and the intensity of the first light such that the target light amounts are obtained by the first imaging unit and the second imaging unit, respectively. An adjusting step for adjusting the intensity of the second light,
A calibration method comprising:
請求項17に記載の校正方法の各工程をコンピュータに実行させるためのプログラム。   A program for causing a computer to execute each step of the calibration method according to claim 17.
JP2018197843A 2018-10-19 2018-10-19 Measurement device, calibration method thereof, and program Pending JP2020064034A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2018197843A JP2020064034A (en) 2018-10-19 2018-10-19 Measurement device, calibration method thereof, and program

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2018197843A JP2020064034A (en) 2018-10-19 2018-10-19 Measurement device, calibration method thereof, and program

Publications (1)

Publication Number Publication Date
JP2020064034A true JP2020064034A (en) 2020-04-23

Family

ID=70387135

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2018197843A Pending JP2020064034A (en) 2018-10-19 2018-10-19 Measurement device, calibration method thereof, and program

Country Status (1)

Country Link
JP (1) JP2020064034A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111649696A (en) * 2020-06-12 2020-09-11 珠海博明传感器技术有限公司 High-precision calibration method for structured light measurement system

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111649696A (en) * 2020-06-12 2020-09-11 珠海博明传感器技术有限公司 High-precision calibration method for structured light measurement system
CN111649696B (en) * 2020-06-12 2021-07-06 珠海博明传感器技术有限公司 High-precision calibration method for structured light measurement system

Similar Documents

Publication Publication Date Title
JP6290720B2 (en) Inspection device, inspection method, and program
US9672630B2 (en) Contour line measurement apparatus and robot system
KR101461068B1 (en) Three-dimensional measurement apparatus, three-dimensional measurement method, and storage medium
US20100239124A1 (en) Image processing apparatus and method
JP6664436B2 (en) Three-dimensional image processing apparatus and method
JP2007206797A (en) Image processing method and image processor
JP2012215394A (en) Three-dimensional measuring apparatus and three-dimensional measuring method
JP2009168658A (en) Three-dimensional shape measuring device
KR101342523B1 (en) P0sition measurement apparatus and p0sition measuring method
JP6282377B2 (en) Three-dimensional shape measurement system and measurement method thereof
CN114424020A (en) Three-dimensional measuring device
CN106683133B (en) Method for obtaining target depth image
JP2020064034A (en) Measurement device, calibration method thereof, and program
JP6412372B2 (en) Information processing apparatus, information processing system, information processing apparatus control method, and program
JP5740649B2 (en) Image measuring apparatus, autofocus control method, and autofocus control program
JP2011095131A (en) Image processing method
JP2015232478A (en) Inspection device, inspection method, and program
EP3062516B1 (en) Parallax image generation system, picking system, parallax image generation method, and computer-readable recording medium
JP5342977B2 (en) Image processing method
CN111536895B (en) Appearance recognition device, appearance recognition system, and appearance recognition method
CN111566439B (en) Three-dimensional measurement device, three-dimensional measurement method, and three-dimensional measurement storage medium
CN109565544B (en) Position designating device and position designating method
JP2018194544A (en) Information processor, method for processing information, and computer program
WO2014109146A1 (en) Three dimensional measuring device
JP2009186216A (en) Three-dimensional shape measuring device

Legal Events

Date Code Title Description
RD01 Notification of change of attorney

Free format text: JAPANESE INTERMEDIATE CODE: A7421

Effective date: 20210103

A521 Written amendment

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20210113