Fine-grained video behavior recognition method based on action tracking

By introducing the temporal information enhancement module and the spatial region semantic activation module into the video action recognition network, combined with the multi-level trajectory comparison loss function, the problem of fine-grained action recognition in the existing technology is solved, and accurate recognition and fine-graining of high-definition sports videos are achieved. Granular action classification.

CN118736459APending Publication Date: 2024-10-01DALIAN UNIV OF TECH
View PDF 0 Cites 2 Cited by

Patent Information

Application Number
CN202410777458.1
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-06-17
Publication Date
2024-10-01

AI Technical Summary

Technical Problem

Existing video behavior recognition methods are difficult to effectively identify fine-grained actions, especially when distinguishing action categories at the sub-category level. Moreover, traditional methods ignore the dynamics of local action details and lack regional-level annotations, resulting in poor recognition results on high-definition sports videos. good.

Method used

A fine-grained video behavior recognition network based on action tracking is proposed, including a temporal information enhancement module, a spatial region semantic activation module, and a motion trajectory generation and behavior prediction module. It extracts the space of video frames through a multi-head self-attention mechanism and a cross-attention mechanism. Regional semantic response, and self-supervised constraints through a multi-level trajectory comparison loss function to generate the final fine-grained action classification results.

Benefits of technology

It achieves accurate recognition of fine-grained actions, can capture action details without regional-level annotations, and improves behavior recognition accuracy on datasets such as FineGym, with advanced advantages.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118736459A_ABST
    Figure CN118736459A_ABST
Patent Text Reader

Abstract

The invention belongs to the field of computer vision and image processing, and relates to fine-grained action classification of an image sequence after video framing by adopting a deep convolutional neural network, in particular to a fine-grained video behavior recognition method based on action tracking. The method is simple in procedure and easy to implement, the action capable of recognizing the fine granularity of the human body can be obtained, and for the fine-granularity action of the human body, unique details of a local area in a video frame can be found and tracked implicitly through the motion trail of the modeling action so as to enrich codes of space and time contexts, and therefore the fine-granularity action can be better reasoned. In addition, according to the method, multi-layer track comparison loss is used for different layers to guide the network to accurately capture action details in an effective self-supervision mode on the space, time and track levels.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the field of computer vision and image processing, and relates to fine-grained behavior recognition of videos using a deep convolutional neural network, and specifically relates to a fine-grained video behavior recognition method based on motion tracking. Background Art

[0002] Video action recognition is of great significance for a wide range of visual analysis applications, such as intelligent surveillance, social scene understanding, and sports video analysis. With the great success of deep learning in various video recognition tasks, many spatiotemporal feature learning action recognition methods (such as STM, TSM, and I3D) and long-term modeling methods (such as TCN, TDRN, and SlowFast) have been proposed for video action recognition. In order to improve the network ability of motion pattern perception, TEA (Yan Li, Bin Ji, Xintian Shi, Jianguo Zhang, Bin Kang, and Limin Wang. TEA: temporal excitation and aggregation for action recognition. In IEEE CVPR, June, pages 906–915, 2020) uses the temporal difference of feature levels to activate motion-sensitive channels and form a hierarchical residual structure for action recognition. TDN (Limin Wang, Zhan Tong, Bin Ji, and Gangshan Wu. TDN: temporal difference networks for efficient action recognition. In IEEE, CVPR, June, pages 1895–1904, 2021) focuses on explicitly exploiting the temporal difference between short-term and long-term motion modeling to capture temporal context.

[0003] Since there are only subtle differences between many human activities in specialized fields, action recognition has recently been developed to a more fine-grained level. While traditional action recognition mainly focuses on recognizing visual appearance cues of objects and backgrounds, such as gymnastics and basketball, fine-grained action recognition distinguishes action categories at the sub-category level. For example, the actions of existing fine-grained datasets built on HD sports videos are more sensitive to temporal correlations than objects and backgrounds. The FineGym dataset consists of various subtle aspects such as posture, range of movement, and dramatic limb deformations. That is, fine-grained action recognition is significantly more challenging than traditional action recognition.

[0004] Existing action recognition frameworks usually focus on easily distinguishable segments while ignoring the dynamics of local action details. Recent works have drawn attention to the challenge of understanding the subtle differences of fine-grained action recognition. For example, MDCN (Baoli Sun, Xinchen Ye, Tiantian Yan, Zhihui Wang, Haojie Li, and Zhiyong Wang. Fine-grained action recognition with robust motion representation decoupling and concentration. In The 30th ACM MM, Lisboa, Portugal, October, pages 4779–4788, 2022) was proposed to learn different motion representations by separating motion representations from action-related motion representations. DSTS (Tianjiao Li, Lin Geng Foo, Qiuhong Ke, Hossein Rahmani, Anran Wang, Jinghua Wang, and Jun Liu. Dynamic spatio-temporal specialization learning for fine-grained action recognition. In ECCV, October, Part IV, volume 13664, pages 386–403, 2022) is proposed to distinguish these similar samples by learning to distinguish fine-grained differences through a dynamic spatio-temporal specialization module. In addition, we also notice that the most salient information in each frame of an action video is usually distributed in several small local regions that evolve over time. Although explicitly locating and tracking local regions that distinguish specific actions as an auxiliary task is a simple solution, it usually lacks region-level annotations. Therefore, our goal is to implicitly identify and track unique local details along the temporal dimension. Summary of the invention

[0005] The present invention aims to overcome the shortcomings of traditional methods and technologies, and proposes a fine-grained video behavior recognition network based on motion tracking. The network consists of a temporal information enhancement module, a spatial region semantic activation module, and a motion trajectory generation and behavior prediction module. The temporal information enhancement module feeds the input features into the encoder, and realizes the enhancement of long-time features through the calculation of the multi-head self-attention mechanism, thereby improving the model's ability to handle long-time information. The specific region semantic activation module addresses the problem that traditional methods cannot pay attention to more fine-grained human movements, and proposes a processing solution for selecting discriminative areas of each frame of the picture, thereby selecting more discriminative action areas in the video. The motion trajectory generation and prediction module splices the obtained trajectory feature vectors along the time dimension to obtain the final fine-grained action classification result.

[0006] The technical solution of the present invention is a fine-grained video behavior recognition method based on motion tracking, the method comprising the following steps:

[0007] The first step is to prepare the initial training data: the training data includes the color image sequence after the video is framed;

[0008] The second step is to build a temporal information enhancement module: The temporal information enhancement module consists of a Transformer encoder. The Transformer encoder uses a self-attention mechanism to enhance the temporal context to gain attention to the long-term temporal dependency characteristics in the video;

[0009] The third step is to build a spatial region semantic activation module: The spatial region semantic activation module consists of a Transformer decoder and a set of learnable feature query vectors. The feature query vector is used as a region query for each video frame to query the details of the local region and obtain the semantic response of the spatial region;

[0010] Step 4: Motion trajectory generation and behavior prediction module construction: After obtaining the semantic responses of the spatial regions of all video frames, these responses are rearranged to generate motion trajectories. These motion trajectories are integrated with the global representation of the entire video to obtain the final behavior prediction results;

[0011] Step 5: Construct the loss function and train the network;

[0012] Loss Function Measuring the gap between the action category labels predicted by the input video and the true category labels in the training data;

[0013]

[0014] in, It is a supervised learning loss used to train the network to extract features related to action recognition and model global action representation. It is used to supervise the final action recognition results, integrate the motion trajectory with the global representation of the entire video, and generate the final prediction result of the video. This loss function ensures the consistency of the trajectory representation and the global representation during prediction. represents the multi-level trajectory contrast loss, which is used to self-supervise the region-aware semantic response at the spatial, temporal and trajectory levels. λ is a hyperparameter used to balance the weights between multiple loss functions. The network training process is to continuously optimize the network parameters using training data to make Converge to get the final network model;

[0015] The sixth step is to perform fine-grained video behavior recognition through the trained network.

[0016] The beneficial effects of the present invention are:

[0017] The present invention builds a framework for fine-grained video behavior recognition based on action tracking based on deep neural networks, and finally obtains the classification results of fine-grained actions, which has the following characteristics:

[0018] 1. The system is easy to build and can recognize fine-grained human actions;

[0019] 2. We propose an action trajectory network to discover and track unique details of local regions in video frames to enrich the encoding of spatial and temporal context for better reasoning about fine-grained actions;

[0020] 3. We design a multi-level trajectory contrastive loss to guide the network to accurately capture action details in an effective self-supervised manner at the spatial, temporal and trajectory levels;

[0021] 4. Experimental results show advanced superiority on four widely used fine-grained action recognition datasets. BRIEF DESCRIPTION OF THE DRAWINGS

[0022] Figure 1 It is a specific implementation network framework diagram.

[0023] Figure 2 It is the structural diagram of the spatial region semantic activation module. DETAILED DESCRIPTION

[0024] The fine-grained video behavior recognition method based on motion tracking of the present invention is described in detail below in conjunction with the embodiments and drawings.

[0025] A fine-grained video action recognition method based on motion tracking, such as Figure 1 As shown, the following steps are included:

[0026] (1) Prepare initial training data;

[0027] The initial training data includes a sequence of color images after video framing. The processed color images are sampled at a fixed frame rate and then input into the network through data enhancement. Data enhancement includes several methods: (a) Geometric transformation. Geometric transformation refers to geometric transformation of images, including flipping, rotation, cropping, deformation, scaling and other operations. (b) Color transformation. The above geometric transformation operations do not change the content of the image itself. They may select part of the image or redistribute the pixels. If you want to change the content of the image itself, it belongs to the color transformation data enhancement. Common ones include noise, blur, color change, erasure, filling, etc.

[0028] (2) Construction of the temporal information enhancement module

[0029] The temporal information enhancement module consists of a Transformer encoder, where the encoder uses a self-attention mechanism to enhance the temporal context to gain attention to the long-term temporal dependency characteristics in the video; it includes the following steps:

[0030] The input X of the timing information enhancement module r It is obtained by inputting a color picture sequence after video frame division into a backbone network, where the backbone network selects TSM (Temporal Shift Module, TSM achieves the performance of 3D network while maintaining the complexity of 2D network by moving some channels in the time dimension. It can be used for low-latency online video recognition and detection and is a general behavior recognition network). The process can be expressed as:

[0031]

[0032] In the formula, X represents the input color image sequence data, T represents the number of frames, H and W represent the height and width in the feature space size, Represents the convolution operation in the TSM network, φ represents 1*1 convolution, and τ represents the dimension expansion operation.

[0033] Feature X output by the backbone network r It is sent to the Transformer encoder, which uses multi-head self-attention to model long-term dependencies. The self-attention operation SelfAtten(-) is expressed as:

[0034]

[0035] Where Q = X r W q , K = X r W k , V = X r W v.W q , W k and W v are all learnable weight parameter matrices in the network. d represents the dimension of the feature. Softmax(-) is the feature activation function.

[0036] The overall process of the timing information enhancement module is expressed as:

[0037]

[0038] Where MSA(·) represents the multi-head self-attention mechanism, and MLP(~) represents the linear mapping layer. represents the features after time series enhancement. Then, the features obtained by the time series information enhancement module are It will be used by the subsequent spatial region semantic activation module.

[0039] (3) Construction of spatial region semantic activation module

[0040] The purpose of the spatial region semantic activation module is to extract the semantic response of the spatial region in the video frame from the temporally enhanced region representation. A set of learnable feature query vectors Xq is introduced as the region query of each video frame to query the details of the local region and obtain the semantic response of the spatial region. Figure 2 As shown, the specific process is: the time-enhanced region is represented as The feature query vector is input into the Transformer decoder to capture region-specific semantic responses through the cross-attention mechanism. The cross-attention operation CrossAtten(·) is expressed as:

[0041]

[0042] The overall process of the spatial region semantic activation module is expressed as:

[0043]

[0044] Where MCA(·) represents the multi-head cross attention mechanism, Represents the features after semantic activation of spatial regions.

[0045] (4) Construction of motion trajectory generation and behavior prediction module

[0046] Motion trajectory generation and behavior prediction module: After obtaining the semantic responses of the spatial regions of all video frames, these responses are The responses of the same order but different frames in the video are rearranged to generate motion trajectories, which link the details of the spatial regions in different frames along the temporal dimension of the video. The mth trajectory Tr m is defined as follows:

[0047]

[0048] Where [-] represents the connection operation, l represents the linear layer mapping transformation, and M is the maximum number of motion trajectories. Finally, these motion trajectories are integrated with the global representation of the entire video to obtain the final behavior prediction result.

[0049] (5) Construct loss function and train the network

[0050] In order to accurately capture action details without region-level annotation, a multi-level trajectory contrast loss function (MTC-Loss) is proposed. MTC-Loss performs self-supervisory constraints on region-aware semantic responses at the spatial, temporal, and trajectory levels. By mutually excluding regional responses in the same frame, it captures rich and discriminative fine-grained features:

[0051]

[0052] In the formula, <·> represents cosine similarity, and ||·||2 represents L2 norm.

[0053] The temporal track contrastive loss attracts responses from different frames but in the same order, capturing the temporal dependencies of action instances:

[0054]

[0055] Where γ is a hyperparameter that indicates the correlation between responses of adjacent frames.

[0056] The track-level contrastive loss differentiates between track representations to track diverse details in videos:

[0057]

[0058]

[0059] Global prediction loss: In order to ensure that better features can be extracted, supervised constraints need to be imposed on the extracted feature vectors:

[0060]

[0061] Where B represents the number of videos input into the network in a batch during training, v represents the global representation of the video, and p(v) represents the behavior prediction probability of the video.

[0062] Overall prediction loss: Finally, these trajectory representations are combined with a global representation of the entire video to produce the final recognition result:

[0063]

[0064] Table 1 Comparison of the accuracy of the behavior recognition results of the present invention

[0065]

[0066] The behavior recognition results of the present invention and the comparison with other methods are shown in Table 1. The present invention adopts the commonly used average per-class accuracy (Mean%) and average per-video accuracy (Top-1%) as the judgment criteria for the accuracy of behavior recognition. The larger the Mean and Top-1, the higher the accuracy of behavior recognition. The present invention uses three common data sets in the field of behavior recognition (FineGym99, FineGym288 and Diving48) to verify the effectiveness of the proposed fine-grained video behavior recognition method based on motion tracking. Specifically, FineGym is a high-definition and high-quality gymnasium video data set with fine annotations. We used a relatively balanced setting, namely FineGym99, which contains 99 action categories, with 26,000 training videos and 85,000 test videos, and a long-tail setting, namely FineGym288, which contains 288 action categories, with 29,000 training videos and 96,000 test videos. Diving48 contains 48 action categories from competitive diving, with 16,000 training videos and 2,000 test videos. Diving48 has a common diving competition setting, and the diving sequences and subtle details define the diversity of these action categories. In terms of experimental settings, the method of the present invention is trained on 2 NVIDIA-A40 graphics cards, with a training data batch size of 16, and the SGD training optimizer is used. In the basic training stage, the model is trained for 100,000, 100,000 and 50,000 iterations on the FineGym99, FineGym288 and Diving48 datasets. The learning rate is set to 0.004 and decayed by 0.1 at the 50000th, 50000th, and 25000th iterations, respectively.

[0067] The comparison methods include I3D (Joao Carreira and Andrew Zisserman. Quo vadis, action recognition? A new model and the kinetics dataset. In IEEE CVPR, July, pages 4724–4733, 2017), TSM (Ji Lin, Chuang Gan, and Song Han. TSM: temporal shift module for efficient video understanding. In IEEE ICCV, October, pages 7082–7092, 2019), TEA (Yan Li, Bin Ji, Xintian Shi, Jianguo Zhang, Bin Kang, and Limin Wang. TEA: temporal excitation and aggregation for action recognition. In IEEE CVPR, June, pages 906–915, 2020), TDN (Limin Wang, Zhan Tong, Bin Ji, and Gangshan Wu. TDN: temporal difference networks for efficient action recognition. In IEEE, CVPR, June, pages 1895–1904, 2021), TimeSformer (Gedas Bertasius, Heng Wang, and Lorenzo Torresani. Is space-time attention all you need for video understanding? In ICML, July, Virtual Event, pages 813–824, 2021), MDCN (Baoli Sun, Xinchen Ye, Tiantian Yan, Zhihui Wang, Haojie Li, and Zhiyong Wang. Fine-grained action recognition with robust motion representation decoupling and concentration. In The 30th ACM MM, Lisboa, Portugal, October, pages 4779–4788, 2022).

Claims

1. A fine-grained video behavior recognition method based on motion tracking, characterized in that: The steps include: The first step is to prepare the initial training data: the training data includes the color image sequence after the video is framed; The second step is to build a temporal information enhancement module: the temporal information enhancement module consists of a Transformer encoder; the Transformer encoder uses a self-attention mechanism to enhance the temporal context to gain attention to the long-term temporal dependency characteristics in the video; The third step is to construct a spatial region semantic activation module: the spatial region semantic activation module consists of a Transformer decoder and a set of learnable feature query vectors; the feature query vector is used as a region query for each video frame to query the details of the local region and obtain the semantic response of the spatial region; Step 4: Motion trajectory generation and behavior prediction module construction: After obtaining the semantic responses of the spatial regions of all video frames, these responses are rearranged to generate motion trajectories; these motion trajectories are integrated with the global representation of the entire video to obtain the final behavior prediction results; Step 5: Construct the loss function and train the network; Loss Function Measuring the gap between the action category labels predicted by the input video and the true category labels in the training data; in, is a supervised learning loss used to train the network to extract features related to action recognition and model global action representation; It is used to supervise the final action recognition results, integrate the motion trajectory with the global representation of the entire video, and generate the final prediction result of the video; this loss function ensures the consistency of the trajectory representation and the global representation during prediction; represents a multi-level trajectory contrastive loss for self-supervising constraints on region-aware semantic responses at the spatial, temporal, and trajectory levels; λ is a hyperparameter used to balance the weights between multiple loss functions; The network training process is to use the training data to continuously optimize the network parameters. Converge to obtain the final network model; The sixth step is to perform fine-grained video behavior recognition through the trained network.

2. The fine-grained video behavior recognition method based on motion tracking according to claim 1 is characterized in that: In the first step, after the video is framed to obtain a color image sequence, the framed color images are sampled at a fixed frame rate and then data enhancement is performed.

3. The fine-grained video behavior recognition method based on motion tracking according to claim 1 is characterized in that: In the second step, the temporal information enhancement module consists of a Transformer encoder that uses a self-attention mechanism to enhance the temporal context to gain attention to the long-term temporal dependency characteristics in the video; it includes the following steps: The input X of the timing information enhancement module r It is obtained by inputting the initial training data into a backbone network, where the backbone network selects TSM. The processing process of the backbone network can be expressed as: In the formula, X represents the input color image sequence data, T represents the number of frames, H and W represent the height and width in the feature space size, Represents the convolution operation in the TSM network, φ represents 1*1 convolution, and τ represents the dimension expansion operation; Feature X output by the backbone network r It is sent to the Transformer encoder, which uses multi-head self-attention to model long-term dependencies; the self-attention operation SelfAtten(·) is expressed as: Where Q = X r W q , K = X r W k , V = X r W v ; W q , W k and W v are all learnable weight parameter matrices in the network; d represents the dimension of the feature; Softmax(·) is the feature activation function; The overall process of the timing information enhancement module is expressed as: Where MSA(·) represents the multi-head self-attention mechanism, and MLP(·) represents the linear mapping layer. represents the features after time series enhancement; then, the features obtained by the time series information enhancement module It will be used by the subsequent spatial region semantic activation module.

4. The fine-grained video behavior recognition method based on motion tracking according to claim 1 is characterized in that: The third step is as follows: The purpose of the spatial region semantic activation module is to extract the semantic response of the spatial region in the video frame from the temporally enhanced region representation; introduce a set of learnable feature query vectors X q As a region query for each video frame, it is used to query the details of the local area and obtain the semantic response of the spatial area; the specific process is: The feature query vector is input into the Transformer decoder to capture region-specific semantic responses through the cross-attention mechanism; the cross-attention operation CrossAtten(·) is expressed as: The overall process of the spatial region semantic activation module is expressed as: Where MCA(·) represents the multi-head cross attention mechanism, Represents the features after semantic activation of spatial regions.

5. The fine-grained video behavior recognition method based on motion tracking according to claim 1 is characterized in that: The fourth step is as follows: Motion trajectory generation and behavior prediction module: After obtaining the semantic response of the spatial region of all video frames, The responses of the same order but different frames in the video are rearranged to generate motion trajectories, which link the details of the spatial regions in different frames along the temporal dimension of the video. The mth trajectory Tr m is defined as follows: Where [·] represents the connection operation, represents the result of rearrangement; l represents the linear layer mapping transformation, and M is the maximum number of motion trajectories; finally, these motion trajectories are integrated with the global representation of the entire video to obtain the final behavior prediction result.

6. The fine-grained video behavior recognition method based on motion tracking according to claim 1 is characterized in that: In the fifth step, the loss function is constructed: The loss function is a multi-level trajectory contrast loss function, including spatial-level trajectory contrast loss, temporal-level trajectory contrast loss, and trajectory-level contrast loss; among them, spatial-level trajectory contrast loss By mutually excluding regional responses in the same frame, it captures rich and discriminative fine-grained features: In the formula, <·> represents cosine similarity, ||·||2 represents L2 norm; The temporal track contrast loss is used to attract responses from different frames but in the same order, capturing the temporal dependencies of action instances: In the formula, γ is a hyperparameter, which indicates the correlation degree of adjacent frame responses; Track-level contrastive loss is used to differentiate between track representations in order to track diverse details in the video: Global prediction loss: In order to ensure that better features can be extracted, supervised constraints need to be imposed on the extracted feature vectors: Where B represents the number of videos input into the network in a batch during training, v represents the global representation of the video, and p(v) represents the behavior prediction probability of the video. Overall prediction loss: Finally, these trajectory representations are combined with a global representation of the entire video to produce the final recognition result:

Citation Information

Cited By

  • Fine-grained video behavior recognition method based on double-text prompt

    CN120126217A

  • Fine-grained video behavior recognition method based on dual text prompts

    CN120126217B