JP6299317B2 - Image processing device - Google Patents

Image processing device Download PDF

Info

Publication number
JP6299317B2
JP6299317B2 JP2014060376A JP2014060376A JP6299317B2 JP 6299317 B2 JP6299317 B2 JP 6299317B2 JP 2014060376 A JP2014060376 A JP 2014060376A JP 2014060376 A JP2014060376 A JP 2014060376A JP 6299317 B2 JP6299317 B2 JP 6299317B2
Authority
JP
Japan
Prior art keywords
parallax
unit
image
coordinate
pixel
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.)
Active
Application number
JP2014060376A
Other languages
Japanese (ja)
Other versions
JP2015184896A (en
Inventor
章 寺谷
章 寺谷
Original Assignee
サクサ株式会社
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 サクサ株式会社 filed Critical サクサ株式会社
Priority to JP2014060376A priority Critical patent/JP6299317B2/en
Publication of JP2015184896A publication Critical patent/JP2015184896A/en
Application granted granted Critical
Publication of JP6299317B2 publication Critical patent/JP6299317B2/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Description

本発明は、画像処理装置に関する。   The present invention relates to an image processing apparatus.

多数の乗客が利用する鉄道車両では安全な運行が要求されるため、従来より、鉄道車両の関係者は、鉄道車両を安全に運行するための様々な試みを行っている。例えば、乗客がプラットホームから線路へ転落すると、重大な事故に繋がるおそれがあることから、乗客の転落をいち早く検知する試みが多数なされており、そのうちの幾つかは実際に鉄道車両の駅で採用されている。   Since railroad vehicles used by a large number of passengers are required to be operated safely, the related parties of the railcars have conventionally made various attempts to operate the railroad vehicles safely. For example, if a passenger falls from a platform to a track, there is a risk of a serious accident. ing.

具体的な一例として、プラットホームの天井下に複数のカメラを設置し、複数のカメラでプラットホームや線路上等の駅構内を監視するカメラシステムがよく知られている。
このようなカメラシステムとして、例えば、特許文献1には、複数のカメラをデイジーチェーン接続し、夫々のカメラで取得された監視情報を他のカメラを経由してサーバに伝送するカメラシステムが開示されている。
As a specific example, a camera system is well known in which a plurality of cameras are installed under the platform ceiling and a plurality of cameras monitor a station premises such as on a platform or a track.
As such a camera system, for example, Patent Document 1 discloses a camera system in which a plurality of cameras are connected in a daisy chain, and monitoring information acquired by each camera is transmitted to a server via another camera. ing.

特開2012−11989号公報JP 2012-11989

このようなカメラシステムでは、通常、ステレオカメラの撮影画像の視差を用いて、線路に落下した乗客や異物を検知することとしている。そのため、従来のカメラシステムでは、線路に落下した乗客や異物を検知するために、線路のレール面上で視差がゼロになるように各カメラを調整し、プラットホームへの設置を行っている。レール面が視差ゼロになるようにカメラを設置することで、線路(レール)に異物が落下すると異物が写っている箇所に視差が生じることから、視差が生じている画素ブロックを検出することで異物を検出できた。   In such a camera system, a parallax of a captured image of a stereo camera is usually used to detect a passenger or a foreign object dropped on a track. Therefore, in the conventional camera system, in order to detect passengers and foreign objects that have fallen on the track, each camera is adjusted so that the parallax is zero on the rail surface of the track, and is installed on the platform. By installing the camera so that the rail surface has zero parallax, when a foreign object falls on the track (rail), the parallax is generated where the foreign object is reflected. Foreign matter was detected.

しかしながら、レール面が視差ゼロになるようにカメラを設置するには、各撮影部の撮影方向を高精度に調整する必要があり、多大な時間を要していた。プラットホーム全域に亘り監視を行うためには多数のカメラを設置する必要がある。多数のカメラの調整には膨大な時間が必要になる上に、乗客の利便性を損なうことのないよう調整作業は夜間に行う必要があるので、調整作業を不要とする技術が求められていた。   However, in order to install the camera so that the rail surface has zero parallax, it is necessary to adjust the shooting direction of each shooting unit with high accuracy, which takes a lot of time. In order to monitor the entire platform, it is necessary to install a large number of cameras. Adjustment of a large number of cameras requires an enormous amount of time, and it is necessary to perform adjustment work at night so as not to impair passenger convenience. Therefore, there is a need for technology that eliminates the need for adjustment work. .

本発明は、このような問題に鑑みてなされたものであり、プラットホームを監視するカメラの調整作業を不要にする画像処理装置を提供することを目的とする。   The present invention has been made in view of such problems, and an object of the present invention is to provide an image processing apparatus that eliminates the need for adjusting a camera for monitoring a platform.

上記課題を解決するために、本発明の画像処理装置は、複数の撮影部が第1方向に沿って配置されたステレオカメラの第1撮影部で撮影した第1画像から、隣接する画素との輝度差が所定以上の画素により構成される複数の画素ブロックを抽出する抽出部と、前記抽出部が抽出した複数の前記画素ブロックから、少なくとも前記第1方向と直交する第2方向の座標が異なる2以上の画素ブロックを選択する選択部と、前記選択部が選択した前記2以上の画素ブロックの夫々について、ステレオカメラの第2撮影部で撮影された第2画像との視差を取得する取得部と、前記取得部が取得した視差及び前記2以上の画素ブロックの夫々の前記第2方向の座標に基づいて、前記視差と前記第2方向の座標との関係を示す視差情報を生成する生成部と、を備える。   In order to solve the above-described problems, an image processing apparatus according to the present invention includes a first image captured by a first imaging unit of a stereo camera in which a plurality of imaging units are arranged along a first direction, and an adjacent pixel. The coordinates of at least the second direction orthogonal to the first direction are different from the extraction unit that extracts a plurality of pixel blocks composed of pixels having a luminance difference of a predetermined value or more and the plurality of pixel blocks extracted by the extraction unit. A selection unit that selects two or more pixel blocks, and an acquisition unit that acquires the parallax between the second image captured by the second imaging unit of the stereo camera for each of the two or more pixel blocks selected by the selection unit. And a generation unit that generates disparity information indicating a relationship between the parallax and the coordinates in the second direction based on the parallax acquired by the acquisition unit and the coordinates in the second direction of each of the two or more pixel blocks. When Equipped with a.

上記の画像処理装置において、前記ステレオカメラは、前記第1方向に沿って延びるプラットホームに設置され、前記プラットホームの周辺を俯瞰的に撮影するステレオカメラであり、前記プラットホームの側面に前記第1方向に沿って延びる線路のレールの、撮影画像における位置を示す前記第2方向の座標を検出する検出部を更に備え、前記選択部は、前記第2方向の座標が、前記レールが位置する座標よりも前記ステレオカメラから離れる方向に位置する少なくとも一の画素ブロックを選択することとしてもよい。   In the above image processing apparatus, the stereo camera is a stereo camera that is installed on a platform extending along the first direction and photographs the periphery of the platform from a bird's-eye view, and is arranged on the side surface of the platform in the first direction. A detection unit that detects coordinates in the second direction indicating a position in the captured image of the rail of the track extending along the rail, and the selection unit is configured such that the coordinates in the second direction are more than coordinates in which the rail is positioned. At least one pixel block located in a direction away from the stereo camera may be selected.

上記の画像処理装置において、前記検出部は、前記複数の画素ブロックにおける視差に基づいて、前記レールが位置する座標を検出することとしてもよい。   In the above image processing device, the detection unit may detect coordinates where the rail is located based on parallax in the plurality of pixel blocks.

上記の画像処理装置において、前記検出部は、前記線路の枕木の位置を検出し、前記選択部は、前記検出部が検出した前記枕木の位置以外に位置する複数の前記画素ブロックから前記2以上の画素ブロックを選択することとしてもよい。   In the above-described image processing device, the detection unit detects a position of a sleeper of the track, and the selection unit is configured to detect the two or more pixel blocks from a plurality of the pixel blocks that are located at positions other than the position of the sleeper detected by the detection unit. The pixel block may be selected.

上記の画像処理装置において、前記選択部は、前記第1方向の座標が所定範囲内の第1領域、及び前記所定範囲外の第2領域の夫々において、前記2以上の画素ブロックを選択し、前記生成部は、前記第1領域及び前記第2領域の夫々に関連付けて、前記視差情報を生成することとしてもよい。   In the above-described image processing device, the selection unit selects the two or more pixel blocks in each of a first region whose coordinates in the first direction are within a predetermined range and a second region outside the predetermined range, The generation unit may generate the parallax information in association with each of the first area and the second area.

上記の画像処理装置において、前記第1画像と前記第2画像との所定座標における視差が、前記視差情報が規定する当該座標の視差に対して所定量以上異なる異常画素ブロックを探索する探索部と、前記探索部が前記異常画素ブロックを検出することを条件に、警告情報を出力する出力部と、を更に備えることとしてもよい。   In the above image processing device, a search unit that searches for an abnormal pixel block in which a parallax at a predetermined coordinate between the first image and the second image differs by a predetermined amount or more with respect to the parallax of the coordinate specified by the parallax information; And an output unit that outputs warning information on condition that the search unit detects the abnormal pixel block.

本発明によれば、調整作業を行うことなくプラットホームを監視するカメラを設置することができる。   According to the present invention, it is possible to install a camera for monitoring the platform without performing adjustment work.

一実施形態に係る撮影システムの構成例を示す図である。It is a figure which shows the structural example of the imaging | photography system which concerns on one Embodiment. 駅プラットホームにおける撮影装置の設置例を示す図である。It is a figure which shows the example of installation of the imaging device in a station platform. 駅プラットホームにおける撮影装置の設置例を示す図である。It is a figure which shows the example of installation of the imaging device in a station platform. 撮影装置が撮影した各種撮影画像の一例を示す図である。It is a figure which shows an example of the various picked-up images image | photographed with the imaging device. データ管理装置の機能構成を示すブロック図である。It is a block diagram which shows the function structure of a data management apparatus. 視差とY座標との関係を示す視差情報の一例を示す図である。It is a figure which shows an example of the parallax information which shows the relationship between parallax and a Y coordinate. データ管理装置の視差情報生成機能の流れの一例を示す図である。It is a figure which shows an example of the flow of the parallax information generation function of a data management apparatus. データ管理装置の視差情報生成機能の流れの一例を示す図である。It is a figure which shows an example of the flow of the parallax information generation function of a data management apparatus. データ管理装置の視差情報生成機能の流れの一例を示す図である。It is a figure which shows an example of the flow of the parallax information generation function of a data management apparatus. データ管理装置の異物検知機能の流れの一例を示す図である。It is a figure which shows an example of the flow of the foreign material detection function of a data management apparatus. 撮影システムの処理の流れを示すフローチャートである。It is a flowchart which shows the flow of a process of an imaging | photography system. 撮影システムの処理の流れを示すフローチャートである。It is a flowchart which shows the flow of a process of an imaging | photography system. データ管理装置の異物検知機能の別例を示す図である。It is a figure which shows another example of the foreign material detection function of a data management apparatus.

[撮影システム10の全体構成]
図1は、本実施形態に係る撮影システム10の全体構成を示す図であり、図2は、撮影装置101の駅のプラットホームにおける設置例を示す図である。なお、図2Aは、鉄道車両の進行方向から駅のプラットホームを見た図であり、図2Bは、鉄道車両の進行方向に対して直交する方向から駅のプラットホームを見た図である。
[Overall Configuration of Shooting System 10]
FIG. 1 is a diagram illustrating an overall configuration of a photographing system 10 according to the present embodiment, and FIG. 2 is a diagram illustrating an installation example of a photographing apparatus 101 on a station platform. 2A is a diagram of the station platform as seen from the traveling direction of the railway vehicle, and FIG. 2B is a diagram of the station platform as viewed from a direction orthogonal to the traveling direction of the railway vehicle.

図1に示すように撮影システム10は、撮影装置群100、及び撮影装置群100と通信可能に接続されたデータ管理装置200を含んで構成される。
なお、撮影システム10は、データ管理装置200と撮影装置群100との間にハブ300を備えてもよく、また、ハブ300に接続される撮影装置群100を複数備えてもよい。この場合、例えば、夫々の撮影装置群100を、駅にある複数のプラットホームの夫々に設置することとしてもよい。また、撮影システム10は、撮影装置群100で撮影された画像を表示するモニタ400を備えてもよい。
As shown in FIG. 1, the imaging system 10 includes an imaging device group 100 and a data management device 200 connected to the imaging device group 100 so as to be communicable.
Note that the imaging system 10 may include the hub 300 between the data management device 200 and the imaging device group 100, or may include a plurality of imaging device groups 100 connected to the hub 300. In this case, for example, each imaging device group 100 may be installed on each of a plurality of platforms at a station. The imaging system 10 may also include a monitor 400 that displays an image captured by the imaging device group 100.

撮影装置群100は、複数の撮影装置101(撮影装置101−1、撮影装置101−2・・・撮影装置101−n、ただしnは3以上の自然数)が所定方向に沿ってデイジーチェーン接続されて構成される。なお、図2Bに示すように、本実施形態では、複数の撮影装置101は、駅のプラットホームPの長さ方向に沿ってデイジーチェーン接続される。   In the imaging device group 100, a plurality of imaging devices 101 (imaging device 101-1, imaging device 101-2... Imaging device 101-n, where n is a natural number of 3 or more) are connected in a daisy chain along a predetermined direction. Configured. As shown in FIG. 2B, in the present embodiment, the plurality of imaging devices 101 are daisy chain connected along the length direction of the platform P of the station.

撮影装置101は、複数の撮影部が駅のプラットホームPの長さ方向に沿って水平に配置されたステレオカメラである。図2Aに示すように、撮影装置101は、駅のプラットホームPの上部(天井)から線路Rに向けて所定の角度となるように設置されるとともに、図2Bに示すように、夫々の撮影装置101の撮影範囲Sが隣接する撮影装置101の撮影範囲Sと重なり合うように設置される。   The photographing apparatus 101 is a stereo camera in which a plurality of photographing units are horizontally arranged along the length direction of the platform P of the station. As shown in FIG. 2A, the photographing device 101 is installed at a predetermined angle from the upper part (ceiling) of the platform P of the station toward the track R, and as shown in FIG. 2B, each photographing device 101 101 is set so that the shooting range S of 101 overlaps the shooting range S of the adjacent shooting device 101.

撮影装置101は、プラットホームPの周辺、即ちプラットホームP及び線路Rを俯瞰的に撮影する。ここで、撮影装置101によって撮影される第1画像51及び第2画像52、並びに第1画像51と第2画像52とから生成される距離画像53の一例を図3に示す。   The photographing apparatus 101 photographs the periphery of the platform P, that is, the platform P and the track R from a bird's-eye view. Here, FIG. 3 shows an example of the first image 51 and the second image 52 photographed by the photographing apparatus 101, and the distance image 53 generated from the first image 51 and the second image 52.

第1画像51は、撮影装置101の第1撮影部により撮影される撮影画像であり、第2画像52は、撮影装置101の第2撮影部により撮影される撮影画像である。
図3の第1画像51に示すように、撮影装置101は、プラットホームP及び線路Rを撮影する。本実施形態では、線路Rは、レールRaと複数の枕木Rtと砂利Rbとから構成されるバラスト軌道である。
The first image 51 is a photographed image photographed by the first photographing unit of the photographing apparatus 101, and the second image 52 is a photographed image photographed by the second photographing unit of the photographing apparatus 101.
As shown in the first image 51 in FIG. 3, the photographing apparatus 101 photographs the platform P and the track R. In the present embodiment, the track R is a ballast track composed of a rail Ra, a plurality of sleepers Rt, and gravel Rb.

距離画像53は、第1画像51と第2画像52との視差に基づいて生成される画像である。
ここで、視差の算出方法は既に公知であり、基準画像(第1画像51)の基準点と対応する対応点を比較画像(第2画像52)の中から探索することで視差を算出する。具体的には、基準となる画素を中心に基準画像から画素ブロックを抽出し、比較画像の探索領域内の画素ブロックのうち基準画像から抽出した画素ブロックと輝度パターンが類似している画素ブロックをSAD(Sum of Absolute Differences)法等の公知の手法により特定する。そして、基準画像の画素ブロックの座標と比較画像の画素ブロックの座標との相違から、視差を算出する。なお、本実施形態では、画素ブロックを構成する複数の画素のうち隣接する画素との輝度差が所定以上でない画素については、視差をゼロとして距離画像53を生成する。
The distance image 53 is an image generated based on the parallax between the first image 51 and the second image 52.
Here, the parallax calculation method is already known, and the parallax is calculated by searching corresponding points corresponding to the reference point of the reference image (first image 51) from the comparison image (second image 52). Specifically, a pixel block is extracted from the reference image around the reference pixel, and a pixel block whose luminance pattern is similar to the pixel block extracted from the reference image among the pixel blocks in the search area of the comparison image. It specifies by well-known methods, such as SAD (Sum of Absolute Differences) method. Then, the parallax is calculated from the difference between the coordinates of the pixel block of the reference image and the coordinates of the pixel block of the comparison image. In the present embodiment, the distance image 53 is generated with the parallax set to zero for pixels in which the luminance difference between adjacent pixels of the plurality of pixels constituting the pixel block is not equal to or greater than a predetermined value.

第1撮影部と第2撮影部とがプラットホームPの長さ方向に沿って水平に配置された撮影装置101でバラスト軌道を撮影する場合、図3の距離画像53に示すように、プラットホームP、レールRa及び枕木Rtについては視差を算出できず、砂利Rbについては輝度パターンに特徴があるため視差を算出することができる。   When the ballast trajectory is imaged by the imaging device 101 in which the first imaging unit and the second imaging unit are horizontally arranged along the length direction of the platform P, as shown in the distance image 53 of FIG. The parallax cannot be calculated for the rail Ra and the sleeper Rt, and the parallax can be calculated for the gravel Rb because the luminance pattern is characteristic.

なお、夫々の画像において水平方向をX方向(第1方向)、垂直方向をY方向(第2方向)とする。撮影装置101の複数の撮影部が駅のプラットホームPの長さ方向に沿って水平に配置されるため、X方向はプラットホームPの長さ方向に相当する。また、Y方向は、プラットホームPや線路Rの幅方向(撮影装置101からの距離)に相当する。
以下では、説明の便宜上、画像上部をY座標「小」とし、画面下部をY座標「大」とする。即ち、撮影装置101から距離が遠いほどY座標を「小」とし、近いほどY座標を「大」とする。
In each image, the horizontal direction is the X direction (first direction), and the vertical direction is the Y direction (second direction). Since the plurality of imaging units of the imaging apparatus 101 are horizontally arranged along the length direction of the platform P of the station, the X direction corresponds to the length direction of the platform P. Further, the Y direction corresponds to the width direction of the platform P and the track R (distance from the photographing apparatus 101).
In the following, for convenience of explanation, the upper part of the image is Y coordinate “small” and the lower part of the screen is Y coordinate “large”. In other words, the Y coordinate is set to “small” as the distance from the image capturing apparatus 101 is increased, and the Y coordinate is set to “large” as it is closer.

撮影装置101が撮影した第1画像51及び第2画像52と、これら第1画像51及び第2画像52から生成された距離画像53とは、所定の通信線を介してデータ管理装置200に送信され、データ管理装置200の記憶部202に記憶される。なお、距離画像53は、撮影装置101が生成することなく、データ管理装置200において生成することとしてもよい。   The first image 51 and the second image 52 photographed by the photographing device 101 and the distance image 53 generated from the first image 51 and the second image 52 are transmitted to the data management device 200 via a predetermined communication line. And stored in the storage unit 202 of the data management device 200. The distance image 53 may be generated by the data management apparatus 200 without being generated by the imaging apparatus 101.

[データ管理装置200の機能構成]
図4は、データ管理装置200の機能構成を示すブロック図である。データ管理装置200は、制御部201と、記憶部202と、を含んで構成される。
[Functional Configuration of Data Management Device 200]
FIG. 4 is a block diagram illustrating a functional configuration of the data management apparatus 200. The data management apparatus 200 includes a control unit 201 and a storage unit 202.

記憶部202は、例えば、ROM及びRAM等により構成される。記憶部202は、データ管理装置200を機能させるための各種プログラムを記憶する。また、記憶部202は、ステレオカメラの第1撮影部が撮影した第1画像51及び第2撮影部が撮影した第2画像52の画像データと、第1画像51及び第2画像52から生成される距離画像53の画像データと、を記憶する。   The storage unit 202 is configured by, for example, a ROM and a RAM. The storage unit 202 stores various programs for causing the data management apparatus 200 to function. The storage unit 202 is generated from the first image 51 taken by the first photographing unit of the stereo camera and the image data of the second image 52 taken by the second photographing unit, and the first image 51 and the second image 52. Image data of the distance image 53 to be stored.

制御部201は、例えば、CPUにより構成され、記憶部202に記憶されている各種プログラムを実行することにより、視差情報生成機能及び異物検知機能として機能する。   The control unit 201 is configured by, for example, a CPU, and functions as a parallax information generation function and a foreign object detection function by executing various programs stored in the storage unit 202.

[視差情報生成機能]
図2Aに示すように、撮影装置101は、所定の角度を持ってプラットホームPの上部に設置されるため、撮影装置101からみると線路Rは傾斜してみえる。そのため、線路R内のプラットホームP側と反対側とでは、撮影装置101からの距離が異なる。なお、以下においてプラットホームP側を「手前側」、反対側を「奥側」と呼ぶことがある。
図5に示すように、視差は撮影装置101からの距離によって異なり、撮影装置101から近い物体を撮影したときの視差は大きく、遠い物体を撮影したときの視差は小さいため、線路R内であっても視差が異なる。
[Parallax information generation function]
As shown in FIG. 2A, since the photographing apparatus 101 is installed on the platform P at a predetermined angle, the track R appears to be inclined when viewed from the photographing apparatus 101. Therefore, the distance from the imaging device 101 differs between the platform P side and the opposite side in the track R. In the following, the platform P side may be referred to as “front side” and the opposite side as “back side”.
As shown in FIG. 5, the parallax varies depending on the distance from the photographing apparatus 101, the parallax when photographing an object close to the photographing apparatus 101 is large, and the parallax when photographing a distant object is small. Even parallax is different.

視差情報生成機能は、このような視差と距離との関係を示す視差情報(図5に示すY−d関数)を生成する。
このような視差情報生成機能を実現するため、制御部201は、抽出部203と、選択部205と、取得部206と、生成部207と、を含んで構成される。
The disparity information generation function generates disparity information (Yd function shown in FIG. 5) indicating the relationship between such disparity and distance.
In order to realize such a parallax information generation function, the control unit 201 includes an extraction unit 203, a selection unit 205, an acquisition unit 206, and a generation unit 207.

抽出部203は、第1撮影部が撮影した第1画像51から、隣接する画素との輝度差が所定(例えば、「3」)以上の画素により構成される複数の画素ブロックを抽出する。例えば、4×4ピクセルの画素ブロックを用いる場合、抽出部203は、16画素のうち隣接する画素との輝度差が所定以上の画素が所定数(例えば、10画素)以上である画素ブロックを、複数抽出する。   The extraction unit 203 extracts, from the first image 51 photographed by the first photographing unit, a plurality of pixel blocks composed of pixels having a luminance difference with an adjacent pixel equal to or greater than a predetermined value (for example, “3”). For example, when a pixel block of 4 × 4 pixels is used, the extraction unit 203 selects a pixel block having a predetermined number or more (for example, 10 pixels) of pixels having a luminance difference from adjacent pixels out of 16 pixels. Extract multiple.

図5に示す視差情報(Y−d関数)を生成するためには、Y座標が異なる位置における複数の視差があればよい。ここで、視差の算出に際して、画素ブロック内の画素の輝度が単一の場合、基準となる画素ブロックの輝度パターンと類似する候補が比較画像の探索領域内に多数あるため、対応点を誤って特定してしまうことがあり、視差の算出に適していない。この点、隣接する画素との輝度差が所定以上の画素により構成される画素ブロックは、輝度パターンに特徴のある領域であり、視差の算出に適している。
そこで、選択部205は、抽出部203が抽出した複数の画素ブロックから、少なくともY方向の座標が異なる2以上の画素ブロックを選択する。
In order to generate the parallax information (Yd function) illustrated in FIG. 5, it is only necessary to have a plurality of parallaxes at positions with different Y coordinates. Here, when calculating the parallax, if the brightness of the pixels in the pixel block is single, there are many candidates in the search area of the comparison image that are similar to the brightness pattern of the reference pixel block. This is not suitable for calculating parallax. In this regard, a pixel block composed of pixels having a luminance difference between adjacent pixels that is greater than or equal to a predetermined value is a region having a characteristic luminance pattern, and is suitable for calculating parallax.
Therefore, the selection unit 205 selects at least two pixel blocks having different coordinates in the Y direction from the plurality of pixel blocks extracted by the extraction unit 203.

取得部206は、選択部205が選択した2以上の画素ブロックの夫々について、撮影装置101の第2撮影部で撮影された第2画像52との視差を取得する。   The acquisition unit 206 acquires the parallax between the two or more pixel blocks selected by the selection unit 205 and the second image 52 captured by the second imaging unit of the imaging apparatus 101.

生成部207は、取得部206が取得した視差及び2以上の画素ブロックの夫々のY方向の座標に基づいて、視差とY方向の座標との関係を示す視差情報を生成する。生成部207は、例えば、最小二乗法等を用いて、2以上の画素ブロックの視差及びY方向の座標に基づいて、視差情報(以下の式(1))を生成する。
d(y)=αY+β・・・式(1)
なお、d(y)は視差を示し、Yは画素ブロックのY座標を示し、α及びβは最小二乗法により算出されるパラメータを示す。
The generation unit 207 generates parallax information indicating the relationship between the parallax and the Y-direction coordinates based on the parallax acquired by the acquisition unit 206 and the Y-direction coordinates of each of the two or more pixel blocks. The generation unit 207 generates disparity information (the following expression (1)) based on the disparity of two or more pixel blocks and the coordinates in the Y direction using, for example, the least square method.
d (y) = αY + β (1)
Here, d (y) indicates parallax, Y indicates the Y coordinate of the pixel block, and α and β indicate parameters calculated by the least square method.

ここで、図3に模式的に示す距離画像53では、プラットホームP、レールRa及び枕木Rtについては視差を算出できていないが、ノイズの影響を完全に除去することはできず、プラットホームP、レールRa及び枕木Rtについても一部視差が算出される。
このようなノイズとして算出された視差を用いて視差情報(Y−d関数)を算出することは好ましくないため、制御部201は、検出部204を更に含むこととしてもよい。
Here, in the distance image 53 schematically shown in FIG. 3, the parallax cannot be calculated for the platform P, the rail Ra, and the sleeper Rt, but the influence of noise cannot be completely removed. Partial parallax is also calculated for Ra and sleepers Rt.
Since it is not preferable to calculate parallax information (Yd function) using parallax calculated as such noise, the control unit 201 may further include a detection unit 204.

検出部204は、プラットホームP、レールRa及び枕木Rtの位置を検出する。より詳細には、プラットホームP及びレールRaが位置するY座標、並びに枕木Rtが位置するX座標を検出する。
選択部205は、検出部204が検出したプラットホームP、レールRa及び枕木Rtの位置以外の位置から2以上の画素ブロックを選択する。このとき、選択部205は、Y座標が、レールRaが位置する座標よりも撮影装置101から離れる方向(奥側)に位置する少なくとも一の画素ブロックを選択することで、算出する視差情報(Y−d関数)の精度を高めることができ好適である。
The detection unit 204 detects the positions of the platform P, the rail Ra, and the sleepers Rt. More specifically, the Y coordinate where the platform P and the rail Ra are located and the X coordinate where the sleeper Rt is located are detected.
The selection unit 205 selects two or more pixel blocks from positions other than the positions of the platform P, the rail Ra, and the sleepers Rt detected by the detection unit 204. At this time, the selection unit 205 selects parallax information (Y that is calculated by selecting at least one pixel block whose Y coordinate is located in a direction (back side) farther from the imaging device 101 than the coordinate where the rail Ra is located. -D function) can be improved in accuracy.

[視差情報生成機能の一例]
続いて、図6から図8を参照して、視差情報生成機能の具体的な処理の流れの一例について説明する。
図6(A)に示すように、第1画像51は、複数の画素ブロック510により構成される。画素ブロック510は、図6(B)に示すように、例えば4×4ピクセルの画素ブロックである。
[Example of disparity information generation function]
Next, an example of a specific processing flow of the disparity information generation function will be described with reference to FIGS.
As shown in FIG. 6A, the first image 51 is composed of a plurality of pixel blocks 510. The pixel block 510 is a pixel block of 4 × 4 pixels, for example, as illustrated in FIG.

抽出部203は、画素ブロック510に含まれる16個の画素から隣接する画素との輝度差が所定以上(例えば、3以上)の画素を特定する。例えば、図6(B)に示す画素ブロック510内の左上の画素は、隣接する画素との輝度差が4(=9−5)であり、隣接する画素との輝度差が所定以上の画素である。一方、画素ブロック510内の右上の画素は、隣接する画素との輝度差が0(=8−8)であり、隣接する画素との輝度差が所定以上の画素ではない。   The extraction unit 203 identifies a pixel having a luminance difference of at least a predetermined value (for example, 3 or more) from adjacent pixels among the 16 pixels included in the pixel block 510. For example, the upper left pixel in the pixel block 510 illustrated in FIG. 6B has a luminance difference of 4 (= 9-5) with an adjacent pixel, and the luminance difference with the adjacent pixel is a predetermined pixel or more. is there. On the other hand, the upper right pixel in the pixel block 510 has a luminance difference of 0 (= 8-8) with an adjacent pixel, and the luminance difference with the adjacent pixel is not a predetermined pixel or more.

抽出部203は、隣接する画素との輝度差が所定以上である画素について視差dをセットする一方で、隣接する画素との輝度差が所定未満である画素について視差ゼロをセットする。なお、視差dは、画素ブロック510内の画素において同一であり、SAD法等の公知の手法により所定のタイミングで算出される。このように、抽出部203は、隣接する画素間の輝度差情報と画素ブロック510の視差とを融合する。
また、抽出部203は、隣接する画素との輝度差が所定以上である画素の数を計数し、計数結果が所定数以上である画素ブロックを、複数抽出する。本実施形態では、抽出部203は、16画素のうち10画素以上の画素が所定以上の輝度差である画素ブロックを、抽出する。
The extraction unit 203 sets the parallax d for a pixel whose luminance difference with an adjacent pixel is greater than or equal to a predetermined value, and sets zero parallax for a pixel whose luminance difference with an adjacent pixel is less than a predetermined value. Note that the parallax d is the same in the pixels in the pixel block 510 and is calculated at a predetermined timing by a known method such as the SAD method. As described above, the extraction unit 203 fuses the luminance difference information between adjacent pixels and the parallax of the pixel block 510.
Further, the extraction unit 203 counts the number of pixels having a luminance difference with the adjacent pixels equal to or greater than a predetermined value, and extracts a plurality of pixel blocks with a count result equal to or greater than the predetermined number. In the present embodiment, the extraction unit 203 extracts pixel blocks in which 10 or more pixels out of 16 pixels have a luminance difference of a predetermined value or more.

図6(C)に示すように、選択部205は、抽出部203が抽出した画素ブロック510から、Y座標の異なる少なくとも2以上の画素ブロック510を、視差情報(Y−d関数)を生成するためのポイントデータとして選択する。
このとき、図6(D)に示すように、プラットホームP、レールRa及び枕木Rt上にノイズとして視差が算出された画素ブロック510を選択することを防止するため、検出部204は、プラットホームP、レールRa及び枕木Rtの位置を検出する。
As illustrated in FIG. 6C, the selection unit 205 generates disparity information (Yd function) for at least two or more pixel blocks 510 having different Y coordinates from the pixel block 510 extracted by the extraction unit 203. Select as point data for.
At this time, as shown in FIG. 6D, in order to prevent selecting the pixel block 510 in which the parallax is calculated as noise on the platform P, the rail Ra, and the sleeper Rt, the detection unit 204 includes the platform P, The positions of the rail Ra and the sleepers Rt are detected.

具体的には、図7(E)に示すように、検出部204は、距離画像53をX方向に走査し、視差ゼロである画素数を計数し、視差ゼロである画素数に基づいて、プラットホームP及びレールRaの位置(Y座標)を検出する。
図7(F)は、Y座標と視差ゼロの画素数との関係を示すヒストグラムである。本実施形態のようにバラスト軌道を撮影する場合、撮影画像のX方向に沿って延びるプラットホームP及びレールRaの位置(Y座標)では、視差ゼロの画素数が多くなる。一方、砂利Rbの位置(Y座標)では、視差が算出されるため、視差ゼロの画素数が少なくなる。
Specifically, as illustrated in FIG. 7E, the detection unit 204 scans the distance image 53 in the X direction, counts the number of pixels with zero parallax, and based on the number of pixels with zero parallax, The positions (Y coordinates) of the platform P and the rail Ra are detected.
FIG. 7F is a histogram showing the relationship between the Y coordinate and the number of pixels with zero parallax. When the ballast trajectory is imaged as in the present embodiment, the number of pixels with zero parallax increases at the position (Y coordinate) of the platform P and the rail Ra extending along the X direction of the captured image. On the other hand, since the parallax is calculated at the gravel Rb position (Y coordinate), the number of pixels with zero parallax is reduced.

検出部204は、視差ゼロの画素数が多いY座標のうち、Y座標が最も大きいものをプラットホームPと検出し、Y座標が次に大きいものを2本のレールRaの手前側のレールRa(以下、「下部レールRad」と呼ぶ)と検出し、Y座用が次に大きいものを2本のレールRaの奥側のレールRa(以下、「上部レールRau」と呼ぶ)と検出する。
また、検出部204は、上部レールRauの位置(Y座標)を座標R1とし、下部レールRadの位置(Y座標)を座標R2とする。
The detection unit 204 detects a Y coordinate having the largest Y coordinate among the Y coordinates having a large number of pixels with zero parallax as the platform P, and detects the next largest Y coordinate on the rail Ra (in front of the two rails Ra ( Hereinafter, it is detected as “lower rail Rad”, and the next largest for the Y seat is detected as a rail Ra on the back side of the two rails Ra (hereinafter referred to as “upper rail Rau”).
Further, the detection unit 204 sets the position (Y coordinate) of the upper rail Rau as the coordinate R1, and sets the position (Y coordinate) of the lower rail Rad as the coordinate R2.

上部レールRau及び下部レールRadの位置を検出すると、検出部204は、続いて、枕木Rtの位置(X座標)を検出する。
具体的には、検出部204は、上部レールRau及び下部レールRad間を所定数に分割する。本実施形態では、図7(G)に示すように、上部レールRau及び下部レールRad間を3分割にする。そこで、検出部204は、上部レールRau及び下部レールRad間を3分割にする位置に、夫々、座標M1,座標M2をセットする。
When the positions of the upper rail Rau and the lower rail Rad are detected, the detection unit 204 subsequently detects the position (X coordinate) of the sleeper Rt.
Specifically, the detection unit 204 divides the upper rail Rau and the lower rail Rad into a predetermined number. In the present embodiment, as shown in FIG. 7G, the upper rail Rau and the lower rail Rad are divided into three parts. Therefore, the detection unit 204 sets the coordinates M1 and M2 at positions where the space between the upper rail Rau and the lower rail Rad is divided into three.

また、枕木Rtは、レールRaよりも手前側及び奥側に延びて設置されるため、検出部204は、下部レールRadよりも手前側の位置に座標M3をセットし、上部レールRauよりも奥側の位置に座標M4をセットする。
なお、検出部204は、「下部レールRadの座標R2+α1」を座標M3としてセットし、「上部レールRauの座標R1−α2」を、座標M4としてセットする。このとき、α1及びα2は、実験等により経験的に設定される値である。
Further, since the sleepers Rt are installed to extend to the near side and the far side with respect to the rail Ra, the detection unit 204 sets the coordinate M3 at a position on the near side with respect to the lower rail Rad, and further to the far side than the upper rail Rau. The coordinate M4 is set at the side position.
The detecting unit 204 sets “coordinate R2 + α1 of the lower rail Rad” as the coordinate M3, and sets “coordinate R1-α2 of the upper rail Rau” as the coordinate M4. At this time, α1 and α2 are values empirically set by experiments or the like.

続いて、検出部204は、座標M1から座標M4の夫々について、距離画像53をX方向に走査し、画素ブロック510単位での視差ゼロの画素数を計数する。図8(H)は、画素ブロック510のX座標と、当該画素ブロック510内の視差ゼロの画素数との関係を示すヒストグラムである。
枕木Rtでは視差が算出できないため、枕木Rtの位置(X座標)の画素ブロック510内では、視差ゼロの画素数が多くなる。一方、砂利Rbでは、視差が算出されるため、砂利Rbの位置(X座標)の画素ブロック510内では、視差ゼロの画素数が少なくなる。検出部204は、画素ブロック510内の視差ゼロの画素数に基づいて、枕木Rtの位置(X座標)を検出する。
Subsequently, the detection unit 204 scans the distance image 53 in the X direction for each of the coordinates M1 to M4, and counts the number of pixels with zero parallax for each pixel block 510 unit. FIG. 8H is a histogram showing the relationship between the X coordinate of the pixel block 510 and the number of pixels with zero parallax in the pixel block 510.
Since the parallax cannot be calculated in the sleeper Rt, the number of pixels with zero parallax increases in the pixel block 510 at the position (X coordinate) of the sleeper Rt. On the other hand, since the parallax is calculated for the gravel Rb, the number of pixels with zero parallax is reduced in the pixel block 510 at the position (X coordinate) of the gravel Rb. The detection unit 204 detects the position (X coordinate) of the sleeper Rt based on the number of pixels with zero parallax in the pixel block 510.

検出部204がレールRa及び枕木Rtの位置を検出すると、選択部205は、レールRa及び枕木Rtの位置以外に位置する複数の画素ブロック510から2以上の画素ブロックを選択する。即ち、検出部204は、砂利Rbの位置に位置する2以上の画素ブロック510を選択する。より具体的には、選択部205は、視差ゼロの画素数が閾値未満である画素ブロック510がn個以上連続している部分を、砂利Rbの位置と特定し、当該部分から任意の画素ブロック510を選択する。   When the detection unit 204 detects the positions of the rail Ra and the sleeper Rt, the selection unit 205 selects two or more pixel blocks from the plurality of pixel blocks 510 positioned other than the position of the rail Ra and the sleeper Rt. That is, the detection unit 204 selects two or more pixel blocks 510 located at the gravel Rb position. More specifically, the selection unit 205 identifies a portion where n or more pixel blocks 510 in which the number of pixels with zero parallax is less than the threshold value is continuous as the position of the gravel Rb, and determines an arbitrary pixel block from the portion. 510 is selected.

本実施形態では、選択部205は、図8(I)に示すように、座標M1から座標M4(Y座標)の夫々について、枕木Rt以外の位置(X座標)に位置する画素ブロック510を選択する。
選択部205が座標M1から座標M4の夫々から画素ブロックを選択すると、生成部207は、これら画素ブロックに対して算出された視差、及びこれら画素ブロックのY座標に基づいて、視差情報(Y−d関数)を生成する。
In the present embodiment, the selection unit 205 selects the pixel block 510 located at a position (X coordinate) other than the sleeper Rt for each of the coordinates M1 to M4 (Y coordinate) as shown in FIG. 8 (I). To do.
When the selection unit 205 selects a pixel block from each of the coordinates M1 to M4, the generation unit 207 generates disparity information (Y−) based on the disparity calculated for these pixel blocks and the Y coordinate of these pixel blocks. d function).

なお、視差とY方向の座標との関係は、撮影画像の中央領域とそれ以外の領域とで異なることがある。そこで、本実施形態では、図8(J)に示すように、撮影画像をX方向に分割し、分割した複数の領域の夫々について視差情報を生成することとしてもよい。
図8(J)のように撮影画像を3分割する場合、選択部205は、X方向の座標が異なる左側領域61、中央領域62及び右側領域63の夫々において、2以上の画素ブロックを選択し、生成部207は、左側領域61、中央領域62及び右側領域63の夫々に関連付けて、視差情報(Y−d関数)を生成する。
Note that the relationship between the parallax and the coordinates in the Y direction may differ between the central region of the captured image and other regions. Therefore, in the present embodiment, as shown in FIG. 8J, the captured image may be divided in the X direction, and disparity information may be generated for each of the divided areas.
When the captured image is divided into three as illustrated in FIG. 8J, the selection unit 205 selects two or more pixel blocks in each of the left region 61, the central region 62, and the right region 63 having different X-direction coordinates. The generation unit 207 generates disparity information (Yd function) in association with each of the left region 61, the central region 62, and the right region 63.

[異物検知機能]
図4に戻り、異物検知機能は、視差情報生成機能により生成した視差情報を用いて、撮影装置101が撮影した画像から異物(例えば、線路Rに落下した異物)を検知する。
このような異物検知機能を実現するため、制御部201は、探索部208と、出力部209と、を含んで構成される。
[Foreign matter detection function]
Returning to FIG. 4, the foreign object detection function detects a foreign object (for example, a foreign object dropped on the track R) from the image captured by the imaging apparatus 101 using the parallax information generated by the parallax information generation function.
In order to realize such a foreign object detection function, the control unit 201 includes a search unit 208 and an output unit 209.

探索部208は、第1画像51と第2画像52との所定座標における視差が、視差情報(Y−d関数)が規定する当該座標の視差に対して所定量以上異なる画素ブロックを異常画素ブロックとして抽出する。即ち、探索部208は、距離画像53を探索し、距離画像53を構成する複数の画素ブロックから異常画素ブロックを検出する。
出力部209は、探索部208が異常画素ブロックを検出することを条件に、警告情報を出力する。なお、出力部209は、任意の方法で警告情報を出力することができ、例えば、モニタ400に所定の情報を表示することで警告情報を出力することとしてもよく、また、スピーカ(不図示)から所定の音声を発することで警告情報を出力することとしてもよい。
The search unit 208 determines a pixel block in which the parallax at a predetermined coordinate between the first image 51 and the second image 52 is different from the parallax of the coordinate specified by the parallax information (Yd function) by a predetermined amount or more. Extract as That is, the search unit 208 searches the distance image 53 and detects an abnormal pixel block from a plurality of pixel blocks constituting the distance image 53.
The output unit 209 outputs warning information on condition that the search unit 208 detects an abnormal pixel block. The output unit 209 can output warning information by an arbitrary method. For example, the output unit 209 may output warning information by displaying predetermined information on the monitor 400, and a speaker (not shown). The warning information may be output by uttering a predetermined sound.

[異物検知機能の一例]
続いて、図9を参照して、異物検知機能の具体的な処理の流れの一例について説明する。
図9(A)に示すように、探索部208は、線路Rの幅方向と略一致する矩形探索エリア530を探索し、異常画素ブロックを抽出する。矩形探索エリア530は、プラットホームPの線路R側端から、上部レールRauより奥側所定量(例えば、実世界における20cm相当)までを覆う領域であり、図9(B)に示すように、Y方向に沿って配置された複数の画素ブロック510により構成される。
[Example of foreign object detection function]
Next, an example of a specific processing flow of the foreign object detection function will be described with reference to FIG.
As shown in FIG. 9A, the search unit 208 searches a rectangular search area 530 that substantially matches the width direction of the line R, and extracts abnormal pixel blocks. The rectangular search area 530 is an area that covers a predetermined amount (for example, equivalent to 20 cm in the real world) beyond the upper rail Rau from the end of the platform P on the track R side, as shown in FIG. It is composed of a plurality of pixel blocks 510 arranged along the direction.

ここで、図9では、矩形探索エリア530に含まれる画素ブロック510のうち、Y座標が最も小さい画素ブロック510について視差情報に基づいて算出される視差を視差d1とし、Y座標が次に小さい画素ブロックについて視差情報に基づいて算出される視差を視差d2、・・・、Y座標が最も大きい画素ブロックについて視差情報に基づいて算出される視差を視差dnとする。
図5に示す視差情報(Y−d関数)を参照すると、Y座標が小さい(奥側)ほど視差は小さく、Y座標が大きい(手前側)ほど視差は大きいため、視差d1が最も小さい視差であり、視差dnが最も大きい視差である。
Here, in FIG. 9, among the pixel blocks 510 included in the rectangular search area 530, the disparity calculated based on the disparity information for the pixel block 510 having the smallest Y coordinate is the disparity d1, and the pixel having the next smallest Y coordinate. The disparity calculated based on the disparity information for the block is referred to as disparity d2,..., And the disparity calculated based on the disparity information for the pixel block having the largest Y coordinate is referred to as disparity dn.
Referring to the parallax information (Yd function) shown in FIG. 5, since the parallax is smaller as the Y coordinate is smaller (back side) and the parallax is larger as the Y coordinate is larger (front side), the parallax d1 is the smallest parallax. Yes, the parallax dn is the largest parallax.

図9(C−a)及び図9(D−a)に撮影装置101からみた線路Rを示す。撮影装置101は、所定の角度を持ってプラットホームPの上部に設置されるため、同図に示すように、撮影装置101からみると線路Rは傾斜してみえる。
また、図9(C−b)及び図9(D−b)に、矩形探索エリア530内における視差と画素数との関係を示すヒストグラムを示す。なお、画素ブロック510の中には視差ゼロとしてセットされる画素が存在するため、視差ゼロの画素数は多くなる。
9 (Ca) and FIG. 9 (Da) show the line R viewed from the photographing apparatus 101. FIG. Since the photographing apparatus 101 is installed at an upper portion of the platform P with a predetermined angle, the track R appears to be inclined when viewed from the photographing apparatus 101 as shown in FIG.
9C and 9D show histograms showing the relationship between the parallax and the number of pixels in the rectangular search area 530. FIG. Note that since there are pixels set as zero parallax in the pixel block 510, the number of pixels with zero parallax increases.

図9(C−a)に示すように、線路R上に異物が存在しない状況では、撮影装置101から撮影対象物(線路R)までの距離は、撮影装置101の設置角度に応じて一様に変化する。そのため、図9(C−b)に示すように、矩形探索エリア530では、視差d1から視差dnまでの視差が略均等に算出される。   As shown in FIG. 9C-a, in the situation where no foreign matter exists on the track R, the distance from the imaging device 101 to the imaging target (track R) is uniform according to the installation angle of the imaging device 101. To change. Therefore, as shown in FIG. 9C-B, in the rectangular search area 530, the parallax from the parallax d1 to the parallax dn is calculated approximately equally.

これに対して、図9(D−a)に示すように、線路R上に異物70が存在する状況では、撮影対象物(線路R、異物70)までの距離が、異物70の存在により変化する。そのため、図9(D−b)に示すように、異物が存在しない状況と比較すると、視差d1から視差dnまでの分布状況が異なることになる。即ち、異物70に対応する画素ブロック510(異常画素ブロック)において異常な視差が算出される。   On the other hand, as shown in FIG. 9 (D-a), in the situation where the foreign object 70 exists on the track R, the distance to the object to be photographed (the track R, the foreign object 70) changes due to the presence of the foreign object 70. To do. Therefore, as shown in FIG. 9 (D-b), the distribution situation from the parallax d1 to the parallax dn is different from the situation where no foreign matter is present. That is, abnormal parallax is calculated in the pixel block 510 (abnormal pixel block) corresponding to the foreign object 70.

探索部208は、矩形探索エリア530において算出された視差のうち、視差ゼロ以外で閾値を超え、且つ、最も多い画素数が計数された視差を異物70に基づく視差とし、異常視差dyとして抽出する。探索部208は、この異常視差dyに対応するY座標を、上記式(1)を変形した式(2)から算出する。
Y=(dy−β)/α・・・式(2)
The search unit 208 extracts the parallax calculated in the rectangular search area 530 as parallax based on the foreign substance 70 as parallax based on the foreign matter 70, which has exceeded the threshold value except for zero parallax and counted the largest number of pixels. . The search unit 208 calculates a Y coordinate corresponding to the abnormal parallax dy from Expression (2) obtained by modifying Expression (1).
Y = (dy−β) / α (2)

なお、式(2)により算出されるY座標は、異物70の始点を示すY座標である。そこで、出力部209は、図9(E)に示すように、算出したY座標(始点)から所定範囲(例えば、1m)の領域を短冊矩形71として示し、異物70の存在をモニタ400に対して表示する。   Note that the Y coordinate calculated by the equation (2) is a Y coordinate indicating the starting point of the foreign material 70. Therefore, as shown in FIG. 9E, the output unit 209 displays a region within a predetermined range (for example, 1 m) from the calculated Y coordinate (start point) as a strip rectangle 71, and indicates the presence of the foreign object 70 to the monitor 400. To display.

以上、データ管理装置200の機能構成について説明した。なお、データ管理装置200が備える抽出部203乃至出力部209のうちの1部の機能を複数の撮影装置101の夫々が備えることとしてもよい。即ち、本発明の画像処理装置は、データ管理装置200により実現されることとしてもよく、また、複数の撮影装置101の夫々により実現されることとしてもよく、また、データ管理装置200と複数の撮影装置101の夫々とにより実現されることとしてもよい。   The functional configuration of the data management apparatus 200 has been described above. Note that each of the plurality of imaging devices 101 may have a function of one of the extraction unit 203 to the output unit 209 included in the data management device 200. In other words, the image processing apparatus of the present invention may be realized by the data management apparatus 200, may be realized by each of the plurality of imaging apparatuses 101, or may be realized by the data management apparatus 200 and the plurality of data management apparatuses 200. It may be realized by each of the imaging devices 101.

[撮影システム10の処理]
続いて、図10及び図11を参照して、本発明の撮影システム10の処理の流れについて説明する。
[Processing of Imaging System 10]
Next, with reference to FIG. 10 and FIG. 11, a processing flow of the photographing system 10 of the present invention will be described.

図10は、視差情報生成機能に基づく視差情報生成処理の流れを示すフローチャートである。
初めに、撮影装置101は、線路Rを撮影し、第1画像51、第2画像52及び距離画像53を取得する(ステップS1)。続いて、データ管理装置200の抽出部203は、輝度情報に基づいて視差有の画素ブロック510を抽出する(ステップS2)。即ち、抽出部203は、第1画像51を参照して、隣接する画素との輝度差が所定以上の画素により構成される複数の画素ブロック510を抽出する。
FIG. 10 is a flowchart showing the flow of the disparity information generation process based on the disparity information generation function.
First, the imaging device 101 captures the track R, and acquires the first image 51, the second image 52, and the distance image 53 (step S1). Subsequently, the extraction unit 203 of the data management apparatus 200 extracts the pixel block 510 with parallax based on the luminance information (step S2). That is, the extraction unit 203 refers to the first image 51 and extracts a plurality of pixel blocks 510 configured by pixels having a luminance difference with an adjacent pixel equal to or greater than a predetermined value.

続いて、検出部204は、レールRaの位置を検出する(ステップS3)。この処理では、検出部204は、距離画像53をX方向に走査し、視差ゼロである画素数を計数し、視差ゼロである画素数に基づいて、レールRaの位置(Y座標)を検出する。
また、検出部204は、枕木Rtの位置を検出する(ステップS4)。この処理では、検出部204は、上部レールRau及び下部レールRadの間のY座標、上部レールRauよりも奥側のY座標、並びに下部レールRadよりも手前側のY座標に位置する画素ブロックをX方向に走査し、画素ブロック510単位での視差ゼロの画素数に基づいて、枕木Rtの位置(X座標)を検出する。
Subsequently, the detection unit 204 detects the position of the rail Ra (step S3). In this process, the detection unit 204 scans the distance image 53 in the X direction, counts the number of pixels with zero parallax, and detects the position (Y coordinate) of the rail Ra based on the number of pixels with zero parallax. .
Moreover, the detection part 204 detects the position of the sleeper Rt (step S4). In this process, the detection unit 204 detects pixel blocks located at the Y coordinate between the upper rail Rau and the lower rail Rad, the Y coordinate on the far side from the upper rail Rau, and the Y coordinate on the near side from the lower rail Rad. Scanning in the X direction, the position (X coordinate) of the sleeper Rt is detected based on the number of pixels with zero parallax in the pixel block 510 unit.

続いて、選択部205は、線路R内のレールRa及び枕木Rt以外の部分、即ち砂利Rbに位置する画素ブロック510をポイントデータとして選択する(ステップS5)。続いて、生成部207は、ポイントデータとして選択した画素ブロック510において算出された視差、及び当該画素ブロック510のY座標に基づいて、上記式(1)に示す視差情報(Y−d関数)を生成し(ステップS6)、処理を終了する。   Subsequently, the selection unit 205 selects, as point data, a pixel block 510 located in a portion other than the rail Ra and sleepers Rt in the track R, that is, gravel Rb (step S5). Subsequently, the generation unit 207 calculates the disparity information (Yd function) shown in the above formula (1) based on the disparity calculated in the pixel block 510 selected as the point data and the Y coordinate of the pixel block 510. Generate (step S6), and the process ends.

図11は、異物検知機能に基づく異物検知処理の流れを示すフローチャートである。
初めに、撮影装置101は、線路Rを撮影し、第1画像51、第2画像52及び距離画像53を取得する(ステップS11)。続いて、データ管理装置200の探索部208は、距離画像53の線路R領域を探索する(ステップS12)。即ち、探索部208は、線路Rの幅方向と略一致する矩形探索エリア530を探索する。
FIG. 11 is a flowchart showing the flow of foreign object detection processing based on the foreign object detection function.
First, the imaging device 101 captures the track R, and acquires the first image 51, the second image 52, and the distance image 53 (step S11). Subsequently, the search unit 208 of the data management device 200 searches for the track R region of the distance image 53 (step S12). That is, the search unit 208 searches for a rectangular search area 530 that substantially matches the width direction of the line R.

続いて、探索部208は、視差の分布状況を取得する(ステップS13)。即ち、探索部208は、矩形探索エリア530における視差と当該視差が算出された画素数との関係を示すヒストグラムを生成する。続いて、探索部208は、所定画素数以上が計数された視差があるか否かを判定する(ステップS14)。この判定がYESのとき、探索部208は、探索した矩形探索エリア530内に異物があると判定し(ステップS15)、ステップS16に処理を移す。他方、この判定がNOのとき、探索した矩形探索エリア530内に異物がないため、探索部208は、処理を終了し、次の矩形探索エリア530の探索に移る。   Subsequently, the search unit 208 acquires the disparity distribution state (step S13). That is, the search unit 208 generates a histogram indicating the relationship between the parallax in the rectangular search area 530 and the number of pixels for which the parallax has been calculated. Subsequently, the search unit 208 determines whether there is a parallax in which a predetermined number of pixels or more are counted (step S14). When this determination is YES, the search unit 208 determines that there is a foreign object in the searched rectangular search area 530 (step S15), and moves the process to step S16. On the other hand, when this determination is NO, since there is no foreign object in the searched rectangular search area 530, the search unit 208 ends the process and moves to searching for the next rectangular search area 530.

ステップS16では、探索部208は、視差情報(Y−d関数)に基づいて異物の場所(Y座標)を特定する。また、出力部209は、特定したY座標から所定範囲の領域を短冊矩形71として示し、異物70の存在をモニタ400に対して表示する。この処理を終えると、探索部208は、次の矩形探索エリア530の探索に移る。   In step S16, the search unit 208 identifies the location (Y coordinate) of the foreign object based on the parallax information (Yd function). In addition, the output unit 209 displays an area within a predetermined range from the specified Y coordinate as a strip rectangle 71 and displays the presence of the foreign substance 70 on the monitor 400. When this processing is finished, the search unit 208 moves to search for the next rectangular search area 530.

[撮影システム10における効果]
以上、本発明の実施形態について説明した。続いて、撮影システム10における効果について説明する。
[Effect in the photographing system 10]
The embodiment of the present invention has been described above. Next, effects in the imaging system 10 will be described.

プラットホームPの上部に所定の角度を持って設置される撮影装置101では、撮影装置101から線路Rまでの距離が手前側と奥側とで異なる。そのため、撮影装置101で撮影した第1画像51と第2画像52との視差も手前側と奥側とで異なる。この点、撮影システム10では、撮影装置101からの距離(Y座標)と視差との関係を示す視差情報(Y−d関数)を生成する。
これにより、生成した視差情報を用いて容易に異物を検知できるため、レール面が視差ゼロになるように調整する必要がなく、撮影装置101の設置を容易に行うことができる。
In the photographing apparatus 101 installed at an upper portion of the platform P with a predetermined angle, the distance from the photographing apparatus 101 to the track R is different between the near side and the far side. For this reason, the parallax between the first image 51 and the second image 52 photographed by the photographing apparatus 101 is also different between the near side and the far side. In this regard, the imaging system 10 generates parallax information (Yd function) indicating the relationship between the distance (Y coordinate) from the imaging apparatus 101 and the parallax.
Thereby, since the foreign object can be easily detected using the generated parallax information, it is not necessary to adjust the rail surface so that the parallax is zero, and the photographing apparatus 101 can be easily installed.

このとき、撮影システム10では、視差情報を生成するためのポイントデータを、隣接する画素との輝度差が所定以上の画素により構成される画素ブロック510の中から選択する。
これにより、類似する輝度の画素のみから構成される画素ブロック510をポイントデータとして選択することがなく、各画素の輝度パターンに特徴のある画素ブロック510をポイントデータとして選択することができる。輝度パターンに特徴のある画素ブロック510は、視差の算出に適しているため、適切な視差情報を生成することができ、好適である。
At this time, the imaging system 10 selects point data for generating disparity information from the pixel block 510 configured by pixels having a luminance difference with an adjacent pixel equal to or greater than a predetermined value.
As a result, the pixel block 510 composed only of pixels having similar luminance is not selected as point data, and the pixel block 510 having a characteristic luminance pattern of each pixel can be selected as point data. Since the pixel block 510 having a characteristic luminance pattern is suitable for calculating parallax, it can generate appropriate parallax information, which is preferable.

また、撮影システム10では、線路R内の上部レールRau及び下部レールRadの位置を検出するとともに、上部レールRauよりも奥側に位置する画素ブロック510を少なくとも1つ選択する。これにより、算出する視差情報の精度を高めることができ好適である。   In addition, the imaging system 10 detects the positions of the upper rail Rau and the lower rail Rad in the track R, and selects at least one pixel block 510 located on the back side of the upper rail Rau. Thereby, the accuracy of the calculated parallax information can be improved, which is preferable.

このとき、撮影システム10では、複数の画素ブロック510における視差に基づいて、レールRaが位置する座標を検出する。即ち、撮影システム10では、視差ゼロの画素数の多いY座標を、レールRaが位置する座標として検出する。また、撮影システム10では、枕木Rtの位置を検出し、レールRa及び枕木Rt以外の位置に位置する画素ブロック510をポイントデータとして選択する。
これにより、レールRa及び枕木Rt上にノイズとして算出された視差に基づいて視差情報を生成することを防止でき、算出する視差情報の精度を高めることができる。
At this time, the imaging system 10 detects the coordinates where the rail Ra is located based on the parallax in the plurality of pixel blocks 510. That is, in the imaging system 10, the Y coordinate having a large number of pixels with zero parallax is detected as the coordinate where the rail Ra is located. Moreover, in the imaging | photography system 10, the position of sleeper Rt is detected and the pixel block 510 located in positions other than rail Ra and sleeper Rt is selected as point data.
Thereby, it can prevent generating parallax information based on the parallax computed as noise on rail Ra and sleeper Rt, and can raise the accuracy of parallax information to compute.

また、撮影システム10では、撮影画像の領域(左側領域61、中央領域62及び右側領域63)に応じて視差情報を算出するため、算出する視差情報の精度を高めることができ、好適である。   Moreover, in the imaging system 10, since the parallax information is calculated according to the area of the captured image (the left area 61, the center area 62, and the right area 63), the accuracy of the calculated parallax information can be improved, which is preferable.

また、撮影システム10では、距離画像53内に、視差情報に対して異常な視差が算出された異常画素ブロックが存在する場合に、警告情報を出力するため、線路Rに落下した異物70を容易に検出することができ、鉄道車両の安全運行に寄与することができる。   Further, in the imaging system 10, when there is an abnormal pixel block in which an abnormal parallax is calculated with respect to the parallax information in the distance image 53, warning information is output, and thus the foreign object 70 that has fallen on the track R can be easily removed. And can contribute to the safe operation of railway vehicles.

以上、本発明を実施の形態を用いて説明したが、本発明の技術的範囲は上記実施の形態に記載の範囲には限定されない。上記実施の形態に、多様な変更又は改良を加えることが可能であることが当業者に明らかである。その様な変更又は改良を加えた形態も本発明の技術的範囲に含まれ得ることが、特許請求の範囲の記載から明らかである。   As mentioned above, although this invention was demonstrated using embodiment, the technical scope of this invention is not limited to the range as described in the said embodiment. It will be apparent to those skilled in the art that various modifications or improvements can be added to the above embodiment. It is apparent from the description of the scope of claims that embodiments with such changes or improvements can be included in the technical scope of the present invention.

例えば、上記実施形態では、異物検知機能において、視差と当該視差が算出された画素数との関係から、異物70を検知することとしている(図9(D−b)参照)。この点、図12に示すように、矩形探索エリア530に含まれる画素ブロック510の視差d及びY座標と、視差情報(Y−d)関数に基づいて算出される当該Y座標における視差dとから、異物70を検知することとしてもよい。即ち、画素ブロック510に対して算出された視差dが、当該画素ブロック510のY座標に対して視差情報(Y−d関数)から算出される視差(d(y))を所定以上上回る画素ブロック510を異常画素ブロックとして抽出することで、異物70を検知することとしてもよい。   For example, in the above-described embodiment, the foreign object detection function detects the foreign object 70 from the relationship between the parallax and the number of pixels for which the parallax is calculated (see FIG. 9D). In this regard, as shown in FIG. 12, the parallax d and Y coordinate of the pixel block 510 included in the rectangular search area 530 and the parallax d at the Y coordinate calculated based on the parallax information (Yd) function. Alternatively, the foreign object 70 may be detected. That is, the pixel block in which the parallax d calculated for the pixel block 510 exceeds the parallax (d (y)) calculated from the parallax information (Yd function) with respect to the Y coordinate of the pixel block 510 by a predetermined amount or more. The foreign object 70 may be detected by extracting 510 as an abnormal pixel block.

10・・・撮影システム、100・・・撮影装置群、101・・・撮影装置、200・・・データ管理装置(画像処理装置)、201・・・制御部、202・・・記憶部、203・・・抽出部、204・・・検出部、205・・・選択部、206・・・取得部、207・・・生成部、208・・・探索部、209・・・出力部、300・・・ハブ、400・・・モニタ DESCRIPTION OF SYMBOLS 10 ... Shooting system, 100 ... Shooting device group, 101 ... Shooting device, 200 ... Data management device (image processing device), 201 ... Control unit, 202 ... Storage unit, 203 ... Extraction unit, 204 ... Detection unit, 205 ... Selection unit, 206 ... Acquisition unit, 207 ... Generation unit, 208 ... Search unit, 209 ... Output unit, 300 ..Hub, 400 ... monitor

Claims (6)

複数の撮影部が第1方向に沿って配置されたステレオカメラの第1撮影部で撮影した第1画像から、隣接する画素との輝度差が所定以上の画素により構成される複数の画素ブロックを抽出する抽出部と、
前記抽出部が抽出した複数の前記画素ブロックから、少なくとも前記第1方向と直交する第2方向の座標が異なる2以上の画素ブロックを選択する選択部と、
前記選択部が選択した前記2以上の画素ブロックの夫々について、ステレオカメラの第2撮影部で撮影された第2画像との視差を取得する取得部と、
前記取得部が取得した視差及び前記2以上の画素ブロックの夫々の前記第2方向の座標に基づいて、前記視差と前記第2方向の座標との関係を示す視差情報を生成する生成部と、
を備える画像処理装置。
A plurality of pixel blocks configured by pixels having a luminance difference with a neighboring pixel or more from a first image captured by a first imaging unit of a stereo camera in which a plurality of imaging units are arranged along a first direction. An extractor for extracting;
A selection unit that selects at least two pixel blocks having different coordinates in a second direction orthogonal to the first direction from the plurality of pixel blocks extracted by the extraction unit;
An acquisition unit that acquires a parallax with the second image captured by the second imaging unit of the stereo camera for each of the two or more pixel blocks selected by the selection unit;
A generating unit that generates disparity information indicating a relationship between the parallax and the coordinate in the second direction based on the parallax acquired by the acquisition unit and the coordinate in the second direction of each of the two or more pixel blocks;
An image processing apparatus comprising:
前記ステレオカメラは、前記第1方向に沿って延びるプラットホームに設置され、前記プラットホームの周辺を俯瞰的に撮影するステレオカメラであり、
前記プラットホームの側面に前記第1方向に沿って延びる線路のレールの、撮影画像における位置を示す前記第2方向の座標を検出する検出部を更に備え、
前記選択部は、前記第2方向の座標が、前記レールが位置する座標よりも前記ステレオカメラから離れる方向に位置する少なくとも一の画素ブロックを選択する、
請求項1に記載の画像処理装置。
The stereo camera is a stereo camera that is installed on a platform extending along the first direction and photographs the periphery of the platform from a bird's-eye view,
A detector for detecting coordinates in the second direction indicating a position in a captured image of a rail of a rail extending along the first direction on a side surface of the platform;
The selection unit selects at least one pixel block in which the coordinate in the second direction is located in a direction away from the stereo camera than the coordinate in which the rail is located;
The image processing apparatus according to claim 1.
前記検出部は、前記複数の画素ブロックにおける視差に基づいて、前記レールが位置する座標を検出する、
請求項2に記載の画像処理装置。
The detection unit detects coordinates where the rail is located based on parallax in the plurality of pixel blocks.
The image processing apparatus according to claim 2.
前記検出部は、前記線路の枕木の位置を検出し、
前記選択部は、前記検出部が検出した前記枕木の位置以外に位置する複数の前記画素ブロックから前記2以上の画素ブロックを選択する、
請求項2又は3に記載の画像処理装置。
The detection unit detects the position of sleepers on the track,
The selection unit selects the two or more pixel blocks from a plurality of the pixel blocks located other than the position of the sleepers detected by the detection unit;
The image processing apparatus according to claim 2.
前記選択部は、前記第1方向の座標が所定範囲内の第1領域、及び前記所定範囲外の第2領域の夫々において、前記2以上の画素ブロックを選択し、
前記生成部は、前記第1領域及び前記第2領域の夫々に関連付けて、前記視差情報を生成する、
請求項1から4のいずれかに記載の画像処理装置。
The selection unit selects the two or more pixel blocks in each of a first region whose coordinates in the first direction are within a predetermined range and a second region outside the predetermined range;
The generation unit generates the disparity information in association with each of the first region and the second region.
The image processing apparatus according to claim 1.
前記第1画像と前記第2画像との所定座標における視差が、前記視差情報が規定する当該座標の視差に対して所定量以上異なる異常画素ブロックを探索する探索部と、
前記探索部が前記異常画素ブロックを検出することを条件に、警告情報を出力する出力部と、
を更に備える請求項1から4のいずれかに記載の画像処理装置。
A search unit that searches for an abnormal pixel block in which a parallax at a predetermined coordinate between the first image and the second image differs by a predetermined amount or more with respect to the parallax of the coordinate specified by the parallax information;
An output unit that outputs warning information on condition that the search unit detects the abnormal pixel block;
The image processing apparatus according to claim 1, further comprising:
JP2014060376A 2014-03-24 2014-03-24 Image processing device Active JP6299317B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2014060376A JP6299317B2 (en) 2014-03-24 2014-03-24 Image processing device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2014060376A JP6299317B2 (en) 2014-03-24 2014-03-24 Image processing device

Publications (2)

Publication Number Publication Date
JP2015184896A JP2015184896A (en) 2015-10-22
JP6299317B2 true JP6299317B2 (en) 2018-03-28

Family

ID=54351357

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2014060376A Active JP6299317B2 (en) 2014-03-24 2014-03-24 Image processing device

Country Status (1)

Country Link
JP (1) JP6299317B2 (en)

Family Cites Families (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP4041678B2 (en) * 2002-02-22 2008-01-30 東日本旅客鉄道株式会社 Home fallen person detection method and apparatus
JP4150223B2 (en) * 2002-07-10 2008-09-17 富士重工業株式会社 Level crossing monitoring device and level crossing monitoring method
JP4018950B2 (en) * 2002-08-05 2007-12-05 富士重工業株式会社 Stereo camera misalignment inspection apparatus and misalignment inspection method
JP4937933B2 (en) * 2008-01-18 2012-05-23 富士重工業株式会社 Outside monitoring device
JP2011024079A (en) * 2009-07-17 2011-02-03 Konica Minolta Opto Inc Peripheral display device

Also Published As

Publication number Publication date
JP2015184896A (en) 2015-10-22

Similar Documents

Publication Publication Date Title
US9704404B2 (en) Lane detection apparatus and operating method for the same
CN110088802B (en) Object detection device
JP6054777B2 (en) Stereo camera device
JP5068134B2 (en) Target area dividing method and target area dividing apparatus
JP2008140370A (en) Stereo camera intrusion detection system
KR101326943B1 (en) Overtaking vehicle warning system and overtaking vehicle warning method
JP6544257B2 (en) INFORMATION PROCESSING SYSTEM, INFORMATION PROCESSING METHOD, AND INFORMATION PROCESSING PROGRAM
JP5101429B2 (en) Image monitoring device
US20170358089A1 (en) Object identifying apparatus
JP6699179B2 (en) Image processing device
JP6299317B2 (en) Image processing device
JP4696925B2 (en) Image processing device
KR101420242B1 (en) vehicle detector and method using stereo camera
KR101811385B1 (en) Apparatus and method for monitoring tram crossroads
JP6471541B2 (en) Image processing device
JP6476945B2 (en) Image processing device
KR101907852B1 (en) Method and Apparatus for Processing Stereo Images
JP2002002485A (en) Track recognition device and railway rolling stock using track recognition device
JP6988860B2 (en) Information processing system, information processing method and information processing program
JP6405765B2 (en) Imaging apparatus and determination method
JP6672800B2 (en) Image processing device
JP2022151740A (en) Method for determining images with possibility of having false negative object detection
JP2015069380A (en) Vehicle exterior environment recognition device
JP7180739B2 (en) Information processing device, information processing system, information processing method and information processing program
JP7014021B2 (en) Image processing device and monitoring area setting method

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20170105

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20171225

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

Free format text: JAPANESE INTERMEDIATE CODE: A01

Effective date: 20180130

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20180212

R150 Certificate of patent or registration of utility model

Ref document number: 6299317

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150