JP2019191763A - Vehicle detection device and vehicle detection method - Google Patents

Vehicle detection device and vehicle detection method Download PDF

Info

Publication number
JP2019191763A
JP2019191763A JP2018081661A JP2018081661A JP2019191763A JP 2019191763 A JP2019191763 A JP 2019191763A JP 2018081661 A JP2018081661 A JP 2018081661A JP 2018081661 A JP2018081661 A JP 2018081661A JP 2019191763 A JP2019191763 A JP 2019191763A
Authority
JP
Japan
Prior art keywords
vehicle
straight line
captured image
image
unit
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
JP2018081661A
Other languages
Japanese (ja)
Inventor
章 寺谷
Akira Teratani
章 寺谷
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.)
Saxa Inc
Original Assignee
Saxa 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 Saxa Inc filed Critical Saxa Inc
Priority to JP2018081661A priority Critical patent/JP2019191763A/en
Publication of JP2019191763A publication Critical patent/JP2019191763A/en
Pending legal-status Critical Current

Links

Images

Landscapes

  • Train Traffic Observation, Control, And Security (AREA)
  • Image Analysis (AREA)

Abstract

To improve accuracy of detecting the presence/absence of a vehicle along a platform at a railroad station.SOLUTION: An image processing device 1 according to an embodiment comprises: a straight line detection unit 112 for detecting a straight line included in a photographic image captured by an imaging unit which images an area including a railroad track on which a vehicle runs; a vehicle determination unit 113 for determining that the photographic image does not include a vehicle if the photographic image includes a straight line having an angle within a predetermined range; and an output unit 114 for outputting information which indicates whether or not the photographic image includes a vehicle on the basis of the determination made by the vehicle determination unit 113.SELECTED DRAWING: Figure 2

Description

本発明は、撮像画像において車両を検出する車両検出装置及び車両検出方法に関する。   The present invention relates to a vehicle detection device and a vehicle detection method for detecting a vehicle in a captured image.

鉄道の駅において、線路内への落下物の検出や、ホームドアの開閉の制御のために、プラットホームに停車している鉄道車両の有無を判定することが行われている。車両の有無を判定する監視装置として、車両が運行していない状態の雛形画像と、車両が運行している状態の現在画像との間でエッジ(輪郭)の差分を取ることによって、プラットホームに沿って進入又は進出する車両の有無を判定する装置が知られている(例えば、特許文献1参照)。   At a railway station, in order to detect a fallen object on a railway track and to control opening and closing of a platform door, it is determined whether or not there is a railway vehicle stopped on the platform. As a monitoring device that determines the presence or absence of a vehicle, it follows the platform by taking the difference in edge (contour) between the template image when the vehicle is not operating and the current image when the vehicle is operating There is known an apparatus for determining the presence or absence of a vehicle that enters or advances (see, for example, Patent Document 1).

特開2001−341642号公報JP 2001-341642 A

夜間等、環境の明るさが低い状態では、画像中のエッジが見えづらくなる。特許文献1に記載の装置は、雛形画像と現在画像との差分の大小に基づいて判定するため、環境の明るさが低い状態で差分が小さくなると、車両の有無を正確に判定できないという問題があった。   When the brightness of the environment is low, such as at night, the edges in the image are difficult to see. Since the apparatus described in Patent Document 1 makes a determination based on the difference between the template image and the current image, there is a problem in that the presence or absence of the vehicle cannot be accurately determined if the difference is small in a state where the brightness of the environment is low. there were.

そこで、本発明はこれらの点に鑑みてなされたものであり、鉄道駅のプラットホームに沿った車両の有無の検出精度を向上させることができる車両検出装置及び車両検出方法を提供することを目的とする。   Therefore, the present invention has been made in view of these points, and an object thereof is to provide a vehicle detection device and a vehicle detection method capable of improving the detection accuracy of the presence or absence of a vehicle along a platform of a railway station. To do.

本発明の第1の態様に係る車両検出装置は、車両が走行する線路を含む領域を撮像する撮像部によって撮像された撮像画像に含まれる直線を検出する直線検出部と、前記撮像画像が予め設定された範囲内の角度を有する前記直線を含む場合に、前記撮像画像が前記車両を含まないと判定する判定部と、前記判定部による判定に基づいて、前記撮像画像が前記車両を含むか否かを示す情報を出力する出力部と、を有する。   The vehicle detection device according to the first aspect of the present invention includes a straight line detection unit that detects a straight line included in a captured image captured by an imaging unit that captures an area including a track on which the vehicle travels, and the captured image is stored in advance. A determination unit that determines that the captured image does not include the vehicle when the straight line having an angle within a set range is included, and whether the captured image includes the vehicle based on the determination by the determination unit An output unit that outputs information indicating whether or not.

前記判定部は、前記撮像画像が前記車両の走行方向と同一の方向の前記直線を含む場合に、前記撮像画像が前記車両を含まないと判定してもよい。   The determination unit may determine that the captured image does not include the vehicle when the captured image includes the straight line in the same direction as the traveling direction of the vehicle.

前記直線検出部は、前記撮像画像の一部を検出領域として設定し、前記検出領域に含まれる前記直線を検出してもよい。   The straight line detection unit may set a part of the captured image as a detection region and detect the straight line included in the detection region.

前記直線検出部は、前記撮像画像を前記車両の走行方向に沿って分割した複数の分割画像のそれぞれに含まれる前記直線を検出し、前記判定部は、前記直線検出部が前記複数の分割画像のそれぞれで検出した前記直線に基づいて、前記車両が前記線路に沿って進入又は進出する向きを特定してもよい。   The straight line detection unit detects the straight line included in each of a plurality of divided images obtained by dividing the captured image along the traveling direction of the vehicle, and the determination unit is configured such that the straight line detection unit includes the plurality of divided images. The direction in which the vehicle enters or advances along the track may be specified based on the straight line detected in each of the above.

前記直線検出部は、前記撮像画像を2値化して輪郭を抽出した後、ハフ変換をすることによって、前記直線を検出してもよい。   The straight line detection unit may detect the straight line by performing Hough transform after binarizing the captured image and extracting a contour.

本発明の第2の態様に係る車両検出方法は、プロセッサが、車両が走行する線路を含む領域を撮像する撮像部によって撮像された撮像画像に含まれる直線を検出するステップと、前記撮像画像が予め設定された範囲内の角度を有する前記直線を含む場合に、前記撮像画像が前記車両を含まないと判定するステップと、前記判定するステップの判定に基づいて、前記撮像画像が前記車両を含むか否かを示す情報を出力するステップと、を実行する。   In the vehicle detection method according to the second aspect of the present invention, a processor detects a straight line included in a captured image captured by an imaging unit that captures an area including a track on which the vehicle travels, and the captured image includes When the image includes the straight line having an angle within a preset range, the captured image includes the vehicle based on the determination that the captured image does not include the vehicle and the determination in the determination step. Outputting information indicating whether or not.

本発明によれば、鉄道駅のプラットホームに沿った車両の有無の検出精度を向上させることができるという効果を奏する。   According to the present invention, it is possible to improve the detection accuracy of the presence or absence of a vehicle along the platform of a railway station.

第1の実施形態に係る画像処理システムの模式図である。1 is a schematic diagram of an image processing system according to a first embodiment. 第1の実施形態に係る画像処理システムのブロック図である。1 is a block diagram of an image processing system according to a first embodiment. 撮像装置が撮像した撮像画像を示す図である。It is a figure which shows the captured image which the imaging device imaged. 検出領域の座標範囲の画像を示す図である。It is a figure which shows the image of the coordinate range of a detection area. 第1の実施形態に係る直線検出部が画像中で検出した直線を示す図である。It is a figure which shows the straight line which the straight line detection part which concerns on 1st Embodiment detected in the image. 第1の実施形態に係る画像処理方法のフローチャートを示す図である。It is a figure which shows the flowchart of the image processing method which concerns on 1st Embodiment. 撮像装置が撮像した撮像画像を示す図である。It is a figure which shows the captured image which the imaging device imaged. 画像を車両の走行方向に沿って分割した分割画像を示す図である。It is a figure which shows the division | segmentation image which divided | segmented the image along the driving direction of a vehicle. 第2の実施形態に係る車両判定部が車両の進入又は進出の向きを特定する条件を示す模式図である。It is a schematic diagram which shows the conditions for which the vehicle determination part which concerns on 2nd Embodiment specifies the direction of approach or advance of a vehicle.

(第1の実施形態)
図1は、本実施形態に係る画像処理システムSの模式図である。画像処理システムSは、画像処理装置1と、撮像装置2とを含む。画像処理システムSは、その他のサーバ、端末等の機器を含んでもよい。
(First embodiment)
FIG. 1 is a schematic diagram of an image processing system S according to the present embodiment. The image processing system S includes an image processing device 1 and an imaging device 2. The image processing system S may include devices such as other servers and terminals.

撮像装置2は、駅のプラットホームPLの上部から、車両TRが走行する線路RAに向けて所定の角度となるように設置されているカメラである。撮像装置2は、プラットホームPLの周辺、すなわちプラットホームPL、車両TR及び線路RAを含む所定の撮像範囲を俯瞰的に撮像する撮像部を有する。撮像装置2は、撮像部を用いて撮像した撮像画像を、画像処理装置1に送信する。本実施形態では撮像装置2は、グレースケールの撮像画像を撮像するが、フルカラーの撮像画像を撮像してもよい。プラットホームPLの周辺における監視対象の領域を網羅して撮像できるように、任意の数の撮像装置2が配置される。   The imaging device 2 is a camera installed at a predetermined angle from the upper part of the station platform PL toward the track RA on which the vehicle TR travels. The imaging device 2 includes an imaging unit that performs a bird's-eye image of a predetermined imaging range including the periphery of the platform PL, that is, the platform PL, the vehicle TR, and the track RA. The imaging device 2 transmits the captured image captured using the imaging unit to the image processing device 1. In the present embodiment, the imaging device 2 captures a grayscale captured image, but may capture a full-color captured image. An arbitrary number of imaging devices 2 are arranged so as to cover the entire area to be monitored around the platform PL.

画像処理装置1は、撮像装置2が撮像した撮像画像に対して所定の処理を行うコンピュータである。画像処理装置1は、撮像画像に基づいて車両を検出する車両検出装置として機能するとともに、撮像画像に基づいて物体(異物)を検出する物体検出装置として機能する。画像処理装置1は、撮像装置2に有線又は無線で接続される。画像処理装置1は、撮像装置2から受信した撮像画像を用いて所定の処理を行う。   The image processing apparatus 1 is a computer that performs predetermined processing on a captured image captured by the imaging apparatus 2. The image processing device 1 functions as a vehicle detection device that detects a vehicle based on a captured image, and also functions as an object detection device that detects an object (foreign matter) based on the captured image. The image processing device 1 is connected to the imaging device 2 by wire or wirelessly. The image processing device 1 performs predetermined processing using the captured image received from the imaging device 2.

[画像処理システムSの構成]
図2は、本実施形態に係る画像処理システムSのブロック図である。図2において、矢印は主なデータの流れを示しており、図2に示したもの以外のデータの流れがあってよい。図2において、各ブロックはハードウェア(装置)単位の構成ではなく、機能単位の構成を示している。そのため、図2に示すブロックは単一の装置内に実装されてよく、あるいは複数の装置内に別れて実装されてよい。ブロック間のデータの授受は、データバス、ネットワーク、可搬記憶媒体等、任意の手段を介して行われてよい。
[Configuration of Image Processing System S]
FIG. 2 is a block diagram of the image processing system S according to the present embodiment. In FIG. 2, arrows indicate main data flows, and there may be data flows other than those shown in FIG. In FIG. 2, each block represents a functional unit configuration, not a hardware (device) unit configuration. Therefore, the blocks shown in FIG. 2 may be implemented in a single device, or may be separately implemented in a plurality of devices. Data exchange between the blocks may be performed via any means such as a data bus, a network, a portable storage medium, or the like.

画像処理装置1は、制御部11と、インタフェース12と、記憶部13と、を有する。制御部11は、画像取得部111と、直線検出部112と、車両判定部113と、出力部114と、物体検出部115とを有する。   The image processing apparatus 1 includes a control unit 11, an interface 12, and a storage unit 13. The control unit 11 includes an image acquisition unit 111, a straight line detection unit 112, a vehicle determination unit 113, an output unit 114, and an object detection unit 115.

インタフェース12は、撮像装置2との間で信号の授受をするためのインタフェースである。インタフェース12は、撮像装置2から受信した信号に所定の処理を行ってデータを取得し、取得したデータを制御部11に入力する。また、インタフェース12は、制御部11から入力されたデータに所定の処理を行って信号を生成し、生成した信号を撮像装置2に送信する。   The interface 12 is an interface for exchanging signals with the imaging device 2. The interface 12 performs predetermined processing on the signal received from the imaging device 2 to acquire data, and inputs the acquired data to the control unit 11. In addition, the interface 12 performs a predetermined process on the data input from the control unit 11 to generate a signal, and transmits the generated signal to the imaging device 2.

記憶部13は、ROM(Read Only Memory)、RAM(Random Access Memory)、ハードディスクドライブ等を含む記憶媒体である。記憶部13は、制御部11が実行するプログラムを予め記憶している。また、記憶部13は、撮像装置2が撮像した撮像画像、及び判定対象の領域を示す領域情報を記憶する。記憶部13は、画像処理装置1の外部に設けられてもよく、その場合にインタフェース12を介して制御部11との間でデータの授受を行ってもよい。   The storage unit 13 is a storage medium including a ROM (Read Only Memory), a RAM (Random Access Memory), a hard disk drive, and the like. The storage unit 13 stores a program executed by the control unit 11 in advance. Further, the storage unit 13 stores a captured image captured by the imaging device 2 and area information indicating a determination target area. The storage unit 13 may be provided outside the image processing apparatus 1, and in that case, data may be exchanged with the control unit 11 via the interface 12.

制御部11は、例えばCPU(Central Processing Unit)等のプロセッサであり、記憶部13に記憶されたプログラムを実行することにより、画像取得部111、直線検出部112、車両判定部113、出力部114及び物体検出部115として機能する。制御部11の機能の少なくとも一部は、電気回路によって実行されてもよい。また、制御部11の機能の少なくとも一部は、ネットワーク経由で実行されるプログラムによって実行されてもよい。   The control unit 11 is a processor such as a CPU (Central Processing Unit), for example, and by executing a program stored in the storage unit 13, the image acquisition unit 111, the straight line detection unit 112, the vehicle determination unit 113, and the output unit 114. And functions as the object detection unit 115. At least a part of the function of the control unit 11 may be executed by an electric circuit. Moreover, at least a part of the functions of the control unit 11 may be executed by a program executed via a network.

本実施形態に係る画像処理システムSは、図2に示す具体的な構成に限定されない。例えば画像処理装置1は、1つの装置に限られず、2つ以上の物理的に分離した装置が有線又は無線で接続されることにより構成されてもよい。   The image processing system S according to the present embodiment is not limited to the specific configuration shown in FIG. For example, the image processing apparatus 1 is not limited to one apparatus, and may be configured by connecting two or more physically separated apparatuses in a wired or wireless manner.

[車両検出方法の説明]
本実施形態に係る画像処理方法は、車両検出方法と、物体検出方法とを含む。車両検出方法において、まず撮像装置2は、所定の撮像範囲を撮像する。撮像装置2は、所定の時間間隔で定期的に撮像してもよく、あるいは画像処理装置1からの指示に従って撮像してもよい。撮像装置2は、撮像部を用いて撮像した撮像画像を画像処理装置1に送信する。
[Description of vehicle detection method]
The image processing method according to the present embodiment includes a vehicle detection method and an object detection method. In the vehicle detection method, first, the imaging device 2 images a predetermined imaging range. The imaging device 2 may periodically capture images at predetermined time intervals, or may capture images according to instructions from the image processing device 1. The imaging device 2 transmits a captured image captured using the imaging unit to the image processing device 1.

画像処理装置1の画像取得部111は、撮像装置2が撮像した撮像画像を取得し、記憶部13に記憶させる。画像取得部111は、撮像装置2が撮像する度に撮像画像を取得してもよく、撮像装置2が所定期間内に撮像した撮像画像をまとめて取得してもよい。   The image acquisition unit 111 of the image processing apparatus 1 acquires a captured image captured by the imaging apparatus 2 and stores the captured image in the storage unit 13. The image acquisition unit 111 may acquire a captured image every time the imaging device 2 captures an image, or may collectively acquire captured images captured by the imaging device 2 within a predetermined period.

なお、本実施形態では、撮像装置2は、撮像画像の水平方向が駅のプラットホームPLの長さ方向(すなわち、車両の走行方向)に相当し、垂直方向がプラットホームPLや線路RAの幅方向(すなわち、車両の走行方向に垂直な方向)に相当するように、配置される。以下では、それぞれの撮像画像において、水平方向をX方向(第1方向)、垂直方向をY方向(第2方向)とする。また、線路RAに向かって水平方向の左側から右側へ向かう向きを右向き、水平方向の右側から左側へ向かう向きを左向きとする。   In the present embodiment, in the imaging device 2, the horizontal direction of the captured image corresponds to the length direction of the platform PL of the station (that is, the traveling direction of the vehicle), and the vertical direction is the width direction of the platform PL or the line RA ( That is, it is arranged so as to correspond to a direction perpendicular to the traveling direction of the vehicle. In the following, in each captured image, the horizontal direction is the X direction (first direction), and the vertical direction is the Y direction (second direction). Further, the direction from the left side to the right side in the horizontal direction toward the track RA is set to the right side, and the direction from the right side to the left side in the horizontal direction is set to the left side.

直線検出部112は、撮像装置2が撮像した撮像画像に含まれる直線を検出する。具体的には、まず、直線検出部112は、記憶部13から、撮像装置2が撮像した撮像画像を取得する。図3(a)、図3(b)は、撮像装置2が撮像した撮像画像P1を示す図である。図3(a)の撮像画像P1では、プラットホームPLに沿って車両TRが無い状態であるため、線路RAが写っている。図3(b)の撮像画像P1では、プラットホームPLに沿って車両TRが有る状態であるため、車両TRが写っており、線路RAが車両TRに隠れている。   The straight line detection unit 112 detects a straight line included in the captured image captured by the imaging device 2. Specifically, first, the straight line detection unit 112 acquires a captured image captured by the imaging device 2 from the storage unit 13. 3A and 3B are diagrams illustrating a captured image P1 captured by the imaging device 2. FIG. In the captured image P <b> 1 in FIG. 3A, the track RA is shown because there is no vehicle TR along the platform PL. In the captured image P1 of FIG. 3B, since the vehicle TR is present along the platform PL, the vehicle TR is shown and the track RA is hidden by the vehicle TR.

次に直線検出部112は、撮像画像P1のうち線路RAを含む可能性がある一部を、直線を検出する検出領域ARとして設定する。撮像画像P1の一部を検出領域ARとして設定することによって、後述の直線の有無を判定する処理の負荷を軽減でき、線路RAとは無関係の直線が検出されることを抑制できる。   Next, the straight line detection unit 112 sets a part of the captured image P1 that may include the line RA as a detection area AR for detecting a straight line. By setting a part of the captured image P1 as the detection area AR, it is possible to reduce the processing load for determining the presence or absence of a straight line, which will be described later, and to suppress the detection of a straight line unrelated to the line RA.

例えば直線検出部112は、ユーザが利用する通信端末(パーソナルコンピュータ、タブレット端末、スマートフォン等)から、ユーザによる検出領域ARの指定を受け付けてもよい。この場合に、直線検出部112は、ユーザの通信端末の表示部に撮像画像P1を表示させる。ユーザは、通信端末の入力部を用いて、撮像画像P1中の領域(画素範囲)を指定する。そして直線検出部112は、ユーザが指定した領域を、検出領域ARとして設定する。これにより、ユーザは所望の検出領域ARを設定できる。   For example, the straight line detection unit 112 may accept the designation of the detection area AR by the user from a communication terminal (personal computer, tablet terminal, smartphone, etc.) used by the user. In this case, the straight line detection unit 112 displays the captured image P1 on the display unit of the user's communication terminal. The user designates an area (pixel range) in the captured image P1 using the input unit of the communication terminal. The straight line detection unit 112 sets a region designated by the user as the detection region AR. Thereby, the user can set a desired detection area AR.

また、例えば直線検出部112は、予め画像処理装置1に記憶された所定の規則に従って、検出領域ARを設定してもよい。この場合に、直線検出部112は、規則に従って撮像画像P1中の領域を決定し、検出領域ARとして設定する。検出領域ARを設定する規則は、例えば撮像画像P1の上側を基準として所定の範囲(上からα番目の画素〜β番目の画素)の画素である。これにより、ユーザが撮像画像P1上で検出領域ARを手作業で指定する必要がないため、ユーザの手間を削減できる。   For example, the straight line detection unit 112 may set the detection area AR according to a predetermined rule stored in the image processing apparatus 1 in advance. In this case, the straight line detection unit 112 determines a region in the captured image P1 according to a rule and sets it as the detection region AR. The rule for setting the detection area AR is, for example, pixels in a predetermined range (α-th pixel to β-th pixel from the top) with reference to the upper side of the captured image P1. This eliminates the need for the user to manually specify the detection area AR on the captured image P1, thereby reducing the user's effort.

撮像装置2は、プラットホームPLから線路RAに向かって撮像するため、2本の線路RAのうちプラットホームPL側の1本は、プラットホームPL上の人間等によって隠れやすい。そのため、2本の線路RAのうちプラットホームPLから遠い側(すなわち撮像画像P1の上側)の線路RAの1本を含むように検出領域ARを設定することによって、線路RAに対応する直線の有無を高精度に判定できる。   Since the imaging device 2 captures an image from the platform PL toward the line RA, one of the two lines RA on the platform PL side is easily hidden by a person or the like on the platform PL. Therefore, the presence or absence of a straight line corresponding to the line RA is determined by setting the detection area AR so as to include one of the lines RA far from the platform PL (that is, the upper side of the captured image P1) of the two lines RA. Can be determined with high accuracy.

また、例えば直線検出部112は、撮像装置2から撮像画像P1の各画素までの距離に基づいて、検出領域ARを設定してもよい。この場合に、撮像装置2は、複数の撮像部を有するステレオカメラとして構成される。ステレオカメラである撮像装置2は、2つの撮像部を用いて同時に撮像範囲を撮像し、同時に撮像した2つの撮像画像を関連付けて画像処理装置1に送信する。   For example, the straight line detection unit 112 may set the detection region AR based on the distance from the imaging device 2 to each pixel of the captured image P1. In this case, the imaging device 2 is configured as a stereo camera having a plurality of imaging units. The imaging device 2 that is a stereo camera simultaneously captures an imaging range using two imaging units, associates two captured images that are simultaneously captured, and transmits the images to the image processing device 1.

画像処理装置1の画像取得部111は、撮像装置2が同時に撮像した2つの撮像画像に基づいて、公知の方法を用いて当該2つ撮像画像における撮像装置2の2つの撮像部の間の視差を、撮像画像の画素ごとに特定する。撮像装置2から被写体への距離が近いほど視差は大きく、撮像装置2から被写体への距離が遠いほど視差は小さい。そのため画像取得部111は、撮像画像の画素ごとに特定した視差の値を、撮像装置2からの距離を示す距離情報として、撮像画像に関連付けて記憶部13に記憶させる。   The image acquisition unit 111 of the image processing device 1 uses a known method based on two captured images simultaneously captured by the image capturing device 2, and parallax between the two image capturing units of the image capturing device 2 in the two captured images. Is specified for each pixel of the captured image. The closer the distance from the imaging device 2 to the subject, the larger the parallax, and the farther the distance from the imaging device 2 to the subject, the smaller the parallax. Therefore, the image acquisition unit 111 stores the parallax value specified for each pixel of the captured image in the storage unit 13 in association with the captured image as distance information indicating the distance from the imaging device 2.

また、撮像装置2は上方から被写体を撮像するため、被写体から撮像装置2までの距離は、所定の基準面(例えば地面又は線路RAが設置されている面)からの被写体の高さに対応する。すなわち、被写体の高さが高いほど撮像装置までの距離が近くなり、被写体の高さが低いほど撮像装置までの距離が遠くなる。そのため画像取得部111は、撮像装置2からの距離に代えて、所定の基準面からの高さを距離情報として用いてもよい。   Further, since the imaging device 2 captures the subject from above, the distance from the subject to the imaging device 2 corresponds to the height of the subject from a predetermined reference plane (for example, the surface on which the ground or the track RA is installed). . That is, the higher the subject height, the closer the distance to the imaging device, and the lower the subject height, the farther the distance to the imaging device. Therefore, the image acquisition unit 111 may use the height from a predetermined reference plane as distance information instead of the distance from the imaging device 2.

そして直線検出部112は、記憶部13に記憶された距離情報に基づいて撮像画像P1の各画素の撮像装置2からの距離を特定し、特定した距離が所定の範囲内の撮像画像P1中の領域を決定し、検出領域ARとして設定する。距離の範囲は、撮像装置2から線路RAまでの距離を含む所定の範囲である。これにより、ユーザが撮像画像P1上で検出領域ARを手作業で指定する必要がないため、ユーザの手間を削減できる。   Then, the straight line detection unit 112 identifies the distance from the imaging device 2 of each pixel of the captured image P1 based on the distance information stored in the storage unit 13, and the identified distance in the captured image P1 within a predetermined range. An area is determined and set as a detection area AR. The range of the distance is a predetermined range including the distance from the imaging device 2 to the line RA. This eliminates the need for the user to manually specify the detection area AR on the captured image P1, thereby reducing the user's effort.

次に直線検出部112は、撮像画像P1から、検出領域ARの座標範囲の画像P2を取り出す。図4(a)、図4(b)は、検出領域ARの座標範囲の画像P2を示す図である。図3(a)の撮像画像P1に対応する図4(a)の画像P2では、プラットホームPLに沿って車両TRが無い状態であるため、線路RAの一部が写っている。図3(b)の撮像画像P1に対応する図4(b)の画像P2は、プラットホームPLに沿って車両TRが有る状態であるため、車両TRの一部が写っている。   Next, the straight line detection unit 112 extracts an image P2 in the coordinate range of the detection area AR from the captured image P1. 4A and 4B are diagrams illustrating an image P2 in the coordinate range of the detection area AR. In the image P2 of FIG. 4A corresponding to the captured image P1 of FIG. 3A, since there is no vehicle TR along the platform PL, a part of the track RA is shown. An image P2 in FIG. 4B corresponding to the captured image P1 in FIG. 3B is in a state where the vehicle TR is present along the platform PL, and thus a part of the vehicle TR is shown.

直線検出部112は、画像P2を2値化し、画像P2に含まれるエッジ(輪郭)を、勾配法、ラプラシアン法等の公知の手法により抽出する。これにより、画像P2において、エッジの部分が白色になり、それ以外の部分が黒色になる。そして直線検出部112は、エッジが抽出された画像P2に対して、ハフ変換をすることによって直線を検出する。   The straight line detection unit 112 binarizes the image P2, and extracts an edge (contour) included in the image P2 by a known method such as a gradient method or a Laplacian method. Thereby, in the image P2, the edge portion becomes white and the other portions become black. The straight line detection unit 112 detects a straight line by performing a Hough transform on the image P2 from which the edge is extracted.

具体的には、直線検出部112は、画像P2において、エッジ上の各座標(x,y)について、ρ=x・cosθ+y・sinθの式を用いて、ρ−θ空間へ射影する。直線検出部112は、ρ−θ空間において、所定の閾値以上の数の射影された曲線が重なっている点(ρ,θ)を、直線を表すパラメータと特定し、特定したパラメータに対応する画像P2(x−y空間)上の直線を検出する。   Specifically, the straight line detection unit 112 projects each coordinate (x, y) on the edge in the image P2 into the ρ−θ space by using an equation of ρ = x · cos θ + y · sin θ. The straight line detection unit 112 identifies a point (ρ, θ) where a number of projected curves equal to or greater than a predetermined threshold overlap in the ρ-θ space as a parameter representing a straight line, and an image corresponding to the identified parameter. A straight line on P2 (xy space) is detected.

直線検出部112は、ρ−θ空間の曲線が重なっている数が所定の閾値以上である全ての点(ρ,θ)に対応する直線を検出してもよく、ρ−θ空間の曲線が重なっている数が多い順に所定の数の直線を検出してもよい。   The straight line detection unit 112 may detect straight lines corresponding to all points (ρ, θ) in which the number of overlapping curves in the ρ-θ space is equal to or greater than a predetermined threshold. A predetermined number of straight lines may be detected in descending order of the number of overlapping.

直線検出部112は、上述の具体的な方法に限らず、撮像画像に含まれる直線を検出可能な公知の方法を用いることができる。直線検出部112は、画像P2を2値化ではなく多値化した画像からエッジ抽出して直線を検出してもよく、グレースケール画像からエッジ抽出して直線を検出してもよい。画像P2を2値化することによって、画像P2中のノイズを低減できるとともに、計算の負荷を低減して直線を検出できるという効果がある。   The straight line detection unit 112 is not limited to the specific method described above, and a known method capable of detecting a straight line included in the captured image can be used. The straight line detection unit 112 may detect a straight line by extracting an edge from an image in which the image P2 is binarized instead of binarized, or may detect a straight line by extracting an edge from a grayscale image. By binarizing the image P2, it is possible to reduce noise in the image P2, and to detect a straight line while reducing the calculation load.

次に車両判定部113は、直線検出部112が検出した各直線について、車両TRの走行方向(すなわち線路RAの延在方向)と同一の方向の直線か否かを特定する。具体的には、車両判定部113は、車両TRの走行方向(撮像画像P1の水平方向)を含む予め設定された範囲(例えば車両TRの走行方向に対して−10度から+10度の範囲)内の角度を有する直線を、車両TRの走行方向と同一の方向の直線として特定する。   Next, the vehicle determination unit 113 specifies whether each straight line detected by the straight line detection unit 112 is a straight line in the same direction as the traveling direction of the vehicle TR (that is, the extending direction of the track RA). Specifically, the vehicle determination unit 113 has a preset range including the traveling direction of the vehicle TR (the horizontal direction of the captured image P1) (for example, a range of −10 degrees to +10 degrees with respect to the traveling direction of the vehicle TR). A straight line having an inner angle is specified as a straight line in the same direction as the traveling direction of the vehicle TR.

図5(a)、図5(b)は、直線検出部112が画像P2中で検出した直線L1、L2を示す図である。図3(a)の撮像画像P1に対応する図5(a)の画像P2は、車両判定部113が車両TRの走行方向と同一の方向と特定した直線L1を含んでいる。すなわち図5(a)の画像P2は、プラットホームPLに沿って車両TRが無い状態であるため、ハフ変換によって車両TRの走行方向と同一の方向に沿って延びる、線路RAに対応する直線L1を含む。   5A and 5B are diagrams illustrating the straight lines L1 and L2 detected by the straight line detection unit 112 in the image P2. An image P2 in FIG. 5A corresponding to the captured image P1 in FIG. 3A includes a straight line L1 that the vehicle determination unit 113 specifies as the same direction as the traveling direction of the vehicle TR. That is, the image P2 in FIG. 5A shows a state in which the vehicle TR is not present along the platform PL. Therefore, the straight line L1 corresponding to the line RA extending along the same direction as the traveling direction of the vehicle TR by the Hough transformation is illustrated. Including.

図3(b)の撮像画像P1に対応する図5(b)の画像P2は、車両判定部113が車両TRの走行方向と同一の方向と特定した直線L1を含んでおらず、車両判定部113が車両TRの走行方向と同一の方向でないと特定した直線L2を含んでいる。すなわち図5(b)の画像P2は、プラットホームPLに沿って車両TRが有る状態であるため、ハフ変換によって車両TRの走行方向に沿った線路RAに対応する直線L1を含まない。その代わりに、図5(b)の画像P2は、車両TRの走行方向とは異なる方向に延びる、車両TRの構造(例えば車両TRの連結部)に対応する直線L2を含む。   The image P2 in FIG. 5B corresponding to the captured image P1 in FIG. 3B does not include the straight line L1 that the vehicle determination unit 113 specifies as the same direction as the traveling direction of the vehicle TR, and the vehicle determination unit 113 includes a straight line L2 that is identified as not being in the same direction as the traveling direction of the vehicle TR. That is, the image P2 in FIG. 5B does not include the straight line L1 corresponding to the track RA along the traveling direction of the vehicle TR due to the Hough transformation because the vehicle TR is present along the platform PL. Instead, the image P2 in FIG. 5B includes a straight line L2 corresponding to the structure of the vehicle TR (for example, a connecting portion of the vehicle TR) extending in a direction different from the traveling direction of the vehicle TR.

画像P2に線路RAが写っている場合には、プラットホームPLに沿って車両TRが無く、画像P2に線路RAが写っていない場合には、プラットホームPLに沿って車両TRが有る。そのため、車両判定部113は、画像P2中で直線検出部112が検出した直線のうち少なくとも1つが車両TRの走行方向と同一の方向の直線である場合(すなわち検出領域ARが車両TRの走行方向と同一の方向の直線を含む場合)に、撮像画像P1(画像P2)が車両TRを含まないと判定する。   When the track RA is shown in the image P2, there is no vehicle TR along the platform PL, and when the track RA is not shown in the image P2, there is a vehicle TR along the platform PL. Therefore, the vehicle determination unit 113 determines that at least one of the straight lines detected by the straight line detection unit 112 in the image P2 is a straight line in the same direction as the traveling direction of the vehicle TR (that is, the detection area AR is the traveling direction of the vehicle TR). The captured image P1 (image P2) is determined not to include the vehicle TR.

一方、車両判定部113は、画像P2中で直線検出部112が検出した全ての直線が車両TRの走行方向と同一の方向の直線でない場合(すなわち検出領域ARが車両TRの走行方向と同一の方向の直線を含まない場合)に、撮像画像P1(画像P2)が車両TRを含むと判定する。   On the other hand, when all the straight lines detected by the straight line detection unit 112 in the image P2 are not in the same direction as the traveling direction of the vehicle TR (that is, the detection area AR is the same as the traveling direction of the vehicle TR). It is determined that the captured image P1 (image P2) includes the vehicle TR when the straight line of the direction is not included.

出力部114は、車両判定部113による判定に基づいて、撮像画像P1が車両TRを含むか否かを示す情報を出力する。出力部114は、記憶部13又はその他の記憶装置に情報を記憶させてもよい。出力部114は、液晶ディスプレイ、ランプ等の表示装置を用いて情報を表示してもよい。出力部114は、スピーカを用いて情報を示す音声を出力してもよい。出力部114は、プリンタを用いて情報を印刷してもよい。   Based on the determination by the vehicle determination unit 113, the output unit 114 outputs information indicating whether or not the captured image P1 includes the vehicle TR. The output unit 114 may store information in the storage unit 13 or other storage device. The output unit 114 may display information using a display device such as a liquid crystal display or a lamp. The output unit 114 may output sound indicating information using a speaker. The output unit 114 may print information using a printer.

このように画像処理装置1は、撮像画像P1のうち線路RAを含む可能性のある検出領域ARの画像P2を2値化及びエッジ抽出し、ハフ変換によって線路RAに対応する直線を検出することによって、プラットホームPLに沿った車両TRの有無を判定する。撮像画像P1からのエッジの抽出は光量の変化に強いため、画像処理装置1は、環境の明るさが低い状態であっても車両の有無の検出精度を向上できる。   As described above, the image processing apparatus 1 binarizes and extracts an edge of the image P2 of the detection area AR that may include the line RA in the captured image P1, and detects a straight line corresponding to the line RA by Hough transform. Thus, the presence / absence of the vehicle TR along the platform PL is determined. Since the extraction of the edge from the captured image P1 is strong against changes in the amount of light, the image processing apparatus 1 can improve the detection accuracy of the presence / absence of the vehicle even when the brightness of the environment is low.

[物体検出方法の説明]
車両検出方法において、撮像画像P1(画像P2)が車両TRを含まないと車両判定部113が判定した場合に、物体検出部115は、撮像画像P1の監視領域内の物体を検出する。物体検出部115は、撮像画像P1の全体(すなわち撮像装置2の撮像範囲)を監視領域としてもよく、撮像画像P1の一部を監視領域としてもよい。
[Description of object detection method]
In the vehicle detection method, when the vehicle determination unit 113 determines that the captured image P1 (image P2) does not include the vehicle TR, the object detection unit 115 detects an object in the monitoring region of the captured image P1. The object detection unit 115 may set the entire captured image P1 (that is, the imaging range of the imaging device 2) as a monitoring region, or may set a part of the captured image P1 as a monitoring region.

具体的には、物体検出部115は、記憶部13に記憶された過去のいずれかの時点(第1時点)の撮像画像を基準画像として、基準画像の監視領域と最新(第2時点)の撮像画像の監視領域とを比較する。物体検出部115は、時系列で1つ前に記憶された撮像画像を基準画像としてもよく、あるいは特定の時点(例えば撮像装置2の設置時)の撮像画像を基準画像としてもよい。そして基準画像の監視領域と最新の撮像画像の監視領域との間の差分が所定の条件(例えば差分の面積が所定値以上であること)を満たす場合に、物体検出部115は監視領域内に新たに存在する物体を検出する。   Specifically, the object detection unit 115 uses a captured image at any one of the past (first time) stored in the storage unit 13 as a reference image, and the monitoring area of the reference image and the latest (second time). The monitored area of the captured image is compared. The object detection unit 115 may use a captured image stored immediately before in time series as a reference image, or may use a captured image at a specific time (for example, when the imaging device 2 is installed) as a reference image. When the difference between the monitoring area of the reference image and the monitoring area of the latest captured image satisfies a predetermined condition (for example, the area of the difference is a predetermined value or more), the object detection unit 115 is in the monitoring area. A newly existing object is detected.

物体検出部115が監視領域内の物体を検出する方法は、上述の具体的な方法に限定されない。例えば物体検出部115は、上述の距離情報に基づいて、撮像画像P1の監視領域内に所定の範囲内の距離の画素が発生した場合に、物体を検出してもよい。ユーザが監視対象の距離を適宜設定することによって、物体検出部115が地面にできた影を物体として検出しないようにできる。   The method by which the object detection unit 115 detects an object in the monitoring area is not limited to the specific method described above. For example, the object detection unit 115 may detect an object when a pixel having a distance within a predetermined range is generated in the monitoring region of the captured image P1 based on the above-described distance information. By appropriately setting the distance to be monitored by the user, the object detection unit 115 can be prevented from detecting a shadow formed on the ground as an object.

物体検出部115が監視領域内に存在する物体を検出した場合に、出力部114は、物体検出部115が撮像画像P1の監視領域内に物体を検出したことを通知する情報を出力する。   When the object detection unit 115 detects an object existing in the monitoring area, the output unit 114 outputs information notifying that the object detection unit 115 has detected an object in the monitoring area of the captured image P1.

一方、車両検出方法において、撮像画像P1(画像P2)が車両TRを含むと車両判定部113が判定した場合に、物体検出部115は、撮像画像P1の監視領域内の物体の検出を行わない。このように、物体検出部115は、車両判定部113がプラットホームPLに沿った車両TRが無いと判定したときのみ、撮像画像P1中の物体を検出するため、物体検出部115がプラットホームPLにある車両TRを物体(異物)として検出することを抑制し、無用な通知の出力を抑制できる。   On the other hand, in the vehicle detection method, when the vehicle determination unit 113 determines that the captured image P1 (image P2) includes the vehicle TR, the object detection unit 115 does not detect an object in the monitoring region of the captured image P1. . As described above, the object detection unit 115 detects the object in the captured image P1 only when the vehicle determination unit 113 determines that there is no vehicle TR along the platform PL. Therefore, the object detection unit 115 is on the platform PL. The detection of the vehicle TR as an object (foreign matter) can be suppressed, and the output of useless notification can be suppressed.

本実施形態では、画像処理装置1は、撮像画像P1中の車両TRの有無を判定した後に、自身で物体の検出をしているが、外部装置が物体の検出をしてもよい。その場合に、画像処理装置1は撮像画像P1中の車両TRの有無の判定結果を示す情報を外部装置に送信し、外部装置は画像処理装置1から受信した判定結果に基づいて物体の検出をするか否か決定する。   In the present embodiment, the image processing apparatus 1 detects the object itself after determining the presence or absence of the vehicle TR in the captured image P1, but the external apparatus may detect the object. In this case, the image processing device 1 transmits information indicating the determination result of the presence or absence of the vehicle TR in the captured image P1 to the external device, and the external device detects an object based on the determination result received from the image processing device 1. Decide whether or not to do.

[画像処理方法のフローチャート]
図6は、本実施形態に係る画像処理方法のフローチャートを示す図である。図6のフローチャートは、例えばユーザが画像処理装置1に対して所定の開始操作を行うことによって開始される。
[Flowchart of image processing method]
FIG. 6 is a diagram illustrating a flowchart of the image processing method according to the present embodiment. The flowchart in FIG. 6 is started, for example, when the user performs a predetermined start operation on the image processing apparatus 1.

画像取得部111は、撮像装置2が撮像した撮像画像P1を取得し、記憶部13に記憶させる(S11)。直線検出部112は、ステップS11で画像取得部111が取得した撮像画像P1の一部を、直線を検出する検出領域ARとして設定する(S12)。   The image acquisition unit 111 acquires the captured image P1 captured by the imaging device 2 and stores it in the storage unit 13 (S11). The straight line detection unit 112 sets a part of the captured image P1 acquired by the image acquisition unit 111 in step S11 as a detection area AR for detecting a straight line (S12).

直線検出部112は、撮像画像P1から、ステップS12で設定した検出領域ARの座標範囲の画像P2を取り出す。そして直線検出部112は、画像P2に対して2値化及びエッジ抽出をし、ハフ変換をすることによって直線を検出する(S13)。車両判定部113は、ステップS13で直線検出部112が検出した各直線について、車両TRの走行方向(すなわち線路RAの延在方向)と同一の方向の直線か否かを特定する(S14)。   The straight line detection unit 112 extracts an image P2 in the coordinate range of the detection area AR set in step S12 from the captured image P1. Then, the straight line detection unit 112 binarizes and extracts an edge from the image P2, and performs a Hough transform to detect a straight line (S13). The vehicle determination unit 113 identifies whether each straight line detected by the straight line detection unit 112 in step S13 is a straight line in the same direction as the traveling direction of the vehicle TR (that is, the extending direction of the track RA) (S14).

車両判定部113は、画像P2(検出領域AR)が車両TRの走行方向と同一の方向の直線を含む場合に(S15のYES)、撮像画像P1(画像P2)が車両TRを含まないと判定する(S16)。出力部114は、撮像画像P1が車両TRを含まないことを示す情報を出力する。そして物体検出部115は、ステップS11で画像取得部111が取得した撮像画像P1の監視領域内の物体を検出する(S17)。   The vehicle determination unit 113 determines that the captured image P1 (image P2) does not include the vehicle TR when the image P2 (detection area AR) includes a straight line in the same direction as the traveling direction of the vehicle TR (YES in S15). (S16). The output unit 114 outputs information indicating that the captured image P1 does not include the vehicle TR. Then, the object detection unit 115 detects an object in the monitoring area of the captured image P1 acquired by the image acquisition unit 111 in step S11 (S17).

ステップS17で物体検出部115が監視領域内に存在する物体を検出した場合に(S18のYES)、出力部114は、物体検出部115が撮像画像P1の監視領域内に物体を検出したことを通知する情報を出力する(S19)。ステップS17で物体検出部115が監視領域内に存在する物体を検出しなかった場合に(S18のNO)、画像処理装置1はステップS21に進む。   When the object detection unit 115 detects an object existing in the monitoring region in step S17 (YES in S18), the output unit 114 indicates that the object detection unit 115 has detected an object in the monitoring region of the captured image P1. Information to be notified is output (S19). If the object detection unit 115 does not detect an object present in the monitoring area in step S17 (NO in S18), the image processing apparatus 1 proceeds to step S21.

車両判定部113は、画像P2(検出領域AR)が車両TRの走行方向と同一の方向の直線を含まない場合に(S15のNO)、撮像画像P1(画像P2)が車両TRを含むと判定する(S20)。出力部114は、撮像画像P1が車両TRを含むことを示す情報を出力する。この場合に、物体検出部115は物体の検出を行わない。   The vehicle determination unit 113 determines that the captured image P1 (image P2) includes the vehicle TR when the image P2 (detection area AR) does not include a straight line in the same direction as the traveling direction of the vehicle TR (NO in S15). (S20). The output unit 114 outputs information indicating that the captured image P1 includes the vehicle TR. In this case, the object detection unit 115 does not detect the object.

所定の終了条件(例えばユーザが画像処理装置1に対して所定の終了操作を行うこと)が満たされていない場合に(S21のNO)、画像処理装置1はステップS11に戻って処理を繰り返す。所定の終了条件が満たされた場合に(S21のYES)、画像処理装置1は処理を終了する。   When a predetermined end condition (for example, the user performing a predetermined end operation on the image processing apparatus 1) is not satisfied (NO in S21), the image processing apparatus 1 returns to step S11 and repeats the process. When the predetermined end condition is satisfied (YES in S21), the image processing apparatus 1 ends the process.

[第1の実施形態の効果]
本実施形態に係る画像処理装置1は、撮像画像P1のうち線路RAを含む可能性のある検出領域ARの画像P2を2値化及びエッジ抽出してから直線を検出することによって、プラットホームPLに沿った車両TRの有無を判定する。撮像画像P1からのエッジの抽出は光量の変化に強いため、画像処理装置1は、環境の明るさが低い状態であっても車両TRの有無の検出精度を向上できる。
[Effect of the first embodiment]
The image processing apparatus 1 according to the present embodiment detects the straight line after binarizing and extracting the image P2 of the detection area AR that may include the line RA in the captured image P1, thereby detecting the straight line on the platform PL. The presence or absence of a vehicle TR along the road is determined. Since the extraction of the edge from the captured image P1 is strong against changes in the amount of light, the image processing apparatus 1 can improve the detection accuracy of the presence / absence of the vehicle TR even when the brightness of the environment is low.

さらに物体検出部115は、車両判定部113がプラットホームPLに沿った車両TRが無いと判定したときのみ、撮像画像P1中の物体を検出する。これにより、物体検出部115は、プラットホームPLにある車両TRを物体(異物)として検出することを抑制し、無用な通知の出力を抑制できる。   Furthermore, the object detection unit 115 detects an object in the captured image P1 only when the vehicle determination unit 113 determines that there is no vehicle TR along the platform PL. Thereby, the object detection part 115 can suppress detecting the vehicle TR in the platform PL as an object (foreign substance), and can suppress the output of useless notification.

(第2の実施形態)
第1の実施形態はプラットホームPLに沿った車両TRの有無を判定するのに対して、本実施形態は車両TRの有無に加えて車両TRがプラットホームPLに沿って進入又は進入している向きを判定する。
(Second Embodiment)
The first embodiment determines the presence or absence of the vehicle TR along the platform PL, while the present embodiment determines the direction in which the vehicle TR enters or enters along the platform PL in addition to the presence or absence of the vehicle TR. judge.

図7は、撮像装置2が撮像した撮像画像P1を示す図である。図7の撮像画像P1では、プラットホームPLに沿って車両TRが右側から進入している状態であるため、撮像画像P1の左側の一部に線路RAが写っており、撮像画像P1の右側の一部に車両TRが写っている。   FIG. 7 is a diagram illustrating a captured image P1 captured by the imaging device 2. In the captured image P1 of FIG. 7, since the vehicle TR enters from the right side along the platform PL, the track RA is shown in a part of the left side of the captured image P1, and the right side of the captured image P1 is shown. The vehicle TR is shown in the part.

本実施形態に係る直線検出部112は、画像取得部111が取得した撮像画像P1から、検出領域ARの座標範囲の画像P2を取り出した後、さらに画像P2を分割位置Dで車両TRの走行方向に沿って複数の分割画像に分割する。図7の例では、直線検出部112は画像P2を3つの分割位置Dで4つに分割しているが、画像P2を少なくとも1つの分割位置Dで2つに分割すればよい。直線検出部112は、各分割画像に対して2値化及びエッジ抽出をし、ハフ変換をすることによって直線を検出する。   The straight line detection unit 112 according to the present embodiment extracts the image P2 in the coordinate range of the detection area AR from the captured image P1 acquired by the image acquisition unit 111, and further extracts the image P2 at the division position D in the traveling direction of the vehicle TR. Are divided into a plurality of divided images. In the example of FIG. 7, the straight line detection unit 112 divides the image P2 into four at three division positions D. However, the image P2 may be divided into two at at least one division position D. The straight line detection unit 112 performs binarization and edge extraction on each divided image, and detects a straight line by performing Hough transform.

図8(a)〜図8(c)は、画像P2を車両TRの走行方向に沿って分割した分割画像P3を示す図である。図8(a)の分割画像P3はプラットホームPLに沿って車両TRが無い図3(a)の状態に対応し、図8(b)の分割画像P3はプラットホームPLに沿って車両TRが右側から進入している図7の状態に対応し、図8(c)の分割画像P3はプラットホームPLに沿って車両TRが有る図3(b)の状態に対応する。各分割画像P3中には、直線検出部112が検出した直線が表されている。   Fig.8 (a)-FIG.8 (c) are the figures which show the division | segmentation image P3 which divided | segmented the image P2 along the running direction of vehicle TR. The divided image P3 of FIG. 8A corresponds to the state of FIG. 3A where the vehicle TR is not present along the platform PL, and the divided image P3 of FIG. 8B is the vehicle TR viewed from the right side along the platform PL. Corresponding to the state of FIG. 7 entering, the divided image P3 of FIG. 8C corresponds to the state of FIG. 3B where the vehicle TR is along the platform PL. In each divided image P3, a straight line detected by the straight line detection unit 112 is represented.

そして車両判定部113は、直線検出部112が検出した各直線について車両TRの走行方向と同一の方向の直線か否かを特定し、車両TRの走行方向と同一の方向の直線を含む分割画像P3が車両TRを含むと判定する。図8(a)〜図8(c)において、各分割画像P3の下に、車両判定部113が車両TRを含むと判定した場合(車両TRの走行方向と同一の方向の直線L1を含まない場合)に「○」、車両判定部113が車両TRを含むと判定しなかった場合(車両TRの走行方向と同一の方向の直線L1を含む場合)に「×」が表されている。   Then, the vehicle determination unit 113 specifies whether each straight line detected by the straight line detection unit 112 is a straight line in the same direction as the traveling direction of the vehicle TR, and a divided image including a straight line in the same direction as the traveling direction of the vehicle TR. It is determined that P3 includes the vehicle TR. 8A to 8C, when the vehicle determination unit 113 determines that the vehicle TR is included under each divided image P3 (not including the straight line L1 in the same direction as the traveling direction of the vehicle TR). ), “X” is shown when the vehicle determination unit 113 does not determine that the vehicle TR is included (when the straight line L1 in the same direction as the traveling direction of the vehicle TR is included).

第1の実施形態では、図8(b)のように撮像画像P1の範囲の一部に車両TRが有る場合に、直線検出部112は線路RAに対応する直線L1を検出するため、車両判定部113は撮像画像P1が車両TRを含まないと判定する。それに対して、本実施形態に係る車両判定部113は、分割画像P3の少なくとも1つが車両TRの走行方向と同一の方向の直線L1を含まない場合(すなわち車両TRに線路RAが隠れている場合)に、撮像画像P1が車両TRを含むと判定する。そのため、画像処理装置1は、車両TRがプラットホームPLに沿って進入又は進出している場合、あるいは車両TRが撮像画像P1の範囲の途中で停車している場合であっても、車両TRが有ると判定できる。   In the first embodiment, as shown in FIG. 8B, when the vehicle TR is part of the range of the captured image P1, the straight line detection unit 112 detects the straight line L1 corresponding to the track RA. The unit 113 determines that the captured image P1 does not include the vehicle TR. On the other hand, when at least one of the divided images P3 does not include the straight line L1 in the same direction as the traveling direction of the vehicle TR (that is, when the track RA is hidden in the vehicle TR), the vehicle determination unit 113 according to the present embodiment. ), It is determined that the captured image P1 includes the vehicle TR. Therefore, the image processing apparatus 1 has the vehicle TR even when the vehicle TR enters or advances along the platform PL or when the vehicle TR stops in the middle of the range of the captured image P1. Can be determined.

さらに車両判定部113は、複数のタイミング(ここでは第1時点及び第2時点)で各分割画像P3の車両TRの有無を判定することによって、車両TRがプラットホームPLに沿って進入又は進出する向きを特定する。判定のタイミングの間隔は、車両TRの速度に応じて予め設定される。   Further, the vehicle determination unit 113 determines the presence or absence of the vehicle TR in each divided image P3 at a plurality of timings (here, the first time point and the second time point), so that the vehicle TR enters or advances along the platform PL. Is identified. The determination timing interval is set in advance according to the speed of the vehicle TR.

図9(a)〜図9(d)は、本実施形態に係る車両判定部113が車両TRの進入又は進出の向きを特定する条件を示す模式図である。図9(a)〜図9(d)は、第1時点及び第1時点より後の第2時点において、4つの分割画像P3についての車両判定部113の判定結果(車両TRを含む場合に「○」、車両TRを含まない場合に「×」)を、分割画像P3の順番で並べて表している。   FIG. 9A to FIG. 9D are schematic diagrams illustrating conditions for the vehicle determination unit 113 according to the present embodiment to specify the direction of entry or advancement of the vehicle TR. 9A to 9D show the determination results of the vehicle determination unit 113 for the four divided images P3 at the first time point and the second time point after the first time point (when the vehicle TR is included, “ “O”, “x” when the vehicle TR is not included, is displayed in the order of the divided images P3.

図9(a)の場合には、第1時点から第2時点へ、右側の車両TRを含む領域が増加している。このような場合に、車両判定部113は、車両TRがプラットホームPLへ左向きに進入していると判定する。図9(b)の場合には、第1時点から第2時点へ、左側の車両TRを含む領域が増加している。このような場合に、車両判定部113は、車両TRがプラットホームPLへ右向きに進入していると判定する。   In the case of FIG. 9A, the region including the vehicle TR on the right side increases from the first time point to the second time point. In such a case, the vehicle determination unit 113 determines that the vehicle TR has entered the platform PL leftward. In the case of FIG. 9B, the region including the vehicle TR on the left side increases from the first time point to the second time point. In such a case, the vehicle determination unit 113 determines that the vehicle TR has entered the platform PL in the right direction.

図9(c)の場合には、第1時点から第2時点へ、左側の車両TRを含む領域が減少している。このような場合に、車両判定部113は、車両TRがプラットホームPLから左向きに進出していると判定する。図9(d)の場合には、第1時点から第2時点へ、右側の車両TRを含む領域が減少している。このような場合に、車両判定部113は、車両TRがプラットホームPLから右向きに進出していると判定する。   In the case of FIG. 9C, the region including the left vehicle TR decreases from the first time point to the second time point. In such a case, the vehicle determination unit 113 determines that the vehicle TR has advanced leftward from the platform PL. In the case of FIG. 9D, the region including the right vehicle TR decreases from the first time point to the second time point. In such a case, the vehicle determination unit 113 determines that the vehicle TR has advanced to the right from the platform PL.

このように車両判定部113は、車両TRを含む分割画像P3の数の複数のタイミングにわたる変化に基づいて、車両TRがプラットホームPLに沿って進入又は進出する向きを特定できる。   As described above, the vehicle determination unit 113 can specify the direction in which the vehicle TR enters or advances along the platform PL based on the change over the plurality of timings of the number of the divided images P3 including the vehicle TR.

[第2の実施形態の効果]
本実施形態に係る画像処理装置1は、撮像画像P1を分割した複数の分割画像P3について車両TRの有無を判定することによって、車両TRがプラットホームPLに沿って進入又は進出している場合、あるいは車両TRが撮像画像P1の範囲の途中で停車している場合であっても、プラットホームPLに沿って車両TRが有ると判定できる。
[Effects of Second Embodiment]
The image processing apparatus 1 according to the present embodiment determines the presence or absence of the vehicle TR for a plurality of divided images P3 obtained by dividing the captured image P1, so that the vehicle TR enters or advances along the platform PL, or Even if the vehicle TR is stopped in the middle of the range of the captured image P1, it can be determined that the vehicle TR is present along the platform PL.

さらに画像処理装置1は、複数の分割画像P3について複数のタイミングでの車両TRの有無を判定することによって、車両TRがプラットホームPLに沿って進入又は進出する向きを特定できる。例えば画像処理装置1は、車両TRが進入又は進出する向きをプラットホームPLに予め関連付けられた入線の向きと比較し、一致した場合には車両TRが有るとの判定が誤検出でないことを確認できる効果がある。画像処理装置1は、車両TRが進入又は進出する方向とプラットホームPLに予め関連付けられた入線の向きとが一致しない場合には、車両TRが有るとの判定が誤検出の可能性がある旨を出力してもよい。   Furthermore, the image processing apparatus 1 can determine the direction in which the vehicle TR enters or advances along the platform PL by determining the presence or absence of the vehicle TR at a plurality of timings for the plurality of divided images P3. For example, the image processing apparatus 1 compares the direction in which the vehicle TR enters or advances with the direction of the incoming line previously associated with the platform PL, and can confirm that the determination that the vehicle TR is present is not a false detection if they match. effective. When the direction in which the vehicle TR enters or advances and the direction of the incoming line pre-associated with the platform PL do not match, the image processing apparatus 1 indicates that the determination that the vehicle TR is present may be erroneously detected. It may be output.

以上、本発明を実施の形態を用いて説明したが、本発明の技術的範囲は上記実施の形態に記載の範囲には限定されず、その要旨の範囲内で種々の変形及び変更が可能である。例えば、装置の分散・統合の具体的な実施の形態は、以上の実施の形態に限られず、その全部又は一部について、任意の単位で機能的又は物理的に分散・統合して構成することができる。また、複数の実施の形態の任意の組み合わせによって生じる新たな実施の形態も、本発明の実施の形態に含まれる。組み合わせによって生じる新たな実施の形態の効果は、もとの実施の形態の効果を合わせ持つ。   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, A various deformation | transformation and change are possible within the range of the summary. is there. For example, the specific embodiments of device distribution / integration are not limited to the above-described embodiments, and all or a part of them may be configured to be functionally or physically distributed / integrated in arbitrary units. Can do. In addition, new embodiments generated by any combination of a plurality of embodiments are also included in the embodiments of the present invention. The effect of the new embodiment produced by the combination has the effect of the original embodiment.

画像処理装置1の制御部11(プロセッサ)は、図6に示す方法に含まれる各ステップ(工程)の主体となる。すなわち、制御部11は、図6に示す方法を実行するためのプログラムを記憶部13から読み出し、当該プログラムを実行して画像処理装置1の各部を制御することによって、図6に示す方法を実行する。   The control unit 11 (processor) of the image processing apparatus 1 is a main component of each step (process) included in the method shown in FIG. That is, the control unit 11 reads out a program for executing the method shown in FIG. 6 from the storage unit 13, and executes the method shown in FIG. 6 by executing the program and controlling each unit of the image processing apparatus 1. To do.

画像処理装置1は、撮像装置2と一体的に構成されてもよい。すなわち、撮像装置2は、画像処理装置1の機能(すなわち画像取得部111、直線検出部112、車両判定部113、出力部114及び物体検出部115)の少なくとも一部を有してもよい。   The image processing device 1 may be configured integrally with the imaging device 2. That is, the imaging device 2 may have at least a part of the functions of the image processing device 1 (that is, the image acquisition unit 111, the straight line detection unit 112, the vehicle determination unit 113, the output unit 114, and the object detection unit 115).

S 画像処理システム
1 画像処理装置
2 撮像装置
11 制御部
112 直線検出部
113 車両判定部
114 出力部

S Image processing system 1 Image processing device 2 Imaging device 11 Control unit 112 Straight line detection unit 113 Vehicle determination unit 114 Output unit

Claims (6)

車両が走行する線路を含む領域を撮像する撮像部によって撮像された撮像画像に含まれる直線を検出する直線検出部と、
前記撮像画像が予め設定された範囲内の角度を有する前記直線を含む場合に、前記撮像画像が前記車両を含まないと判定する判定部と、
前記判定部による判定に基づいて、前記撮像画像が前記車両を含むか否かを示す情報を出力する出力部と、
を有する車両検出装置。
A straight line detection unit that detects a straight line included in a captured image captured by an imaging unit that captures an area including a track on which the vehicle travels;
A determination unit that determines that the captured image does not include the vehicle when the captured image includes the straight line having an angle within a preset range;
An output unit that outputs information indicating whether the captured image includes the vehicle based on the determination by the determination unit;
A vehicle detection device.
前記判定部は、前記撮像画像が前記車両の走行方向と同一の方向の前記直線を含む場合に、前記撮像画像が前記車両を含まないと判定する、請求項1に記載の車両検出装置。   The vehicle detection device according to claim 1, wherein the determination unit determines that the captured image does not include the vehicle when the captured image includes the straight line in the same direction as the traveling direction of the vehicle. 前記直線検出部は、前記撮像画像の一部を検出領域として設定し、前記検出領域に含まれる前記直線を検出する、請求項1又は2に記載の車両検出装置。   The vehicle detection device according to claim 1, wherein the straight line detection unit sets a part of the captured image as a detection region and detects the straight line included in the detection region. 前記直線検出部は、前記撮像画像を前記車両の走行方向に沿って分割した複数の分割画像のそれぞれに含まれる前記直線を検出し、
前記判定部は、前記直線検出部が前記複数の分割画像のそれぞれで検出した前記直線に基づいて、前記車両が前記線路に沿って進入又は進出する向きを特定する、請求項1から3のいずれか一項に記載の車両検出装置。
The straight line detection unit detects the straight line included in each of a plurality of divided images obtained by dividing the captured image along the traveling direction of the vehicle,
4. The method according to claim 1, wherein the determination unit specifies a direction in which the vehicle enters or advances along the track based on the straight lines detected by the straight line detection unit in each of the plurality of divided images. The vehicle detection device according to claim 1.
前記直線検出部は、前記撮像画像を2値化して輪郭を抽出した後、ハフ変換をすることによって、前記直線を検出する、請求項1から4のいずれか一項に記載の車両検出装置。   The vehicle detection device according to any one of claims 1 to 4, wherein the straight line detection unit detects the straight line by performing Hough transform after binarizing the captured image and extracting a contour. プロセッサが、
車両が走行する線路を含む領域を撮像する撮像部によって撮像された撮像画像に含まれる直線を検出するステップと、
前記撮像画像が予め設定された範囲内の角度を有する前記直線を含む場合に、前記撮像画像が前記車両を含まないと判定するステップと、
前記判定するステップの判定に基づいて、前記撮像画像が前記車両を含むか否かを示す情報を出力するステップと、
を実行する車両検出方法。
Processor
Detecting a straight line included in a captured image captured by an imaging unit that captures an area including a track on which the vehicle travels;
Determining that the captured image does not include the vehicle when the captured image includes the straight line having an angle within a preset range;
Outputting information indicating whether or not the captured image includes the vehicle based on the determination in the determination step;
Vehicle detection method for executing
JP2018081661A 2018-04-20 2018-04-20 Vehicle detection device and vehicle detection method Pending JP2019191763A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2018081661A JP2019191763A (en) 2018-04-20 2018-04-20 Vehicle detection device and vehicle detection method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2018081661A JP2019191763A (en) 2018-04-20 2018-04-20 Vehicle detection device and vehicle detection method

Publications (1)

Publication Number Publication Date
JP2019191763A true JP2019191763A (en) 2019-10-31

Family

ID=68390319

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2018081661A Pending JP2019191763A (en) 2018-04-20 2018-04-20 Vehicle detection device and vehicle detection method

Country Status (1)

Country Link
JP (1) JP2019191763A (en)

Similar Documents

Publication Publication Date Title
US8184859B2 (en) Road marking recognition apparatus and method
JP2008225838A (en) Apparatus, method, and program for face feature point detection
US20230005176A1 (en) Throwing position acquisition method and apparatus, computer device and storage medium
JPWO2016199244A1 (en) Object recognition device and object recognition system
JP2006268097A (en) On-vehicle object detecting device, and object detecting method
CN107428261B (en) Lifting hook detection device based on image processing
JP2009175802A (en) Object detection system
JP2016004287A (en) Traffic lane boundary line extraction device, traffic line boundary line extraction method and program
US20160180201A1 (en) Image processing
JP2015064752A (en) Vehicle monitoring device and vehicle monitoring method
JPH11351862A (en) Foregoing vehicle detecting method and equipment
US20170358089A1 (en) Object identifying apparatus
CN110740315B (en) Camera correction method and device, electronic equipment and storage medium
JP6903477B2 (en) Orbit identification device and program
JP5264457B2 (en) Object detection device
WO2021200038A1 (en) Road deteriotation diagnosing device, road deterioration diagnosing method, and recording medium
JP2017175789A (en) Pantograph inspection device, inspection method and inspection system
JP2016207185A (en) Movement determination device, movement determination method, and movement determination program
JP6831396B2 (en) Video monitoring device
JP2019191763A (en) Vehicle detection device and vehicle detection method
CN113744200B (en) Camera dirt detection method, device and equipment
AU2015318811B2 (en) Arc detection system and method
JP2016062369A (en) Vehicle detection system, adjustment support device, vehicle detection method and adjustment method
JPH03265985A (en) Plate segmenting device for automatic car number reader
JP6218514B2 (en) Pedestrian detection device and traffic control system