JP2012118680A - Image processor and image processing method - Google Patents

Image processor and image processing method Download PDF

Info

Publication number
JP2012118680A
JP2012118680A JP2010266674A JP2010266674A JP2012118680A JP 2012118680 A JP2012118680 A JP 2012118680A JP 2010266674 A JP2010266674 A JP 2010266674A JP 2010266674 A JP2010266674 A JP 2010266674A JP 2012118680 A JP2012118680 A JP 2012118680A
Authority
JP
Japan
Prior art keywords
threshold value
threshold
image
value
processing
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.)
Granted
Application number
JP2010266674A
Other languages
Japanese (ja)
Other versions
JP5500507B2 (en
Inventor
Kei Kokuzen
慶 谷全
Noriyuki Mochizuki
規之 望月
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 JP2010266674A priority Critical patent/JP5500507B2/en
Publication of JP2012118680A publication Critical patent/JP2012118680A/en
Application granted granted Critical
Publication of JP5500507B2 publication Critical patent/JP5500507B2/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Image Analysis (AREA)
  • Image Processing (AREA)
  • Studio Devices (AREA)

Abstract

PROBLEM TO BE SOLVED: To stabilize the operation of detecting a foreign matter from a photographed image by a background difference method.SOLUTION: A difference image is binarized by threshold processing (S103), foreign matters and others (noise) other than the foreign matters are discriminated, and then a threshold is adjusted for each pixel (S104). The threshold is switchable between a threshold TH1 predetermined corresponding to the magnification of the noise generated in a photographing environment and a threshold TH2 a prescribed value lower than the threshold TH1. The prescribed value is determined on the basis of the variation of the actually measured noise. In the threshold adjustment (S104), the threshold adjustment of performing adjustment to the value of the threshold TH2 when a foreign matter is discriminated at the initial threshold TH1 and returning it to the threshold TH1 thereafter when the foreign matter is not discriminated anymore in consecutively executed binarization processing by the threshold TH2 is executed for each pixel. By the adjustment, a foreign matter detecting operation is prevented from becoming instable without being affected by almost all generated noise.

Description

本発明は、動画を撮るカメラの撮影画像を処理し画像に現れる異物を検出する処理を行う画像処理装置及び画像処理方法に関する。   The present invention relates to an image processing apparatus and an image processing method for processing a captured image of a camera that takes a moving image and detecting foreign matter appearing in the image.

いわゆる異物を検出する装置として、例えば、動画像を撮るビデオカメラ等の撮像装置を監視場所に設置し、ビデオカメラの撮影画像を処理することによって、撮影した画面内に現れる物体を異物として検出する移動体検出装置が既に知られている(特許文献1参照)。
この移動体検出装置では、CCD(Charge Coupled Device)等を変換手段とするビデオカメラによって撮影し画素の単位で変換される画像信号から異物を検出する手法が用いられる。この検出手法は、いわゆる背景差分法、即ち、予め監視対象の異物が存在しない状態で撮影しておいた監視場所の背景画像と、その後、その場所の監視時における撮影画像との差分をとって、監視対象の異物が存在する場合に現れる差分値から異物を検出する手法である。
As a so-called foreign object detection device, for example, an imaging device such as a video camera that captures a moving image is installed at a monitoring location, and an image appearing in the captured screen is detected as a foreign object by processing a captured image of the video camera. A moving body detection apparatus is already known (see Patent Document 1).
In this moving body detection apparatus, a technique is used in which a foreign object is detected from an image signal that is captured by a video camera using a CCD (Charge Coupled Device) or the like and converted in units of pixels. This detection method is a so-called background difference method, i.e., taking a difference between a background image of a monitoring location that has been previously captured in a state where there is no foreign object to be monitored and a captured image at the time of monitoring that location. This is a technique for detecting a foreign object from a difference value that appears when a foreign object to be monitored is present.

ところで、カメラの入力画像には、変動成分として、撮影環境に応じたノイズが多かれ少なかれ重畳されることが知られている。このため、背景差分法を用いた異物検出では、求めた差分に含まれる異物の信号成分のほかに加わるノイズ成分を異物として検出することがないように、ノイズを除く処理を行う。即ち、この処理により、画素毎に求めた差分値に対し、閾値による2値化処理によって、ノイズを含む差分画像からノイズ分だけの画素を除き、異物成分を含む画素の存在を2値信号で示す、つまり、閾値以上であれば異物、閾値未満であればノイズとして区別し異物を検出することができる。   By the way, it is known that noise corresponding to the shooting environment is more or less superimposed on the input image of the camera as a fluctuation component. For this reason, in the foreign object detection using the background difference method, processing for removing noise is performed so that a noise component added in addition to the signal component of the foreign object included in the obtained difference is not detected as a foreign object. That is, by this process, the difference value obtained for each pixel is subjected to a binarization process using a threshold value, so that pixels corresponding to noise are excluded from the difference image including noise, and the presence of a pixel including a foreign component is expressed as a binary signal. In other words, the foreign object can be detected as a foreign object if it is greater than or equal to the threshold value, and as a noise if it is less than the threshold value.

ここで、2値化に用いる閾値は、撮影環境の変化が小さければ固定値でもよいが、撮影環境が大きく変化する場合には、その変化に合わせて、動的に閾値を変える必要がある。即ち、一般に、明るい環境下においてはノイズの変動は小さく、暗い環境下においてはノイズの変動は大きくなる傾向があるため、これに対応して、ノイズを異物として誤検知しないように、2値化のための閾値を動的に変更することで、ノイズを有効に除くことによってノイズによる誤検出率を下げ、異物の検出精度を上げる必要がある。   Here, the threshold used for binarization may be a fixed value as long as the change in the shooting environment is small. However, when the shooting environment changes greatly, it is necessary to dynamically change the threshold in accordance with the change. That is, in general, noise fluctuation tends to be small in a bright environment and noise fluctuation tends to be large in a dark environment. Accordingly, binarization is performed so that noise is not erroneously detected as a foreign object. Therefore, it is necessary to reduce the false detection rate due to noise and increase the accuracy of detecting foreign matter by effectively changing the noise by dynamically changing the threshold value for.

しかし、従来の閾値に基づく2値化処理による異物検出方法では、差分画像の異物成分を検知する際に、撮影画像の異物自体に生じるノイズで検出動作が不安定になるという問題がある。つまり、異物の差分値が上記2値化の閾値とほぼ等しい大きさであると、ノイズにより異物画素の差分値が変動するため、差分画像の画素毎の差分値が閾値以上と未満とを行き来するという状態になり得る。そのため、正確な異物検出が難しくなる。その結果、異物検出の通報を監視システムの制御部に繰り返し行ってしまい、当該システムの正常な動作の障害となる。また、一定時間、異物が継続的に検出されたことを条件に通報を行うようにする置き去り又は持ち去り検知を行う場合には、通報が行われなくなってしまう、等の問題が生じる。   However, the conventional foreign object detection method based on the binarization process based on the threshold value has a problem that when detecting the foreign material component of the difference image, the detection operation becomes unstable due to noise generated in the foreign material itself of the captured image. In other words, if the difference value of the foreign matter is approximately equal to the binarization threshold value, the difference value of the foreign matter pixel fluctuates due to noise, so the difference value for each pixel of the difference image goes back and forth between the threshold value and the threshold value. Can be in a state of being. Therefore, accurate foreign object detection becomes difficult. As a result, the foreign object detection notification is repeatedly sent to the control unit of the monitoring system, which becomes an obstacle to the normal operation of the system. In addition, when leaving or carrying out detection is performed in which a notification is made on condition that foreign matter has been continuously detected for a certain period of time, there is a problem that the notification is not performed.

特開平7−160858号公報JP-A-7-160858

本発明は、上記従来技術の問題を解決すべくなされたものであって、その目的は、いわゆる背景差分法により撮影画像から異物を検出する処理を行う際に、異物の存否を検出するための閾値と同等の大きさの差分値を有する異物が存在した場合にも、ノイズの影響を抑えつつ異物検出を正確に行えるようにすることである。   The present invention has been made to solve the above-described problems of the prior art, and an object of the present invention is to detect the presence / absence of a foreign substance when performing a process of detecting the foreign substance from a captured image by a so-called background subtraction method. Even when a foreign object having a difference value equal to the threshold value exists, it is possible to accurately detect the foreign object while suppressing the influence of noise.

本発明は、所定の場所に設置される動画を撮るカメラにより背景を撮影し画素の単位で変換される背景画像と背景撮影後に同場所を前記カメラにより撮影し得られる撮影画像との差分画像を基に異物を検出する処理を行う画像処理装置であって、前記差分画像を予め定めた閾値と画素毎に比較し、比較結果によって異物画素とそれ以外の画素に判別する閾値処理手段と、前記閾値処理手段によって判別された異物画素よりなる画像を基に検出対象の異物であるか否かを判定する異物判定手段と、前記異物判定手段の判定結果を異物検出結果として出力する手段と、前記閾値処理手段で用いる閾値の設定を、撮影環境で生じるノイズの大きさに応じてノイズを検出しないように予め定められた第1閾値と第1閾値よりも所定値だけ低い第2閾値との間で切り替え可能として、異物画素と判別した場合に用いていた閾値が第1閾値であれば、該当する画素に対し次に前記閾値処理手段で処理に用いる閾値の設定を第2閾値に切り替える一方、異物画素ではないと判別した場合に用いていた閾値が前記第2閾値であれば、設定を第1閾値に切り替えて閾値を調整する閾値調整手段と、を有したことを特徴とする。
本発明は、所定の場所に設置される動画を撮るカメラにより背景を撮影し画素の単位で変換される背景画像と背景撮影後に同場所を前記カメラにより撮影し得られる撮影画像との差分画像を基に異物を検出する処理を行う画像処理方法であって、前記差分画像を予め定めた閾値と画素毎に比較し、比較結果によって異物画素とそれ以外の画素に判別する閾値処理工程と、前記閾値処理工程で判別された異物画素よりなる画像を基に検出対象の異物であるか否かを判定する異物判定工程と、前記異物判定工程の判定結果を異物検出結果として出力する工程と、前記閾値処理工程で用いる閾値の設定を、撮影環境で生じるノイズの大きさに応じてノイズを検出しないように予め定められた第1閾値と第1閾値よりも所定値だけ低い第2閾値との間で切り替え可能として、異物画素と判別した場合に用いていた閾値が第1閾値であれば、該当する画素に対し次に行う閾値処理で用いる閾値の設定を第2閾値に切り替える一方、異物画素ではないと判別した場合に用いていた閾値が前記第2閾値であれば、設定を第1閾値に切り替えて閾値を調整する閾値調整工程と、を有したことを特徴とする。
The present invention provides a difference image between a background image captured by a camera that takes a moving image installed at a predetermined location and converted in units of pixels, and a captured image obtained by capturing the same location by the camera after the background capture. An image processing device that performs processing for detecting foreign matter based on the threshold value processing means that compares the difference image for each pixel with a predetermined threshold value, and discriminates between the foreign pixel and other pixels based on the comparison result; A foreign matter determination means for determining whether or not the foreign object is a detection target based on an image made up of foreign matter pixels determined by the threshold processing means, a means for outputting the determination result of the foreign matter determination means as a foreign matter detection result, The threshold value used in the threshold processing means is a first threshold value that is set in advance so as not to detect noise according to the magnitude of noise that occurs in the shooting environment, and a second threshold value that is lower than the first threshold value by a predetermined value. If the threshold value used when the pixel is determined to be a foreign pixel is the first threshold value, the threshold value used for processing by the threshold value processing unit for the corresponding pixel is switched to the second threshold value. On the other hand, if the threshold value used when it is determined that the pixel is not a foreign pixel is the second threshold value, there is provided a threshold adjustment means for switching the setting to the first threshold value and adjusting the threshold value.
The present invention provides a difference image between a background image captured by a camera that takes a moving image installed at a predetermined location and converted in units of pixels, and a captured image obtained by capturing the same location by the camera after the background capture. An image processing method for performing processing for detecting foreign matter based on the threshold value processing step of comparing the difference image for each pixel with a predetermined threshold value, and discriminating between the foreign pixel and other pixels based on the comparison result, A foreign substance determination step for determining whether or not a foreign object is a detection target based on an image formed of the foreign substance pixels determined in the threshold processing step, a step of outputting the determination result of the foreign substance determination step as a foreign object detection result, The threshold value used in the threshold processing step is set between a first threshold value that is set in advance so as not to detect noise according to the magnitude of noise that occurs in the shooting environment, and a second threshold value that is lower than the first threshold value by a predetermined value. If the threshold value used when it is determined that the pixel is a foreign pixel is the first threshold value, the threshold value used in the next threshold processing for the corresponding pixel is switched to the second threshold value, but not the foreign pixel. If the threshold value used when it is determined that the threshold value is the second threshold value, the threshold value adjusting step of adjusting the threshold value by switching the setting to the first threshold value is provided.

本発明によれば、異物の存否を検出するための閾値と同等の大きさの差分値を有する異物が存在する場合にも、ノイズの影響を抑えつつ異物検出を安定して正確に行うことができる。   According to the present invention, even when there is a foreign object having a difference value equivalent to a threshold value for detecting the presence or absence of a foreign object, foreign object detection can be performed stably and accurately while suppressing the influence of noise. it can.

本発明に係る画像処理装置の概略構成を示すブロック図である。1 is a block diagram showing a schematic configuration of an image processing apparatus according to the present invention. 本発明に係る画像処理装置(図1)が行う異物を検出する処理のフロー図である。It is a flowchart of the process which detects the foreign material which the image processing apparatus (FIG. 1) which concerns on this invention performs. 異物を検出する処理(図2)の閾値調整ステップのサブシーケンスのフロー図である。It is a flowchart of the subsequence of the threshold value adjustment step of the process (FIG. 2) which detects a foreign material. 閾値調整値の決定過程で求められる差分値を説明する図である。It is a figure explaining the difference value calculated | required in the determination process of a threshold value adjustment value. ノイズ量の算出ステップを付加した異物を検出する処理の1実施形態に係るフロー図である。It is a flowchart which concerns on one Embodiment of the process which detects the foreign material which added the calculation step of noise amount. ノイズ量の算出ステップを付加した異物を検出する処理の他の実施形態に係るフロー図である。It is a flowchart which concerns on other embodiment of the process which detects the foreign material which added the calculation step of noise amount. ノイズ量の算出ステップを付加した異物を検出する処理の他の実施形態に係るフロー図である。It is a flowchart which concerns on other embodiment of the process which detects the foreign material which added the calculation step of noise amount.

本発明の実施形態の説明に先立って、まず、本発明の原理について説明する。
本発明は背景差分法、即ち、所定の場所に設置される動画を撮るカメラにより背景を撮影し画素単位で変換される、背景画像と背景撮影後に同場所を前記カメラにより撮影し得られる撮影画像との画素毎の画素値の差分をとる背景差分法、によって得られる画像を基に異物を検出する処理を行う。
背景差分法によって得られる差分画像は、ノイズがなければ背景が除かれた異物の存在によって現れる差分のみの画像となるが、実際には重畳されるノイズ分が差分画像に現れるので、ノイズ分の差分値を検出しないように考慮して設定された閾値により差分画像を2値化処理し、異物とそれ以外の画素を判別する。
しかし、実際には異物画像自体にもノイズが含まれるため、異物画素の差分値が閾値程度の場合には、当該差分値に生じるノイズの影響により異物検出動作が不安定になり正確な異物検出が難しくなる。
Prior to the description of the embodiments of the present invention, first, the principle of the present invention will be described.
The present invention is a background subtraction method, that is, a background image captured by a camera that captures a moving image installed at a predetermined location and converted in units of pixels, and a captured image obtained by capturing the same location after the background image is captured by the camera. A process for detecting a foreign object is performed based on an image obtained by a background difference method that obtains a difference in pixel value for each pixel.
If there is no noise, the difference image obtained by the background difference method is an image of only the difference that appears due to the presence of a foreign object from which the background has been removed. The difference image is binarized using a threshold set in consideration of not detecting the difference value, and foreign matter and other pixels are discriminated.
However, since the foreign object image itself also contains noise, if the difference value of the foreign object pixel is about the threshold value, the foreign object detection operation becomes unstable due to the effect of noise generated on the difference value, and accurate foreign object detection is performed. Becomes difficult.

「安定化手法」
そこで、本発明では、閾値調整、即ち画素毎に異物とそれ以外の画素を判別する2値化の閾値を調整(変更)することで、検出動作の安定化を図る。
この閾値調整では、異物画素の検出動作中に閾値を変動させる、つまり、1つの撮影画像に対する2値化の結果を基に次の撮影画像に対する閾値を変更する方式をとる。
閾値は、異物検出処理システムを起動したときなどに設定される値(「第1閾値TH1」という)と、第1閾値TH1よりも所定値(以下、「閾値調整値」或いは単に「調整値」という)だけ輝度値が低い閾値(「第2閾値TH2」という)との間で切り替える。
Stabilization method
Therefore, in the present invention, the detection operation is stabilized by adjusting (changing) the threshold value, that is, by adjusting (changing) the binarization threshold value for discriminating a foreign substance and other pixels for each pixel.
In this threshold value adjustment, the threshold value is changed during the foreign pixel detection operation, that is, the threshold value for the next captured image is changed based on the binarization result for one captured image.
The threshold value is a value set when the foreign object detection processing system is activated (referred to as “first threshold value TH1”) and a predetermined value (hereinafter referred to as “threshold adjustment value” or simply “adjustment value”) than the first threshold value TH1. And a threshold value having a low luminance value (referred to as “second threshold value TH2”).

なお、第1閾値TH1は、異物検出処理システムの起動時などに設定される値を各画素に共通に用いる。設定される第1閾値TH1は、撮影環境によって生じるノイズ分の差分値が異なるので、撮影環境で生じるノイズの大きさに応じてノイズを検出しないように予め定められた閾値を適用する。第1閾値TH1を決める方法は、既存の方法を採用することによって実施することが可能であり、例えば、現場の撮影環境で実験を行い、そのときの撮影環境の変化に応じて変わるノイズ量を基に、異物とそれ以外の画素を誤りなく判別するために適する値を決める。
また、調整値は、画像のノイズ量を基にした統計的な手法で決定する(後記実施例における“調整値の決定”で詳述)。つまり、異物画素自体に含まれる撮影画像のノイズによる変動量を考慮する。
For the first threshold TH1, a value set when the foreign object detection processing system is started is commonly used for each pixel. The first threshold value TH1 to be set has a difference value corresponding to noise generated in the shooting environment, and therefore a predetermined threshold value is applied so as not to detect noise according to the magnitude of noise generated in the shooting environment. The method for determining the first threshold value TH1 can be implemented by adopting an existing method. For example, an experiment is performed in an on-site shooting environment, and a noise amount that changes in accordance with a change in the shooting environment at that time is calculated. Based on this, a value suitable for discriminating foreign objects and other pixels without error is determined.
The adjustment value is determined by a statistical method based on the amount of noise in the image (detailed in “determination of adjustment value” in the examples described later). That is, the amount of fluctuation due to noise in the captured image included in the foreign pixel itself is taken into account.

閾値の切り替えは、第1閾値TH1により異物と判別された画素があれば、その画素の閾値を第1閾値TH1よりも所定値だけ低い第2閾値TH2に切り替え、その後、引き続いてこの低い第2閾値TH2で処理を行って、この閾値を越えることが途切れたとき、即ち、異物判別がなされなかったときは、その画素の閾値を再び第1閾値TH1に戻すことで行う。   When there is a pixel that is determined to be a foreign object by the first threshold value TH1, the threshold value is switched to the second threshold value TH2 that is lower than the first threshold value TH1 by a predetermined value. When processing is performed with the threshold value TH2 and exceeding this threshold is interrupted, that is, when foreign matter determination is not performed, the threshold value of the pixel is returned to the first threshold value TH1 again.

この閾値の切り替えを行う理由は、第1閾値TH1のみで全ての異物判別処理を行うと、異物画素自体に含まれるノイズの影響で本来は第1閾値TH1を越える差分値であるにもかかわらず、第1閾値TH1未満の差分値となる可能性があるからである。また、閾値を第2閾値TH2に下げるのは、第1閾値を越えて異物と判別された画素が引き続いて次に処理される差分画像における差分値で第1閾値TH1未満となった場合でも、その画素の差分値はこの第2閾値TH2は越えるようにして、異物画像の画素を確実に判別できるようにするためである。
また、第2閾値TH2を越えることが途切れたときに再び第1閾値TH1に戻すのは、第2閾値TH2はノイズを検出しないように定められた閾値ではなく、異物を安定して検出するための閾値であり、ノイズを異物と誤判別する可能性があるため、ノイズを検出しないように定められた第1閾値TH1に戻せばその可能性が低減することから、第1閾値TH1に基づいて、再度異物画素の検知を行うためである。
The reason for switching the threshold value is that when all the foreign matter determination processing is performed only with the first threshold value TH1, the difference value exceeds the first threshold value TH1 due to the noise included in the foreign matter pixel itself. This is because the difference value may be less than the first threshold TH1. Further, the threshold value is lowered to the second threshold value TH2, even when the pixel that has been determined to be a foreign object after exceeding the first threshold value is less than the first threshold value TH1 in the difference value in the difference image that is subsequently processed. This is because the difference value of the pixel exceeds the second threshold value TH2 so that the pixel of the foreign object image can be reliably identified.
The reason why the threshold value TH2 is returned to the first threshold value TH1 again when exceeding the second threshold value TH2 is not a threshold value determined so as not to detect noise, is to detect foreign matters stably. Since there is a possibility that the noise is misidentified as a foreign object, the possibility is reduced if the noise is returned to the first threshold TH1 which is determined not to detect the noise. Therefore, based on the first threshold TH1 This is because the foreign pixel detection is performed again.

なお、第1閾値TH1から第2閾値TH2への調整の際、必要以上に閾値を下げてしまうと、最悪の場合第1閾値TH1に戻す切り替えができなくなる(つまり、異物画素を検出し続ける)可能性があるため、この点を考慮して適用する値を定めることが必要である。   When the threshold value is lowered more than necessary during the adjustment from the first threshold value TH1 to the second threshold value TH2, in the worst case, switching to the first threshold value TH1 cannot be performed (that is, foreign object pixels are continuously detected). Since there is a possibility, it is necessary to determine the value to be applied in consideration of this point.

このような閾値の調整を行うことにより、異物とそれ以外の画素を判別する2値化処理の出力を安定化することができる。
特に、上述のように、一定時間、異物が継続的に検出されたことを条件に通報を行うようにする置き去り又は持ち去り検知では、有効性をより高めることができる。
なお、以上述べたように、この実施形態の安定化の手法は、画素毎に閾値を調整して異物検出を安定化させる手法であるため、背景差分法を用いた異物検出システム全般にプラスαの機能として利用可能である。
By adjusting the threshold value in this way, it is possible to stabilize the output of the binarization process for discriminating foreign objects and other pixels.
In particular, as described above, the effectiveness can be further improved in the leaving or removal detection in which notification is made on the condition that foreign matter is continuously detected for a certain period of time.
As described above, the stabilization method of this embodiment is a method of stabilizing the foreign object detection by adjusting the threshold value for each pixel. It can be used as a function of

以下、上記原理を用いた画像処理装置及び画像処理方法に係る実施形態を図面を参照して説明する。
ここでは、背景差分法によって得られる差分画像を基に異物検出処理を行う画像処理装置についてその概要を説明する。
図1は、本実施形態に係る画像処理装置の概略構成を示すブロック図である。
図1に示すように、画像処理装置10は、制御部11と、制御部11の制御下で動作する画像処理部12、撮影環境検知部13、記憶部14、表示部15、入力部16及びインターフェース部17の各部と、データをやり取りするために上記各部11〜17を相互に接続するバス18を有する。
Hereinafter, embodiments according to an image processing apparatus and an image processing method using the above principle will be described with reference to the drawings.
Here, an outline of an image processing apparatus that performs foreign object detection processing based on a difference image obtained by the background difference method will be described.
FIG. 1 is a block diagram illustrating a schematic configuration of an image processing apparatus according to the present embodiment.
As shown in FIG. 1, the image processing apparatus 10 includes a control unit 11, an image processing unit 12 that operates under the control of the control unit 11, a photographing environment detection unit 13, a storage unit 14, a display unit 15, an input unit 16, and In order to exchange data with each part of the interface part 17, it has the bus | bath 18 which connects each said part 11-17 mutually.

制御部11は、画像処理装置全体を制御し、異物検出処理等を実行するためのデータ処理等を行う手段として、図示しないが、CPU(Central Processing Unit)、CPUの処理に必要なプログラムやデータ等を一時的に記憶しておくためのRAM(Random Access Memory)及びCPUを駆動して演算や処理等を実行させるためのプログラム等を格納したROM(Read Only Memory)を備えたコンピュータ等を備える。
画像処理部12は、撮影画像から異物を検出する処理を行う手段であり、後記で図2、3及び図5〜7の処理フローを参照して詳述する検出処理を実行する手段を備える。なお、画像処理部12は、異物検出処理を行う専用の画像処理回路で構成してもよいが、異物検出処理を実行するプログラムを制御部11のコンピュータで駆動することにより実施してもよい。
Although not shown, the control unit 11 controls the entire image processing apparatus and performs data processing for executing foreign object detection processing or the like, although not shown, a CPU (Central Processing Unit), a program and data necessary for processing of the CPU A RAM (Random Access Memory) for temporarily storing and the like, and a ROM (Read Only Memory) storing a program for driving the CPU to execute operations and processes, etc. .
The image processing unit 12 is a unit that performs a process of detecting a foreign object from a captured image, and includes a unit that performs a detection process that will be described in detail later with reference to the process flows of FIGS. The image processing unit 12 may be configured by a dedicated image processing circuit that performs foreign object detection processing, but may be implemented by driving a program that executes foreign object detection processing by the computer of the control unit 11.

撮影環境検知部13は、撮影環境の変化を検知するために設け、屋内、屋外、昼、夜、日照の有無、等の撮影環境の変化によって異物検出処理の処理条件(例えば、後述する2値化に用いる閾値)を変更する場合に、変更に必要な情報を制御部11へ知らせる手段である。なお、後述する実施形態では、撮影画像全体の変化に基づいて検知する手段を採用している。
記憶部14は、撮影画像や処理画像等の画像データを含む各種データを記憶する手段であるが、そのほかに制御部11のコンピュータが用いる異物検出処理や画像処理等に必要な各種プログラムを保存する。
The shooting environment detection unit 13 is provided to detect a change in the shooting environment, and processing conditions (for example, binary described later) according to changes in the shooting environment such as indoors, outdoors, daytime, night, presence / absence of sunlight, etc. This is means for notifying the control unit 11 of information necessary for the change when the threshold value used for conversion is changed. In the embodiment described later, means for detecting based on a change in the entire captured image is employed.
The storage unit 14 stores various data including image data such as a photographed image and a processed image. In addition, the storage unit 14 stores various programs necessary for foreign object detection processing, image processing, and the like used by the computer of the control unit 11. .

入力部16は、異物検出処理に対する指示や操作、或いは異物検出処理の処理(制御)条件の設定等、異物検出に必要な設定データを含む各種データ等を入力するための、例えばマウスやキーボード又はタッチパネル等である。
表示部15は、入力部16とともにユーザーインターフェースとしての機能を提供する手段であり、入力部16を介して入力されたデータやカメラ1による撮影画像或いは画像処理部12によって処理された処理画像等のデータを表示するモニタ等の表示手段であり、異物検出処理の結果を撮影画像上で表示する際、入力時の設定データや検知結果等を表示する際に使用される。
インターフェース部17は、外部機器との間でデータを交換するための手段であり、この実施形態では、ここを介して検出対象を撮影するカメラ1からの撮影画像を画像処理部12等に取り込む。
The input unit 16 is used to input various data including setting data necessary for foreign object detection, such as an instruction or operation for the foreign object detection process, or setting of processing (control) conditions for the foreign object detection process. Such as a touch panel.
The display unit 15 is a means for providing a function as a user interface together with the input unit 16, such as data input through the input unit 16, a captured image by the camera 1, or a processed image processed by the image processing unit 12. It is a display means such as a monitor for displaying data, and is used when displaying the result of foreign object detection processing on a captured image, when displaying setting data at the time of input, detection result, and the like.
The interface unit 17 is a means for exchanging data with an external device, and in this embodiment, the captured image from the camera 1 that captures the detection target is captured in the image processing unit 12 and the like.

「異物検出処理」
画像処理装置10が行う異物検出処理の処理例を示す。なお、以下に示す処理例は、所定の監視場所に現れる異物を設置されたカメラ1により監視するシステムに実施し得る画像処理装置の処理例であり、この監視システムが立ち上げられると、すぐに異物検出の処理が起動されて処理を開始し、システムのシャットダウンにより処理を終了する。
"Foreign matter detection process"
The process example of the foreign material detection process which the image processing apparatus 10 performs is shown. The processing example shown below is an example of an image processing apparatus that can be implemented in a system that monitors a foreign object appearing at a predetermined monitoring location by a camera 1 installed. As soon as this monitoring system is started up, The foreign object detection process is started to start the process, and the process ends when the system is shut down.

図2は、本実施形態の異物検出処理における処理フロー図である。
制御部11は、図2に示すように、監視システムが起動されると処理を開始し、先ず、インターフェース部17を通してカメラ1により撮影された画像が入力される(ステップS101)。
次に、制御部11の制御下で画像処理部12は、入力された撮影画像と予め作成され記憶部14に保存しておいた背景画像の各画素の画素値との差分値(絶対値)を画素単位で求め、差分画像を生成する(ステップS102)。
次いで、画像処理部12は、異物とそれ以外の画素を判別するために画素毎に設定される閾値によって前段で求めた差分画像を2値化処理し、意図する2値画像を得る(ステップS103)。
FIG. 2 is a process flow diagram in the foreign object detection process of the present embodiment.
As shown in FIG. 2, the control unit 11 starts processing when the monitoring system is activated. First, an image photographed by the camera 1 is input through the interface unit 17 (step S101).
Next, under the control of the control unit 11, the image processing unit 12 performs a difference value (absolute value) between the input captured image and the pixel value of each pixel of the background image that is created in advance and stored in the storage unit 14. For each pixel, and a difference image is generated (step S102).
Next, the image processing unit 12 binarizes the difference image obtained in the previous stage with a threshold set for each pixel in order to discriminate foreign objects and other pixels, and obtains an intended binary image (step S103). ).

次に、制御部11は、異物検出動作を安定化させるためにステップS103で用いる閾値を画素毎に調整する(ステップS104)。
ここで、このステップで行う処理例を下記“閾値調整処理”にて説明し、また、調整値の決め方についての処理例を下記“調整値の決定”にて説明する。
Next, the control unit 11 adjusts the threshold value used in step S103 for each pixel in order to stabilize the foreign object detection operation (step S104).
Here, an example of processing performed in this step will be described in the following “threshold adjustment processing”, and an example of processing for determining an adjustment value will be described in the following “determination of adjustment value”.

“閾値調整処理”
図3は、異物検出処理フロー(図2)の閾値調整ステップ(ステップS104)のサブシーケンスのフロー図である。なお、このサブシーケンスは、上述の「安定化手法」を適用して異物検出処理を実施する手順である。
“Threshold adjustment process”
FIG. 3 is a flowchart of the subsequence of the threshold adjustment step (step S104) in the foreign object detection processing flow (FIG. 2). This sub-sequence is a procedure for performing the foreign object detection process by applying the above-described “stabilization method”.

図3のシーケンスに示すように、先ず、制御部11は、判別対象となった画素がステップS103で閾値による2値化処理で異物と判別されたか否かを確認する(ステップS201)。
ここで、異物と判別されたことを確認した場合には(ステップS201-YES)、そのときの閾値が第1閾値TH1(上記「安定化手法」、参照)であるか否かを確認する(ステップS202)。
この確認の結果、閾値が第1閾値TH1であれば(ステップS202-YES)、既に述べた理由により、第1閾値TH1よりも所定値だけ低い第2閾値TH2(上記「安定化手法」、参照)に変更して閾値を調整し(ステップS203)、このシーケンスを終える。
他方、ステップS202の確認の結果、閾値が第1閾値TH1でなければ(ステップS202-NO)、その場合の閾値は第2閾値TH2であるから、閾値を変更せずそのままの値(第2閾値TH2)にしておき、このシーケンスを終える。
As shown in the sequence of FIG. 3, first, the control unit 11 checks whether or not the pixel to be discriminated is discriminated as a foreign object in the binarization process using the threshold value in step S103 (step S201).
Here, when it is confirmed that it is determined as a foreign object (step S201-YES), it is confirmed whether or not the threshold value at that time is the first threshold value TH1 (see “stabilization method” above) ( Step S202).
As a result of this confirmation, if the threshold is the first threshold TH1 (step S202-YES), the second threshold TH2 that is lower than the first threshold TH1 by a predetermined value (see “stabilization method” above) for the reason already described. ) To adjust the threshold value (step S203), and this sequence is completed.
On the other hand, if the threshold value is not the first threshold value TH1 as a result of the confirmation in step S202 (step S202-NO), the threshold value in this case is the second threshold value TH2, so that the threshold value is not changed (the second threshold value). TH2) and finish this sequence.

また、ステップS201で判別対象となる画素が異物と判別されなかった場合には(ステップS201-NO)、そのときの閾値が第2閾値TH2であるか否かを確認する(ステップS204)。
この確認の結果、閾値が第2閾値TH2であれば(ステップS204-YES)、これも既に述べた理由により、第1閾値TH1に変更して閾値を初期値に戻し(ステップS205)、このシーケンスを終える。
他方、ステップS204の確認の結果、閾値が第2閾値TH2でなければ(ステップS204-NO)、その場合の閾値は第1閾値TH1であるから、閾値を変更せずそのままの値(第1閾値TH1)にしておく。
If the pixel to be determined is not determined to be a foreign object in step S201 (step S201-NO), it is confirmed whether or not the threshold value at that time is the second threshold value TH2 (step S204).
As a result of this confirmation, if the threshold value is the second threshold value TH2 (step S204-YES), this is also changed to the first threshold value TH1 for the reason already described, and the threshold value is returned to the initial value (step S205). Finish.
On the other hand, if the threshold value is not the second threshold value TH2 as a result of the confirmation in step S204 (step S204-NO), the threshold value in this case is the first threshold value TH1, so that the threshold value is not changed (the first threshold value). TH1).

“閾値調整値の決定”
上記の閾値調整(図3)で異物検出動作を安定化させるために初期値の第1閾値TH1よりも所定値だけ輝度値が低い第2閾値TH2値に調整する際に適用する閾値調整値(前記所定値)の決定方法について説明する。
なお、この調整値は、監視場所の撮影環境下で生じるノイズ量に適応したものであることが求められ、具体的には監視場所に設置されたカメラ1の撮影画像を基にノイズ量を実測し、実測値からノイズの影響を受けずに異物検出を確実に行える、つまり異物検出を安定して行える調整値を決める。
下記の決定処理例では、監視場所を実際にカメラ1で撮影した画像のノイズ量を元にした統計的な手法で決定する方法について示す。また、撮影環境に適応すべく実測値に基づく閾値調整値の決定を異物検出においてどのようなタイミングで行うかについては、後述する「ノイズ量算出処理」にて説明する。
“Determination of threshold adjustment value”
In order to stabilize the foreign object detection operation by the above-described threshold adjustment (FIG. 3), the threshold adjustment value (when adjusted to the second threshold value TH2 whose luminance value is lower than the first threshold value TH1 by the predetermined value) A method for determining the predetermined value will be described.
This adjustment value is required to be adapted to the amount of noise generated in the shooting environment at the monitoring location. Specifically, the amount of noise is measured based on the captured image of the camera 1 installed at the monitoring location. Then, an adjustment value that can reliably detect foreign matter without being affected by noise, that is, stably detect foreign matter, is determined from the actually measured value.
The following determination processing example shows a method of determining the monitoring location by a statistical method based on the noise amount of the image actually captured by the camera 1. Further, the timing at which the threshold adjustment value based on the actual measurement value is determined in order to adapt to the shooting environment will be described in “noise amount calculation process” to be described later.

調整値の決定処理例について、〈処理例1〉及び〈処理例2〉の2例を示す。
〈処理例1〉
この処理例は、下記1.〜5.に示す処理手順に従って実行する。
1.撮影画像のうちノイズ量の検出対象とする画像領域として、異物の入らない小領域を設定する。なお、この設定を行う理由は、異物が入らない画像領域の方が安定したノイズ量情報の取得ができるからである。また、小領域の設定方法は、モニタ画像上で上記の条件を満たす画像領域をマウスクリックなどにより手動で設定する方式や異物が入らない画像領域を自動設定する既知のアルゴリズムを用いる画像処理によって自動的に設定する方式が採用できるが、いずれの方式を用いてもよい。
2.上記1.で設定した小領域に対しフレーム間差分を求めることにより、画素毎の輝度値の変化量を差分値(絶対値)として得る。
3.上記2.で差分値を得た各画素のうち差分値の小さい方から該当する差分値を持つ画素の画素数を順に足していき、総数が小領域の画素数の大部分の割合(予め定められた割合であり、撮影環境により変動する経験値として、例えば、小領域の画素数の8〜9割)を占めたときに該当する画素の差分値を求める差分値とし、求めた差分値を記憶する。
Two examples of <Processing example 1> and <Processing example 2> are shown as examples of adjustment value determination processing.
<Processing example 1>
This processing example is as follows. ~ 5. Execute according to the processing procedure shown in
1. A small area where no foreign matter enters is set as an image area to be detected for the amount of noise in the captured image. The reason for performing this setting is that stable noise amount information can be acquired in an image area that does not contain foreign matter. In addition, the small area setting method is automatically performed by a method of manually setting an image area that satisfies the above conditions on the monitor image by a mouse click or by image processing using a known algorithm for automatically setting an image area that does not contain a foreign object. However, any method may be used.
2. Above 1. By obtaining the inter-frame difference for the small area set in step 1, the amount of change in the luminance value for each pixel is obtained as the difference value (absolute value).
3. 2. In this order, the number of pixels having the corresponding difference value is added in order from the smaller difference value among the pixels that have obtained the difference value, and the total number is the proportion of the majority of the number of pixels in the small area (predetermined proportion As the experience value that varies depending on the shooting environment, for example, when the difference value of the corresponding pixel is occupied when 80 to 90% of the number of pixels in the small area is occupied, the obtained difference value is stored.

図4は、上記の方法で求める差分値を説明するグラフである。図4におけるグラフは、差分値(縦軸)に対する画素数(横軸)の分布を示している。同図に示すように、ノイズに基づき発生する差分値は、差分値が0の画素数を最大に差分値が大きくなるに連れ画素数は徐々に少なくなり、或る差分値より大きくなると急激に画素数が少なくなる分布となる傾向にある。画素数が急激に少なくなる値を越える差分値は、異常値とみなすことができ、この値を限界値と定めることが適当である。この限界値以内に収まる差分値を持つ画素は検出対象とする画像領域内の大部分を占め、普通に発生するほとんどのノイズは、この限界値以内に収まる差分値を持つ。よって、この限界値を求める差分値としてこの値を閾値調整値とする。ただ、ここでは、求めた差分値を基礎として下記4.で調整値を決定する。
なお、この方法によって求める差分値は、明るさ等の撮影環境によって異なった値となる。
FIG. 4 is a graph for explaining the difference value obtained by the above method. The graph in FIG. 4 shows the distribution of the number of pixels (horizontal axis) with respect to the difference value (vertical axis). As shown in the figure, the difference value generated based on the noise gradually decreases as the difference value increases with the number of pixels having a difference value of 0 being maximized, and rapidly increases when the difference value is larger than a certain difference value. The distribution tends to be reduced in the number of pixels. A difference value exceeding a value at which the number of pixels rapidly decreases can be regarded as an abnormal value, and it is appropriate to determine this value as a limit value. Pixels having difference values that fall within this limit value occupy most of the image area to be detected, and most noise that occurs normally has difference values that fall within this limit value. Therefore, this value is set as a threshold adjustment value as a difference value for obtaining this limit value. However, here, based on the obtained difference value, the following 4. Use to determine the adjustment value.
Note that the difference value obtained by this method differs depending on the shooting environment such as brightness.

4.上記3.の処理を数秒間繰り返し行い、この数秒間に求めた全ての値を基礎にして、これらの値の平均値、最頻値、中間値のいずれか1つを算出し、算出した値を基に閾値調整値を定める。この方法で求めた調整値によって、異物検出動作を安定化することができる。なお、3.及び4.の処理によって求める閾値調整値の精度を向上させるために、この処理で得られる閾値調整値に所定の上限値を設定し、精度を確保する。即ち、得られる閾値調整値が所定の上限値を越えたときは、検出対象として設定した小領域に異物が入るか、もしくは画像全体に影響する状況の変化(照明変化や日照変化、カメラ絞りの変化など)が生じたことが推測できるので、3.及び4.の処理をやり直す、という対処などが行える。   4). 3. above. This process is repeated for a few seconds, and based on all the values obtained in the last few seconds, one of these values is calculated as an average value, a mode value, or an intermediate value. Based on the calculated value, A threshold adjustment value is determined. The foreign object detection operation can be stabilized by the adjustment value obtained by this method. 3. And 4. In order to improve the accuracy of the threshold adjustment value obtained by this process, a predetermined upper limit value is set to the threshold adjustment value obtained by this process to ensure the accuracy. That is, when the obtained threshold adjustment value exceeds a predetermined upper limit value, foreign matter enters a small area set as a detection target, or changes in the situation that affect the entire image (illumination change, change in sunlight, camera aperture Since it can be inferred that a change has occurred), 3. And 4. It is possible to deal with re-processing.

5.上記4.で得られた差分値(大部分の画素が占める限界を定める差分値)を、撮影画像の実測ノイズ量として、このノイズ量を示す値を初期値の第1閾値TH1から下げる閾値調整値とする。つまり、第2閾値TH2は、第1閾値TH1からこの調整値を引いた値となる。   5). 4. above. The difference value (difference value that defines the limit occupied by the majority of pixels) as the measured noise amount of the photographed image is used as the threshold adjustment value that lowers the value indicating this noise amount from the initial first threshold TH1. . That is, the second threshold value TH2 is a value obtained by subtracting this adjustment value from the first threshold value TH1.

〈処理例2〉
上記〈処理例1〉では、ノイズ量の検出対象とする画像領域として、撮影画像のうちの異物の入らない小領域を設定したが、この処理例では、撮影画像の全画面を検出対象とする。なお、全画面とした場合も、処理中には撮影画像に異物が映り込まないという条件が必要であり、この条件を満たせば、上記〈処理例1〉と同じ方法による処理を行っても問題は生じない。
ただ、一定時間毎など決められたタイミングでこの決定処理を行う場合には、全画面を検出対象とすると、ノイズによる差分値(限界値)を求めるために得る撮影画像中に何かしらの異物が映り込む可能性が高くなるため、その分だけ精度が落ちてしまうおそれがある。求めるノイズ量に影響する何かしらの異物の映り込みが起きる状況では、この点を考慮して、ノイズによる差分値の限界値を求める上記〈処理例1〉の3.の手順において、対象画像領域の画素数の大部分を占めるとする割合を、上記〈処理例1〉のときに定めたよりは低くすることで精度の低下を抑制することができる。
<Processing example 2>
In <Processing Example 1>, a small area that does not contain a foreign object in the captured image is set as an image area that is a target for detecting the amount of noise. In this processing example, the entire screen of the captured image is detected. . Even in the case of a full screen, it is necessary that a foreign object does not appear in the photographed image during processing. If this condition is satisfied, it is not necessary to perform processing by the same method as in <Processing Example 1>. Does not occur.
However, when this determination process is performed at a fixed timing, such as every certain time, if the entire screen is the detection target, some foreign matter appears in the captured image obtained to obtain the difference value (limit value) due to noise. Therefore, there is a risk that the accuracy will drop accordingly. In a situation where some kind of foreign matter is reflected in the amount of noise to be obtained, considering this point, the limit value of the difference value due to noise is calculated in the above <Processing example 1> 3. In the above procedure, it is possible to suppress a decrease in accuracy by setting the ratio of the majority of the number of pixels in the target image area to be lower than that determined in the above <Processing Example 1>.

ここで、図2のフローに戻ると、ステップS104の閾値調整ステップ(図3のサブシーケンス)を抜けると、次に、ステップS103の2値化処理により得た異物とそれ以外の画素を判別するため2値化画像に対しラベリングを行う(ステップS105)。このステップでは、異物と判別された画像を連結画素領域(異物画素が連結し、1かたまりとなった画像領域)単位に分け、領域ごとに領域を識別するラベルを付し、管理情報として用いる。
次いで、ラベルの付された各領域の画像が検出対象の異物であるか否かを判定する(ステップS106)。このステップでは、異物と判定されてラベルの付された画像の中から、検出対象の異物(例えば、人間)らしいとみなされる画像を検出するために、当該異物が有する画像の大きさ、形状、等の特徴に合致する画像を判定し、その結果を得る。
Returning to the flow of FIG. 2, if the threshold adjustment step (subsequence of FIG. 3) in step S <b> 104 is exited, then the foreign matter obtained by the binarization process of step S <b> 103 and other pixels are discriminated. Therefore, labeling is performed on the binarized image (step S105). In this step, an image determined to be a foreign object is divided into connected pixel regions (image regions in which foreign pixels are connected to form a single block), a label for identifying the region is attached to each region, and used as management information.
Next, it is determined whether or not the image of each labeled region is a foreign object to be detected (step S106). In this step, in order to detect an image that is considered to be a foreign object to be detected (for example, a human) from images that are determined to be foreign objects and are labeled, An image that matches the characteristics such as is determined, and the result is obtained.

次いで、前段で行った異物の判定結果を利用先に出力する(ステップS107)。出力形態は、例えば、表示部15の原撮影画像を表示する画面上に検出結果として得られた異物の部分を識別可能に表示する方法等を採用することができる。また、検出結果として得たデータを、異物を管理する他の制御システムで利用してもよい。   Next, the foreign substance determination result performed in the previous stage is output to the use destination (step S107). As the output form, for example, a method of displaying the foreign matter portion obtained as a detection result on the screen displaying the original captured image of the display unit 15 so as to be identifiable can be adopted. Further, data obtained as a detection result may be used in another control system that manages foreign matter.

検出結果の出力を行った後、次の撮影画像に対する異物検出処理に移行するが、その前に背景画像の更新処理を行う(ステップS108)。背景画像は、ステップS102において差分画像を生成する際に用いるために記憶部14に保存されるが、撮影環境の経時変化が想定される場合には、この処理フローにおけるように、異物検出動作を行うたびに撮影した最新の背景画像によって記憶部14の保存データを更新することが検出を高精度に保つために必要である。背景更新の方法については、既知のアルゴリズムが採用できる。
背景更新を行った後、次の撮影画像に対する異物検出処理を実行するために、ステップS101に戻る。
After outputting the detection result, the process proceeds to the foreign object detection process for the next photographed image, but before that, the background image is updated (step S108). The background image is stored in the storage unit 14 for use when generating the difference image in step S102. However, when the photographing environment is assumed to change over time, the foreign object detection operation is performed as in this processing flow. It is necessary to update the data stored in the storage unit 14 with the latest background image taken each time in order to keep detection with high accuracy. A known algorithm can be used for the background update method.
After performing the background update, the process returns to step S101 in order to execute the foreign object detection process for the next photographed image.

異物検出の処理フロー(図2)において、閾値調整ステップ(図3のサブシーケンス)で、初期値の第1閾値TH1で異物が判別された場合に、第1閾値TH1よりも上記“閾値調整値の決定”で述べた方法で決定した閾値調整値だけ低い第2閾値TH2値に調整し、その後、引き続いて行う第2閾値TH2による2値化処理で異物と判別される画素が検出されなくなったときに再び第1閾値TH1に戻す閾値調整を実行し、この閾値調整を画素毎に行うことによって、発生する殆どのノイズの影響を受けることがなく、異物検出動作が不安定になることを防ぐことができ、正確な異物検出ができる。特に、本実施形態では、ノイズにより検出が断続されることがないため、異物が継続的に検出されることを条件に通報を行う置き去り又は持ち去り検知では、有効性をより高めることができる。   In the foreign matter detection processing flow (FIG. 2), when the foreign matter is determined by the first threshold value TH1 of the initial value in the threshold adjustment step (subsequence of FIG. 3), the above “threshold adjustment value than the first threshold value TH1. The threshold value adjusted by the method described in “Determination of the threshold value” is adjusted to a second threshold value TH2 that is lower, and pixels that are determined to be foreign objects are no longer detected in the subsequent binarization process using the second threshold value TH2. Sometimes, threshold adjustment is performed again to return to the first threshold TH1, and this threshold adjustment is performed for each pixel, so that it is not affected by most of the generated noise and prevents the foreign object detection operation from becoming unstable. And accurate foreign object detection can be performed. In particular, in the present embodiment, detection is not intermittently caused by noise, so that the effectiveness can be further improved in the detection of leaving or taking away on the condition that foreign matter is continuously detected.

次に、“調整値の決定”に必要なノイズ量の算出(以下「ノイズ量算出」処理という)をどのようなタイミングで行うかについて説明する。
ノイズ量算出処理は、調整値を決定するために、上述のように、監視場所を撮影した画像の画素値を基に統計的な処理手法を用いて実測ノイズ量を算出するので、相当の処理負担が生じる。この処理負担を軽減するためには、異物検出の精度が保たれる撮影環境があれば、できるだけ少なくすることが望ましい。そこで、以下の実施形態では、異物検出処理を行う度ごとに行わずに、処理負担が軽減できる所定のタイミングでノイズ量算出処理を行う方法について説明する。
Next, the timing at which the calculation of the noise amount necessary for “determination of the adjustment value” (hereinafter referred to as “noise amount calculation” processing) is performed will be described.
In the noise amount calculation process, as described above, the measured noise amount is calculated using a statistical processing method based on the pixel value of the image obtained by photographing the monitoring place in order to determine the adjustment value. A burden arises. In order to reduce this processing burden, it is desirable to reduce as much as possible if there is an imaging environment in which the accuracy of foreign object detection is maintained. Therefore, in the following embodiment, a method of performing the noise amount calculation process at a predetermined timing that can reduce the processing load without performing the foreign object detection process each time will be described.

「ノイズ量算出処理」
異物検出処理におけるノイズ量算出処理を、処理負担が軽減できる所定のタイミングで行う方法は、主に次の2通りである。
1つは、予め決められた所定タイミングでノイズ量算出処理を行う方法であり、もう1つは、撮影環境が変化したタイミングでノイズ量算出処理を行う方法である。
以下、上記2方法を“所定タイミングによる処理”と“撮影環境の変化に対応する処理”と命名して、それぞれの処理例を示す。
"Noise amount calculation process"
There are mainly two methods for performing the noise amount calculation processing in the foreign object detection processing at a predetermined timing at which the processing load can be reduced.
One is a method of performing a noise amount calculation process at a predetermined timing determined in advance, and the other is a method of performing a noise amount calculation process at a timing when the shooting environment changes.
Hereinafter, the above two methods are named “processing at a predetermined timing” and “processing corresponding to a change in photographing environment”, and respective processing examples are shown.

“所定タイミングによる処理”
まず、ノイズ量算出処理を所定タイミングで行う手順として、異物検出の処理が起動される時にだけ行うようにする。例えば、外光がなく、室内照明だけといった一定の条件で撮影場所が照明されているような撮影環境においては、動作が終了するまでノイズの変動がほとんどない、という前提のもとに異物検出動作を行う場合に適した処理である。この処理例では、起動時だけにノイズ量算出処理を行い、その後算出したノイズ量を使い続けて閾値を調整するので、最も処理負担の少ない処理といえる。
“Processing at a specified timing”
First, as a procedure for performing the noise amount calculation process at a predetermined timing, it is performed only when the foreign object detection process is activated. For example, in a shooting environment where there is no outside light and the shooting location is illuminated under certain conditions such as indoor lighting, the foreign object detection operation is based on the assumption that there is almost no noise fluctuation until the operation is completed. This process is suitable for performing the above. In this processing example, the noise amount calculation process is performed only at the time of startup, and the threshold value is adjusted by continuing to use the calculated noise amount thereafter.

図5は、異物検出処理の起動時だけにノイズ量の算出を行うようにした異物検出処理の処理例に係るフロー図である。
図5の処理フローによると、制御部11は、監視システムが起動されると処理を開始し、先ず、ノイズ量の算出処理を行い(ステップS301)、閾値調整値(上記“閾値調整値の決定”、参照)を求める。なお、求めた閾値調整値は、後段の閾値調整(ステップS305)で第1閾値TH1から第2閾値TH2値への調整に用いる。
ステップS301の処理後、異物検出動作をステップS302〜S309の異物検出の処理フローに従って行う。なお、ステップS302〜S309の処理は、上記「異物検出処理」において図2及び3を参照して説明した異物検出の基本処理(ステップS101〜S108)と同じであるから、先の説明を参照することとし、ここでは説明を省略する。
FIG. 5 is a flowchart according to a processing example of the foreign object detection process in which the noise amount is calculated only when the foreign object detection process is started.
According to the processing flow of FIG. 5, the control unit 11 starts processing when the monitoring system is activated, first performs noise amount calculation processing (step S <b> 301), and sets a threshold adjustment value (determining the above “threshold adjustment value”). ", See). The obtained threshold adjustment value is used for adjustment from the first threshold TH1 to the second threshold TH2 in the subsequent threshold adjustment (step S305).
After the process of step S301, the foreign object detection operation is performed according to the foreign object detection process flow of steps S302 to S309. The processing in steps S302 to S309 is the same as the foreign matter detection basic processing (steps S101 to S108) described with reference to FIGS. 2 and 3 in the above “foreign matter detection processing”. Therefore, the description is omitted here.

ノイズ量算出処理を所定タイミングで行う手順について、次に示す処理例では、異物検出処理の起動時にノイズ量算出処理を行い、その後一定時間周期でノイズ量算出処理を行うようにする。例えば、撮影場所が日照の影響を受けるような撮影環境であっても、急激な明るさの変化ではなければ、一定時間周期で変化に追従してノイズ量を算出し、求めた閾値調整値によって、許容範囲の精度で閾値調整を行う。この処理例によれば、起動時だけにノイズ量算出処理を行う上記処理例に比べて処理負担が大きくなるが、撮影環境の制限をより緩和することができる。   Regarding the procedure for performing the noise amount calculation process at a predetermined timing, in the following processing example, the noise amount calculation process is performed when the foreign object detection process is activated, and then the noise amount calculation process is performed at a constant time period. For example, even in a shooting environment where the shooting location is affected by sunlight, if there is no sudden change in brightness, the amount of noise is calculated following the change at a fixed time period, and the calculated threshold adjustment value is used. Threshold adjustment is performed with an accuracy within an allowable range. According to this processing example, the processing load is increased as compared with the above processing example in which the noise amount calculation processing is performed only at the time of activation, but the limitation of the shooting environment can be more relaxed.

図6は、一定時間周期でノイズ量の算出を行うようにした異物検出処理の処理例に係るフロー図である。
なお、異物検出動作をステップS402〜S411の異物検出の処理フローに従って行う。ただ、ステップS403及びS404を除くステップS402〜S411の処理は、上記「異物検出処理」において図2及び3を参照して説明した異物検出の基本処理(ステップS101〜S108)と同じである。したがって、先の説明を参照することとし、ここでは説明を省略する。
FIG. 6 is a flowchart according to a processing example of the foreign object detection processing in which the amount of noise is calculated at a constant time period.
The foreign object detection operation is performed in accordance with the foreign object detection processing flow in steps S402 to S411. However, the processing of steps S402 to S411 except for steps S403 and S404 is the same as the foreign matter detection basic processing (steps S101 to S108) described with reference to FIGS. 2 and 3 in the “foreign matter detection processing”. Therefore, the previous description will be referred to and the description will be omitted here.

図6の処理フローに示すように、制御部11は、監視システムが起動されると処理を開始し、先ず、ノイズ量の算出処理を行い(ステップS401)、閾値調整値を求める(上記“閾値調整値の決定”、参照)。
ここで、ステップS401のノイズ量の算出処理を行ったとき、次にノイズ量の算出処理を行う時間を管理するためにタイマーを始動する。なお、このステップで求めた閾値調整値は、後段の閾値調整(ステップS407)で第1閾値TH1から第2閾値TH2値への調整に用いる。
As shown in the processing flow of FIG. 6, the control unit 11 starts processing when the monitoring system is activated, and first performs noise amount calculation processing (step S <b> 401) to obtain a threshold adjustment value (the above “threshold value”). See “Determining Adjustment Values”.
Here, when the noise amount calculation process in step S401 is performed, a timer is started in order to manage the time for the next noise amount calculation process. The threshold adjustment value obtained in this step is used for adjustment from the first threshold value TH1 to the second threshold value TH2 in the subsequent threshold adjustment (step S407).

また、この実施形態の処理フローでは、先にノイズ量の算出処理を行ったときに始動したタイマーを確認するステップを入れて、タイマーに設定しておいた一定時間が経過した時に再びノイズ量の算出処理を行う。フローとしては、ステップS403で一定時間の経過をタイマーにより確認し、一定時間が経過した場合には(ステップS403-YES)、ノイズ量の算出処理を行う。なお、このノイズ量の算出処理を行ったときにも、次にノイズ量の算出処理を行う時間を管理するためにタイマーをリセットし、再び始動する。
他方、ステップS403で一定時間の経過をタイマーにより確認し、一定時間が経過していない場合には(ステップS403-NO)、ノイズ量の算出処理を行うことなく、異物検出処理を進める。
Further, in the processing flow of this embodiment, a step for confirming the timer that was started when the noise amount calculation process was performed first is included, and the noise amount is again measured when a predetermined time set in the timer has elapsed. Perform the calculation process. As a flow, the elapse of a certain time is confirmed by a timer in step S403, and when the certain time has elapsed (YES in step S403), a noise amount calculation process is performed. Even when the noise amount calculation process is performed, the timer is reset and started again in order to manage the time for the next noise amount calculation process.
On the other hand, the elapse of the predetermined time is confirmed by a timer in step S403, and if the predetermined time has not elapsed (step S403-NO), the foreign object detection process proceeds without performing the noise amount calculation process.

“撮影環境の変化に対応する処理”
この撮影環境の変化に対応する処理では、異物検出処理を行う度ごとに撮影環境の変化を調べて、調べた結果を基にノイズ量を算出し直すか否かを確認し、確認結果によってノイズ量算出処理を行う。例えば、撮影場所が日照の影響を受けるような撮影環境であり、雲によって日照が遮られ急激な明るさの変化が起きる場合、ノイズ量算出を上記のように一定時間周期で行うと、日照の変化に追従できない、という不都合が生じるが、この処理例では、異物検出処理時に撮影環境の変化を調べて、必要性を確認して実行することで、撮影環境の変化に追従したノイズ量の算出を行い、常時検出を高精度に保つことができる。この処理例によれば、所定のタイミングでノイズ量算出処理を行う上記処理例に比べて処理負担が大きくなる可能性があるが、撮影環境の制限をさらに緩和することができる。
“Processing for changes in shooting environment”
In the processing corresponding to the change in the shooting environment, the change in the shooting environment is checked every time the foreign object detection process is performed, and it is confirmed whether or not the noise amount is recalculated based on the checked result. A quantity calculation process is performed. For example, in a shooting environment where the shooting location is affected by sunlight, when the sunlight is blocked by clouds and sudden changes in brightness occur, if the noise amount calculation is performed at regular intervals as described above, Inconvenient inability to follow changes, but in this processing example, the amount of noise following the changes in the shooting environment is calculated by checking the change in the shooting environment during the foreign object detection process and confirming the necessity. Can always be detected with high accuracy. According to this processing example, there is a possibility that the processing load may be increased as compared with the above processing example in which the noise amount calculation processing is performed at a predetermined timing, but it is possible to further ease the limitation of the shooting environment.

本実施形態では、撮影環境の変化を調べるため、撮影環境検知部13が設けられている(図1参照)。撮影環境検知部13は、屋内、屋外、昼、夜、日照の有無、撮影場所の転移等の撮影環境の変化を検知する手段として、変化を推定する方法によるものを含め諸種の手段を利用することができるが、ここでは撮影場所の明るさを検知する方法による。
また、撮影場所の明るさを検知する方法として、この実施形態では、カメラ1の撮影画像を基に画像全体の変化に基づいてこの検知を行う方法を採用する。
In the present embodiment, a photographing environment detection unit 13 is provided in order to examine changes in the photographing environment (see FIG. 1). The shooting environment detection unit 13 uses various means including a method of estimating the change as a means for detecting changes in the shooting environment such as indoors, outdoors, daytime, night, presence / absence of sunshine, and transfer of the shooting location. However, here, it depends on the method of detecting the brightness of the shooting location.
In addition, as a method for detecting the brightness of the shooting location, in this embodiment, a method is used in which this detection is performed based on a change in the entire image based on the image taken by the camera 1.

撮影環境の変化を撮影画像全体の変化の検知に基づいて行う方法の処理例を以下に示す。
この処理例は、下記1.〜5.に示す処理手順に従って実行する。
1.撮影画像のうち処理対象とする画像領域として、異物の入らない小領域を設定する。なお、この設定を行う理由は、異物が入らない画像領域の方が安定した検知処理ができるからである。
2.上記1.で設定した小領域に対し背景差分を求めることにより、画素毎の輝度値の変化量を差分値(絶対値)として得る。なお、背景差分を求めるときに用いる背景画像は、異物検出の処理に用いるために保存されているものである。
3.上記2.で差分値を得た各画素のうち差分値の小さい方から該当する値を持つ画素の画素数を順に足していき、総数が小領域の画素数の大部分の割合(予め定められた割合であり、経験値として、例えば、小領域の画素数の9割といった数値を当てる)を占めたときの差分値を求める値とし、求めた値を記憶する。
A processing example of a method for performing a change in shooting environment based on detection of a change in the entire shot image will be described below.
This processing example is as follows. ~ 5. Execute according to the processing procedure shown in
1. A small area that does not contain a foreign object is set as an image area to be processed in the captured image. The reason for performing this setting is that a stable detection process can be performed in an image area where no foreign matter enters.
2. Above 1. By obtaining the background difference for the small region set in step 1, the amount of change in luminance value for each pixel is obtained as the difference value (absolute value). The background image used when obtaining the background difference is stored for use in the foreign object detection process.
3. 2. In this order, the number of pixels having the corresponding value from the smaller difference value is added in order, and the total number is the ratio of the majority of the number of pixels in the small area (predetermined ratio) Yes, as an experience value, for example, a value that is 90% of the number of pixels in a small area is assigned), and a difference value is obtained, and the obtained value is stored.

4.上記3.の処理を数秒間繰り返し行い、この数秒間に求めた全ての値を基礎にして、これらの値の平均値、最頻値、中間値のいずれか1つを算出し、算出した値を求める撮影環境の変化を示す値とする。
5.上記4.で得られた差分値(大部分の画素が占める限界を定める差分値)を、ノイズ量を算出し直すか否かを判定するために設定した閾値と比較し、比較結果によりこの判定をする。なお、この判定は、異物検出処理を行うたびごとに行い、処理を繰り返す間に一定時間以上閾値を越え続けた場合に、画像全体の明るさの変化、つまり意図する(ノイズ量の算出を実行する)撮影環境の変化が生じたと判定する手順としてもよい。
4). 3. above. The above process is repeated for several seconds, and based on all the values obtained in these several seconds, one of these values is calculated, and the average value, mode value, or intermediate value is calculated, and the calculated value is obtained. A value indicating the environmental change.
5. 4. above. The difference value (difference value that determines the limit occupied by most pixels) is compared with a threshold value set to determine whether or not to recalculate the noise amount, and this determination is made based on the comparison result. This determination is performed every time the foreign object detection process is performed. If the threshold value is exceeded for a certain period of time or more while the process is repeated, the brightness of the entire image is changed, that is, the intention is calculated (a noise amount is calculated). Yes) It may be a procedure for determining that a change in the shooting environment has occurred.

図7は、撮影環境の変化に対応してノイズ量の算出を行うようにした異物検出処理の処理例に係るフロー図である。
なお、図示のフローにおいて、ステップS503〜S505を除くステップS502〜S512の処理は、上記「異物検出処理」において図2及び3を参照して説明した異物検出の基本処理(ステップS101〜S108)と同じである。したがって、先の説明を参照することとし、ここでは説明を省略する。
FIG. 7 is a flowchart according to a processing example of the foreign object detection processing in which the amount of noise is calculated in response to a change in the shooting environment.
In the illustrated flow, the processing of steps S502 to S512 excluding steps S503 to S505 is the same as the foreign matter detection basic processing (steps S101 to S108) described with reference to FIGS. 2 and 3 in the “foreign matter detection processing”. The same. Therefore, the previous description will be referred to and the description will be omitted here.

図7の処理フローに示すように、制御部11は、監視システムが起動されると処理を開始し、先ず、ノイズ量の算出処理を行い(ステップS501)、閾値調整値(上記“閾値調整値の決定”、参照)の初期値を求める。なお、このステップで求めた閾値調整値は、後段の閾値調整(ステップS508)で第1閾値TH1から第2閾値TH2値への調整に用いる。   As shown in the processing flow of FIG. 7, the control unit 11 starts processing when the monitoring system is activated. First, the control unit 11 performs noise amount calculation processing (step S <b> 501), and sets a threshold adjustment value (the above “threshold adjustment value”). The initial value is determined. The threshold adjustment value obtained in this step is used for the adjustment from the first threshold TH1 to the second threshold TH2 in the subsequent threshold adjustment (step S508).

また、この実施形態の処理フローでは、異物検出処理を行うたびごとに撮影環境の変化を判定し、判定結果からノイズ量を算出し直すか否かを判定するステップを入れて、この判定に従いノイズ量の算出処理を行う。
処理フローとしては、撮影画像を入力し(ステップS502)、その後、撮影画像全体の明るさ(撮影環境)の変化によりノイズ量を算出するか否かの判定をする(ステップS503)。
次いで、ステップS503の判定結果を確認して(ステップS504)、ノイズ量を算出すると判定された場合には(ステップS504-YES)、ノイズ量の算出処理を行う(ステップS505)。なお、このとき、先にノイズ量の算出処理により求められ、保存されている閾値調整値を今回求めた値で更新する。
他方、ステップS504でノイズ量を算出する必要がないと判定された場合には(ステップS504-NO)、ノイズ量の算出処理を行うことなく、異物検出処理を進める。
In the processing flow of this embodiment, a change in the shooting environment is determined every time the foreign object detection process is performed, and a step of determining whether to recalculate the noise amount from the determination result is included. An amount calculation process is performed.
As a processing flow, a photographed image is input (step S502), and then it is determined whether or not the amount of noise is calculated based on a change in the brightness of the entire photographed image (photographing environment) (step S503).
Next, the determination result in step S503 is confirmed (step S504). If it is determined that the noise amount is to be calculated (step S504-YES), a noise amount calculation process is performed (step S505). At this time, the stored threshold adjustment value obtained by the noise amount calculation process and updated at this time is updated.
On the other hand, if it is determined in step S504 that it is not necessary to calculate the amount of noise (step S504-NO), the foreign object detection processing is performed without performing the noise amount calculation processing.

異物検出の処理フロー(図5〜7)において、監視場所に設置されたカメラ1の撮影画像を基にノイズ量算出処理を行い、算出結果に基づいて決定される閾値調整値を異物検出動作に反映させることにより、ノイズの影響を低減しつつ異物検出を高精度に保つことができ、異物検出をより安定して行うことができる。
また、起動時だけにノイズ量算出処理を行う処理フロー(図5)によれば、ノイズ量算出処理の負担が少なくて済む。
また、一定時間周期にノイズ量算出処理を行う処理フロー(図6)によれば、起動時だけの処理に比べて処理負担が大きくなるが、撮影環境の制限を緩和することができる。撮影環境の変化に対応する処理フロー(図7)によれば、所定のタイミングでノイズ量算出処理を行う図5及び6の処理例に比べて処理負担が大きくなる可能性があるが、撮影環境の制限をさらに緩和することができる。
In the foreign matter detection processing flow (FIGS. 5 to 7), a noise amount calculation process is performed based on the captured image of the camera 1 installed at the monitoring location, and the threshold adjustment value determined based on the calculation result is set as the foreign matter detection operation. By reflecting, foreign object detection can be maintained with high accuracy while reducing the influence of noise, and foreign object detection can be performed more stably.
Further, according to the processing flow (FIG. 5) in which the noise amount calculation process is performed only at the time of startup, the burden of the noise amount calculation process can be reduced.
Further, according to the processing flow (FIG. 6) for performing the noise amount calculation processing at a constant time period, the processing load is increased as compared with the processing only at the time of activation, but the restriction of the photographing environment can be relaxed. According to the processing flow corresponding to the change of the shooting environment (FIG. 7), there is a possibility that the processing load becomes larger than the processing examples of FIGS. 5 and 6 in which the noise amount calculation processing is performed at a predetermined timing. Can be further relaxed.

1・・カメラ、10・・画像処理装置、11・・制御部、12・・画像処理部、13・・撮影環境検知部、14・・記憶部、15・・表示部、16・・入力部、17・・インターフェース部、18・・バス。   DESCRIPTION OF SYMBOLS 1 ... Camera 10 ... Image processing apparatus 11 ... Control part 12 ... Image processing part 13 ... Imaging environment detection part 14 ... Storage part 15 ... Display part 16 ... Input part , 17 · Interface part, 18 · Bus.

Claims (6)

所定の場所に設置される動画を撮るカメラにより背景を撮影し画素の単位で変換される背景画像と背景撮影後に同場所を前記カメラにより撮影し得られる撮影画像との差分画像を基に異物を検出する処理を行う画像処理装置であって、
前記差分画像を予め定めた閾値と画素毎に比較し、比較結果によって異物画素とそれ以外の画素に判別する閾値処理手段と、
前記閾値処理手段によって判別された異物画素よりなる画像を基に検出対象の異物であるか否かを判定する異物判定手段と、
前記異物判定手段の判定結果を異物検出結果として出力する手段と、
前記閾値処理手段で用いる閾値の設定を、撮影環境で生じるノイズの大きさに応じてノイズを検出しないように予め定められた第1閾値と第1閾値よりも所定値だけ低い第2閾値との間で切り替え可能として、異物画素と判別した場合に用いていた閾値が第1閾値であれば、該当する画素に対し次に前記閾値処理手段で処理に用いる閾値の設定を第2閾値に切り替える一方、異物画素ではないと判別した場合に用いていた閾値が前記第2閾値であれば、設定を第1閾値に切り替えて閾値を調整する閾値調整手段と、
を有したことを特徴とする画像処理装置。
A foreign object is captured based on a difference image between a background image that is captured by a camera that captures a moving image installed at a predetermined location and the background image is converted in units of pixels and a captured image that can be captured by the camera after the background is captured. An image processing apparatus that performs processing to detect,
A threshold processing means for comparing the difference image for each pixel with a predetermined threshold, and discriminating between the foreign pixel and the other pixels based on the comparison result;
Foreign matter determination means for determining whether or not the foreign object is a detection target based on an image made up of foreign matter pixels determined by the threshold processing means;
Means for outputting the determination result of the foreign matter determination means as a foreign matter detection result;
The threshold value used by the threshold value processing means is set to a first threshold value that is set in advance so as not to detect noise according to the magnitude of noise that occurs in the shooting environment, and a second threshold value that is lower than the first threshold value by a predetermined value. If the threshold value used when it is determined that the pixel is a foreign pixel is the first threshold value, the threshold value used for the next processing by the threshold value processing unit for the corresponding pixel is switched to the second threshold value. If the threshold value used when it is determined that the pixel is not a foreign pixel is the second threshold value, threshold adjustment means for switching the setting to the first threshold value and adjusting the threshold value;
An image processing apparatus comprising:
請求項1に記載された画像処理装置において、
前記カメラにより撮影される画像のうち異物が入らない画像領域の画素を対象にフレーム間差分値を得、得られる各画素のフレーム間差分値の中の異常値を除く画素の差分値の大部分が収まる限界値を求め、求めた限界値を第2閾値に係る前記所定値として前記閾値処理手段で用いる第2閾値を生成する第2閾値生成手段を有したことを特徴とする画像処理装置。
The image processing apparatus according to claim 1,
Most of the difference values of pixels excluding abnormal values in the inter-frame difference value of each pixel obtained by obtaining the inter-frame difference value for pixels in the image area where no foreign matter enters among the images photographed by the camera An image processing apparatus, comprising: a second threshold value generating unit configured to generate a second threshold value that is used by the threshold value processing unit as a predetermined value related to a second threshold value.
請求項2に記載された画像処理装置において、
前記第2閾値生成手段は、前記所定値を求める処理を複数回繰り返し、求まる複数の所定値の平均値、最頻値、中間値のいずれか1つを基に第2閾値を生成する手段であることを特徴とする画像処理装置。
The image processing apparatus according to claim 2,
The second threshold generation unit is a unit that generates the second threshold based on any one of an average value, a mode value, and an intermediate value of the plurality of predetermined values obtained by repeating the process of calculating the predetermined value a plurality of times. An image processing apparatus comprising:
請求項2又は3に記載された画像処理装置において、
予め定めたタイミングで前記第2閾値生成手段を動作させて第2閾値を生成することを特徴とする画像処理装置。
In the image processing device according to claim 2 or 3,
An image processing apparatus that generates the second threshold value by operating the second threshold value generation unit at a predetermined timing.
請求項2又は3に記載された画像処理装置において、
前記カメラにより撮影される画像全体の輝度値が変化したことを検出する撮影環境検知手段を有し、
前記撮影環境検知手段によって画像全体の輝度値の変化が検知されたときに前記第2閾値生成手段は、画像全体の変化を検出したときに前記第2閾値生成手段を動作させて第2閾値を生成することを特徴とする画像処理装置。
In the image processing device according to claim 2 or 3,
A photographing environment detecting means for detecting that the luminance value of the entire image photographed by the camera has changed,
When the change in luminance value of the entire image is detected by the photographing environment detection unit, the second threshold value generation unit operates the second threshold value generation unit to detect the second threshold value when the change of the entire image is detected. An image processing apparatus that generates the image processing apparatus.
所定の場所に設置される動画を撮るカメラにより背景を撮影し画素の単位で変換される背景画像と背景撮影後に同場所を前記カメラにより撮影し得られる撮影画像との差分画像を基に異物を検出する処理を行う画像処理方法であって、
前記差分画像を予め定めた閾値と画素毎に比較し、比較結果によって異物画素とそれ以外の画素に判別する閾値処理工程と、
前記閾値処理工程で判別された異物画素よりなる画像を基に検出対象の異物であるか否かを判定する異物判定工程と、
前記異物判定工程の判定結果を異物検出結果として出力する工程と、
前記閾値処理工程で用いる閾値の設定を、撮影環境で生じるノイズの大きさに応じてノイズを検出しないように予め定められた第1閾値と第1閾値よりも所定値だけ低い第2閾値との間で切り替え可能として、異物画素と判別した場合に用いていた閾値が第1閾値であれば、該当する画素に対し次に行う閾値処理で用いる閾値の設定を第2閾値に切り替える一方、異物画素ではないと判別した場合に用いていた閾値が前記第2閾値であれば、設定を第1閾値に切り替えて閾値を調整する閾値調整工程と、
を有したことを特徴とする画像処理方法。
A foreign object is captured based on a difference image between a background image that is captured by a camera that captures a moving image installed at a predetermined location and the background image is converted in units of pixels and a captured image that can be captured by the camera after the background is captured. An image processing method for performing detection processing,
A threshold processing step of comparing the difference image for each pixel with a predetermined threshold, and determining a foreign pixel and other pixels according to the comparison result;
A foreign matter determination step for determining whether or not the foreign matter is a detection target based on the image formed of the foreign matter pixels determined in the threshold processing step;
Outputting the determination result of the foreign matter determination step as a foreign matter detection result;
The threshold value used in the threshold value processing step is set to a first threshold value that is determined in advance so as not to detect noise in accordance with the magnitude of noise that occurs in the shooting environment, and a second threshold value that is lower than the first threshold value by a predetermined value. If the threshold value used when the pixel is determined to be a foreign pixel is the first threshold value, the threshold value used in the threshold processing to be performed next for the corresponding pixel is switched to the second threshold value. If the threshold value used when it is determined that the threshold value is not the second threshold value, a threshold adjustment step of adjusting the threshold value by switching the setting to the first threshold value;
An image processing method characterized by comprising:
JP2010266674A 2010-11-30 2010-11-30 Image processing apparatus and image processing method Active JP5500507B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2010266674A JP5500507B2 (en) 2010-11-30 2010-11-30 Image processing apparatus and image processing method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2010266674A JP5500507B2 (en) 2010-11-30 2010-11-30 Image processing apparatus and image processing method

Publications (2)

Publication Number Publication Date
JP2012118680A true JP2012118680A (en) 2012-06-21
JP5500507B2 JP5500507B2 (en) 2014-05-21

Family

ID=46501447

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2010266674A Active JP5500507B2 (en) 2010-11-30 2010-11-30 Image processing apparatus and image processing method

Country Status (1)

Country Link
JP (1) JP5500507B2 (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103929624A (en) * 2014-04-29 2014-07-16 金三立视频科技(深圳)有限公司 Box camera and ball camera cooperative tracking and monitoring method
KR101583036B1 (en) * 2014-12-24 2016-01-06 한국항공우주연구원 Method detecting interest object by generating and removing isolated points from celestial image

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH07282262A (en) * 1994-04-15 1995-10-27 Mitsubishi Electric Corp Body detection system and control unit equipped with the same
JP2007257449A (en) * 2006-03-24 2007-10-04 Toyota Motor Corp Road division line detector
JP2008076445A (en) * 2006-09-19 2008-04-03 Ricoh Co Ltd Projection-type display device, projection-type display method, program for performing this method, and computer-readable medium with the program stored
JP2008180696A (en) * 2006-12-28 2008-08-07 Sharp Corp Defect detector, defect detecting method, image sensor device, image sensor module, defect detecting program, and computer readable recording medium

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH07282262A (en) * 1994-04-15 1995-10-27 Mitsubishi Electric Corp Body detection system and control unit equipped with the same
JP2007257449A (en) * 2006-03-24 2007-10-04 Toyota Motor Corp Road division line detector
JP2008076445A (en) * 2006-09-19 2008-04-03 Ricoh Co Ltd Projection-type display device, projection-type display method, program for performing this method, and computer-readable medium with the program stored
JP2008180696A (en) * 2006-12-28 2008-08-07 Sharp Corp Defect detector, defect detecting method, image sensor device, image sensor module, defect detecting program, and computer readable recording medium

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103929624A (en) * 2014-04-29 2014-07-16 金三立视频科技(深圳)有限公司 Box camera and ball camera cooperative tracking and monitoring method
CN103929624B (en) * 2014-04-29 2017-07-04 深圳金三立视频科技股份有限公司 Gunlock, ball machine collaboration tracing and monitoring method
KR101583036B1 (en) * 2014-12-24 2016-01-06 한국항공우주연구원 Method detecting interest object by generating and removing isolated points from celestial image

Also Published As

Publication number Publication date
JP5500507B2 (en) 2014-05-21

Similar Documents

Publication Publication Date Title
KR102207939B1 (en) Defog system and method
JP4729610B2 (en) Smoke detector
JP6944272B2 (en) Motion detector and its control method
WO2017206444A1 (en) Method and device for detecting imaging difference, and computer storage medium
US20150146006A1 (en) Display control apparatus and display control method
JP2015028753A (en) Image processing apparatus and image processing method
US20150371376A1 (en) Control apparatus, control method, and storage medium
JP2018029237A5 (en)
EP3110144A1 (en) Monitoring system
JP5088279B2 (en) Target tracking device
CN100375530C (en) Movement detecting method
JP5500507B2 (en) Image processing apparatus and image processing method
US20130235195A1 (en) Image processing device, image processing method, and image processing program
JP2011215804A (en) Smoke detection device
JP5015838B2 (en) Smoke detector
JP2022000829A (en) Image comparing apparatus, image comparing program, and image comparing method
JP2009225345A (en) Program, device, and method for correcting image
JP7251425B2 (en) Attached matter detection device and attached matter detection method
JP4853657B2 (en) Image processing device
JP5388827B2 (en) Image processing device for monitoring
JP2014216832A (en) Imaging device
CN111064910B (en) Image sensing method and image sensing system
JP4619082B2 (en) Image determination device
JP6081786B2 (en) Smoke detector
US11178339B2 (en) Control of an illuminator

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20130422

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20131106

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20131118

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20140110

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: 20140217

R150 Certificate of patent or registration of utility model

Ref document number: 5500507

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20140302