CN110765896A - Video processing method and device - Google Patents

Video processing method and device Download PDF

Info

Publication number
CN110765896A
CN110765896A CN201910949696.5A CN201910949696A CN110765896A CN 110765896 A CN110765896 A CN 110765896A CN 201910949696 A CN201910949696 A CN 201910949696A CN 110765896 A CN110765896 A CN 110765896A
Authority
CN
China
Prior art keywords
target
action
score
video
ball
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN201910949696.5A
Other languages
Chinese (zh)
Inventor
张智炜
李泽
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Vivo Mobile Communication Co Ltd
Original Assignee
Vivo Mobile Communication Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Vivo Mobile Communication Co Ltd filed Critical Vivo Mobile Communication Co Ltd
Priority to CN201910949696.5A priority Critical patent/CN110765896A/en
Publication of CN110765896A publication Critical patent/CN110765896A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V40/00Recognition of biometric, human-related or animal-related patterns in image or video data
    • G06V40/20Movements or behaviour, e.g. gesture recognition
    • G06V40/23Recognition of whole body movements, e.g. for sport training
    • AHUMAN NECESSITIES
    • A63SPORTS; GAMES; AMUSEMENTS
    • A63BAPPARATUS FOR PHYSICAL TRAINING, GYMNASTICS, SWIMMING, CLIMBING, OR FENCING; BALL GAMES; TRAINING EQUIPMENT
    • A63B71/00Games or sports accessories not covered in groups A63B1/00 - A63B69/00
    • A63B71/06Indicating or scoring devices for games or players, or for other sports activities
    • A63B71/0605Decision makers and devices using detection means facilitating arbitration

Abstract

The embodiment of the invention discloses a video processing method and a video processing device. The video processing method can be applied to electronic equipment, and comprises the following steps: acquiring a target match video; recognizing a ball serving action in a target game video by using a preset action recognition model; and in the case that the goal match video is identified to have the ball serving action, updating the goal score. The embodiment of the invention can solve the problem of lower accuracy of the scoring result of manual scoring in the prior art.

Description

Video processing method and device
Technical Field
The embodiment of the invention relates to the technical field of video processing, in particular to a video processing method and device.
Background
In a conventional ball game, the scores of two participants are determined and scored by a specialized referee. However, when exercising in a game between ball fans, it is often not judged to be scored, but only by the participants of the game or the spectators on the scene.
However, this manual scoring method may cause misclassification and missed scoring, which reduces the accuracy of the scoring result and causes errors in the determined game result.
Disclosure of Invention
The embodiment of the invention provides a video processing method and a video processing device, which aim to solve the problem of low accuracy of a scoring result of manual scoring in the prior art.
In order to solve the technical problem, the invention is realized as follows:
in a first aspect, an embodiment of the present invention provides a video processing method, which is applied to an electronic device, and the method includes:
acquiring a target match video;
recognizing a ball serving action in a target game video by using a preset action recognition model;
and in the case that the goal match video is identified to have the ball serving action, updating the goal score.
In a second aspect, an embodiment of the present invention provides a video processing apparatus, including:
the video acquisition module is used for acquiring a target match video;
the video detection module is used for identifying the ball serving action in the target game video by using a preset action identification model;
and the score updating module is used for updating the target score under the condition that the goal serving action exists in the target game video.
In a third aspect, an embodiment of the present invention provides an electronic device, which includes a processor, a memory, and a computer program stored in the memory and being executable on the processor, and when executed by the processor, the electronic device implements the steps of the video processing method according to the first aspect.
In a fourth aspect, the present invention provides a computer-readable storage medium, on which a computer program is stored, where the computer program, when executed by a processor, implements the steps of the video processing method according to the first aspect.
In the embodiment of the invention, the electronic equipment can acquire the target game video and identify the ball serving action in the target game video by using the preset action identification model, so that the target score is updated under the condition that the ball serving action exists in the target game video, namely, the electronic equipment can quickly and effectively update the target scores corresponding to the two participants by identifying the ball serving action in the target game video, thereby realizing accurate scoring of the two participants, improving the accuracy of the scoring result and improving the accuracy of the determined game result.
Drawings
The present invention will be better understood from the following description of specific embodiments thereof taken in conjunction with the accompanying drawings, in which like or similar reference characters designate like or similar features.
Fig. 1 is a schematic flow chart of a video processing method according to an embodiment of the present invention;
fig. 2 is a schematic flow chart of a video processing method according to another embodiment of the present invention;
FIG. 3 is a flow chart of a badminton scoring method according to an embodiment of the present invention;
fig. 4 is a schematic structural diagram of a video processing apparatus according to an embodiment of the present invention;
fig. 5 is a schematic diagram of a hardware structure of an electronic device implementing various embodiments of the present invention.
Detailed Description
The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are some, not all, embodiments of the present invention. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
In order to solve the problems in the prior art, embodiments of the present invention provide a video processing method and apparatus, an electronic device, and a computer-readable storage medium. First, a video processing method provided by an embodiment of the present invention is described below.
Fig. 1 is a flowchart illustrating a video processing method according to an embodiment of the present invention. As shown in fig. 1, the video processing method may include:
s110, obtaining a target match video;
s120, identifying a ball serving action in the target game video by using a preset action identification model;
and S130, updating the target score when the goal match video is identified to have the goal act.
The video processing method of the embodiment of the invention can be applied to electronic equipment. The electronic device may be a mobile phone, a tablet computer, a personal computer, or the like.
In the embodiment of the invention, the electronic equipment can acquire the target game video and identify the ball serving action in the target game video by using the preset action identification model, so that the target score is updated under the condition that the ball serving action exists in the target game video, namely, the electronic equipment can quickly and effectively update the target scores corresponding to the two participants by identifying the ball serving action in the target game video, thereby realizing accurate scoring of the two participants, improving the accuracy of the scoring result and improving the accuracy of the determined game result.
The video processing method provided by the embodiment of the invention can be used for scoring two participants in a ball game, and particularly can be applied to ball games with the scoring parties in each game adding scores or subtracting scores. Such as table tennis, badminton, tennis, volleyball, etc.
In the embodiment of the present invention, when a user needs to use the video processing method of the embodiment of the present invention to score two participants of a ball game, a scoring request may be input to the electronic device, so that the electronic device executes the video processing method of the embodiment of the present invention in response to the scoring request.
In step S110 of the embodiment of the present invention, the electronic device may obtain a target game video corresponding to the target ball game field in response to receiving the scoring request.
Specifically, the electronic device may acquire and obtain the target game video through its own image acquisition device, or may obtain the target game video through an image acquisition device in communication connection with the electronic device.
In step S120 of the embodiment of the present invention, a specific method for identifying a ball serving action in a target game video by using a preset action identification model may include:
inputting each frame of image data of the target game video and audio data corresponding to each frame of image data into a preset action recognition model to obtain a corresponding serve action confidence sequence of the target game video;
and if the confidence sequence of the serve action meets the Gaussian distribution and the confidence peak value of the serve action in the confidence sequence of the serve action is larger than a first preset peak value threshold value, determining that the serve action exists in the target game video.
In the embodiment of the invention, the electronic equipment can acquire the audio data through the audio acquisition device of the electronic equipment, and can also acquire the audio data through the audio acquisition device in communication connection with the electronic equipment.
Specifically, after receiving the scoring request, the image acquisition device and the audio acquisition device may be synchronously controlled to acquire audio data corresponding to each frame of image data in the target game video and the target game video, then each frame of image data in the target game video and the audio data corresponding to each frame of image data are input into a preset action recognition model to obtain the ball-serving action confidence of each frame of image data and the audio data corresponding to each frame of image data, the ball-serving action confidence is arranged according to the time sequence, and the ball-serving action confidence peak value in the ball-serving action confidence is determined, then the ball-serving action confidence within the predetermined time length range is obtained according to the ball-serving action confidence peak value, the ball-serving action confidence corresponding to the target game video is configured into a ball-serving action confidence sequence by using the ball-serving action confidence, wherein the time corresponding to the ball-serving action confidence peak value is located at the midpoint of the predetermined time length range, and finally, judging whether the confidence sequence of the serve action meets Gaussian distribution or not, and whether the confidence peak value of the serve action in the confidence sequence of the serve action is larger than a first preset peak threshold or not, and if the confidence sequence of the serve action meets the Gaussian distribution and the confidence peak value of the serve action in the confidence sequence of the serve action is larger than the first preset peak threshold, determining that the serve action exists in the target game video.
In the embodiment of the present invention, since the video data is a dynamic image data with a time sequence, the preset motion recognition model can be obtained based on the training of the first long-short memory network with a time sequence.
Specifically, before the target game video is obtained, the video processing method according to the embodiment of the present invention may further include:
acquiring historical video data of a plurality of preset time lengths and a marking result of each historical video data in the plurality of historical video data; the historical video data comprises image data and audio data, and the marking result is that a serve action exists in the historical video data or the serve action does not exist in the historical video data;
and training the first long and short memory network by using the plurality of historical video data and the marking result of each historical video data to obtain a preset action recognition model.
Specifically, a plurality of historical video data with a predetermined time length and a labeling result of each of the plurality of historical video data may be acquired as training data, and the training data is used to train the first long-short memory network to obtain a preset motion recognition model.
Therefore, when the preset action recognition model is used, the current frame image data and the audio data corresponding to the current frame image data are input into the preset action recognition model, and meanwhile, the ball-serving action confidence corresponding to the previous frame image data of the current frame image data needs to be input into the preset action recognition model, so that the ball-serving action confidence of the current frame image data and the audio data corresponding to the current frame image data is obtained.
Therefore, in the embodiment of the present invention, since the ball serving action existing in the target game video corresponding to the target ball game field can be recognized only by using the preset action recognition model obtained based on the first long and short memory network training, the target score corresponding to the two participants is updated, and the data processing amount of the preset action recognition model obtained based on the first long and short memory network training is small, the data processing amount and the calculation amount of the image data and the audio data can be reduced, the data processing efficiency is improved, and the resource occupancy rate of the electronic device is reduced.
In addition, taking a ball game as an example of a badminton game, when a ball serving action exists in a target game video, because the badminton can impact a racket during the ball serving, a sound peak value is generated corresponding to the audio data, the image data can be used for assisting in judging the confidence coefficient of the ball serving action by using the audio data, the interference of detecting the confidence coefficient of the ball serving action is reduced, and the accuracy of a detection result of the confidence coefficient of the ball serving action is improved.
In step S130 of some embodiments of the present invention, in the case that it is recognized that there is a ball serving action in the target game video, the specific method for updating the target score may be determined according to the game rule, for example, a predetermined score is increased for a ball serving party, or a predetermined score is decreased for another party except the ball serving party, and may be specifically determined according to the point rule, which is not described herein again.
In step S130 according to other embodiments of the present invention, in the case that it is recognized that there is a ball serving action in the target game video, the specific method for updating the target score may further include:
under the condition that the goal match video is identified to have a serve action, if the goal score is detected to be the initial score for the first time, the goal score is not updated; and if the target score is not detected for the first time or if the target score is not detected to be the initial score, updating the target score.
Specifically, the target score may be detected before determining whether to update the target score, if the target score is detected as the initial score for the first time, it indicates that the match is just started, the current serve is taken as the first serve, and if there is no win or loss, the target score is not updated; if the target score is not detected for the first time or if the target score is not detected for the first time, it is indicated that the service action is not the first service, and a win-or-lose condition exists in the last game, the service party needs to be determined according to the service action, and the target score is updated based on the integral rule.
In some embodiments of the present invention, the image capturing device of the electronic device or the image capturing device communicatively connected to the electronic device may have an ultra-wide-angle lens, and the image capturing area of the image capturing device may cover the entire game field, that is, the target game field corresponding to the target game video may include a first participant field and a second participant field of the two participant fields, and at this time, scoring of the two participants may be performed only by using the electronic device.
Specifically, in step S130 of these embodiments, a specific method for updating the target score by the electronic device may include:
determining a participant field with a serve action in a first participant field and a second participant field;
and increasing or decreasing a preset score for the participant corresponding to the determined participant site to update the target score.
For example, if the first participant field is determined to be a participant field where a serve action exists and the scoring rule is a scorer serve, the participant to which the first participant field corresponds may be determined to be a scorer and a predetermined score may be added to the scorer.
Wherein the predetermined score may be determined according to an integration rule. For example, if the ball game is a badminton game, the score of each scoring party is added by 1, and at this time, the predetermined score may be set to 1.
In other embodiments of the present invention, the image capturing device of the electronic device or the image capturing device communicatively connected to the electronic device may be a common lens, and the image capturing area of the image capturing device may only cover a partial area in the competition field, that is, the target ball competition field corresponding to the target competition video may include a first participant field in two participant fields, and at this time, the electronic device and the target device communicatively connected to the electronic device through bluetooth or a local area network or the like are required to jointly score the two participants. At this time, the image acquisition device of the target device or the image acquisition device in communication connection with the target device may also be a common lens, and the image acquisition area of the image acquisition device, i.e., the target ball game field, may include a second participant field of the two participant fields.
Specifically, in step S130 of these embodiments, a specific method for updating the target score by the electronic device may include:
and increasing or decreasing a preset score for the participant corresponding to the first participant field so as to update the target score.
Further, the video processing method may further include:
receiving a score updating request sent by target equipment corresponding to a second competitor field in the two competitor fields;
in response to the score update request, the target score is updated.
The target device may perform the same video processing method as the electronic device, that is, determine whether a ball serving action exists in the second participant field according to the target game video acquired by the target device, increase or decrease a predetermined score for a participant corresponding to the second participant field to update the target score if it is detected that a predetermined action exists, and generate a score update request. Then, the target device may send a score update request to the electronic device, and the electronic device may obtain, in response to receiving the score update request, an updated target score sent by the target device, so as to update the target score in the electronic device by using the obtained target score, thereby completing data interaction between the electronic device and the target device, and implementing update of the target scores of the two parties.
In the embodiment of the invention, after the competition is finished, if the participant who reaches the competition point score wins the competition, the competition is finished, the next competition cannot exist, and the target scores of the two participants cannot be updated through the serve action of the next competition. Therefore, a corresponding scoring party judgment mechanism needs to be designed for the competition game.
Fig. 2 is a flow chart illustrating a video processing method according to another embodiment of the present invention. As shown in fig. 2, the video processing method includes:
s210, obtaining a target match video;
s220, under the condition that the scores of the two participants do not reach the preset score, the service action is recognized in the target game video by using a preset action recognition model, and the target score is updated under the condition that the service action exists in the target game video;
and S230, under the condition that the score of at least one participant reaches a preset score, identifying the batting action in the target game video and the ball track position at each moment in the target game video, and updating the target score according to the batting action and the ball track position at each moment.
Therefore, in the embodiment of the present invention, before the step S220 and the step S230, the target score needs to be detected, the step S220 may be executed if neither of the scores of the two participants reaches the preset score, and the step S230 may be executed if at least one score of the participants reaches the preset score.
The preset score may be a score of a playing point defined by an integration rule of the ball game. For example, if the game is 13 points, the score of any participant reaches 12 points, i.e. the game is entered, and at this time, the preset score may be set to 12. After the first game is finished, the target score can be updated by identifying the ball serving action in the target game video after the second game is started until any one of the participants reaches 12 scores.
The method for realizing the scoring of the scoring party based on the serve action can be applied to the ball game of scoring and serving, and at the moment, the target scores corresponding to the two participants can be simply and quickly updated only through the serve action.
Steps S210 to S220 of the embodiment shown in fig. 2 are similar to steps S110 to S130 of the embodiment shown in fig. 1, and are not repeated herein.
In step S230 of some embodiments of the present invention, a specific method for identifying a hitting action in a target game video may include:
inputting each frame of image data of the target game video and the audio data corresponding to each frame of image data into a batting action recognition model to obtain a batting action confidence sequence corresponding to the target game video;
and if the hitting action confidence coefficient sequence meets the Gaussian distribution and the hitting action confidence coefficient peak value in the hitting action confidence coefficient sequence is larger than a second preset peak value threshold value, determining that the hitting action exists in the target game video.
And the batting action recognition model is obtained based on the training of the second length memory network.
Specifically, the method for identifying the ball hitting action is similar to the method for identifying the service action, and the method for obtaining the ball hitting action identification model based on the second long and short memory network training is similar to the method for training the preset action identification model, which is not described herein again.
In step S230 of some embodiments of the present invention, a specific method for identifying a ball trajectory position at each moment in the target game video may include:
inputting each frame of image data of the target game video into a ball track position identification model to obtain a ball track position in the target ball game field at a moment corresponding to each frame of image data; the ball track position recognition model is obtained based on convolutional neural network training.
Specifically, the ball trajectory position recognition model obtained based on convolutional neural network training can use a ball as a recognition target, so that the ball trajectory position in the target ball game field at the moment corresponding to each frame of image data is recognized.
In step S230 of some embodiments of the present invention, if the target ball game field corresponding to the target game video includes a first participant field and a second participant field of the two participant fields, a specific method for updating the target score according to the ball hitting action and the ball trajectory position at each moment may include:
determining a scoring party from the recognized hitting action and the ball trajectory position at each moment in time, among the two participants;
and increasing a predetermined score for the scoring party to update the target score.
At this time, scoring both participants can be achieved using only electronic devices.
In step S230 of another embodiment of the present invention, if the target ball game field corresponding to the target game video includes a first participant field of two participant fields, a specific method for updating the target score according to the ball hitting action and the ball trajectory position at each moment may include:
receiving an information updating request sent by target equipment corresponding to a second competitor field in the two competitor fields; wherein the information update request comprises a batting action in the second participant field and a ball track position at each moment in the second participant field;
responding to the information updating request, and updating the batting action and the ball track position at each moment;
and updating the target score according to the updated batting action and the ball track position at each moment.
At this time, the electronic device and the target device connected to the electronic device through communication such as bluetooth or a local area network need to be used to jointly score the two participants.
Specifically, the electronic device and the target device may perform data interaction in real time, update respective data with data of another device, and add a predetermined score to the scoring party according to the respective updated data to update the target score.
In some embodiments of the present invention, when it is determined that the ball trajectory position is the ball landing position, the landing frame image data corresponding to the landing time of the ball may be obtained, and then the landing frame image data may be input into the landing position recognition model to determine the landing position of the ball.
Specifically, the landing position recognition model can be obtained by training based on a classifier. The landing position recognition model can recognize the landing position of the ball as being in or out of the boundary.
Upon determining that the ball landing location is in-bound or out-of-bound, a scoring party may be determined among the two participants based on the positional relationship of the ball landing location to the first and second participant fields and the relationship of the last ball striking action to the first and second participant fields.
Specifically, if it is recognized that the ball landing position is within the boundary, the participant corresponding to the participant field in which the ball does not fall is the scoring party. If the landing position of the ball is recognized to be out of bounds, determining a participant field close to the ball and a participant field with the last ball hitting action, and determining a scoring party according to the participant field close to the ball and the participant field with the last ball hitting action. For example, if the participant field where the ball approaches is the same as the participant field where the last ball hitting action exists, determining the ball game participant corresponding to the participant field where the last ball hitting action does not exist as the scoring party; and if the participator field close to the ball is different from the participator field with the last batting action, determining the participator of the ball game corresponding to the participator field close to the ball as the scoring party.
In other embodiments of the present invention, it may also occur that the ball trajectory position is not identified in the image data of the video data. In this case, if the time during which the ball trajectory position is not recognized in the first and second participant fields exceeds a predetermined time in accordance with the ball hitting action and the ball trajectory position at each time, it can be determined that the ball is hit off and has flown out of the ball race field, and therefore, it can be determined that the participant corresponding to the participant field in which the last ball hitting action does not exist is the scoring party.
Fig. 3 is a flow chart illustrating a badminton scoring method according to an embodiment of the present invention. As shown in fig. 3, the badminton scoring method can be applied to an electronic device with an image acquisition device having an ultra-wide-angle lens, and specifically includes the following steps:
step S301, receiving a scoring request;
step S302, starting an image acquisition device and an audio acquisition device to monitor images and sounds of a target ball game field and acquire a target game video;
step S303, detecting whether the scores of the two participants are both smaller than a preset score, if so, executing step S304, and if not, executing step S309;
step S304, detecting a ball serving action;
step S305, whether a serve operation is detected or not, if yes, step S306 is executed, and if not, step S304 is executed;
step S306, judging whether the target score is detected for the first time, if so, not updating the target score, and executing step S304, otherwise, executing step S307;
step S307, judging a service party corresponding to the service action according to the competition party site where the service action is located;
step S308, adding 1 to the score of the ball-serving party, and executing step S303;
step S309, detecting a batting action and a ball track position;
step S310, judging whether the ball track position is that the ball falls to the ground or not, if so, executing step S311, otherwise, executing step S309;
step S311, determining a scoring party according to the landing position of the ball and the field of the participating party where the last ball hitting action is located;
step S312, adding 1 to the score of the scoring party;
step S313, detecting whether there is a participant with a score reaching the set winner score (13 if 13 scores), if yes, executing step S314, otherwise executing step S309;
and step S314, determining a winner according to the scores of the two participants.
Fig. 4 is a schematic structural diagram of a video processing apparatus according to an embodiment of the present invention. As shown in fig. 4, the video processing apparatus 400 may include:
a video obtaining module 410, configured to obtain a target game video;
the video detection module 420 is configured to identify a ball serving action in the target game video by using a preset action identification model;
and a score updating module 430, configured to update the target score when it is recognized that the ball serving action exists in the target game video.
In the embodiment of the invention, the video processing device can acquire the target game video and identify the ball serving action in the target game video by using the preset action identification model, so that the target score is updated under the condition that the ball serving action exists in the target game video, namely, the electronic equipment can quickly and effectively update the target scores corresponding to two participants by identifying the ball serving action in the target game video, thereby realizing accurate scoring of the two participants, improving the accuracy of the scoring result and improving the accuracy of the determined game result.
The video processing device of the embodiment of the invention can be used for scoring two participants in the ball game, and particularly can be applied to the ball game with the same score added or subtracted by the scoring party in each game. Such as table tennis, badminton, tennis, volleyball, etc.
In the embodiment of the present invention, the video processing apparatus 400 may acquire and obtain the target game video through its own image acquisition apparatus, or may obtain the target game video through an image acquisition apparatus communicatively connected to the video processing apparatus 400.
In an embodiment of the present invention, the video detection module 420 may include:
the service action detection unit is used for inputting each frame of image data of the target game video and the audio data corresponding to each frame of image data into a preset action recognition model to obtain a service action confidence sequence corresponding to the target game video;
and the ball serving action determining unit is used for determining that the ball serving action exists in the target game video under the condition that the ball serving action confidence coefficient sequence meets the Gaussian distribution and the ball serving action confidence coefficient peak value in the ball serving action confidence coefficient sequence is greater than a first preset peak value threshold value.
In the embodiment of the present invention, the video processing apparatus 400 may acquire the audio data through its own audio acquisition apparatus, or may acquire the audio data through an audio acquisition apparatus communicatively connected to the video processing apparatus 400.
In the embodiment of the present invention, since the video data is a dynamic image data with a time sequence, the preset motion recognition model can be obtained based on the training of the first long-short memory network with a time sequence.
Therefore, in the embodiment of the present invention, since the ball serving action existing in the target game video corresponding to the target ball game field can be recognized only by using the preset action recognition model obtained based on the first long and short memory network training, the target score corresponding to the two participants is updated, and the data processing amount of the preset action recognition model obtained based on the first long and short memory network training is small, the data processing amount and the calculation amount of the image data and the audio data can be reduced, the data processing efficiency is improved, and the resource occupancy rate of the electronic device is reduced.
In addition, taking a ball game as an example of a badminton game, when a ball serving action exists in a target game video, because the badminton can impact a racket during the ball serving, a sound peak value is generated corresponding to the audio data, the image data can be used for assisting in judging the confidence coefficient of the ball serving action by using the audio data, the interference of detecting the confidence coefficient of the ball serving action is reduced, and the accuracy of a detection result of the confidence coefficient of the ball serving action is improved.
In this embodiment of the present invention, the score updating module 430 may include:
the score detection unit is used for detecting a target score under the condition that the goal serve action exists in the target match video;
the score updating unit is used for not updating the target score under the condition that the target score is detected to be the initial score for the first time; and under the condition that the target score is not detected to be the initial score for the first time or the target score is not detected to be the initial score, updating the target score.
In the embodiment of the invention, after the competition is finished, if the participant who reaches the competition point score wins the competition, the competition is finished, the next competition cannot exist, and the target scores of the two participants cannot be updated through the serve action of the next competition. Therefore, a corresponding scoring party judgment mechanism needs to be designed for the competition game.
Specifically, the video processing apparatus 400 may further include:
the score detection module is used for detecting scores of two participants in the target score;
the video detection module is specifically used for identifying a ball serving action in the target match video by using a preset action identification model under the condition that the scores of the two participants do not reach the preset score; and under the condition that the score of at least one competitor is detected to reach the preset score, identifying the batting action in the target game video and the ball track position at each moment in the target game video, and updating the target score according to the batting action and the ball track position at each moment.
It should be noted that the video processing apparatus according to the embodiment of the present invention can implement each process in the above-mentioned video processing method embodiment, and details are not described herein to avoid repetition.
The electronic device provided in the embodiment of the present invention can implement each process implemented by the electronic device in the method embodiments of fig. 1 to fig. 3, and is not described herein again to avoid repetition.
Fig. 5 is a schematic diagram of a hardware structure of an electronic device implementing various embodiments of the present invention. As shown in fig. 5, the electronic device 500 includes, but is not limited to: a radio frequency unit 501, a network module 502, an audio output unit 503, an input unit 504, a sensor 505, a display unit 506, a user input unit 507, an interface unit 508, a memory 509, a processor 510, and a power supply 511. Those skilled in the art will appreciate that the electronic device configuration shown in fig. 5 does not constitute a limitation of the electronic device, and that the electronic device may include more or fewer components than shown, or some components may be combined, or a different arrangement of components. In the embodiment of the present invention, the electronic device includes, but is not limited to, a mobile phone, a tablet computer, a notebook computer, a palm computer, a vehicle-mounted terminal, a wearable device, a pedometer, and the like.
Wherein, the processor 510 is configured to:
acquiring a target match video;
recognizing a ball serving action in a target game video by using a preset action recognition model;
and in the case that the goal match video is identified to have the ball serving action, updating the goal score.
In the embodiment of the invention, the electronic equipment can acquire the target game video and identify the ball serving action in the target game video by using the preset action identification model, so that the target score is updated under the condition that the ball serving action exists in the target game video, namely, the electronic equipment can quickly and effectively update the target scores corresponding to the two participants by identifying the ball serving action in the target game video, thereby realizing accurate scoring of the two participants, improving the accuracy of the scoring result and improving the accuracy of the determined game result.
It should be understood that, in the embodiment of the present invention, the radio frequency unit 501 may be used for receiving and sending signals during a message sending and receiving process or a call process, and specifically, receives downlink data from a base station and then processes the received downlink data to the processor 510; in addition, the uplink data is transmitted to the base station. In general, radio frequency unit 501 includes, but is not limited to, an antenna, at least one amplifier, a transceiver, a coupler, a low noise amplifier, a duplexer, and the like. In addition, the radio frequency unit 501 can also communicate with a network and other devices through a wireless communication system.
The electronic device provides wireless broadband internet access to the user via the network module 502, such as assisting the user in sending and receiving e-mails, browsing web pages, and accessing streaming media.
The audio output unit 503 may convert audio data received by the radio frequency unit 501 or the network module 502 or stored in the memory 509 into an audio signal and output as sound. Also, the audio output unit 503 may also provide audio output related to a specific function performed by the electronic apparatus 500 (e.g., a call signal reception sound, a message reception sound, etc.). The audio output unit 503 includes a speaker, a buzzer, a receiver, and the like.
The input unit 504 is used to receive an audio or video signal. The input Unit 504 may include a Graphics Processing Unit (GPU) 5041 and a microphone 5042, and the Graphics processor 5041 processes image data of a still picture or video obtained by an image capturing device (e.g., a camera) in a video capturing mode or an image capturing mode. The processed image frames may be displayed on the display unit 506. The image frames processed by the graphic processor 5041 may be stored in the memory 509 (or other storage medium) or transmitted via the radio frequency unit 501 or the network module 502. The microphone 5042 may receive sounds and may be capable of processing such sounds into audio data. The processed audio data may be converted into a format output transmittable to a mobile communication base station via the radio frequency unit 501 in case of the phone call mode.
The electronic device 500 also includes at least one sensor 505, such as light sensors, motion sensors, and other sensors. Specifically, the light sensor includes an ambient light sensor that can adjust the brightness of the display panel 5061 according to the brightness of ambient light, and a proximity sensor that can turn off the display panel 5061 and/or a backlight when the electronic device 500 is moved to the ear. As one type of motion sensor, an accelerometer sensor can detect the magnitude of acceleration in each direction (generally three axes), detect the magnitude and direction of gravity when stationary, and can be used to identify the posture of an electronic device (such as horizontal and vertical screen switching, related games, magnetometer posture calibration), and vibration identification related functions (such as pedometer, tapping); the sensors 505 may also include fingerprint sensors, pressure sensors, iris sensors, molecular sensors, gyroscopes, barometers, hygrometers, thermometers, infrared sensors, etc., which are not described in detail herein.
The display unit 506 is used to display information input by the user or information provided to the user. The Display unit 506 may include a Display panel 5061, and the Display panel 5061 may be configured in the form of a Liquid Crystal Display (LCD), an Organic Light-Emitting Diode (OLED), or the like.
The user input unit 507 may be used to receive input numeric or character information and generate key signal inputs related to user settings and function control of the electronic device. Specifically, the user input unit 507 includes a touch panel 5071 and other input devices 5072. Touch panel 5071, also referred to as a touch screen, may collect touch operations by a user on or near it (e.g., operations by a user on or near touch panel 5071 using a finger, stylus, or any suitable object or attachment). The touch panel 5071 may include two parts of a touch detection device and a touch controller. The touch detection device detects the touch direction of a user, detects a signal brought by touch operation and transmits the signal to the touch controller; the touch controller receives touch information from the touch sensing device, converts the touch information into touch point coordinates, sends the touch point coordinates to the processor 510, and receives and executes commands sent by the processor 510. In addition, the touch panel 5071 may be implemented in various types such as a resistive type, a capacitive type, an infrared ray, and a surface acoustic wave. In addition to the touch panel 5071, the user input unit 507 may include other input devices 5072. In particular, other input devices 5072 may include, but are not limited to, a physical keyboard, function keys (e.g., volume control keys, switch keys, etc.), a trackball, a mouse, and a joystick, which are not described in detail herein.
Further, the touch panel 5071 may be overlaid on the display panel 5061, and when the touch panel 5071 detects a touch operation thereon or nearby, the touch operation is transmitted to the processor 510 to determine the type of the touch event, and then the processor 510 provides a corresponding visual output on the display panel 5061 according to the type of the touch event. Although in fig. 5, the touch panel 5071 and the display panel 5061 are two independent components to implement the input and output functions of the electronic device, in some embodiments, the touch panel 5071 and the display panel 5061 may be integrated to implement the input and output functions of the electronic device, and is not limited herein.
The interface unit 508 is an interface for connecting an external device to the electronic apparatus 500. For example, the external device may include a wired or wireless headset port, an external power supply (or battery charger) port, a wired or wireless data port, a memory card port, a port for connecting a device having an identification module, an audio input/output (I/O) port, a video I/O port, an earphone port, and the like. The interface unit 508 may be used to receive input (e.g., data information, power, etc.) from external devices and transmit the received input to one or more elements within the electronic apparatus 500 or may be used to transmit data between the electronic apparatus 500 and external devices.
The memory 509 may be used to store software programs as well as various data. The memory 509 may mainly include a storage program area and a storage data area, wherein the storage program area may store an operating system, an application program required by at least one function (such as a sound playing function, an image playing function, etc.), and the like; the storage data area may store data (such as audio data, a phonebook, etc.) created according to the use of the cellular phone, and the like. Further, the memory 509 may include high-speed random access memory, and may also include non-volatile memory, such as at least one magnetic disk storage device, flash memory device, or other volatile solid-state storage device.
The processor 510 is a control center of the electronic device, connects various parts of the whole electronic device by using various interfaces and lines, performs various functions of the electronic device and processes data by running or executing software programs and/or modules stored in the memory 509 and calling data stored in the memory 509, thereby performing overall monitoring of the electronic device. Processor 510 may include one or more processing units; preferably, the processor 510 may integrate an application processor, which mainly handles operating systems, user interfaces, application programs, etc., and a modem processor, which mainly handles wireless communications. It will be appreciated that the modem processor described above may not be integrated into processor 510.
The electronic device 500 may further include a power supply 511 (e.g., a battery) for supplying power to various components, and preferably, the power supply 511 may be logically connected to the processor 510 via a power management system, so as to implement functions of managing charging, discharging, and power consumption via the power management system.
In addition, the electronic device 500 includes some functional modules that are not shown, and are not described in detail herein.
Preferably, an embodiment of the present invention further provides an electronic device, which includes a processor 510, a memory 509, and a computer program that is stored in the memory 509 and can be run on the processor 510, and when the computer program is executed by the processor 510, the processes of the video processing method embodiment are implemented, and the same technical effect can be achieved, and in order to avoid repetition, details are not described here again.
The embodiment of the present invention further provides a computer-readable storage medium, where a computer program is stored on the computer-readable storage medium, and when the computer program is executed by a processor, the computer program implements each process of the video processing method embodiment, and can achieve the same technical effect, and in order to avoid repetition, details are not repeated here. The computer-readable storage medium may be a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk or an optical disk.
It should be noted that, in this document, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising an … …" does not exclude the presence of other like elements in a process, method, article, or apparatus that comprises the element.
Through the above description of the embodiments, those skilled in the art will clearly understand that the method of the above embodiments can be implemented by software plus a necessary general hardware platform, and certainly can also be implemented by hardware, but in many cases, the former is a better implementation manner. Based on such understanding, the technical solutions of the present invention may be embodied in the form of a software product, which is stored in a storage medium (such as ROM/RAM, magnetic disk, optical disk) and includes instructions for enabling a terminal (such as a mobile phone, a computer, a server, an air conditioner, or a network device) to execute the method according to the embodiments of the present invention.
While the present invention has been described with reference to the embodiments shown in the drawings, the present invention is not limited to the embodiments, which are illustrative and not restrictive, and it will be apparent to those skilled in the art that various changes and modifications can be made therein without departing from the spirit and scope of the invention as defined in the appended claims.

Claims (10)

1. A video processing method applied to an electronic device is characterized by comprising the following steps:
acquiring a target match video;
recognizing a ball serving action in the target game video by using a preset action recognition model;
and updating the target score when the goal-serving action exists in the target game video.
2. The method of claim 1, wherein updating the target score in the event that the ball serving action is identified as being present in the target game video comprises:
under the condition that the goal match video is identified to have the serve action, if the goal score is detected to be the initial score for the first time, the goal score is not updated; and if the target score is not detected as the initial score for the first time or if the target score is not detected as the initial score, updating the target score.
3. The method of claim 1, wherein the identifying a ball serving action in the target game video using a preset action recognition model comprises:
inputting each frame of image data of the target game video and audio data corresponding to each frame of image data into a preset action recognition model to obtain a ball serving action confidence sequence corresponding to the target game video;
and if the confidence sequence of the serve action meets the Gaussian distribution and the confidence peak value of the serve action in the confidence sequence of the serve action is larger than a first preset peak value threshold value, determining that the serve action exists in the target game video.
4. The method of claim 1, wherein in the event that the target game video includes a first of two competitor fields, further comprising:
receiving a score updating request sent by target equipment corresponding to a second competitor field in the two competitor fields;
updating the target score in response to the score update request.
5. The method of claim 1, wherein the utilizing a preset motion recognition model, before recognizing a ball serving motion in the target game video, further comprises:
under the condition that the scores of the two participants do not reach the preset score, the service action is identified in the target competition video by utilizing the preset action identification model;
and under the condition that at least one of the participator scores reaches the preset score, identifying the batting action in the target game video and the ball track position at each moment in the target game video, and updating the target score according to the batting action and the ball track position at each moment.
6. The method of claim 5, wherein in the event that the target game video includes a first of two participant fields, said updating the target score based on the ball striking motion and the ball trajectory position at each of the time instants comprises:
receiving an information updating request sent by target equipment corresponding to a second competitor field in the two competitor fields; wherein the information update request includes a ball hitting action in the second participant field and a ball trajectory position at each moment in the second participant field;
updating the batting action and the ball track position at each moment in response to the information updating request;
and updating the target score according to the updated batting action and the ball track position at each moment.
7. A video processing apparatus, comprising:
the video acquisition module is used for acquiring a target match video;
the video detection module is used for identifying a ball serving action in the target game video by using a preset action identification model;
and the score updating module is used for updating the target score under the condition that the goal playing action exists in the target game video.
8. The apparatus of claim 7, wherein the score update module comprises:
a score detection unit for detecting the target score when the goal service action is recognized to exist in the target game video;
the score updating unit is used for not updating the target score under the condition that the target score is detected as the initial score for the first time; and updating the target score under the condition that the target score is not detected as the initial score for the first time or if the target score is not detected as the initial score.
9. The apparatus of claim 7, wherein the video detection module comprises:
the ball serving action detection unit is used for inputting each frame of image data of the target game video and audio data corresponding to each frame of image data into a preset action recognition model to obtain a ball serving action confidence coefficient sequence corresponding to the target game video;
and the ball serving action determining unit is used for determining that the ball serving action exists in the target game video under the condition that the ball serving action confidence sequence meets the Gaussian distribution and the peak value of the ball serving action confidence in the ball serving action confidence sequence is greater than a first preset peak value threshold.
10. The apparatus of claim 7, further comprising:
the score detection module is used for detecting scores of two participants in the target scores;
the video detection module is specifically used for identifying the ball serving action in the target match video by using a preset action identification model under the condition that the scores of the two participants do not reach preset scores; and under the condition that at least one of the competition party scores reaches the preset score, identifying the batting action in the target competition video and the ball track position at each moment in the target competition video, and updating the target score according to the batting action and the ball track position at each moment.
CN201910949696.5A 2019-10-08 2019-10-08 Video processing method and device Pending CN110765896A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910949696.5A CN110765896A (en) 2019-10-08 2019-10-08 Video processing method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910949696.5A CN110765896A (en) 2019-10-08 2019-10-08 Video processing method and device

Publications (1)

Publication Number Publication Date
CN110765896A true CN110765896A (en) 2020-02-07

Family

ID=69331088

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910949696.5A Pending CN110765896A (en) 2019-10-08 2019-10-08 Video processing method and device

Country Status (1)

Country Link
CN (1) CN110765896A (en)

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112237731A (en) * 2020-10-19 2021-01-19 上海名图软件有限公司 Automatic scoring system and scoring method for badminton match
CN113542774A (en) * 2021-06-04 2021-10-22 北京格灵深瞳信息技术股份有限公司 Video synchronization method and device, electronic equipment and storage medium
CN114494356A (en) * 2022-04-02 2022-05-13 中傲数据技术(深圳)有限公司 Badminton video clip processing method and system based on artificial intelligence
CN116370939A (en) * 2023-03-13 2023-07-04 刘鑫宇 Game scoring method and related equipment based on martial arts free combat protective equipment and images

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101833232A (en) * 2010-04-20 2010-09-15 浙江大学 Visual support and match analysis system for ping-pong match and method for running same
CN107773961A (en) * 2017-09-15 2018-03-09 维沃移动通信有限公司 One kind service control method and mobile terminal
CN108079565A (en) * 2017-12-28 2018-05-29 深圳市超级视觉科技有限公司 A kind of game of billiards scoring system
CN108549861A (en) * 2018-04-10 2018-09-18 百度在线网络技术(北京)有限公司 Point system and device
CN109325440A (en) * 2018-09-19 2019-02-12 深圳市赢世体育科技有限公司 Human motion recognition method and system
CN109663325A (en) * 2019-01-25 2019-04-23 深圳大学 A kind of scoring system and point system of type games of batting

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101833232A (en) * 2010-04-20 2010-09-15 浙江大学 Visual support and match analysis system for ping-pong match and method for running same
CN107773961A (en) * 2017-09-15 2018-03-09 维沃移动通信有限公司 One kind service control method and mobile terminal
CN108079565A (en) * 2017-12-28 2018-05-29 深圳市超级视觉科技有限公司 A kind of game of billiards scoring system
CN108549861A (en) * 2018-04-10 2018-09-18 百度在线网络技术(北京)有限公司 Point system and device
CN109325440A (en) * 2018-09-19 2019-02-12 深圳市赢世体育科技有限公司 Human motion recognition method and system
CN109663325A (en) * 2019-01-25 2019-04-23 深圳大学 A kind of scoring system and point system of type games of batting

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
赵洪明,张力彤,吕然: "《大学体育实践教程》", 31 July 2014 *

Cited By (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112237731A (en) * 2020-10-19 2021-01-19 上海名图软件有限公司 Automatic scoring system and scoring method for badminton match
CN114949825A (en) * 2020-10-19 2022-08-30 上海名图软件有限公司 Automatic scoring system and scoring method for badminton match
CN113542774A (en) * 2021-06-04 2021-10-22 北京格灵深瞳信息技术股份有限公司 Video synchronization method and device, electronic equipment and storage medium
CN113542774B (en) * 2021-06-04 2023-10-20 北京格灵深瞳信息技术股份有限公司 Video synchronization method, device, electronic equipment and storage medium
CN114494356A (en) * 2022-04-02 2022-05-13 中傲数据技术(深圳)有限公司 Badminton video clip processing method and system based on artificial intelligence
CN114494356B (en) * 2022-04-02 2022-06-24 中傲数据技术(深圳)有限公司 Badminton video clip processing method and system based on artificial intelligence
CN116370939A (en) * 2023-03-13 2023-07-04 刘鑫宇 Game scoring method and related equipment based on martial arts free combat protective equipment and images

Similar Documents

Publication Publication Date Title
CN110765896A (en) Video processing method and device
CN108449489B (en) Flexible screen control method, mobile terminal and server
CN108153422B (en) Display object control method and mobile terminal
CN110174993B (en) Display control method, terminal equipment and computer readable storage medium
CN108683850B (en) Shooting prompting method and mobile terminal
CN109376705A (en) Dance training methods of marking, device and computer readable storage medium
CN110075521A (en) Pressure rifle householder method, device, mobile terminal and the storage medium of shooting game
CN108668024B (en) Voice processing method and terminal
CN111083354A (en) Video recording method and electronic equipment
CN108762877B (en) Control method of mobile terminal interface and mobile terminal
CN111416904B (en) Data processing method, electronic device and medium
CN111415722B (en) Screen control method and electronic equipment
CN110636225B (en) Photographing method and electronic equipment
CN111158624A (en) Application sharing method, electronic equipment and computer readable storage medium
CN115497159A (en) Human body abnormal state detection method and device, computer equipment and storage medium
CN109754819B (en) Data processing method, device and storage medium
CN110942022A (en) Shooting data output method and electronic equipment
CN111078072B (en) Display control method, device and computer readable storage medium
CN109453526B (en) Sound processing method, terminal and computer readable storage medium
CN108536272B (en) Method for adjusting frame rate of application program and mobile terminal
CN108234745B (en) Signal receiving method, mobile terminal and computer readable storage medium
CN108038427B (en) Character recognition method and mobile terminal
CN110013673B (en) Method, device and storage medium for playing game by using folding display screen
CN110046569B (en) Unmanned driving data processing method and device and electronic equipment
CN111276142B (en) Voice wake-up method and electronic equipment

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
RJ01 Rejection of invention patent application after publication

Application publication date: 20200207

RJ01 Rejection of invention patent application after publication