Parallel bar arm flexion and extension motion detection method, device and equipment and storage medium
By combining identity verification and human posture recognition with state machine flow simulation and dual-flow neural network model, the automated detection of parallel bar arm dips and extensions is realized, which solves the problems of low detection efficiency and poor accuracy in existing technologies, and provides efficient and accurate motion analysis and violation warning.
Patent Information
- Application Number
- CN202511965080.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-12-24
- Publication Date
- 2026-05-15
AI Technical Summary
Existing technologies for detecting parallel bar dips and extensions suffer from inconsistent testing standards, low efficiency, heavy workload for judges, and the potential for minor errors to lead to joint damage or incorrect movement patterns. There is a lack of automated detection solutions based on state machine flow simulation and in-depth analysis.
By employing identity verification, human posture recognition, state machine transition simulation, and a dual-stream neural network model, video streams are acquired through cameras, posture information is filtered and deeply analyzed, and a detection report is generated to achieve automated detection.
It improves detection efficiency, avoids subjective errors from manual counting, enhances detection accuracy and security, and provides detailed motion analysis and violation warnings.
Smart Images

Figure CN122049975A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of motion detection technology, and in particular to a method, apparatus, equipment, and storage medium for detecting parallel bar dips and extensions. Background Technology
[0002] The dip is a classic upper body pushing exercise that primarily works the pectoral, deltoid, and triceps muscles, while also requiring strong core stability.
[0003] In related technologies, parallel bar dips are often used as an assessment score in physical training. However, traditional measurement methods, such as manual counting or infrared equipment, suffer from inconsistent testing standards, low efficiency, and heavy workload for judges, making them unsuitable for the needs of modern sports training and assessment. Furthermore, visual detection methods analyze perception on a frame-by-frame basis, employing discrete-time analysis, requiring in-depth analysis of the current situation, resulting in high detection complexity. In addition, parallel bar dips are a highly technical sport, and even minor errors can lead to joint damage or the development of incorrect movement patterns.
[0004] Based on the above analysis of the development status of this technology field, the existing technologies lack a solution to abstract the detection and counting of parallel bar arm flexion and extension into a state machine flow simulation, and to improve the quality of motion through in-depth analysis using a dual-flow neural network model. Summary of the Invention
[0005] The purpose of this invention is to provide a method, apparatus, device, and storage medium for detecting parallel bar dips and extensions, in order to solve the aforementioned problems in the prior art.
[0006] According to a first aspect of the present invention, a method for detecting parallel bar dips is provided, comprising: The athlete's identity is verified, and matching and testing are initiated after successful verification. The video stream corresponding to the parallel bar dip exercise is acquired by pre-deployed cameras, and the posture points are filtered by the human posture recognition model based on the video stream to obtain posture information. Threshold rule judgment based on attitude information for state machine transition simulation is used as the result of quantitative analysis; attitude information and video stream are input into a dual-stream neural network model, and the dual-stream neural network model outputs the deep analysis result. Warnings are issued based on quantitative and in-depth analysis results, and a detection report is generated after the exercise ends.
[0007] According to a second aspect of the present invention, a parallel bar dip motion detection device is provided, comprising: The startup module is used to verify the athlete's identity. Once the verification is successful, the matching and detection will be initiated. The extraction module is used to acquire video streams corresponding to parallel bar dips and extensions through pre-deployed cameras, and to filter posture points based on the video stream using a human posture recognition model to obtain posture information. The analysis module is used to determine the threshold rules for state machine transition simulation based on attitude information, and to provide the quantitative analysis results; it inputs attitude information and video stream into a dual-stream neural network model, and outputs deep analysis results through the dual-stream neural network model. The processing module is used to issue warnings based on quantitative and in-depth analysis results and generate a detection report after the exercise is completed.
[0008] According to a third aspect of the present invention, an electronic device is provided, comprising: a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the computer program, when executed by the processor, implements the steps of the parallel bar dip and extension motion detection method provided in the first aspect of the present disclosure.
[0009] According to a fourth aspect of the present invention, a computer-readable storage medium is provided, on which an information transmission implementation program is stored, which, when executed by a processor, implements the steps of the parallel bar dip and extension motion detection method provided in the first aspect of the present disclosure.
[0010] The technical solution provided by the embodiments of the present invention has the following beneficial effects: Based on the machine vision and artificial intelligence technology system, a complete process of automated detection of parallel bar dips is formed, which specifically includes identity verification, motion acquisition, posture analysis, counting judgment, violation warning and report generation, avoiding subjective errors of manual counting and effectively improving the detection efficiency of parallel bar dips.
[0011] It should be understood that the above general description and the following detailed description are exemplary and explanatory only, and are not intended to limit this disclosure. Attached Figure Description
[0012] To more clearly illustrate the technical solutions in one or more embodiments of this specification or in the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments recorded in this specification. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0013] Figure 1 This is a flowchart of the parallel bar arm flexion and extension motion detection method according to an embodiment of the present invention; Figure 2 This is a schematic diagram of the state machine transition according to an embodiment of the present invention; Figure 3 This is a schematic diagram of the design framework of an embodiment of the present invention; Figure 4 This is a schematic diagram of the detection preparation stage according to an embodiment of the present invention; Figure 5 This is a schematic diagram of the data acquisition stage in an embodiment of the present invention; Figure 6 This is a schematic diagram of the data processing and analysis stage of an embodiment of the present invention; Figure 7 This is a schematic diagram of the result evaluation and feedback stage of an embodiment of the present invention; Figure 8 This is a schematic diagram of the parallel bar arm flexion and extension motion detection device according to an embodiment of the present invention; Figure 9 This is a schematic diagram of an electronic device according to an embodiment of the present invention. Detailed Implementation
[0014] To enable those skilled in the art to better understand the technical solutions in one or more embodiments of this specification, the technical solutions in one or more embodiments of this specification will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only a part of the embodiments of this specification, and not all of the embodiments. Based on one or more embodiments of this specification, all other embodiments obtained by those skilled in the art without creative effort should fall within the protection scope of this document.
[0015] Method Example 1 According to an embodiment of the present invention, a method for detecting parallel bar dips and extensions is provided. Figure 1 This is a flowchart of the parallel bar dip and extension motion detection method according to an embodiment of the present invention, as follows: Figure 1 As shown, the parallel bar dip and extension motion detection method according to an embodiment of the present invention specifically includes: In step S110, the athlete's identity is verified. After successful verification, matching and detection are initiated, specifically including: Facial images of people are captured in front of a camera. The ArcFaca model is used to match the person's image with pre-stored information in the database, such as student ID and name. If a match is found, the verification is successful. After successful verification, the detection is bound to the corresponding person's information. The detection is started after the athlete holds the parallel bars in a preset position. The replacement of the verification model with a conventional model such as YOLOv8 is also within the scope of protection of this application; The camera captures the position of both hands and automatically marks the coordinates of the grip on the bar as G_left(x1,y1) and G_right(x2,y2), and binds them to the tester's identity. If no valid grip position is detected within 5 seconds, the system will prompt "Please adjust your grip posture" until the binding is successful.
[0016] ArcFace is an arc-shaped face recognition model, a high-precision face recognition algorithm based on deep learning. It achieves an accuracy of 99.83% on the LFW dataset. Combined with the spatial constraints of the hand grip position, it effectively avoids the problem of others taking the test on your behalf.
[0017] In this embodiment of the invention, the face recognition threshold is that a similarity of ≥90% is considered a successful match. The grip position error is allowed to have a coordinate deviation of ±5 pixels to avoid the binding failure caused by slight hand movements of the tester. Based on the above description, the starting conditions are: identity verification passed + grip position successfully bound + detection of the first state with arms straight, the system starts timing, the default assessment time is 1 minute, which can be configured in the backend; In step S120, a video stream corresponding to the parallel bar dip motion is acquired through a pre-deployed camera. Based on the video stream, posture points are filtered using a human posture recognition model to obtain posture information, specifically including: The OpenCV VideoCapture interface is called to synchronously acquire video streams from front and side cameras. Each frame is stored in RGB format with a resolution of 1920×1080 and a stable frame rate of 60fps. The image frames in the video stream are corrected, the region of interest is extracted from the corrected image, and the region of interest is then illuminated to obtain the processed image. Specifically, this includes: performing distortion correction on image frames, obtaining the intrinsic parameter matrix and distortion coefficients in advance using the checkerboard method, and using the cv2.undistort() function to eliminate lens distortion; The region of interest (ROI) is defined based on the grip coordinates. The ROI is defined based on the grip coordinates G_left and G_right, roughly from 200 pixels above the test subject's head to 300 pixels below the double bars, excluding background interference. A histogram equalization algorithm is used to perform illumination compensation on the region of interest, solving the problem of uneven image brightness caused by backlighting and shadows, and ensuring the accuracy of human key point detection.
[0018] The RTMPose model is used as the human pose recognition model. The RTMPose model is a real-time multi-person pose estimation model, which is an improvement on PP-HumanPose. Its inference speed reaches 100+ fps, which is suitable for real-time scenarios. It can be used to detect 17 key points of the human body. In this embodiment of the invention, in the processed image, pose points including the left shoulder, right shoulder, left elbow, right elbow, left wrist, and right wrist are extracted by the RTMPose model, represented as follows: left shoulder: L_Shoulder, right shoulder: R_Shoulder, left elbow: L_Elbow, right elbow: R_Elbow, left wrist: L_Wrist, right wrist: R_Wrist; The coordinates of each attitude point are determined by two-dimensional coordinates. The left coordinates are similar to L_Shoulder(x3,y3), L_Elbow(x4,y4), and L_Wrist(x5,y5), while the right coordinates are R_Shoulder(x3,y3), R_Elbow(x4,y4), and R_Wrist(x5,y5). Pose points with a confidence level greater than or equal to a preset confidence level are retained as pose information. In this embodiment of the invention, the preset confidence level is 0.8. Only the coordinates of key points with a confidence level ≥ 0.8 are retained to exclude false detections caused by blurred frames. If the confidence level of a certain key point is < 0.8 for 3 consecutive frames, the system prompts "Please adjust your body posture to ensure that the camera clearly captures the action".
[0019] In step S130, a threshold rule judgment is performed based on the attitude information to simulate the state machine transition, which is used as the result of the quantitative analysis. The attitude information and video stream are input into a dual-stream neural network model, and the deep analysis result is output through the dual-stream neural network model, specifically including: Based on trigonometric functions, calculate the angle formed by the left and right wrists, elbows, and shoulders. Use Formula 1 to calculate the angle Angle formed by the left or right wrists, elbows, and shoulders: Angle = arccos( (EL·ES) / (|EL|×|ES|) ) Formula 1; Where EL = (x5-x4, y5-y4) represents the wrist-to-elbow vector, i.e., wrist->elbow, ES = (x3-x4, y3-y4) represents the elbow-to-shoulder vector, i.e., elbow->shoulder, (x3,y3) represents the coordinates of the left or right shoulder posture point, (x4,y4) represents the coordinates of the left or right elbow posture point, and (x5,y5) represents the coordinates of the left or right wrist posture point; The unit for the included angle is degrees; When calculating the left included angle Angle_L, the left coordinates are used; when calculating the right included angle Angle_R, the right coordinates are used. The quantitative analysis process for parallel bar dip and extension motion detection is set as a state machine flow simulation. The standard motion process is defined by the following threshold rules for state transition: the initial state satisfies that the included angles on both sides are higher than or equal to the initial angle threshold before the assessment begins. During the motion, the process starts from the first state and realizes the transition between the first state and the second state until the end of the motion. In this embodiment of the invention, the initial angle threshold is 160°; The first state is similar to both walls being straightened, and the second state is similar to the arm being bent into place. The transition from the first state to the second state is successful if the average value of the included angle Angle on both sides is less than or equal to the arm flexion threshold for three consecutive frames, and both shoulders are lower than the elbow coordinates; that is, if "(Angle_L+Angle_R) / 2 ≤120° and the shoulders are lower than the elbows" is satisfied for three consecutive frames. The transition from the second state to the first state is successful when the included angle Angle on both sides is higher than the straightening threshold for three consecutive frames, and the real-time count is incremented by one; that is, when "Angle_L≥160° and Angle_R≥160°" is satisfied for three consecutive frames, the transition from the second state to the first state is successful. Figure 2 This is a schematic diagram of the state machine transition according to an embodiment of the present invention, as shown below. Figure 2 As shown, this demonstrates the simulation method of the state machine transition in the parallel bar dip extension exercise. A represents the first state, and B represents the second state, which includes the standard movement process and possible violations. If a violation occurs, it is not counted and the system returns to the previous state.
[0020] In this embodiment of the invention, the flexion threshold of 120° and the extension threshold of 160° are determined by statistical analysis of 1000+ standard movement samples with an error of ±5°.
[0021] The quantitative analysis process can intuitively obtain the current athlete's posture angle, that is, whether the angle change during the transition between states is reasonable. This helps to further apply warning rules based on intuitive data and facilitates automated counting. The test will stop when the time is up, or the athlete will stop voluntarily, for example, by taking their hands off the bar for ≥10 seconds. The removal detection is when the distance between L_Wrist and R_Wrist and G_left and G_right is greater than 50 pixels. If any of the above conditions are met, the voice prompt "The test is over" will be given and the counting will stop.
[0022] In-depth analysis is used for assessing motion quality that cannot be directly obtained; The sequence of attitude information during motion detection is represented in a two-dimensional image, which is obtained by stitching the images of each frame in time order from left to right in a two-dimensional image. Preferably, the trajectory lines corresponding to each attitude point are drawn in the two-dimensional image, and the trajectory lines are also input into the fully connected layer for analysis. Graph convolutional networks are used to extract spatial feature vectors from two-dimensional images, and LSTM models are used to extract temporal feature vectors from video streams. The spatial feature vector and the temporal feature vector are aligned on the timestamp, and the fused features are obtained through a cross-modal attention mechanism. The fused features are then input into a fully connected layer to output a deep analysis result on quality evaluation, and the motion quality level is output.
[0023] In step S140, a warning is issued based on the quantitative analysis results and the deep analysis results, and a detection report is generated after the exercise ends, specifically including: If the corresponding threshold rule is not met when transitioning from the first state, it will indicate that the arm is not bent properly, that is, the transition from the first state to the second state is not successful, or the action in the second state is not standard. If the shoulder does not extend beyond the elbow, i.e., L_Shoulder.y ≤ L_Elbow.y or R_Shoulder.y ≤ R_Elbow.y, a further prompt of "Shoulder not extending beyond the elbow, violation" can be displayed on the screen, a red warning icon will be displayed, the count will not be counted, and the system will return to the first state. If the corresponding threshold rule is not met when transitioning from the second state, it will indicate that the arms are not straight, that is, the transition from the second state to the first state is unsuccessful. It can also be considered that the action in the first state is not standard, so it will not be counted and will return to the second state. If the quality level of the in-depth analysis results is lower than the preset level, a quality deficiency will be indicated.
[0024] Perform data storage and report generation; After the assessment and analysis are completed, data will be stored, including the following: Basic information: Tester ID, name, assessment date, assessment duration; Action data: Real-time counting results, number of violations (statistically categorized), key point coordinates for each frame (stored in JSON format, supporting backtracking); Video data: Full assessment video (compressed to MP4 format, named according to "Tester ID_Date", stored in the cloud, and retained for 30 days). After the assessment and analysis, a PDF report is automatically generated, including the following: Cover: Tester information, assessment items, assessment time; Core data: Number of completions, number of violations (pie chart showing the percentage of violation types), average completion time; Movement analysis: Extracting 3 typical movement frames (state A, state B, violation frame), marking key points and angle values, and providing improvement suggestions, such as "There are too many instances of the shoulder not reaching the elbow; it is recommended to lower the body height when bending the arm"; Data export: Supports exporting detailed data in Excel format (counts every 10 seconds, angle changes) for coaches to analyze training effects.
[0025] In this embodiment of the invention, the system adopts a three-tier architecture of "end-edge-cloud", as follows: Terminal layer: responsible for image acquisition and basic interaction, including high-definition camera, display screen, and voice module; Edge layer: deployed on local server, responsible for real-time posture analysis, counting calculation, violation judgment, reducing cloud latency, and ensuring real-time processing of more than 30 frames per second; Cloud layer: used for data storage (historical test records, motion video backtracking), model iteration (optimizing posture estimation accuracy based on massive data), and multi-terminal data synchronization (such as data aggregation of multiple parallel bars areas in campus physical education assessment).
[0026] The hardware configuration is as follows: a 2-megapixel high-definition camera with a frame rate of 60fps and a resolution of 1920×1080, supporting H.265 encoding, with one camera each in front and to the side to cover blind spots; a local server configured with an Intel Xeon Silver 4314 processor (16 cores, 32 threads), 64GB DDR4 memory, and a 2TB SSD to meet real-time model inference requirements; a 1080P resolution display screen used to show the tester's identity, real-time action angle, counting results, and violation prompts; a voice module supporting Chinese speech synthesis and recognition for voice interactions such as "Assessment Start," "Violation Prompt," and "Assessment End"; and a network module supporting Gigabit Ethernet to ensure low-latency data transmission between the camera and the edge server, and between the edge layer and the cloud layer, with latency ≤50ms. The detection algorithm and other software implementations are based on Python 3.9. The core dependent libraries include OpenCV image processing, PyTorch deep learning model inference, MySQL data storage, and Flask, which is the web-based interactive interface, used to implement the functions involved in steps S110 to S140.
[0027] Method Example 2 In this embodiment of the invention, the preliminary preparations include equipment debugging, data entry, and parameter configuration; The equipment debugging process includes: starting the edge server, running the camera_calibration.py script to complete camera distortion correction; logging into the cloud management platform to confirm that the cameras and servers in the multi-parallel bar area are connected to the network and synchronized; The data entry process includes: importing student information (student ID, name, and facial photo) into the school's academic affairs system and storing it in a MySQL database; The parameter configuration process includes: setting the assessment duration (1 minute), angle threshold (first state A ≥ 160°, second state B ≤ 120°) and violation prompt voice content in the background.
[0028] The exercise and testing process is as follows: 1. Identity verification (30 seconds): The candidate stands in front of the display screen, and the system calls the camera to capture the face and match it with the database (if the match fails, the system will prompt "Please align with the camera again"); after the match is successful, the screen will prompt "Please hold the parallel bars with both hands". After the candidate holds the bars, the system will automatically mark the coordinates of the grip and bind the candidate's identity, and display "Identity verification passed, ready to start".
[0029] 2. Motion detection and counting (1 minute): When the candidate extends both arms, the system detects state A and announces "Assessment begins, 1 minute timer." The screen displays the countdown, current count (initially 0), and Angle_L / Angle_R values in real time. The candidate begins performing dips: when bending the arms, if the average Angle_L / Angle_R is ≤120° and the shoulder is lower than the elbow, the screen displays "State B (Bend in place)." After pushing back up, if Angle_L / Angle_R is ≥160°, the count increments by 1, and the screen flashes to indicate the count. If the "shoulder not above elbow" condition occurs, a red warning will be displayed on the screen, a voice prompt will indicate a violation, and the count will not increase.
[0030] 3. Assessment ends and report generated (30 seconds): Once the 1-minute countdown ends, the system will announce "Assessment complete" via voice prompt. The screen will display "15 completed attempts, 2 violations, 1 instance of shoulder not reaching elbow, 1 instance of arms not fully extended"; and will perform a deep analysis based on a dual-flow neural network model. Click "Generate Report" and the system will automatically export a PDF report, which candidates can scan to save to their mobile phones. At the same time, the data will be synchronized to the school's physical education assessment system.
[0031] The following are the contents of post-processing data management: Administrators can log in to the cloud platform to view the assessment data of all candidates (filtered by class and student ID), and export a summary Excel spreadsheet. If candidates have any objections to their scores, they can use the "Video Review" function to view the entire assessment video and the key points and angle data of each frame to ensure fairness. A weekly "grade assessment analysis report" is automatically generated, which statistically analyzes the average number of completions and the distribution of violation types, providing a basis for improving physical education teaching.
[0032] Preferably, in the embodiments of the present invention, the effect is verified, including accuracy verification and efficiency verification: Accuracy Verification: Test Environment: 10 candidates (5 males and 5 females, aged 18-22), each candidate completed 2 sets of assessments (1 minute per set); Comparison Method: System counting vs. manual counting (2 professional physical education teachers counted independently, and the average value was taken); Results: The error rate between system counting and manual counting was ≤3% (only 1 case was missed due to slight obstruction by the candidate's hand), and the angle detection error was ≤2° (compared with manual measurement using a protractor).
[0033] Efficiency verification: Traditional manual assessment can be completed by one teacher for 20 candidates per hour (including counting, recording, and score entry); this system can complete the assessment of 45 candidates per hour in one parallel bar area (no manual counting required, reports are automatically generated), improving efficiency by 125%.
[0034] In this embodiment of the invention, the athlete feedback screen displays the angle and count in real time, enabling timely adjustments to movements. Violation prompts are clear and more transparent than manual counting. Teachers do not need to focus on counting and can pay more attention to the standardization of the examinee's movements, saving a lot of time in subsequent data statistics.
[0035] The above technical solutions of the embodiments of the present invention will be illustrated with reference to the following accompanying drawings.
[0036] Figure 3 This is a schematic diagram of the design framework of an embodiment of the present invention, as shown below. Figure 3 As shown, the parallel bar dip motion detection module includes motion recognition and judgment criteria, real-time data processing and feedback, system functions and modes, anti-cheating and security, data management and analysis, and system security and privacy.
[0037] Figure 4 This is a schematic diagram of the detection preparation stage according to an embodiment of the present invention; Figure 5 This is a schematic diagram of the data acquisition stage in an embodiment of the present invention; Figure 6 This is a schematic diagram of the data processing and analysis stage of an embodiment of the present invention; Figure 7 This is a schematic diagram of the result evaluation and feedback stage of an embodiment of the present invention; as shown below. Figures 4 to 7 As shown, the mind map document generated in the initial stage of each design scheme serves as the basis for the final parallel bar dip extension exercise testing scheme.
[0038] In summary, addressing the existing problems, this invention presents a parallel bar dip motion detection method. Based on machine vision and artificial intelligence technologies, it establishes a complete automated detection process for parallel bar dips, including identity verification, motion acquisition, posture analysis, counting and judgment, violation warning, and report generation. This avoids subjective errors from manual counting and effectively improves the efficiency of parallel bar dip motion detection. Specifically, in addition to data correction and other preprocessing during human posture point extraction, it also divides the region of interest to narrow down the subject area of the athlete in the image, improving the accuracy of human posture recognition. Based on the periodic characteristics of the parallel bar dip motion, a state machine flow simulation is set up to achieve accurate motion stage recognition and segmentation, avoiding stage-based misjudgments. The dual-stream neural network model goes beyond simple counting or completion judgment, obtaining more comprehensive and in-depth evaluation results through multimodal information complementarity. Overall, it is a highly efficient and accurate detection and counting method.
[0039] Device Examples According to an embodiment of the present invention, a device for detecting dip and extension motion on parallel bars is provided. Figure 8 This is a schematic diagram of the parallel bar dip and extension motion detection device according to an embodiment of the present invention, as shown below. Figure 8 As shown, the parallel bar dip and extension motion detection device according to an embodiment of the present invention specifically includes: Module 80 is used to verify the athlete's identity. After successful verification, it initiates matching and detection. Specifically, it is used for: Facial images of people are captured in front of a camera. The ArcFaca model is used to match the person's image with the pre-stored information in the database. If a match is found, the verification is successful. After successful verification, the detection is bound to the corresponding person's information, and the detection is started when the current athlete holds the parallel bars in a preset designated position.
[0040] Extraction module 82 is used to acquire video streams corresponding to parallel bar dips and extensions via pre-deployed cameras, and to filter posture points based on the video stream using a human posture recognition model to obtain posture information. Specifically, it is used for: The image frames in the video stream are corrected, the region of interest is extracted from the corrected image, and illumination compensation is performed on the region of interest to obtain the processed image. Specifically, this includes: performing distortion correction on the image frames, dividing the region of interest based on the lever coordinates, and performing illumination compensation on the region of interest using a histogram equalization algorithm.
[0041] The RTMPose model is used as the human pose recognition model. In the processed image, the RTMPose model extracts pose points including the left shoulder, right shoulder, left elbow, right elbow, left wrist, and right wrist. Pose points with a confidence level greater than or equal to the preset confidence level are retained as pose information.
[0042] Analysis module 84 is used for threshold rule determination in state machine transition simulation based on attitude information, as the result of quantitative analysis; it inputs attitude information and video stream into a dual-stream neural network model, and outputs deep analysis results through the dual-stream neural network model, specifically for: Use Formula 1 to calculate the angle Angle formed by the three points: left or right wrist, elbow, and shoulder. Angle = arccos( (EL·ES) / (|EL|×|ES|) ) Formula 1; Where EL = (x5-x4, y5-y4) represents the wrist-to-elbow vector, ES = (x3-x4, y3-y4) represents the elbow-to-shoulder vector, (x3,y3) represents the coordinates of the left or right shoulder posture point, (x4,y4) represents the coordinates of the left or right elbow posture point, and (x5,y5) represents the coordinates of the left or right wrist posture point. The quantitative analysis process for parallel bar dip and extension motion detection is set as a state machine flow simulation. The standard motion process is defined by the following threshold rules for state transition: the initial state satisfies that the included angles on both sides are higher than or equal to the initial angle threshold before the assessment begins. During the motion, the process starts from the first state and realizes the transition between the first state and the second state until the end of the motion. Among them, the transition from the first state satisfies that the average value of the included angles Angle on both sides is less than or equal to the flexion threshold for consecutive preset frames, and both shoulders are lower than the elbow coordinate; the transition from the second state satisfies that the included angles Angle on both sides are higher than the straightening threshold for consecutive preset frames, and the real-time count is incremented by one. The sequence of pose information during motion detection is represented in a two-dimensional image. A graph convolutional network is used to extract spatial feature vectors from the two-dimensional image, and an LSTM model is used to extract temporal feature vectors from the video stream. Spatial and temporal feature vectors are aligned on timestamps, and fused features are obtained through a cross-modal attention mechanism. The fused features are then input into a fully connected layer to output deep analysis results on quality assessment.
[0043] Module 86, used for processing, issues warnings based on quantitative and in-depth analysis results and generates a detection report after the exercise is completed. Specifically, it is used for: If the corresponding threshold rule is not met when transitioning from the first state, an error message will be displayed indicating that the arm is not fully bent. If the corresponding threshold rule is not met when transitioning from the second state, a message will be displayed indicating that the arms are not fully extended. If the quality level of the in-depth analysis results is lower than the preset level, a quality deficiency will be indicated.
[0044] In summary, addressing the existing problems, this invention, a parallel bar dip motion detection device, is based on machine vision and artificial intelligence technologies. It establishes a complete automated detection process for parallel bar dips, including identity verification, motion acquisition, posture analysis, counting and judgment, violation warning, and report generation. This avoids subjective errors from manual counting and effectively improves the efficiency of parallel bar dip motion detection. Specifically, in human posture point extraction, in addition to data correction and other preprocessing, it also divides the region of interest to narrow down the subject area of the athlete in the image, improving the accuracy of human posture recognition. Based on the periodic characteristics of the parallel bar dip motion, a state machine flow simulation is set up to achieve accurate action stage recognition and segmentation, avoiding stage-based misjudgments. The dual-stream neural network model goes beyond simple counting or completion judgment, obtaining more comprehensive and in-depth evaluation results through multimodal information complementarity. Overall, it is a highly efficient and accurate detection and counting method.
[0045] Electronic device examples Figure 9 This is a schematic diagram of an electronic device according to an embodiment of the present invention. The electronic device 900 may include at least one processor 910 and a memory 920. The processor 910 can execute instructions stored in the memory 920. The processor 910 is communicatively connected to the memory 920 via a data bus. In addition to the memory 920, the processor 910 can also be communicatively connected to an input device 930, an output device 940, and a communication device 950 via the data bus.
[0046] Processor 910 can be any conventional processor, such as a commercially available CPU. Processors may also include graphics processing units (GPUs), field-programmable gate arrays (FPGAs), systems on chips (SOCs), application-specific integrated circuits (ASICs), or combinations thereof.
[0047] The memory 920 can be implemented by any type of volatile or non-volatile storage device or a combination thereof, such as static random access memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic storage, flash memory, magnetic disk or optical disk.
[0048] In this embodiment of the present disclosure, the memory 920 stores executable instructions, and the processor 910 can read the executable instructions from the memory 920 and execute the instructions to implement all or part of the steps of the parallel bar dip and extension motion detection method in any of the exemplary embodiments described above.
[0049] Computer-readable storage medium embodiments In addition to the methods and apparatus described above, exemplary embodiments of this disclosure may also be a computer program product or a computer-readable storage medium storing the computer program product, the computer product including computer program instructions that can be executed by a processor to implement all or part of the steps described in any of the parallel bar dip and extension motion detection methods in the exemplary embodiments described above.
[0050] Computer program products can be written in any combination of one or more programming languages to perform the operations of the embodiments of this application. Programming languages include object-oriented programming languages such as Java and C++, as well as conventional procedural programming languages such as C or similar languages, and scripting languages (e.g., Python). The program code can be executed entirely on the user's computing device, partially on the user's device, as a standalone software package, partially on the user's computing device and partially on a remote computing device, or entirely on a remote computing device or server.
[0051] Computer-readable storage media may be any combination of one or more readable media. A readable medium may be a readable signal medium or a readable storage medium. A readable storage medium may be, for example,, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination thereof. More specific examples of readable storage media include: static random access memory (SRAM) having one or more electrically connected wires; electrically erasable programmable read-only memory (EEPROM); erasable programmable read-only memory (EPROM); programmable read-only memory (PROM); read-only memory (ROM); magnetic storage; flash memory; magnetic disk or optical disk; or any suitable combination thereof.
[0052] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, and not to limit them; although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some or all of the technical features; and these modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the scope of the technical solutions of the embodiments of the present invention.
Claims
1. A method for detecting parallel bar dips, characterized in that, include: The athlete's identity is verified, and matching and testing are initiated after successful verification. The video stream corresponding to the parallel bar dip exercise is acquired by pre-deployed cameras, and the posture points are filtered through the human posture recognition model based on the video stream to obtain posture information. Threshold rule judgment is performed based on the attitude information to simulate the state machine transition, and this is used as the result of quantitative analysis. The pose information and the video stream are input into a dual-stream neural network model, and the dual-stream neural network model outputs depth analysis results. Warnings are issued based on the quantitative analysis results and the in-depth analysis results, and a detection report is generated after the exercise ends.
2. The method according to claim 1, characterized in that, The process of verifying the athlete's identity and initiating matching and detection upon successful verification specifically includes: Facial images of people are captured in front of a camera. The ArcFaca model is used to match the personnel image with the pre-stored information in the database. If a match is found, the verification is successful. After successful verification, the detection is bound to the corresponding personnel information, and the detection is started after the current athlete grips the parallel bars at a preset designated position.
3. The method according to claim 1, characterized in that, The step of filtering posture points based on the video stream using a human posture recognition model to obtain posture information specifically includes: The image frames in the video stream are corrected, the region of interest is extracted from the corrected image, and the region of interest is subjected to illumination compensation to obtain the processed image. Using the RTMPose model as a human pose recognition model, pose points including the left shoulder, right shoulder, left elbow, right elbow, left wrist, and right wrist are extracted from the processed image using the RTMPose model. Pose points with a confidence level greater than or equal to a preset confidence level are retained as the pose information.
4. The method according to claim 3, characterized in that, The process of correcting image frames in the video stream, extracting regions of interest (ROIs) from the corrected images, and performing illumination compensation on the ROIs to obtain the processed images specifically includes: performing distortion correction on the image frames, dividing the ROIs based on lever coordinates, and performing illumination compensation on the ROIs using a histogram equalization algorithm.
5. The method according to claim 1, characterized in that, The threshold rule judgment for state machine transition simulation based on the attitude information, as a result of quantitative analysis, specifically includes: Use Formula 1 to calculate the angle Angle formed by the three points: left or right wrist, elbow, and shoulder. Angle = arccos( (EL·ES) / (|EL|×|ES|) ) Formula 1; Where EL = (x5-x4, y5-y4) represents the wrist-to-elbow vector, ES = (x3-x4, y3-y4) represents the elbow-to-shoulder vector, (x3,y3) represents the coordinates of the left or right shoulder posture point, (x4,y4) represents the coordinates of the left or right elbow posture point, and (x5,y5) represents the coordinates of the left or right wrist posture point. The quantitative analysis process for parallel bar dip and extension motion detection is set as a state machine flow simulation. The standard motion process is defined by the following threshold rules for state transition: the initial state satisfies that the included angles on both sides are higher than or equal to the initial angle threshold before the assessment begins. During the motion, the process starts from the first state and realizes the transition between the first state and the second state until the end of the motion. Specifically, the transition from the first state satisfies the following conditions: the average value of the included angles Angle on both sides is less than or equal to the flexion threshold for consecutive preset frames, and both shoulders are lower than the elbow coordinate; the transition from the second state satisfies the following conditions: the included angles Angle on both sides are higher than the straightening threshold for consecutive preset frames, and the real-time count is incremented by one.
6. The method according to claim 1, characterized in that, The step of inputting the pose information and the video stream into a dual-stream neural network model, and outputting depth analysis results through the dual-stream neural network model, specifically includes: The sequence of pose information during motion detection is represented in a two-dimensional image. A graph convolutional network is used to extract spatial feature vectors from the two-dimensional image, and an LSTM model is used to extract temporal feature vectors from the video stream. The spatial feature vector and the temporal feature vector are aligned on the timestamp, and a fused feature is obtained through a cross-modal attention mechanism. The fused feature is then input into a fully connected layer to output a deep analysis result on quality evaluation.
7. The method according to claim 5, characterized in that, The warning based on the quantitative analysis results and the in-depth analysis results specifically includes: If the corresponding threshold rule is not met when transitioning from the first state, an indication will be given that the arm is not fully bent. If the corresponding threshold rule is not met when transitioning from the second state, a message will be displayed indicating that the arms are not fully extended. If the quality level described by the in-depth analysis result is lower than the preset level, a quality deficiency will be indicated.
8. A device for detecting dip and extension motion on parallel bars, characterized in that, include: The startup module is used to verify the athlete's identity. Once the verification is successful, the matching and detection will be initiated. The extraction module is used to acquire video streams corresponding to parallel bar dips and extensions through pre-deployed cameras, and to filter posture points based on the video streams using a human posture recognition model to obtain posture information. The analysis module is used to determine the threshold rules for state machine transition simulation based on the attitude information, and to use the results of the quantitative analysis. The pose information and the video stream are input into a dual-stream neural network model, and the dual-stream neural network model outputs depth analysis results. The processing module is used to issue warnings based on the quantitative analysis results and the deep analysis results, and to generate a detection report after the exercise ends.
9. An electronic device, characterized in that, include: The memory, the processor, and the computer program stored in the memory and executable on the processor, wherein the computer program, when executed by the processor, implements the steps of the parallel bar dip and extension motion detection method as described in any one of claims 1 to 7.
10. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores an implementation program for information transmission, which, when executed by a processor, implements the steps of the parallel bar dip and extension motion detection method as described in any one of claims 1 to 7.