Martial arts action recognition method based on deep learning
Through deep learning-based methods, combined with efficient visual self-attention mechanism, dynamic multi-head technology and polarized self-attention mechanism, the complex action recognition problem in martial arts action recognition is solved, achieving fast and accurate recognition in complex backgrounds, and Reduced computing resource requirements.
Patent Information
- Application Number
- CN202410732316.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-06-06
- Publication Date
- 2024-09-03
AI Technical Summary
The existing technology is difficult to quickly and accurately identify complex movements in martial arts action recognition, and the detection effect is poor on complex backgrounds. A single local feature cannot meet the needs for accurate recognition.
Adopt a method based on deep learning, use efficient visual self-attention mechanism for target detection, introduce dynamic multi-head technology and polarized self-attention mechanism, combine with multi-scale time graph convolution network, optimize target detection and action recognition modules, use replacement minimum Distance intersection and union loss function to improve detection speed and accuracy.
It achieves fast and accurate detection of martial arts actions in complex backgrounds, can capture fine-grained local features and global context information, and improves the accuracy of action recognition without requiring expensive computing resources.
Smart Images

Figure CN118587768A
Abstract
Description
Technical Field
[0001] The present invention relates to the field of target detection and action recognition, and in particular to a martial arts action recognition method based on deep learning. Background Art
[0002] Wushu action recognition is a research hotspot in the field of computer vision. It automatically detects and classifies different martial arts actions by analyzing the human skeleton and action patterns in the video. Since martial arts actions are fast, complex, and last for a long time, their recognition is more challenging than simple actions (such as walking or jumping). First, the rapidity of martial arts actions requires that the recognition algorithm must be able to capture the changes in the action in real time; second, the complexity and duration of the action require the algorithm to be able to process and analyze the rich information in the time dimension; third, relying solely on a single local feature in the spatial and temporal dimensions cannot meet the needs of accurate recognition. Therefore, studying how to quickly and accurately recognize complex martial arts actions has become a research focus in the current field of martial arts action recognition. Summary of the invention
[0003] The present invention aims to solve the shortcomings of the prior art in martial arts action recognition and proposes a novel method based on deep learning. The method first uses a target detection algorithm to locate the martial arts subject target in the video. In order to quickly and accurately capture the target, the present invention adopts an efficient visual self-attention mechanism as the backbone network, which can significantly improve the speed and accuracy of target detection. In addition, the present invention also introduces dynamic multi-head technology as a prediction classifier, which not only enhances the model's ability to integrate multi-scale features, but also improves the spatial perception ability, making the detection of human subjects in complex backgrounds more accurate. In order to further optimize the detection target area, we adopt a method of replacing the minimum distance intersection loss function, which helps to achieve a better balance between detection speed and accuracy. In the recognition of martial arts actions, the present invention introduces a polarized self-attention mechanism, which can not only capture fine-grained local features, but also accurately obtain global context information, that is, global features. This mechanism enables the method of the present invention to simultaneously obtain global features and local features in the spatiotemporal dimension, thereby improving the accuracy of action recognition. In order to further enrich the information in the time dimension and improve the recognition accuracy of the long sequence of martial arts actions, the present invention also introduces a multi-scale time graph convolutional network. Importantly, the method of the present invention does not require expensive computing resources, and is therefore more efficient and practical in practical applications. The method of the present invention does not require expensive computing power and can quickly and accurately identify complex martial arts movements.
[0004] In order to achieve the above object, the present invention adopts the following technical solution:
[0005] A martial arts action recognition method based on deep learning, characterized in that the operation steps are as follows:
[0006] Step 1: Create a martial arts image dataset and mark the corresponding position boxes for training the martial arts subject detection module, thereby completing the preprocessing process of the martial arts image dataset and obtaining the sorted martial arts image dataset;
[0007] Step 2: Create a martial arts action dataset and mark the corresponding key nodes of the human skeleton for training the martial arts action recognition module, thereby completing the martial arts action dataset preprocessing process and obtaining the sorted martial arts action dataset;
[0008] Step 3: Input the data in the martial arts image dataset sorted out in step 1 into the optimized martial arts subject detection module for training to achieve accurate positioning of human targets in martial arts movements;
[0009] Step 4: Based on the Alphapose network, extract the human skeleton joints of the human target detected in step 3 to obtain human joint data;
[0010] Step 5: Input the martial arts action data set sorted in step 2 into the optimized martial arts action recognition module to extract the spatiotemporal features of martial arts actions. By capturing the timing information between action sequences, martial arts action recognition is completed to improve the accuracy of action recognition.
[0011] Preferably, the martial arts image data set preprocessing in step 1 includes the following operations:
[0012] 1-1: Collect images containing different martial arts movements, covering 36 types of martial arts boxing; the data sources are diverse, covering different scenes, lighting conditions and human postures. After screening, it contains 2124 pictures, and the resolution of each image is 1024×1024;
[0013] 1-2: Use the professional image annotation tool LabelImg to annotate the human targets in each image; the annotation includes the location box and the corresponding category, and the corresponding information is saved in txt format;
[0014] 1-3: Enhance the data set to increase the diversity and richness of the data; the enhancement methods include rotation, translation, scaling, and mirroring operations to simulate martial arts movements at different angles and postures;
[0015] 1-4: Clean the dataset to remove noise data and labeling errors; ensure the accuracy and consistency of the labeling to improve the reliability of model training and evaluation. Finally, 4424 labeled data samples are obtained, thus obtaining the sorted martial arts boxing image dataset.
[0016] Preferably, the martial arts action data set preprocessing in step 2 includes the following operations:
[0017] 2-1: Both online and offline strategies were adopted to collect positive tutorial videos; the online strategy mainly included collecting public teaching resources from major video sharing platforms, social media, and specialized martial arts teaching websites; the offline strategy involved cooperating with martial arts schools, gymnasiums, and martial arts groups to directly record or obtain their teaching videos; a total of 168 videos were collected, including at least two boxing techniques from Bagua, Baji, Tai Chi, Mantis, and Wing Chun, with a total duration of 21,650 seconds;
[0018] 2-2: Crop each video into 10-second segments; use OpenCV to read the video frames, and use YOLOv5s as the detection model to identify the target human body bounding box in the video frame and fine-tune it;
[0019] 2-3: The data annotated in 2-2 is input into the SPPE_FastPose pose estimation model to extract the positions of the skeleton joints and the corresponding scores; the extracted joint positions and scores are normalized to ensure that the coordinates of the joint positions are independent of the resolution of the original video, and are adjusted in the range of [0,1], and all data are saved in a CSV file;
[0020] 2-4: Read the data in the CSV file and remove the data rows with missing values in the main key points; for the scores of all key points in each frame, improve the main parts and merge the One-Hot encoded labels with other key point data;
[0021] 2-5: Output and save the final constructed skeleton features and labels into a .pickle file, thereby obtaining a sorted martial arts action dataset for subsequent learning, training and analysis.
[0022] Further preferably, in said steps 2-4, the main key points in said data rows with missing values on the removed main key points are human shoulders and hips; and the main parts in said main parts scores that are improved are human shoulders and hips.
[0023] Preferably, the martial arts training subject detection module in step 3 includes the following operations:
[0024] 3-1: Use the martial arts subject detection module YOLOv5s algorithm;
[0025] 3-2: In YOLOv5s, the EfficientViT network is introduced as the backbone network, and DyHead is used as the prediction classifier. Then, the MPDIoU loss function is used during the training process to achieve lightweight and accurate detection of martial arts subjects, and obtain an optimized martial arts subject detection module;
[0026] 3-3: Input the martial arts boxing image dataset sorted in step 1 into the optimized martial arts subject detection module, that is, the YOLOv5s algorithm with embedded efficient visual self-attention mechanism and dynamic multi-head technology to perform network model training;
[0027] 3-4: During the network model training process, the Adam optimization algorithm is used, the learning rate is 0.01, the batch size is 16, and a total of 300 training iterations are performed.
[0028] Preferably, the step 4 of extracting human skeletal joints from the human target comprises the following operations:
[0029] 4-1: Use Alphapose to extract features from the human target image obtained in step 3 to obtain a high-dimensional feature representation;
[0030] 4-2: Use multiple feature maps to estimate the skeleton nodes; Improve robustness and stability by using feature maps at different levels for processing;
[0031] 4-3: Connect and smooth the key points to further improve accuracy and stability;
[0032] 4-4: The final output is the position and confidence of each key point, as well as the key point connection relationship and confidence of the posture.
[0033] Preferably, the training of the martial arts action recognition module in step 5 includes the following operations:
[0034] 5-1: Collect training data from the martial arts action data set in step 2, and pre-process the collected data to obtain the spatiotemporal information of the action sequence;
[0035] 5-2: Based on the preprocessed data, a spatiotemporal graph is constructed to represent each action sequence; the key nodes of the human body are regarded as nodes in the graph, and the edges of the graph are constructed according to the spatial distance and time series relationship between the nodes to form a spatiotemporal relationship graph;
[0036] 5-3: Use the martial arts action recognition module to extract action features and model the temporal information; use the spatiotemporal graph convolution operation to capture the spatiotemporal dependencies between nodes to achieve feature extraction and temporal modeling of action sequences;
[0037] 5-4: The martial arts action recognition module uses an improved ST-GCN network. In its structure, the first three layers are ST-GCN for extracting low-level features, and the last six layers introduce a polarization attention mechanism module in ST-GCN. The temporal graph convolutional network TCN is replaced by a multi-scale temporal graph convolutional network, thereby comprehensively extracting the global and local features of time and space, and then accurately identifying the types of martial arts, and obtaining an optimized martial arts action recognition module;
[0038] 5-5: Input the preprocessed spatiotemporal information sorted out in step 5-1 into the optimized martial arts action recognition module, i.e., ST-GCN with embedded self-attention mechanism for training;
[0039] 5-6: The network model training uses the RAdam optimization algorithm, with a learning rate of 0.05, a batch size of 16, and a total of 300 training iterations.
[0040] The present invention has the following obvious outstanding essential features and remarkable advantages:
[0041] 1. The present invention designs a martial arts action recognition method based on deep learning; in the stage of martial arts subject detection, by introducing an efficient visual self-attention model, features can be quickly extracted, the network can be deployed in a lightweight manner, and dynamic multi-head technology can be introduced to enhance spatial perception and the ability to integrate features of different scales, thereby improving the detection effect under complex backgrounds such as occlusion and insufficient light, and replacing the loss function with the minimum distance intersection loss function; the method of the present invention optimizes the target detection area, thereby being able to detect the task target more quickly and accurately;
[0042] 2. In the martial arts action recognition stage, the method of the present invention can extract global and local features from the spatiotemporal dimensions by introducing multi-scale temporal graph convolution and polarized self-attention mechanism, thereby accurately classifying martial arts actions;
[0043] 3. The method of the present invention at least displays visualization effect diagrams of four kinds of boxing, namely Bagua, Baji, Taiji and Mantis. The method of the present invention can accurately identify martial arts boxing and provide a digital tool for the dissemination of martial arts culture. BRIEF DESCRIPTION OF THE DRAWINGS
[0044] Figure 1 The figure is an overall flow chart of the method of the preferred embodiment of the present invention.
[0045] Figure 2 It is a martial arts subject detection module with an embedded efficient visual self-attention mechanism and dynamic multi-head technology of the preferred embodiment method of the present invention.
[0046] Figure 3 A martial arts action recognition module with a self-attention mechanism according to a preferred embodiment of the present invention.
[0047] Figure 4 Four types of boxing techniques, namely Bagua, Baji, Taiji and Mantis, are visualized and designed using the method of the preferred embodiment of the present invention. DETAILED DESCRIPTION
[0048] The preferred embodiments of the present invention are described in detail below with reference to the accompanying drawings.
[0049] Embodiment 1:
[0050] See also Figure 1 , a martial arts action recognition method based on deep learning, the steps are as follows:
[0051] Step 1: Create a martial arts image dataset and mark the corresponding position boxes for training the martial arts subject detection module, thereby completing the preprocessing process of the martial arts image dataset and obtaining the sorted martial arts image dataset;
[0052] Step 2: Create a martial arts action dataset and mark the corresponding key nodes of the human skeleton for training the martial arts action recognition module, thereby completing the martial arts action dataset preprocessing process and obtaining the sorted martial arts action dataset;
[0053] Step 3: Input the data in the martial arts image dataset sorted out in step 1 into the optimized martial arts subject detection module for training to achieve accurate positioning of human targets in martial arts movements;
[0054] Step 4: Based on the Alphapose network, extract the human skeleton joints of the human target detected in step 3 to obtain human joint data;
[0055] Step 5: Input the martial arts action data set sorted in step 2 into the optimized martial arts action recognition module to extract the spatiotemporal features of martial arts actions. By capturing the timing information between action sequences, martial arts action recognition is completed to improve the accuracy of action recognition.
[0056] The method of this embodiment can accurately identify a variety of boxing techniques, and the entire model training process is very low-cost and does not require expensive hardware equipment.
[0057] Embodiment 2:
[0058] This embodiment is basically the same as the first embodiment, with the following special features:
[0059] like Figure 1-4 As shown, in this embodiment, the martial arts boxing image data set preprocessing in step 1 includes the following operations:
[0060] 1-1: Collect images containing different martial arts movements, covering 36 types of martial arts boxing; the data sources are diverse, covering different scenes, lighting conditions and human postures. After screening, it contains 2124 pictures, and the resolution of each image is 1024×1024;
[0061] 1-2: Use the professional image annotation tool LabelImg to annotate the human targets in each image; the annotation includes the location box and the corresponding category, and the corresponding information is saved in txt format;
[0062] 1-3: Enhance the data set to increase the diversity and richness of the data; the enhancement methods include rotation, translation, scaling, and mirroring operations to simulate martial arts movements at different angles and postures;
[0063] 1-4: Clean the dataset to remove noise data and labeling errors; ensure the accuracy and consistency of the labeling to improve the reliability of model training and evaluation. Finally, 4424 labeled data samples are obtained, thus obtaining the sorted martial arts boxing image dataset.
[0064] In this embodiment, the martial arts action data set preprocessing in step 2 includes the following operations:
[0065] 2-1: Both online and offline strategies were adopted to collect positive tutorial videos; the online strategy mainly included collecting public teaching resources from major video sharing platforms, social media and specialized martial arts teaching websites; the offline strategy involved cooperating with martial arts schools, gymnasiums and martial arts groups to directly record or obtain their teaching videos; a total of 168 videos were collected, including four types of boxing: Bagua, Baji, Taiji and Mantis, with a total length of 21,650 seconds;
[0066] 2-2: Crop each video into 10-second segments; use OpenCV to read the video frames, and use YOLOv5s as the detection model to identify the target human body bounding box in the video frame and fine-tune it;
[0067] 2-3: The data obtained in step 2-2 is input into the SPPE_FastPose pose estimation model to extract the positions of the skeleton joints and the corresponding scores; the extracted joint positions and scores are normalized to ensure that the coordinates of the joint positions are independent of the resolution of the original video, and are adjusted in the range of [0,1], and all data are saved in a CSV file;
[0068] 2-4: Read the data in the CSV file and remove the data rows with missing values in the main key points, which are shoulders and hips of people; for the scores of all key points in each frame, improve the scores of the main parts, which are shoulders and hips of people, and merge the One-Hot encoded labels with other key point data;
[0069] 2-5: Output and save the final constructed skeleton features and labels into a .pickle file, thereby obtaining a sorted martial arts action dataset for subsequent learning, training and analysis.
[0070] In this embodiment, the martial arts training subject detection module in step 3 includes the following operations:
[0071] 3-1: Use the martial arts subject detection module YOLOv5s algorithm;
[0072] 3-2: YOLOv5s introduces the EfficientViT network as the backbone network and DyHead as the prediction classifier. Then, the MPDIoU loss function is used in the training process to achieve lightweight and accurate detection of martial arts subjects, and obtain an optimized martial arts subject detection module. The structure of the martial arts subject detection module with an embedded efficient visual self-attention mechanism and dynamic multi-head technology is as follows: Figure 2 As shown;
[0073] 3-3: Input the martial arts boxing image dataset sorted in step 1 into the optimized martial arts subject detection module, that is, the YOLOv5s algorithm with embedded efficient visual self-attention mechanism and dynamic multi-head technology to perform network model training;
[0074] 3-4: During the network model training process, the Adam optimization algorithm is used, the learning rate is 0.01, the batch size is 16, and a total of 300 training iterations are performed.
[0075] In this embodiment, the step 4 of extracting human skeletal joints from the human target includes the following operations:
[0076] 4-1: Use Alphapose to extract features from the human target image obtained in step 3 to obtain a high-dimensional feature representation;
[0077] 4-2: Use multiple feature maps to estimate the skeleton nodes; Improve robustness and stability by using feature maps at different levels for processing;
[0078] 4-3: Connect and smooth the key points to further improve accuracy and stability;
[0079] 4-4: The final output is the position and confidence of each key point, as well as the key point connection relationship and confidence of the posture.
[0080] In this embodiment, the training martial arts action recognition module in step 5 includes the following operations:
[0081] 5-1: Collect training data from the martial arts action data set in step 2, and pre-process the collected data to obtain the spatiotemporal information of the action sequence;
[0082] 5-2: Based on the preprocessed data, a spatiotemporal graph is constructed to represent each action sequence; the key nodes of the human body are regarded as nodes in the graph, and the edges of the graph are constructed according to the spatial distance and time series relationship between the nodes to form a spatiotemporal relationship graph;
[0083] 5-3: Use the martial arts action recognition module to extract action features and model the temporal information; use the spatiotemporal graph convolution operation to capture the spatiotemporal dependencies between nodes to achieve feature extraction and temporal modeling of action sequences;
[0084] 5-4: The martial arts action recognition module uses an improved ST-GCN network. In its structure, the first three layers are ST-GCN for extracting low-level features, and the last six layers introduce a polarization attention mechanism module in ST-GCN. The temporal graph convolutional network TCN is replaced by a multi-scale temporal graph convolutional network, thereby comprehensively extracting the global and local features of time and space, and then accurately identifying the types of martial arts, and obtaining an optimized martial arts action recognition module;
[0085] 5-5: Input the preprocessed spatiotemporal information sorted out in step 5-1 into the optimized martial arts action recognition module, i.e., ST-GCN with embedded self-attention mechanism for training;
[0086] 5-6: The network model training uses the RAdam optimization algorithm, with a learning rate of 0.05, a batch size of 16, and a total of 300 training iterations.
[0087] The present embodiment is a martial arts action recognition method based on deep learning; in the martial arts subject detection stage, by introducing an efficient visual self-attention model, features can be quickly extracted, the network can be deployed in a lightweight manner, and dynamic multi-head technology can be introduced to enhance spatial perception and the ability to fuse features of different scales, thereby improving the detection effect under complex backgrounds such as occlusion and insufficient light, and replacing the loss function with a minimum distance intersection loss function; the method of the present embodiment optimizes the target detection area, thereby being able to detect the task target more quickly and accurately; in the martial arts action recognition stage, the method of the present embodiment introduces multi-scale temporal graph convolution and polarization self-attention mechanism to extract global features and local features from the time and space dimensions, thereby accurately classifying martial arts actions; the method of the present embodiment at least displays visualization effect diagrams of four types of boxing: Bagua, Baji, Tai Chi, and Mantis. The method of the present embodiment can accurately identify martial arts boxing and provide a digital tool for the dissemination of martial arts culture.
[0088] Embodiment three:
[0089] This embodiment is basically the same as the above embodiment, with the following special features:
[0090] like Figure 1-4 As shown, in this embodiment, the martial arts training subject detection module of step 3 includes the following operations:
[0091] 3-1: Use the martial arts subject detection module YOLOv5s algorithm;
[0092] 3-2: In YOLOv5s, the EfficientViT network is introduced as the backbone network, DyHead is used as the prediction classifier, and the MPDIoU loss function is used in the training process, which can accurately detect the main body of martial arts figures in a lightweight way;
[0093] The backbone network in YOLOv5s is the EfficientViT network, which is used to quickly extract features. The feature maps output from the MBConv module, the lightweight EfficientViT module, and the SPPF module are connected with the upsampling in the Neck network to output feature maps of sizes 20×20, 40×40, and 80×80. Then, downsampling is performed, and the output feature maps of the three sizes are input into the prediction classifier and replaced with DyHead to improve the detection ability of complex backgrounds and the fusion ability of feature scales of different sizes. Finally, the MPDIoU loss function is used in the training process to optimize the target detection area, which can further quickly and accurately detect the main body of martial arts figures.
[0094] 3-3: Input the martial arts boxing image dataset compiled in step 1 into the improved martial arts subject detection module, that is, the YOLOv5s algorithm with an embedded efficient visual self-attention mechanism and dynamic multi-head technology for training;
[0095] 3-4: The network model training uses the Adam optimization algorithm, with a learning rate of 0.01, a batch size of 16, and a total of 300 training iterations.
[0096] In this embodiment, the training martial arts action recognition module in step 5 includes the following operations:
[0097] 5-1: First, a large amount of training data is collected from the martial arts action data set in step 2 and preprocessed to obtain the spatiotemporal information of the action sequence;
[0098] 5-2: Based on the preprocessed data, a spatiotemporal graph is constructed to represent each action sequence. The key nodes of the human body are regarded as nodes in the graph, and the edges of the graph are constructed according to the spatial distance and time series relationship between the nodes to form a spatiotemporal relationship graph:
[0099] G=(V,E)
[0100] Among them, V represents the node set, and E represents the edge set;
[0101] 5-3: The martial arts action recognition module is used to extract action features and model temporal information; the spatiotemporal graph convolution operation is designed to capture the spatiotemporal dependencies between nodes, and realize feature extraction and temporal modeling of action sequences;
[0102] 5-4: The martial arts action recognition module uses an improved ST-GCN network, whose structure is as follows Figure 3 As shown in the figure, the first three layers are ST-GCN for extracting low-level features, and the last six layers introduce a polarization attention mechanism module in ST-GCN. The temporal graph convolution network TCN is replaced by a multi-scale temporal graph convolution network, in order to fully extract the global and local features of time and space, and then accurately identify the types of martial arts.
[0103] 5-5: Input the preprocessed spatiotemporal information sorted out in step 5-1 into the improved martial arts action recognition module, i.e., ST-GCN with embedded self-attention mechanism, for training;
[0104] 5-6: The network model training uses the RAdam optimization algorithm, with a learning rate of 0.05, a batch size of 16, and a total of 300 training iterations.
[0105] The method of this embodiment has good comprehensive performance in terms of speed and accuracy. The method of the present invention uses a target detection algorithm to locate the main martial arts target in the video. In order to quickly and accurately capture the target, the present invention adopts an efficient visual self-attention mechanism as the backbone network, which can significantly improve the speed and accuracy of target detection. The method of this embodiment also introduces dynamic multi-head technology as a prediction classifier, which not only enhances the model's ability to integrate multi-scale features, but also improves the spatial perception ability, making the detection of human subjects in complex backgrounds more accurate. In order to further optimize the detection target area, this embodiment adopts a method of replacing the minimum distance intersection loss function, which helps to achieve a better balance between detection speed and accuracy. In the recognition of martial arts movements, the present invention can not only capture fine-grained local features, but also accurately obtain global context information, that is, global features, by introducing a polarized self-attention mechanism. This mechanism enables the method of the present invention to simultaneously obtain global features and local features in the spatiotemporal dimension, thereby improving the accuracy of action recognition. In order to further enrich the information in the time dimension and improve the recognition accuracy of the long sequence of martial arts movements, this embodiment also introduces a multi-scale time graph convolutional network. This embodiment method selects a self-built martial arts action data set to verify the performance of the method of the present invention. A visualization effect diagram is used to show the performance of the method. Figure 4 As shown, accurate recognition of martial arts movements is achieved, computing resources are saved, and the cost is low.
[0106] In summary, the martial arts action recognition method based on deep learning of the present invention first creates a martial arts boxing image data set, marks the corresponding position box, and is used to train the martial arts subject detection module; then creates a martial arts action data set, marks the corresponding human skeleton key nodes, and is used to train the martial arts action recognition module; then the sorted martial arts boxing image data set is input into the optimized martial arts subject detection module for training, so as to achieve accurate positioning of human targets in martial arts movements; then the human skeleton joints of the detected human targets are extracted based on the Alphapose network to obtain human joint data; then the sorted martial arts action data set is pre-processed and input into the optimized martial arts action recognition module to extract the spatiotemporal features of martial arts actions, and the accuracy of action recognition is improved by capturing the timing information between action sequences. This method of the present invention does not require expensive computing resources, so it is more efficient and practical in practical applications. The method of the present invention does not require expensive computing power, and can quickly and accurately identify complex martial arts actions.
[0107] The above describes the embodiments of the present invention in conjunction with the accompanying drawings, but the present invention is not limited to the above embodiments. Various changes can be made according to the purpose of the invention. Any changes, modifications, substitutions, combinations or simplifications made according to the spirit and principle of the technical solution of the present invention should be equivalent replacement methods. As long as they meet the purpose of the invention and do not deviate from the technical principles and inventive concepts of the present invention, they belong to the protection scope of the present invention.
Claims
1. A martial arts action recognition method based on deep learning, characterized in that: The steps are as follows: Step 1: Create a martial arts image dataset and mark the corresponding position boxes for training the martial arts subject detection module, thereby completing the preprocessing process of the martial arts image dataset and obtaining the sorted martial arts image dataset; Step 2: Create a martial arts action dataset and mark the corresponding key nodes of the human skeleton for training the martial arts action recognition module, thereby completing the martial arts action dataset preprocessing process and obtaining the sorted martial arts action dataset; Step 3: Input the data in the martial arts boxing image dataset sorted out in step 1 into the optimized martial arts subject detection module for training to achieve the positioning of human targets in martial arts movements; Step 4: Based on the Alphapose network, extract the human skeleton joints of the human target detected in step 3 to obtain human joint data; Step 5: Input the martial arts action data set sorted in step 2 into the optimized martial arts action recognition module to extract the spatiotemporal features of martial arts actions, and complete martial arts action recognition by capturing the timing information between action sequences.
2. The martial arts action recognition method based on deep learning according to claim 1, characterized in that: The martial arts image dataset preprocessing in step 1 includes the following operations: 1-1: Collect images containing different martial arts movements, covering 36 types of martial arts boxing; the data sources are diverse, covering different scenes, lighting conditions and human postures. After screening, it contains 2124 pictures, and the resolution of each image is 1024×1024; 1-2: Use the image annotation tool LabelImg to annotate the human targets in each image; the annotation includes the location box and the corresponding category, and the corresponding information is saved in txt format; 1-3: Enhance the data set to increase the diversity and richness of the data; the enhancement methods include rotation, translation, scaling, and mirroring operations to simulate martial arts movements at different angles and postures; 1-4: Clean the data set to remove noise data and labeling errors; 4424 labeled data samples are obtained, thus obtaining a sorted martial arts boxing image dataset.
3. The martial arts action recognition method based on deep learning according to claim 1, characterized in that: The martial arts action data set preprocessing in step 2 includes the following operations: 2-1: Adopt both online and offline strategies to collect positive tutorial videos; the online strategy mainly includes collecting public teaching resources from major video sharing platforms, social media and specialized martial arts teaching websites; the offline strategy involves cooperating with martial arts schools, gymnasiums and martial arts groups to directly record or obtain their teaching videos; A total of 168 videos were collected, including at least two boxing styles from Bagua, Baji, Tai Chi, Mantis, and Wing Chun, with a total duration of 21,650 seconds; 2-2: Crop each video into 10-second segments; use OpenCV to read the video frames, and use YOLOv5s as the detection model to identify the target human body bounding box in the video frame and fine-tune it; 2-3: Input the data in step 2-2 into the SPPE_FastPose pose estimation model to extract the positions of the skeleton joints and the corresponding scores; the extracted joint positions and scores are normalized to ensure that the coordinates of the joint positions are independent of the resolution of the original video, and are adjusted in the range of [0,1], and all data are saved in a CSV file; 2-4: Read the data in the CSV file and remove the data rows with missing values in the main key points; for the scores of all key points in each frame, increase the scores of the main parts and merge the One-Hot encoded labels with other key point data; 2-5: Output and save the final constructed skeleton features and labels into a .pickle file, thereby obtaining a sorted martial arts action dataset for subsequent learning, training and analysis.
4. The martial arts action recognition method based on deep learning according to claim 3 is characterized in that: In the steps 2-4, the main key points in the data rows with missing values on the main key points are removed, which are human shoulders and hips; and the main parts in the main parts scores that are improved are human shoulders and hips.
5. The martial arts action recognition method based on deep learning according to claim 1, characterized in that: The martial arts training subject detection module in step 3 includes the following operations: 3-1: Use the martial arts subject detection module YOLOv5s algorithm; 3-2: In YOLOv5s, the EfficientViT network is introduced as the backbone network, and DyHead is used as the prediction classifier. Then, the MPDIoU loss function is used during the training process to detect the martial arts subject and obtain the optimized martial arts subject detection module; 3-3: Input the martial arts boxing image dataset sorted in step 1 into the optimized martial arts subject detection module, that is, the YOLOv5s algorithm with embedded efficient visual self-attention mechanism and dynamic multi-head technology to perform network model training; 3-4: During the network model training process, the Adam optimization algorithm is used, the learning rate is 0.01, the batch size is 16, and a total of 300 training iterations are performed.
6. The martial arts action recognition method based on deep learning according to claim 1 is characterized in that: The step 4 of extracting human skeleton joints from the human target comprises the following operations: 4-1: Use Alphapose to extract features from the human target image obtained in step 3 to obtain a high-dimensional feature representation; 4-2: Use multiple feature maps to estimate the skeleton nodes; Process by using feature maps at different levels; 4-3: Connect and smooth the key points to further improve accuracy and stability; 4-4: The final output is the position and confidence of each key point, as well as the key point connection relationship and confidence of the posture.
7. The martial arts action recognition method based on deep learning according to claim 1 is characterized in that: The training of the martial arts action recognition module in step 5 includes the following operations: 5-1: Collect training data from the martial arts action data set in step 2, and pre-process the collected data to obtain the spatiotemporal information of the action sequence; 5-2: Based on the preprocessed data, a spatiotemporal graph is constructed to represent each action sequence; the key nodes of the human body are regarded as nodes in the graph, and the edges of the graph are constructed according to the spatial distance and time series relationship between the nodes to form a spatiotemporal relationship graph; 5-3: Use the martial arts action recognition module to extract action features and model the temporal information; use the spatiotemporal graph convolution operation to capture the spatiotemporal dependencies between nodes to achieve feature extraction and temporal modeling of action sequences; 5-4: The martial arts action recognition module uses an improved ST-GCN network. In its structure, the first three layers are ST-GCN for extracting low-level features, and the last six layers introduce a polarization attention mechanism module in ST-GCN. The temporal graph convolution network TCN is replaced by a multi-scale temporal graph convolution network, thereby comprehensively extracting the global and local features of time and space, and then identifying the types of martial arts, and obtaining an optimized martial arts action recognition module; 5-5: Input the preprocessed spatiotemporal information sorted out in step 5-1 into the optimized martial arts action recognition module, i.e., ST-GCN with embedded self-attention mechanism for training; 5-6: The network model training uses the RAdam optimization algorithm, with a learning rate of 0.05, a batch size of 16, and a total of 300 training iterations.
Citation Information
Cited By
Tai Chi teaching system based on motion perception
CN119479073A
A Tai Chi teaching system based on action perception
CN119479073B
Police martial arts fighting action evaluation method and system based on peak shifting time pulse
CN120339905A
Evaluation method and system for police martial arts fighting movements based on staggered time pulses
CN120339905B
Linkage type martial art training auxiliary device and training method
CN121155102A
