Competition wonderful moment identification method and system based on tracking holder data
By analyzing angle changes based on tracking gimbal data and identifying AI models, ball game videos can be edited quickly and accurately, solving the problem of existing technologies being unable to capture key moments. This enables efficient and accurate identification and editing of exciting moments, and is suitable for a variety of ball sports such as basketball and football.
Patent Information
- Application Number
- CN202510889511.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-06-30
- Publication Date
- 2025-10-03
AI Technical Summary
Existing automatic editing methods cannot accurately capture key moments in ball games, such as goals and wonderful passes. The editing is not smart enough, resulting in videos that are too long or lack logical coherence, and cannot accurately capture the emotions and rhythm of different stages of the game.
By analyzing the angle changes based on the tracking gimbal data and combining it with the time window to quickly judge fast break events, the AI model is used to identify player movements and goal events, mark and edit the highlights of the game, and support user-defined adjustments.
It achieves fast, accurate and efficient recognition of exciting moments in games, reduces manual intervention, improves editing efficiency, enhances video logic coherence and user experience, is adaptable to a variety of ball sports, and is versatile and configurable.
Smart Images

Figure CN120751199A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of computer vision, and more particularly to a method and system for identifying exciting moments in a match based on tracking pan-tilt data. Background Art
[0002] With the development of image processing technology, more and more scenes are being edited to form corresponding highlights. For example, automatic editing is used in ball sports (such as basketball, football, etc.) game videos.
[0003] Traditional video editing of sports matches usually requires manual work, which is time-consuming and prone to missing important moments. In recent years, with the rapid development of AI technology and computer vision, automated video processing technology has gradually been applied to the sports field.
[0004] However, existing automatic editing methods have the following shortcomings: they cannot accurately capture key game moments, such as goals and wonderful passes; the editing is not smart enough, resulting in videos that are too long or lack logical coherence; and they are not accurate enough in capturing the emotions and rhythm of different stages of the game.
[0005] The above statements are only used to provide background technical information related to this application. Unless otherwise indicated herein, the contents described in this section are not prior art for the contents of other parts of this application. Summary of the Invention
[0006] In response to the above-mentioned technical limitations, the present application provides a method and system for identifying exciting moments in a game based on tracking pan-tilt data. By analyzing the angle changes based on the pan-tilt rotation log and combining it with the time window to quickly judge fast break events, the fast break events of the game can be quickly, accurately and completely identified. Then, through marking and editing, the video of the ball game can be edited in a more efficient and intelligent way, providing users with one-click generation of accurate short videos of exciting moments.
[0007] In addition, this application generates wonderful clips with one click, significantly reducing manual intervention, improving editing efficiency, and achieving efficient and accurate editing.
[0008] This application uses gimbal data and AI models to more accurately identify fast breaks, effective attacks, and goal-scoring events.
[0009] This application supports user-defined adjustments, enhances video logic coherence and user experience, and realizes dynamic adaptability of video editing.
[0010] This application is suitable for various ball sports such as basketball and football. It is universal and configurable, and achieves cross-scenario compatibility.
[0011] According to a first aspect of an embodiment of the present application, a method for identifying highlight moments of a game based on tracking pan / tilt data is provided, comprising:
[0012] Obtain game video data, video timeline data, and tracking gimbal rotation logs shot by the tracking gimbal;
[0013] Parse the rotation log and calculate the gimbal angle change rate within a preset time window based on the gimbal rotation angle and timestamp. When the angle change rate exceeds the threshold, it is identified as a fast attack event.
[0014] Identify and mark fast break event videos based on the fast break event time window;
[0015] Identify game highlights based on fast break event videos.
[0016] In some embodiments of the present application, identifying game highlights based on a fast break event video includes:
[0017] Get the fast break event video within the preset time period with the fast break event time window as the center;
[0018] Extracting multiple frames of continuous fast-break images in a fast-break event video;
[0019] Input the fast break image into the human action recognition model or the goal recognition model;
[0020] When a player's action is recognized as a valid action or a goal event is recognized, the fast break event video is determined to be a highlight moment of the game, and the fast break event video is marked on the video timeline.
[0021] In some embodiments of the present application, identifying a player's action as a valid action or identifying a goal-scoring event includes:
[0022] The human action recognition model identifies the player's action sequence based on fast break images;
[0023] The result of analyzing the action sequence is a shooting action or a goal-shooting action, and the action sequence is determined to be a valid action. The shooting action or the goal-shooting action includes raising the ball with both hands and releasing the hand to shoot the ball; the goal-shooting action includes volleying the ball with a big foot.
[0024] In some embodiments of the present application, identifying a player's action as a valid action or identifying a goal-scoring event includes:
[0025] Identify fast break images through target recognition algorithms to identify ball targets and goal areas;
[0026] The overlap between the ball target and the goal area is judged and detected, and it is determined as a goal event.
[0027] In some embodiments of the present application, performing overlap determination and detecting the overlap between the ball target and the goal area includes:
[0028] Determine the trajectory of the ball target;
[0029] When the distance between the ball target's motion trajectory and the goal area is within a certain threshold, it is determined that the ball target overlaps with the goal area.
[0030] In some embodiments of the present application, after determining that the ball target overlaps with the goal area, the method further includes:
[0031] Detecting that the center of the ball's trajectory coincides with the center of the goal area, and detecting that the player moves outward and crosses the baseline within a certain period of time, and determining the moment of coincidence as the time of successful goal;
[0032] Alternatively, it is detected that the center of the ball target motion trajectory stays in the goal area for more than a threshold value, and the starting point of the area overlap is determined as the time point when the goal is successfully scored.
[0033] Next, when editing, obtain the successful goal video within the preset time length floating around the successful goal time point, and mark the successful goal video on the video timeline.
[0034] In some embodiments of the present application, identifying game highlights based on a fast break event video includes:
[0035] Determine the time point of each successful goal in the game to form a time point set of successful goal events;
[0036] The fast break event video is edited based on the time point set of the goal success event to obtain the goal highlight moment video.
[0037] In some embodiments of the present application, after obtaining the game video data shot by the tracking gimbal, the method further includes:
[0038] Perform frame extraction processing on the game video data according to the preset frame extraction interval;
[0039] The extracted images are read and saved frame by frame.
[0040] According to a second aspect of an embodiment of the present application, a method for editing game highlights is provided, comprising:
[0041] Apply the method for identifying the exciting moments of the game to identify the exciting moments of the game;
[0042] Receive video editing parameters adjusted by the user, including the total video length, the length of the highlights clip, and the video acceleration / deceleration multiples;
[0043] Edit the highlights of the game according to the video editing parameters and generate customized videos of the highlights.
[0044] According to a third aspect of an embodiment of the present application, a system for identifying highlight moments in a match based on tracking pan / tilt data is provided, comprising:
[0045] PTZ data acquisition module: used to obtain the game video data shot by the tracking PTZ, video timeline data and the rotation log of the tracking PTZ;
[0046] Fast-break event recognition module: This module parses rotation logs and calculates the PTZ angle change rate within a preset time window based on the PTZ rotation angle and timestamp. When the angle change rate exceeds a threshold, it is identified as a fast-break event.
[0047] Video marking module: used to mark and identify fast break event videos based on the fast break event time window;
[0048] Video recognition module: used to identify exciting moments of the game based on fast break event videos.
[0049] According to a fourth aspect of an embodiment of the present application, a system for editing highlights of a match based on tracking pan / tilt data is provided, comprising:
[0050] A wonderful moment recognition module is used to apply a wonderful moment recognition method to identify the wonderful moments of the game;
[0051] A parameter adjustment module is used to receive video editing parameters adjusted by the user, including the total length of the video, the length of the highlight moment clip, and the video acceleration / deceleration multiples;
[0052] The video editing module is used to edit the exciting moments of the game according to the video editing parameters and generate customized videos of the exciting moments.
[0053] According to the fifth aspect of the embodiment of the present application, a device for identifying exciting moments of a game based on tracking pan-tilt data is provided, including: a storage unit for storing executable instructions; and a processing unit for connecting to the memory to execute the executable instructions to complete a method for identifying exciting moments of a game based on tracking pan-tilt data.
[0054] According to the sixth aspect of the embodiment of the present application, a device for editing the highlights of a match based on tracking pan-tilt data is provided, comprising: a storage unit for storing executable instructions; and a processing unit for connecting to the memory to execute the executable instructions to complete a method for editing the highlights of a match based on tracking pan-tilt data.
[0055] According to a seventh aspect of an embodiment of the present application, a computer-readable storage medium is provided, on which a computer program is stored; the computer program is executed by a processor to implement a method for identifying or editing game highlights based on tracking pan-tilt data.
[0056] The method and system for identifying game highlights based on tracking gimbal data of the present application include obtaining game video data, video timeline data, and a rotation log of the tracking gimbal shot based on the tracking gimbal; parsing the rotation log, and calculating the angle change rate of the gimbal within a preset time window based on the gimbal rotation angle and timestamp; identifying a fast break event when the angle change rate exceeds a threshold; determining and marking the fast break event video based on the fast break event time window; and identifying game highlights based on the fast break event video. The present invention analyzes the angle changes based on the gimbal rotation log, combines it with the time window to quickly determine fast break events, and quickly, accurately, and completely identifies game fast break events. Then, through marking and editing, it achieves a more efficient and intelligent way to edit ball game videos, providing users with a one-click method to generate accurate short videos of highlights.
[0057] Compared with traditional video editing, this application generates highlights with one click, significantly reducing manual intervention, improving editing efficiency, and achieving efficient and accurate editing. This application can more accurately identify fast breaks, effective offenses, and goal-scoring events by linking pan-tilt data with AI models. This application supports user-defined adjustments, enhances video logic coherence and user experience, and achieves dynamic adaptability of video editing. This application is suitable for a variety of ball sports such as basketball and football, is universal and configurable, and achieves cross-scene compatibility. BRIEF DESCRIPTION OF THE DRAWINGS
[0058] The drawings described herein are used to provide a further understanding of the present application and constitute a part of the present application. The illustrative embodiments of the present application and their descriptions are used to explain the present application and do not constitute an improper limitation on the present application. In the drawings:
[0059] Figure 1 : A schematic diagram showing the steps of a method for identifying exciting moments of a game based on tracking PTZ data according to an embodiment of the present application is shown;
[0060] Figure 2 : A schematic diagram of steps for identifying exciting moments of a game based on a fast break event video according to an embodiment of the present application is shown;
[0061] Figure 3 : A schematic diagram of the steps of identifying player actions according to an embodiment of the present application is shown;
[0062] Figure 4 : shows another schematic diagram of steps for identifying player actions according to an embodiment of the present application;
[0063] Figure 5 ] shows another schematic diagram of steps for identifying exciting moments of a game based on a fast break event video according to an embodiment of the present application;
[0064] Figure 6: A schematic diagram of the steps of a method for editing exciting moments of a game according to an embodiment of the present application is shown;
[0065] Figure 7 : shows a flow chart of a method for identifying and editing exciting moments of a game according to an embodiment of the present application;
[0066] Figure 8 : shows a schematic diagram of a process for determining the time point of each successful goal in a game according to an embodiment of the present application;
[0067] Figure 9 : shows a schematic diagram of target frame detection of a target detection model according to an embodiment of the present application;
[0068] Figure 10 : shows a schematic diagram of detecting a successful basketball goal according to an embodiment of the present application;
[0069] Figure 11 : shows a schematic structural diagram of a system for identifying exciting moments of a match based on tracking PTZ data according to an embodiment of the present application;
[0070] Figure 12 : shows a schematic structural diagram of a system for editing highlights of a match based on tracking PTZ data according to an embodiment of the present application;
[0071] Figure 13 2 is a schematic structural diagram of a device 400 for identifying exciting moments in a match based on tracking pan-tilt data according to an embodiment of the present application. DETAILED DESCRIPTION
[0072] Regarding this application, with the rapid development of AI technology and computer vision, automated video processing technology has gradually been applied to the field of sports. Furthermore, with the development of image processing technology, more and more scenes are being edited to form corresponding highlights, allowing users to quickly watch game content.
[0073] However, existing automatic editing methods have the following shortcomings: they cannot accurately capture key game moments, such as goals and wonderful passes; the editing is not smart enough, resulting in videos that are too long or lack logical coherence; and they are not accurate enough in capturing the emotions and rhythm of different stages of the game.
[0074] An automatic tracking gimbal can control its built-in lens or a camera mounted on it to track and film specific targets throughout the game. Because automatic tracking focuses on key targets on the field, the gimbal's rotation plays an important auxiliary role in identifying the game's highlights. Based on this, the present invention aims to provide a highlight-moment marking algorithm based on tracking gimbal data and AI, enabling more efficient and intelligent editing of ball game videos, providing users with the ability to generate short videos of highlights with a single click.
[0075] In summary, the method and system for identifying game highlights based on tracking gimbal data provided by this application quickly judges fast break events by analyzing the angle changes based on the gimbal rotation log and combining it with the time window, and quickly, accurately and completely identifies game fast break events. Then, through marking and editing, it achieves a more efficient and intelligent way to edit ball game videos, providing users with one-click generation of accurate short videos of highlights.
[0076] In addition, this application generates wonderful clips with one click, significantly reducing manual intervention, improving editing efficiency, and achieving efficient and accurate editing.
[0077] This application uses gimbal data and AI models to more accurately identify fast breaks, effective attacks, and goal-scoring events.
[0078] This application supports user-defined adjustments, enhances video logic coherence and user experience, and realizes dynamic adaptability of video editing.
[0079] This application is suitable for various ball sports such as basketball and football. It is universal and configurable, and achieves cross-scenario compatibility.
[0080] In order to make the technical solutions and advantages of the embodiments of the present application more clearly understood, the exemplary embodiments of the present application are further described in detail below with reference to the accompanying drawings. Obviously, the described embodiments are only part of the embodiments of the present application, and are not an exhaustive list of all the embodiments. It should be noted that the embodiments and features in the embodiments of the present application can be combined with each other unless they conflict.
[0081] In the field of computer vision analysis, it is generally assumed that the origin of the coordinate system is located in the upper left corner of the screen. In the various embodiments of the present application, unless otherwise stated, the upper left corner is used as the origin of the coordinate system of the screen. Those skilled in the art should know that such a coordinate system setting is not absolutely fixed. When the origin of the coordinate system is set at any position inside or outside the screen, the corresponding technical solutions that can be obtained by simple adjustments to this solution without creative labor are all within the scope of protection of this application.
[0082] Example 1
[0083] Figure 1 2 is a schematic diagram showing the steps of a method for identifying exciting moments of a game based on tracking pan-tilt data according to an embodiment of the present application.
[0084] like Figure 1 As shown, a method for identifying exciting moments in a game based on tracking PTZ data in an embodiment of the present application includes:
[0085] S1: Obtain the game video data, video timeline data and tracking gimbal rotation log shot by the tracking gimbal;
[0086] S2: Parse the rotation log and calculate the gimbal angle change rate within a preset time window based on the gimbal rotation angle and timestamp. When the angle change rate exceeds a threshold, it is identified as a fast attack event.
[0087] S3: Determine and mark the fast break event video according to the fast break event time window;
[0088] S4: Identifying game highlights based on fast break event videos.
[0089] By analyzing the angle changes based on the pan-tilt rotation log and combining it with the time window, fast break events can be quickly judged, and fast break events in the game can be identified quickly, accurately and completely. Then, through marking and editing, ball game videos can be edited in a more efficient and intelligent way, providing users with the ability to generate accurate short videos of exciting moments with one click.
[0090] Figure 2 2 is a schematic diagram showing the steps of identifying exciting moments of a game based on a fast break event video according to an embodiment of the present application.
[0091] like Figure 2 As shown, in a specific implementation, in S4, identifying the exciting moments of the game based on the fast break event video includes:
[0092] Optionally, the fast break event video is accurately obtained within a preset time length floating around the fast break event time window.
[0093] S41: extracting multiple frames of continuous fast break images in the fast break event video;
[0094] S42: Inputting the fast break image into a human action recognition model or a goal recognition model to recognize player actions;
[0095] S43: When the player's action is recognized as a valid action or a goal event is recognized, the fast break event video is determined to be a highlight moment of the game, and the fast break event video is marked on the video timeline.
[0096] This application uses gimbal data and AI models to more accurately identify fast breaks, effective attacks, and goal-scoring events.
[0097] This application is suitable for various ball sports such as basketball and football. It is universal and configurable, and achieves cross-scenario compatibility.
[0098] Figure 3 Schematic diagram of the steps of identifying player actions according to an embodiment of the present application is shown in FIG.
[0099] like Figure 3As shown, in S43, when the player's action is identified as a valid action or a goal event is identified, the following steps are included:
[0100] S431: Human action recognition model identifies player action sequences based on fast break images;
[0101] S432: Analyze the action sequence to obtain a result of a shooting action or a goal-shooting action, and determine that the action sequence is a valid action.
[0102] The shooting action or the shooting action includes raising the ball with both hands and shooting the ball; the shooting action includes kicking the football with a big foot.
[0103] Figure 4 FIG. 2 shows another schematic diagram of steps for identifying player actions according to an embodiment of the present application.
[0104] like Figure 4 As shown, in S43, when the player's action is identified as a valid action or a goal event is identified, the following steps are included:
[0105] S4301: Identify the fast break image using a target recognition algorithm to identify the ball target and goal area;
[0106] S4302: Determine the overlap between the ball target and the goal area, detect the overlap, and determine it as a goal event.
[0107] In a preferred embodiment, performing overlap determination and detecting the overlap between the ball target and the goal area in S4302 includes the following steps:
[0108] 1) First, determine the trajectory of the ball target;
[0109] 2) The system then determines if the distance between the ball's trajectory and the goal area is within a certain threshold. The threshold can be set to a default value or customized.
[0110] In a preferred embodiment, after determining that the ball target overlaps with the goal area in S4302, further distinguishing the exciting moments of a successful goal is performed, specifically including the following steps:
[0111] When the center of the ball's trajectory is detected to coincide with the center of the goal area, and a player is detected moving outward across the baseline of the court within a certain period of time, the moment of coincidence is determined to be the time when the goal was successfully scored; this method is particularly suitable for basketball.
[0112] Or it is detected that the center of the ball target's motion trajectory stays in the goal area for more than a threshold, and the starting point of the area overlap is determined as the time point when the goal is successfully scored. This method is particularly suitable for football.
[0113] Next, when editing, obtain the successful goal video within the preset time length floating around the successful goal time point, and mark the successful goal video on the video timeline.
[0114] Figure 5 FIG2 shows another schematic diagram of steps for identifying exciting moments of a game based on a fast break event video according to an embodiment of the present application.
[0115] like Figure 5 As shown, in another preferred embodiment, identifying the exciting moments of the game based on the fast break event video in S4 includes:
[0116] S401: Determine the time point of each successful goal in the game to form a time point set of successful goal events;
[0117] S402: Identify exciting moments of the game based on the goal success event time point set.
[0118] Then, the fast break event video is edited based on the exciting moments of the game to obtain the exciting moment video of the goal.
[0119] In a preferred embodiment, after S1 obtains the game video data shot by the tracking gimbal, it also includes performing frame extraction processing on the game video data according to a preset frame extraction interval, and then reading and saving the images obtained by the frame extraction frame by frame.
[0120] The method for identifying exciting moments in a game based on tracking gimbal data according to an embodiment of the present application includes obtaining game video data, video timeline data, and a rotation log of the tracking gimbal shot based on the tracking gimbal; parsing the rotation log, and calculating the angle change rate of the gimbal within a preset time window based on the gimbal rotation angle and timestamp; when the angle change rate exceeds a threshold, identifying it as a fast break event; determining and marking a fast break event video based on the fast break event time window; and identifying exciting moments in the game based on the fast break event video.
[0121] The embodiment of the present application analyzes the angle changes based on the pan-tilt rotation log and combines it with the time window to quickly judge fast break events, quickly, accurately and completely identify fast break events in the game, and then through marking and editing, it realizes the editing of ball game videos in a more efficient and intelligent way, providing users with one-click generation of accurate short videos of exciting moments.
[0122] Compared with traditional video editing, the embodiment of the present application generates highlights with one click, significantly reducing manual intervention, improving editing efficiency, and achieving efficient and accurate editing. By linking pan-tilt data with AI models, the present application can more accurately identify fast breaks, effective offenses, and goal-scoring events. The present application supports user-defined adjustments, enhances video logic coherence and user experience, and achieves dynamic adaptability of video editing. The present application is suitable for a variety of ball sports such as basketball and football, has versatility and configurability, and achieves cross-scene compatibility.
[0123] Figure 6 2 is a schematic diagram showing the steps of a method for editing game highlights according to an embodiment of the present application.
[0124] like Figure 6 As shown, a method for editing game highlights in an embodiment of the present application includes the following steps:
[0125] S10: Apply the above-provided method for identifying exciting moments of the game to identify exciting moments of the game;
[0126] S20: Receive video editing parameters adjusted by the user, the video editing parameters including the total video length, the length of the highlight moment clip, and the video acceleration / deceleration multiple;
[0127] S30: Editing the exciting moments of the game according to the video editing parameters to generate a customized video of the exciting moments.
[0128] This application supports user-defined adjustments, enhances video logic coherence and user experience, and realizes dynamic adaptability of video editing.
[0129] To further illustrate the method for identifying and editing the highlights of a match according to an embodiment of the present application, a specific implementation process is provided below.
[0130] Figure 7 Detailed description of the process flow of a method for identifying and editing exciting moments of a game according to an embodiment of the present application is shown in FIG.
[0131] like Figure 7 As shown in the figure, the identification and editing of exciting moments in a match mainly includes four stages: data input, event detection, motion analysis, and video generation.
[0132] When inputting data, input the complete game video and related metadata (such as timeline, gimbal rotation log, etc.).
[0133] During event detection, pre-trained AI models are used to detect key events and mark the time points.
[0134] During motion analysis, the player's movements and ball trajectory are analyzed based on the multi-target tracking algorithm.
[0135] When generating videos, clipped videos are generated based on the detection results and rules and output in multiple formats.
[0136] (1) Regarding data input, namely video and log input.
[0137] This embodiment uses data captured by an automatic tracking PTZ, including video files, video timeline data, and PTZ log files.
[0138] (2) Then perform video preprocessing.
[0139] In order to reduce the amount of data that needs to be processed and improve processing efficiency, this application preferably extracts frames from the video to be processed.
[0140] The steps of frame extraction include:
[0141] 1. Read video files: Use a video processing library (such as OpenCV) to open the video file and obtain the video frame rate and total frame number information.
[0142] 2. Set the frame extraction interval: Determine the frame extraction interval according to your needs, for example, extract one frame every 5 frames.
[0143] 3. Read and save frame by frame: Read the video frame by frame at the set interval and save it as an image file, such as .jpg or .png format.
[0144] In addition, the video frames are denoised and the video quality is improved through image enhancement.
[0145] (3) Image recognition of player movements.
[0146] 1. Use a deep learning model (YOLOv8) to identify key objects such as people, balls, goals, baskets, nets, and other targets.
[0147] 2. Extract the character's joint information and perform posture analysis, such as using the OpenPose algorithm, MaskR-CNN algorithm, AlphaPose algorithm, HRNet algorithm, DensePose algorithm, etc., and simultaneously support subsequent action detection.
[0148] (4) Player movement analysis.
[0149] During the quick attack detection and analysis, the gimbal rotation data is first parsed. The gimbal rotation angle and timestamp at each moment are parsed from the log file, and the angle information of the starting point (left side) and the end point (right side) is recorded.
[0150] The gimbal's rotation rate is then analyzed using angular velocity to ensure that only fast, continuous rotations are recorded, filtering out slow or intermittent rotations.
[0151] Finally, set the fast break judgment condition: if the gimbal angle changes by more than a preset threshold (such as 60°) within a preset time window (such as 3 seconds for basketball and 10 seconds for soccer), this preset time window and the preset duration before and after (such as 3 seconds) will be marked as a fast break event in the timeline.
[0152] During effective offensive detection and analysis, a human motion recognition model (such as OpenPose) is used to determine the player's motion sequence within a preset time window and a preset duration after the detected fast break event.
[0153] If a standard shooting or shooting action is detected (such as raising both hands and releasing the ball in basketball, or volleying the ball in football, etc.), it is determined to be a complete shooting or shooting and is determined to be a valid attack.
[0154] The embodiment of the present application uses multi-frame continuous analysis to ensure the integrity of the action and avoid misjudgment due to shaking or rotation.
[0155] This application uses gimbal data and AI models to more accurately identify fast breaks, effective attacks, and goal-scoring events.
[0156] Based on the effective attack detection, further goal success detection is carried out.
[0157] For example, goal detection is performed within a preset time window of a detected fast break event and a preset time duration thereafter.
[0158] First, position recognition and coordinate extraction are performed. A trained deep learning model is used to detect the ball and goal (basket), accurately identify the position in each frame, and output the (x, y) coordinates of the corresponding target.
[0159] Then, the goal judgment logic.
[0160] Through real-time analysis, the position of the ball and the goal is tracked at a rate of multiple frames per second, and the coordinates of the center of the ball and the area covered by the goal are recorded.
[0161] Then, determine whether the center point of the ball enters the goal area: if the flight trajectory of the ball passes from one side of the goal area to the other side, a goal is scored.
[0162] Preferably, the goal / basket area in the video is three-dimensionally reconstructed using SLAM technology, and the boundary of the goal / basket and the surrounding area are used as the goal area.
[0163] In the preferred implementation, multiple frames of continuous detection results are combined to avoid misjudgments (such as the ball only flying in front of the goal but not entering). At the same time, a trajectory prediction model (such as a Kalman filter) is added to handle short-term occlusions to ensure the consistency of trajectory calculation.
[0164] Next, determine whether it is a wonderful moment.
[0165] When at least one of a valid attack or a goal is detected in a fast break event, the fast break event is confirmed to be a valid fast break, the time period is determined as a highlight moment, and the beginning and end moments of the time period are stored in the log.
[0166] Finally, automatic editing is performed to edit the wonderful moments and time periods identified by the system into short videos.
[0167] Preferably, in response to the user's action of extending the length of the short video, the time period information in the log is read and modified accordingly, and the wonderful moment is re-edited based on the modified log information.
[0168] For example, a user is provided with an eight-second fast break video, located at 23'25"-23'32" on the timeline. After watching the short video, the user thinks the ending is too abrupt and chooses to extend the clip by 2 seconds. At this time, the system modifies the timeline information in the log to 23'25"-23'34" and provides the user with a new fast break video.
[0169] Among them, the target recognition algorithm adopts the yolov8 algorithm. After identifying the ball target and the goal area, it judges the overlap between the ball target and the goal area and detects the overlap, determines it as a goal event, and determines the time point of the goal success.
[0170] There are two ways to determine the time of goal success:
[0171] 1) When the center of the ball's trajectory is detected to coincide with the center of the goal area, and a player is detected moving outward across the baseline within a certain period of time, the moment of coincidence is determined to be the time of a successful goal.
[0172] 2) Or it is detected that the center of the ball target motion trajectory stays in the goal area for more than a threshold value, and the starting point of the area overlap is determined as the time point of successful goal.
[0173] When editing, obtain the successful goal video within the preset time length floating around the successful goal time point, and mark the successful goal video on the video timeline.
[0174] Next, we will use the recognition and editing of basketball game videos as an example to illustrate the logic of judging the time point of a goal event.
[0175] By accurately judging whether a shot in a basketball game is a successful goal, the time point of each successful goal in the game can be determined. Furthermore, an automatic editing function can be provided to users to edit each scoring scene into a short video for users to publish.
[0176] Figure 8 Detailed description of the process of determining the time point of each successful goal in a game according to an embodiment of the present application is shown in FIG.
[0177] like Figure 8As shown, after the video is imported, frames are extracted to obtain each video frame to be processed; the ball and the basket are identified by the target recognition method, and it is determined whether the positions of the ball and the basket area overlap. If so, the time point of the frame is recorded as the shooting time point; the video frames within three seconds after the shooting time point are traversed, and the players and the baseline are identified by the target recognition algorithm; it is determined whether any player crosses the baseline in the video frames within 3 seconds after the shooting time point, and the shooting time point is determined as the goal time point.
[0178] Considering that, in common descriptions, the two long sides of a court rectangle are called sidelines, and the two short sides are called baselines, with the baseline being the line along which the basket or net is located. In basketball, every time a team scores a goal, the opposing team's player must step out of the baseline to throw the ball inbounds. Therefore, in this case, this action serves as the criterion for determining whether a goal has been scored.
[0179] 1) How to determine whether the positions of the ball and the basket overlap.
[0180] For each frame, the target detection model of this application will output the target frame position information of the detected basketball and basket. Each target frame is usually represented by four parameters, namely the center coordinates of the target frame (X center , Y center ), target box width W and target box height H.
[0181] Figure 9 Graph 1 shows a schematic diagram of target frame detection of a target detection model according to an embodiment of the present application.
[0182] Since the next thing to judge is the goal scene, when the basketball scores a goal, the basketball will pass through the basket, and the diameter of the basketball is slightly smaller than the diameter of the basket; therefore, Figure 9 As shown in Figure 2, when a goal is scored, the center point of the basketball target frame in the detection model passes near the center point of the basket target frame.
[0183] When considering the error, it can be considered that when a goal event occurs, the center coordinates of the basketball target frame (X center_ball , Y center_ball ) and the center coordinate of the basket's target frame (X center_basket , Y center_basket ) will definitely overlap or approximately overlap.
[0184] Specifically, the embodiment of the present application sets the error to 1 / 8 of the basketball diameter R, which can be approximately 1 / 8 of the width of the basketball target frame. That is:
[0185] When |X center_ball -X center_basket |≤R / 8; and |Y center_ball -Y center_basket When |≤R / 8, it is determined that the basketball and the basket overlap.
[0186] 2) How to determine whether this overlap is a successful goal-scoring event.
[0187] Since the shooting angle of the game is usually sideways, when the basketball and the basket overlap in the shooting picture, it may not be a goal event, but the basketball just passes through the position of the basket (such as a three-way miss). Therefore, an additional judgment is required.
[0188] We note that in basketball, according to the rules, when one team scores a shot, a player from the other team must leave the baseline to throw the ball out of bounds. However, when a shot fails to score, the scramble for rebounds is intense, leading to a second attack or a reverse fast break, which doesn't involve players leaving the baseline. Therefore, we determine whether a player leaves the baseline within a period of 2-3 seconds after the overlap event. If so, we confirm that the overlap was a goal.
[0189] The specific steps to determine whether a player has left the baseline include:
[0190] First, the Yolo algorithm is used to identify the target frame and bottom line of the person in the current picture.
[0191] Secondly, determine whether any character's foot points have crossed the bottom line. Specifically, determine whether the bottom edge midpoint of each character's target box has moved from one side of the bottom line to the other side.
[0192] In specific implementation, the coordinates of the character's foot point are (X center_target , Y center_target +H / 2); let the bottom line coordinate be ax+by+c=0;
[0193] Then, substitute the coordinates of the character's feet into the function f(x,y)=ax+by+c to get the value of f(x,y);
[0194] Monitor the f(x,y) value of each player's foot. When the value changes from positive to negative, or vice versa, it means that the foot has crossed the baseline. At this point, it is determined that a player has left the baseline.
[0195] 3) Finally, when it is determined that a player leaves the baseline event occurs after the overlap event, the overlap event is determined to be a goal event, and the time point of the overlap event frame is marked as the goal event time point.
[0196] Finally, with the time point of the goal event as the center, a certain number of seconds before and after are selected (the preset value is 2 seconds, which can be changed by user input), and automatically edited into a short video to provide to the user.
[0197] The former is to further detect a goal success event based on detecting that the video is a goal event. This application also provides another method of directly detecting a goal success event on a fast break event video.
[0198] See also Figure 5 ,identifying the highlights of the game based on the fast break event video specifically includes the following steps:
[0199] S401: Determine the time point of each successful goal in the game to form a time point set of successful goal events;
[0200] S402: Identify exciting moments of the game based on the goal success event time point set.
[0201] Take the example of a basketball game with a net under the basket.
[0202] Figure 10 Detailed description is given of a schematic diagram of detecting a successful basketball goal according to an embodiment of the present application.
[0203] like Figure 10 As shown, the net and the basket are regarded as a whole target frame, which can be directly identified as the net target frame. Since in a goal event, the basketball will be resisted by the net after passing through the basket, and the trajectory will be changed to a nearly vertical falling trajectory, it can be considered that a goal event occurs when the ball passes through the upper and lower boundaries of this large target frame at the same time.
[0204] When a basketball scores a goal, it will pass through the basket, and the diameter of the basketball is slightly smaller than the diameter of the basket. Therefore, when a goal is scored, the center point of the basketball target box in Yolo will definitely pass through the upper midpoint and the lower midpoint of the net target box at the same time.
[0205] That is, the center coordinate of the basketball goal frame (X center_ball , Y center_ball ) and the upper midpoint of the net target box (X center_net , Y center_net -height_net / 2) and the lower midpoint (X center_net , Y center_net +height_net / 2) coincides or nearly coincides.
[0206] In specific implementation, the error can be set to 1 / 8 of the diameter of the basketball, which can be approximately 1 / 8 of the width of the basketball target frame.
[0207] In terms of steps, 1. First, find the time points when the center points of all basketball target boxes coincide with the midpoints of the upper edges of the net target boxes, and use these time points as set A.
[0208] The time point is represented by a timestamp, and each frame has a unique timestamp.
[0209] 2. Secondly, find the time point when the center point of all basketball target boxes coincides with the midpoint of the bottom edge of the net target box, as set B.
[0210] 3. Determine in turn whether each element in set B is within 1 second of an element in set A at any time point; if so, put the element into set C.
[0211] Repeat the above steps until all elements in set B have been judged. At this point, set C can be regarded as the time point set of goal events.
[0212] Or vice versa:
[0213] Determine in turn whether each element in set A is within 1 second before any element in set B at any time point;
[0214] If so, put the element into set C.
[0215] Repeat the above steps until all elements in set A have been judged. At this point, set C can be regarded as the time point set of goal events.
[0216] Through the method for identifying game highlights based on tracking pan-tilt data in the embodiment of the present application, by analyzing the angle changes based on the pan-tilt rotation log and combining it with the time window to quickly judge fast break events, game fast break events can be quickly, accurately and completely identified, and then through marking and editing, ball game videos can be edited in a more efficient and intelligent way, providing users with one-click generation of accurate short videos of highlights.
[0217] In addition, this application generates wonderful clips with one click, significantly reducing manual intervention, improving editing efficiency, and achieving efficient and accurate editing.
[0218] This application uses gimbal data and AI models to more accurately identify fast breaks, effective attacks, and goal-scoring events.
[0219] This application supports user-defined adjustments, enhances video logic coherence and user experience, and realizes dynamic adaptability of video editing.
[0220] This application is suitable for various ball sports such as basketball and football. It is universal and configurable, and achieves cross-scenario compatibility.
[0221] Example 2
[0222] This embodiment provides a system for identifying exciting moments in a match based on tracking pan-tilt data. For details not disclosed in the system for identifying exciting moments in a match based on tracking pan-tilt data in this embodiment, please refer to the specific implementation content of the method for identifying exciting moments in a match based on tracking pan-tilt data in other embodiments.
[0223] Figure 11 2 shows a structural diagram of a system for identifying exciting moments in a match based on tracking pan-tilt data according to an embodiment of the present application.
[0224] like Figure 11 As shown in the figure, the game highlight moment recognition system based on tracking gimbal data includes:
[0225] PTZ data acquisition module 10: used to acquire the game video data shot by the tracking PTZ, video timeline data and the rotation log of the tracking PTZ;
[0226] The fast-break event recognition module 20 is used to analyze the rotation log and calculate the PTZ angle change rate within a preset time window based on the PTZ rotation angle and timestamp. When the angle change rate exceeds a threshold, it is identified as a fast-break event.
[0227] Video marking module 30: used to mark and determine the fast break event video according to the fast break event time window;
[0228] Video recognition module 40: used to identify exciting moments of the game based on the fast break event video.
[0229] The system for identifying highlight moments in a match based on tracking PTZ data in an embodiment of the present application includes the following in its overall system architecture:
[0230] Data input layer: inputs the complete game video and related metadata (such as timeline, PTZ rotation log, etc.);
[0231] Event detection layer: Uses pre-trained AI models to detect key events and mark time points;
[0232] Motion analysis layer: Based on multi-target tracking algorithm, it analyzes player movements and ball trajectories;
[0233] Video generation layer: Generates clipped videos based on detection results and rules, and outputs them in multiple formats.
[0234] The embodiment of the present application provides a system for identifying game highlights based on tracking pan-tilt data. By analyzing the angle changes based on the pan-tilt rotation log and combining it with a time window, the system quickly determines fast break events, identifies game fast break events quickly, accurately, and completely, and then achieves more efficient and intelligent editing of ball game videos through marking and editing, providing users with one-click generation of accurate short videos of highlights.
[0235] On this basis, this embodiment also provides a system for editing game highlights based on tracking PTZ data.
[0236] Figure 122 shows a structural diagram of a system for editing highlights of a match based on tracking pan-tilt data according to an embodiment of the present application.
[0237] like Figure 12 As shown, the game highlights editing system includes:
[0238] A wonderful moment recognition module 100 is used to apply a method for identifying wonderful moments in a match to identify wonderful moments in the match;
[0239] The parameter adjustment module 200 is used to receive video editing parameters adjusted by the user, the video editing parameters including the total video length, the clipping length of the highlights, and the video acceleration / deceleration multiples;
[0240] The video editing module 300 is used to edit the exciting moments of the game according to the video editing parameters to generate customized videos of the exciting moments.
[0241] This allows for enhanced video logic coherence and user experience by supporting user-defined adjustments, and enables dynamic adaptability of video editing.
[0242] In addition, this application generates wonderful clips with one click, significantly reducing manual intervention, improving editing efficiency, and achieving efficient and accurate editing.
[0243] This application uses gimbal data and AI models to more accurately identify fast breaks, effective attacks, and goal-scoring events.
[0244] This application supports user-defined adjustments, enhances video logic coherence and user experience, and realizes dynamic adaptability of video editing.
[0245] This application is suitable for various ball sports such as basketball and football. It is universal and configurable, and achieves cross-scenario compatibility.
[0246] Example 3
[0247] This embodiment provides a device for identifying exciting moments in a match based on tracking pan-tilt data. For details not disclosed in the device for identifying exciting moments in a match based on tracking pan-tilt data in this embodiment, please refer to the specific implementation content of the method or system for identifying exciting moments in a match based on tracking pan-tilt data in other embodiments.
[0248] Figure 13 2 is a schematic structural diagram of a device 400 for identifying exciting moments in a match based on tracking pan-tilt data according to an embodiment of the present application.
[0249] like Figure 13As shown, the device 400 for identifying exciting moments in a match based on tracking pan-tilt data includes: a storage unit 402 for storing executable instructions; and a processing unit 401 for connecting to the storage unit 402 to execute executable instructions to complete a method for identifying exciting moments in a match based on tracking pan-tilt data.
[0250] Those skilled in the art will understand that Figure 13 The above is merely an example of a device 400 for identifying exciting game moments based on tracking pan-tilt data, and does not constitute a limitation on the device 400 for identifying exciting game moments based on tracking pan-tilt data. The device may include more or fewer components than shown in the figure, or a combination of certain components, or different components. For example, the device 400 for identifying exciting game moments based on tracking pan-tilt data may also include input and output devices, network access devices, buses, etc.
[0251] The so-called processing unit 401 (Central Processing Unit, CPU) can also be other general-purpose processors, digital signal processors (Digital Signal Processor, DSP), application-specific integrated circuits (Application-Specific Integrated Circuit, ASIC), field-programmable gate arrays (Field-Programmable Gate Array, FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. A general-purpose processor can be a microprocessor, or the processing unit 401 can also be any conventional processor, etc. The processing unit 401 is the control center of the device 400 for identifying exciting moments in a match based on tracking pan-tilt data, and uses various interfaces and lines to connect various parts of the device 400 for identifying exciting moments in a match based on tracking pan-tilt data.
[0252] The storage unit 402 can be used to store computer-readable instructions. The processing unit 401 implements the various functions of the device 400 for identifying highlight moments in a match based on PTZ data tracking by running or executing the computer-readable instructions or modules stored in the storage unit 402 and accessing the data stored in the storage unit 402. The storage unit 402 may primarily include a program storage area and a data storage area. The program storage area may store an operating system and at least one application required for a function (such as a sound playback function or an image playback function); the data storage area may store data created by the device 400 for identifying highlight moments in a match based on PTZ data tracking. Furthermore, the storage unit 402 may include a hard disk, memory, a plug-in hard disk, a smart media card (SMC), a secure digital (SD) card, a flash card, at least one disk storage device, a flash memory device, a read-only memory (ROM), a random access memory (RAM), or other non-volatile or volatile storage devices.
[0253] If the modules integrated into the device 400 for identifying highlight moments in a match based on pan / tilt data tracking are implemented as software functional modules and sold or used as independent products, they can be stored on a computer-readable storage medium. Based on this understanding, the present invention can also implement all or part of the processes in the above-described method embodiments by instructing the relevant hardware through computer-readable instructions. The computer-readable instructions can be stored on a computer-readable storage medium, and when executed by a processor, these computer-readable instructions can implement the steps of each of the above-described method embodiments.
[0254] Referring to the device 400 for identifying exciting moments of a match based on tracking pan-tilt data, an embodiment of the present application also provides a device for editing exciting moments of a match based on tracking pan-tilt data.
[0255] Example 4
[0256] This embodiment provides a computer-readable storage medium having a computer program stored thereon; the computer program is executed by a processor to implement the method for identifying exciting moments of a game based on tracking pan-tilt data in other embodiments.
[0257] The device and medium for identifying and editing game highlights based on tracking pan-tilt data of this application are used to quickly judge fast break events through angle change analysis based on the pan-tilt rotation log and time window combination, and quickly, accurately and completely identify game fast break events. Then, through marking and editing, ball game videos are edited in a more efficient and intelligent way, providing users with one-click generation of accurate short videos of highlights.
[0258] In addition, this application generates wonderful clips with one click, significantly reducing manual intervention, improving editing efficiency, and achieving efficient and accurate editing.
[0259] This application uses gimbal data and AI models to more accurately identify fast breaks, effective attacks, and goal-scoring events.
[0260] This application supports user-defined adjustments, enhances video logic coherence and user experience, and realizes dynamic adaptability of video editing.
[0261] This application is suitable for various ball sports such as basketball and football. It is universal and configurable, and achieves cross-scenario compatibility.
[0262] Those skilled in the art will appreciate that the terms used in the present invention are for the purpose of describing specific embodiments only and are not intended to limit the present invention. As used in the present invention and the appended claims, the singular forms "a," "the," and "the" are intended to include plural forms, unless the context clearly indicates otherwise. It should also be understood that the term "and / or" as used herein refers to and encompasses any or all possible combinations of one or more of the associated listed items.
[0263] It should be understood that although the terms "first," "second," "third," etc. may be used in the present invention to describe various information, such information should not be limited to these terms. These terms are merely used to distinguish information of the same type from one another. For example, first information may also be referred to as second information, and similarly, second information may also be referred to as first information, without departing from the scope of the present invention. Depending on the context, the term "if" as used herein may be interpreted as "when," "when," or "in response to determining."
[0264] Although the preferred embodiments of the present application have been described, those skilled in the art may make additional changes and modifications to these embodiments once they have learned the basic creative concept. Therefore, the appended claims are intended to be interpreted as including the preferred embodiments and all changes and modifications that fall within the scope of the present application.
[0265] Obviously, those skilled in the art may make various changes and modifications to this application without departing from the spirit and scope of this application. Thus, if these modifications and variations of this application fall within the scope of the claims of this application and their equivalents, this application is intended to include these modifications and variations.
Claims
1. A method for identifying exciting moments in a match based on tracking PTZ data, characterized in that: include: Obtaining game video data, video timeline data, and a rotation log of the tracking gimbal captured by the tracking gimbal; parsing the rotation log, and calculating the angular change rate of the pan / tilt within a preset time window based on the pan / tilt rotation angle and timestamp; identifying a quick attack event when the angular change rate exceeds a threshold; Determining and marking a fast break event video according to the fast break event time window; Identify exciting moments of the game based on the fast break event video.
2. The method for identifying exciting moments in a match according to claim 1, wherein: The identifying of the exciting moments of the game based on the fast break event video includes: Extracting multiple frames of continuous fast-break images from the fast-break event video; Inputting the fast break image into a human action recognition model or a goal recognition model to identify player actions; When a player's action is identified as a valid action or a goal event is identified, the fast break event video is determined to be a highlight of the game, and the fast break event video is marked on the video timeline.
3. The method for identifying exciting moments in a match according to claim 2, wherein: When the player action is identified as a valid action or a goal event is identified, the method includes: The human action recognition model recognizes a player's action sequence based on the fast break image; The action sequence is analyzed to obtain a result that the result is a shooting action or a shooting action, and the action sequence is determined to be a valid action.
4. The method for identifying exciting moments in a match according to claim 2, wherein: When the player action is identified as a valid action or a goal event is identified, the method includes: Identify the fast break image using a target recognition algorithm to identify the ball target and the goal area; The overlap between the ball target and the goal area is judged and detected, and it is determined as a goal event.
5. The method for identifying exciting moments in a match according to claim 4, characterized in that: The step of judging and detecting the overlap between the ball target and the goal area includes: Determine the trajectory of the ball target; When the distance between the ball target motion trajectory and the goal area is within a certain threshold, it is determined that the ball target overlaps with the goal area.
6. The method for identifying exciting moments in a match according to claim 5, characterized in that: After determining that the ball target overlaps with the goal area, the method further includes: Detecting that the center of the ball target's motion trajectory coincides with the center of the goal area, and detecting that the player moves outward and crosses the baseline of the court within a certain period of time thereafter, and determining the coincidence moment as the time point of successful goal scoring; Alternatively, it is detected that the center of the ball target motion trajectory stays in the goal area for more than a threshold value, and the starting point of the area overlap is determined as the time point of successful goal.
7. The method for identifying exciting moments in a match according to claim 1, wherein: The identifying of the exciting moments of the game based on the fast break event video includes: Determine the time point of each successful goal in the game to form a time point set of successful goal events; Identify exciting moments of the game based on the goal success event time point set.
8. A method for editing exciting moments of a game, characterized in that: include: Applying the method for identifying exciting moments of a game as described in any one of claims 1 to 7 to identify exciting moments of a game; Receive video editing parameters adjusted by the user, wherein the video editing parameters include the total length of the video, the length of the highlight moment clipping, and the video acceleration / deceleration multiples; The exciting moments of the game are edited according to the video editing parameters to generate a customized video of the exciting moments.
9. A system for identifying exciting moments in a match based on tracking PTZ data, characterized in that: include: PTZ data acquisition module: used to acquire the game video data shot by the tracking PTZ, video timeline data and the rotation log of the tracking PTZ; A quick-break event recognition module is configured to analyze the rotation log and calculate the PTZ angle change rate within a preset time window based on the PTZ rotation angle and timestamp; identify a quick-break event when the angle change rate exceeds a threshold; Video marking module: used for marking and determining the fast break event video according to the fast break event time window; Video recognition module: used to identify exciting moments of the game based on the fast break event video.
10. A device for identifying exciting moments in a match based on tracking PTZ data, characterized in that: include: a storage unit for storing executable instructions; as well as A processing unit, configured to be connected to the memory to execute executable instructions to complete the method according to any one of claims 1 to 8.