## 3 Materials and Methods
### Regional Topic Model and Its Online Inference Algorithm
These simulated experimental results show the validity of RTM for discovering motion topic and motion region. #### 4.3.2 Real Video Experiment

Likewise, for QUML dataset, the motion topics and regions discovered by RTM-GS and RTM-HSVG is shown in Figures 8-11 respectively. According to the comparisons of latent motion topic and motion regions discovered in above figures, RTM-GS obtained more clearly atomic motion patterns, which form the motion topic. Nevertheless, RTM-HSVG obtained a more focused clustering in both motion topic and region, and the direction representation of RTM-HSVG is richer (observed from the mixture of four directions). This is because the Markov chain state space of large-scale dataset is larger; it needs a longer burn-in time for Markov chain convergence. Even if RTM-HSVG has a shorter burn-in time, it also obtained a better performance than RTM-GS. In order to test the impact of burn-in time on performance of our model, the burn-in time of RTM-GS is increasing to four times, and the iteration-times is set as 8000. Then, the motion topics and regions results are shown in Figures 12 and 13. Figure 11: Thirty-six latent motion topics discovered by RTM-HSVG. Figure 10: Twenty latent motion regions discovered by RTM-HSVG. In comparison with Figures 8 and 12 as well as Figures 9 and 13, we find that longer burn-in time makes a more focused clustering in both motion topic and region. Nevertheless, it is difficult to decide when Markov chain is convergent in Gibbs sampling, and longer burn-time is at the expense of time efficiency. Therefore, RTM-HSVG is more efficient than RTM-GS as an online algorithm. Meanwhile, we find that a larger number of topics can make more clear motion topics, which also makes more repeated latent topics. Therefore, it illustrates that the number of topics and regions are important aspects to decide performance of RTM. The ROC curve comparison of RTM-HSVG and RTM-GS is shown in the Figure 14. As shown in Figure 14, the area under ROC of RTM-HSVG is 0.59, and RTM-GS is 0.577. These results again indicate that RTM-HSVG can improve the accuracy of abnormal event detection in comparison with RTM-GS. At last, several abnormal events discovered by RTM-HSVG are shown in Figure 15, and the regions of abnormal motion are labeled by dark red. Figure 12: Twenty latent motion regions discovered by RTM-GS on longer burn-in time. Figure 13: Eighteen latent motion topics discovered by RTM-GS on longer burn-in time. Figure 15a shows an abnormal event in 33 rd clips (37,410-37,769), its motion region is number 6, and NLL = 724,951.87. A fire vehicle is driving into the crossing from right and interrupting the vertical traffic. Figure 15b shows an abnormal event in 25 th clips (34,538-34,897), its motion region is number 9, and NLL = 753,774.17. A car is turning right illegally. Figure 15c shows an abnormal event in 15 th clips (30,948-31,307), its motion region is number 13, and NLL = 792,248.81. A car makes a U-turn illegally. Figure 15d shows an abnormal event in 14 th clips (30,589-30,948), its motion region is number 15, and NLL = 819,426.78. A fire vehicle is driving into the crossing from lift and interrupting the vertical traffic. From the above experimental results, we can see that RTM is able to discover motion topics and motion regions efficiently. Specially, the HSVG inference algorithm designed for RTM is better than Gibbs sampling on accuracy and time efficiency. Therefore, we can anticipate that RTM-HSVG is a potential method for real-time video mining. ## 5 Conclusions

To solve the problem that traditional topic model is unable to process video in real-time and model motion regional information, we proposed a RTM and designed its hybrid stochastic variational Gibbs sampling algorithm. In RTM, observation data not only has the motion topic label but also has

Figure 5:0 Comparative results of ROC on real video. Figure 5:1 Locating abnormal events by RTM-HSVG. region label of its position.