JP7256032B2 - Person counting device, person counting method and person counting program - Google Patents

Person counting device, person counting method and person counting program Download PDF

Info

Publication number
JP7256032B2
JP7256032B2 JP2019037871A JP2019037871A JP7256032B2 JP 7256032 B2 JP7256032 B2 JP 7256032B2 JP 2019037871 A JP2019037871 A JP 2019037871A JP 2019037871 A JP2019037871 A JP 2019037871A JP 7256032 B2 JP7256032 B2 JP 7256032B2
Authority
JP
Japan
Prior art keywords
counting
person
trajectory
area
movement
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
JP2019037871A
Other languages
Japanese (ja)
Other versions
JP2020140660A (en
Inventor
豊 北野
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.)
Glory Ltd
Original Assignee
Glory Ltd
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 Glory Ltd filed Critical Glory Ltd
Priority to JP2019037871A priority Critical patent/JP7256032B2/en
Publication of JP2020140660A publication Critical patent/JP2020140660A/en
Application granted granted Critical
Publication of JP7256032B2 publication Critical patent/JP7256032B2/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Closed-Circuit Television Systems (AREA)
  • Image Analysis (AREA)

Description

本発明は、人物計数装置、人物計数方法及び人物計数プログラムに関する。より詳しくは、所定エリアを撮影した映像に基づいて計数エリアを通過した人物の人数を計数するのに好適な人物計数装置、人物計数方法及び人物計数プログラムに関する。 The present invention relates to a person counting device, a person counting method, and a person counting program. More specifically, the present invention relates to a person counting device, a person counting method, and a person counting program suitable for counting the number of persons who have passed through a counting area based on an image of a predetermined area.

監視カメラによって屋内外の所定エリアが撮影された映像を解析し、その所定エリアを通過した人物の人数を数える手法が従来から提案されている。 2. Description of the Related Art Conventionally, there has been proposed a method of analyzing a video of a predetermined indoor/outdoor area captured by a surveillance camera and counting the number of people who have passed through the predetermined area.

例えば、特許文献1には、映像内に人の出入りの基準となる線分を設定し、各歩行者の移動ベクトルがその線分を横切る場合にその人物を計数対象とする方法が開示されている。 For example, Patent Literature 1 discloses a method of setting a line segment in an image as a reference for the entry and exit of a person, and counting the person when the movement vector of each pedestrian crosses the line segment. there is

また、特許文献2には、店舗内での顧客の移動状況を分析するために、計測エリアの各辺と、人物の動線との交差状況に基づいて、その人物の移動パターンを特定し、移動パターンごとに人数を集計する方法が開示されている。 In addition, in Patent Document 2, in order to analyze the movement of customers in the store, the movement pattern of the person is specified based on the intersection of each side of the measurement area and the flow line of the person, A method for counting the number of people for each movement pattern is disclosed.

特開2016-71801号公報JP 2016-71801 A 特許第5834249号Patent No. 5834249

しかしながら、特許文献1記載の方法では、混雑時に複数の人物が重なることで線分(計数ライン)の前後で移動ベクトルが途切れ、計数漏れが発生する可能性がある。 However, in the method described in Patent Literature 1, when a plurality of people overlap during congestion, there is a possibility that the motion vector is interrupted before and after the line segment (counting line), resulting in an omission in counting.

特許文献2記載の方法では、計測対象はエリア(平面)であるが、計測エリアの少なくとも一辺と、人物の動線との交差状況を検出する必要があることから、人物の動線は計測エリアの少なくとも一辺を横切る必要がある。したがって、この方法でも混雑時に複数の人物が重なると、計測エリアの辺の前後で動線が途切れ、その人物が計数から漏れてしまう可能性がある。 In the method described in Patent Document 2, the object to be measured is an area (plane), but it is necessary to detect the intersection of at least one side of the measurement area and the person's flow line. must cross at least one side of Therefore, even with this method, when a plurality of people overlap during congestion, there is a possibility that the line of flow will be interrupted before and after the side of the measurement area, and that person will be omitted from the count.

上記課題に鑑み、本発明においては、混雑時であっても人数の計数漏れを低減でき、人数計数の精度を向上することが可能な人物計数装置、人物計数方法及び人物計数プログラムを提供することを目的とする。 In view of the above problems, the present invention provides a people counting device, a people counting method, and a people counting program capable of reducing omissions in counting the number of people even during congestion and improving the accuracy of counting people. With the goal.

上述した課題を解決し、目的を達成するために、本発明は、所定エリアを撮影した映像に基づいて、前記所定エリア内の計数エリアを通過した人物の人数を計数する人物計数装置であって、前記映像から人物ごとの移動軌跡を検出する軌跡検出部と、前記軌跡検出部により検出した移動軌跡のうちの、前記計数エリア内における長さが所定の長さ以上である移動軌跡の本数に基づいて、前記計数エリアを通過した人物の人数を計数する人物計数部と、を備えることを特徴とする。 In order to solve the above-described problems and achieve the object, the present invention provides a person counting device that counts the number of persons who have passed through a counting area within a predetermined area based on a video image of the predetermined area. a trajectory detection unit for detecting a movement trajectory for each person from the video; and a person counting unit that counts the number of persons who have passed through the counting area based on the number of persons.

また、本発明は、上記発明において、前記計数エリア内における長さが所定の長さ以上である前記移動軌跡は、前記計数エリア内に存在する時間が所定の時間以上であることを特徴とする。 Further, according to the present invention, in the above invention, the movement trajectory having a length of a predetermined length or more in the counting area is present in the counting area for a predetermined time or longer. .

また、本発明は、上記発明において、前記計数エリア内における長さが所定の長さ以上である前記移動軌跡は、前記計数エリア内に存在するフレーム数が所定のフレーム数以上であることを特徴とする。 Further, in the above invention, the moving trajectory whose length in the counting area is equal to or greater than a predetermined length has a number of frames existing in the counting area equal to or greater than a predetermined number of frames. and

また、本発明は、上記発明において、前記計数エリア内における長さが所定の長さ以上である前記移動軌跡は、前記計数エリア内における空間的な長さが所定の空間的な長さ以上であることを特徴とする。 Further, according to the present invention, in the above invention, the moving trajectory having a length in the counting area of a predetermined length or more has a spatial length in the counting area of a predetermined spatial length or more. characterized by being

また、本発明は、上記発明において、前記人物計数部は、前記軌跡検出部により検出した移動軌跡のうちの、前記計数エリア内における長さが所定の長さ以上であり、かつ移動方向が所定の方向である移動軌跡の本数に基づいて、前記計数エリアを通過した人物の人数を計数することを特徴とする。 Further, according to the present invention, in the above invention, the person counting unit has a moving trajectory detected by the trajectory detecting unit whose length in the counting area is equal to or greater than a predetermined length, and whose moving direction is a predetermined length. The number of persons who have passed through the counting area is counted based on the number of movement trajectories in the direction of .

また、本発明は、上記発明において、前記軌跡検出部は、前記計数エリア内において前記映像から人物ごとの移動軌跡を検出することを特徴とする。 Further, according to the present invention, in the above invention, the trajectory detection section detects a movement trajectory of each person from the video within the counting area.

また、本発明は、上記発明において、前記軌跡検出部は、前記所定エリア全体において前記映像から人物ごとの移動軌跡を検出することを特徴とする。 Further, according to the present invention, in the above invention, the trajectory detection section detects a movement trajectory of each person from the image in the entire predetermined area.

また、本発明は、上記発明において、前記人物計数部は、前記軌跡検出部により検出した移動軌跡のうちの、前記計数エリア内における平均移動量が所定値より小さい移動軌跡を除いた移動軌跡の本数に基づいて、前記計数エリアを通過した人物の人数を計数することを特徴とする。 Further, in the present invention, in the above invention, the person counting unit calculates the number of movement trajectories detected by the trajectory detection unit, excluding a movement trajectory having an average movement amount smaller than a predetermined value in the counting area. The number of persons who have passed through the counting area is counted based on the number of lines.

また、本発明は、上記発明において、前記計数エリアは、多角形であり、前記人物計数部は、前記軌跡検出部により検出した移動軌跡のうちの、前記計数エリアの一辺から進行して同じ辺に戻る移動軌跡を除いた移動軌跡の本数に基づいて、前記計数エリアを通過した人物の人数を計数することを特徴とする。 Further, according to the present invention, in the above-described invention, the counting area is a polygon, and the person counting section moves from one side of the counting area to the same side of the moving trajectory detected by the trajectory detecting section. The number of persons who have passed through the counting area is counted based on the number of movement trajectories excluding the movement trajectories returning to .

また、本発明は、上記発明において、前記人物計数部は、前記軌跡検出部により検出した移動軌跡のうちの、終点部分の移動方向が始点部分の移動方向と反対である移動軌跡を除いた移動軌跡の本数に基づいて、前記計数エリアを通過した人物の人数を計数することを特徴とする。 Further, in the present invention, in the above-described invention, the person counting unit includes a movement trajectory detected by the trajectory detection unit excluding a movement trajectory having an end point portion in a moving direction opposite to a starting point portion moving direction. The number of persons passing through the counting area is counted based on the number of tracks.

また、本発明は、上記発明において、前記軌跡検出部は、人物の中心軸上の部位、前記中心軸から左に外れた部位、及び前記中心軸から右に外れた部位のうちの、少なくとも2つの部位をそれぞれ追跡することによって人物ごとの移動軌跡を検出することを特徴とする。 Further, according to the present invention, in the above invention, the trajectory detection unit detects at least two of a part on the central axis of the person, a part off to the left from the central axis, and a part off to the right from the central axis. It is characterized by detecting the movement trajectory of each person by tracking each of the six parts.

また、本発明は、所定エリアを撮影した映像に基づいて、前記所定エリア内の計数エリアを通過した人物の人数を計数する人物計数方法であって、前記映像から人物ごとの移動軌跡を検出する軌跡検出ステップと、前記軌跡検出ステップにより検出した移動軌跡のうちの、前記計数エリア内における長さが所定の長さ以上である移動軌跡の本数に基づいて、前記計数エリアを通過した人物の人数を計数する人物計数ステップと、を含むことを特徴とする。 Further, the present invention is a person counting method for counting the number of persons who have passed through a counting area within a predetermined area based on an image of a predetermined area, wherein the movement trajectory of each person is detected from the image. a trajectory detection step; and the number of people who have passed through the counting area based on the number of trajectories detected by the trajectory detection step that have a length equal to or greater than a predetermined length in the counting area. and a person counting step of counting

また、本発明は、所定エリアを撮影した映像に基づいて、前記所定エリア内の計数エリアを通過した人物の人数を計数するための人物計数プログラムであって、前記映像から人物ごとの移動軌跡を検出する軌跡検出処理と、前記軌跡検出処理により検出した移動軌跡のうちの、前記計数エリア内における長さが所定の長さ以上である移動軌跡の本数に基づいて、前記計数エリアを通過した人物の人数を計数する人物計数処理と、をコンピュータに実行させることを特徴とする。 Further, the present invention is a person counting program for counting the number of persons who have passed through a counting area within a predetermined area based on an image of a predetermined area, wherein the moving trajectory of each person is calculated from the image. A person who has passed through the counting area based on the trajectory detection process to be detected and the number of trajectories among the trajectories detected by the trajectory detection process whose length in the counting area is equal to or greater than a predetermined length. and a person counting process for counting the number of people.

本発明の人物計数装置、人物計数方法及び人物計数プログラムによれば、混雑時であっても人数の計数漏れを低減でき、人数計数の精度を向上することができる。 According to the people counting device, the people counting method, and the people counting program of the present invention, it is possible to reduce omissions in counting the number of people even during congestion, and improve the accuracy of counting people.

映像に設定された計数エリアにおける人物の移動軌跡の検出状況を説明するための図である。FIG. 10 is a diagram for explaining how a person's movement trajectory is detected in a counting area set in an image; 検出された人物ごとの移動軌跡と、それらが計数エリア内で検出されたフレーム数とを説明するための図である。FIG. 4 is a diagram for explaining the detected movement trajectories of each person and the number of frames in which they are detected within the counting area; 実施形態1に係る人物計数装置を含むシステムの全体構成を説明するブロック図である。1 is a block diagram illustrating the overall configuration of a system including a people counting device according to Embodiment 1; FIG. 実施形態1に係る人物計数装置の構成を説明するブロック図である。1 is a block diagram illustrating the configuration of a person counting device according to Embodiment 1; FIG. 軌跡検出部によって追跡される体の部位を説明するための図である。FIG. 4 is a diagram for explaining body parts tracked by a trajectory detection unit; 移動軌跡が計数エリアのどの辺から出発して計数エリアのどの辺に到着したかを判定する方法を説明するための図である。FIG. 10 is a diagram for explaining a method of determining from which side of a counting area a moving trajectory starts and reaches which side of a counting area; 実施形態1に係る人物計数装置で行われる人数計数処理の手順の一例を示すフローチャートである。6 is a flow chart showing an example of a procedure of people counting processing performed by the people counting device according to the first embodiment; モニタに表示される計数結果表示画面の一例を示す模式図である。It is a schematic diagram which shows an example of the counting result display screen displayed on a monitor. モニタに表示される計数結果表示画面の別の例を示す模式図である。FIG. 11 is a schematic diagram showing another example of the counting result display screen displayed on the monitor; モニタに表示される計数結果表示画面の更に別の例を示す模式図である。FIG. 10 is a schematic diagram showing still another example of the counting result display screen displayed on the monitor; 検出された人物ごとの移動軌跡と、それらの計数エリア内での空間的な長さとを説明するための図である。FIG. 4 is a diagram for explaining the movement trajectory of each detected person and their spatial length within the counting area;

本明細書において、「計数エリア内における長さが所定の長さ以上である」との記載における長さとは、時間的な長さ(時間)、及び空間的な長さ(軌跡の長さ)の両方を包含するものとする。したがって、「計数エリア内における長さが所定の長さ以上である」とは、(1)計数エリア内における時間、すなわち計数エリア内に軌跡が存在する時間が所定の時間以上であることと、(2)計数エリア内における空間的な長さ(軌跡の長さ)が所定の空間的な長さ以上であることとの少なくとも一方を満たすことを言う。 In this specification, the length in the description that "the length in the counting area is a predetermined length or more" refers to the temporal length (time) and the spatial length (trajectory length) shall include both Therefore, "the length in the counting area is a predetermined length or longer" means (1) the time in the counting area, that is, the time for which the trajectory exists in the counting area is a predetermined time or longer; (2) It means that at least one of the following conditions is satisfied: that the spatial length (length of the trajectory) in the counting area is equal to or greater than a predetermined spatial length.

また、上記(1)の場合の時間とは、秒等の直接的に時の長さを表すもののみならず、映像(動画)のフレーム数(コマ数)等の間接的に時の長さを表すものも包含するものとする。 In addition, the time in the case of (1) above does not only directly represent the length of time such as seconds, but also indirectly represents the length of time such as the number of frames of video (video). shall also be included.

以下、本発明に係る人物計数装置、人物計数方法及び人物計数プログラムの好適な実施形態を、図面を参照しながら説明する。 BEST MODE FOR CARRYING OUT THE INVENTION Preferred embodiments of a person counting device, a person counting method, and a person counting program according to the present invention will be described below with reference to the drawings.

<本実施形態の概要>
まず、図1及び2を用いて、本実施形態の概要について説明する。本実施形態では、まず、図1に示すように、所定エリア(例えば、屋外の通路)を撮影した映像に、ある面積を持つ多角形(例えば四角形)の計数エリアを設定する。次に、計数エリアを通過する各人物を追跡して人物ごとの移動軌跡(以下、単に軌跡)を検出する。そして、計数エリア内における時間(計数エリア内に存在する時間)、ここでは計数エリア内に存在するフレーム数fが所定のフレーム数(以下、基準フレーム数)以上である軌跡の本数を数える。これにより、混雑時に人物の軌跡が途切れたとしても、その人物を計数することができる。すなわち、図2に示すように、特許文献1及び2に記載の方法とは異なり、本実施形態では、計数エリアと交差しない軌跡Aであっても、計数エリア内に存在するフレーム数fが基準フレーム数以上であれば、その人物を計数対象とすることができる。したがって、軌跡の途切れによる計数漏れの発生を低減することができる。
<Overview of this embodiment>
First, an overview of the present embodiment will be described with reference to FIGS. 1 and 2. FIG. In this embodiment, first, as shown in FIG. 1, a polygonal (for example, square) counting area having a certain area is set in an image of a predetermined area (for example, an outdoor passage). Next, each person passing through the counting area is tracked to detect the movement trajectory (hereinafter simply trajectory) of each person. Then, the time in the counting area (the time in the counting area), here, the number of trajectories where the number of frames f existing in the counting area is equal to or greater than a predetermined number of frames (hereinafter referred to as the reference number of frames) is counted. As a result, even if the trajectory of a person is interrupted during congestion, the person can be counted. That is, as shown in FIG. 2, unlike the methods described in Patent Documents 1 and 2, in the present embodiment, even if the trajectory A does not intersect the counting area, the number of frames f existing within the counting area is used as the reference. If the number of frames is greater than or equal to the number of frames, the person can be counted. Therefore, it is possible to reduce the occurrence of counting omissions due to discontinuities in the trajectory.

もちろん、計数エリアと交差する軌跡Bや軌跡Cであっても、計数エリア内に存在するフレーム数fが基準フレーム数以上であれば、その人物は計数対象になり得る。 Of course, even if the trajectory B or the trajectory C crosses the counting area, the person can be counted if the number of frames f present in the counting area is equal to or greater than the reference number of frames.

他方、フレーム数fが基準フレーム数未満である軌跡Dについては、その人物は計数対象から除外される。これは、自転車等の人物以外を人物として誤検出する等、短時間だけ誤検出した軌跡を計数対象から除外するためである。このような誤検出は、基準フレーム数をN(Nは2以上の整数)に設定し、(N-1)フレームしか検出されなかった軌跡を計数対象から除外することによって、効果的に排除することができる。 On the other hand, for the trajectory D whose frame number f is less than the reference frame number, the person is excluded from the counting target. This is to exclude trajectories that are erroneously detected for a short period of time, such as erroneously detecting a person other than a person, such as a bicycle, from the objects to be counted. Such erroneous detection is effectively eliminated by setting the number of reference frames to N (N is an integer equal to or greater than 2) and excluding trajectories for which only (N-1) frames have been detected. be able to.

以上より、本実施形態では、混雑時であっても人数の計数漏れを低減でき、人数計数の精度を向上させることができる。 As described above, in this embodiment, it is possible to reduce omissions in counting the number of people even during congestion, and to improve the accuracy of counting the number of people.

また、本実施形態では、図2に示したように、種々の方向に移動する軌跡が存在する場合に、それらの軌跡を所定の方向ごと(例えば、図2に示すように上方向と下方向の2方向)に分類するとともにカウントし、所定の方向ごとに人物を計数することができる。 Further, in this embodiment, as shown in FIG. 2, when there are trajectories moving in various directions, the trajectories are moved in predetermined directions (for example, upward and downward directions as shown in FIG. 2). (2 directions) and counting, and the number of persons can be counted for each predetermined direction.

また、本実施形態では、以下の場合を計数対象から除外することで、計数エリアを通過する人物の計数精度をより高精度なものとすることができる。 In addition, in the present embodiment, by excluding the following cases from the counting target, the counting accuracy of persons passing through the counting area can be increased.

1)軌跡の計数エリア内での平均移動量が所定値より小さい場合。
これにより、計数エリア内で長期間滞留している人物を計数対象から除外することができる。このように長期間滞留している人物を計数対象から除外しないと、その人物の手前を他の人物が通過する等した場合に追跡が途切れて複数の軌跡が検出され、同一人物に対して複数回計数してしまう可能性がある。
1) When the average amount of movement in the trajectory counting area is smaller than a predetermined value.
This makes it possible to exclude persons staying in the counting area for a long period of time from being counted. If a person staying for a long period of time is not excluded from counting, tracking will be interrupted and multiple trajectories will be detected when another person passes in front of the person. You may count the number of times.

2)軌跡がUターンした場合。
これにより、計数エリア内をUターンした人物を計数対象から除外することができる。したがって、計数エリアを通過する人物の計数精度の向上が可能である。
2) When the trajectory makes a U-turn.
As a result, a person who has made a U-turn within the counting area can be excluded from being counted. Therefore, it is possible to improve the counting accuracy of persons passing through the counting area.

以下、本実施形態についてより詳細に説明する。以下では、人物の追跡を計数エリア外で行わず、計数エリア内のみで行う場合について説明する。 The present embodiment will be described in more detail below. A case will be described below in which tracking of a person is not performed outside the counting area, but only within the counting area.

<人物計数装置を含むシステムの全体構成>
まず、図3を用いて、実施形態1に係る人物計数装置を含むシステムの全体構成について説明する。図3に示すように、このシステムは、屋内外の所定エリア(例えば屋外の通路)等を対象にして構築されるものであり、カメラ1と、レコーダ(画像記録装置)2と、人物計数装置3と、を備えている。
<Overall Configuration of System Including People Counting Device>
First, the overall configuration of the system including the people counting device according to the first embodiment will be described with reference to FIG. As shown in FIG. 3, this system is constructed for a predetermined indoor and outdoor area (for example, an outdoor passage), etc., and includes a camera 1, a recorder (image recording device) 2, and a person counting device. 3 and .

カメラ1は、屋内外の所望の場所に設置される。カメラ1により屋内外の所定エリアが撮影される。撮影された映像(各フレーム)は、レコーダ2に蓄積される。 The camera 1 is installed at a desired location indoors or outdoors. A predetermined indoor and outdoor area is photographed by the camera 1. - 特許庁The captured video (each frame) is accumulated in the recorder 2 .

人物計数装置3には、撮影した映像等を表示するモニタ(表示装置)4と、操作者が種々の入力操作を行う入力デバイス5(例えばマウス)とが接続されている。なお、モニタ4及び入力デバイス5は、タッチパネルディスプレイ等の入力機能付きの表示装置から構成されてもよい。 The people counting device 3 is connected to a monitor (display device) 4 for displaying captured images, etc., and an input device 5 (for example, a mouse) for an operator to perform various input operations. Note that the monitor 4 and the input device 5 may be composed of a display device with an input function such as a touch panel display.

人物計数装置3は、操作者が、モニタ4によって、カメラ1で撮像された映像をリアルタイムで閲覧できるように構成されるとともに、レコーダ2に録画された過去の映像を閲覧できるように構成されている。 The people counting device 3 is configured so that the operator can view the video captured by the camera 1 in real time on the monitor 4 and also can view the past video recorded on the recorder 2. there is

<人物計数装置の構成>
次に、図4を用いて、人物計数装置3の構成について説明する。人物計数装置3は、一般的なパーソナルコンピューター相当の機能を有する情報処理装置であり、図4に示すように、制御部10及び記憶部20を備えている。
<Configuration of person counting device>
Next, the configuration of the person counting device 3 will be described with reference to FIG. The people counting device 3 is an information processing device having functions equivalent to those of a general personal computer, and includes a control unit 10 and a storage unit 20 as shown in FIG.

制御部10は、映像入力部11、軌跡検出部12、計数エリア設定部13、人物計数部14、及び表示情報生成部15の機能を備えている。制御部10は、例えば、各種の処理を実現するためのソフトウェアプログラムと、該ソフトウェアプログラムを実行するCPU(Central Processing Unit)と、該CPUによって制御される各種ハードウェア等によって構成されている。制御部10の動作に必要なソフトウェアプログラムやデータは記憶部20に記憶される。 The control unit 10 has functions of an image input unit 11 , a trajectory detection unit 12 , a counting area setting unit 13 , a person counting unit 14 and a display information generation unit 15 . The control unit 10 includes, for example, software programs for realizing various types of processing, a CPU (Central Processing Unit) that executes the software programs, various types of hardware controlled by the CPU, and the like. Software programs and data necessary for the operation of the control unit 10 are stored in the storage unit 20 .

なお、制御部10の図4に示した各部は、制御部10のCPUで人数計数プログラムを実行させることによって実現される。人数計数プログラムは、人物計数装置3に予め導入されてもよいし、汎用OS上で動作可能なアプリケーションプログラムとして、コンピュータ読み取り可能な記録媒体に記録して、又は、ネットワークを介して、操作者に提供されてもよい。 4 of the control unit 10 are implemented by causing the CPU of the control unit 10 to execute a people counting program. The people counting program may be installed in the people counting device 3 in advance, or may be recorded in a computer-readable recording medium as an application program operable on a general-purpose OS, or sent to the operator via a network. may be provided.

記憶部20は、ハードディスク装置や不揮発性メモリ等の記憶装置から構成される。 The storage unit 20 is configured by a storage device such as a hard disk device or a nonvolatile memory.

映像入力部11は、カメラ1又はレコーダ2から映像を取得する処理を行う。人数計数をリアルタイムで行う場合にはカメラ1から映像を取得し、過去の映像から人数計数を行う場合にはレコーダ2から映像を取得する。 The image input unit 11 performs processing for acquiring images from the camera 1 or the recorder 2 . When the people are counted in real time, the images are obtained from the camera 1, and when the people are counted from past images, the images are obtained from the recorder 2. - 特許庁

軌跡検出部12は、カメラ1による映像から、計数エリア内において人物ごとの軌跡を検出する処理を行う。この軌跡検出処理は、公知の画像認識技術(人物検出技術及び人物追跡技術等)を利用することができる。 The trajectory detection unit 12 detects the trajectory of each person within the counting area from the image captured by the camera 1 . This trajectory detection process can use known image recognition technology (person detection technology, person tracking technology, etc.).

具体的には、例えば、軌跡検出部12は、まず、既存の人物検出技術を利用して、撮影された所定エリア全体において各人物の頭部、肩、肘、手、腰、膝、足等の部位を検出して姿勢を推定し、フレームごとに各人物の座標情報を生成する。座標情報には、検出した各部位の位置情報や、検出した人物が撮影された時刻等に関する情報が含まれる。なお、検出した人物の撮影時刻は、フレームの撮像時刻から取得可能である。 Specifically, for example, the trajectory detection unit 12 first uses an existing person detection technology to detect the head, shoulders, elbows, hands, waist, knees, legs, etc. of each person in the entire predetermined area photographed. The body part is detected to estimate the posture, and the coordinate information of each person is generated for each frame. The coordinate information includes position information of each detected part and information about the time when the detected person was photographed. Note that the photographing time of the detected person can be obtained from the photographing time of the frame.

続いて、生成した人物の座標情報を連続するフレーム間で照合し、基準を満たした座標情報をもつ人物の対応付けを行うことによって、計数エリア内において人物ごとの追跡を行う。対応付けは、例えば、その人物に共通のIDナンバーを付与することによって行う。このとき、軌跡検出部12は、他の人物に隠れる等して人物の追跡が途切れた場合でも、所定のフレーム数(例えばMフレーム、Mは2以上の整数)の間はその人物の追跡を継続する。例えば、追跡が途切れる前の座標情報を保持するとともに、その人物のその後の位置をフレーム毎に推定し、推定した位置近傍に基準を満たした座標情報をもつ人物が検出された場合は、その人物を追跡が途切れる前の人物と同一の人物であるとして対応付けを行う。また、本実施形態では、人物の追跡が途切れた場合、軌跡が計数エリア内に存在するフレーム数fは、追跡が途切れている間のフレームの数も加えてカウントされる。なお、上記Mフレームは、カメラ1の設定に応じて適宜変更可能である。 Subsequently, the generated coordinate information of the person is collated between consecutive frames, and the person having the coordinate information that satisfies the criteria is associated with each other, thereby tracking each person within the counting area. The association is made, for example, by assigning a common ID number to the person. At this time, the trajectory detection unit 12 keeps tracking the person for a predetermined number of frames (for example, M frames, where M is an integer equal to or greater than 2) even if tracking of the person is interrupted because the person is hidden by another person. continue. For example, while holding the coordinate information before the tracking is interrupted, the position of the person after that is estimated for each frame. is the same person as the person before the tracking was interrupted. In addition, in this embodiment, when tracking of a person is interrupted, the number f of frames in which the trajectory exists within the counting area is counted by adding the number of frames while tracking is interrupted. It should be noted that the above M frame can be changed as appropriate according to the settings of the camera 1 .

人物の追跡を行うとき、人物の中心軸上の部位、中心軸から左に外れた部位、及び中心軸から右に外れた部位のうちの、少なくとも2つの部位をそれぞれ追跡することが好ましい。これにより、2人の人物がすれ違った場合に対応付けの誤りが発生するのを抑制することができる。すれ違う人物では左右の部位が中心軸に対して反対に位置することから、同一人物ではないと判定することが可能であるためである。例えば、図5に示すように、人物の中心軸上の左右の肩の中心と、中心軸から左に外れた左肩及び左腰と、中心軸から右に外れた右肩及び右腰とをそれぞれ追跡する。そして、各部位のフレーム間での移動距離を算出し、算出した5つの部位の移動距離の平均を取り、その平均距離に基づいて人物の対応付けを行う。また、例えば、人物の中心軸上の部位と右肩とをそれぞれ追跡してもよいし、人物の中心軸上の部位と左肩とをそれぞれ追跡してもよい。なお、既存の人物検出技術であっても人物の左右の部位を区別して検出することが可能であることから、上述のように左右の部位を区別して容易に追跡することが可能である。 When tracking a person, it is preferable to track at least two parts of the person on the central axis, the part off the central axis to the left, and the part off the central axis to the right. As a result, it is possible to suppress the occurrence of an error in association when two persons pass each other. This is because it is possible to determine that the two persons are not the same person because the left and right parts of the two persons passing each other are positioned opposite to each other with respect to the central axis. For example, as shown in FIG. 5, the center of the left and right shoulders on the central axis of the person, the left shoulder and left hip off the central axis to the left, and the right shoulder and right hip off the central axis to the right, respectively. Chase. Then, the movement distance of each part between frames is calculated, the average of the calculated movement distances of the five parts is taken, and the person is associated based on the average distance. Also, for example, the part on the central axis of the person and the right shoulder may be tracked, or the part on the central axis of the person and the left shoulder may be tracked. It should be noted that, even with the existing person detection technology, it is possible to distinguish between the left and right parts of a person and detect them, so that the left and right parts can be distinguished and easily tracked as described above.

そして、軌跡検出部12は、対応付けられた人物の座標情報に基づいて、その人物の軌跡を生成する処理を行う。軌跡は、特定の部位(例えば頭部)を検出した特定点を連結することによって生成される。 Then, the trajectory detection unit 12 performs processing for generating the trajectory of the person based on the associated coordinate information of the person. A trajectory is generated by connecting specific points that detect specific parts (eg, the head).

軌跡検出部12で検出した人物ごとの軌跡に関する軌跡情報21は、軌跡検出部12によって記憶部20に記憶される。 Trajectory information 21 regarding the trajectory of each person detected by the trajectory detection unit 12 is stored in the storage unit 20 by the trajectory detection unit 12 .

計数エリア設定部13は、操作者の入力操作に応じて、ある面積を持つ多角形(例えば四角形)の計数エリアを設定する処理を行う。操作者は、マウス等の入力デバイス5を用いて、カメラ1又はレコーダ2から取得した映像が表示されたモニタ4の画面上にて計数エリアの位置を入力する。 The counting area setting unit 13 performs a process of setting a polygonal (for example, quadrangular) counting area having a certain area in accordance with an operator's input operation. The operator uses the input device 5 such as a mouse to input the position of the counting area on the screen of the monitor 4 on which the image obtained from the camera 1 or the recorder 2 is displayed.

人物計数部14は、軌跡検出部12で取得された軌跡情報21に含まれる人物ごとの軌跡の本数に基づいて、計数エリアを通過した人物を計数する処理を行う。本実施形態では、軌跡が計数エリア内で検出されたフレームの数(=フレーム数f)が基準フレーム数以上であると、計数エリアを通過したものと判断して、その人物を計数対象とする。 The person counting unit 14 counts the number of persons who have passed through the counting area based on the number of trajectories for each person included in the trajectory information 21 acquired by the trajectory detection unit 12 . In this embodiment, when the number of frames in which the trajectory is detected in the counting area (=frame number f) is greater than or equal to the reference number of frames, it is determined that the person has passed through the counting area, and the person is counted. .

また、人物計数部14は、図2に示したように、種々の方向に移動する複数の軌跡が存在する場合に、それらの軌跡を所定の方向ごと(例えば、上方向と下方向の2方向)に分類するとともに計数する。これにより、所定の方向ごとに人物を計数することができる。 In addition, as shown in FIG. 2, when there are a plurality of trajectories moving in various directions, the person counting unit 14 detects the trajectories in each predetermined direction (for example, in two directions, upward and downward). ) and counted. Thereby, the number of persons can be counted for each predetermined direction.

なお、軌跡を所定の方向のどの方向に分類するかは、軌跡の始点(起点)と終点の座標を比較することによって判定してもよい。例えば、図6に示すような場合、軌跡の始点のY座標が軌跡の終点のY座標より小さい場合は、上方向と判定し、反対に、軌跡の始点のY座標が軌跡の終点のY座標より小さくない場合は、下方向と判定してもよい。また、軌跡の始点と終点の左右方向の座標に差があれば左右方向も同時にカウントしてもよい。すなわち、軌跡の始点のX座標が軌跡の終点のX座標より小さい場合は、右方向と判定し、反対に、軌跡の始点のX座標が軌跡の終点のX座標より小さくない場合は、左方向と判定してもよい。 It should be noted that the direction in which the trajectory is to be classified may be determined by comparing the coordinates of the starting point (starting point) and the end point of the trajectory. For example, in the case shown in FIG. 6, if the Y coordinate of the start point of the locus is smaller than the Y coordinate of the end point of the locus, it is determined that the direction is upward. If it is not smaller, it may be determined to be downward. Also, if there is a difference in the horizontal coordinates of the start point and the end point of the trajectory, the left and right directions may be counted at the same time. That is, if the X coordinate of the start point of the locus is smaller than the X coordinate of the end point of the locus, it is determined to be in the rightward direction. can be determined.

また、人物計数部14は、軌跡が計数エリア内に滞留している場合、具体的には軌跡の計数エリア内での平均移動量が所定値より小さい場合は、その軌跡を計数対象から除外する。これにより、計数エリア内で長期間滞留している人物を計数対象から除外することができる。平均移動量は、例えば、所定数のフレーム(例えば1フレーム)当たりの平均移動量であってもよいし、所定時間(例えば1秒)当たりの平均移動量であってもよい。 In addition, when the trajectory remains within the counting area, specifically, when the average amount of movement of the trajectory within the counting area is smaller than a predetermined value, the person counting unit 14 excludes the trajectory from being counted. . This makes it possible to exclude persons staying in the counting area for a long period of time from being counted. The average amount of movement may be, for example, the average amount of movement per predetermined number of frames (for example, one frame), or the average amount of movement per predetermined time period (for example, one second).

更に、人物計数部14は、軌跡が計数エリア内をUターンした場合も、その軌跡を計数対象から除外する。これにより、計数エリア内をUターンした人物を計数対象から除外することができる。 Furthermore, when the trajectory makes a U-turn within the counting area, the person counting unit 14 also excludes that trajectory from being counted. As a result, a person who has made a U-turn within the counting area can be excluded from being counted.

より具体的には、人物計数部14では、軌跡が計数エリアのある辺から計数エリア内に進行して同じ辺に戻る場合、その軌跡を計数対象から除外する。 More specifically, the person counting unit 14 excludes the trajectory from counting when the trajectory progresses from a side of the counting area into the counting area and then returns to the same side.

なお、軌跡が計数エリアのどの辺から計数エリア内に進行するかは、図6に示すように、その軌跡を描く初めの所定数のフレーム(例えばPフレーム、ただし、Pは2以上の整数)を用いて平均の移動方向を計算し、軌跡の始点からその移動方向と反対方向に軌跡を延長して交差する辺を検出することによって判定される。同様に、軌跡が計数エリアのどの辺に戻る(進行する)かは、その軌跡を描く最後の所定数のフレーム(例えばQフレーム、ただし、QはPと同じ数)を用いて平均の移動方向を計算し、軌跡の終点からその移動方向に軌跡を延長して交差する辺を検出することによって判定される。 As shown in FIG. 6, from which side of the counting area the trajectory advances into the counting area is determined by the first predetermined number of frames (for example, P frames, where P is an integer of 2 or more) where the trajectory is drawn. is used to calculate the average direction of travel, and is determined by finding the edges that intersect by extending the trajectory from the start of the trajectory in the opposite direction to the direction of travel. Similarly, to which side of the counting area the trajectory returns (progresses) is determined by using the last predetermined number of frames (for example, Q frames, where Q is the same number as P) to draw the trajectory, and the average moving direction , and extending the trajectory from the endpoint of the trajectory in the direction of its movement and detecting the intersecting edges.

人物計数部14は、軌跡の終点部分の移動方向がその軌跡の始点部分の移動方向と反対である場合、その軌跡を計数対象から除外してもよい。これにより、計数エリアが、円や楕円等の多角形でない場合でも、計数エリア内をUターンした人物を計数対象から効果的に除外することができる。なお、軌跡の終点部分と始点部分の移動方向が反対であるか否かは、図6に示したように終点部分と始点部分の平均の移動方向を算出して、両方向のなす角を所定の角度範囲(例えば180°±20°の範囲)と比較し、所定の角度範囲内であれば反対であると判定され、所定の角度範囲内でなければ反対でないと判定される。 The person counting unit 14 may exclude the trajectory from being counted when the direction of movement of the end point of the trajectory is opposite to the direction of movement of the starting point of the trajectory. As a result, even if the counting area is not a polygon such as a circle or an ellipse, it is possible to effectively exclude a person who makes a U-turn within the counting area from being counted. It should be noted that whether or not the movement directions of the end point portion and the start point portion of the trajectory are opposite to each other can be determined by calculating the average movement direction of the end point portion and the start point portion as shown in FIG. Compared with an angle range (for example, a range of 180°±20°), if it is within the predetermined angle range, it is determined to be opposite, and if it is not within the predetermined angle range, it is determined to be non-opposite.

表示情報生成部15は、人物計数部14の計数結果に基づいて、計数エリアを通過した人物の人数を表す表示情報を生成する処理を行う。また、表示情報生成部15は、軌跡検出部12で検出された人物ごとの軌跡に関する軌跡情報21に基づいて、計数エリアを通行している人物の軌跡を表す表示情報を生成する処理を行う。生成された表示情報は、モニタ4に出力され、計数エリアを通過した人物の人数が所定の方向ごとにモニタ4に表示されるとともに、人物ごとの軌跡が表示される。 The display information generation unit 15 performs processing for generating display information representing the number of persons who have passed through the counting area based on the counting result of the person counting unit 14 . The display information generation unit 15 also performs processing for generating display information representing the trajectory of a person passing through the counting area based on the trajectory information 21 regarding the trajectory of each person detected by the trajectory detection unit 12 . The generated display information is output to the monitor 4, and the number of persons who have passed through the counting area is displayed in each predetermined direction on the monitor 4, and the trajectory of each person is displayed.

<人物計数処理の手順>
次に、図7を用いて、人物計数装置3で行われる人数計数処理の手順について説明する。
<Procedure for counting people>
Next, the procedure of the people counting process performed by the people counting device 3 will be described with reference to FIG.

図7に示すように、まず、映像入力部11に、カメラ1又はレコーダ2から映像(フレーム)が入力される(S11)。 As shown in FIG. 7, first, a video (frame) is input to the video input unit 11 from the camera 1 or the recorder 2 (S11).

次に、軌跡検出部12が、入力された映像から人物の軌跡を検出する(S12)。なお、映像から複数の人物が検出された場合には、軌跡検出部12による軌跡の検出処理と、以降の処理とを人物ごとに行う。 Next, the trajectory detection unit 12 detects the trajectory of the person from the input video (S12). Note that when a plurality of persons are detected from the video, the trajectory detection processing by the trajectory detection unit 12 and the subsequent processing are performed for each person.

次に、人物計数部14によって以下の処理が行われる。まず、検出された軌跡が計数エリア内に存在するフレーム数fが基準フレーム数以上であるか否かの判定が行われる(S13)。より具体的には、計数エリア内で軌跡が追跡されたフレーム数(追跡が一時的に途切れた場合のその間のフレーム数を含む)がNフレーム(Nは2以上の整数)以上であるか否かが判定され、計数エリア内で追跡されたフレーム数がNフレーム未満である場合には(S13でNo)、その軌跡を計数せずに人数計数処理を終了する(S14)。計数エリア内で追跡されたフレーム数がNフレーム以上であれば(S13でYes)、その軌跡が計数エリア内に滞留しているか否かの判定が行われる(S15)。軌跡が計数エリア内に滞留している場合には(S15でYes)、その軌跡を計数せずに人数計数処理を終了する(S14)。軌跡が計数エリア内に滞留していなければ(S15でNo)、その軌跡が計数エリア内をUターンしているか否かの判定が行われる(S16)。軌跡が計数エリア内をUターンしている場合には(S16でYes)、その軌跡を計数せずに人数計数処理を終了する(S14)。軌跡が計数エリア内をUターンしていなければ(S16でNo)、その軌跡の始点のY座標(その軌跡を検出した最初のフレームでのY座標)が軌跡の終点のY座標(その軌跡を検出した最終フレームでのY座標)より小さいか否かの判定が行われる(S17)。軌跡の始点のY座標軌跡が軌跡の終点のY座標より小さくなければ(S17でNo)、上方向のカウント値を1増分する処理が行われる(S18)。軌跡の始点のY座標軌跡が軌跡の終点のY座標より小さければ(S17でYes)、下方向のカウント値を1増分する処理が行われる(S19)。 Next, the person counting unit 14 performs the following processing. First, it is determined whether or not the number f of frames in which the detected trajectory exists within the counting area is greater than or equal to the reference number of frames (S13). More specifically, whether or not the number of frames in which the trajectory is tracked within the counting area (including the number of frames during which tracking is temporarily interrupted) is N frames (N is an integer of 2 or more) or more. If the number of frames tracked in the counting area is less than N frames (No in S13), the people counting process is terminated without counting the trajectory (S14). If the number of frames tracked within the counting area is N frames or more (Yes in S13), it is determined whether or not the trajectory remains within the counting area (S15). If the trajectory stays within the counting area (Yes in S15), the people counting process ends without counting the trajectory (S14). If the trajectory does not stay within the counting area (No in S15), it is determined whether or not the trajectory makes a U-turn within the counting area (S16). If the trajectory makes a U-turn within the counting area (Yes in S16), the people counting process is terminated without counting the trajectory (S14). If the trajectory does not make a U-turn within the counting area (No in S16), the Y coordinate of the starting point of the trajectory (the Y coordinate in the first frame in which the trajectory is detected) is the Y coordinate of the ending point of the trajectory (the trajectory is It is determined whether or not it is smaller than the detected Y coordinate in the final frame (S17). If the Y-coordinate locus of the starting point of the locus is not smaller than the Y-coordinate of the ending point of the locus (No in S17), processing is performed to increment the count value in the upward direction by one (S18). If the Y-coordinate locus of the starting point of the locus is smaller than the Y-coordinate of the ending point of the locus (Yes in S17), the downward count value is incremented by one (S19).

なお、図7に示した例では、所定の方向ごとに軌跡の本数を計数する処理を行ったが、この処理を軌跡の方向に関係なく行ってもよい。すなわち、軌跡が計数エリア内をUターンしていなければ(S16でNo)、すぐにカウント値を1増分する処理を行ってもよい。 In the example shown in FIG. 7, the number of trajectories is counted for each predetermined direction, but this processing may be performed regardless of the direction of the trajectory. That is, if the trajectory does not make a U-turn within the counting area (No in S16), the count value may be immediately incremented by one.

<人数計数結果の閲覧画面>
次に、図8~10を用いて人数計数結果を操作者が閲覧するための人数計数画面について説明する。
<Browsing screen for people counting results>
Next, the people counting screen for the operator to view the people counting results will be described with reference to FIGS.

本実施形態では、図8に示すように、表示情報生成部15において、人物計数部14での計数結果に基づいて、計数エリアを通過した人物の人数を表す表示情報を生成してモニタ4に出力し、モニタ4に、計数結果を操作者が閲覧するための計数結果表示画面が表示される。この計数結果表示画面には、映像表示部41と、計数結果表示部42と、が設けられている。 In this embodiment, as shown in FIG. 8, the display information generating unit 15 generates display information representing the number of persons who have passed through the counting area based on the counting result of the person counting unit 14, and displays the information on the monitor 4. A count result display screen is displayed on the monitor 4 for the operator to view the count result. A video display section 41 and a counting result display section 42 are provided on the counting result display screen.

映像表示部41には、カメラ1による映像とともに、計数エリア及び人物ごとの軌跡がオーバーレイ表示される。計数結果表示部42には、人数計数結果である計数エリアの通過人数が所定の方向(例えば、上方向と下方向)ごとにオーバーレイ表示される。 The video display unit 41 overlays the counting area and the trajectory of each person with the video from the camera 1 . The number of people passing through the counting area, which is the result of counting the number of people, is overlaid on the counting result display section 42 for each predetermined direction (for example, upward and downward directions).

図9は、計数エリアが四角形以外の多角形、具体的には5角形である場合を示す計数結果表示画面の例である。 FIG. 9 is an example of a counting result display screen showing a case where the counting area is a polygon other than a quadrangle, specifically a pentagon.

図10は、屋内の部屋の入室人数と退室人数を計数した結果を示す計数結果表示画面の例であり、計数結果表示部42には、入室人数(IN)及び退室人数(OUT)がそれぞれオーバーレイ表示される。 FIG. 10 is an example of a count result display screen showing the result of counting the number of people entering and leaving an indoor room. Is displayed.

この例では、頂点が6点ある6角形の計数エリアが設定されている。各頂点は、入力デバイス5であるマウスの操作(クリック及びドラッグ)により自在に移動可能であり、操作者は、容易に計数エリアを所望の位置に設定することができる。 In this example, a hexagonal counting area with six vertices is set. Each vertex can be freely moved by operating (clicking and dragging) the mouse, which is the input device 5, and the operator can easily set the counting area at a desired position.

また、計数エリアの中央には、入室(IN)の方向及び退室(OUT)の方向を示す両矢印が表示されている。この両矢印は、マウスの操作で回転可能であり、例えば、中心をクリックし、右にドラッグで右回転、左にドラッグで左回転する。これにより、操作者は、入室(IN)の方向及び退室(OUT)の方向に容易に設定することができる。 Also, in the center of the counting area, a double-headed arrow indicating the direction of entry (IN) and the direction of exit (OUT) is displayed. This double-headed arrow can be rotated by operating the mouse. For example, clicking the center and dragging it to the right rotates it to the right, and dragging it to the left rotates it to the left. Thereby, the operator can easily set the direction of entering (IN) and the direction of leaving (OUT).

以上説明したように、本実施形態では、計数エリア内における時間、詳細には計数エリア内に存在するフレーム数fが所定のフレーム数(基準フレーム数)以上である軌跡の本数に基づいて、計数エリアを通過した人物の人数を計数することから、混雑時に人物の軌跡が途切れたとしても、その人物を計数することができる。したがって、混雑時であっても人数の計数漏れを低減でき、人数計数の精度を向上させることができる。 As described above, in the present embodiment, the time in the counting area, more specifically, the number of trajectories for which the number of frames f existing in the counting area is equal to or greater than a predetermined number of frames (reference number of frames) is counted. Since the number of people who have passed through the area is counted, even if the trajectory of a person is interrupted during congestion, the person can be counted. Therefore, it is possible to reduce omissions in counting the number of people even during congestion, and improve the accuracy of counting the number of people.

なお、上記実施形態では、計数エリア内における時間的な長さ(時間)が所定の時間以上である軌跡の本数に基づいて、計数エリアを通過した人物の人数を計数する場合について説明したが、図11に示すように、計数エリア内での空間的な長さ(軌跡の長さ)Lが所定の空間的な長さ(以下、基準長さ)以上である軌跡の本数に基づいて、計数エリアを通過した人物の人数を計数してもよい。この場合も、混雑時に人物の軌跡が途切れたとしても、その人物を計数することができる。すなわち、図11に示すように、計数エリアと交差しない軌跡 aであっても、計数エリア内での長さLが基準長さ以上であれば、その人物を計数対象とすることができる。したがって、軌跡の途切れによる計数漏れの発生を低減することができる。 In the above-described embodiment, the number of people who have passed through the counting area is counted based on the number of trajectories whose temporal length (time) is equal to or greater than a predetermined time in the counting area. As shown in FIG. 11, based on the number of trajectories whose spatial length (trajectory length) L in the counting area is equal to or greater than a predetermined spatial length (hereinafter referred to as reference length), counting The number of persons passing through the area may be counted. In this case also, even if the trajectory of a person is interrupted during congestion, the person can be counted. That is, as shown in FIG. 11, even if the trajectory a does not intersect the counting area, if the length L within the counting area is equal to or greater than the reference length, the person can be counted. Therefore, it is possible to reduce the occurrence of counting omissions due to discontinuities in the trajectory.

もちろん、計数エリアと交差する軌跡bや軌跡cであっても、計数エリア内での長さLが基準長さ以上であれば、その人物は計数対象になり得る。他方、誤検出した軌跡を計数対象から除外する観点から、長さLが基準長さ未満である軌跡dについては、その人物は計数対象から除外される。 Of course, even if the trajectory b or trajectory c intersects the counting area, if the length L in the counting area is equal to or greater than the reference length, the person can be counted. On the other hand, from the viewpoint of excluding trajectories that are erroneously detected from being counted, for trajectories d whose length L is less than the reference length, the person is excluded from being counted.

また、計数エリア内に存在する時間が所定の時間以上であり、かつ計数エリア内での長さLが基準長さ以上である軌跡の本数に基づいて、計数エリアを通過した人物の人数を計数してもよい。 Also, the number of people who have passed through the counting area is counted based on the number of trajectories that exist in the counting area for a predetermined time or longer and whose length L in the counting area is a reference length or longer. You may

なお、計数エリア内での空間的な長さ(軌跡の長さ)は、例えば、計数エリア内の全ての特定点の座標(画素)から算出されてもよいし、計数エリア内で初めに検出された特定点、すなわち始点の座標(画素)と、計数エリア内で最後に検出された特定点、すなわち終点の座標(画素)とから算出されてもよい。 The spatial length (trajectory length) in the counting area may be calculated from the coordinates (pixels) of all specific points in the counting area, or may be first detected in the counting area. It may be calculated from the coordinates (pixels) of the detected specific point, that is, the start point, and the coordinates (pixels) of the last detected specific point, that is, the end point within the counting area.

また、上記実施形態では、人物の追跡を計数エリア外で行わず、計数エリア内のみで行う場合について主に説明したが、人物の追跡は、映像の全域、すなわち撮影した所定エリア全体において行ってもよく、所定エリア全体において人物ごとの軌跡を検出してもよい。 Further, in the above-described embodiment, the case where the tracking of a person is performed only within the counting area without being performed outside the counting area has been mainly described. Alternatively, the trajectory of each person may be detected in the entire predetermined area.

以上、図面を参照しながら本発明の実施形態を説明したが、本発明は、上記実施形態に限定されるものではない。また、各実施形態の構成は、本発明の要旨を逸脱しない範囲において適宜組み合わされてもよいし、変更されてもよい。 Although the embodiments of the present invention have been described above with reference to the drawings, the present invention is not limited to the above embodiments. Moreover, the configuration of each embodiment may be appropriately combined or changed without departing from the gist of the present invention.

以上のように、本発明は、所定エリアを撮影した映像に基づいて、所定エリア内の計数エリアを通過した人物の人数を計数するのに有用な技術である。 INDUSTRIAL APPLICABILITY As described above, the present invention is a technique useful for counting the number of persons who have passed through a counting area within a predetermined area based on a video image of the predetermined area.

1:カメラ
2:レコーダ
3:人物計数装置
4:モニタ
5:入力デバイス
10:制御部
11:映像入力部
12:軌跡検出部
13:計数エリア設定部
14:人物計数部
15:表示情報生成部
20:記憶部
21:軌跡情報
41:映像表示部
42:計数結果表示部
1: Camera 2: Recorder 3: People counting device 4: Monitor 5: Input device 10: Control unit 11: Video input unit 12: Trajectory detection unit 13: Counting area setting unit 14: People counting unit 15: Display information generation unit 20 : Storage unit 21: Trajectory information 41: Image display unit 42: Count result display unit

Claims (12)

所定エリアを撮影した映像に基づいて、前記所定エリア内の計数エリアを通過した人物の人数を計数する人物計数装置であって、
前記映像から人物ごとの座標情報を含む移動軌跡を、当該人物の特定の部位を検出した特定点を連結することで検出する軌跡検出部と、
前記計数エリア内の前記特定点の座標から前記移動軌跡の前記計数エリア内における空間的な長さを算出し、前記軌跡検出部により検出した移動軌跡のうちの、算出した前記計数エリア内における前記空間的な長さが所定の空間的な長さ以上である移動軌跡の本数を数え、数えた前記移動軌跡の本数に基づいて、前記計数エリアを通過した人物の人数を計数する人物計数部と、
を備えることを特徴とする人物計数装置。
A people counting device that counts the number of people who have passed through a counting area within a predetermined area based on an image of the predetermined area,
a trajectory detection unit that detects a movement trajectory including coordinate information for each person from the video by connecting specific points that detect specific parts of the person ;
calculating the spatial length of the movement trajectory within the counting area from the coordinates of the specific point within the counting area ; a person counting unit that counts the number of movement trajectories whose spatial length is equal to or greater than a predetermined spatial length, and counts the number of persons who have passed through the counting area based on the counted number of the movement trajectories; ,
A person counting device comprising:
前記計数エリア内における前記空間的な長さが所定の空間的な長さ以上である前記移動軌跡は、前記計数エリア内に存在する時間が所定の時間以上である
ことを特徴とする請求項1記載の人物計数装置。
2. The movement trajectory whose spatial length in said counting area is equal to or longer than a predetermined spatial length is present in said counting area for a time equal to or longer than a predetermined time. A person counting device as described.
前記計数エリア内における前記空間的な長さが所定の空間的な長さ以上である前記移動軌跡は、前記計数エリア内に存在するフレーム数が所定のフレーム数以上である
ことを特徴とする請求項1又は2記載の人物計数装置。
The moving trajectory having the spatial length within the counting area equal to or greater than a predetermined spatial length has a number of frames existing within the counting area equal to or greater than a predetermined number of frames. Item 3. The person counting device according to item 1 or 2.
前記人物計数部は、前記軌跡検出部により検出した移動軌跡のうちの、前記計数エリア内における前記空間的な長さが所定の空間的な長さ以上であり、かつ移動方向が所定の方向である移動軌跡の本数に基づいて、前記計数エリアを通過した人物の人数を計数する
ことを特徴とする請求項1~のいずれかに記載の人物計数装置。
The person counting unit determines that the spatial length in the counting area of the moving trajectory detected by the trajectory detecting unit is equal to or greater than a predetermined spatial length and the moving direction is a predetermined direction. 4. The person counting device according to any one of claims 1 to 3 , wherein the number of persons passing through said counting area is counted based on the number of movement trajectories.
前記軌跡検出部は、前記計数エリア内において前記映像から人物ごとの移動軌跡を検出する
ことを特徴とする請求項1~のいずれかに記載の人物計数装置。
5. The person counting device according to any one of claims 1 to 4 , wherein the trajectory detection unit detects a movement trajectory of each person from the video within the counting area.
前記軌跡検出部は、前記所定エリア全体において前記映像から人物ごとの移動軌跡を検出する
ことを特徴とする請求項1~のいずれかに記載の人物計数装置。
5. The person counting device according to any one of claims 1 to 4 , wherein the trajectory detection unit detects a movement trajectory of each person from the image in the entire predetermined area.
前記人物計数部は、前記軌跡検出部により検出した移動軌跡のうちの、前記計数エリア内における平均移動量が所定値より小さい移動軌跡を除いた移動軌跡の本数に基づいて、前記計数エリアを通過した人物の人数を計数する
ことを特徴とする請求項1~のいずれかに記載の人物計数装置。
The person counting unit passes through the counting area based on the number of trajectories detected by the trajectory detecting unit, excluding trajectories whose average amount of movement in the counting area is smaller than a predetermined value. 7. The person counting device according to any one of claims 1 to 6 , which counts the number of persons who have done so.
前記計数エリアは、多角形であり、
前記人物計数部は、前記軌跡検出部により検出した移動軌跡のうちの、前記計数エリアの一辺から進行して同じ辺に戻る移動軌跡を除いた移動軌跡の本数に基づいて、前記計数エリアを通過した人物の人数を計数する
ことを特徴とする請求項1~のいずれかに記載の人物計数装置。
the counting area is a polygon,
The person counting unit passes through the counting area based on the number of moving trajectories detected by the trajectory detecting unit, excluding moving trajectories that proceed from one side of the counting area and return to the same side. 8. The person counting device according to any one of claims 1 to 7 , which counts the number of persons who have done so.
前記人物計数部は、前記軌跡検出部により検出した移動軌跡のうちの、終点部分の移動方向が始点部分の移動方向と反対である移動軌跡を除いた移動軌跡の本数に基づいて、前記計数エリアを通過した人物の人数を計数する
ことを特徴とする請求項1~のいずれかに記載の人物計数装置。
The person counting section calculates the counting area based on the number of movement trajectories detected by the trajectory detection section, excluding a movement trajectory having an end portion whose movement direction is opposite to a movement direction of a start point portion. 9. The person counting device according to any one of claims 1 to 8 , which counts the number of persons who have passed through.
前記軌跡検出部は、人物の中心軸上の部位、前記中心軸から左に外れた部位、及び前記中心軸から右に外れた部位のうちの、少なくとも2つの部位をそれぞれ追跡し、各部位のフレーム間での移動距離を算出し、算出した複数の部位の移動距離の平均を取り、その平均距離に基づいて人物の対応付けを行い、対応付けられた人物の座標情報に基づいて、その人物の移動軌跡を、特定の部位を検出した特定点を連結することによって生成する
ことを特徴とする請求項1~のいずれかに記載の人物計数装置。
The trajectory detection unit tracks at least two parts of a part on the central axis of the person, a part off to the left from the central axis, and a part off to the right from the central axis. Calculate the movement distance between frames, take the average of the calculated movement distances of a plurality of parts, associate the person based on the average distance, and based on the coordinate information of the associated person, 10. The person counting device according to any one of claims 1 to 9, wherein the movement trajectory of is generated by connecting specific points from which specific parts are detected .
所定エリアを撮影した映像に基づいて、前記所定エリア内の計数エリアを通過した人物の人数を計数する人物計数方法であって、
前記映像から人物ごとの座標情報を含む移動軌跡を、当該人物の特定の部位を検出した特定点を連結することで検出する軌跡検出ステップと、
前記計数エリア内の前記特定点の座標から前記移動軌跡の前記計数エリア内における空間的な長さを算出し、前記軌跡検出ステップにより検出した移動軌跡のうちの、算出した前記計数エリア内における前記空間的な長さが所定の空間的な長さ以上である移動軌跡の本数を数え、数えた前記移動軌跡の本数に基づいて、前記計数エリアを通過した人物の人数を計数する人物計数ステップと、
を含むことを特徴とする人物計数方法。
A person counting method for counting the number of persons who have passed through a counting area within a predetermined area based on a video image of the predetermined area,
a trajectory detection step of detecting a movement trajectory including coordinate information for each person from the video by connecting specific points from which specific parts of the person are detected ;
calculating the spatial length of the movement trajectory within the counting area from the coordinates of the specific point within the counting area ; a person counting step of counting the number of movement trajectories having a spatial length equal to or greater than a predetermined spatial length, and counting the number of persons who have passed through the counting area based on the counted number of the movement trajectories; ,
A person counting method, comprising:
所定エリアを撮影した映像に基づいて、前記所定エリア内の計数エリアを通過した人物の人数を計数するための人物計数プログラムであって、
前記映像から人物ごとの座標情報を含む移動軌跡を、当該人物の特定の部位を検出した特定点を連結することで検出する軌跡検出処理と、
前記計数エリア内の前記特定点の座標から前記移動軌跡の前記計数エリア内における空間的な長さを算出し、前記軌跡検出処理により検出した移動軌跡のうちの、算出した前記計数エリア内における前記空間的な長さが所定の空間的な長さ以上である移動軌跡の本数を数え、数えた前記移動軌跡の本数に基づいて、前記計数エリアを通過した人物の人数を計数する人物計数処理と、
をコンピュータに実行させることを特徴とする人物計数プログラム。
A person counting program for counting the number of persons who have passed through a counting area within a predetermined area based on a video image of the predetermined area,
A trajectory detection process for detecting a movement trajectory containing coordinate information for each person from the video by connecting specific points from which specific parts of the person are detected ;
calculating the spatial length of the movement trajectory within the counting area from the coordinates of the specific point within the counting area ; a person counting process for counting the number of movement trajectories having a spatial length equal to or greater than a predetermined spatial length, and counting the number of persons who have passed through the counting area based on the counted number of the movement trajectories; ,
A person counting program characterized by causing a computer to execute
JP2019037871A 2019-03-01 2019-03-01 Person counting device, person counting method and person counting program Active JP7256032B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2019037871A JP7256032B2 (en) 2019-03-01 2019-03-01 Person counting device, person counting method and person counting program

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2019037871A JP7256032B2 (en) 2019-03-01 2019-03-01 Person counting device, person counting method and person counting program

Publications (2)

Publication Number Publication Date
JP2020140660A JP2020140660A (en) 2020-09-03
JP7256032B2 true JP7256032B2 (en) 2023-04-11

Family

ID=72264984

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2019037871A Active JP7256032B2 (en) 2019-03-01 2019-03-01 Person counting device, person counting method and person counting program

Country Status (1)

Country Link
JP (1) JP7256032B2 (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP7486685B1 (en) 2023-03-03 2024-05-17 三菱電機株式会社 Target tracking device and target tracking method

Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2011039792A (en) 2009-08-11 2011-02-24 Hitachi Kokusai Electric Inc Counter for the number of persons

Patent Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2011039792A (en) 2009-08-11 2011-02-24 Hitachi Kokusai Electric Inc Counter for the number of persons

Also Published As

Publication number Publication date
JP2020140660A (en) 2020-09-03

Similar Documents

Publication Publication Date Title
JP6273685B2 (en) Tracking processing apparatus, tracking processing system including the tracking processing apparatus, and tracking processing method
JP6525453B2 (en) Object position estimation system and program thereof
US10893207B2 (en) Object tracking apparatus, object tracking method, and non-transitory computer-readable storage medium for storing program
JP6918523B2 (en) A program that causes a computer to execute an information processing system, an information processing device, an information processing method, and an information processing method.
JP6159179B2 (en) Image processing apparatus and image processing method
US7457439B1 (en) System and method for motion capture
JP7359621B2 (en) Area setting support device, area setting support method, and area setting support program
US20190294890A1 (en) Method and apparatus for surveillance
WO2021036373A1 (en) Target tracking method and device, and computer readable storage medium
JP6590609B2 (en) Image analysis apparatus and image analysis method
JP5853141B2 (en) People counting device, people counting system, and people counting method
JP6771996B2 (en) Systems and methods for real-time interactive operation of the user interface
JP2007280043A (en) Video monitoring and search system
JP4288428B2 (en) Video analysis system and video analysis method
JP2001094975A (en) Mobile object tracing method and device
JP7256032B2 (en) Person counting device, person counting method and person counting program
WO2022078134A1 (en) People traffic analysis method and system, electronic device, and readable storage medium
US11363241B2 (en) Surveillance apparatus, surveillance method, and storage medium
US20130265420A1 (en) Video processing apparatus, video processing method, and recording medium
JP2020201674A (en) Video analyzer and control method therefor and program
JP6679349B2 (en) Information processing apparatus, information processing method, and program
WO2024111474A1 (en) Counting device, counting system, counting method, and program
US20230126755A1 (en) Information processing apparatus, information processing method, and imaging system
JP6630322B2 (en) Video analysis method
JP2024010264A (en) Information processing system, information processing device, information processing method, article manufacturing method, program, and recording medium

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20211021

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20221025

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20221101

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20221227

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

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20230330

R150 Certificate of patent or registration of utility model

Ref document number: 7256032

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150