## 2 Detection Model
### Foreground Motion Blocks Extraction
#### 2.1.1 Sampling Areas Determination
The panning and zooming groups are tested with six sequences, and the results are acquired by computing their average values. One can see that an optimal combination of (\(th1\), \(th2\)) is (0.3, 0.5), which indicates that the classifier is able to make acceptable decisions for camera statuses. #### 2.1.5 Marking Motion Areas

After acquiring the global compensated motion data of foreground ROI objects, a MV clustering method is proposed to segment blocks into motion areas. For each ROI block, we apply the target clustering function \(J\) based on the following definition:

\[J=\sum_{i=1}^{N}\sum_{j=1}^{K}\mu_{ij}(\|\tilde{x}_{i}^{p}-\tilde{c}_{j}^{p}\|^ {2}+\|\tilde{x}_{i}^{mv}-\tilde{c}_{j}^{mv}\|^{2}+\|\tilde{x}_{i}^{I}-\tilde{c }_{j}^{I}\|^{2}), \tag{21}\]

where \(\tilde{x}_{i}^{p}\), \(\tilde{x}_{i}^{mv}\) and \(\tilde{x}_{i}^{I}\) denote the normalized vectors of position, motion vector, pixel intensity for block \(i\) correspondingly. Please note that \(\tilde{x}_{i}^{I}\) has three components (Y/U/V) while the others have two. \(\mu_{ij}\) indicates the belongingness of block \(i\) to cluster area \(j\), and \(c\) stands for the center vector. Apparently, the target function \(J\) considers blocks' position together with pixel and motion similarities. To solve non-spherical clusters, we use Kernel Fuzzy C-Means (KFCM) method for block classification, which induces the kernel function \(\mathcal{K}(\mathbf{\tilde{x}}_{i},\mathbf{\tilde{c}}_{j})=\exp(-\frac{\|\mathbf{\tilde{x} }_{i}-\mathbf{\tilde{c}}_{j}^{I}\|^{2}}{\sigma^{2}})\) in criteria computation. To adaptively classify \begin{table}
\begin{tabular}{c c c c c c} \hline \hline
**Sequences** & **Our Method** & **GD** & **LSS-ME** & **RANSAC** \\ \hline _Flower_ & 0.097 s & 0.181 s & 0.466 s & 0.240 s \\ _Stefan_ & 0.293 s & 0.665 s & 0.712 s & 0.497 s \\ _CoastGuard_ & 0.225 s & 0.604 s & 0.811 s & 0.472 s \\ \hline \hline \end{tabular}
\end{table} 
Table 1: Running time tests for GME approaches. (Platform: OpenCV 3.1, Core-i/? CPU 2.8 GHZ\(\times\) 4). \begin{table}
\begin{tabular}{c c c c c c c} \hline \hline
**Seq** & **Status** & \(th1\) & \(th2\) & **prec** & **Recall** & **F-Score** \\ \hline _BQTerrace_ & & 0.1 & 0.3 & 0.818 & 0.901 & 0.857 \\ _Flower_ & panning & 0.3 & 0.3 & 0.940 & 0.901 & 0.922 \\ _Foreman_ & / rests & 0.5 & 0.3 & 0.846 & 0.880 & 0.863 \\  & & 0.7 & 0.3 & 0.702 & 0.801 & 0.747 \\ \hline \hline \multirow{3}{*}{_PartyScene_ _BQSquare_} & & 0.3 & 0.1 & 0.649 & 0.740 & 0.692 \\  & zooming & 0.3 & 0.3 & 0.722 & 0.780 & 0.750 \\ \cline{1-1}  & / rests & 0.3 & 0.5 & 0.773 & 0.820 & 0.796 \\ \cline{1-1}  & & 0.3 & 0.7 & 0.693 & 0.680 & 0.686 \\ \hline \hline \end{tabular}
\end{table} 
Table 2: Performance of camera status decision with different settings of thresholds. these foreground blocks, we propose a clustering algorithm which optimally classifies blocks into adequate areas, see Algorithm 3 for details. ```
1: Set \(k=1\), \(\tilde{\epsilon}_{1}=E(\tilde{\pi}_{i}^{p},\tilde{\pi}_{i}^{mw},\tilde{\pi}_{i}^{ l})\). 2:while\(k\geq K_{max}\)do
3: Segment \(N\) blocks into \(k\) clusters by KFCM algorithm with the stopping criteria: \(\frac{|I^{t+1}-I^{t}|}{|I^{t}|}<\epsilon\). 4: Compute \(J_{j}=\sum\limits_{j}\left(||\tilde{x}_{j}^{T}-\tilde{c}_{j}^{t}||^{2}+|| \tilde{x}_{i}^{mw}-\tilde{c}_{j}^{mw}||^{2}+||\tilde{x}_{i}^{l}-\tilde{c}_{j}^{ l}||^{2}\right)\). 5:if\(\max_{j\in(0,k]}J_{j}\overset{\xi\to{}}{\xi}|\tilde{\epsilon}_{j}|\)and\(|\tilde{\epsilon}_{j}|\geq N/(k+o)\)then
6:return\(\mu\), \(k\), \(\tilde{\epsilon}_{j},j\in(0,k]\). 7:endif
8:\(k=k+1\);
9:endwhile
10:return\(\mu\), \(K_{max}\), \(\tilde{\epsilon}_{j},j\in(0,K_{max}]\). ```

**Algorithm 3** KFCM Motion Areas Clustering Algorithm

Notice that the clustering algorithm segments the foreground blocks into \(k\) clusters, where \(k\) increases from \(1\) to \(K_{max}\) iteratively. At each turn, it computes the target function (\(J_{j}\)) for each cluster \(j\).