JP2016142960A - Imaging system and imaging method - Google Patents

Imaging system and imaging method Download PDF

Info

Publication number
JP2016142960A
JP2016142960A JP2015019880A JP2015019880A JP2016142960A JP 2016142960 A JP2016142960 A JP 2016142960A JP 2015019880 A JP2015019880 A JP 2015019880A JP 2015019880 A JP2015019880 A JP 2015019880A JP 2016142960 A JP2016142960 A JP 2016142960A
Authority
JP
Japan
Prior art keywords
imaging
subject
height
depth
boundary
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
JP2015019880A
Other languages
Japanese (ja)
Inventor
学 八講
Manabu Hakko
学 八講
川島 美代子
Miyoko Kawashima
美代子 川島
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 JP2015019880A priority Critical patent/JP2016142960A/en
Publication of JP2016142960A publication Critical patent/JP2016142960A/en
Pending legal-status Critical Current

Links

Abstract

PROBLEM TO BE SOLVED: To provide an imaging system and imaging method that can make a size of a small segment large, and can make a blur of an image in each small segment small.SOLUTION: An imaging system includes: an optical system that forms an image of a subject; imaging means that images an imaging range of the subject for each of a plurality of small segments via the optical system; measurement means that measures a height of the subject in an optical axis direction of the optical system before the subject is imaged by the imaging means; processing means that calculates a residual error based on the height of the subject and an approximate height in a plane having a height distribution of the subject approximated to thereby acquire an imaging condition for each small segment; and adjustment means that adjusts a relative position relation between the small segment and the imaging means on the basis of the imaging condition.SELECTED DRAWING: Figure 4

Description

本発明は、標本を撮像してデジタル画像データを取得する撮像システムおよび撮像方法に関する。   The present invention relates to an imaging system and an imaging method for capturing a sample and acquiring digital image data.

近年、病理診断の分野において、標本(人体の組織片等)の顕微鏡像を撮像し、高精細のデジタル画像を取得・蓄積・閲覧する撮像システムが注目を集めている。この種の撮像システムは、バーチャル・スライド・システムとも呼ばれ、広域な領域を撮像することが求められる。例えば、プレパラート上の10mm×10mmの観察領域を光学倍率10倍で撮像する場合、撮像面での撮像領域の大きさは100mm×100mm、すなわち直径141mm程度になる。これほどの面積を一括で撮像可能な大判の撮像素子(イメージセンサ)は、画素欠陥などによる歩留り低下の影響によりコスト高となる。そのため、被写体の撮像領域を複数の小区画に分割し、小区画単位で撮像を行い、得られた部分画像をつなぎ合わせて全体画像を生成することが行われている。   In recent years, in the field of pathological diagnosis, an imaging system that captures a microscope image of a specimen (such as a tissue piece of a human body) and acquires, accumulates, and browses a high-definition digital image has attracted attention. This type of imaging system is also called a virtual slide system, and is required to image a wide area. For example, when a 10 mm × 10 mm observation area on a slide is imaged at an optical magnification of 10 times, the size of the imaging area on the imaging surface is 100 mm × 100 mm, that is, about 141 mm in diameter. A large image sensor (image sensor) capable of capturing an image of such an area at a time is costly due to the influence of a decrease in yield due to a pixel defect or the like. For this reason, an imaging region of a subject is divided into a plurality of small sections, images are captured in units of small sections, and the obtained partial images are connected to generate an entire image.

ここで、被写体とは、標本そのもの、あるいはプレパラートといった撮像する物体一般を意味する。プレパラートは、観察対象となる標本(組織片等)をスライドグラス上に載置し、これを透明な保護部材(カバーグラス)によって挟んで固定したものである。撮像回数を減らして撮像時間を短縮するためには、小区画の大きさをより大きくし、小区画の数をより少なくすることが望ましい。また、被写体の撮像においては高い解像力が求められ、撮像光学系の物体側の開口数(NA)を大きくする必要がある。しかしながら、物体側の開口数を大きくすると被写界深度は浅くなる。被写体の表面に高さ方向の凹凸がある場合、小区画内で被写界深度を超える高さの場所が存在することがあり、像がぼけてしまうことがある。   Here, the subject means a general object to be imaged such as a specimen itself or a preparation. In the preparation, a specimen (tissue piece or the like) to be observed is placed on a slide glass, and this is sandwiched and fixed by a transparent protective member (cover glass). In order to reduce the number of times of imaging and shorten the imaging time, it is desirable to increase the size of the small sections and reduce the number of small sections. In addition, high resolution is required for imaging a subject, and it is necessary to increase the numerical aperture (NA) on the object side of the imaging optical system. However, increasing the numerical aperture on the object side decreases the depth of field. If the surface of the subject has height unevenness, there may be a place with a height exceeding the depth of field in the small section, and the image may be blurred.

広視野の観察を可能にする技術として、特許文献1では、撮像区画の異なる複数の画像を貼り合せることにより高解像かつ広画角な画像を生成するシステムが提案されている。このシステムでは、最初にオペレータが低解像度の全体画像上で撮像範囲を指定すると、演算装置が撮像範囲を小区画に分割し、小区画毎に顕微鏡で高倍率の画像を撮像する。この際、被写体の高さ情報を用いて合焦位置で画像を撮像する。小区画の大きさは、小区画内で被写界深度を超える部分が生じないように、小さく設定される。   As a technique enabling observation of a wide field of view, Patent Document 1 proposes a system that generates a high-resolution and wide-angle image by combining a plurality of images with different imaging sections. In this system, when an operator first specifies an imaging range on a low-resolution whole image, the arithmetic unit divides the imaging range into small sections and captures a high-magnification image with a microscope for each small section. At this time, an image is taken at the in-focus position using the height information of the subject. The size of the small section is set small so that a portion exceeding the depth of field does not occur in the small section.

また、小区画の大きさを大きくする技術として、特許文献2には、被写体の凹凸に合わせて撮像する技術が開示されている。撮像システムは、第1の結像光学系(結像光学系)と、第2の結像光学系(再結像光学系)と、それらの間の光路上に配置された反射手段とを有する。反射手段の光軸方向の位置および光軸に対する傾きの少なくとも一方を変更することで、被写体の凹凸に合わせて撮像する。この技術において、小区画の数が増えると、第2の結像光学系の数が増えてしまう。第2の結像光学系の数をより少なくするためには小区画の数は少ない方が望ましく、このためには小区画の大きさはより大きいことが望ましい。   As a technique for increasing the size of the small section, Patent Document 2 discloses a technique for imaging in accordance with the unevenness of the subject. The imaging system includes a first imaging optical system (imaging optical system), a second imaging optical system (re-imaging optical system), and reflecting means disposed on the optical path between them. . By changing at least one of the position of the reflecting means in the optical axis direction and the inclination with respect to the optical axis, imaging is performed in accordance with the unevenness of the subject. In this technique, when the number of small sections increases, the number of second imaging optical systems increases. In order to reduce the number of second imaging optical systems, it is desirable that the number of small sections is small. For this purpose, it is desirable that the size of the small sections is larger.

特開2007−108223号公報JP 2007-108223 A 特許第5220172号Patent No. 5220172

特許文献1では、撮像領域を複数の小区画に分割する際に用いる境界は被写体の存在する位置を用いて定められる。ただし、小区画内の高さ分布に対して被写体に対する小区画の境界の相対的な位置が最適化されることはない。撮像面は、像面の凹凸に対して合焦位置を合わせるために光軸方向に平行移動を行う。しかしながら、被写体の凹凸に合わせて、撮像面を被写体に対して相対的に傾けることはできない。このため、被写体の凹凸による像の合焦位置の変化を小さくすることが困難で、小区画の大きさを大きくすることができない。   In Patent Document 1, a boundary used when an imaging region is divided into a plurality of small sections is determined using a position where a subject exists. However, the relative position of the boundary of the small section with respect to the subject is not optimized with respect to the height distribution in the small section. The imaging surface is translated in the direction of the optical axis in order to align the in-focus position with the unevenness of the image surface. However, the imaging surface cannot be tilted relative to the subject in accordance with the unevenness of the subject. For this reason, it is difficult to reduce the change in the focus position of the image due to the unevenness of the subject, and the size of the small section cannot be increased.

特許文献2では、反射手段の位置や傾きを調整することで、被写体の凹凸が被写界深度を超えないようにする。しかし、被写体の凹凸の量が大きいと小区画の大きさを大きくすることは難しい。また、小区画に分割する境界によっては、被写体の凹凸が被写界深度を越える場合がある。このような場合に対応するためには、小区画の大きさや被写体に対する小区画の境界位置ならびに反射手段の位置調整量を最適化する必要がある。しかしながら、小区画の大きさや小区画に分割する境界を最適化し、最適化された境界において反射手段の位置や傾きを決定する方法の具体的な開示はない。   In Patent Literature 2, the unevenness of the subject is prevented from exceeding the depth of field by adjusting the position and inclination of the reflecting means. However, if the amount of unevenness of the subject is large, it is difficult to increase the size of the small section. Also, depending on the boundary divided into small sections, the unevenness of the subject may exceed the depth of field. In order to cope with such a case, it is necessary to optimize the size of the small section, the boundary position of the small section with respect to the subject, and the position adjustment amount of the reflecting means. However, there is no specific disclosure of a method for optimizing the size of a small section or the boundary to be divided into small sections and determining the position and inclination of the reflecting means at the optimized boundary.

このような課題を鑑みて、本発明は、小区画のサイズを大きくするとともに、各小区画内の像のぼけを小さくすることが可能な撮像システムおよび撮像方法を提供することを目的とする。   In view of such a problem, an object of the present invention is to provide an imaging system and an imaging method capable of increasing the size of a small section and reducing blurring of an image in each small section.

本発明の一側面としての撮像システムは、被写体の像を形成する光学系と、前記光学系を介して、前記被写体の撮像範囲を複数の小区画毎に撮像する撮像手段と、前記撮像手段で前記被写体を撮像する前に、前記光学系の光軸方向における前記被写体の高さを計測する計測手段と、前記被写体の高さと前記被写体の高さ分布を近似した平面における近似高さとに基づく残差を算出することで、前記小区画毎の撮像条件を取得する処理手段と、前記撮像条件に基づいて、前記小区画と前記撮像手段との相対的な位置関係を調節する調節手段と、を有することを特徴とする。   An imaging system according to an aspect of the present invention includes an optical system that forms an image of a subject, an imaging unit that captures an imaging range of the subject for each of a plurality of small sections via the optical system, and the imaging unit. Before imaging the subject, a measuring means for measuring the height of the subject in the optical axis direction of the optical system, and a residual based on the height of the subject and an approximate height on a plane approximating the height distribution of the subject. Processing means for obtaining an imaging condition for each of the small sections by calculating a difference; and adjusting means for adjusting a relative positional relationship between the small sections and the imaging means based on the imaging conditions; It is characterized by having.

また、本発明の他の側面としての撮像方法は、被写体の像を形成する光学系と、前記光学系を介して、前記被写体の撮像範囲を複数の小区画毎に撮像する撮像手段と、を有する撮像システムの撮像方法であって、前記光学系の光軸方向における前記被写体の高さを計測するステップと、前記被写体の高さと前記被写体の高さ分布を近似した平面における近似高さとに基づく残差を算出することで、前記小区画毎の撮像条件を取得するステップと、前記撮像条件に基づいて、前記小区画と前記撮像手段との相対的な位置関係を調節するステップと、前記撮像手段が前記小区画を撮像するステップと、を有することを特徴とする。   According to another aspect of the present invention, an imaging method includes: an optical system that forms an image of a subject; and an imaging unit that captures an imaging range of the subject for each of a plurality of small sections via the optical system. An imaging method for an imaging system, comprising: measuring a height of the subject in the optical axis direction of the optical system; and an approximate height in a plane that approximates the height of the subject and the height distribution of the subject A step of obtaining an imaging condition for each of the small sections by calculating a residual, a step of adjusting a relative positional relationship between the small section and the imaging unit based on the imaging conditions, and the imaging And means for imaging the subsection.

本発明によれば、小区画のサイズを大きくするとともに、各小区画内の像のぼけを小さくすることが可能な撮像システムおよび撮像方法を提供することができる。   ADVANTAGE OF THE INVENTION According to this invention, while increasing the size of a small division, the imaging system and imaging method which can make the blur of the image in each small division small can be provided.

本発明の実施形態に係る撮像システムの要部概略図である。It is a principal part schematic of the imaging system which concerns on embodiment of this invention. 反射部材を有する撮像ユニットの要部概略図である。It is a principal part schematic diagram of the imaging unit which has a reflection member. 平面フィッティングの説明図である。It is explanatory drawing of a plane fitting. 撮像方法のフローチャートである。It is a flowchart of an imaging method. 撮像条件の設定を示す図である。It is a figure which shows the setting of an imaging condition. 撮像条件の設定法を示す図である。It is a figure which shows the setting method of an imaging condition. 撮像条件の設定法1,2のフローチャートである。6 is a flowchart of imaging method setting methods 1 and 2; 撮像条件の設定法3のフローチャートである。10 is a flowchart of an imaging condition setting method 3; 撮像条件の設定法4のフローチャートである。10 is a flowchart of an imaging condition setting method 4; 実施例1の計測で得た高さを示す図である。It is a figure which shows the height obtained by the measurement of Example 1. FIG. 実施例1の境界を変化させたことを示す図である。It is a figure which shows having changed the boundary of Example 1. FIG. 実施例2の被写界深度を超える残差の位置を示す図である。FIG. 10 is a diagram illustrating a position of a residual exceeding the depth of field according to the second embodiment. 実施例2の被写界深度を超える残差の値を示す図である。It is a figure which shows the value of the residual exceeding the depth of field of Example 2. 実施例2の被写界深度を超える残差の位置と、その残差を撮像する境界を示す図である。It is a figure which shows the position of the residual exceeding the depth of field of Example 2, and the boundary which images the residual. 実施例2の新しい境界における残差の値を示す図である。It is a figure which shows the value of the residual in the new boundary of Example 2. FIG. 実施例2の計測で得た高さを示す図である。It is a figure which shows the height obtained by the measurement of Example 2. FIG. 実施例3の被写界深度を超える残差の位置を示す図である。FIG. 10 is a diagram illustrating a position of a residual exceeding the depth of field according to the third embodiment. 実施例3の被写界深度を超える残差の値を示す図である。It is a figure which shows the value of the residual exceeding the depth of field of Example 3. 実施例3の被写界深度を超える残差の位置と、その残差を撮像する境界を示す図である。It is a figure which shows the position of the residual exceeding the depth of field of Example 3, and the boundary which images the residual. 実施例3の新しい境界における残差の値を示す図である。It is a figure which shows the value of the residual in the new boundary of Example 3. FIG.

以下、本発明の実施例について、図面を参照しながら詳細に説明する。各図において、同一の部材については同一の参照番号を付し、重複する説明は省略する。
(システム構成)
図1は、本発明の実施形態に係る撮像システムの要部概略図である。光軸に平行な方向をz方向、紙面に垂直な方向をx方向、光軸に垂直で紙面と平行な方向をy方向とする。撮像システムは、計測撮像装置1、演算装置(処理手段)2、および表示装置3から構成される。
Hereinafter, embodiments of the present invention will be described in detail with reference to the drawings. In each figure, the same members are denoted by the same reference numerals, and redundant description is omitted.
(System configuration)
FIG. 1 is a main part schematic diagram of an imaging system according to an embodiment of the present invention. The direction parallel to the optical axis is the z direction, the direction perpendicular to the paper surface is the x direction, and the direction perpendicular to the optical axis and parallel to the paper surface is the y direction. The imaging system includes a measurement imaging device 1, an arithmetic device (processing means) 2, and a display device 3.

計測撮像装置1は、計測ユニット(計測手段)100、撮像ユニット(撮像手段)300、被写体であるプレパラート103を搬送する搬送部203、および制御部401を有し、プレパラート103上の標本を撮像してデジタル画像を生成する。計測ユニット100は、表面形状計測を行う。表面形状計測とは、プレパラート103上の標本位置や被写体の高さ(凹凸)を計測することを指す。表面形状計測は、被写体を撮像する前に撮像ユニット300で撮像する撮像倍率よりも低い倍率で行われる。また、計測ユニット100は、表面形状計測のみでなく、計測データを処理する機能を有していてもよい。例えば、表面形状計測の結果に対して表面形状の空間周波数を計算し、空間周波数が一定の値を超えた成分を除去する処理を行う機能を有する。この処理で、ステージの誤差や計測エラーに起因する高い空間周波数を持つノイズを除去することができる。表面形状計測の結果は、撮像ユニット300の撮像条件を設定する際に用いられる。撮像ユニット300は、被写体の撮像領域を複数の小区画に分割し、小区画単位で撮像を行う。ここでは小区画毎に異なる撮像素子で撮像する場合を考える。本実施形態では、被写体を複数の小区画に分割する境界の位置を決める際に、計測ユニット100による表面形状計測の結果を用いる。つまり、表面形状計測で得られた標本またはカバーグラスの高さz(x,y)を用いて、撮像条件の1つである被写体に対する小区画の境界位置(x,y)を設定する。撮像条件は、小区画の境界位置に限らず、後述する撮像面の位置や傾きの条件を含み、より少ない撮像回数で被写体の全領域を被写界深度に収まるように設定される。撮像条件は、演算装置2を用いて計算される。搬送部203は、表面形状計測が終了したプレパラート103を、計測ユニット100から撮像ユニット300に搬送する。制御部401は、小区画の境界位置などの撮像条件を満たすように、撮像装置の被写体の位置や撮像面の位置を制御する。   The measurement and imaging apparatus 1 includes a measurement unit (measurement unit) 100, an imaging unit (imaging unit) 300, a conveyance unit 203 that conveys a preparation 103 that is a subject, and a control unit 401, and images a sample on the preparation 103. To generate a digital image. The measurement unit 100 performs surface shape measurement. The surface shape measurement refers to measuring the sample position on the preparation 103 and the height (unevenness) of the subject. The surface shape measurement is performed at a magnification lower than the imaging magnification imaged by the imaging unit 300 before imaging the subject. The measurement unit 100 may have a function of processing measurement data as well as surface shape measurement. For example, it has a function of calculating a spatial frequency of the surface shape with respect to the result of the surface shape measurement and performing a process of removing a component whose spatial frequency exceeds a certain value. With this process, noise having a high spatial frequency due to stage errors or measurement errors can be removed. The result of the surface shape measurement is used when setting the imaging conditions of the imaging unit 300. The imaging unit 300 divides the imaging area of the subject into a plurality of small sections, and performs imaging in units of small sections. Here, consider a case where an image is picked up by a different image sensor for each small section. In the present embodiment, the result of surface shape measurement by the measurement unit 100 is used when determining the position of the boundary that divides the subject into a plurality of small sections. That is, the boundary position (x, y) of the small section with respect to the subject, which is one of the imaging conditions, is set using the height z (x, y) of the sample or cover glass obtained by the surface shape measurement. The imaging conditions are not limited to the boundary positions of the small sections, but include conditions for the position and inclination of the imaging surface described later, and are set so that the entire area of the subject can be accommodated in the depth of field with a smaller number of imaging times. The imaging condition is calculated using the arithmetic device 2. The transport unit 203 transports the preparation 103 whose surface shape measurement has been completed from the measurement unit 100 to the imaging unit 300. The control unit 401 controls the position of the subject of the imaging apparatus and the position of the imaging surface so as to satisfy imaging conditions such as the boundary positions of the small sections.

演算装置2は、撮像条件を取得する。また、計測撮像装置1を用いて得られた画像データに対し所定の画像処理(現像、色変換、ガンマ補正、ノイズ除去、圧縮など)を適用する機能、小区画の画像をつなぎ合わせる機能、および画像の管理・閲覧を行う機能などを有する。演算装置2は、CPU、メモリ、記憶装置、および入力装置(入力手段)などを備える汎用のコンピュータでもよいし、専用の画像処理回路を有してもよい。演算装置2の記憶装置には、撮影条件を取得するためのプログラムが格納されている。なお、演算装置2の機能を計測撮像装置1に組み込んでもよい。   The arithmetic device 2 acquires imaging conditions. A function of applying predetermined image processing (development, color conversion, gamma correction, noise removal, compression, etc.) to the image data obtained by using the measurement imaging device 1, a function of stitching the images of the small sections, and It has functions to manage and view images. The arithmetic device 2 may be a general-purpose computer including a CPU, a memory, a storage device, an input device (input means), and the like, or may have a dedicated image processing circuit. The storage device of the arithmetic device 2 stores a program for acquiring shooting conditions. Note that the function of the arithmetic device 2 may be incorporated in the measurement imaging device 1.

表示装置3は、画像や計算結果などの閲覧に用いられるディスプレイである。なお、表示装置3を計測撮像装置1や演算装置2に一体化してもよい。   The display device 3 is a display used for browsing images and calculation results. Note that the display device 3 may be integrated with the measurement imaging device 1 and the calculation device 2.

計測ユニット100は、計測用照明部101、計測用ステージ102、計測用光学系104、および計測部105を備える。計測用照明部101は、計測用ステージ102上に設置されているプレパラート103に光源からの光を導く照明光学系を有する。計測用ステージ102は、プレパラート103を保持し、計測用光学系104に対するプレパラート103の位置を調整する。計測用光学系104は、プレパラート103を透過した光を計測部105に導く光学系である。計測ユニット100ではプレパラート全体の計測を行うことが目的のため、計測用光学系104は低倍率でよい。計測部105は、センサであり、計測用光学系104からの光に基づき、被写体上の複数の点における物理量を計測する。標本もしくはカバーグラスの凹凸(表面形状)を計測する目的であれば、反射光や干渉光を利用する各種の距離センサを用いることができる。図1では、透過型の計測ユニットを例示しているが、計測する物理量やセンサの種類に応じて、カバーグラス側から光を照射し被写体での反射光を計測する反射型の計測ユニットを用いてもよい。また、複数のユニットもしくはセンサを組み合わせて用いてもよい。各計測点の計測データは制御部401に伝送される。   The measurement unit 100 includes a measurement illumination unit 101, a measurement stage 102, a measurement optical system 104, and a measurement unit 105. The measurement illumination unit 101 has an illumination optical system that guides light from a light source to a preparation 103 installed on the measurement stage 102. The measurement stage 102 holds the preparation 103 and adjusts the position of the preparation 103 with respect to the measurement optical system 104. The measurement optical system 104 is an optical system that guides the light transmitted through the preparation 103 to the measurement unit 105. Since the measurement unit 100 is intended to measure the entire preparation, the measurement optical system 104 may have a low magnification. The measurement unit 105 is a sensor, and measures physical quantities at a plurality of points on the subject based on the light from the measurement optical system 104. For the purpose of measuring the unevenness (surface shape) of the specimen or the cover glass, various distance sensors using reflected light or interference light can be used. In FIG. 1, a transmission type measurement unit is illustrated, but a reflection type measurement unit that irradiates light from the cover glass side and measures reflected light from the subject is used according to the physical quantity to be measured and the type of sensor. May be. A plurality of units or sensors may be used in combination. Measurement data at each measurement point is transmitted to the control unit 401.

搬送部203は、表面形状計測が終了したプレパラート103を、計測ユニット100から撮像ユニット300に搬送する。撮像ユニット300に搬送されたプレパラート103は、撮像ユニット300の撮像用ステージ302上に配置されたプレパラート303として示されている。搬送部203は、例えば計測用ステージ102自体を移動させ、撮像用ステージ302として機能させてもよい。また、ハンド装置によりプレパラート103を保持または吸着してステージ上に移動させてもよい。さらに、複数のプレパラート103を撮像する場合には、計測用ステージ102と撮像用ステージ302にそれぞれ異なるプレパラートが設置されてもよい。このとき、表面形状計測処理と撮像処理が並列に行われてもよい。なお、複数のプレパラートの撮像を連続的に行う場合は、ストッカ(不図示)に収容されているプレパラート103が搬送部203によって1枚ずつ計測用ステージ102から撮像用ステージ302に搬送されるのが望ましい。   The transport unit 203 transports the preparation 103 whose surface shape measurement has been completed from the measurement unit 100 to the imaging unit 300. The preparation 103 conveyed to the imaging unit 300 is shown as a preparation 303 disposed on the imaging stage 302 of the imaging unit 300. For example, the transport unit 203 may move the measurement stage 102 itself to function as the imaging stage 302. Alternatively, the preparation 103 may be held or sucked by the hand device and moved onto the stage. Further, when imaging a plurality of preparations 103, different preparations may be installed on the measurement stage 102 and the imaging stage 302, respectively. At this time, the surface shape measurement process and the imaging process may be performed in parallel. In addition, when imaging a plurality of slides continuously, the slide 103 accommodated in a stocker (not shown) is transported one by one from the measurement stage 102 to the imaging stage 302 by the transport unit 203. desirable.

撮像ユニット300は、撮像用照明部301、撮像用ステージ302、結像光学系304、およびCCDやCMOSといった撮像素子から構成された撮像部305を有する。撮像用照明部301は、ステージ302上に設置されているプレパラート303に光源からの光を導く照明光学系を有する。光源には、例えばハロゲンランプやキセノンランプ、LED(Light Emitting Diode)を用いることができる。結像光学系304は、被写体の像を拡大して撮像部305に形成する。撮像部305は、複数の撮像素子から構成されている。図1では、3つの撮像素子が設けられているが、撮像素子の数はこれに限らない。撮像素子で受光した光を光電変換し、画像データを生成、出力する。この画像データは制御部401を介して演算装置2に伝送される。撮像素子のサイズ、数、配置は任意である。N個の小区画の撮像を行うために、N個の撮像素子を用いて一括撮像をすることが理想ではあるが、1つの撮像素子でN回撮像してもよいし、複数(m個)の撮像素子でN/m回撮像してもよい。複数の撮像素子を用いるほうが撮像時間を短縮できる。   The imaging unit 300 includes an imaging unit 305 including an imaging illumination unit 301, an imaging stage 302, an imaging optical system 304, and an imaging element such as a CCD or a CMOS. The imaging illumination unit 301 has an illumination optical system that guides light from a light source to a preparation 303 installed on a stage 302. As the light source, for example, a halogen lamp, a xenon lamp, or an LED (Light Emitting Diode) can be used. The imaging optical system 304 enlarges the subject image and forms it on the imaging unit 305. The imaging unit 305 includes a plurality of imaging elements. In FIG. 1, three image sensors are provided, but the number of image sensors is not limited to this. The light received by the image sensor is photoelectrically converted to generate and output image data. This image data is transmitted to the arithmetic device 2 via the control unit 401. The size, number, and arrangement of the image sensor are arbitrary. In order to capture N small sections, it is ideal to perform collective imaging using N imaging elements. However, N imaging may be performed with one imaging element, or a plurality (m). You may image N / m times with this image sensor. The imaging time can be shortened by using a plurality of imaging elements.

制御部401は、各駆動部とともに駆動機構(調節手段)として機能する。具体的には、制御部401は、演算装置2が取得した撮像情報に基づいて各駆動部を駆動することで、プレパラート303と、撮像部305を構成する複数の撮像素子の撮像面との相対的な位置関係を調節する。相対的な位置関係とは、xy平面上の撮像面に対するプレパラート303の位置と、z方向におけるプレパラート303と撮像面との距離と、撮像面に対するプレパラート303のz軸に対する傾き角度を意味する。xy平面上の撮像面に対するプレパラート303の位置は、被写体を小区画に分割する境界の位置の条件から決まる。z方向におけるプレパラート303と撮像面との距離と、撮像面に対するプレパラート303のz軸に対する傾き角度は、小区画内の撮像データが被写界深度内に収まるように設定される。   The control unit 401 functions as a driving mechanism (adjusting means) together with each driving unit. Specifically, the control unit 401 drives each driving unit based on the imaging information acquired by the arithmetic device 2, so that the preparation 303 and the imaging surfaces of the plurality of imaging elements constituting the imaging unit 305 are relative to each other. Adjust the relative position. The relative positional relationship means the position of the preparation 303 with respect to the imaging surface on the xy plane, the distance between the preparation 303 and the imaging surface in the z direction, and the tilt angle of the preparation 303 with respect to the z-axis with respect to the imaging surface. The position of the preparation 303 with respect to the imaging surface on the xy plane is determined by the condition of the boundary position for dividing the subject into small sections. The distance between the preparation 303 and the imaging surface in the z direction and the inclination angle of the preparation 303 with respect to the imaging surface with respect to the z axis are set such that the imaging data in the small section is within the depth of field.

駆動部201は、制御部401から伝送された信号に基づき、撮像用ステージ302を駆動し、プレパラート303と撮像部305との相対的な位置を調整する。駆動部201は、撮像用ステージ302をxy平面上で平行移動させ、プレパラート303の位置を微調整する。駆動部201は、撮像用ステージ302に対し、z軸を中心としたxy平面内での回転や、z方向の平行移動や、x軸やy軸を中心とした回転を行ってもよい。   The driving unit 201 drives the imaging stage 302 based on the signal transmitted from the control unit 401 and adjusts the relative positions of the preparation 303 and the imaging unit 305. The drive unit 201 translates the imaging stage 302 on the xy plane and finely adjusts the position of the preparation 303. The drive unit 201 may rotate the imaging stage 302 in the xy plane around the z axis, translate in the z direction, or rotate around the x axis or the y axis.

駆動部202は、制御部401から伝送された信号に基づき、撮像部305を駆動する。駆動部202は、撮像部305を構成する複数の撮像素子それぞれに対して独立に設けられている。駆動部202は、x軸を中心にした回転駆動を行う。本実施形態では、xz面内に駆動部(不図示)が配置されている。xz面内の駆動部は、y軸を中心にした回転駆動を行う。そうすることで、撮像素子のz軸に対する傾きが変化する。すなわち、本実施形態では、撮像部305を構成する複数の撮像素子ごとに位置および傾きを調整することができる。また、駆動部202は、撮像素子のz方向の位置を変化させる。
(反射部材を有する撮像ユニットの構成)
撮像ユニット300に複数の撮像部が設けられている構成の一例について、図2を用いて説明する。図2では、例として2つの撮像部505,508が設けられている。撮像ユニットは、第1の結像光学系502と第2の結像光学系504,507に分かれている。図中のx,y,z軸は、第1の結像光学系502の光軸方向と、第2の結像光学系504,507の光軸方向に基づいて別々に設定されるローカル座標とする。第1の結像光学系502の像位置には、反射部材503,506が配置されている。反射部材503は第1の結像光学系502と第2の結像光学系504との間、反射部材506は第1の結像光学系502と第2の結像光学系507との間に配置されている。第2の結像光学系504,507の物点に相当する位置は、第1の結像光学系502の像点に相当する。第2の結像光学系504,507の物点に相当する位置は、第1の結像光学系502の像において異なる位置に相当する。第1の結像光学系502の像とは撮像用ステージ501上の被写体の像であるから、複数の第2の結像光学系504,507はそれぞれ被写体の異なる領域を再結像する。このように複数の第2の結像光学系を用いることで、第2の結像光学系の撮像領域を複数の小区画に分割して一括撮像することができる。本実施形態では、表面形状計測の結果に基づいて、駆動部509で撮像用ステージ501を駆動し、撮像用ステージ501上の被写体をxy面内で平行移動させる。こうして被写体に対する小区画の境界位置を最適にする。また、駆動部512,513で反射部材503,506の傾きや光軸(z軸)に対する位置を変化させる。このように境界の位置と反射部材503,506傾きや光軸に対する位置を変化させることで、各小区画の撮像を行う。反射部材を有する撮像ユニットの場合は、このように反射部材を用いて被写体と撮像部との相対的な位置および方向を変化させることができる。また、反射部材のみでなく、駆動部510,511を用いて撮像部505,508の位置を変化させて各小区画の撮像を行ってもよい。撮像部の位置の変化においては、z方向の位置や撮像面内の位置を主に変化させる。なお、第1および第2の結像光学系の少なくとも一方が、変倍機能を有していてもよい。
(平面フィッティング)
平面フィッティングについて、図3を用いて説明する。平面フィッティングは、撮像面の光軸に対する位置と傾きを設定する際に演算装置2によって計算される。
The driving unit 202 drives the imaging unit 305 based on the signal transmitted from the control unit 401. The driving unit 202 is provided independently for each of the plurality of imaging elements constituting the imaging unit 305. The driving unit 202 performs rotational driving around the x axis. In the present embodiment, a drive unit (not shown) is disposed in the xz plane. The drive unit in the xz plane performs rotational driving around the y axis. By doing so, the inclination of the image sensor with respect to the z-axis changes. That is, in the present embodiment, the position and inclination can be adjusted for each of a plurality of image sensors that constitute the imaging unit 305. The drive unit 202 changes the position of the image sensor in the z direction.
(Configuration of imaging unit having a reflecting member)
An example of a configuration in which the imaging unit 300 includes a plurality of imaging units will be described with reference to FIG. In FIG. 2, two imaging units 505 and 508 are provided as an example. The imaging unit is divided into a first imaging optical system 502 and second imaging optical systems 504 and 507. The x, y, and z axes in the figure are local coordinates set separately based on the optical axis direction of the first imaging optical system 502 and the optical axis directions of the second imaging optical systems 504 and 507. To do. Reflecting members 503 and 506 are arranged at the image position of the first imaging optical system 502. The reflecting member 503 is between the first imaging optical system 502 and the second imaging optical system 504, and the reflecting member 506 is between the first imaging optical system 502 and the second imaging optical system 507. Has been placed. The positions corresponding to the object points of the second imaging optical systems 504 and 507 correspond to the image points of the first imaging optical system 502. The positions corresponding to the object points of the second imaging optical systems 504 and 507 correspond to different positions in the image of the first imaging optical system 502. Since the image of the first imaging optical system 502 is an image of the subject on the imaging stage 501, the plurality of second imaging optical systems 504 and 507 re-image each different area of the subject. As described above, by using the plurality of second imaging optical systems, the imaging region of the second imaging optical system can be divided into a plurality of small sections and collectively imaged. In the present embodiment, the imaging stage 501 is driven by the drive unit 509 based on the surface shape measurement result, and the subject on the imaging stage 501 is translated in the xy plane. In this way, the boundary position of the small section with respect to the subject is optimized. In addition, the tilts of the reflecting members 503 and 506 and the position with respect to the optical axis (z axis) are changed by the driving units 512 and 513. In this way, by changing the position of the boundary, the inclination of the reflecting members 503 and 506, and the position with respect to the optical axis, each small section is imaged. In the case of an imaging unit having a reflecting member, the relative position and direction between the subject and the imaging unit can be changed using the reflecting member in this way. Further, not only the reflecting member but also the driving units 510 and 511 may be used to change the positions of the imaging units 505 and 508 to perform imaging of each small section. In changing the position of the imaging unit, the position in the z direction and the position in the imaging plane are mainly changed. Note that at least one of the first and second imaging optical systems may have a zooming function.
(Flat fitting)
The plane fitting will be described with reference to FIG. The plane fitting is calculated by the arithmetic unit 2 when setting the position and inclination of the imaging surface with respect to the optical axis.

図3(a)に示すように、被写体の領域を大きさが指定された小区画で分割する。黒い実線で示した正方形の1つ1つが小区画の1つ1つを示している。灰色の濃淡は表面形状計測で取得した被写体の高さを表し、色が薄いほど被写体の高さが高いことを示している。平面フィッティングは、表面形状計測で取得した小区画内の被写体の高さデータに対して行われる。別の小区画に属する高さは、別の平面でフィッティングされる。同一の小区画に属する高さは、同一の平面でフィッティングされる。平面フィッティングは、最小二乗法などの一般的な方法を用いることができる。表面形状計測で取得した小区画内の被写体のデータと平面フィッティング後のデータとの残差(フィッティング残差)が被写界深度内に収まるように、被写体に対する小区画の境界位置を最適化する。例えば、図3(b)は、図3(a)のR1で示す小区画を平面フィッティングした図である。平面フィッティング前のデータをZ(X,Y)、平面フィッティング後のデータをP(X,Y)、残差をE、平面のX方向の傾きをG、平面のY方向の傾きをH、平面のZ方向の位置をCとすると、以下の式(1),(2)が成り立つ。G,H,Cの値は撮像条件に相当し、G,H,Cの値に対応するように、撮像面の傾きと位置が設定される。   As shown in FIG. 3A, the area of the subject is divided into small sections having a designated size. Each square indicated by a solid black line represents a small section. Gray shading represents the height of the subject acquired by the surface shape measurement, and the lighter the color, the higher the height of the subject. The plane fitting is performed on the height data of the subject in the small section acquired by the surface shape measurement. Heights belonging to different subsections are fitted with different planes. Heights belonging to the same small section are fitted on the same plane. For the plane fitting, a general method such as a least square method can be used. Optimize the boundary position of the small section relative to the subject so that the residual (fitting residual) between the data of the subject in the small section obtained by surface shape measurement and the data after plane fitting is within the depth of field. . For example, FIG. 3B is a diagram in which a small section indicated by R1 in FIG. The data before plane fitting is Z (X, Y), the data after plane fitting is P (X, Y), the residual is E, the slope of the plane in the X direction is G, the slope of the plane in the Y direction is H, the plane When the position in the Z direction is C, the following equations (1) and (2) hold. The values of G, H, and C correspond to the imaging conditions, and the inclination and position of the imaging surface are set so as to correspond to the values of G, H, and C.

P(X,Y)=G・X+H・Y+C (1)
E(X,Y)=|P(X,Y)−Z(X,Y)| (2)
また、平面フィッティングにおける各平面の境界位置は、小区画の境界位置と同一であり、これも撮像条件に相当する。撮像用ステージ302の位置は、境界位置に対応するように設定される。なお、残差Eの評価は、上式を用いた方法に限らず、他の方法を用いてもよい。例えば、小区画内にある残差E(X,Y)のデータ数がNd個と大きい場合、評価する残差のデータ数をMdに減らして評価してもよい。例えば、1つの小区画にあるNd個のデータに対してR個(Nd>R)のデータをひとまとめにして評価することで、評価データをMd個に減らす。この場合は、Md=Nd/Rとなる。Nd/Rが小数になる場合は、小数点以下を切り捨てて整数にする。R個のデータを用いて、二乗平均平方根RMSを式(3)で求める。
P (X, Y) = G.X + H.Y + C (1)
E (X, Y) = | P (X, Y) −Z (X, Y) | (2)
Further, the boundary position of each plane in the plane fitting is the same as the boundary position of the small section, and this also corresponds to the imaging condition. The position of the imaging stage 302 is set so as to correspond to the boundary position. Note that the evaluation of the residual E is not limited to the method using the above equation, and other methods may be used. For example, when the number of residual E (X, Y) data in the small section is as large as Nd, the number of residual data to be evaluated may be reduced to Md for evaluation. For example, the evaluation data is reduced to Md by evaluating R data (Nd> R) collectively for Nd data in one small section. In this case, Md = Nd / R. When Nd / R becomes a decimal, the decimal part is rounded down to an integer. Using the R pieces of data, the root mean square RMS is obtained by Equation (3).

二乗平均平方根RMSは、1つの小区画でMd個得られる。そして、Md個のデータを用いて1つの小区画の残差を評価してもよい。
(画像取得の手順)
本実施形態の撮像方法について、図4のフローチャートを用いて説明する。ステップs1では、表面形状計測で被写体の高さを計測し、高さデータを取得する。表面形状計測は、計測ユニット100を用いて行われる。ステップs2では、被写体の撮像範囲を複数の小区画に分割して撮像する際の撮像条件を設定する。撮像条件には、小区画の境界位置や、撮像面の位置、傾きを含む。これ以外にも撮像光学系が変倍機能を有する場合、小区画の大きさを含む場合がある。撮像条件は、演算装置2によって計算される。ステップs3では、ステップs2で設定された撮像条件に基づいて、駆動機構を用いて撮像用ステージ、撮像面、および反射部材を動かして、各小区画の部分画像を撮像する。ステップs4では、ステップs3で撮像した部分画像のデータを取り込む。演算装置2は、所定の画像処理の適用、小区画の画像をつなぎ合わせ、および画像の管理・閲覧などを実行する。また、表示装置3を用いて画像や解析結果などを表示する。さらに、画像データを内部または外部の記憶装置に保存する。
(撮像条件の設定の概要)
図4のステップs2の撮像条件は、より少ない撮像回数で被写体の全領域を被写界深度に収まるように設定される。演算装置2は、まず、撮像回数1回で被写体の全領域を被写界深度に収まるように撮像する条件があるかを計算する。この条件がない場合には、撮像回数2回で被写体の全領域を被写界深度に収まるように撮像する条件があるかを計算する。具体的には、1回目の撮像で被写界深度に収まらなかった全ての領域を被写界深度に収まるように撮像する条件があるかを計算する。1回目の撮像で被写界深度におさまった領域については、撮像データが記憶装置に保存されるので、2回目で必ずしも撮像する必要はない。2回の撮像でも被写体の全領域を被写界深度に収まるように撮像する条件がない場合は、さらに同様に回数を増やし、被写体の全領域を被写界深度に収まるように撮像する条件があるかを計算する。あらかじめ決められた撮像回数に達しても被写体の全領域を被写界深度に収まるように撮像する条件がない場合は、深度を超える領域を表示する。表示された領域に関しては、撮像用ステージまたは撮像面のいずれか一方のz方向の位置を変化させながら複数枚の画像を撮像し、被写界深度に収まる画像を得ることができる。しかしながら、この方法は撮像時間が増えてしまう。
The root mean square RMS is obtained as Md pieces in one small section. Then, the residual of one small section may be evaluated using Md pieces of data.
(Image acquisition procedure)
The imaging method of this embodiment will be described using the flowchart of FIG. In step s1, the height of the subject is measured by surface shape measurement, and height data is acquired. The surface shape measurement is performed using the measurement unit 100. In step s2, an imaging condition is set when the subject imaging range is divided into a plurality of small sections. The imaging conditions include the boundary positions of the small sections, the position of the imaging surface, and the inclination. In addition to this, when the imaging optical system has a zooming function, it may include the size of a small section. The imaging condition is calculated by the arithmetic device 2. In step s3, based on the imaging condition set in step s2, the imaging stage, the imaging surface, and the reflecting member are moved using the drive mechanism, and a partial image of each small section is captured. In step s4, the partial image data captured in step s3 is captured. The arithmetic device 2 executes application of predetermined image processing, stitching of images of small sections, image management / viewing, and the like. The display device 3 is used to display images, analysis results, and the like. Further, the image data is stored in an internal or external storage device.
(Overview of setting imaging conditions)
The imaging condition in step s2 in FIG. 4 is set so that the entire area of the subject can be accommodated in the depth of field with a smaller number of imaging. First, the computing device 2 calculates whether there is a condition for capturing an image so that the entire area of the subject falls within the depth of field with one imaging. If this condition does not exist, it is calculated whether there is a condition for imaging so that the entire area of the subject is within the depth of field when the number of times of imaging is two. Specifically, it is calculated whether or not there is a condition for imaging so that all the areas that did not fit in the depth of field in the first imaging can fall within the depth of field. Since the imaging data is stored in the storage device for the area that has fallen into the depth of field in the first imaging, it is not always necessary to perform imaging in the second time. If there is no condition for capturing the entire area of the subject within the depth of field even in the case of the two imaging, the number of times is increased in the same manner, and the condition for capturing the entire area of the subject within the depth of field is the same. Calculate if there is. If there is no condition to capture the entire area of the subject within the depth of field even if the predetermined number of times of imaging is reached, the area exceeding the depth is displayed. With respect to the displayed area, it is possible to capture a plurality of images while changing the z-direction position of either the imaging stage or the imaging surface, and obtain an image that falls within the depth of field. However, this method increases the imaging time.

撮像条件の設定における計算で用いられる変数は、撮像用ステージや撮像面、反射部材を駆動する駆動機構の有無や撮像光学系の変倍機能の有無によって異なる。本実施形態では、表面形状計測で得られた標本またはカバーグラスの高さを用いて、被写体に対する小区画の境界位置を設定する。このため、本実施形態では、撮像用ステージがxy平面内で移動する機構を必ず有する。撮像面に関しては、光軸z方向への移動とz軸に対する回転の移動ができる機構を有していることが望ましい。しかし、例えば、撮像面をz軸に対して回転する機構がない場合であってもよい。この場合は、平面フィッティングをシフト成分のCのみを変数にし、チルト成分のGとHをゼロに固定すればよい。   The variables used in the calculation in setting the imaging conditions differ depending on the presence or absence of an imaging stage, imaging surface, drive mechanism for driving the reflecting member, and the presence or absence of a magnification function of the imaging optical system. In the present embodiment, the boundary position of the small section with respect to the subject is set using the height of the sample or the cover glass obtained by the surface shape measurement. For this reason, in this embodiment, the imaging stage always has a mechanism for moving in the xy plane. Regarding the imaging surface, it is desirable to have a mechanism capable of moving in the optical axis z direction and rotating with respect to the z axis. However, for example, there may be a case where there is no mechanism for rotating the imaging surface with respect to the z axis. In this case, the plane fitting may be performed by setting only the shift component C as a variable and fixing the tilt components G and H to zero.

撮像条件の設定について、図5を用いて説明する。ステップs201では、演算装置2は、小区画の境界、zシフト、およびzチルトを変数にした平面フィッティングを全小区画に対して計算する。zシフトは平面のZ方向の位置C、zチルトは(平面のX方向の傾きG,平面のY方向の傾きH)に相当する。ステップs202では、平面フィッティングの全ての残差が被写界深度に収まるかどうかを判定する。収まる場合は撮像条件が設定され終了し、収まらない場合はステップs203に進む。ステップs203では、演算装置2は、深度を超えた領域に対して平面フィッティングを行う。詳細については、後述する。ステップs204では、演算装置2は、平面フィッティングの全ての残差が被写界深度に収まるかどうかを判定する。収まる場合は撮像条件が設定され終了し、収まらない場合はステップs205に進む。ステップs205では、深度を超える領域を表示して終了する。   Setting of imaging conditions will be described with reference to FIG. In step s201, the arithmetic unit 2 calculates the plane fitting using the boundaries of the small sections, the z shift, and the z tilt as variables for all the small sections. The z shift corresponds to the position C in the Z direction on the plane, and the z tilt corresponds to (tilt G in the X direction on the plane, and tilt H in the Y direction on the plane). In step s202, it is determined whether all the residuals of the plane fitting are within the depth of field. If it does not fit, the imaging conditions are set and the process ends. If not, the process proceeds to step s203. In step s203, the arithmetic unit 2 performs plane fitting on the region exceeding the depth. Details will be described later. In step s204, the arithmetic unit 2 determines whether all the residuals of the plane fitting are within the depth of field. If it does not fit, the imaging conditions are set and the process ends. If not, the process proceeds to step s205. In step s205, an area exceeding the depth is displayed and the process ends.

なお、撮像条件の設定について、撮像光学系の変倍機能を有さない場合について説明したが、本発明においては、撮像光学系の変倍機能を備えていなくても影響はない。変倍機能を有する場合は、平面フィッティングの計算において変数に小区画の大きさが加わる。撮像光学系の撮像倍率(拡大倍率)を高くすることで被写体を分割する小区画の大きさを小さくする。ここで撮像面の大きさは一定とする。小区画に含まれる被写体の領域が小さくなるので小区画内の被写体の高さ変化が小さくなる。平面フィッティングする対象である高さの変化が小さくなるので、平面フィッティングの残差も小さくなり、被写界深度に収まる撮像条件を求めることが容易になる。計算の各ステップは、小区画の大きさの変数が増すのみで図5に示したものと同様である。
(撮像条件の設定)
撮像条件の設定では、まず撮像領域全域(全小区画)に対し1回目の平面フィッティングを行い、次に残差が被写界深度に収まらなかった領域に対し2回目の平面フィッティングを行う。2回目の平面フィッティングは2通りの場合がある。1つ目は、2回目の平面フィッティングで1回目の平面フィッティングの境界位置を変えずに、残差が被写界深度に収まらなかった領域のみzシフトとzチルトを変える場合である。2つ目は、2回目の平面フィッティングにおいて1回目の平面フィッティングの境界位置を変化させた上で、残差が被写界深度に収まらなかった領域のzシフトとzチルトを求め直す場合である。これらは、被写体に対する小区画の境界位置を変える場合と変えない場合に相当する。
The setting of the imaging conditions has been described for the case where the imaging optical system does not have a scaling function. However, in the present invention, there is no influence even if the imaging optical system has no scaling function. In the case of having a scaling function, the size of the small section is added to the variable in the calculation of plane fitting. By increasing the imaging magnification (magnification magnification) of the imaging optical system, the size of the small section into which the subject is divided is reduced. Here, the size of the imaging surface is assumed to be constant. Since the area of the subject included in the small section is small, the change in the height of the subject in the small section is small. Since the change in height, which is a target for plane fitting, is small, the residual of the plane fitting is also small, and it is easy to obtain an imaging condition that falls within the depth of field. Each calculation step is the same as that shown in FIG. 5 except that the size of the small section is increased.
(Setting imaging conditions)
In setting the imaging conditions, first, the first plane fitting is performed on the entire imaging area (all small sections), and then the second plane fitting is performed on the area where the residual does not fall within the depth of field. There are two cases of the second plane fitting. The first is a case where the z-shift and the z-tilt are changed only in a region where the residual does not fall within the depth of field without changing the boundary position of the first plane fitting in the second plane fitting. The second is a case where, in the second plane fitting, after changing the boundary position of the first plane fitting, the z shift and the z tilt of the region where the residual does not fall within the depth of field are obtained again. . These correspond to the case where the boundary position of the small section with respect to the subject is changed and the case where it is not changed.

1回目の平面フィッティングで撮像領域全域の残差が被写界深度内に収まる場合を撮像条件の設定法0と呼ぶ。また、残差が被写界深度を超えた領域に対して行う2回目の平面フィッティングにおいて境界位置を変えずにzシフトとzチルトを変化させる場合を撮像条件の設定法1と呼ぶ。一方、残差が被写界深度を超えた領域に対して行う2回目の平面フィッティングにおいて境界位置を変えてzシフトとzチルトを変化させる場合を撮像条件の設定法2と呼ぶ。演算装置2において撮像条件を計算する際には、まず撮像条件の設定法0を計算する。撮像領域全域の残差が被写界深度内に収まらなかった場合には、例えば、撮像条件の設定法1,2の順番で計算し、撮像領域全域の残差が被写界深度内に収まった場合には計算を終了すればよい。撮像条件の設定法0〜2は、撮像光学系が変倍機能を有さない場合に相当する。   The case where the residual of the entire imaging region is within the depth of field in the first plane fitting is called imaging method setting method 0. The case where the z-shift and the z-tilt are changed without changing the boundary position in the second plane fitting performed for the region where the residual exceeds the depth of field is called imaging condition setting method 1. On the other hand, the case where the boundary position is changed and the z shift and the z tilt are changed in the second plane fitting performed on the region where the residual exceeds the depth of field is called imaging condition setting method 2. When calculating the imaging condition in the arithmetic device 2, first, the imaging condition setting method 0 is calculated. If the residual of the entire imaging area does not fit within the depth of field, for example, the imaging condition setting methods 1 and 2 are calculated in order, and the residual of the entire imaging area falls within the depth of field. If so, the calculation may be terminated. The imaging condition setting methods 0 to 2 correspond to the case where the imaging optical system does not have a zoom function.

撮像光学系が変倍機能を有する場合には、小区画の大きさを変化させることができる。撮像光学系の拡大倍率を上げて小区画の大きさを小さくして撮像領域全域を撮像する方法を撮像条件の設定法3と呼ぶ。また、残差が被写界深度を超えた領域がなくなるまで小区画の大きさを小さくして複数回撮像する方法を撮像条件の設定法4と呼ぶ。   When the imaging optical system has a zoom function, the size of the small section can be changed. A method of imaging the entire imaging region by increasing the magnification of the imaging optical system and reducing the size of the small section is called imaging condition setting method 3. Also, a method of imaging a plurality of times by reducing the size of the small section until there is no region where the residual exceeds the depth of field is called imaging condition setting method 4.

撮像条件の設定法0〜4について、図6を用いて説明する。
(撮像条件の設定法0)
撮像条件の設定法0について、図6(a)を用いて説明する。灰色に示した被写体に対して9つの小区画に分割して撮像する方法について説明する。設定法0では、被写体に対する境界の相対位置(x,y)を最適化することで、撮像領域全域の残差が被写界深度に収まる。この場合は例えば図2の構成で、9つの第2の結像光学系を用い、9つの小区画を別々に同時に撮像することができる。つまり、撮像回数は1回である。
(撮像条件の設定法1)
撮像条件の設定法1について、図6(b),(c)を用いて説明する。この方法は、1回目の撮像では撮像領域全域被写体の全領域の残差が被写界深度に収まらない場合に用いられる。つまり、被写体に対する境界B1を最適化しても、1つ以上の高さデータの残差が被写界深度を超えてしまう場合に用いられる。
The imaging condition setting methods 0 to 4 will be described with reference to FIG.
(Imaging condition setting method 0)
The imaging condition setting method 0 will be described with reference to FIG. A method for capturing an image of a subject shown in gray divided into nine small sections will be described. In the setting method 0, the residual of the entire imaging region is within the depth of field by optimizing the relative position (x, y) of the boundary with respect to the subject. In this case, for example, in the configuration of FIG. 2, nine second imaging optical systems can be used, and nine small sections can be imaged separately and simultaneously. That is, the number of times of imaging is one.
(Imaging condition setting method 1)
The imaging condition setting method 1 will be described with reference to FIGS. This method is used when the residual of the entire area of the subject in the entire imaging area does not fall within the depth of field in the first imaging. That is, it is used when the residual of one or more height data exceeds the depth of field even if the boundary B1 for the subject is optimized.

まず、図6(b)に示すように被写界深度を超える残差の数が最小となる境界B1を決定するとともに、境界B1で残差が被写界深度を超える黒色で示した領域N1,N2を特定する。そして、領域N1,N2およびその近傍に対して、領域N1,N2が被写界深度内に収まるように平面フィッティングを再度行う。この際の小区画の大きさは、境界B1の小区画と同じ大きさである。また、小区画の境界B1は変えずに、平面の傾きと位置のみをフィッティング変数にする。つまり、境界B1は不変のもと、領域N1,N2を含む小区画を再度平面フィッティングし直す(図6(c))。なお、領域N1,N2以外の領域は、平面フィッティングの対象ではないので、被写界深度を超えてもよい。
(撮像条件の設定法2)
環境条件の設定法2について、図6(d)〜(g)を用いて説明する。この方法は、撮像条件の設定法1と異なり、再度平面フィッティングし直す際のフィッティング係数として境界も変化させる。
First, as shown in FIG. 6B, a boundary B1 in which the number of residuals exceeding the depth of field is minimized is determined, and a region N1 indicated by black where the residual exceeds the depth of field at the boundary B1. , N2 is specified. Then, plane fitting is performed again on the areas N1 and N2 and the vicinity thereof so that the areas N1 and N2 are within the depth of field. The size of the small section at this time is the same size as the small section of the boundary B1. Further, only the inclination and position of the plane are used as fitting variables without changing the boundary B1 of the small section. That is, the boundary B1 remains unchanged, and the small section including the regions N1 and N2 is subjected to the plane fitting again (FIG. 6C). In addition, since areas other than the areas N1 and N2 are not objects of plane fitting, the depth of field may be exceeded.
(Imaging condition setting method 2)
The environmental condition setting method 2 will be described with reference to FIGS. This method differs from the imaging condition setting method 1 in that the boundary is also changed as a fitting coefficient when the plane fitting is performed again.

まず、被写界深度を超える残差の数が最小となる境界B1を決定する(図6(d))。そして、境界B1で残差が被写界深度を超える領域Er1,Er2およびその近傍に対して、領域Er1,Er2が被写界深度内に収まるように平面フィッティングを再度行う。この際の小区画の大きさは境界B1の小区画と同じ大きさであるが、小区画の境界B1を変化させる。つまり、境界を平面フィッティングの変数にして、領域Er1,Er2を含む小区画を再度、平面フィッティングし直す(図6(e))。   First, the boundary B1 that minimizes the number of residuals exceeding the depth of field is determined (FIG. 6D). Then, the plane fitting is performed again so that the regions Er1 and Er2 fall within the depth of field with respect to the regions Er1 and Er2 where the residual exceeds the depth of field at the boundary B1. The size of the small section at this time is the same size as the small section of the boundary B1, but the boundary B1 of the small section is changed. That is, using the boundary as a variable for plane fitting, the small section including the regions Er1 and Er2 is subjected to plane fitting again (FIG. 6 (e)).

平面フィッティングする対象領域を、データEr1,Er2およびその近傍に限定しない場合も考えられる。被写界深度を超えるデータ数が最小となる境界B1を決定した後、データEr1,Er2を含む小区画の全データを平面フィッティングの対象データとしてもよい。図6(f)は、境界を変化させて小区画の全データを平面フィッティングの対象データとして計算し、境界B3を求めた場合を示している。境界B3では、境界B1で残差が被写界深度を超える領域Er1,Er2が被写界深度内となる。また、境界B3において、領域Er1を含む小区画R21,R22に含まれる全ての残差は被写界深度内に収まる。しかし、境界B3において、領域Er2を含む小区画R23〜R26のうち、小区画R23において、×印で示した領域Er21の残差は被写界深度を超える。この場合は、小区画R23の撮像において、小区画R23の全域のデータを取得した後に領域Er21を削除すればよい。または、領域Er21は、境界B1で撮像する際に取得しているので、領域Er21に相当する図6(g)において黒色で示したD2の部分を撮像しないように(光が入らないように)マスキングして撮像してもよい。このように、本発明は、深度を超えた残差をもつ撮像データに対する処置を含んでいてもよい。
(撮像条件の設定法3)
撮像条件の設定法3について、図6(h)を用いて説明する。この方法では、小区画の大きさを小さくすることで、単一の境界で、被写体の全領域を撮像する。この方法を用いることで、1回の撮像で全領域を撮像できる場合がある。一方、撮像ユニットの高倍化による撮像領域の縮小により、被写体の全領域を撮像できなくなる場合がある。この場合は撮像用ステージを動かして、複数回撮像する必要がある。図6(h)に示した数字は、撮像の順番を示している。1回目の撮像に対して横方向に撮像用ステージを動かして2回目の撮像を行う。そして、1回目の撮像に対して縦方向に撮像用ステージを動かして3回目の撮像を行う。そして、1回目の撮像に対して横方向と縦方向に撮像用ステージを動かして4回目の撮像を行う。撮像する順番は、番号順である必要はない。この方法では、小区画の大きさは、単一の値に決定され、撮像回数の違いで変わることはない。また、全てのフィッティング残差が被写界深度内になるように小区画の大きさを設定するので、同じ領域を重複して撮像することはない。
(撮像条件の設定法4)
撮像条件の設定法4について、図6(i)を用いて説明する。この方法では、同一領域を重複して撮像し、撮像回数の違いで小区画の大きさを変化させる。まず、特定の大きさの小区画を設定し、被写界深度を超える残差が最小となる境界B21をまず決定する。これは撮像条件の設定法1と同じである。そして、境界B21において被写界深度を超える残差を被写界深度に収まるようにする境界B22を決定する。境界B22を決める際に設定する小区画の大きさは、変更可能とする。このことが他の撮像条件の設定法とは異なる。境界B21において被写界深度が超える複数の残差の中には、境界B22に変えて平面フィッティングしても依然として被写界深度を超える残差が含まれる場合がある。この場合はこれらの残差が被写界深度に収まるようにする境界B23を決定する。境界B23を決める際に設定する小区画の大きさは、変更可能とする。このようにして、全ての残差が被写界深度に収まるように、境界を変え、重複して撮像する。境界B22,B23の決定においては、小区画内の残差が全て被写界深度内になるものを選ぶ条件をつけることができる。また、境界B21,B22において被写界深度を超えた残差となる部分のみを境界B22,B23において残差が被写界深度内に収まるようにすれば、小区画内の残差が全て被写界深度内にならなくてもいいとする条件をつけることができる。後者の条件では、境界の採用基準が緩くなり、被写界深度をこえた残差が存在する領域ごとに異なる小区画の大きさを持つ境界が採用されやすくなる。しかし、小区画内にある深度を超えた残差が存在する領域の撮像データを削除する処理が必要になる。このことから撮像方法が複雑化しやすい。小区画内のデータが全て被写界深度内になるものを選ぶ条件をつけると、被写界深度を超えた残差が存在する領域の撮像データを削除する処理が不要になり、撮像方法を簡易化できる。また、小区画の大きさの変化に伴い、撮像データのサンプリングピッチが変化する。このため、たとえばn−1回目とn回目の撮像で得られたデータを等しいサンプリングピッチになるように補間する処理が必要になる。
(撮影条件の設定法のフロー)
撮像条件の設定法1〜4のフローについて、図7〜9を用いて説明する。このフローは、図5のステップs203の詳細に相当する。このため、図5のステップs201の平面フィッティングにおいて、残差が被写界深度を超える領域が決定している。そして、図5のステップs202の判断で残差が被写界深度を超えた領域(例えば、図6(d)の領域Er1,Er2)をA1とする。
It is also conceivable that the target area to be plane-fitted is not limited to the data Er1, Er2 and its vicinity. After determining the boundary B1 that minimizes the number of data exceeding the depth of field, all data of the small sections including the data Er1 and Er2 may be set as the target data for the plane fitting. FIG. 6 (f) shows a case where the boundary B3 is obtained by changing the boundary and calculating all the data of the small sections as the target data for plane fitting. At the boundary B3, the regions Er1 and Er2 whose residuals exceed the depth of field at the boundary B1 are within the depth of field. Further, at the boundary B3, all the residuals included in the small sections R21 and R22 including the region Er1 are within the depth of field. However, in the boundary B3, among the small sections R23 to R26 including the area Er2, in the small section R23, the residual of the area Er21 indicated by the x mark exceeds the depth of field. In this case, in the imaging of the small section R23, the area Er21 may be deleted after the data of the entire area of the small section R23 is acquired. Alternatively, since the area Er21 is acquired when imaging at the boundary B1, the portion of D2 shown in black in FIG. 6G corresponding to the area Er21 is not imaged (so that no light enters). You may image by masking. As described above, the present invention may include a treatment for imaging data having a residual exceeding the depth.
(Imaging condition setting method 3)
The imaging condition setting method 3 will be described with reference to FIG. In this method, the entire area of the subject is imaged at a single boundary by reducing the size of the small section. By using this method, there is a case where the entire region can be imaged by one imaging. On the other hand, there is a case where the entire area of the subject cannot be captured due to the reduction of the imaging area due to the higher magnification of the imaging unit. In this case, it is necessary to move the imaging stage and perform imaging a plurality of times. The numbers shown in FIG. 6H indicate the imaging order. The second imaging is performed by moving the imaging stage in the horizontal direction with respect to the first imaging. Then, the third imaging is performed by moving the imaging stage in the vertical direction with respect to the first imaging. Then, with respect to the first imaging, the imaging stage is moved in the horizontal direction and the vertical direction to perform the fourth imaging. The imaging order need not be in numerical order. In this method, the size of the small section is determined as a single value and does not change depending on the difference in the number of times of imaging. In addition, since the size of the small section is set so that all fitting residuals are within the depth of field, the same region is not duplicated.
(Imaging condition setting method 4)
The imaging condition setting method 4 will be described with reference to FIG. In this method, the same region is imaged twice, and the size of the small section is changed depending on the number of times of imaging. First, a small section having a specific size is set, and a boundary B21 that minimizes the residual exceeding the depth of field is first determined. This is the same as the imaging condition setting method 1. Then, the boundary B22 is determined so that the residual exceeding the depth of field at the boundary B21 falls within the depth of field. The size of the small section set when determining the boundary B22 can be changed. This is different from other imaging condition setting methods. Among the plurality of residuals exceeding the depth of field at the boundary B21, there may be a residual exceeding the depth of field even when the plane fitting is performed instead of the boundary B22. In this case, a boundary B23 is determined so that these residuals fall within the depth of field. The size of the small section set when determining the boundary B23 can be changed. In this way, the boundary is changed so that all the residuals are within the depth of field, and images are taken in duplicate. In the determination of the boundaries B22 and B23, a condition can be set for selecting one in which all the residuals in the small sections are within the depth of field. Further, if only the part that becomes the residual exceeding the depth of field at the boundaries B21 and B22 is set to be within the depth of field at the boundaries B22 and B23, all the residuals in the small sections are covered. A condition can be set that it is not necessary to be within the depth of field. Under the latter condition, the boundary adoption criteria become loose, and it is easy to adopt a boundary having a size of a small partition for each region where there is a residual exceeding the depth of field. However, it is necessary to delete the imaging data of the area where there is a residual exceeding the depth in the small section. For this reason, the imaging method tends to be complicated. If you select a condition that selects all the data in the subdivision within the depth of field, the processing to delete the imaging data in the area where there is a residual exceeding the depth of field becomes unnecessary, and the imaging method It can be simplified. Further, the sampling pitch of the imaging data changes with the change of the size of the small section. For this reason, for example, a process for interpolating the data obtained by the (n−1) -th and n-th imaging so as to have the same sampling pitch is required.
(Flow for setting shooting conditions)
The flow of the imaging condition setting methods 1 to 4 will be described with reference to FIGS. This flow corresponds to the details of step s203 in FIG. For this reason, in the plane fitting in step s201 of FIG. 5, the region where the residual exceeds the depth of field is determined. Then, a region where the residual exceeds the depth of field by the determination in step s202 of FIG. 5 (for example, regions Er1 and Er2 of FIG. 6D) is defined as A1.

まず、撮像条件の設定法1のフローについて、図7を用いて説明する。ステップs101では、1回目(N=1)の撮像で残差が被写界深度を超える領域A1を読み出す。ステップs102では、領域A1における残差の数が最小となる境界を決定する。残差を計算する際に行う平面フィッティングは、領域A1とその近傍のみを平面フィッティングの対象データにする。そして、境界B1を変化させずに、zシフトとzチルトのみを変化させる。ステップs103では、領域A1全域で残差が被写界深度内に収まるかどうかを判定する。収まる場合はステップs104に進み、収まらない場合はs105に進む。ステップs104では、ステップs103において全ての残差が被写界深度内に収まったので、境界位置と撮像面のチルトとシフトと撮像回数を決定する。例えば、図6(b),(c)で示した場合は、まず境界B1で1回目の撮像を行う。次に境界B1のもと領域N1,N2を含む小区画を撮像する際に、物体面と撮像面との光軸方向の相対的な位置と傾きを変えて2回目の撮像をする。すなわち、撮像回数は2回である。ステップs105では、ステップs103において全ての残差が被写界深度内に収まらなかったので、被写界深度内に収まらなかった残差を撮像するため、撮像回数の増加をカウントする。ステップs106では、撮像回数があらかじめ設定した上限を超えたかどうかを判定する。上限を超えていない場合は、ステップs101に進み、以後前述したフローを進む。上限を超えた場合は、ステップs107に進む。ステップs107では、撮像回数が上限を超えた場合に、被写界深度を超える領域を表示すし、終了する。   First, the flow of the imaging condition setting method 1 will be described with reference to FIG. In step s101, an area A1 in which the residual exceeds the depth of field in the first imaging (N = 1) is read. In step s102, a boundary that minimizes the number of residuals in the region A1 is determined. In the plane fitting performed when calculating the residual, only the area A1 and its vicinity are set as the target data for the plane fitting. Then, only the z shift and the z tilt are changed without changing the boundary B1. In step s103, it is determined whether or not the residual is within the depth of field in the entire area A1. If it does not fit, the process proceeds to step s104, and if it does not fit, the process proceeds to s105. In step s104, since all residuals are within the depth of field in step s103, the boundary position, the tilt and shift of the imaging surface, and the number of imaging operations are determined. For example, in the case shown in FIGS. 6B and 6C, first imaging is performed at the boundary B1. Next, when the small section including the areas N1 and N2 under the boundary B1 is imaged, the second imaging is performed by changing the relative position and inclination of the object plane and the imaging plane in the optical axis direction. That is, the number of times of imaging is two. In step s105, since all the residuals did not fall within the depth of field in step s103, an increase in the number of imaging is counted in order to capture the residual that did not fall within the depth of field. In step s106, it is determined whether the number of imaging has exceeded a preset upper limit. If it does not exceed the upper limit, the process proceeds to step s101, and thereafter proceeds to the flow described above. If the upper limit is exceeded, the process proceeds to step s107. In step s107, when the number of times of imaging exceeds the upper limit, an area exceeding the depth of field is displayed and the process ends.

次に、撮像条件の設定法2のフローについて、図7を用いて説明する。ステップs101では、1回目の撮像で残差が被写界深度を超える領域A1を読み出す。ステップs102では、領域A1における残差の数が最小となる境界を決定する。前述したように、撮像条件の設定法2では、境界を境界B1から変化させる。平面フィッティングは、領域A1とその近傍のみを平面フィッティングの対象データに限定する場合と、限定しない場合がある。限定する場合は例えば図6(e)の境界B2に相当し、限定しない場合は例えば図6(f)の境界B3に相当する。仮に図5のステップs201,s202で境界B1を求める際に、境界B1以外の境界の残差が計算されていれば、この計算の結果から、領域A1が最小となる境界を境界B3として読み出してもよい。また、境界B3を改めて計算してもよい。前述したように、境界B3の平面フィッティングの残差において、領域A1以外の残差(例えば、図6(f)のEr21)が被写界深度を超えても、領域A1の残差が被写界深度内に収まれば境界B3として採用することができる。ステップs103では、ステップs102で求めた残差において、領域A1の残差が全て被写界深度内に収まるかどうかを判定する。この後のフローは撮像条件の設定法1と同様である。撮像条件の設定法2では境界が変化するが、小区画の大きさは変化しない。   Next, the flow of the imaging condition setting method 2 will be described with reference to FIG. In step s101, the area A1 in which the residual exceeds the depth of field in the first imaging is read. In step s102, a boundary that minimizes the number of residuals in the region A1 is determined. As described above, in the imaging condition setting method 2, the boundary is changed from the boundary B1. In the plane fitting, there are cases where only the area A1 and its vicinity are limited to the target data of the plane fitting, and there are cases where it is not limited. In the case of limitation, for example, it corresponds to the boundary B2 in FIG. 6 (e), and in the case of not limiting, for example, it corresponds to the boundary B3 in FIG. 6 (f). If the boundary residual other than the boundary B1 is calculated when the boundary B1 is obtained in steps s201 and s202 in FIG. 5, the boundary where the region A1 is minimum is read out as the boundary B3 from the result of this calculation. Also good. Further, the boundary B3 may be calculated again. As described above, in the residual of the plane fitting at the boundary B3, even if the residual other than the area A1 (for example, Er21 in FIG. 6F) exceeds the depth of field, the residual in the area A1 is not captured. If it falls within the depth of field, it can be adopted as the boundary B3. In step s103, it is determined whether all the residuals in the area A1 fall within the depth of field in the residuals obtained in step s102. The subsequent flow is the same as the imaging condition setting method 1. In the imaging condition setting method 2, the boundary changes, but the size of the small section does not change.

次に、撮像条件の設定法3のフローについて、図8を用いて説明する。ステップs301では、平面フィッティングする領域を全領域に指定する。これは、平面フィッティングをする対象データを、例えば被写界深度を超えた残差など一部に限定しないという意味である。フィッティングする平面は小区画毎に別々である。ステップs302では、小区画の大きさを設定する。ステップs303では、撮像回数があらかじめ決めた上限を超えたかどうかを判断する。小区画の大きさによっては、1回で全領域を撮像できない場合がある。小区画の大きさ(撮影倍率)にしたがって、撮像回数が決まる。例えば、図6(h)では、4回と決まる。上限を超えていない場合はステップs304に進み、上限を超えた場合はステップs308に進む。ステップs308では、被写界深度を超える残差が存在する領域を表示し、終了する。ステップs304では、小区画の境界を設定する。ステップs305では、全ての小区画を平面フィッティングし、残差を計算する。ステップs306では、全ての残差が被写界深度内に収まっているかどうかを判断する。全ての残差が被写界深度内に収まる場合はステップs307に進み、収まらない場合はステップs302に進み、小区画の大きさを設定し直し、同様のフローを繰り返す。この際、平面フィッティングする領域は常に全領域である。ステップs307では、全領域共通の小区画の大きさをもつ境界と、平面の位置と傾きを決定し、終了する。   Next, the flow of the imaging condition setting method 3 will be described with reference to FIG. In step s301, the area for plane fitting is designated as the entire area. This means that the target data to be plane-fitted is not limited to a part such as a residual exceeding the depth of field. The plane to be fitted is different for each small section. In step s302, the size of the small section is set. In step s303, it is determined whether the number of times of imaging exceeds a predetermined upper limit. Depending on the size of the small section, it may not be possible to capture the entire region at one time. The number of times of imaging is determined according to the size of the small section (imaging magnification). For example, in FIG. 6 (h), it is determined as 4 times. If the upper limit is not exceeded, the process proceeds to step s304, and if the upper limit is exceeded, the process proceeds to step s308. In step s308, an area where there is a residual exceeding the depth of field is displayed and the process ends. In step s304, the boundaries of the small sections are set. In step s305, all the small sections are plane-fitted and the residual is calculated. In step s306, it is determined whether all the residuals are within the depth of field. If all the residuals are within the depth of field, the process proceeds to step s307. If not, the process proceeds to step s302, the size of the small section is reset, and the same flow is repeated. At this time, the area for plane fitting is always the entire area. In step s307, the boundary having the size of the small section common to all regions, the position and the inclination of the plane are determined, and the process ends.

次に、撮像条件の設定法4のフローについて、図9を用いて説明する。ステップs401では、1回目の撮像の被写界深度を超える領域A1を読み出す。ステップs402では、小区画の大きさを設定する。ステップs403では、領域A1を小区画に分割する境界を設定する。ステップs403では、平面フィッティングの残差を計算する。ステップs405では、被写界深度を超えた残差を被写界深度内にする境界があるかどうかを判定する。判定の際には、小区画内のデータが全て被写界深度内になる境界に限定するという条件をつけることができる。この条件で小区画内にある被写界深度を超えた残差をもつデータを削除する処理が割愛できる。また、被写界深度を超えたデータを被写界深度内にすれば、小区画内のデータが全て被写界深度内にならなくてもよいとする条件をつけることも可能である。こうした条件を満たす境界がない場合はステップs402に戻り、こうした条件を満たす境界がある場合はステップs406に進む。ステップs406では、領域A1の全てのフィッティング残差が被写界深度内に収まるかどうかを判定する。収まる場合は、ステップs407で境界と平面の位置と傾きと撮像回数を決定し、終了する。収まらない場合は、ステップs408に進む。ステップs408では、撮像回数のカウントNを1つ増加する。ステップs409では、撮像回数が上限を超えたかどうかを判定する。上限を超えた場合は、ステップs410でフィッティング残差が被写界深度を超える領域を表示し、終了する。上限を超えない場合は、ステップs402に戻り、以下同様のフローを繰り返す。   Next, the flow of the imaging condition setting method 4 will be described with reference to FIG. In step s401, an area A1 exceeding the depth of field of the first imaging is read out. In step s402, the size of the small section is set. In step s403, a boundary for dividing the area A1 into small sections is set. In step s403, the residual of the plane fitting is calculated. In step s405, it is determined whether there is a boundary that makes the residual exceeding the depth of field within the depth of field. At the time of determination, it is possible to set a condition that the data within the small section is limited to a boundary within the depth of field. Under this condition, the process of deleting data having a residual exceeding the depth of field in the small section can be omitted. Further, if data exceeding the depth of field is within the depth of field, it is possible to set a condition that all the data in the small section need not be within the depth of field. If there is no boundary satisfying these conditions, the process returns to step s402. If there is a boundary satisfying these conditions, the process proceeds to step s406. In step s406, it is determined whether all the fitting residuals in the area A1 fall within the depth of field. If it falls within the range, in step s407, the boundary, the position and inclination of the plane, and the number of times of imaging are determined, and the process ends. If not, the process proceeds to step s408. In step s408, the count N of the number of imaging is increased by one. In step s409, it is determined whether the number of imaging has exceeded the upper limit. If the upper limit is exceeded, an area where the fitting residual exceeds the depth of field is displayed in step s410, and the process ends. If the upper limit is not exceeded, the process returns to step s402, and the same flow is repeated thereafter.

本実施例では、撮像条件の設定法0に関して詳しく説明する。   In this embodiment, the imaging condition setting method 0 will be described in detail.

まず、図4のステップs1では、表面形状計測で物体の高さを取得する。表面形状計測で得た高さを補完してデータ数を増す補完処理を行ってもよい。本実施例では、補完処理は割愛する。表面形状計測で得た高さを図10に示す。高さは、0.25mm刻みで得られている。   First, in step s1 of FIG. 4, the height of the object is acquired by surface shape measurement. Complement processing for increasing the number of data by complementing the height obtained by the surface shape measurement may be performed. In this embodiment, the complement process is omitted. The height obtained by the surface shape measurement is shown in FIG. The height is obtained in increments of 0.25 mm.

次に、図4のステップs2に進み、小区画の大きさ、撮像位置、傾きの最適化を行う。本実施例では、被写体の大きさは、物体面上において10mm×10mmとする。この被写体を2mm×2mmの小区画に分割して撮像する。1つの小区画に相当する領域を1つの撮像素子で撮像する。撮像素子の撮像面の大きさは40mm×40mmで、撮像倍率は20倍である。2mm×2mmの小区画には、9×9=81個の高さデータがある。境界は81通り変化させることができる。被写体に対して境界位置を最適化する際に、境界は最大で小区画1つ分ずれる。このため、被写体の大きさと、境界が最大で小区画1つ分ずれることを考え、撮像ユニット300は12mm×12mmの範囲を撮像できるものとする。全領域を撮像した場合には、36個の小区画が撮像される。本実施例では、表面形状計測で得た高さと平面フィッティングした近似高さとの差を残差として評価する。被写界深度Dは、本実施例において、以下の式で算出される。k2は定数、λは使用波長、NAは撮像ユニットの物体側開口数である。なお、被写体深度は、計算者が任意に設定してもよい。   Next, the process proceeds to step s2 in FIG. 4 to optimize the size of the small section, the imaging position, and the inclination. In this embodiment, the size of the subject is 10 mm × 10 mm on the object plane. The subject is imaged by dividing it into small sections of 2 mm × 2 mm. An area corresponding to one small section is imaged by one image sensor. The size of the imaging surface of the imaging device is 40 mm × 40 mm, and the imaging magnification is 20 times. There are 9 × 9 = 81 pieces of height data in a 2 mm × 2 mm small section. The boundary can be changed in 81 ways. When the boundary position is optimized with respect to the subject, the boundary is shifted by one small section at the maximum. For this reason, it is assumed that the imaging unit 300 can capture a range of 12 mm × 12 mm in consideration of the size of the subject and the boundary being shifted by one small section at the maximum. When the entire area is imaged, 36 small sections are imaged. In this embodiment, the difference between the height obtained by surface shape measurement and the approximate height obtained by plane fitting is evaluated as a residual. In this embodiment, the depth of field D is calculated by the following equation. k2 is a constant, λ is a used wavelength, and NA is an object-side numerical aperture of the imaging unit. Note that the subject depth may be arbitrarily set by the calculator.

本実施例では、k2=1.0、λ=0.54μm、NA=0.6としているため、被写界深度は物体面上においてD=±1.5μmとなる。   In this embodiment, since k2 = 1.0, λ = 0.54 μm, and NA = 0.6, the depth of field is D = ± 1.5 μm on the object plane.

図5のステップs201では、小区画の境界を設定し、残差を計算する。本実施形態では、境界を81通り変化させて、それぞれの境界で全領域を平面フィッティングし、残差が被写界深度(1.5μm)を超えるデータ数を取得する。   In step s201 of FIG. 5, the boundaries of the small sections are set, and the residual is calculated. In the present embodiment, 81 boundaries are changed, and the whole area is planarly fitted at each boundary, and the number of data whose residual exceeds the depth of field (1.5 μm) is acquired.

なお、境界(被写体と境界の相対位置)は、例えば最急降下法などを用いて変化させるなど様々な方法が適用可能である。最急降下法を利用する場合、まず、データ位置(X,Y)と境界位置(m,n)と平面の傾きと位置(G,H,C)を変数にもつ平面近似した高さPを求める。そして、高さPと表面形状計測で得られた高さZとの残差Eを求める。そして、残差Eを各変数で微分し、残差が小さくなる方向に最も大きく変化する向きに各変数を微小量変化させる。このようにして、残差が最小となる変数の組を決定する。   Note that various methods such as changing the boundary (relative position between the subject and the boundary) using, for example, the steepest descent method can be applied. When using the steepest descent method, first, a plane approximation height P having the data position (X, Y), boundary position (m, n), plane inclination and position (G, H, C) as variables is obtained. . Then, a residual E between the height P and the height Z obtained by the surface shape measurement is obtained. Then, the residual E is differentiated by each variable, and each variable is changed by a minute amount in the direction in which the residual changes most greatly in the direction in which the residual becomes smaller. In this way, the set of variables that minimizes the residual is determined.

本実施例では深度を超える残差の数がゼロとなる境界が算出され、その結果を図11に示す。図11(a)は、表面形状計測値に初期境界の境界線を重ねて示したものである。図11(b)は、被写界深度を超える残差の数がゼロとなるような境界の境界線を重ねて示したものである。   In this embodiment, a boundary where the number of residuals exceeding the depth is zero is calculated, and the result is shown in FIG. FIG. 11A shows an initial boundary line superimposed on the surface shape measurement value. FIG. 11B shows the boundary lines of the boundary such that the number of residuals exceeding the depth of field is zero.

図5のステップs202では、全ての残差が被写界深度内に収まるので、撮像条件の設定を終了する。境界位置とフィッティングした平面の傾き(式(1)のG,H)と光軸方向に対する位置(式(1)のC)が決まる。撮像回数は1回である。   In step s202 of FIG. 5, since all the residuals are within the depth of field, the setting of the imaging conditions is ended. The boundary position and the slope of the fitted plane (G, H in equation (1)) and the position with respect to the optical axis direction (C in equation (1)) are determined. The number of imaging is one.

次に、図4のステップs3の分割撮像を行う。ここでは、図2の撮像ユニットを考える。図4のステップs2で決定した境界の位置に合わせて、撮像用ステージ501を動かして被写体をxy平面上で移動させる。さらに、各小区画の平面フィッティングの結果である平面の傾きと光軸に対する位置(式(1)のG,H,C)に対応して、反射部材503,506の位置と傾きについて、駆動部512,513を用いて調整する。xz面内の傾きGとyz面内の傾きHはともに±2mradの範囲である。また、z方向の高さの調整量は、物体側で±5μmの範囲である。像側で相対位置を調整する場合には倍率を考慮する。こうして、被写体と撮像面の相対位置を調整したうえで、第2撮像光学系504,507を用いて、小区画毎に独立して同時に撮像する。このようにして、境界(図11(b))に対応する被写体位置と撮像素子との相対位置で、被写体全域を分割撮像する。   Next, divided imaging in step s3 in FIG. 4 is performed. Here, the imaging unit of FIG. 2 is considered. The imaging stage 501 is moved in accordance with the boundary position determined in step s2 in FIG. 4 to move the subject on the xy plane. Further, the drive unit is configured to determine the position and inclination of the reflecting members 503 and 506 corresponding to the inclination of the plane and the positions relative to the optical axis (G, H, and C in Expression (1)) as a result of the plane fitting of each small section. Adjust using 512,513. Both the inclination G in the xz plane and the inclination H in the yz plane are within a range of ± 2 mrad. The height adjustment amount in the z direction is in the range of ± 5 μm on the object side. When adjusting the relative position on the image side, the magnification is taken into consideration. In this way, after adjusting the relative position of the subject and the imaging surface, the second imaging optical systems 504 and 507 are used to capture images independently for each of the small sections. In this manner, the entire subject is divided and imaged at the relative position between the subject position corresponding to the boundary (FIG. 11B) and the image sensor.

次に、図4のステップs4のデータ取り込みを行う。ステップs4では、ステップs3で撮像した部分画像のデータを取り組む。そして、小区画の画像を合成する(つなぎ合わせる)。必要に応じて、図1の表示装置3を用いて画像や解析結果などを表示する。そして、画像データを記憶装置に格納し、終了する。   Next, the data capture in step s4 of FIG. 4 is performed. In step s4, the data of the partial image captured in step s3 is tackled. Then, the images of the small sections are synthesized (joined together). If necessary, an image, an analysis result, etc. are displayed using the display device 3 of FIG. Then, the image data is stored in the storage device, and the process ends.

本実施例では、撮像条件の設定法2に関して詳しく説明する。図5のステップs202において、深度を超えるフィッティング残差があった場合に相当する。   In the present embodiment, the imaging condition setting method 2 will be described in detail. This corresponds to the case where there is a fitting residual exceeding the depth in step s202 of FIG.

本実施例では、実施例1と同じ表面形状計測値とする。また、本実施例では、k2=1.0、λ=0.54μm、NA=0.73としているため、被写界深度は物体面上においてD=±1.0μmとなる。   In this embodiment, the surface shape measurement value is the same as that in the first embodiment. In this embodiment, since k2 = 1.0, λ = 0.54 μm, and NA = 0.73, the depth of field is D = ± 1.0 μm on the object plane.

実施例1と同様に、境界を81通り変化させたところ、境界B79〜B81の3つが被写界深度を超える残差が存在する小区画の数が1で最小となった。全ての小区画のフィッティング残差が深度内に入る境界はない。つまり、図6(a)で示した1回撮像では全領域を被写界深度内に撮像することはできない。   As in Example 1, when the boundary was changed in 81 ways, the number of small sections in which three of the boundaries B79 to B81 had a residual exceeding the depth of field was 1, which was the smallest. There is no boundary where the fitting residuals of all sub-parts fall within the depth. That is, the entire region cannot be imaged within the depth of field by the single imaging shown in FIG.

図7のステップs101では、1回目の撮像でフィッティング残差が深度を超える領域A1を読み出す。本実施例では、1回目の撮像において、境界B79〜B81の3つにおいて、被写界深度を超える残差の数が最も少ない。ここでは、被写界深度を超える残差の数のみでなく残差の量も考慮して、フィッティング残差の量が最小の境界B80を選び、境界B80の領域A1を読み出す。被写界深度を超える5つの残差の位置を図12に×印で示した。図12には、被写体121、および小区画の境界B80が示されている。被写界深度を超える5つの残差は、全て1つの小区画B80R1に存在する。小区画B80R1の残差の値を図13に示した。数値の単位はμmである。5つの残差E1〜E5が被写界深度を超えている。   In step s101 of FIG. 7, the region A1 where the fitting residual exceeds the depth is read out in the first imaging. In the present embodiment, in the first imaging, the number of residuals exceeding the depth of field is the smallest at the three boundaries B79 to B81. Here, considering not only the number of residuals exceeding the depth of field but also the amount of residuals, the boundary B80 having the smallest amount of fitting residuals is selected, and the region A1 of the boundary B80 is read. The positions of the five residuals exceeding the depth of field are indicated by crosses in FIG. FIG. 12 shows a subject 121 and a small section boundary B80. All of the five residuals exceeding the depth of field exist in one small section B80R1. The residual value of the small section B80R1 is shown in FIG. The unit of the numerical value is μm. The five residuals E1 to E5 exceed the depth of field.

図7のステップs102では、5つの残差E1〜E5のうちより多くの残差が被写界深度に収まる境界を決定する。本実施例では、図5のステップs201,s202で既に計算された境界の残差の情報を用いて決めることができる。本実施例では、境界B72において5つのフィッティング残差全てが深度内にフィッティングされる。図14に境界B72と境界B80との相対位置を示す。境界B80では1つの小区画内にあった被写界深度を超えた5つの残差は、境界B72では2つの小区画B72R1,B72R2に分布している。図15(a)には、境界B72における小区画B72R1の残差の値が示されている。数値の単位はμmである。境界B80において被写界深度を超えた残差E1〜E3が全て被写界深度内に収まっているとともに、小区画の全ての残差が深度内に収まっている。図15(b)には、境界B72における小区画B72R2の残差の値が示されている。境界B80において被写界深度を超えた残差E4,E5の両方が被写界深度内に収まっている。一方、破線部E21,E22で示した7個の残差が深度を超えている。しかし、これらのデータは、境界B80で被写界深度内にフィッティングできたデータである。   In step s102 of FIG. 7, a boundary where more of the five residuals E1 to E5 are within the depth of field is determined. In the present embodiment, the determination can be made using the boundary residual information already calculated in steps s201 and s202 of FIG. In the present embodiment, all five fitting residuals are fitted within the depth at the boundary B72. FIG. 14 shows the relative positions of the boundary B72 and the boundary B80. The five residuals exceeding the depth of field that existed in one small section at the boundary B80 are distributed in two small sections B72R1 and B72R2 at the boundary B72. FIG. 15A shows the residual value of the small section B72R1 at the boundary B72. The unit of the numerical value is μm. All of the residuals E1 to E3 exceeding the depth of field at the boundary B80 are within the depth of field, and all the residuals of the small sections are within the depth. FIG. 15B shows the residual value of the small section B72R2 at the boundary B72. Both of the residuals E4 and E5 exceeding the depth of field at the boundary B80 are within the depth of field. On the other hand, the seven residuals indicated by the broken lines E21 and E22 exceed the depth. However, these data are data that can be fitted within the depth of field at the boundary B80.

図7のステップs103では、領域A1全域の残差、つまり5つの残差E1〜E5が被写界深度内に収まるかどうかを判定する。前述したように、5つの残差E1〜E5は、境界B80と境界B72の2つの境界を用いることで、全てが被写界深度内に収まる。   In step s103 in FIG. 7, it is determined whether or not the residuals in the entire area A1, that is, the five residuals E1 to E5 are within the depth of field. As described above, the five residuals E1 to E5 are all within the depth of field by using the two boundaries of the boundary B80 and the boundary B72.

図7のステップs104では、境界の位置と傾きと撮像回数を決定する。境界の位置は、境界B80と境界B72に決まる。平面の位置と傾きは平面フィッティングで得られた結果(式(1)のG,H,C)を採用する。これは、境界B80では、36個全ての小区画毎に異なる位置と傾きになる。境界B72では、境界B80で深度を超えたデータのみを撮像すれば十分なので小区画B72R1,B72R2の2つの平面の位置と傾きで足りる。撮像回数は、境界B80の撮像と境界B72の撮像の2回となる。   In step s104 in FIG. 7, the position and inclination of the boundary and the number of imaging are determined. The position of the boundary is determined by the boundary B80 and the boundary B72. For the position and inclination of the plane, the results obtained by plane fitting (G, H, C in equation (1)) are adopted. In the boundary B80, the position and inclination are different for all 36 small sections. At the boundary B72, it is sufficient to image only the data exceeding the depth at the boundary B80, so the positions and inclinations of the two planes of the small sections B72R1 and B72R2 are sufficient. The number of times of imaging is two times of imaging of the boundary B80 and imaging of the boundary B72.

以上で撮像条件の設定法2が終了する。   Thus, the imaging condition setting method 2 is completed.

この後の分割撮像以降のフローは、分割撮像の回数が変わるのみで、実施例1と同様である。実施例1と同様に、境界B80に対応して、被写体位置と反射部材の位置と傾きを調整して撮像する。そして、境界B72に対応して、被写体位置と反射部材の位置と傾きを新たに調整して、2回目の撮像を行う。2回目の撮像では、前述したように小区画B72R1,B72R2の2つの区画のみ撮像すればよい。もちろん全領域撮像しても構わない。小区画B72R2の撮像においては、図15(b)に示した破線部E21,E22の7個のデータを撮像しないように撮像面にマスキングを施してもよい。また、破線部E21,E22の7個のデータを含めて撮像して、図4のステップs4におけるデータ取り込みで、破線部E21,E22の7個のデータを削除してもよい。   The subsequent flow after divided imaging is the same as that of the first embodiment except that the number of times of divided imaging is changed. Similar to the first embodiment, the subject position and the position and inclination of the reflecting member are adjusted corresponding to the boundary B80 to capture an image. Then, in response to the boundary B72, the subject position and the position and inclination of the reflecting member are newly adjusted, and the second imaging is performed. In the second imaging, only the two sections B72R1 and B72R2 need be imaged as described above. Of course, the entire area may be imaged. In imaging of the small section B72R2, the imaging surface may be masked so that the seven data of the broken line portions E21 and E22 shown in FIG. Alternatively, the seven data of the broken line portions E21 and E22 may be imaged, and the seven data of the broken line portions E21 and E22 may be deleted by capturing the data in step s4 in FIG.

実施例3では、撮像条件の設定法4に関して詳しく説明する。   In the third embodiment, the imaging condition setting method 4 will be described in detail.

表面形状計測で得た高さを図16に示す。高さは、0.25mm刻みのデータとして得られている。小区画の大きさを実施例1と同様に2mm×2mmとする。1つの小区画には9×9=81個のデータが含まれる。撮像ユニットが撮像可能な範囲は、12mm×12mmである。本実施例では、実施例2と同様に被写界深度は物体面上において±1.0μmとする。また、表面形状計測で得た高さと平面フィッティングした近似高さとの差を残差として評価する。   FIG. 16 shows the height obtained by the surface shape measurement. The height is obtained as data in increments of 0.25 mm. The size of the small section is 2 mm × 2 mm as in the first embodiment. One small section includes 9 × 9 = 81 pieces of data. The range that can be imaged by the imaging unit is 12 mm × 12 mm. In the present embodiment, as in the second embodiment, the depth of field is set to ± 1.0 μm on the object plane. Further, the difference between the height obtained by the surface shape measurement and the approximate height obtained by plane fitting is evaluated as a residual.

図17には、被写体191、および境界B301が示されている。被写界深度内に収まらない残差を含む小区画(B301R1,B301R2,B301R3)は濃い灰色で示されている。これら3つの小区画の残差の値を図18に示す。被写界深度内に収まらない残差を楕円で囲って示した。被写界深度内に収まらない残差は、主に小区画の端に集まっている。被写界深度内に収まらないフィッティング残差は18個ある。   FIG. 17 shows a subject 191 and a boundary B301. Subsections (B301R1, B301R2, B301R3) that contain residuals that do not fit within the depth of field are shown in dark gray. The residual values of these three subdivisions are shown in FIG. Residuals that do not fit within the depth of field are shown enclosed in ellipses. Residuals that do not fit within the depth of field are gathered mainly at the edge of the subdivision. There are 18 fitting residuals that do not fit within the depth of field.

図9のステップs401で1回目の撮像の被写界深度が超える領域A1を読み出す。領域A1は、図17の3つの小区画(B301R1,B301R2,B301R3)である。   In step s401 of FIG. 9, the area A1 that exceeds the depth of field of the first imaging is read out. The area A1 is the three small sections (B301R1, B301R2, B301R3) in FIG.

ステップs402では、小区画の大きさを設定する。本実施例では、小区画の大きさを1.75mm×1.75mmとした。これは、小区画に含まれるデータが8×8=64個になる大きさである。   In step s402, the size of the small section is set. In this example, the size of the small section was 1.75 mm × 1.75 mm. This is the size of 8 × 8 = 64 data contained in the small section.

ステップs403では領域A1を分割する小区画の境界を設定し、ステップs404では残差を計算する。   In step s403, the boundaries of the small sections that divide the area A1 are set, and in step s404, the residual is calculated.

ステップs405では、被写界深度を超えた残差を被写界深度内にする境界があるかどうかを判定する。この判定の際、本実施例では、小区画内のデータが全て被写界深度内に収まる条件をつけた。この条件について具体的に説明する。例えば、領域A1の被写界深度を超える残差が18個である場合、このうち1つの残差N31を被写界深度内に収める境界B31が求まるとする。この境界B31において、残差N31を含む小区画がR31であるとき、小区画R31に含まれる全ての残差は被写界深度内に収まらなければならないというのが条件の内容である。境界B31はこのように1つの被写界深度を超える残差(N31)を被写界深度内に収まれば条件を満たす。本実施例では、他の17個の被写界深度を超える残差が被写界深度内に収まらなくてもステップs406に進む。   In step s405, it is determined whether there is a boundary that makes the residual exceeding the depth of field within the depth of field. In this determination, in this embodiment, a condition is set in which all the data in the small section is within the depth of field. This condition will be specifically described. For example, when there are 18 residuals exceeding the depth of field in the area A1, it is assumed that a boundary B31 that can accommodate one of the residuals N31 within the depth of field is obtained. In the boundary B31, when the small section including the residual N31 is R31, the condition is that all the residuals included in the small section R31 must be within the depth of field. The boundary B31 satisfies the condition if the residual (N31) exceeding one depth of field falls within the depth of field in this way. In the present embodiment, the process proceeds to step s406 even if the residuals exceeding the other 17 depths of field do not fall within the depth of field.

ステップs406では、領域A1の18個全ての被写界深度を超える残差が被写界深度内に収まっていないと判断される。そのため、小区画に含まれるデータが小さくなるように小区画の大きさを小さくし、1.25mm×1.25mmの大きさで、小区画内の全ての残差が被写界深度内になる。全ての残差が被写界深度内に収まる境界は複数存在するので、ここでは、被写界深度を超えた残差を撮像するのに要する小区画の数が最小となる境界を選択する。この境界を図19に境界B302として示す。境界B301において、被写界深度内に収まらない残差を含む小区画(領域A3)を図17と同様に小区画(B301R1,B301R2,B301R3)で濃い灰色で示してある。倍率を上げることで、小区画36個で撮像できる被写体領域は7.50mm×7.50mmに小さくなるが、境界B302で領域A3を1回で撮像できる。領域A3の境界B302における残差の値を図20に示した。単位はμmである。例えば、小区画B302R1において、楕円で囲った被写界深度を超える残差が深度内の−0.53になり、かつ小区画B302R1内の全ての残差が被写界深度内に収まっている。このことから、ステップs406に進む。   In step s406, it is determined that the residuals that exceed all 18 depths of field in area A1 do not fall within the depth of field. Therefore, the size of the small section is reduced so that the data included in the small section is small, and the size of 1.25 mm × 1.25 mm, and all residuals in the small section are within the depth of field. . Since there are a plurality of boundaries where all the residuals fall within the depth of field, a boundary that minimizes the number of small sections required to image the residual exceeding the depth of field is selected here. This boundary is shown as a boundary B302 in FIG. In the boundary B301, the small sections (region A3) including the residual that does not fall within the depth of field are shown in dark gray in the small sections (B301R1, B301R2, B301R3) as in FIG. By increasing the magnification, the subject area that can be imaged by 36 small sections is reduced to 7.50 mm × 7.50 mm, but the area A3 can be imaged once at the boundary B302. The residual value at the boundary B302 of the region A3 is shown in FIG. The unit is μm. For example, in the small section B302R1, the residual exceeding the depth of field surrounded by the ellipse is −0.53 within the depth, and all the residuals within the small section B302R1 are within the depth of field. . Accordingly, the process proceeds to step s406.

ステップs406では、領域A3の18個全ての被写界深度を超える残差が被写界深度内に収まっていると判断されるので、ステップs407に進む。   In step s406, since it is determined that the residuals exceeding all 18 depths of field in area A3 are within the depth of field, the process proceeds to step s407.

ステップs407では、境界と平面の位置と傾きと撮像回数を決定する。境界は、境界B301,B302を用いる。それぞれの境界において、平面フィッティングを計算した結果から平面の位置と傾き(式(1)のG,H,C)は決定している。撮像用ステージと反射部材の位置を調整することで、境界B301に対応するように被写体と撮像面の相対位置を設定し、1回撮像する。そして、被写界深度を超える18個の残差を含む領域A3を、境界B302に対応するように、撮像倍率を20倍から32倍にした後、撮像用ステージと反射部材の位置を調節することで被写体と撮像面の相対位置を設定し2回目の撮像を行う。このとき、前述したように1回の撮像で領域A1の全域を撮像できる。つまり、境界B301の1回と境界B302の1回の計2回が撮像回数となる。この後の分割撮像以降のフローは、分割撮像の回数が変わるのみで、実施例1と同様である。   In step s407, the position and inclination of the boundary and the plane, and the number of times of imaging are determined. As the boundaries, boundaries B301 and B302 are used. At each boundary, the plane position and inclination (G, H, C in equation (1)) are determined from the result of calculating the plane fitting. By adjusting the positions of the imaging stage and the reflecting member, the relative position between the subject and the imaging surface is set so as to correspond to the boundary B301, and imaging is performed once. Then, after the imaging magnification is increased from 20 times to 32 times so that the area A3 including 18 residuals exceeding the depth of field corresponds to the boundary B302, the positions of the imaging stage and the reflecting member are adjusted. Thus, the relative position between the subject and the imaging surface is set, and the second imaging is performed. At this time, as described above, the entire area A1 can be imaged by one imaging. That is, the number of times of imaging is two times, one time at the boundary B301 and one time at the boundary B302. The subsequent flow after divided imaging is the same as that of the first embodiment except that the number of times of divided imaging is changed.

図2の第1の結像光学系502の倍率を変えずに、第2の結像光学系504,507の倍率を変えることで、撮像倍率を32倍にする場合を考える。このとき第2の結像光学系504,507の像側のNAを変えずに、物体側のNAを変えることで変倍すれば、変倍が第2の結像光学系504,507の撮像面の移動量に影響を及ぼすことはない。第2の結像光学系504,507の物体面にある反射部材503,506の光軸方向の移動量と光軸に対する傾きを調整することで境界B302の境界に対応するように被写体と撮像面の相対位置を設定できる。   Consider a case where the imaging magnification is set to 32 times by changing the magnification of the second imaging optical systems 504 and 507 without changing the magnification of the first imaging optical system 502 in FIG. At this time, if the magnification is changed by changing the NA on the object side without changing the NA on the image side of the second imaging optical systems 504 and 507, the magnification is picked up by the second imaging optical systems 504 and 507. The amount of movement of the surface is not affected. The subject and the imaging surface are adjusted so as to correspond to the boundary of the boundary B302 by adjusting the movement amount in the optical axis direction of the reflecting members 503 and 506 on the object plane of the second imaging optical systems 504 and 507 and the inclination with respect to the optical axis. The relative position of can be set.

なお、本実施例では、小区画の大きさを変えても、被写界深度を超える残差は、表面形状計測で得た高さと平面フィッティングした近似高さとの差が1μmを超えるものとした。しかし、例えば撮像倍率を大きくして小区画の大きさを小さくする場合、この条件を倍率に応じて変えてもよい。許容できる残差の量は、被写界深度によらず計算者が任意に設定できる。   In the present embodiment, even if the size of the small section is changed, the difference exceeding the depth of field is such that the difference between the height obtained by the surface shape measurement and the approximate height obtained by plane fitting exceeds 1 μm. . However, for example, when the imaging magnification is increased to reduce the size of the small section, this condition may be changed according to the magnification. The amount of residual that can be allowed can be arbitrarily set by the calculator regardless of the depth of field.

また、本実施例では、境界B302で、領域A1のみでなく被写体の全領域を被写界深度内に撮像できる。境界B301で撮像せずに、境界B302のみを用いた撮像で全領域を撮像する場合は、図19からわかるように、4回撮像することになる。これは図6(h)で示した撮像条件の設定法3の場合の解である。撮像条件の設定法4の解を得た後に、撮像条件の設定法3を行い、より少ない回数の撮像方法を選んでもよい。   In this embodiment, not only the area A1 but also the entire area of the subject can be imaged within the depth of field at the boundary B302. When the entire region is imaged by imaging using only the boundary B302 without imaging at the boundary B301, imaging is performed four times as can be seen from FIG. This is a solution in the case of the imaging condition setting method 3 shown in FIG. After obtaining the solution of the imaging condition setting method 4, the imaging condition setting method 3 may be performed to select an imaging method with a smaller number of times.

また、本実施例では、小区画の大きさを小区画に含まれるデータ数が少なくなるように徐々に小さくしたが、これ以外の方法も考えられる。例えば、表面形状計測で得た高さデータの空間周波数情報から、x,y方向の周期情報を得て、周期情報に基づいて大きさを決定することが考えられる。また、表面形状計測で得た高さデータの変化量が一定値未満になるように大きさを決定することも考えられる。また、勾配法(最急降下法)を利用することも考えられる。最急降下法を利用する場合には、以下のように計算する。データ位置(X,Y)と境界位置(m,n)と平面の傾きと位置(G,H,C)と小区画の大きさ(R)を変数に持つ平面近似した高さPを求める。そして、Pと表面形状計測で得られた高さZとの残差Eを求める。次に残差Eを各変数で微分し、残差が小さくなる方向に最も大きく変化する向きに各変数を微小量変化させる。このようにして、残差が最小となる変数の組を決定する。   In the present embodiment, the size of the small section is gradually reduced so that the number of data included in the small section is reduced, but other methods are also conceivable. For example, it is conceivable to obtain period information in the x and y directions from the spatial frequency information of the height data obtained by the surface shape measurement and determine the size based on the period information. It is also conceivable to determine the size so that the amount of change in the height data obtained by the surface shape measurement is less than a certain value. It is also possible to use the gradient method (the steepest descent method). When using the steepest descent method, calculate as follows. A plane approximation height P having the data position (X, Y), the boundary position (m, n), the inclination of the plane, the position (G, H, C), and the size (R) of the small section as variables is obtained. Then, a residual E between P and the height Z obtained by the surface shape measurement is obtained. Next, the residual E is differentiated by each variable, and each variable is changed by a minute amount in the direction in which the residual changes most greatly in the direction in which the residual decreases. In this way, the set of variables that minimizes the residual is determined.

以上、本発明の好ましい実施形態について説明したが、本発明はこれらの実施形態に限定されず、その要旨の範囲内で種々の変形及び変更が可能である。   As mentioned above, although preferable embodiment of this invention was described, this invention is not limited to these embodiment, A various deformation | transformation and change are possible within the range of the summary.

2 演算装置(処理手段)
100 計測ユニット(計測手段)
300 撮像ユニット(撮像手段)
401 制御部(調節手段)
2 arithmetic unit (processing means)
100 Measuring unit (measuring means)
300 Imaging unit (imaging means)
401 Control unit (adjustment means)

Claims (18)

被写体の像を形成する光学系と、
前記光学系を介して、前記被写体の撮像範囲を複数の小区画毎に撮像する撮像手段と、
前記撮像手段で前記被写体を撮像する前に、前記光学系の光軸方向における前記被写体の高さを計測する計測手段と、
前記被写体の高さと前記被写体の高さ分布を近似した平面における近似高さとに基づく残差を算出することで、前記小区画毎の撮像条件を取得する処理手段と、
前記撮像条件に基づいて、前記小区画と前記撮像手段との相対的な位置関係を調節する調節手段と、を有することを特徴とする撮像システム。
An optical system for forming an image of a subject;
Imaging means for imaging the imaging range of the subject for each of a plurality of small sections via the optical system;
Measuring means for measuring the height of the subject in the optical axis direction of the optical system before imaging the subject by the imaging means;
Processing means for obtaining an imaging condition for each of the small sections by calculating a residual based on the height of the subject and an approximate height in a plane approximating the height distribution of the subject;
An imaging system comprising: an adjusting unit that adjusts a relative positional relationship between the small section and the imaging unit based on the imaging condition.
前記撮像条件は、前記光学系の光軸と垂直な面における前記撮像手段に対する前記小区画の位置、前記小区画と前記撮像手段との距離、および前記撮像手段に対する前記小区画の傾きの少なくともいずれかであることを特徴とする請求項1に記載の撮像システム。   The imaging condition includes at least one of a position of the small section with respect to the imaging unit on a plane perpendicular to the optical axis of the optical system, a distance between the small section and the imaging unit, and an inclination of the small section with respect to the imaging unit. The imaging system according to claim 1, wherein 前記処理手段は、前記残差が所定の被写界深度内となる撮像条件を取得することを特徴とする請求項1または2に記載の撮像システム。   The imaging system according to claim 1, wherein the processing unit acquires an imaging condition in which the residual is within a predetermined depth of field. 前記被写界深度は、使用波長、前記光学系の開口数、および前記光学系の撮像倍率を用いて決定されることを特徴とする請求項3に記載の撮像システム。   The imaging system according to claim 3, wherein the depth of field is determined using a use wavelength, a numerical aperture of the optical system, and an imaging magnification of the optical system. 前記処理手段は、前記近似高さを算出する際に、前記小区画の大きさを変数に含むことを特徴とする請求項1から4のいずれか1項に記載の撮像システム。   The imaging system according to any one of claims 1 to 4, wherein the processing unit includes the size of the small section as a variable when calculating the approximate height. 前記小区画の大きさは、前記撮像手段の撮像面の大きさ、および前記光学系の撮像倍率を用いて決定されることを特徴とする請求項5に記載の撮像システム。   6. The imaging system according to claim 5, wherein the size of the small section is determined using a size of an imaging surface of the imaging unit and an imaging magnification of the optical system. 前記処理手段は、前記小区画内の撮像データの一部を削除、または補間のいずれかを実行することを特徴とする請求項5または6に記載の撮像システム。   The imaging system according to claim 5 or 6, wherein the processing means performs either deletion or interpolation of a part of imaging data in the small section. 前記撮像手段の撮像面の大きさと前記光学系の撮像倍率とを用いて決定される前記小区画の大きさ、および、使用波長と前記光学系の開口数と前記光学系の撮像倍率とを用いて決定される被写界深度の少なくとも一方を入力する入力手段を更に有することを特徴とする請求項1から7のいずれか1項に記載の撮像システム。   Using the size of the small section determined using the size of the imaging surface of the imaging means and the imaging magnification of the optical system, the wavelength used, the numerical aperture of the optical system, and the imaging magnification of the optical system The imaging system according to claim 1, further comprising an input unit configured to input at least one of the depths of field determined in this way. 前記処理手段は、前記被写体の高さと前記被写体の高さ分布を近似した平面における近似高さに基づく第1の残差が所定の被写界深度を超えている場合の第1の撮像条件を取得した後、前記被写体の高さと前記第1の残差を含む領域の高さ分布を近似した平面における近似高さに基づく第2の残差を算出することで第2の撮像条件を取得し、
前記調節手段は、前記第1の撮像条件に基づいて前記小区画と前記撮像手段との相対的な位置関係を調節し、前記撮像手段によって撮像された後、前記第2の撮像条件に基づいて前記小区画と前記撮像手段との相対的な位置関係を調節することを特徴とする請求項1から8のいずれか1項に記載の撮像システム。
The processing means sets a first imaging condition when a first residual based on an approximate height on a plane approximating the height of the subject and the height distribution of the subject exceeds a predetermined depth of field. After the acquisition, the second imaging condition is acquired by calculating a second residual based on an approximate height in a plane approximating the height distribution of the area including the height of the subject and the first residual. ,
The adjusting unit adjusts a relative positional relationship between the small section and the imaging unit based on the first imaging condition, and after being imaged by the imaging unit, based on the second imaging condition. The imaging system according to claim 1, wherein a relative positional relationship between the small section and the imaging unit is adjusted.
前記撮像手段は、前記第2の撮像条件に基づいて前記位置関係が調節された後、前記領域と異なる領域を撮像しないことを特徴とする請求項9に記載の撮像システム。   The imaging system according to claim 9, wherein the imaging unit does not capture an area different from the area after the positional relationship is adjusted based on the second imaging condition. 前記処理手段は、前記第2の撮像条件に基づいて前記位置関係が調節された後、前記撮像手段によって撮像された前記被写体のうち前記領域と異なる領域を削除することを特徴とする請求項9または10に記載の撮像システム。   The processing means deletes an area different from the area from the subject imaged by the imaging means after the positional relationship is adjusted based on the second imaging condition. Or the imaging system of 10. 前記光学系は、物体を結像する第1の結像光学系と、前記第1の結像光学系により結像された前記物体を再結像する第2の結像光学系と、前記第1および第2の結像光学系の間に配置される反射手段と、を備え、
前記撮像条件に基づいて、前記反射手段の前記光軸方向の位置、および前記反射手段の前記光軸に対する傾きの少なくとも一方を変更可能であることを特徴とする請求項1から11のいずれか1項に記載の撮像システム。
The optical system includes: a first imaging optical system that images an object; a second imaging optical system that re-images the object imaged by the first imaging optical system; Reflecting means disposed between the first and second imaging optical systems,
The at least one of the position of the reflecting means in the optical axis direction and the inclination of the reflecting means with respect to the optical axis can be changed based on the imaging condition. The imaging system according to item.
前記処理手段は、前記近似高さの一部のデータを用いて、前記残差を算出することを特徴とする請求項1から12のいずれか1項に記載の撮像システム。   The imaging system according to claim 1, wherein the processing unit calculates the residual using a part of the data of the approximate height. 前記処理手段は、前記被写体の高さのデータ数を増やすために、補間を行うことを特徴とする請求項1から13のいずれか1項に記載の撮像システム。   The imaging system according to any one of claims 1 to 13, wherein the processing unit performs interpolation to increase the number of data of the height of the subject. 前記処理手段は、前記被写体の高さを用いて、空間周波数情報を算出することを特徴とする請求項1から14のいずれか1項に記載の撮像システム。   The imaging system according to any one of claims 1 to 14, wherein the processing unit calculates spatial frequency information using a height of the subject. 前記残差は、前記被写体の高さと前記近似高さとの差または前記被写体の高さと前記近似高さとの差の二乗平均平方根のいずれか一方であることを特徴とする請求項1から15のいずれか1項に記載の撮像システム。   16. The residual according to claim 1, wherein the residual is one of a difference between the height of the subject and the approximate height, or a root mean square of a difference between the height of the subject and the approximate height. The imaging system according to claim 1. 前記処理手段は、最小二乗法、または勾配法のいずれか一方を用いて、前記近似高さを算出することを特徴とする請求項1から16のいずれか1項に記載の撮像システム。   The imaging system according to any one of claims 1 to 16, wherein the processing unit calculates the approximate height using one of a least square method and a gradient method. 被写体の像を形成する光学系と、前記光学系を介して、被写体の撮像範囲を複数の小区画毎に撮像する撮像手段と、を有する撮像システムの撮像方法であって、
前記光学系の光軸方向における前記被写体の高さを計測するステップと、
前記被写体の高さと前記被写体の高さ分布を近似した平面における近似高さとに基づく残差を算出することで、前記小区画毎の撮像条件を取得するステップと、
前記撮像条件に基づいて、前記小区画と前記撮像手段との相対的な位置関係を調節するステップと、
前記撮像手段が前記小区画を撮像するステップと、を有することを特徴とする撮像方法。
An imaging method for an imaging system, comprising: an optical system that forms an image of a subject; and an imaging unit that captures an imaging range of the subject for each of a plurality of small sections via the optical system,
Measuring the height of the subject in the optical axis direction of the optical system;
Obtaining an imaging condition for each of the small sections by calculating a residual based on the height of the subject and an approximate height in a plane approximating the height distribution of the subject;
Adjusting the relative positional relationship between the small section and the imaging means based on the imaging condition;
And a step of imaging the small section by the imaging means.
JP2015019880A 2015-02-04 2015-02-04 Imaging system and imaging method Pending JP2016142960A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2015019880A JP2016142960A (en) 2015-02-04 2015-02-04 Imaging system and imaging method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2015019880A JP2016142960A (en) 2015-02-04 2015-02-04 Imaging system and imaging method

Publications (1)

Publication Number Publication Date
JP2016142960A true JP2016142960A (en) 2016-08-08

Family

ID=56570421

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2015019880A Pending JP2016142960A (en) 2015-02-04 2015-02-04 Imaging system and imaging method

Country Status (1)

Country Link
JP (1) JP2016142960A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2019102723A1 (en) * 2017-11-22 2019-05-31 富士フイルム株式会社 Observation device, method for operating observation device, and observation control program

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2019102723A1 (en) * 2017-11-22 2019-05-31 富士フイルム株式会社 Observation device, method for operating observation device, and observation control program
JPWO2019102723A1 (en) * 2017-11-22 2020-11-19 富士フイルム株式会社 Observation device, operation method of observation device, and observation control program
JP7195269B2 (en) 2017-11-22 2022-12-23 富士フイルム株式会社 Observation device, method of operating observation device, and observation control program
US11971530B2 (en) 2017-11-22 2024-04-30 Fujifilm Corporation Observation apparatus, method of operating observation apparatus, and observation control program

Similar Documents

Publication Publication Date Title
US8044974B2 (en) Image creating apparatus and image creating method
US6519359B1 (en) Range camera controller for acquiring 3D models
US8233665B2 (en) Image measuring apparatus and computer program
US20030128207A1 (en) 3-Dimensional image processing method, 3-dimensional image processing device, and 3-dimensional image processing system
US20140184778A1 (en) Image processing apparatus, control method for the same, image processing system, and program
JP2013011856A (en) Imaging system and control method thereof
US11836881B2 (en) Intra-oral scanning device with active delete of unwanted scanned items
JP5911296B2 (en) Image processing apparatus, imaging apparatus, microscope system, image processing method, and image processing program
CN110915193B (en) Image processing system, server device, image processing method, and recording medium
KR101501129B1 (en) Substrate inspection apparatus
JP2004309240A (en) Three-dimensional shape measuring apparatus
JP2013029806A (en) Imaging apparatus
JP5599849B2 (en) Lens inspection apparatus and method
JP2013153429A (en) Image processing apparatus, image display system, image processing method and image processing program
US9014506B2 (en) Image processing method, program, image processing apparatus, image-pickup optical apparatus, and network device
US10481378B2 (en) Interactive graphical representation of image quality and control thereof
JP2004037410A (en) Modulation transfer function measuring device and modulation transfer function measuring method
JP2016142960A (en) Imaging system and imaging method
US10827114B2 (en) Imaging system and setting device
JP6012396B2 (en) Image processing apparatus, image processing method, and program.
JP6641485B2 (en) Position specifying device and position specifying method
JP2010283088A (en) Wafer appearance inspection device
JPH0474661B2 (en)
WO2024038677A1 (en) Imaging assistance device, imaging device, imaging assistance method, and program
JP2013152429A (en) Image processing device, image processing method and program