レーザーライン抽出

カメラセンサによって捕捉された物体のプロファイルのシーケンスから深度マップを作成するためには、レーザライン抽出(LLE)アルゴリズムが必要です。

LLEアルゴリズムの目的は、ユーザ定義の関心領域(ROI)内のセンサフレームの各列の垂直プロファイルに沿ったライン位置を測定することです。

オブジェクト 一般的な文章では、オブジェクトという用語はクラスインスタンスという意味で理解します。一方、EasyObjectでは、レイヤ背景に属する連結した隣接ピクセルから成る最大限の大きさの領域のことをオブジェクトと呼びます。位置のすべてのステップについて、検出はフレームの各列を個別に分析し、グレー値として格納された出力位置の行を生成します。

下の図は、深度マップの生成を示しています。

The class ELaserLineExtractor provides the laser line extraction functionality in Open eVision.

Uses the method ELaserLineExtractor.AnalysisMode to select one of the following algorithms to extract the laser line (see below for more details):

最大検出は最大強度のピクセル位置を戻します。最速の方法ですが、サブピクセルの精度はサポートしていません。
ピーク検出手法は、極大値を検出します。いくつかの最大値が検出された場合、強度の最も高い値が戻されます。位置はサブピクセル精度で戻ります。
重心 アルゴリズムは、レーザーラインが数ピクセルにわたって広がっている場合に適しています。位置はサブピクセル精度で戻ります。

低い強度のピクセルを除外するための閾値を設定することもできます。

レーザーライン抽出アルゴリズムにより戻されるライン位置は、関心領域の底部に関連しています。つまり、深度マップ内の値は0(ROIの底部)からROIの高さまでの範囲になります。

レーザーライン抽出メソッド

最大検出

最大検出アルゴリズムは、ROI列内の全てのピクセルを分析して、最大値を有するものを決定します。下の図は、特定のROI列のレーザーライン位置を示しています。

ROIプロファイルでの最大検出

処理チェーンに含めることもお勧めします。

画像の高周波変動を低減するためのローパスフィルタ。
センサーからバックグラウンドノイズを除去するためのしきい値。

ピーク検出

ピーク検出アルゴリズムは、一次導関数の離散単純化に依存しています。

f'(x)はに沿って特定のの傾きを出力します。f(x)x

f(x)とプロットf'(x)

2点形式の直線方程式に基づいて、f’(x)が信号を変化させる位置を検出することによって、直線位置を計算します。

ここでは、(x1, y1)(x2, y2)x2≠ x1をもった直線上の2つの点で、次の式y = 0が得られます。

重心

重心(CoG)法は、画像オブジェクトの重心を計算するアルゴリズムを使用します。「平面図形の重心」としても知られるCoGは、次の式で求められます。

    

ここでは、はCoGの座標で、ax軸とy軸に沿ったピクセル値です。

ROIプロファイル上の重心

ローパスリニアフィルタ

必要に応じて、画像のノイズおよび高周波数を低減するために、ライン抽出の前にローパスリニアフィルタを適用することができます。

ローパスリニアフィルタは、1x3スライディングウィンドウにコンボリューション演算子を適用します。コンボリューションカーネルの3つの要素(A、BおよびC)は構成可能であり、正の整数を受け入れます。以下の図は、ROI内のコンボリューションカーネル要素の配置を示しています。

You can activate the low-pass filter for any of the laser line extraction methods with the method ELaserLineExtractor::SetEnableSmoothing(true/false). Parameters A, B and C are set with ELaserLineExtractor::SetSmoothingParameters(A, B, C).

Depth map Z resolution

As explained above, the laser line extraction computes the sub-pixel position of the laser line profile for each column of the region of interest.
This position is encoded in a 16-bit depth map (EDepthMap16).
The resolution controls the way the sub-pixel positions are converted to 16-bit fixed point values (that is how many bits are allocated to represent the fractional part of the sub-pixel position).
On a EDepthMap16, use the method EDepthMap16.ZResolution to retrieve the resolution. It is a floating-point value used to convert the integer pixel value to a real depth value.
By default, ELaserLineExtractor computes the best resolution depending on the height of the region of interest. The following table lists typical resolution values depending on the height of the processed frame or region of interest.

Frame or ROI height

Bits used for the fractional part

Z resolution

100

8

1/256 = 0.00390625

200

8

1/256 = 0.00390625

400

7

1/128 = 0.0078125

800

6

1/64 = 0.015625

2500

4

1/16 = 0.0625

Use the optional parameter zResolution of the constructor ELaserLineExtractor.ElaserLineExtractor to fix the Z resolution.
If you do not set the parameter zResolution, an algorithm computes the optimal value. Use ElaserLineExtractor.DepthMap to query the returned depth map and get the effective resolution.
If you are using the hardware laser line extraction with the Coaxlink Quad 3D-LLE, the fixed point format is set by the configuration: 8_8 or 11_5 for 8- or 5-bit fractional part.
2 See documentation.euresys.com/Products/COAXLINK/COAXLINK/en-us/Content/03_Interfaces/functional-guide/lle/LLE_Processing_Core_Characteristics.htm