Foot Traffic Heatmaps for Retail Stores

Mapping people seen in store camera feeds onto the floor plan


This systems uses the CCTV feeds of ACI Shwapno retail stores to build heatmaps of foot traffic on each store’s floor plan. It was deployed in two stores with 16 cameras each. Store teams used the heatmaps to plan shelf layouts and to decide when and where more staff were needed.

How it works

Detecting people. A YOLOv8 model detects people in each camera’s frames. It doesn’t distinguish shoppers from staff, so the heatmaps show overall foot traffic.

Mapping to the floor plan. For each detection, the bottom-center of its bounding box, roughly where the person is standing, is mapped onto the floor plan using a homography computed once for each camera:

\[\begin{bmatrix} x' \\ y' \\ w \end{bmatrix} = \begin{bmatrix} h_{11} & h_{12} & h_{13} \\ h_{21} & h_{22} & h_{23} \\ h_{31} & h_{32} & h_{33} \end{bmatrix} \begin{bmatrix} x \\ y \\ 1 \end{bmatrix}\]

Here \((x, y)\) is the point in the camera image, and \((x'/w,\ y'/w)\) is the matching point on the floor plan.

Building the heatmaps. Mapped positions from all cameras are accumulated over time into heatmaps, which show the busiest areas of the store and when they are busiest.

Demo: Detections across the 16 camera feeds of one store.