CN107832688B - A traffic pattern and abnormal behavior detection method for video surveillance of traffic intersections - Google Patents
A traffic pattern and abnormal behavior detection method for video surveillance of traffic intersections Download PDFInfo
- Publication number
- CN107832688B CN107832688B CN201711030491.4A CN201711030491A CN107832688B CN 107832688 B CN107832688 B CN 107832688B CN 201711030491 A CN201711030491 A CN 201711030491A CN 107832688 B CN107832688 B CN 107832688B
- Authority
- CN
- China
- Prior art keywords
- video
- topic
- distribution
- document
- bnbp
- 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.)
- Expired - Fee Related
Links
- 206010000117 Abnormal behaviour Diseases 0.000 title claims abstract description 31
- 238000001514 detection method Methods 0.000 title claims description 26
- 238000000034 method Methods 0.000 claims abstract description 87
- 238000009826 distribution Methods 0.000 claims abstract description 81
- 230000003287 optical effect Effects 0.000 claims abstract description 39
- 239000011159 matrix material Substances 0.000 claims abstract description 24
- 239000013598 vector Substances 0.000 claims abstract description 24
- 230000008569 process Effects 0.000 claims description 12
- 238000005070 sampling Methods 0.000 claims description 11
- 230000000007 visual effect Effects 0.000 claims description 11
- 238000004422 calculation algorithm Methods 0.000 claims description 9
- 238000012360 testing method Methods 0.000 claims description 7
- 238000013139 quantization Methods 0.000 claims description 4
- 238000012549 training Methods 0.000 claims description 3
- 238000012544 monitoring process Methods 0.000 claims description 2
- 238000011002 quantification Methods 0.000 claims description 2
- 230000002159 abnormal effect Effects 0.000 description 14
- 230000006399 behavior Effects 0.000 description 11
- 230000006870 function Effects 0.000 description 11
- 238000004458 analytical method Methods 0.000 description 5
- 238000005065 mining Methods 0.000 description 4
- 238000004364 calculation method Methods 0.000 description 3
- 230000000694 effects Effects 0.000 description 3
- 238000011161 development Methods 0.000 description 2
- 238000002474 experimental method Methods 0.000 description 2
- 238000012545 processing Methods 0.000 description 2
- 241000283070 Equus zebra Species 0.000 description 1
- 230000002547 anomalous effect Effects 0.000 description 1
- 230000003542 behavioural effect Effects 0.000 description 1
- 230000009286 beneficial effect Effects 0.000 description 1
- 230000000052 comparative effect Effects 0.000 description 1
- 238000007418 data mining Methods 0.000 description 1
- 230000007423 decrease Effects 0.000 description 1
- 238000005516 engineering process Methods 0.000 description 1
- 238000000605 extraction Methods 0.000 description 1
- 238000005286 illumination Methods 0.000 description 1
- 238000010801 machine learning Methods 0.000 description 1
- 238000012986 modification Methods 0.000 description 1
- 230000004048 modification Effects 0.000 description 1
- 238000003909 pattern recognition Methods 0.000 description 1
- 230000008447 perception Effects 0.000 description 1
- 230000009467 reduction Effects 0.000 description 1
- 238000011160 research Methods 0.000 description 1
- 230000002123 temporal effect Effects 0.000 description 1
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06V—IMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
- G06V20/00—Scenes; Scene-specific elements
- G06V20/40—Scenes; Scene-specific elements in video content
- G06V20/41—Higher-level, semantic clustering, classification or understanding of video scenes, e.g. detection, labelling or Markovian modelling of sport events or news items
- G06V20/42—Higher-level, semantic clustering, classification or understanding of video scenes, e.g. detection, labelling or Markovian modelling of sport events or news items of sport video content
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06V—IMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
- G06V20/00—Scenes; Scene-specific elements
- G06V20/50—Context or environment of the image
- G06V20/56—Context or environment of the image exterior to a vehicle by using sensors mounted on the vehicle
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04N—PICTORIAL COMMUNICATION, e.g. TELEVISION
- H04N21/00—Selective content distribution, e.g. interactive television or video on demand [VOD]
- H04N21/40—Client devices specifically adapted for the reception of or interaction with content, e.g. set-top-box [STB]; Operations thereof
- H04N21/43—Processing of content or additional data, e.g. demultiplexing additional data from a digital video stream; Elementary client operations, e.g. monitoring of home network or synchronising decoder's clock; Client middleware
- H04N21/44—Processing of video elementary streams, e.g. splicing a video clip retrieved from local storage with an incoming video stream or rendering scenes according to encoded video stream scene graphs
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04N—PICTORIAL COMMUNICATION, e.g. TELEVISION
- H04N21/00—Selective content distribution, e.g. interactive television or video on demand [VOD]
- H04N21/40—Client devices specifically adapted for the reception of or interaction with content, e.g. set-top-box [STB]; Operations thereof
- H04N21/43—Processing of content or additional data, e.g. demultiplexing additional data from a digital video stream; Elementary client operations, e.g. monitoring of home network or synchronising decoder's clock; Client middleware
- H04N21/44—Processing of video elementary streams, e.g. splicing a video clip retrieved from local storage with an incoming video stream or rendering scenes according to encoded video stream scene graphs
- H04N21/44008—Processing of video elementary streams, e.g. splicing a video clip retrieved from local storage with an incoming video stream or rendering scenes according to encoded video stream scene graphs involving operations for analysing video streams, e.g. detecting features or characteristics in the video stream
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04N—PICTORIAL COMMUNICATION, e.g. TELEVISION
- H04N21/00—Selective content distribution, e.g. interactive television or video on demand [VOD]
- H04N21/40—Client devices specifically adapted for the reception of or interaction with content, e.g. set-top-box [STB]; Operations thereof
- H04N21/47—End-user applications
- H04N21/472—End-user interface for requesting content, additional data or services; End-user interface for interacting with content, e.g. for content reservation or setting reminders, for requesting event notification, for manipulating displayed content
- H04N21/47205—End-user interface for requesting content, additional data or services; End-user interface for interacting with content, e.g. for content reservation or setting reminders, for requesting event notification, for manipulating displayed content for manipulating displayed content, e.g. interacting with MPEG-4 objects, editing locally
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04N—PICTORIAL COMMUNICATION, e.g. TELEVISION
- H04N7/00—Television systems
- H04N7/18—Closed-circuit television [CCTV] systems, i.e. systems in which the video signal is not broadcast
Landscapes
- Engineering & Computer Science (AREA)
- Multimedia (AREA)
- Signal Processing (AREA)
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Theoretical Computer Science (AREA)
- Computational Linguistics (AREA)
- Software Systems (AREA)
- Databases & Information Systems (AREA)
- Human Computer Interaction (AREA)
- Image Analysis (AREA)
- Compression Or Coding Systems Of Tv Signals (AREA)
Abstract
Description
技术领域technical field
本发明涉及一种交通模式和异常行为的检测方法,特别涉及一种交通路口的视频监控的交通模式和异常行为的检测方法。The invention relates to a method for detecting traffic patterns and abnormal behaviors, in particular to a method for detecting traffic patterns and abnormal behaviors in video surveillance of traffic intersections.
背景技术Background technique
随着机器视觉和数据挖掘技术的发展,自动发现视频监控数据中的有用信息成为可能。其中,从拥挤的人、车流交通路口场景的视频数据中发现有规律的交通模式或者反常的交通行为,成为一类还未完全解决的有重要研究价值和技术应用前景的问题。解决这类问题,往往存在如下几点挑战:1)在复杂和拥挤的交通场景下,现有的基于计算机视觉跟踪的方法性能往往较差;2)交通模式与视频中的底层的特征无关,它反应了视频中的高层的语义信息,而这些信息涉及到机器视觉中的高层视觉即视觉理解问题。底层视觉特征和高层视觉语意之间往往存在着巨大的语意鸿沟,这使得基于底层视觉特征检测的方法——目标检测、目标跟踪方法无法获取整个视频的上层语义信息。具体到交通路口的交通模式检测和异常交通行为检测的问题上,由于交叉路口存在密集的人流和车流,场景容易受到噪声、光照、天气变化和复杂背景信息等的影响,基于目标检测和目标运动轨迹聚类的方法性能往往较差。With the development of machine vision and data mining technology, it becomes possible to automatically discover useful information in video surveillance data. Among them, finding regular traffic patterns or abnormal traffic behaviors from video data of crowded people and traffic intersection scenes has become a kind of problem that has not been fully solved with important research value and technical application prospects. To solve such problems, there are often the following challenges: 1) In complex and crowded traffic scenes, the performance of existing computer vision tracking methods is often poor; 2) Traffic patterns are not related to the underlying features in the video, It reflects the high-level semantic information in the video, which is related to the high-level vision in machine vision, that is, visual understanding. There is often a huge semantic gap between low-level visual features and high-level visual semantics, which makes the methods based on low-level visual feature detection—object detection and object tracking methods unable to obtain the upper-level semantic information of the entire video. Specific to the problem of traffic pattern detection and abnormal traffic behavior detection at traffic intersections, due to the dense flow of people and vehicles at intersections, the scene is easily affected by noise, illumination, weather changes and complex background information. Based on target detection and target motion Trajectory clustering methods tend to perform poorly.
为了克服上述方法的缺点,另一类直接利用视频的底层运动信息例如光流信息来获取视频场景中的“事件”或“活动”的方法逐渐流行起来。该类方法避免了对单个运动目标的跟踪,主要利用相邻的视频帧之间的丰富的局部运动信息——来自底层特征的位置和运动信息,再利用复杂的降维模型(例如主题模型)从高维的特征信息中提取有效的高层语义信息。常见的主题模型,例如PLSA(Probabilistic Latent Semantic Analysis)、LDA(Latent Dirichlet Allocation)、HDP(Hierarchical Dirichlet Process)等最初用于文本语料库中的主题发现,后来也逐渐用于图像和视频等的分析任务。王晓刚等[1]提出了一种利用层次贝叶斯模型的非监督的学习框架为复杂和拥挤的视频场景中的“事件”和“行为模式”进行建模的方法。宋等[2]提出了一种两层LDA结构的交通模式挖掘方法,该方法可以发现交通路口视频场景中的简单交通模式和复杂交通模式以及检测异常交通行为。文献[3]利用FSTM(Fully Sparse Topic Model)来进行交通视频的异常检测。文献[4]提出了一种利用HDP和HDP-HMM分别来学习交通视频中的典型活动和交通状态信息,并利用高斯过程来对交通状态信息进行分类。MCTM(Markov Clustering Topic Model)利用LDA模型对交通视频帧的底层特征——视觉词进行建模和马尔可夫链来对相邻视频帧间的时间关系进行建模。该方法可以实现将交通视觉特征层次的聚类为局部的交通模式和全局的交通模式。WS-JTM(Weakly Supervised Joint Topic Model)是一种弱监督的联合主题模型。该模型在LDA模型的基础上,充分利用了不同视频文档的类别特征对典型的交通模式和异常的交通模式进行挖掘。另一类方法主要是基于非主题模型的方法。该类方法主要利用矩阵分解、稀疏字典学习等建模方法,对底层的视觉特征进行主题建模以获取典型和异常的交通模式。In order to overcome the shortcomings of the above methods, another method that directly utilizes the underlying motion information of the video, such as optical flow information, to acquire "events" or "activities" in a video scene has gradually become popular. This class of methods avoids the tracking of a single moving target, and mainly uses the rich local motion information between adjacent video frames - the position and motion information from the underlying features, and then uses complex dimensionality reduction models (such as topic models) Extract effective high-level semantic information from high-dimensional feature information. Common topic models, such as PLSA (Probabilistic Latent Semantic Analysis), LDA (Latent Dirichlet Allocation), HDP (Hierarchical Dirichlet Process), etc., were originally used for topic discovery in text corpora, and were gradually used for image and video analysis tasks. . Wang Xiaogang et al. [1] proposed an unsupervised learning framework using Hierarchical Bayesian models to model "events" and "behavioral patterns" in complex and crowded video scenes. Song et al. [2] proposed a traffic pattern mining method with a two-layer LDA structure, which can discover simple and complex traffic patterns in video scenes of traffic intersections and detect abnormal traffic behaviors. Reference [3] uses FSTM (Fully Sparse Topic Model) to detect anomaly in traffic video. Reference [4] proposed a method to use HDP and HDP-HMM to learn the typical activity and traffic state information in traffic videos, respectively, and use Gaussian process to classify the traffic state information. MCTM (Markov Clustering Topic Model) uses the LDA model to model the underlying features of traffic video frames—visual words and Markov chains to model the temporal relationship between adjacent video frames. This method can realize the hierarchical clustering of traffic visual features into local traffic patterns and global traffic patterns. WS-JTM (Weakly Supervised Joint Topic Model) is a weakly supervised joint topic model. Based on the LDA model, the model makes full use of the category features of different video documents to mine typical traffic patterns and abnormal traffic patterns. Another class of methods is mainly based on non-topic models. This type of method mainly uses modeling methods such as matrix factorization and sparse dictionary learning to perform topic modeling on the underlying visual features to obtain typical and abnormal traffic patterns.
上述两类交通视频交通模式挖掘方法中,基于概率主题模型的方法很难获得稀疏的交通模式即视频文档中主题不是稀疏分布的。此外,基于概率主题模型的方法模型的学习和推理方法较复杂,导致算法的运算过程复杂、计算量大。基于非概率主题模型的方法由于能充分利用视觉信息中的稀疏性而被广泛用于交通视频中的典型和异常交通模式的发现,但必须事先指定主题即交通模式的数量,缺乏一定的灵活性。针对这些问题,本发明提出了一种两层结构的交通模式分析方法,第一层利用BNBP-PFA(贝塔负二项过程——泊松因子分解)主题模型来提取主题即简单的交通模式,得到每个视频文档在主题(简单交通模式)上的分布情况,第二层BNBP-PFA主题模型在第一层获得的主题的基础上获得第二层的主题即视频中的复杂交通模式。和文献[2]的两层LDA模型相比,本发明提出的方法由于采用了BNBP-PFA主题模型,每一层都不需要预先指定主题的数量。此外和LDA模型相比,由于BNBP适合处理稀疏的计数型数据,而特别适合处理视频的运动特征数据;和HDP主题模型相比,BNBP具有更好的结构形式和计算上的灵活性。Among the above two types of traffic video traffic pattern mining methods, the method based on probabilistic topic model is difficult to obtain sparse traffic patterns, that is, topics in video documents are not sparsely distributed. In addition, the learning and reasoning methods of the method model based on the probabilistic topic model are more complicated, which leads to the complex operation process of the algorithm and the large amount of calculation. The methods based on non-probabilistic topic models are widely used in the discovery of typical and abnormal traffic patterns in traffic videos because they can make full use of the sparsity in visual information. . In view of these problems, the present invention proposes a traffic pattern analysis method with a two-layer structure. The first layer uses the BNBP-PFA (negative binomial beta process-Poisson factorization) topic model to extract the topic, that is, the simple traffic pattern. The distribution of each video document on the topic (simple traffic pattern) is obtained, and the second-layer BNBP-PFA topic model obtains the second-layer topic based on the topic obtained in the first layer, that is, the complex traffic pattern in the video. Compared with the two-layer LDA model of the literature [2], the method proposed in the present invention does not need to pre-specify the number of topics in each layer because it adopts the BNBP-PFA topic model. In addition, compared with the LDA model, since BNBP is suitable for processing sparse count data, it is especially suitable for processing video motion feature data; compared with the HDP topic model, BNBP has better structural form and computational flexibility.
发明的内容content of invention
本发明的主要目的是克服现有的交通模式和异常行为的检测方法的不足,提供了一种新的基于两层BNBP-PFA主题模型的交通模式和异常行为检测的方法。该方法利用两层的BNBP-PFA主题模型来同时实现检测交通视频中的简单交通模式和复杂交通模式,和现有的方法相比具有识别的模式更多、准确率更高,能自动学习模式的数量等优点,取得了比现有方法更好的检测效果;在此基础上提出了基于两层BNBP-PFA主题模型的对数似然函数值的异常行为检测方法,取得了比现有方法更好的检测效果。The main purpose of the present invention is to overcome the shortcomings of the existing traffic pattern and abnormal behavior detection methods, and provide a new traffic pattern and abnormal behavior detection method based on a two-layer BNBP-PFA topic model. This method uses the two-layer BNBP-PFA topic model to simultaneously detect simple traffic patterns and complex traffic patterns in traffic videos. Compared with existing methods, it has more recognized patterns, higher accuracy, and can automatically learn patterns. On this basis, an abnormal behavior detection method based on the log-likelihood function value of the two-layer BNBP-PFA topic model is proposed, which has achieved better detection results than existing methods. better detection results.
本发明提出的方法,包括视频光流特征的提取和视频文档的生成、基于两层BNBP-PFA主题模型的简单交通模式和复杂交通模式检测、交通视频中异常行为的检测等技术问题。为了解决这些技术问题,本发明提供了一种交通路口视频监控的交通模式和异常行为的检测方法,所述方法包括以下步骤:The method proposed by the invention includes the extraction of video optical flow features and the generation of video documents, the detection of simple and complex traffic patterns based on the two-layer BNBP-PFA topic model, and the detection of abnormal behaviors in traffic videos. In order to solve these technical problems, the present invention provides a traffic pattern and abnormal behavior detection method for video surveillance at a traffic intersection, the method includes the following steps:
A1.将时长为T秒的长视频按照时间顺序划分为长度为Ts秒的短视频剪辑,每个视频剪辑作为一个视频文档,共得到N=T/Ts个视频文档;A1. A long video with a duration of T seconds is divided into short video clips with a length of T s seconds in chronological order, and each video clip is used as a video file, and N=T/T s video files are obtained altogether;
A2.对每个视频文档,计算其每相邻两对视频帧的光流向量;A2. For each video document, calculate the optical flow vector of every two adjacent pairs of video frames;
A3.对A2中所得的光流向量进行量化得到每个视频文档的每对视频帧的视频词;A3. quantify the optical flow vector obtained in A2 to obtain the video words of each pair of video frames of each video document;
A4.基于词袋模型,统计每个视频文档的视频词的计数向量,得到整个长视频所组成的视频文档集的文档——词计数矩阵M;A4. Based on the bag-of-words model, count the count vectors of the video words of each video document, and obtain the document-word count matrix M of the video document set composed of the entire long video;
A5.对A4中得到的视频文档利用BNBP-PFA主题模型进行主题提取,得到主题-词的分布和文档-主题的分布,所得的主题就是视频中的简单交通模式;A5. Use the BNBP-PFA topic model to extract topics from the video documents obtained in A4, and obtain topic-word distribution and document-topic distribution, and the resulting topics are the simple traffic patterns in the video;
A6.对A5中得到的主题作为新的词,将A5所得文档-主题分布作为新的文档,利用BNBP-PFA主题模型进行主题提取,得到第二层主题模型的主题-词的分布,所得的主题就是视频中的复杂交通模式;A6. Take the topic obtained in A5 as a new word, take the document-topic distribution obtained in A5 as a new document, use the BNBP-PFA topic model to extract the topic, and obtain the topic-word distribution of the second-layer topic model, the obtained The subject is the complex traffic pattern in the video;
A7.在A5和A6所得两层BNBP-PFA主题模型基础上,基于两层主题模型的对数似然函数值,检测视频帧中的异常行为。A7. Based on the two-layer BNBP-PFA topic model obtained in A5 and A6, and based on the log-likelihood function value of the two-layer topic model, detect abnormal behaviors in video frames.
上述步骤A2中的相邻两对帧的光流向量计算的过程具体包括:The process of calculating the optical flow vectors of two adjacent pairs of frames in the above step A2 specifically includes:
A21.对相邻的两个连续视频帧Ix,Iy计算每个像素点(i,j)的光流信息向量(vx(i,j),vy(i,j));A21. Calculate the optical flow information vector (v x (i, j), v y (i, j)) of each pixel (i, j) for two adjacent consecutive video frames I x and I y ;
A22.按照公式和得到每个像素点光流的强度和方向信息(M(i,j),D(i,j));A22. According to the formula and Obtain the intensity and direction information of the optical flow of each pixel point (M(i,j), D(i,j));
上述步骤A3中的对光流向量进行量化得到视频词的过程具体包括:The process of quantizing the optical flow vector to obtain video words in the above step A3 specifically includes:
A31.对光流的位置信息进行划分:将大小为Nx×Ny视频帧划分为N1×N1的像素块,总共得到个像素块(符号[*]表示取整数,N1,Nx,Ny均为正整数),用该像素块中心点的坐标作为该块的坐标;A31. Divide the position information of the optical flow: divide the video frame of size N x ×N y into N 1 ×N 1 pixel blocks, and obtain a total of pixel blocks (the symbol [*] represents an integer, N 1 , N x , N y are all positive integers), and the coordinates of the center point of the pixel block are used as the coordinates of the block;
A32.光流强度和方向的量化:每个像素块包含N1 2个像素点,将这N1 2个像素点的平均光流值作为该像素块的光流向量当该块的光流强度值超过预先设置的门限值Th即时,判定该像素块是运动像素块,否则是背景像素块;将该块的光流方向进行量化,共量化为S个方向;A32. Quantization of optical flow intensity and direction: each pixel block contains N 1 2 pixels, and the average optical flow value of these N 1 2 pixels is used as the optical flow vector of the pixel block When the optical flow intensity value of the block exceeds the preset threshold Th, that is, When , determine that the pixel block is a motion pixel block, otherwise it is a background pixel block; quantize the optical flow direction of the block, and quantize it into S directions in total;
A33.按照上述量化方法,可以得到的视频文档集的词汇表的大小为 A33. According to the above quantification method, the size of the vocabulary of the video document set that can be obtained is:
上述步骤A5具体包括:The above-mentioned step A5 specifically includes:
假设A4中所得的文档计数矩阵为Mij∈RP×N,该计数矩阵包含N个文档的P个特征。按照公式mijk~Pois(φikθkj),φk~Dir(αφ,…,αφ),θkj~Gamma(rk,pk/(1-pk)),rk~Gamma(c0r0,1/c0),pk~Beta(cε,c(1-ε))的BNBP-PFA主题建模过程,可以得到K个主题分布矩阵Φ∈RP×K和K个主题在N个文档中的组成情况矩阵Θ∈RK×N,其中主题分布矩阵表示K个主题在P个特征上的分布情况。Assuming that the resulting document count matrix in A4 is M ij ∈ R P×N , the count matrix contains P features of N documents. According to the formula m ijk ~Pois(φ ik θ kj ), φ k ~Dir(α φ ,…,α φ ), θ kj ~Gamma(r k ,p k /(1-p k )), r k ~Gamma(c 0 r 0 ,1/c 0 ), p k ~Beta(cε,c(1-ε)) BNBP-PFA topic modeling process, K topic distribution matrices Φ∈R P×K and K topics can be obtained The composition matrix Θ∈R K×N in N documents, where the topic distribution matrix represents the distribution of K topics on P features.
上述步骤A6具体包括:The above-mentioned step A6 specifically includes:
将步骤A5中所得的主题φik当作步骤A6中的词,A6中的文档——词的分布θkj就看作是由A5中的主题组成的。按照公式θkjk′~Pois(φ′kk′θ′k′j),φ′k′~Dir(α′φ′,…,α′φ′),θ′k′j~Gamma(r′k′,p′k′/(1-p′k′)),r′k′~Gamma(c′0r′0,1/c′0),p′k′~Beta(c′ε′,c′(1-ε′))的BNBP-PFA主题建模过程,可以得到K′个主题——词分布φ′kk′和文档——主题的分布θ′k′j。The topic φ ik obtained in step A5 is regarded as the word in step A6, and the document-word distribution θ kj in A6 is regarded as composed of the topics in A5. According to the formula θ kjk′ ~Pois(φ′ kk′ θ′ k′j ), φ′ k′ ~Dir(α′ φ′ ,…,α′ φ′ ), θ′ k′j ~Gamma(r′ k′ , p′ k′ /(1-p′ k′ )), r′ k′ ~Gamma(c′ 0 r′ 0 ,1/c′ 0 ), p′ k′ ~Beta(c′ε′,c′ (1-ε′)) BNBP-PFA topic modeling process, K′ topic-word distribution φ′ kk′ and document-topic distribution θ′ k′j can be obtained.
上述步骤A7具体包括:The above-mentioned step A7 specifically includes:
A71.在整个视频文档集的文档——视觉词计数矩阵M上,随机选择80%的视频文档组成训练视频文档集X,剩下的20%的视频文档集组成测试集Y=M-X;A71. On the document-visual word count matrix M of the entire video document set, randomly select 80% of the video documents to form the training video document set X, and the remaining 20% of the video document set form the test set Y=M-X;
A72.在测试集Y上,按照公式(其中ypi=Y(p,i),φpk是第一层BNBP-PFA主题模型所得主题分布,θki是视频帧ypi在主题φpk上的分布的系数,N1是视频帧ypi长度即其包含的视觉词的数量),计算每个视频帧ypi在第一层BNBP-PFA主题模型上的归一化的似然函数值F1;A72. On the test set Y, according to the formula (in y pi = Y(p,i), φ pk is the topic distribution obtained by the first-layer BNBP-PFA topic model, θ ki is the coefficient of the distribution of video frame y pi on topic φ pk , N 1 is the length of video frame y pi That is, the number of visual words it contains), calculate the normalized likelihood function value F 1 of each video frame y pi on the first-layer BNBP-PFA topic model;
A73.按照公式(其中θki是视频帧ypi在主题φpk上的分布的系数,φ′kk′是第二层BNBP-PFA主题模型所得主题分布,θ′k′i是θki在主题φ′kk′上的分布的系数,N2是θki向量的长度即其包含的主题φpk的数量),计算每个视频帧ypi在主题φpk上的分布的系数θki在第二层BNBP-PFA主题模型上的归一化的似然函数值F2;A73. According to the formula (in θ ki is the coefficient of the distribution of video frame y pi on the topic φ pk , φ′ kk′ is the topic distribution obtained by the second-layer BNBP -PFA topic model, θ′ k′ i is the distribution of θ ki on the topic φ′ kk′ Coefficient of distribution, N 2 is the length of the θ ki vector (that is, the number of topics φ pk it contains), calculate the coefficient θ ki of the distribution of each video frame y pi on the topic φ pk in the second-layer BNBP-PFA topic model The normalized likelihood function value F 2 on ;
A74.计算视频帧ypi在两层BNBP-PFA主题模型上的加权似然函数值F=η·F1+(1-η)·F2,其中取参数η∈(0,1);A74. Calculate the weighted likelihood function value F=η·F 1 +(1-η)·F 2 of the video frame y pi on the two-layer BNBP-PFA topic model, where the parameter η∈(0,1) is taken;
A75.将A74中计算得到的似然函数值F和给定的门限值Th1进行比较,如果有F<Th1,则视频帧ypi中包含有异常行为,否则没有。A75. Compare the likelihood function value F calculated in A74 with the given threshold value Th 1 , if there is F<Th 1 , the video frame y pi contains abnormal behavior, otherwise it does not.
本发明提供的实施例的有益效果:The beneficial effects of the embodiments provided by the present invention:
本发明将主题模型应用于交通视频场景的理解和分析,发明了一种既能检测交通视频场景中的简单交通模式和复杂交通模式又能检测异常交通行为的方法。本发明的方法和现有方法相比其发现的交通模式更多、质量更高。此外,由于采用了非参数化的主题模型,本发明的方法不需要事先指定主题的数量,这在处理一些复杂的、未知的交通视频数据时非常有用。本发明所提出的方法可以应用于交通视频中交通模式的挖掘和异常交通行为的检测,对智慧交通以及交通视频监控等领域的发展具有重要意义。The present invention applies the subject model to the understanding and analysis of traffic video scenes, and invents a method that can detect both simple traffic patterns and complex traffic patterns in traffic video scenes and abnormal traffic behaviors. Compared with existing methods, the method of the present invention finds more traffic patterns and is of higher quality. In addition, due to the use of a non-parametric topic model, the method of the present invention does not need to specify the number of topics in advance, which is very useful when dealing with some complex and unknown traffic video data. The method proposed in the present invention can be applied to the mining of traffic patterns in traffic videos and the detection of abnormal traffic behaviors, which is of great significance to the development of intelligent traffic and traffic video monitoring and other fields.
附图说明Description of drawings
图1为本发明一种交通路口视频监控的交通模式和异常行为的检测方法具体实施例的流程图;1 is a flowchart of a specific embodiment of a method for detecting traffic patterns and abnormal behaviors in a traffic intersection video surveillance of the present invention;
图2为本实施例中所用数据集的样例帧;Fig. 2 is the sample frame of the data set used in this embodiment;
图3为本实施例中本发明方法在视频数据集中发现的第一层主题即简单交通模式;FIG. 3 is the first-level theme found in the video data set by the method of the present invention in this embodiment, namely the simple traffic pattern;
图4为本实施例中LDA方法在视频数据集中发现的15个主题;Fig. 4 finds 15 topics in the video data set by LDA method in this embodiment;
图5为本实施例中FTM方法在视频数据集中发现的15个主题;5 is the 15 topics found in the video dataset by the FTM method in this embodiment;
图6为本实施例中HDP方法在视频数据集中发现的15个主题;FIG. 6 is the 15 topics found in the video dataset by the HDP method in this embodiment;
图7为本实施例中本发明方法在视频数据集中发现的第二层主题即复杂交通模式;FIG. 7 is the second-layer theme found in the video data set by the method of the present invention in the present embodiment, that is, the complex traffic pattern;
图8为本实施例中本发明的方法在视频数据集上检测到的4种异常交通行为;FIG. 8 is four abnormal traffic behaviors detected on the video data set by the method of the present invention in this embodiment;
具体实施方式Detailed ways
下面结合附图和实施例,对本发明的具体实施方式做进一步的详细描述。下面通过参考附图描述的实施例是示例性的,仅用于解释本发明,而不能解释为对本发明的限制。The specific embodiments of the present invention will be described in further detail below with reference to the accompanying drawings and embodiments. The embodiments described below with reference to the accompanying drawings are exemplary and are only used to explain the present invention, but not to be construed as a limitation of the present invention.
图1为本发明一种交通路口视频监控的交通模式和异常行为的检测方法具体实施例的流程图。如图1所示,本实施例交通模式和异常行为的检测方法的工作流程包括如下步骤:FIG. 1 is a flow chart of a specific embodiment of a method for detecting traffic patterns and abnormal behaviors in a video surveillance of a traffic intersection according to the present invention. As shown in FIG. 1 , the workflow of the method for detecting traffic patterns and abnormal behaviors in this embodiment includes the following steps:
A1:将时长为T秒的长视频按照时间顺序划分为长度为Ts秒的短视频剪辑,每个视频剪辑作为一个视频文档,共得到N1=T/Ts个视频文档。A1: Divide a long video with a duration of T seconds into short video clips with a length of T s seconds in chronological order. Each video clip is regarded as a video file, and a total of N 1 =T/T s video files are obtained.
在本步骤中,通过计算机下载QMUL Junction Dataset 2数据集公开的交通路口视频数据(http://www.eecs.qmul.ac.uk/~tmh/downloads.html)作为本发明的实施例的视频数据。该数据集包含一个时长为52分钟,帧率为25Hz,每帧大小为360×288像素的繁忙的城市交通路口视频。该数据集的样例帧如图2所示,包含6个运动模式如表1所示。该数据集共包含4种异常行为。该视频数据总长度为3120秒,其中取一个视频文档的长度为12秒视频(总共300视频帧),则共得到260个视频文档后,进入步骤A2。In this step, the traffic intersection video data (http://www.eecs.qmul.ac.uk/~tmh/downloads.html) disclosed by the
表1 图2中QMUL Junction Dataset 2数据集中包含的可能的运动模式及其描述(分上、下、左、右四个方向)Table 1 The possible motion patterns included in the
A2:对每个视频文档,计算其每相邻两对视频帧的光流向量。A2: For each video document, calculate the optical flow vector of every two adjacent pairs of video frames.
在本步骤中,对每个视频文档所包含的300个视频帧,从第二帧开始,按照时间先后顺序依次计算该帧Ix和相邻的前一帧Iy之间的在每个像素点(i,j)上的光流向量(vx(i,j),vy(i,j)),这里的光流计算采用标准的Lucas-Kanade光流计算方法。然后按照公式和计算得到每个像素点(i,j)光流的强度和方向矩阵(M(i,j),D(i,j))。In this step, for the 300 video frames included in each video document, starting from the second frame, calculate the distance between the frame I x and the adjacent previous frame I y in each pixel in chronological order. The optical flow vector (v x (i, j), v y (i, j)) at point (i, j), where the optical flow calculation adopts the standard Lucas-Kanade optical flow calculation method. Then follow the formula and The intensity and direction matrix (M(i,j), D(i,j)) of each pixel (i,j) optical flow is calculated.
A3:对A2中所得的光流向量(M(i,j),D(i,j))进行量化得到每个视频文档的每对视频帧的视频词。A3: Quantize the optical flow vector (M(i,j), D(i,j)) obtained in A2 to obtain the video words of each pair of video frames of each video document.
在本步骤中,对光流的位置信息、强度和方向分别进行量化,具体包括三个子步骤:In this step, the position information, intensity and direction of the optical flow are quantified respectively, which specifically includes three sub-steps:
1)将大小为360×288像素的视频帧划分为8×8的像素块,总共得到1620个像素块,用每个像素块中心点的坐标作为该块的坐标;1) The video frame with a size of 360×288 pixels is divided into 8×8 pixel blocks, 1620 pixel blocks are obtained in total, and the coordinates of the center point of each pixel block are used as the coordinates of the block;
2)光流强度和方向的量化:将每个像素块包含的64个像素点的平均光流值作为该像素块的光流向量当该块的光流强度值超过预先设置的门限值Th=0.05即时,判定该像素块是运动像素块,否则是背景像素块;将该块的光流方向进行量化,共量化为上、下、左、右共4个方向;2) Quantization of optical flow intensity and direction: take the average optical flow value of 64 pixels contained in each pixel block as the optical flow vector of the pixel block When the optical flow intensity value of the block exceeds the preset threshold Th=0.05, that is When , it is determined that the pixel block is a motion pixel block, otherwise it is a background pixel block; the optical flow direction of the block is quantized, and a total of 4 directions of up, down, left, and right are quantized;
3)按照上述量化方法,可以得到每个视频文档集的词汇表的大小为6480。3) According to the above quantization method, the size of the vocabulary of each video document set can be obtained as 6480.
A4.基于词袋模型,统计每个视频文档的视频词的计数向量,得到整个视频数据集所组成的视频文档集的文档——词计数矩阵M260*6480;A4. Based on the bag-of-words model, count the count vectors of the video words of each video document, and obtain the document of the video document set composed of the entire video data set—word count matrix M 260*6480 ;
A5.对A4中得到的视频文档矩阵M260*6480利用BNBP-PFA主题模型进行主题提取,得到主题-词的分布Φ和文档-主题的分布Θ,所得的主题就是视频中的简单交通模式;A5. Use the BNBP-PFA topic model to extract the subject of the video document matrix M 260*6480 obtained in A4, and obtain the distribution Φ of the subject-word and the distribution Θ of the document-theme, and the obtained subject is the simple traffic pattern in the video;
上述步骤A5具体包括:The above-mentioned step A5 specifically includes:
假设A4中所得的文档计数矩阵为Mij∈R6480×260,该计数矩阵包含260个文档的6480个特征。按照公式mijk~Pois(φikθkj),φk~Dir(αφ,…,αφ),θkj~Gamma(rk,pk/(1-pk)),rk~Gamma(c0r0,1/c0),pk~Beta(cε,c(1-ε))的BNBP-PFA主题建模过程,按照如下的利用常用的马尔科夫链蒙特卡洛推理算法,可以得到上述BNBP-PFA主题模型的概率分布φk、θkj和相关参数rk和pk。具体推理算法如下:Suppose the resulting document count matrix in A4 is M ij ∈ R 6480×260 , which contains 6480 features for 260 documents. According to the formula m ijk ~Pois(φ ik θ kj ), φ k ~Dir(α φ ,…,α φ ), θ kj ~Gamma(r k ,p k /(1-p k )), r k ~Gamma(c 0 r 0 ,1/c 0 ), p k ~ Beta(cε,c(1-ε)) BNBP-PFA topic modeling process, according to the following using the commonly used Markov chain Monte Carlo reasoning algorithm, you can The probability distributions φ k , θ kj and related parameters r k and p k of the above BNBP-PFA topic model are obtained. The specific reasoning algorithm is as follows:
1)记主题数量K的上界由cγαB(cε,c(1-ε))确定,其中P=6480,N=260,c=1,γ=1,α=1,ε=0.05;1) Note The upper bound of the number of topics K is determined by cγαB(cε,c(1-ε)), where P=6480, N=260, c=1, γ=1, α=1, ε=0.05;
2)按照下面的公式(1)采样得到mijk;2) sample m ijk according to the following formula (1);
[mij1,…,mijK]~Mult(mij;ζij1,…,ζijK) (1)[m ij1 ,…,m ijK ] ~Mult(m ij ;ζ ij1 ,…,ζ ijK ) (1)
3)利用泊松分布和多项式分布之间的关系,以及关系式可知p([m1jk,…,mpjk]|-)=Mult(m·jk;φk),则可按照下面式(2)采样得到φk;3) Use the relationship between Poisson distribution and multinomial distribution, and the relationship It can be known that p([m 1jk ,...,m pjk ]|-)=Mult(m ·jk ; φ k ), then φ k can be obtained by sampling according to the following formula (2);
p(φk|-)~Dir(αφ+m1·k,…,αφ+mP·k) (2)p(φ k |-)~Dir(α φ +m 1·k ,…,α φ +m P·k ) (2)
4)边缘化φk和θkj后,m·jk~NB(rk,pk),pk~Beta(cε,c(1-ε)),则pk可按下式(3)采样得到;4) After marginalizing φ k and θ kj , m ·jk ~NB(r k ,p k ), p k ~Beta(cε,c(1-ε)), then p k can be sampled by the following formula (3) get;
p(pk|-)~Beta(cε+m··k,c(1-ε)+Nrk) (3)p(p k |-)~Beta(cε+m ··k ,c(1-ε)+Nr k ) (3)
5)由于则可以按照下式(4)来采样得到rk。5) Due to Then, r k can be obtained by sampling according to the following formula (4).
可以得到K=15个主题分布矩阵Φ∈RP×K和K=15个主题在N=260个文档中的组成情况矩阵Θ∈RK×N,其中主题分布矩阵表示K=15个主题在P=6480个特征上的分布情况。所得的主题就是视频中的简单交通模式如图3所示,作为和本发明的方法所得实验结果的比对,图4-图6分别给出了LDA方法[4]、HDP方法[1]和FTM方法[3]在QMUL Junction Dataset 2数据集上获得的K=15个典型主题。从图3-图6所示的结果中可知,除了HDP方法只能检测出5种模式其中包含正确的4种外,其它三个方法均能正确的检测所有有效运动模式。从以上实验结果分析可得,HDP方法在四种模型中所得结果最差,本发明的方法所得结果最好,LDA方法和FTM方法的性能相差不大。另外从图3-图6的实验结果上来看,四种方法产生的主题质量按照本发明的方法、FTM方法、LDA方法、HDP方法的顺序依次降低。The composition matrix Θ∈R K×N of K=15 topic distribution matrix Φ∈R P×K and K=15 topics in N=260 documents can be obtained, wherein the topic distribution matrix represents K=15 topics in P = distribution over 6480 features. The obtained theme is the simple traffic pattern in the video as shown in Figure 3. As a comparison with the experimental results obtained by the method of the present invention, Figures 4 to 6 show the LDA method [4] , HDP method [1] and K=15 typical topics obtained by FTM method [3] on
A6.对A5中得到的主题分布Φ作为新的词,将A5所得文档-主题分布Θ作为新的文档,利用BNBP-PFA主题模型进行主题提取,得到第二层主题模型的主题-词的分布Φ’,所得的主题就是视频中的复杂交通模式;A6. Take the topic distribution Φ obtained in A5 as a new word, take the document-topic distribution Θ obtained in A5 as a new document, use the BNBP-PFA topic model to extract topics, and obtain the topic-word distribution of the second-layer topic model Φ', the resulting theme is the complex traffic pattern in the video;
上述步骤A6具体包括:The above-mentioned step A6 specifically includes:
将步骤A5中所得的15个主题φik的分布当作A6中的词,A6中的文档——词的分布θkj就看作是由A5中的主题组成的。按照公式θkjk′~Pois(φ′kk′θ′k′j),φ′k′~Dir(α′φ′,…,α′φ′),θ′k′j~Gamma(r′k′,p′k′/(1-p′k′)),r′k′~Gamma(c′0r′0,1/c′0),p′k′~Beta(c′ε′,c′(1-ε′))的BNBP-PFA主题建模过程,可以得到K′=3个主题——词分布φ′kk′和260个文档——主题的分布θ′k′j。按照如下的利用常用的马尔科夫链蒙特卡洛推理算法,可以得到上述BNBP-PFA主题模型的概率分布φ′k′、θ′k′j和相关参数r′k′和p′k′。具体推理算法如下:The distribution of the 15 topics φ ik obtained in step A5 is regarded as the words in A6, and the document-word distribution θ kj in A6 is regarded as composed of the topics in A5. According to the formula θ kjk′ ~Pois(φ′ kk′ θ′ k′j ), φ′ k′ ~Dir(α′ φ′ ,…,α′ φ′ ), θ′ k′j ~Gamma(r′ k′ , p′ k′ /(1-p′ k′ )), r′ k′ ~Gamma(c′ 0 r′ 0 ,1/c′ 0 ), p′ k′ ~Beta(c′ε′,c′ (1-ε′)) BNBP-PFA topic modeling process, we can get K′=3 topics—word distribution φ′ kk′ and 260 documents—topic distribution θ′ k′j . The probability distributions φ′ k′ , θ′ k′j and related parameters r′ k′ and p′ k′ of the above-mentioned BNBP-PFA topic model can be obtained as follows using the commonly used Markov chain Monte Carlo inference algorithm. The specific reasoning algorithm is as follows:
1)记主题数量K′的上界由c′γ′α′B(c′ε′,c′(1-ε′))确定,其中K=15,N=260,c'=1,γ'=1,α'=1,ε'=0.05;1) Note The upper bound of the number of topics K' is determined by c'γ'α'B(c'ε',c'(1-ε')), where K=15, N=260, c'=1, γ'=1 , α'=1, ε'=0.05;
2)按照下面的公式(5)采样得到θkjk′;2) obtain θ kjk′ by sampling according to the following formula (5);
[θkj1,…,θkjK′]~Mult(θkj;ζ′kj1,…,ζ′kjK′) (5)[θ kj1 ,…,θ kjK′ ]~Mult(θ kj ;ζ′ kj1 ,…,ζ′ kjK′ ) (5)
3)利用泊松分布和多项式分布之间的关系,以及关系式可知p([θ1jk′,…,θkjk′]|-)=Mult(θ·jk′;φ′k′),则可按照下面式(6)采样得到φ′k′;3) Use the relationship between Poisson distribution and multinomial distribution, and the relationship It can be known that p([θ 1jk′ ,...,θ kjk′ ]|-)=Mult(θ ·jk′ ; φ′ k′ ), then φ′ k ′ can be obtained by sampling according to the following formula (6);
p(φ′k′|-)~Dir(α′φ′+θ1·k′,…,α′φ′+θK·k′) (6)p(φ′ k′ |-)~Dir(α′ φ′ +θ 1·k′ ,…,α′ φ′ +θ K·k′ ) (6)
4)边缘化φ′k′和θ′k′j后,θ·jk′~NB(r′k′,p′k′),p′k′~Beta(c′ε′,c′(1-ε′)),则p′k′可按下式(7)采样得到;4) After marginalizing φ′ k′ and θ′ k′j , θ ·jk′ ~NB(r′k′,p′k ′ ), p′k ′ ~Beta(c′ε′,c′(1 -ε′)), then p′ k′ can be sampled by the following formula (7);
p(p′k′|-)~Beta(c′ε′+θ··k′,c′(1-ε′)+N′r′k′) (7)p(p′ k′ |-)~Beta(c′ε′+θ ··k′ ,c′(1-ε′)+N′r′ k′ ) (7)
5)由于则可以按照下式(8)来采样得到r′k′。5) Due to Then, r'k' can be obtained by sampling according to the following formula (8).
可以得到K′=3个主题分布矩阵Φ'∈RK×K'和K′=3个主题在N=260个文档中的组成情况矩阵Θ'∈RK'×N,其中主题分布矩阵表示K′=3个主题在K=15个子主题(即简单交通模式)上的分布情况。A6中所得的主题就是视频中的复杂交通模式如图7所示。和文献[2]中的方法仅能得到左右和上下两个大的方向的复杂交通模式相比,本发明所提出的方法可以获得更多的详细的复杂交通模式。下表2给出了本发明的方法在QMUL Junction Dataset 2数据集上的所获得的3种交通模式的主题组成和交通流状态的说明。K'=3 topic distribution matrices Φ'∈R K×K' and K'=3 topics in N=260 documents composition matrix Θ'∈R K'×N , where topic distribution matrix represents K' = distribution of 3 topics on K = 15 subtopics (ie simple traffic patterns). The resulting theme in A6 is the complex traffic pattern in the video as shown in Figure 7. Compared with the method in document [2], which can only obtain complex traffic patterns in two major directions, left and right and up and down, the method proposed in the present invention can obtain more detailed complex traffic patterns. Table 2 below gives the description of the subject composition and traffic flow state of the three traffic modes obtained by the method of the present invention on the
表2 QMUL Junction Dataset 2数据集上的3种交通模式的主题组成和交通流状态说明Table 2 The topic composition and traffic flow state descriptions of 3 traffic modes on
A7.在A5和A6所得两层BNBP-PFA主题模型基础上,基于两层主题模型的对数似然函数值,检测视频帧中的异常行为。A7. Based on the two-layer BNBP-PFA topic model obtained in A5 and A6, and based on the log-likelihood function value of the two-layer topic model, detect abnormal behaviors in video frames.
上述步骤A7具体包括:The above-mentioned step A7 specifically includes:
A71.在整个视频文档集的文档——视觉词计数矩阵M260×6480上,随机选择80%的视频文档组成训练视频文档集X,剩下的20%的视频文档集组成测试集Y=M-X;A71. On the document of the entire video document set—the visual word count matrix M 260×6480 , randomly select 80% of the video documents to form the training video document set X, and the remaining 20% of the video document set form the test set Y=MX ;
A72.在测试集Y上,按照公式(其中ypi=Y(p,i),φpk是第一层BNBP-PFA主题模型所得主题分布,θki是视频帧ypi在主题φpk上的分布的系数,N1=6480是视频帧ypi长度即其包含的视觉词的数量),计算每个视频帧ypi在第一层BNBP-PFA主题模型上的归一化的似然函数值F1;A72. On the test set Y, according to the formula (in y pi =Y(p,i), φ pk is the topic distribution obtained by the first-layer BNBP-PFA topic model, θ ki is the coefficient of the distribution of video frame y pi on the topic φ pk , N 1 =6480 is the video frame y The length of pi is the number of visual words it contains), calculate the normalized likelihood function value F 1 of each video frame y pi on the first-layer BNBP-PFA topic model;
A73.按照公式(其中θki是视频帧ypi在主题φpk上的分布的系数,φ′kk′是第二层BNBP-PFA主题模型所得主题分布,θ′k′i是θki在主题φ′kk′上的分布的系数,N2=15是θki向量的长度即其包含的主题φpk的数量),计算每个视频帧ypi在主题φpk上的分布的系数θki在第二层BNBP-PFA主题模型上的归一化的似然函数值F2;A73. According to the formula (in θ ki is the coefficient of the distribution of video frame y pi on the topic φ pk , φ′ kk′ is the topic distribution obtained by the second-layer BNBP -PFA topic model, θ′ k′ i is the distribution of θ ki on the topic φ′ kk′ The coefficient of distribution, N 2 =15 is the length of the θ ki vector (that is, the number of topics φ pk it contains), and the coefficient θ ki of the distribution of each video frame y pi on the topic φ pk is calculated in the second layer BNBP-PFA the normalized likelihood function value F 2 on the topic model;
A74.计算视频帧ypi在两层BNBP-PFA主题模型上的加权似然函数值F=η·F1+(1-η)·F2,其中取参数η=0.5;A74. Calculate the weighted likelihood function value F=η·F 1 +(1-η)·F 2 of the video frame y pi on the two-layer BNBP-PFA topic model, where the parameter η=0.5;
A75.将A74中计算得到的似然函数值F和给定的门限值Th1=0.1进行比较,如果有F<Th1,则视频帧ypi中包含有异常行为,否则没有。A75. Compare the likelihood function value F calculated in A74 with the given threshold value Th 1 =0.1, if there is F<Th 1 , the video frame y pi contains abnormal behavior, otherwise it does not.
对测试数据集上的每个视频文档进行检测,可以得出包含异常交通行为的视频帧。在图8中,本发明的方法在QMUL Junction Dataset 2数据集上检测到的4种异常交通行为分别为:(1)行人不走斑马线横穿马路,(2)行人人行道上过马路闯红灯,(3)车辆在交叉路口中间变道,(4)车辆从两车之间穿行。图8中用红色的框标出了异常行为发生的对象及位置。Detecting each video document on the test dataset yields video frames that contain anomalous traffic behaviors. In Figure 8, the four abnormal traffic behaviors detected by the method of the present invention on the
为了定量的评价本发明提出的异常交通行为检测方法的性能,将本发明提出的方法和文献[6]中的MCTM方法和LDA方法进行对比实验。为了对比实验的方便,MCTM方法和LDA方法在QMUL Junction Dataset 2数据集上异常交通行为检测的数据直接引用文献[6]中的结果。由于在QMUL Junction Dataset 2数据集上图5中所示的异常行为模式(3)和(4)出现较少,且MCTM方法仅粗略的检测了2种行人的异常交通模式即对应于图5中的异常行为(1)和(2),故本发明仅采用2种异常行为的数据来进行对比实验。下表3分别给出了本发明的异常检测方法、MCTM和LDA方法在QMUL Junction Dataset 2数据集上的实验结果。In order to quantitatively evaluate the performance of the abnormal traffic behavior detection method proposed by the present invention, the method proposed by the present invention is compared with the MCTM method and the LDA method in the literature [6]. For the convenience of comparison experiments, the data of abnormal traffic behavior detection by the MCTM method and the LDA method on the
表3 各种方法在QMUL Junction Dataset 2数据集上异常检测性能比较实验结果Table 3. Experimental results of anomaly detection performance comparison of various methods on
从表3的实验结果可知,在QMUL Junction Dataset 2数据集上,本发明提出的异常交通行为检测方法在行人横穿马路和行人闯红灯两种异常行为检测上均获得最好的结果,总TPR(真正率)获得最大值而总FPR(假正率)获得最小值。综上所述,本发明的方法在QMUL Junction Dataset 2数据集上获得了比MCTM和LDA方法更好的异常行为检测能力。It can be seen from the experimental results in Table 3 that on the
以上所述仅是本发明的部分实施方式,应当指出,对于本技术领域的普通技术人员来说,在不脱离本发明原理的前提下,还可以做出若干改进和润饰,这些改进和润饰也应视为本发明的保护范围。The above are only some embodiments of the present invention. It should be pointed out that for those skilled in the art, without departing from the principles of the present invention, several improvements and modifications can be made. It should be regarded as the protection scope of the present invention.
参考文献references
[1]X.Wang,X.Ma,E.Grimson,Unsupervised activity perception byhierarchical Bayesian models,in:IEEE Conference on Computer Vision andPattern Recognition,2007,pp.1–8.[1] X. Wang, X. Ma, E. Grimson, Unsupervised activity perception byhierarchical Bayesian models, in: IEEE Conference on Computer Vision and Pattern Recognition, 2007, pp. 1–8.
[2]L.Song,F.Jiang,Z.Shi,A.Katsaggelos,“Understanding dynamic scenesby hierarchical motion pattern mining”,IEEE International Conference onMultimedia and Expo(ICME),pp.1–6,2011.[2] L. Song, F. Jiang, Z. Shi, A. Katsaggelos, "Understanding dynamic scenes by hierarchical motion pattern mining", IEEE International Conference on Multimedia and Expo (ICME), pp.1–6, 2011.
[3]K.Than,and T.B.Ho,"Fully sparse topic models",Proceedings of theEuropean conference on Machine Learning and Knowledge Discovery in Databases-Volume Part I,2012.[3] K. Than, and T.B. Ho, "Fully sparse topic models", Proceedings of the European conference on Machine Learning and Knowledge Discovery in Databases-Volume Part I, 2012.
[4]Liao W,Rosenhahn B,Yang M Y.Video Event Recognition by CombiningHDP and Gaussian Process[C].IEEE International Conference on Computer VisionWorkshop.IEEE,2015:166-174.[4] Liao W, Rosenhahn B, Yang M Y. Video Event Recognition by CombiningHDP and Gaussian Process[C].IEEE International Conference on Computer VisionWorkshop.IEEE,2015:166-174.
[5]Blei D M,Ng A Y,Jordan M I.Latent dirichlet allocation[J].Journalof Machine Learning Research,2003,3:993-1022.[5] Blei D M, Ng A Y, Jordan M I. Latent dirichlet allocation[J]. Journal of Machine Learning Research, 2003, 3:993-1022.
[6]T.Hospedales,S.Gong and T.Xiang,“A Markov Clustering Topic Modelfor Mining Behaviour in Video,”in Proc.Int’l.Conf.Computer Vision,pp.1165-1172,2009.[6] T.Hospedales, S.Gong and T.Xiang, "A Markov Clustering Topic Model for Mining Behaviour in Video," in Proc.Int'l.Conf.Computer Vision, pp.1165-1172, 2009.
Claims (6)
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201711030491.4A CN107832688B (en) | 2017-10-27 | 2017-10-27 | A traffic pattern and abnormal behavior detection method for video surveillance of traffic intersections |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201711030491.4A CN107832688B (en) | 2017-10-27 | 2017-10-27 | A traffic pattern and abnormal behavior detection method for video surveillance of traffic intersections |
Publications (2)
Publication Number | Publication Date |
---|---|
CN107832688A CN107832688A (en) | 2018-03-23 |
CN107832688B true CN107832688B (en) | 2020-08-11 |
Family
ID=61649930
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201711030491.4A Expired - Fee Related CN107832688B (en) | 2017-10-27 | 2017-10-27 | A traffic pattern and abnormal behavior detection method for video surveillance of traffic intersections |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN107832688B (en) |
Families Citing this family (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN109034062B (en) * | 2018-07-26 | 2023-05-16 | 南京邮电大学 | A Weakly Supervised Abnormal Behavior Detection Method Based on Temporal Consistency |
CN110070003B (en) * | 2019-04-01 | 2021-07-30 | 浙江大华技术股份有限公司 | Abnormal behavior detection and optical flow autocorrelation determination method and related device |
CN111104792B (en) * | 2019-12-13 | 2023-05-23 | 浙江工业大学 | Traffic track data semantic analysis and visualization method based on topic model |
CN112164223B (en) * | 2020-02-27 | 2022-04-29 | 浙江恒隆智慧科技集团有限公司 | Intelligent traffic information processing method and device based on cloud platform |
CN114218610B (en) * | 2021-11-24 | 2023-02-14 | 南京信息职业技术学院 | Multi-dense block detection and extraction method based on Possion distribution |
Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
EP2226012B1 (en) * | 2007-12-20 | 2012-06-20 | Gifu University | Image processing apparatus, image processing program, storage medium, and ultrasonic diagnostic apparatus |
CN103136540A (en) * | 2013-03-19 | 2013-06-05 | 中国科学院自动化研究所 | Behavior recognition method based on concealed structure reasoning |
CN104820824A (en) * | 2015-04-23 | 2015-08-05 | 南京邮电大学 | Local abnormal behavior detection method based on optical flow and space-time gradient |
CN106548153A (en) * | 2016-10-27 | 2017-03-29 | 杭州电子科技大学 | Video abnormality detection method based on graph structure under multi-scale transform |
CN107220607A (en) * | 2017-05-22 | 2017-09-29 | 西安电子科技大学 | Movement locus Activity recognition method based on 3D stationary wavelets |
-
2017
- 2017-10-27 CN CN201711030491.4A patent/CN107832688B/en not_active Expired - Fee Related
Patent Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
EP2226012B1 (en) * | 2007-12-20 | 2012-06-20 | Gifu University | Image processing apparatus, image processing program, storage medium, and ultrasonic diagnostic apparatus |
CN103136540A (en) * | 2013-03-19 | 2013-06-05 | 中国科学院自动化研究所 | Behavior recognition method based on concealed structure reasoning |
CN104820824A (en) * | 2015-04-23 | 2015-08-05 | 南京邮电大学 | Local abnormal behavior detection method based on optical flow and space-time gradient |
CN106548153A (en) * | 2016-10-27 | 2017-03-29 | 杭州电子科技大学 | Video abnormality detection method based on graph structure under multi-scale transform |
CN107220607A (en) * | 2017-05-22 | 2017-09-29 | 西安电子科技大学 | Movement locus Activity recognition method based on 3D stationary wavelets |
Non-Patent Citations (4)
Title |
---|
Houkui Zhou.Topic Evolution based on the Probabilistic.《Frontiers of Computer Science》.2017, * |
Nonparametric Bayesian Negative Binomial Factor Analysis;Mingyuan Zhou;《arxiv.org》;20160415;全文 * |
Unsupervised Activity Perception by Hierarchinal Bayesian Models;X.Wang;《IEEE Conference on Computer Vision and Pattern Recognition》;20071231;全文 * |
基于视频的客流检测与分析算法研究及其在交通枢纽站中的应用;刘敬禹;《中国优秀硕士论文全文数据库信息科技辑》;20160615;全文 * |
Also Published As
Publication number | Publication date |
---|---|
CN107832688A (en) | 2018-03-23 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN107832688B (en) | A traffic pattern and abnormal behavior detection method for video surveillance of traffic intersections | |
Zhou et al. | Spatial–temporal convolutional neural networks for anomaly detection and localization in crowded scenes | |
Singh et al. | Deep spatio-temporal representation for detection of road accidents using stacked autoencoder | |
Sreenu et al. | Intelligent video surveillance: a review through deep learning techniques for crowd analysis | |
Santhosh et al. | Anomaly detection in road traffic using visual surveillance: A survey | |
Jia et al. | Real‐time automatic helmet detection of motorcyclists in urban traffic using improved YOLOv5 detector | |
Fenil et al. | Real time violence detection framework for football stadium comprising of big data analysis and deep learning through bidirectional LSTM | |
Wu et al. | An explainable and efficient deep learning framework for video anomaly detection | |
CN110084151B (en) | Video abnormal behavior discrimination method based on non-local network deep learning | |
CN104217225B (en) | A kind of sensation target detection and mask method | |
Kumar et al. | A visual-numeric approach to clustering and anomaly detection for trajectory data | |
Xu et al. | Video anomaly detection based on a hierarchical activity discovery within spatio-temporal contexts | |
CN102999640B (en) | Based on the video of semantic reasoning and structural description and image indexing system and method | |
Morris et al. | Understanding vehicular traffic behavior from video: a survey of unsupervised approaches | |
Li et al. | Traffic anomaly detection based on image descriptor in videos | |
CN103942575A (en) | System and method for analyzing intelligent behaviors based on scenes and Markov logic network | |
Ratre et al. | Tucker tensor decomposition‐based tracking and Gaussian mixture model for anomaly localisation and detection in surveillance videos | |
Athanesious et al. | Detecting abnormal events in traffic video surveillance using superorientation optical flow feature | |
Gawande et al. | Deep learning approach to key frame detection in human action videos | |
Laib et al. | A probabilistic topic model for event-based image classification and multi-label annotation | |
Zhang et al. | Pedestrian detection based on hierarchical co-occurrence model for occlusion handling | |
Ren et al. | A new multi-scale pedestrian detection algorithm in traffic environment | |
Gong et al. | Erroneous pixel prediction for semantic image segmentation | |
Yasin et al. | Anomaly Prediction over Human Crowded Scenes via Associate‐Based Data Mining and K‐Ary Tree Hashing | |
Chen et al. | Group Behavior Pattern Recognition Algorithm Based on Spatio‐Temporal Graph Convolutional Networks |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant | ||
CF01 | Termination of patent right due to non-payment of annual fee | ||
CF01 | Termination of patent right due to non-payment of annual fee |
Granted publication date: 20200811 Termination date: 20211027 |