
# 基于快速信息融合方法的多视角人数统计

米卡埃尔·A·穆斯 $^{1,2}$ · 西纳·莫塔梅德 $^{1}$ · 欧仁·C·埃赞 $^{2}$

收稿日期：2015年7月24日 / 修回日期：2015年12月15日 / 录用日期：2016年2月9日

© 2016 纽约施普林格科学+商业媒体有限公司

## 摘要

人群规模的实时估计是民用监控中的核心任务。本文提出了一种利用重叠相机对人群场景进行人数统计的新型系统。该系统融合所有单视角前景信息，对场景中的每个人进行定位。我们融合策略的目的是利用每个单视角的前景像素，改进相机网络中各相机之间的实时目标关联效果。前景像素通过基于码本的算法获得。本研究中，我们对相机网络得到的轮廓进行聚合，计算每个相机的视觉外壳到地平面的平面单应性投影。视觉外壳通过提取前景像素的凸包得到。投影到地平面后，我们利用场景的几何特性和各相机检测结果的质量对得到的多边形进行融合。我们还提出了一种基于区域的跟踪策略，能够随时间跟踪人员运动和身份，还可容忍偶尔的误检测。该跟踪策略基于视角融合结果实现，能够逐帧估计人群规模。使用面向人数统计系统评估的公开数据集开展的实验验证了本文融合方法的性能。结果表明，该融合策略可实时运行，在数据关联任务上十分高效。我们

---

还证明了本文的融合方法与所提出的跟踪方法相结合，能够提升人数统计的效果。

关键词 视频监控 · 人数统计 · 单应性 · 数据关联 · 跟踪 · 重叠相机

## 1 引言

人群人数统计是视频监控领域至关重要且极具挑战性的问题。对各类环境进行监控存在广泛需求，可实现多种目标，例如安全保障、资源管理、城市规划或广告投放等。准确估计人群中的人数是反映人群安全状况的关键指标，是极具价值的信息。在人群中，要清晰观测每个个体以检测潜在异常也十分重要。由于存在大量遮挡，人群人数统计难度很高。过去二十年间，研究者已经提出了多种人数统计方法。

### 1.1 相关工作

大多数关于人数统计的文献都采用单视角方法，这是因为单台监控摄像头应用广泛，且实现相对容易 [^5] [^6] [^16] [^34] [^37] [^42]。即使有强有力的先验假设且不受计算能力限制，通常也很难通过单个普通摄像头的视角对人群中的人数进行高效统计。为了克服这一缺陷，多项研究工作 [^1] [^8] [^12] [^24] 提出使用垂直向下拍摄的摄像头，这类摄像头固定安装在天花板上。但这类方案的应用大多仅限于室内环境。已有研究也考虑了立体摄像头，以利用深度信息将移动人员投影到地平面，生成占用图并减少遮挡 [^2] [^15] [^33] [^36] [^40]。部分研究工作提出使用多摄像头系统，多摄像头的应用对拥挤环境下的人员定位和人数统计至关重要 [^13] [^22] [^26] [^29] [^30]。在计算机视觉领域，多摄像头的应用范围十分广泛，其应用动机多种多样，涉及多个领域，例如重要保护场所的监测与安防、流量的管控与预估（停车场、机场、港口和高速公路）。随着数据处理、通信和仪器设备的快速发展，这类应用得以实现。这类系统需要更多摄像头来覆盖整个视场，减少物体动态遮挡的影响。对同一场景使用多个视角（多视图）能够恢复单个特定视角中可能被遮挡的信息。人数统计系统可分为两类：以个体为中心的方法，基于对轨迹的检测、跟踪和计数；以及以人群为中心的方法，基于分析从人群图像中提取的全局低层级特征来得到准确的计数结果 [^4]。本文研究以个体为中心的方法，因为这类方法不需要针对场景中的人员进行专门学习就能得到人员位置，且计数仅基于人员检测完成。传统的计数流程首先需要定位所有独立个体，这是因为在拥挤场景下，人数估计依赖于对个体的检测才能完成计数。但定位所有目标是一项颇具挑战性的任务，因为目标往往外观相似或相互遮挡，导致数据关联难度很大。

---

根据Xu等人的研究 [^39]，针对多视角目标定位，现有的多摄像头监控算法可分为三类。

第一类方法的系统融合低层级信息。在这类方法中，多摄像头监控系统仅在单个摄像头视角下进行检测和/或跟踪，当系统预测当前摄像头无法获得良好的场景视野时，就切换到另一台摄像头 [^3] [^18]。这类方法存在缺陷，因为前景信息是从单个摄像头视角中提取的。

第二类方法中，系统会在每个独立摄像头中提取特征，甚至跟踪目标。在此之后，我们整合所有特征与轨迹以获得全局估计。这类系统属于中间层信息融合[^17] [^21] [^38]。这类方法仍存在缺陷，因为特征都是从单个摄像头视角提取得到的。

第三类方法的系统融合高层信息。在这类系统中，单个摄像头不提取特征，仅向融合中心提供前景位图信息，检测和/或跟踪由融合中心完成[^9] [^19] [^20] [^39] [^41]。

本文聚焦于第三类方法，因为这类算法对动态目标遮挡具有较强的鲁棒性。该类别下已经提出了多种算法。Khan和Shah提出利用平面单应占空约束融合不同视角的前景似然图像[^19]。该方法解决了遮挡问题，能够确定地平面上被行人占据的区域。他们还将地平面扩展到一组与之平行、但偏离地平面一定高度的平面，以此减少误检和漏检[^20]。Eshel和Moses将每个独立摄像头得到的前景强度位图投影到参考图像上[^9]。场景平面被设置在行人头部的高度，通过应用强度相关对齐不同摄像头的帧来检测头顶，该方法能够处理高度拥挤的场景。Yang等人通过寻找多摄像头二值前景图像的视觉壳来检测目标[^41]。这类方法利用多摄像头提供的视觉线索，在处理遮挡时鲁棒性较好。但图像层面的逐像素单应变换会拖慢处理速度。为了克服这一缺点，Xu等人提出了一种通过对多摄像头前景多边形进行单应映射实现目标检测的方法[^39]。他们用多边形近似每个前景区域的轮廓，仅传输和投影多边形的顶点；前景区域通过高斯混合模型检测，之后多边形在参考图像中重建并融合。他们证明该方法比现有最优融合算法快40倍。

本文提出的人数统计系统，为了解决单视角检测到的前景目标之间的数据关联问题，提出了一种基于降低多边形融合复杂度的目标定位新策略。每个摄像头视角的前景像素通过码本模型检测，这些像素被分组为多边形。针对场景中的每个行人，我们的策略是检测出对该行人最具代表性的多边形。在每个摄像头视角中，通过提取前景区域的凸包得到前景多边形。最优多边形的选择结合了场景的几何特性和每个单视角检测的质量。我们还提出了一种多视角跟踪策略，逐帧估计人群规模。每一帧的人数可以通过对融合和估计得到的多边形进行计数得到。

---

结合跟踪策略的方法可以得到曾在场景中停留过的不同行人的数量。

本文组织结构如下：第2节介绍本文提出的人数统计方法，第3节展示了在不同数据集上开展的实验与性能评估，第4节给出结论与未来工作方向。

## 2 人数统计方法

在本节中，我们介绍本文提出的基于多摄像头的人数统计方法。该方法分为四个模块：

单前景像素检测：该模块识别每个摄像头视角下的前景像素。本文采用基于码本模型的运动检测算法；

- 前景信息融合：该模块融合第一个模块得到的所有前景像素，获取场景的全局信息；

- 跟踪：该模块用于辅助人数统计，随时间持续跟踪人员的运动与身份信息；

计数：该模块的作用是统计人数。

### 2.1 基于码本模型的运动检测

单个场景视角下的前景检测是本文提出的人数统计系统的基础构建模块，其精度对整个流程至关重要。因此，本文采用Kim等人提出的面向视频序列的码本背景模型[^25]，该模型针对运动目标检测常见挑战的高精度和鲁棒性早已得到验证。我们过往的研究工作[^32]也证实了这些结论，在该研究中，我们在多个场景更具挑战性的新序列上测试了该算法。该方法可实时检测动态背景中的目标，图1为基于码本的算法流程图。

在该方法中，每个像素$p_t$由一个码本$\mathcal{C} = \{c_1, c_2, ..., c_L\}$表示，每个码字$c_i$、$i = 1, ..., L$由一个RGB向量$v_i$和一个六元组$aux_i = \{I_i, \tilde{I}_i, f_i, p_i, \lambda_i, q_i\}$表示，其中$\tilde{I}$和$\tilde{f}$分别是分配给该码字$c_i$的所有像素的最小亮度和最大亮度，$f_i$是该码字的出现频率，$\lambda_i$是最大负游程长度，定义为训练阶段该码字未再次出现的最长间隔，$p_i$和$q_i$分别是该码字第一次和最后一次出现的访问时间。码本模型通过两个准则进行构建与更新：第一个准则基于颜色失真（1），第二个准则基于亮度失真（2）。

 $$ \sqrt{||p_{t}||^{2}-C_{p}^{2}}<=\varepsilon_{1} $$

 $$ I_{low}\leq I\leq I_{hi} $$

在式（1）中，自相关值 $C_p^2$ 由式（3）给出， $\|p_t\|^2$ 由式（4）给出。

 $$ C_{p}^{2}=\frac{(R_{i}R+G_{i}G+B_{i}B)^{2}}{R_{i}^{2}+G_{i}^{2}+B_{i}^{2}} $$

---

![Image](images/dd224a9f2a70f304eb333d102d14bd611b1639c97e2197846a10893a8c145af6.jpg)

<div style="text-align: center;">Fig. 1 Flow diagram of the Codebook based algorithm. (the solid lines correspond to the learning phase; dashed lines correspond to the phase of moving objects detection)</div>

 $$ ||p_{t}||^{2}=R^{2}+G^{2}+B^{2} $$

在式（2）中，$I_{low} = \alpha \hat{I}_i$、$I_{hi} = min\left\{\beta \hat{I}, \frac{\check{\iota}}{\alpha}\right\}$和$I = \sqrt{R^2 + G^2 + B^2}$。

训练阶段结束后，如果输入像素与码本中的某个码字匹配，则该码字会被更新，该像素会被判定为背景像素；如果像素不匹配，则其信息会被存入缓存码字，该像素会被判定为前景像素。

### 2.2 融合策略

在本节中，我们介绍多摄像头系统中移动人数统计的融合方法。Kuncheva等人区分了两种信息融合方法：决策融合和源选择 [^28]。在他们的定义中，决策融合指融合来自多个源的信息以达成共识 [^7] [^27]，而源选择指从多个源中动态选择最优源 [^14] [^23]。本文的方法基于源选择，我们的融合方法的核心思路是找到对场景中每个存在人员的定位拥有最佳视角的摄像头。

检测到每个视角中的前景像素后，需要将这些像素分组为前景区域。每个区域都可以用多边形近似，该多边形通过提取阈值图像中所有检测轮廓的凸包得到。凸包（又称凸包络）的定义是：欧氏平面或欧氏空间中点集X的凸包是包含X的最小凸集。例如，当X是平面中的有界子集时，凸包可以直观理解为橡皮筋环绕X后围成的形状。为了求取凸包，我们首先在X中找出一个肯定属于最小凸包的点：我们选择x坐标最小的点（即X中最靠左的点）。我们创建列表P，在其中存储各点的编号（即它们在X数组中的位置）。之后，我们对其余点按照相对于起始 [^0] 点的左侧位置进行升序排序（P$R = XP[0]$除外）。我们约定，如果点C位于向量RB的左侧，则满足 $B < C$。随后我们应用基于成对比较的排序算法

---

![Image](images/e60ca8cee3da62839c6b83b9b3a7eaa1a51364cf86eac126e70dd1db9de2c06d.jpg)

![Image](images/510b6637658812f4019274ef409ed6d67262b37d1bae462904d79a879809e9fa.jpg)

<div style="text-align: center;">(a)</div>

![Image](images/6ba4b30142e779e15efc0162fc5fa68fa088d005c987b3a0735e4cc0648be5e9.jpg)

<div style="text-align: center;">(b)</div>

![Image](images/7796201f84f1154982ac3d440ddde4fb7cfa680805b7e9cbd73062ee5453397e.jpg)

<div style="text-align: center;">(c)</div>

![Image](images/1eba77719fbf151c9c863468a24c17cb3b02558637eefd818ba712808ce0e7e0.jpg)

<div style="text-align: center;">(d)</div>

![Image](images/dff74dc1a8b70f77bd6f3269a68214450082383ddb5c150ef2f123f1b2d804db.jpg)

<div style="text-align: center;">(e)</div>

![Image](images/6dc8125e41fbd5561eaa83ff4fa0a400fca4534f4e28e8b92551c5282002f9e2.jpg)

<div style="text-align: center;">(f)</div>

<div style="text-align: center;">(g)</div>

![Image](images/6e8d7f47374d8a3bb33927cc323082b2dfa9b55cb40af02a28520f9da702143c.jpg)

<div style="text-align: center;">(h)</div>

![Image](images/d171ea59f7a9c51b76b349d23c5e16eebbb9aa497a1a4436756822b4ec5d4fdf.jpg)

<div style="text-align: center;">(i)</div>

![Image](images/663bbde19ab31de3c11b4da2156182d4c39dd8fe577c69a5bf34ae9930601f8d.jpg)

<div style="text-align: center;">(i)</div>

![Image](images/a25599eca1d34f0bb03ba94a3080ef1fa18e1e7c1664a8a2b9fdbf81de100a4c.jpg)

<div style="text-align: center;">(k)</div>

![Image](images/9a87de12c0b88e025c380dadbc6d8c2cb0b8f57f32c7e67cc5b5f49e9ee59f62.jpg)

<div style="text-align: center;">(1)</div>

![Image](images/3c2fa3bcff43f44a827e763ef692d2218fd019264066e57dd2b21bd5593bdd94.jpg)

<div style="text-align: center;">(m)</div>

![Image](images/83735960212378ae10666acd22cc5f93e1a2927d812f65c1849378d9bfb065b1.jpg)

<div style="text-align: center;">(n)</div>

![Image](images/faa063f256f6d6b336e9e0f505c87059f1a225443e382c6fdd03af39f6b61289.jpg)

<div style="text-align: center;">(0)</div>

![Image](images/1f3d4abb0ee746fe85a35e7eac68454339a0fe565069855a302e1eaa6bd35c41.jpg)

<div style="text-align: center;">(p)</div>

<div style="text-align: center;">Fig. 2 Example of detection of the convex hull of a set of points</div>

对这些元素排序。这一步我们得到了多边形的起始点，以及多边形顶点排列的潜在顺序（参见图2的子图(a)：起始点标记为红色，潜在顺序为0, 1, 2, ..., n-1）。最后一步是剪角处理。为此，我们创建列表S，并将前两个顶点放入其中（S=[P[^0], P[^1]]）。随后遍历其余所有顶点，我们持续追踪最近的三个点，计算它们形成的角度。如果这三个点的方向不是逆时针，我们就通过移除S中的最后一个顶点来剪去这个角。一旦方向为顺时针，就无需再剪角，因此我们将当前顶点加入S。这最后一步由图2的子图(b)、(c)、…、(p)展示。所有区域都可以被多边形近似，且每个多边形都是凸多边形。图3给出了移动目标检测算法与多边形近似策略的部分实现结果。多边形近似减少了后续需要

---

![Image](images/23398538647c2f82d37079fbcecad97fbd29dbdce45abdd2eece310d1f4e79fa.jpg)

<div style="text-align: center;">Fig. 3 These results are obtained by using sequence from PETS 2010 dataset. The first row shows the original images. The second row shows the foreground pixels obtained by using Codebook based algorithm. The third row shows the foreground regions and the last row shows the detected polygons. Black points on polygon represent the vertices of the polygon.</div>

处理的数据量。这种近似还允许我们将所有孔洞或不连续斑块都算作前景像素，因为所有属于多边形的像素都会被判定为前景像素。为了在信息融合模块中使用多边形顶点，我们为每个多边形分配了唯一标识符id。检测到各个前景区域后，我们需要融合这些区域以得到多视角信息。我们通过将多边形每个顶点投影到地平面，得到整个多边形在地平面的投影，投影过程使用平面单应映射完成。

单应性通常通过在一对图像中寻找特征对应关系来估计。最常用的特征是不同图像中的对应点，不过也可使用单个图像中的直线、二次曲线等其他特征。这些特征从二维图像中手动或自动选择匹配，用于计算两个相机视角之间的单应性，或是一个相机视角与顶视图之间的单应性。因此，必须对平台进行校准以

---

得到投影矩阵。单应变换是射影变换的一种特殊变体。我们设无畸变图像中的点为$x = (x_s, y_s, 1)$，三维世界中的点为$X = (X_w, Y_w, Z_w, 1)$。从X到x的投影变换由式(5)给出。

 $$ \left[\begin{array}{c}{x_{s}}\\ {y_{s}}\\ {1}\end{array}\right]=\left[\begin{array}{c c c c}{f/s_{x}}&{s}&{C_{x}}&{0}\\ {0}&{f/s_{y}}&{C_{y}}&{0}\\ {0}&{0}&{1}&{0}\end{array}\right]\left[\begin{array}{c c c c}{r_{11}}&{r_{12}}&{r_{13}}&{t_{x}}\\ {r_{21}}&{r_{22}}&{r_{23}}&{t_{y}}\\ {r_{31}}&{r_{32}}&{r_{33}}&{t_{z}}\\ {0}&{0}&{0}&{1}\end{array}\right]\left[\begin{array}{c}{X_{w}}\\ {Y_{w}}\\ {0}\\ {1}\end{array}\right] $$

如果X限定在地平面上，因此$Z_{w}$将等于0，从X到x的投影变换变为：

 $$ \left[\begin{array}{c}x_{s}\\ y_{s}\\ 1\end{array}\right]=\left[\begin{array}{c c c}f/s_{x}&s&C_{x}\\ 0&f/s_{y}&C_{y}\\ 0&0&1\end{array}\right]\left[\begin{array}{c}r_{11}r_{12}r_{13}t_{x}\\ r_{21}r_{22}r_{23}t_{y}\\ r_{31}r_{32}r_{33}t_{z}\end{array}\right]\left[\begin{array}{c}X_{w}\\ Y_{w}\\ 1\end{array}\right] $$

 $$ \begin{aligned}\left[\begin{array}{c}x_{s}\\y_{s}\\1\end{array}\right]=\left[\begin{array}{ccc}h_{11}&h_{12}&h_{13}\\h_{21}&h_{22}&h_{23}\\h_{31}&h_{32}&h_{33}\end{array}\right]\left[\begin{array}{c}X_{w}\\Y_{w}\\1\end{array}\right]\end{aligned} $$

平面单应映射的目标是找到$3 \times 3$矩阵，该矩阵将两个不同视角下地平面上的点$pt(x, y)$对应到另一个点$pt'(x', y')$。对于非平面场景，需要引入并整合一个空间模型。该空间模型应包含对场景中不符合平面假设的平面子区域的检测。由于每个子区域本身是平面，我们可以对每个子区域分别计算单应性。随后结合空间模型对图像进行合并（图4）。

投影完成后，我们提出了一种多边形融合策略。我们的融合方法基于场景的几何特性和每个相机检测结果的质量。如图5所示，假设有一个场景被多个视角重叠的相机观测，在本示例中场景由两个相机观测。每个相机对场景的观测结果不同，因此需要对场景进行映射来明确每个相机的视场范围。该信息对实现高效融合非常重要，因为它可以标明场景中每个点被多少个相机覆盖。利用每个单一视角得到的投影多边形，针对双视角场景，我们归纳出三种情况：

c1：第一个视角的多边形与第二个视角的任何多边形都不匹配。如果该多边形出现在仅被一个相机覆盖的区域，我们认为该相机拥有对目标的最佳观测。如果该多边形出现在被两个相机共同覆盖的区域，则认为该多边形是误检结果，我们会舍弃这个投影多边形。这种情况可以帮助我们减少每个阈值化视角中因存在假阳性像素导致的计数错误。

c2：第一个视角的多边形仅与第二个视角的一个多边形匹配。为选出最佳观测视角，我们优先选择检测到与行人关联的投影多边形（投影到地平面上）最低点的相机。对于每个多边形，最低点就是最靠近地面的点，即y轴上数值最大的顶点。以图6为例，我们的融合策略会选择来自第二个视角的多边形（红色多边形），因为第二个视角检测到了多边形的最低点。如果该准则仍无法选出多边形

---

![Image](images/2008f55397d439d8b5522098c5ac67acd1d2ac7a9ead1c23b61c157b6d8a399f.jpg)

<div style="text-align: center;">Fig. 4 These results are obtained by using sequence from PETS 2010 dataset. The first row shows the original images with detected polygons. The second row shows the foreground mask and the third row presents the projected polygons. The ground plane image is obtained using Google Maps view of the scene provided with the dataset.</div>

就如图7中的情况，我们会根据目标相对于相机的位置进行选择。实际上，该位置会对单应平面中的成像结果产生影响。为应用该准则，我们为每个相机计算

![Image](images/9c578b2f76fd1422ae70e86e3e872f7d782fea42410abdd02e72fa8b98fe05d5.jpg)

<div style="text-align: center;">Fig. 5 Illustration of scene observed by two cameras</div>

---

![Image](images/2347fea435af16c0bb97586b0eb1a2d14c9526c1c8c5f398a58a37fa3583c89c.jpg)

<div style="text-align: center;">Fig. 6 Polygons obtained after projection in a ground plane. In this plane, the x-axis is oriented from right to left and the y-axis is oriented from bottom to up. The polygon in color green is from the first view and the polygon in color red is from the second view.</div>

投影多边形最高顶点（y轴数值最小的顶点）与同一多边形最低顶点投影之间的距离。最优多边形就是该距离最小的多边形。在图7的示例中，最优多边形为绿色多边形。

c3：来自第一个视角的多边形关联到来自第二个视角的多个多边形。第三种情况如图8所示，在该情况下我们判定这属于目标之间的动态遮挡。据此，拥有最多关联多边形的相机为最优相机，这些多边形随后会被选中。如果将该原则应用到图8中，绿色多边形将作为融合过程的结果被选中。

在c1、c2和c3三种情况中，若来自某视角的多边形P1的任意一个顶点投影到底平面后，所得投影点落在将P2顶点投影到底平面得到的投影多边形内部，则认为P1与来自另一视角的多边形P2相关联。为了解决点是否在多边形内的问题，我们采用了Sutherland等人在[^35]中提出的光线投射算法。该算法会统计从给定点出发的射线

![Image](images/43abab554893d61081da66e9a24f58fbb196b0b8828c48edb413688da4ebc646.jpg)

<div style="text-align: center;">Fig. 7 Polygons obtained after projection in a ground plane. In this plane, the x-axis is oriented from right to left and the y-axis is oriented from bottom to up. The polygon in color green is from the first view and the polygon in color red is from the second view.</div>

---

![Image](images/b8c4f902541ca5d47112ed8fac9e289fed6f435507e6155b1300dcc9e8d23146.jpg)

<div style="text-align: center;">Fig. 8 Polygons obtained after projection in a ground plane. In this plane, the x-axis is oriented from right to left and the y-axis is oriented from bottom to up. The polygon in color green is from the first view and the polygon in color red is from the second view.</div>

与多边形各边相交的次数。如果待判断点不在多边形边界上，相交次数为偶数时点在多边形外，相交次数为奇数时点在多边形内。该算法既适用于凸多边形，也适用于凹多边形。

对于剩余的每台相机（如果还有剩余），会重复上述融合过程，处理对象为上一次融合得到的多边形和新视角的多边形。

### 2.3 跟踪策略

本节介绍我们的跟踪策略和人数统计方法。在所提出的系统中，跟踪模块用于支撑人数统计功能，它会随时间持续跟踪人员的运动并保存其身份信息。我们的跟踪模块是对Motamed在[^31]中提出的跟踪策略的扩展。该学者原本提出了一种简单有效的策略，用于单摄像头视频监控系统中的目标跟踪。我们的跟踪策略将多摄像头系统的需求融入了[^31]提出的算法中。本文提出的策略在融合完成后对地平面上的目标进行跟踪。融合完成后，为了纳入目标的近似行为规律，我们对每个被跟踪目标在地平面上使用一阶位置预测。对于每个检测到的区域，我们会计算以下视觉特征：重心、边界框，以及每个视角下目标的颜色直方图。为了减少数据量，每个颜色通道的直方图被压缩为32个区间。为了给每个目标减少候选区域数量，我们定义了一个空间验证门限。该门限可以纳入所有目标的运动学限制。为了提升计算效率，我们根据经验将该门限的尺寸设置为目标边界框的两倍，位置则在预测目标位置周围。匹配过程基于区域的空间邻近度和视觉兼容性。算法会显式评估每次关联的质量，该信息由两个指标概括：一致性指标和身份指标。这些指标在跟踪步骤中会被递归更新并存储。被跟踪目标的一致性指标首先可以在连续观测后完成对新目标的有效验证，其次它可以容忍轨迹可靠的目标出现暂时性丢失。它

---

<table border=1 style='margin: auto; word-wrap: break-word;'><tr><td style='text-align: center; word-wrap: break-word;'>Object information</td></tr><tr><td style='text-align: center; word-wrap: break-word;'>Object number</td></tr><tr><td style='text-align: center; word-wrap: break-word;'>View 1 color histogram (k), view 2 color histogram (k),...,view n color histogram (k)</td></tr><tr><td style='text-align: center; word-wrap: break-word;'>Position in ground plane (k), Bounding box in ground plane (k)</td></tr><tr><td style='text-align: center; word-wrap: break-word;'>Consistency indicator (k)</td></tr><tr><td style='text-align: center; word-wrap: break-word;'>Speed vector (k)</td></tr><tr><td style='text-align: center; word-wrap: break-word;'>Identity indicator (k)</td></tr></table>

在目标层面作为一种鲁棒滤波器发挥作用。当目标特征（各视角下对应目标的颜色直方图、投影所得多边形在地平面上的边界框尺寸，以及投影多边形的速度向量）未观测到显著变化时，该指示值会上升。反之，或是在目标丢失的极端情况下，指示值会下降。目标颜色直方图之间的差异性采用巴氏距离（Bhattacharya distance）计算。每个被跟踪目标一致性指示值的更新过程由人类专家定义的时间延迟控制，该延迟也被称为稳定性指示值。当丢失目标的一致性指示值连续一段时间为零后，就会终止该目标的跟踪。该延迟通常固定为3秒。每个被跟踪目标都会存储一组信息（表1）。表1中的「目标编号」属性是每个目标的唯一标识符。当出现合并场景（或拆分场景）时，我们采用[^31]中提出的合并流程（或对应的拆分流程）。当在临时分组区域附近检测到新目标时，判定为拆分场景；当在多个已有目标附近检测到一个新目标时，判定为合并场景。

### 2.4 计数策略

本文的人数统计方法与跟踪策略紧密关联。当跟踪器检测到有效的新目标时，总人数就会增加1。跟踪器创建带有新目标编号的目标，即代表检测到新目标。按照该方式处理，并且基于所有目标都被跟踪器跟踪的假设，我们可以确保统计出所有经过场景的人数。要统计当前帧中的人数，我们首先统计跟踪器检测到的所有目标，在此基础上加上根据一致性指示值判定为暂时丢失的目标数量。该策略可以在容忍一定程度暂时丢失的前提下实现高效计数。

## 3 实验结果与性能评估

### 3.1 实验环境

本节我们介绍实验环境，用于评估本文提出的基于融合算法的多视角人数统计方法的性能。该方法已在多个多视角序列上完成测试。这些序列均公开可用，且已被其他现有方法采用。这些序列来自EPFL [^11] 和

---

PETS 2010 [^10] 数据集，已有众多研究工作在实验中采用了该数据集，因此将本文提出的算法与过往研究算法进行性能对比是公平合理的。来自EPFL数据集的Terrace1序列（包含view_0至view_3）时长约3分半钟，画面中最多有7人在平台上行走。这类序列给行人检测、跟踪与计数带来了公认的挑战，包括光照变化与阴影、相机距离场景较远，以及人群导致的频繁遮挡。来自PETS 2009数据集的多个短序列：Time_12-34_S0（view_1至view_8）、Time_12-34_S2（view_1至view_8）、Time_13-57_S1（view_1至view_8）和Time_13-59_S1（view_1至view_4），其中最多有40人在10平方米的区域内行走。对于跟踪模块，我们设定一致性指标在持续1.5秒的有效关联后达到最大值。所有实验均在一台笔记本电脑上完成，该电脑配备英特尔酷睿i7 L640 CPU，主频为2.13GHz × 4，内存4GB，编程语言为基于OpenCv库的C++。

### 3.2 性能评估与讨论

我们从两个层面展示并分析所提方法的性能：首先评估本文提出的融合策略的性能，该策略是我们行人计数方法的核心模块，之后再分析整个计数系统的性能。

融合模块的目标是完成相机网络中各相机捕捉到的行人之间的关联。我们将本文的融合方法与现有领域中已提出的其他融合方法 [^39] [^41] 进行对比。结果表明，本文方法能够很好地完成移动行人关联，在动态遮挡场景下仍能保持较高的准确率，其性能与现有领域 [^39] [^41] 提出的融合方法性能相近。我们还评估了本文融合方法的处理时间，并将其与 [^41] 和 [^39] 中提出的融合方法进行对比。Time_13-59_S1和Time_12-34_S2数据集的实验结果如图9所示。该图验证了 [^39] 得出的结论（[^39] 的作者称他们的方法比现有融合算法快40倍）。这些结果也证实本文提出的融合方法比Xu等人的方法运行速度更快。因此我们可以得出结论：本文的融合算法能够更快地完成各单相机不同观测结果之间的数据关联。此外，为了衡量

![Image](images/58312e617de19edbb91e50ee2a7d85556ee44f73a370117b8e8344d8ebb0b2ab.jpg)

<div style="text-align: center;">Fig. 9 Speed processing evaluation for Time_13-59_S1 and Time_12-34_S2 datasets</div>

---

![Image](images/76254d92fbba8fe2022fd0ac562c43c58aaa06e731abef4edc43652ac45f79eb.jpg)

<div style="text-align: center;">Fig. 10 Evolution of the recall value depending on the number of camera used for people counting (sequence: Terrace 1)</div>

融合策略带来的增益，我们研究了计数过程中所用相机数量对结果的影响。我们采用多个指标对行人计数效果进行评估，这些指标分别是召回率（Recall）、精确率（Precision）和F度量（F-Measure）。对于Terrace 1序列，召回率和精确率随相机数量的变化趋势如图10和图11所示。两张图均表明，召回率和精确率均随相机数量的增加而提升。由此可见，本文的融合策略能够有效融合不同视角的信息，提升计数准确率。

证明了融合方法的有效性后，我们将本文提出的人数统计方法的性能与现有其他先进算法进行了对比。对于已有公开结果的方法，我们对比了[^13] [^29]和[^30]中报道的多视角人数统计方法取得的性能值。结果列于表2中，这些结果表明本文提出的方法拥有更高的准确率。我们的方法优于Ge和Collins [^13]以及Ma等人[^29]提出的方法，性能更接近现有已提出的方法。

![Image](images/e33c4200f741d07f76d7fea8f060586a81c49cf823766fefbe4c3f6c4d314f4b.jpg)

<div style="text-align: center;">Fig. 11 Evolution of the precision value depending on the number of camera used for people counting (sequence : Terrace 1)</div>

---

<div style="text-align: center;">Table 2 People counting performance in sequences Time_12-34_S0, Time_12-34_S2, Terrace1</div>

<table border=1 style='margin: auto; word-wrap: break-word;'><tr><td style='text-align: center; word-wrap: break-word;'>Sequence</td><td style='text-align: center; word-wrap: break-word;'>Algorithm</td><td style='text-align: center; word-wrap: break-word;'>Recall</td><td style='text-align: center; word-wrap: break-word;'>Precision</td><td style='text-align: center; word-wrap: break-word;'>F-measure</td></tr><tr><td rowspan="2">Time_12-34_S0</td><td style='text-align: center; word-wrap: break-word;'>Maddalena et al. [^30]</td><td style='text-align: center; word-wrap: break-word;'>0.97</td><td style='text-align: center; word-wrap: break-word;'>0.99</td><td style='text-align: center; word-wrap: break-word;'>0.98</td></tr><tr><td style='text-align: center; word-wrap: break-word;'>proposed</td><td style='text-align: center; word-wrap: break-word;'>0.98</td><td style='text-align: center; word-wrap: break-word;'>0.99</td><td style='text-align: center; word-wrap: break-word;'>0.98</td></tr><tr><td rowspan="4">Time_12-34_S2</td><td style='text-align: center; word-wrap: break-word;'>Ge and Collins [^13]</td><td style='text-align: center; word-wrap: break-word;'>0.91</td><td style='text-align: center; word-wrap: break-word;'>0.95</td><td style='text-align: center; word-wrap: break-word;'>0.93</td></tr><tr><td style='text-align: center; word-wrap: break-word;'>Ma et al. [^29]</td><td style='text-align: center; word-wrap: break-word;'>0.92</td><td style='text-align: center; word-wrap: break-word;'>0.97</td><td style='text-align: center; word-wrap: break-word;'>0.94</td></tr><tr><td style='text-align: center; word-wrap: break-word;'>Maddalena et al. [^30]</td><td style='text-align: center; word-wrap: break-word;'>0.98</td><td style='text-align: center; word-wrap: break-word;'>0.98</td><td style='text-align: center; word-wrap: break-word;'>0.98</td></tr><tr><td style='text-align: center; word-wrap: break-word;'>proposed</td><td style='text-align: center; word-wrap: break-word;'>0.98</td><td style='text-align: center; word-wrap: break-word;'>0.98</td><td style='text-align: center; word-wrap: break-word;'>0.98</td></tr><tr><td rowspan="3">Terrace 1</td><td style='text-align: center; word-wrap: break-word;'>Ma et al. [^29]</td><td style='text-align: center; word-wrap: break-word;'>0.95</td><td style='text-align: center; word-wrap: break-word;'>0.92</td><td style='text-align: center; word-wrap: break-word;'>0.93</td></tr><tr><td style='text-align: center; word-wrap: break-word;'>Maddalena et al. [^30]</td><td style='text-align: center; word-wrap: break-word;'>0.96</td><td style='text-align: center; word-wrap: break-word;'>0.96</td><td style='text-align: center; word-wrap: break-word;'>0.96</td></tr><tr><td style='text-align: center; word-wrap: break-word;'>proposed</td><td style='text-align: center; word-wrap: break-word;'>0.98</td><td style='text-align: center; word-wrap: break-word;'>0.99</td><td style='text-align: center; word-wrap: break-word;'>0.98</td></tr></table>

接近Maddalena等人[^30]提出的方法。但我们的系统不需要学习阶段，而[^30]中提出的系统采用的是有监督分类方法。这为我们的系统提供了大得多的灵活性。我们还给出了序列Time_13-57_S1和Time_13-59_S1在平均帧误差指标下的结果，结果展示在图12中。通过观察图12可以得出，与Maddalena等人[^30]提出的方法相比，我们提出的方法平均误差更低。因此我们的方法在人数统计上能得到更好的结果，同时将误差最小化。综合表2和图12中的性能结果，我们可以得出结论：本文提出的方法在中等人群密度场景中取得了良好的性能。最后，我们在表3中给出了本文算法在3.1节描述的普通笔记本电脑上的处理速率。通过该表可以看出，我们在普通笔记本电脑上实现的方法，运行速度会根据场景中的人数和所用相机的数量发生变化。

![Image](images/8fb85b0b657be1584b1f20cbdbf79181aef48f8b4871513139c71bbf672137c6.jpg)

<div style="text-align: center;">Fig. 12 Average Frame Error for people counting in sequences Time_13-57_S1 and Time_13-59_S1</div>

---

<div style="text-align: center;">Table 3 Processing rate</div>

<table border=1 style='margin: auto; word-wrap: break-word;'><tr><td style='text-align: center; word-wrap: break-word;'>Sequence</td><td style='text-align: center; word-wrap: break-word;'>Processing rate</td></tr><tr><td style='text-align: center; word-wrap: break-word;'>Time_12-34_S0</td><td style='text-align: center; word-wrap: break-word;'>2.02 frames/second</td></tr><tr><td style='text-align: center; word-wrap: break-word;'>Time_12-34_S2</td><td style='text-align: center; word-wrap: break-word;'>2.11 frames/second</td></tr><tr><td style='text-align: center; word-wrap: break-word;'>Time_13-59_S1</td><td style='text-align: center; word-wrap: break-word;'>5.32 frames/second</td></tr><tr><td style='text-align: center; word-wrap: break-word;'>Terrace 1</td><td style='text-align: center; word-wrap: break-word;'>7.97 frames/second</td></tr></table>

## 4 结论与未来工作

本文提出了一种用于视频监控场景的多视角相机人数统计算法。该系统依托多视角视频目标检测和运动目标跟踪领域的研究成果，集成了多个经实践验证非常高效的模块。我们采用基于码本的模型检测前景像素，并将前景图融合到地平面上。本文数据关联方法的计算复杂度是人数统计系统的一大优势。我们后续采用跟踪系统逐帧估计人群规模。该系统对动态遮挡（通过融合策略实现）和目标检测的暂时丢失（通过跟踪策略实现）都具备鲁棒性。然而，当人群规模更大、密度更高时，单个目标的检测和跟踪会变得困难，因此人数统计的准确率会下降。一种替代方案是采用“以人群为中心”的方法，该方法基于分析从人群图像中提取的全局低层特征来得到准确的人数统计估计。本文的计数方法还高度依赖每个相机的前景像素提取结果，因此假阳性的存在会影响计数结果。最后，如果场景中出现非人类物体，也会产生计数误差。

未来，我们计划利用运动方向轨迹将人群分割为向不同方向移动的子群体。这些信息将有助于提出基于运动轨迹分析的事件识别算法。

致谢 本工作得到了法国AS2V协会与Jacques De Rette基金会的部分资助。作者感谢法国驻贝宁大使馆文化与合作处的支持。我们也非常感谢匿名评审专家给出的宝贵意见，这些意见极大地提升了本文的质量。

## 参考文献

[^1]: Albiol A, Mora I, Naranjo V (2001) Real-time high density people counter using morphological tools. IEEE Trans Intell Trans Syst 2(4):204–218

[^2]: Beymer D (2000) Person counting using stereo. In: Proceedings of workshop on human motion, pp 127–133

[^3]: Cai Q, Aggarwal J (1998) Automatic tracking of human motion in indoor scenes across multiple synchronized video streams. In: Proceedings of IEEE international conference on computer vision, pp 356–362

[^4]: Chan A, Vasconcelos N (2012) Counting people with low-level features and bayesian regression. IEEE Trans Image Process 21(4):2160–2177


## [^5]: Conte D, Foggia P, Percannella G, Tufano F, Vento M (2010) A method for counting moving people in video surveillance videos. EURASIP J Adv Signal Processing:1–10


---

[^6]: Davies A, Yin JH, Velastin S (1995) Crowd monitoring using image processing. Electron Commun Eng J 7(1):37–47

[^7]: Duin RPW, Tax DMJ (2000) Experiments with classifier combining rules. In: Proceedings of 1st international workshop on multiple classifier systems, pp 16–29

[^8]: Englebienne G, Krose B (2010) Fast bayesian people detection. In: Proceedings of the 22nd benelux conference on artificial intelligence

[^9]: Eshel R, Moses Y (2008) Homography based multiple camera detection and tracking of people in a dense crowd. In: Proceedings of 18th IEEE international conference on computer vision and pattern recognition, pp 1–8

[^10]: Ferryman J, Shahrokni A (2009) An overview of the pets 2009 challenge. In: Proceedings of the 11th IEEE international workshop on performance evaluation of tracking and surveillance, pp 25–30

[^11]: Fleuret F, Berclaz J, Lengagne R (2008) Multi-camera people tracking with a probabilistic occupancy map. IEEE Trans Pattern Anal Mach Intell 30(2):267–282

[^12]: Fu H, Ma H, Xiao H (2014) Scene-adaptive accurate and fast vertical crowd counting via joint using depth and color. Multimed Tools Appl 73(1):273–289

[^13]: Ge W, Collins R (2010) Crowd detection with a multiview sampler. In: Daniilidis K, Maragos P, Paragios N (eds) Computer vision ECCV 2010. Lecture Notes in Computer Science, pp 324–337

[^14]: Giacinto G, Roli F, Fumera G (2000) Selection of classifiers based on multiple classifier behaviour. In: Advances in pattern recognition, pp 87–93

[^15]: Harville M (2004) Stereo person tracking with adaptive plan-view templates of height and occupancy statistics. Image Vis Comput 22(2):127–142

[^16]: Hashemzadeh M, Pan G, Yao M (2014) Counting moving people in crowds using motion statistics of feature-points. Multimed Tools Appl 72(1):453–487

[^17]: Hu W, Hu M, Zhou X, Tan T, Lou J, Maybank S (2006) Principal axis-based correspondence between multiple cameras for people tracking. IEEE Trans Pattern Anal Mach Intell 28(4):663–671

[^18]: Khan S, Shah M (2003) Consistent labeling of tracked objects in multiple cameras with overlapping fields of view. IEEE Trans Pattern Anal Mach Intell 25(10):1355–1360

[^19]: Khan SM, Shah M (2006) A multi-view approach to tracking people in crowded scenes using a planar homography constraint. In: Proceedings of 9th European conference on computer vision, pp 133–146

[^20]: Khan SM, Shah M (2009) Tracking multiple occluding people by localizing on multiple scene planes. IEEE Trans Pattern Anal Mach Intell 31(3):505–519

[^21]: Kang J, Cohen I, Medioni G (2003) Continuous tracking within and across camera streams. In: Proceedings of international conference on computer vision pattern recognition, vol 1, pp 267–272

[^22]: Kim K, Davis LS (2006) Multi-camera tracking and segmentation of occluded people on ground plane using search-guided particle filtering. In: Proceedings of the 9th European conference on computer vision, pp 98–109

[^23]: Kim J, Seo K, Chung K (1997) A systematic approach to classifier selection on combining multiple classifiers for handwritten digit recognition. In: Proceedings of international conference on document analysis and recognition, vol 2, pp 459–462

[^24]: Kim JW, Choi KS, Park WS, Lee JY, Ko SJ (2002) Robust real-time people tracking system for securi

[^24]: Kim JW, Choi KS, Park WS, Lee JY, Ko SJ (2002) Robust real-time people tracking system for security

[^25]: Kim K, Chalidabhonse TH, Harwood D, Davis L (2005) Real-time foreground-background segmentation using codebook model. Elsevier Real-Time Imaging 11(3):167–256

[^26]: Krahnstoever N, Yu T, Patwardhan K, Gao D (2009) Multi-camera person tracking in crowded environments. In: Proceedings of 12th IEEE international workshop on performance evaluation of tracking and surveillance, pp 1–7

[^27]: Kuncheva LI, Whitaker CJ, Ship CA, Duin RPW (2000) Is independence good for combining classifiers? In: Proceedings of international conference on pattern recognition, vol 2, pp 168–171

[^28]: Kuncheva LI, Bezdek CJ, Duin RPW (2001) Decision templates for multiple classifier fusion : on experimental comparison. Pattern Recogn:299–314

[^29]: Ma H, Zeng C, Ling CX (2012) A reliable people counting system via multiple cameras. ACM Trans Intell Syst Technol 3(2)

[^30]: Maddalena L, Petrosino A, Russi F (2014) People counting by learning their appearance in a multi-view camera environment. Pattern Recogn Lett 36:125–134


## [^31]: Motamed C (2006) Motion detection and tracking using belief indicators for an automatic visual-surveillance system. Image Vis Comput:1192–1201


---

[^32]: Mousse MA, Ezin EC, Motamed C (2014) Foreground-background segmentation based on codebook and edge detector. In: 10th international conference on signal-image technology and internet-based systems, pp 119–124

[^33]: Qiuyu Z, Li T, Yiping J, Wei Jun D (2010) A novel approach of counting people based on stereovision and disp. In: Proceedings of The 2nd international conference on computer and automation engineering, vol 1, pp 81–84

[^34]: Subburaman V, Descamps A, Carincotte C (2012) Counting people in the crowd using a generic head detector. In: Proceedings of IEEE 9th international conference on advanced video and signal-based surveillance, pp 470–475

[^35]: Sutherland IE, Sproull RF, Schumacker RA (1974) A characterization of ten hidden surface algorithms. In: ACM Computing Surveys (CSUR), pp 1–55

[^36]: van Oosterhout T, Bakkes S, Krse BJA (2011) Head detection in stereo data for people counting and segmentation. In: VISAPP, pp 620–625

[^37]: Wren C, Azarbayejani A, Darrel T, Pentland A (1996) Pfinder: real-time tracking of the human body. In: Proceedings of 2nd international conference on automatic face and gesture recognition, pp 51–56

[^38]: Xu M, Orwell J, Lowey L, Thirde D (2005) Architecture and algorithms for tracking football players with multiple cameras. IEE Proc-Vis Image Signal Process 152(2):232–241

[^39]: Xu M, Ren J, Chen D, Smith J, Wang G (2011) Real-time detection via homography mapping of foreground polygons from multiple. In: Proceedings of 18th IEEE international conference on image processing, pp 3593–3596

[^40]: Yahiaoui T, Khoudour L, Meurie C (2010) Real-time passenger counting in buses using dense stereovision. J Electron Imaging 19(3)

[^41]: Yang DB, Gonzalez-Banos HH, Guibas LJ (2003) Counting people in crowds with a real-time network of simple image sensors. In: Proceedings of 9th IEEE international conference on computer vision, vol 1, pp 122–129

[^42]: Zhao T, Nevatia R (2003) Counting people in crowds with a real-time network of simple image sensors. In: Proceedings of IEEE international conference on computer vision and pattern recognition, vol 1, pp 122–129

![Image](images/ef5a8448a54b5d8355305d617639b3e4ae4fba14fd98151dd7d37cd79245a79e.jpg)

米卡埃尔·A·穆斯于2008年在贝宁阿波美-卡拉维大学应用经济与管理国立学院获得工程学士学位，2012年在贝宁阿波美-卡拉维大学数学与物理科学学院获得计算机工程与应用科学硕士学位。目前他正于贝宁阿波美-卡拉维大学数学与物理科学学院与法国滨海-加来海峡海岸大学攻读计算机工程方向博士学位。他的研究方向包括信号处理、图像处理、视频处理、机器学习以及模式分析与识别。

---

![Image](images/059a42bdbd889748307795a25d47337404a39c7e59227030cc549708ab407ea1.jpg)

<div style="text-align: center;">Cina Motamed is associate professor in Computer Science in the University of Littoral Cote d'Opale, Calais, France. He received his B.Sc. in mathematics, and M.Sc. in Electrical Engineering and Computer Science from the University of Caen, France and the PhD degree in Computer Science from the University of Compiagne, France, in 1987, 1989, and 1992, respectively. Current research is concerned with the automatic visual surveillance of wide area scenes using computational vision. His research interests focus on the design of multicamera system for real-time multiobject tracking and human action recognition. He is recently focusing on the uncertainty management over the vision system by using graphical models, and beliefs propagation. He is also interested in unsupervised learning approaches for human activity recognition.</div>

![Image](images/e275492954d63d9b27da26367d41bc922e3724cef78102381177b0f70c055fc2.jpg)

<div style="text-align: center;">Eugène C. Ezin, IEEE member in computer society, received his PhD degree in 2001 with the highest level of distinction after research works carried out on neural networks and fuzzy systems for speech applications at the International Institute for Advanced Scientific Studies in Italy. Since July 2012, he is associated professor in computer science in the field of artificial intelligence. He supervised many master theses and some works are ongoing for PhD theses. He is a reviewer for Mexican International Conference on Artificial Intelligence and other journals. His research interests include machine learning, neural networks and fuzzy systems, signal and image processing, cryptography, information system and network security. He is also interested in human activities recognition through multi-sensor systems.</div>
