Method, device and equipment for capturing baby video highlights based on action classification

By extracting and classifying key points of limbs in baby videos, and using action classification models to accurately capture movements in baby videos, the problem of poor baby video capture effects in the existing technology is solved, and the fun and user experience of the videos are improved.

CN115914741BActive Publication Date: 2024-10-18WUHAN SIMSHINE INTELLIGENT TECH CO LTD
View PDF 6 Cites 0 Cited by

Patent Information

Application Number
CN202211565460.X
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-04-27
Publication Date
2024-10-18
Estimated Expiration
2041-04-27

AI Technical Summary

Technical Problem

The existing method of capturing baby video highlights based on action classification cannot effectively capture baby videos, resulting in poor user experience and prone to ghosting or unclear information.

Method used

By converting the baby video into HSV color space, extract each frame target image containing the key points of the baby's limbs, classify the images using the preset action classification model, and calculate the dispersion of the key points of the limbs to determine the action benchmark image, thereby accurately Capture videos of specific baby movements.

Benefits of technology

It achieves precise capture of videos of specific baby movements, saves device storage space, and improves the fun and user experience of the video.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115914741B_ABST
    Figure CN115914741B_ABST
Patent Text Reader

Abstract

The present invention belongs to the technical field of video editing, solves the technical problem that the conventional method of video editing cannot complete the targeted editing of baby specific actions, resulting in poor user experience, and provides a method, device and equipment for capturing baby video collection based on action classification. The method includes: obtaining the initial video of the baby, converting the initial color space of the initial video of the baby into the HSV color space, recording the converted video as the baby video, extracting each frame target image containing the key points of the baby's limbs in the baby video; classifying the target images of each frame using a preset action classification model, and determining the action image set; determining the target video according to the key points of the baby's limbs in each frame target image in the action image set. Through this method, the corresponding video can be captured based on the baby's specific actions, which is convenient for users to store and view, and also saves storage space and improves the fun of the video.
Need to check novelty before this filing date? Find Prior Art

Description

[0001] This application is a divisional application of the invention patent application filed on April 27, 2021, with the invention name being “Method, device, equipment and medium for automatically capturing wonderful baby video highlights” and application number 2021104651800. Technical Field

[0002] The present invention relates to the technical field of video editing, and in particular to a method, device and equipment for capturing baby video highlights based on action classification. Background Art

[0003] With the development of computer and network technology, the functions of electronic devices are becoming more and more diversified. It is becoming more and more popular for users to splice interesting video segments into new videos by video editing.

[0004] In the prior art, there are mainly several methods for capturing baby video highlights based on action classification: one is to use background modeling to remove invalid backgrounds and combine dynamic scenes into videos. This method has the advantage of fast speed, but the editing effect is too poor and ghosting is prone to occur; the other method is to detect the target object in the scene and capture the video using the picture containing the person as the key frame. The video captured by this method cannot obtain meaningful information and the information is relatively unclear. Therefore, the user experience is poor. Summary of the invention

[0005] In view of this, the embodiments of the present invention provide a method, device and equipment for capturing baby video highlights based on action classification, so as to solve the technical problem that it is impossible to effectively capture infant videos in the prior art.

[0006] The technical solution adopted by the present invention is:

[0007] The present invention provides a method for capturing baby video highlights based on action classification, characterized in that the method comprises:

[0008] Obtaining an initial video of the baby, converting an initial color space of the initial video of the baby into an HSV color space, recording the converted video as the baby video, and extracting target images of each frame containing key points of the baby's limbs in the baby video;

[0009] Using a preset action classification model to classify the target images of each frame to determine an action image set;

[0010] The target video is determined according to the key points of the baby's limbs in each frame of the target image in the action image set.

[0011] Preferably, the step of acquiring the initial baby video, converting the initial color space of the initial baby video into the HSV color space, recording the converted video as the baby video, and extracting each frame target image containing the key points of the baby's limbs in the baby video comprises:

[0012] Obtain the conversion relationship between the initial color space of the baby's initial video and the HSV color space;

[0013] Converting the initial baby video into the baby video in the HSV color space according to the conversion relationship;

[0014] Obtaining a frame rate of the baby video, and decomposing the baby video into corresponding frame images according to the frame rate;

[0015] The key points of the baby's limbs are detected for each frame of the image, and the target images of each frame containing the key points of the baby's limbs are output.

[0016] Preferably, the step of classifying the target images of each frame by using a preset action classification model to determine the action image set comprises:

[0017] Obtain the image size of each frame of the target image and the key point coordinates corresponding to each key point of the infant's limbs in the target image;

[0018] According to each of the image sizes, the coordinates of each of the key points in the target image corresponding to each of the image sizes are standardized to obtain standardized coordinate values ​​of each of the key points of the infant's limbs;

[0019] According to the standardized coordinate values ​​of the key points of the baby's limbs in each frame of the target image, each frame of the target image is classified and the action image set is output.

[0020] Preferably, the classifying each frame of target image according to the standardized coordinate values ​​of each key point of each infant's limb in each frame of target image, and outputting the action image set comprises:

[0021] Taking the standardized coordinate values ​​of each key point of the baby's limbs in each frame of the target image as a group, obtaining a target coordinate group of each key point of the baby's limbs corresponding to each frame of the target image;

[0022] The target coordinate group is input into a preset classifier to perform action classification on the target image, and an action image set is output; wherein the preset classifier includes an SVM classifier, and the SVM classifier identifies whether the target image includes an infant's face based on the input target image. When it is identified that the target image includes an infant's face, the target image is input into a classification subnetwork of the SVM classifier, and the probability of occurrence of each infant action category is determined by the classification subnetwork, and the action image set is output.

[0023] Preferably, determining the target video according to the key points of the baby's limbs in each frame of the target image in the action image set comprises:

[0024] According to the position of each key point of the baby's limbs in the target image, the discreteness of the key points of the baby's limbs in each frame of the target image in the action image set is calculated, and the reference image corresponding to each type of action is output;

[0025] The videos corresponding to various actions in the baby video are edited based on the reference images, and a target video is output.

[0026] Preferably, the step of calculating the discreteness of the key points of the baby's limbs in each frame of the target image in the action image set according to the position of each key point of the baby's limbs in the target image, and outputting the reference image corresponding to each type of action comprises:

[0027] Segment each frame of the target image to obtain multiple sub-images of the same size;

[0028] Obtaining the center coordinates of each of the sub-images, and determining a weight value according to the distance between the center position of each sub-image and the center position of the target image;

[0029] Obtaining discrete values ​​of key points of the baby's limbs in each frame of the target image according to the central coordinates and weight values ​​of each of the sub-images in each frame of the target image;

[0030] The discrete values ​​of the target images of each frame corresponding to each type of action are compared, and the reference images corresponding to each type of action are output.

[0031] Preferably, the step of editing the videos corresponding to various actions in the baby video based on the reference images to output the target video comprises:

[0032] Acquire the duration of each action and the time sequence of each of the reference images;

[0033] Capturing the action image set before and / or after the reference image to obtain each action sub-video of the time length;

[0034] The action sub-videos are spliced ​​according to the sequence of the moments, and the target video is output.

[0035] The present invention also provides a device for capturing baby video highlights based on action classification, comprising:

[0036] An image data extraction module is used to obtain an initial video of the baby, convert the initial color space of the initial video of the baby into an HSV color space, record the converted video as the baby video, and extract each frame target image containing the key points of the baby's limbs in the baby video;

[0037] An image data classification module is used to classify the target images of each frame using a preset action classification model to determine an action image set;

[0038] The video data synthesis module is used to determine the target video according to the key points of the baby's limbs in each frame of the target image in the action image set.

[0039] The present invention also provides an electronic device, comprising: at least one processor, at least one memory, and computer program instructions stored in the memory, and when the computer program instructions are executed by the processor, any of the above-mentioned methods is implemented.

[0040] The present invention also provides a medium on which computer program instructions are stored, and when the computer program instructions are executed by a processor, any of the above-mentioned methods is implemented.

[0041] In summary, the beneficial effects of the present invention are as follows:

[0042] The present invention provides a method, device and equipment for capturing a collection of baby videos based on action classification, which extracts target images of each frame containing key points of the baby's limbs from the baby video, and classifies the actions in each frame image to obtain a set of action images; then calculates the discreteness of the key points of the baby's limbs in each frame image, thereby determining the reference image corresponding to each action; based on each reference image, various actions in the baby video are captured to obtain a target video consisting of a corresponding number of image frames for each action; through this method, the video corresponding to the specific action of the baby can be accurately captured, and then stored and viewed, which can save device storage space and improve the fun of the video and user experience. BRIEF DESCRIPTION OF THE DRAWINGS

[0043] In order to more clearly illustrate the technical solution of the embodiment of the present invention, the drawings required for use in the embodiment of the present invention will be briefly introduced below. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative work, and these are all within the protection scope of the present invention.

[0044] Figure 1 Schematic diagram of the flow of the method for capturing baby video highlights based on action classification in Example 1 of the present invention;

[0045] Figure 2 This is a schematic diagram of a process for obtaining an action image set in Embodiment 1 of the present invention;

[0046] Figure 3 This is a schematic diagram of the process of normalizing the coordinates of key points of an infant's limbs in Example 1 of the present invention;

[0047] Figure 4This is a schematic diagram of a process for obtaining target coordinate values ​​of key points of an infant's limbs in Example 1 of the present invention;

[0048] Figure 5 Schematic diagram of the process of obtaining the reference image of each action in Embodiment 1 of the present invention;

[0049] Figure 6 This is a schematic diagram of a process for obtaining a target video in Embodiment 1 of the present invention;

[0050] Figure 7 This is a schematic diagram of a process for obtaining a baby video corresponding to an HSV color space in Embodiment 1 of the present invention;

[0051] Figure 8 Schematic diagram of the structure of a baby video collection capture device based on action classification in Example 2 of the present invention;

[0052] Fig. 9 Schematic diagram of the structure of an electronic device in Embodiment 3 of the present invention. DETAILED DESCRIPTION

[0053] In order to make the purpose, technical solution and advantages of the embodiment of the present invention clearer, the technical solution in the embodiment of the present invention will be clearly and completely described in conjunction with the drawings in the embodiment of the present invention. It should be noted that, in this article, relational terms such as first and second are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply that there is any such actual relationship or order between these entities or operations. In the description of the present invention, it should be understood that the orientation or position relationship indicated by the terms "center", "upper", "lower", "front", "back", "left", "right", "vertical", "horizontal", "top", "bottom", "inside", "outside", etc. is based on the orientation or position relationship shown in the drawings, which is only for the convenience of describing the present application and simplifying the description, rather than indicating or implying that the device or element referred to must have a specific orientation, be constructed and operated in a specific orientation, and therefore cannot be understood as a limitation of the present invention. Moreover, the term "include", "comprise" or any other variant thereof is intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also includes other elements not explicitly listed, or also includes elements inherent to such a process, method, article or device. In the absence of further restrictions, the elements defined by the phrase "comprising..." do not exclude the presence of other identical elements in the process, method, article or device comprising the elements. If there is no conflict, the various features in the embodiments and examples of the present invention can be combined with each other, all within the scope of protection of the present invention.

[0054] Implementation Method 1

[0055] Example 1

[0056] See also Figure 1 , Figure 1 The flowchart of the method for capturing baby video highlights based on action classification in Embodiment 1 of the present invention is as follows; the method comprises:

[0057] S1: Extract target images of each frame containing key points of baby limbs in the baby video, and output action image sets divided into action categories;

[0058] Specifically, the baby video captured by the camera is divided into frames according to the frame rate of the video, and the baby video is converted into multiple frames of images; the image frames containing the key points of the baby's limbs are extracted, and then the extracted image frames are divided according to the action category to form an action image set that distinguishes the action categories; the action image set includes at least one image corresponding to an action, and at the same time, any category of action includes at least one image. By integrating and classifying the key frames of each action, it is helpful to compare the key frames of the same action, screen out the key frames that meet the requirements, reduce the interference between images of different actions, and reduce the amount of data processing.

[0059] In one embodiment, see Figure 2 , the S1 comprises:

[0060] S11: Obtain the frame rate of the video;

[0061] Specifically, the frame rate of the video stream is the number of image frames transmitted per unit time during video transmission. For example, if the frame rate is 20 frames per second, an image is transmitted every 0.05 seconds.

[0062] S12: Decomposing the baby video into corresponding frame images according to the frame rate;

[0063] Specifically, the baby video is converted into frame images according to the frame rate, including frame images with baby movements and frame images without baby movements, such as: when the baby disappears or appears in the corresponding video from the camera monitoring area, the baby exists in some image frames and not in some image frames.

[0064] S13: Detect key points of baby limbs on each frame of the image, and output each frame of target image containing key points of baby limbs;

[0065] Specifically, each frame of image is detected to determine whether each frame of image contains human body key points corresponding to specific actions of the baby. If so, the frame of image is extracted. Using this method, each frame of image that conforms to the specific action is obtained; the specific action includes at least one of the following: holding, sucking, laughing, jumping, crawling, standing, covering the face, raising the head, turning around, and other growth actions of infants and young children aged 0 to 3 years old.

[0066] S14: using a preset action classification model to classify each frame of target image, and outputting the action image set.

[0067] Specifically, the information and positional relationship of the key points of the infant's limbs corresponding to each action are stored in the action classification model, and the collected corresponding key points of the infant's limbs and the positional information between the key points are compared with the preset historical data to obtain the image of each action to form an action image set; and the classification of the action is completed.

[0068] In one embodiment, see Figure 3 , the S14 comprises:

[0069] S141: Obtaining the image size of each frame of the target image and the key point coordinates corresponding to each key point of the baby's limbs in the target image;

[0070] Specifically, the length L of each frame image is obtained a and width dimension W a , and the key point coordinates P of each key point of the baby's limbs in each target image a (X i ,Y i ), where a is the ath target image, i is the i-th limb key point of the target image, X is the horizontal coordinate, Y is the vertical coordinate, W is the width of the target image, L is the length of the target image, P a (X i ,Y i ) is the coordinate of the i-th limb key point in the a-th target image.

[0071] S142: According to each image size, the coordinates of each key point in the target image corresponding to each image size are normalized to obtain the normalized coordinate values ​​of each key point of the infant's limbs.

[0072] Specifically, the image size of each target image and the key point coordinates of each key point of the infant's limbs in each target image are obtained, and then the coordinates of each key point are standardized, that is, normalized; and the standardized coordinate values ​​of each key point of the infant's limbs are obtained.

[0073] In one embodiment, see Figure 4 , the S142 includes:

[0074] S1421: Using formula Convert each of the key point coordinates P (X, Y) into a corresponding floating point value;

[0075] Specifically, using the formula The horizontal and vertical coordinates corresponding to each key point of the target image are converted into corresponding floating point values, such as the horizontal coordinate X of the i-th key point in image a.i Convert to the corresponding floating point value P i (X′), the horizontal coordinate Y of the i-th key point in image a i Convert to the corresponding floating point value P i (Y′).

[0076] S1422: Using formula Convert each of the floating point values ​​into a corresponding standard coordinate value;

[0077] Specifically, after converting the key point coordinates into corresponding floating point values, use the formula

[0078] Each floating point value is converted into a corresponding standard coordinate value, thereby completing the standardization of the key point coordinates. i After standardization, the coordinate standard value P is obtained. i (X″), the horizontal coordinate Y of the i-th key point in image a i After standardization, the coordinate standard value P is obtained i (Y″).

[0079] Wherein, W is the width of the target image, L is the length of the target image, X is the horizontal coordinate of the limb key point, Y is the vertical coordinate of the limb key point, X′ is the floating point value corresponding to the horizontal coordinate, Y′ is the floating point value corresponding to the vertical coordinate, X″ is the standard coordinate value corresponding to the horizontal coordinate, Y″ is the standard coordinate value corresponding to the vertical coordinate, and q is the total number of limb key points contained in the corresponding action in each target image.

[0080] S143: Classify each frame of target image according to the standardized coordinate values ​​of each key point of the baby's limbs in each frame of target image, and output the action image set.

[0081] Specifically, according to the normalized coordinate values ​​corresponding to all limb key points in each target image, the action type of the target image is obtained, the action type of each target image is classified, and the action type is output as an action image set. The target coordinate values ​​of all limb key points in each target image are taken as a group to obtain the target coordinate group of each limb key point corresponding to each target image, and then each group of target coordinate value groups is input into the SVM classifier to classify the actions in each target image, and the action image set is output; the SVM classifier is a linear classifier, which is mainly used for binary classification. The SVM classifier can determine whether the image includes a face or not based on the input feature map. The feature map of the image frame is input into the classification subnetwork, and the classification subnetwork can output the probability of each action category in each target detection frame, thereby realizing the action classification of the target image; which includes but is not limited to faces, and can also be arms, torsos, etc.;.

[0082] S2: Calculate the discreteness of the key points of the baby's limbs in each frame of the target image in the action image set, and output the reference images corresponding to each type of action;

[0083] Specifically, the discreteness of the key points is calculated according to the positions of the key points of the baby's limbs in the image, and the image with the discreteness meeting the requirements is used as the reference image. Subsequently, the reference image is used as a reference to capture each frame of the corresponding action. For example, the reference image of action A1 is a, and the image a is used as a reference to capture the corresponding image frame in action A1 according to the established capture method to obtain the capture action of action A1; the reference image of action A2 is b, and the image b is used as a reference to capture the corresponding image frame in action A2 according to the established capture method to obtain the capture action of action A2.

[0084] It should be noted that the preset classifiers include but are not limited to common classifiers such as SVM and softmax.

[0085] In one embodiment, see Figure 5 , said S2 comprises:

[0086] S21: Segment each frame of the target image to obtain multiple sub-images of the same size;

[0087] Specifically, each target image is divided into a plurality of sub-images of the same size according to a predetermined rule. For example, each target image is divided into 9 sub-images in a nine-square grid.

[0088] S22: Obtain the center coordinates and weight value of each sub-image;

[0089] Specifically, the center coordinates of each sub-image are obtained, and a weight value is assigned to each sub-image. The size of the weight is determined by the distance between the center position of each sub-image and the center position of the target image. For example, each target image is divided into a nine-square grid to obtain 9 sub-images. The 1st, 3rd, 7th and 9th sub-images are farthest from the center point, and the weight value is set to 2. The 2nd, 4th, 6th and 8th sub-images are close to the center point, and the weight value is set to 1. The center point of the 5th sub-image coincides with the center point of the target image, and the weight value is set to 0.

[0090] It should be noted that the weight setting includes but is not limited to pre-setting, setting by the user according to usage habits, and modification by the system according to the user's preference for the target image; for example, some users prefer centered high-color images or videos, and some users prefer images or videos with image offset or distortion.

[0091] It should be noted that the center coordinates of the image can be preset by the system or a point set by the user later.

[0092] S23: Obtaining discrete values ​​of key points of the baby's limbs in each frame of the target image according to the central coordinates and weight values ​​of each of the sub-images in each frame of the target image;

[0093] Specifically, according to the center coordinates of each sub-image and the corresponding weight value, the formula S = W1 + W2 + ... + W q Calculate the discrete value of each target image, where S is the discrete value of the key points of the baby's limbs in each target image, W is the weight value, and W q Represents the weight value of the qth limb key point; taking the target image of the nine-square grid segmentation as an example, limb key points 1 and 2 are both located in the first sub-image, then the values ​​of W1 and W2 are both 2.

[0094] S24: comparing the discrete values ​​of the target images of each frame corresponding to each type of action, and outputting the reference images corresponding to each type of action.

[0095] Specifically, by comparing the discrete values ​​of target images of each frame in the same action type, a larger discrete value indicates a better image effect of the captured baby action, and thus the target image with a larger discrete value is used as the reference image.

[0096] S3: based on the reference images, clipping the videos corresponding to the various actions in the baby video to output a target video.

[0097] Specifically, after determining the reference image of each action, each action is captured according to the action capture rule to obtain a wonderful video stream corresponding to each action, and then spliced ​​to obtain the target video.

[0098] In one embodiment, see Figure 6 , said S3 comprises:

[0099] S31: Acquire the duration of each action and the time sequence of each reference image;

[0100] Specifically, the time length T corresponding to an action is set, that is, the total number of images included in an action is determined; and the time of each frame of the reference image is determined to obtain the time sequence of all the reference images.

[0101] S32: capturing the action image set before and / or after the reference image to obtain each action sub-video of the time length;

[0102] Specifically, according to the time length required for the action, multiple images including the corresponding reference image are screened out from the action image set; the time length corresponding to the multiple images is less than or equal to T; for example, a images are captured before the reference image, the corresponding time length is T1, and b images are captured after the reference image, the corresponding time length is T2, T1+T2≤T.

[0103] S33: splicing the action sub-videos according to the time sequence, and outputting the target video.

[0104] In one embodiment, see Figure 7 , the S1 also includes:

[0105] S01: Obtain the conversion relationship between the initial color space of the baby's initial video and the HSV color space;

[0106] S02: Convert the initial baby video into the baby video in the HSV color space according to the conversion relationship.

[0107] Specifically, the video in the non-HSV color space is converted into the video in the HSV color space, where H is hue, S is saturation, and V is brightness; this can improve the accuracy of the hue, vividness, and brightness parameters of the extracted image and reduce the problem of false color detection.

[0108] The method for capturing baby video highlights based on action classification of this embodiment is adopted to extract target images of each frame containing key points of baby limbs from the baby video, and classify the actions in each frame image to obtain a set of action images; then the discreteness of the key points of the baby limbs in each frame image is calculated to determine the reference image corresponding to each action; based on each reference image, various actions in the baby video are captured to obtain a target video consisting of a corresponding number of image frames for each action; this method can accurately capture videos corresponding to specific baby actions, and then store and view them, which can save device storage space and improve the fun of the video and user experience.

[0109] Example 2

[0110] The present invention also provides a device for capturing baby video highlights based on action classification, see Figure 8 ,include:

[0111] Image data detection module: used to extract target images of each frame containing key points of baby limbs in the baby video, and output action image sets divided into action categories;

[0112] Image data processing module: used to calculate the discreteness of the key points of the baby's limbs in each frame of the target image in the action image set, and output the reference images corresponding to various actions;

[0113] Video data synthesis module: used for editing the videos corresponding to various actions in the baby video based on the reference images, and outputting the target video.

[0114] The device for capturing baby video highlights based on action classification of this embodiment is used to extract target images of each frame containing key points of baby's limbs from baby videos, and classify the actions in each frame to obtain a set of action images; then the discreteness of the key points of baby's limbs in each frame is calculated to determine the reference image corresponding to each action; based on each reference image, various actions in the baby video are captured to obtain a target video consisting of a corresponding number of image frames for each action; this method can accurately capture videos corresponding to specific baby actions, and then store and view them, which can save device storage space and improve the fun of the video and user experience.

[0115] In one embodiment, the frame rate of the video stream is obtained:

[0116] Image length unit: Get the frame rate of the baby video;

[0117] Video splitting unit: splitting the baby video into corresponding frame images according to the frame rate;

[0118] Key point detection unit: performs baby limb key point detection on each frame of the image, and outputs each frame of the target image containing the baby limb key points;

[0119] Image action classification unit: classifies each frame of target image using a preset action classification model and outputs the action image set.

[0120] In one embodiment, the image action classification unit includes:

[0121] Image parameter acquisition unit: acquires the image size of each frame of the target image and the key point coordinates corresponding to each key point of the baby's limbs in the target image;

[0122] A standardization processing unit: according to each image size, standardizes the coordinates of each key point in the target image corresponding to each image size to obtain a standardized coordinate value of each key point of the baby's limbs;

[0123] Action image classification unit: classifies each frame of target image according to the standardized coordinate value of each key point of the baby's limbs in each frame of target image, and outputs the action image set.

[0124] In one embodiment, the action image classification unit includes:

[0125] Coordinate floating value unit: Using the formula Convert each of the key point coordinates P (X, Y) into a corresponding floating point value;

[0126] Target coordinate value unit: Use the formula Convert each of the floating point values ​​into a corresponding standard coordinate value;

[0127] Action classification unit: input the target coordinate value of each key point of the baby's limbs in each frame of the target image into the SVM classifier to classify each frame of the target image, and output the action image set;

[0128] Wherein, W is the width of the target image, L is the length of the target image, X is the horizontal coordinate of the limb key point, Y is the vertical coordinate of the limb key point, X′ is the floating point value corresponding to the horizontal coordinate, Y′ is the floating point value corresponding to the vertical coordinate, X″ is the standard coordinate value corresponding to the horizontal coordinate, Y″ is the standard coordinate value corresponding to the vertical coordinate, and q is the total number of limb key points contained in the corresponding action in each target image.

[0129] In one embodiment, the image data processing module includes:

[0130] Image segmentation unit: segment each frame of the target image to obtain multiple sub-images of the same size;

[0131] Sub-image parameter unit: obtains the center coordinates and weight values ​​of each sub-image;

[0132] Image discrete value unit: obtains discrete values ​​of key points of baby limbs of each frame of target image according to the center coordinates and weight values ​​of each sub-image of each frame of target image;

[0133] Reference image calculation unit: compares the discrete values ​​of the target images of each frame corresponding to each type of action, and outputs the reference images corresponding to each type of action.

[0134] In one embodiment, the video data synthesis module includes:

[0135] Time sequence unit: obtains the time length of each action and the time sequence of each reference image;

[0136] Sub-video grabbing unit: grabbing the action image set before and / or after the reference image to obtain each action sub-video of the time length;

[0137] Video splicing unit: splices the action sub-videos according to the sequence of the moments and outputs the target video.

[0138] In one embodiment, before executing the image data detection module, the method further includes:

[0139] Color space mapping relationship unit: obtains the conversion relationship between the initial color space of the baby's initial video and the HSV color space;

[0140] A video color space conversion unit is configured to convert the initial baby video into the baby video in the HSV color space according to the conversion relationship.

[0141] The baby video collection capture device based on action classification of this embodiment is used to extract each frame target image containing the baby's limb key points from the baby video, and classify the actions in each frame image to obtain a set of action images; then the discreteness of the baby's limb key points in each frame image is calculated to determine the reference image corresponding to each action; based on each reference image, various actions in the baby video are captured to obtain a target video consisting of a corresponding number of image frames for each action; this method can accurately capture the video corresponding to the baby's specific action, and then store and view it, which can save device storage space and improve the fun of the video and user experience.

[0142] Example 3

[0143] The present invention provides an electronic device and a medium, such as Fig. 9 As shown, the system comprises at least one processor, at least one memory and computer program instructions stored in the memory.

[0144] Specifically, the above-mentioned processor may include a central processing unit (CPU), or an application specific integrated circuit (ASIC), or may be configured to implement one or more integrated circuits of an embodiment of the present invention, and the electronic device includes at least one of the following: a camera, a mobile device with a camera, and a wearable device with a camera.

[0145] The memory may include a large capacity memory for data or instructions. By way of example and not limitation, the memory may include a hard disk drive (HDD), a floppy disk drive, a flash memory, an optical disk, a magneto-optical disk, a magnetic tape, or a universal serial bus (USB) drive or a combination of two or more of these. Where appropriate, the memory may include a removable or non-removable (or fixed) medium. Where appropriate, the memory may be inside or outside a data processing device. In a particular embodiment, the memory is a non-volatile solid-state memory. In a particular embodiment, the memory includes a read-only memory (ROM). Where appropriate, the ROM may be a mask-programmed ROM, a programmable ROM (PROM), an erasable PROM (EPROM), an electrically erasable PROM (EEPROM), an electrically rewritable ROM (EAROM) or a flash memory or a combination of two or more of these.

[0146] The processor reads and executes computer program instructions stored in the memory to implement any one of the methods for capturing baby video highlights based on action classification in the first embodiment described above.

[0147] In one example, the electronic device may further include a communication interface and a bus, wherein the processor, the memory, and the communication interface are connected via the bus and communicate with each other.

[0148] The communication interface is mainly used to implement communication between the modules, devices, units and / or equipment in the embodiments of the present invention.

[0149] Bus includes hardware, software or both, and the parts of electronic equipment are coupled to each other.For example, but not limitation, bus may include accelerated graphics port (AGP) or other graphics bus, enhanced industrial standard architecture (EISA) bus, front side bus (FSB), hypertransport (HT) interconnection, industrial standard architecture (ISA) bus, infinite bandwidth interconnection, low pin count (LPC) bus, memory bus, micro channel architecture (MCA) bus, peripheral component interconnection (PCI) bus, PCI-Express (PCI-X) bus, serial advanced technology attachment (SATA) bus, video electronics standard association local (VLB) bus or other suitable bus or two or more of these combinations. In suitable cases, bus may include one or more buses. Although the embodiment of the present invention describes and shows a specific bus, the present invention considers any suitable bus or interconnection.

[0150] In summary, the embodiments of the present invention provide a method, device and equipment for capturing baby video highlights based on action classification, which extracts target images of each frame containing key points of the baby's limbs from the baby video, and classifies the actions in each frame image to obtain a set of action images; then calculates the discreteness of the baby's limb key points in each frame image, so as to determine the reference image corresponding to each action; based on each reference image, various types of actions in the baby video are captured to obtain a target video consisting of a corresponding number of image frames for each type of action; through this method, the video corresponding to the specific action of the baby can be accurately captured, and then stored and viewed, which can save device storage space and improve the fun of the video and user experience.

[0151] It should be clear that the present invention is not limited to the specific configuration and processing described above and shown in the figures. For the sake of simplicity, a detailed description of the known method is omitted here. In the above embodiments, several specific steps are described and shown as examples. However, the method process of the present invention is not limited to the specific steps described and shown, and those skilled in the art can make various changes, modifications and additions, or change the order between the steps after understanding the spirit of the present invention.

[0152] The functional blocks shown in the above-described block diagram can be implemented as hardware, software, firmware or a combination thereof. When implemented in hardware, it can be, for example, an electronic circuit, an application specific integrated circuit (ASIC), appropriate firmware, a plug-in, a function card, etc. When implemented in software, the elements of the present invention are programs or code segments that are used to perform the required tasks. The program or code segment can be stored in a machine-readable medium, or transmitted on a transmission medium or a communication link by a data signal carried in a carrier wave. "Machine-readable medium" can include any medium capable of storing or transmitting information. Examples of machine-readable media include electronic circuits, semiconductor memory devices, ROM, flash memory, erasable ROM (EROM), floppy disks, CD-ROMs, optical disks, hard disks, optical fiber media, radio frequency (RF) links, etc. The code segment can be downloaded via a computer network such as the Internet, an intranet, etc.

[0153] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit it. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or replace some or all of the technical features therein with equivalents. However, these modifications or replacements do not cause the essence of the corresponding technical solutions to deviate from the scope of the technical solutions of the embodiments of the present invention.

Claims

1. A method for capturing baby video highlights based on action classification, characterized in that: The method comprises: Obtaining an initial video of the baby, converting an initial color space of the initial video of the baby into an HSV color space, recording the converted video as the baby video, and extracting target images of each frame containing key points of the baby's limbs in the baby video; Using a preset action classification model to classify the target images of each frame to determine an action image set; According to the position of each key point of the baby's limbs in the target image, the discreteness of the key points of the baby's limbs in each frame of the target image in the action image set is calculated, and the reference image corresponding to each type of action is output; Based on the reference images, the videos corresponding to the various actions in the baby video are edited to output a target video; The step of calculating the discreteness of the key points of the baby's limbs in each frame of the target image in the action image set according to the position of each key point of the baby's limbs in the target image, and outputting the reference images corresponding to each type of action comprises: Segment each frame of the target image to obtain multiple sub-images of the same size; Obtaining the center coordinates of each of the sub-images, and determining a weight value according to the distance between the center position of each sub-image and the center position of the target image; Obtaining discrete values ​​of key points of the baby's limbs in each frame of the target image according to the central coordinates and weight values ​​of each of the sub-images in each frame of the target image; The discrete values ​​of the target images of each frame corresponding to each type of action are compared, and the reference images corresponding to each type of action are output.

2. The method for capturing baby video highlights based on action classification according to claim 1, characterized in that: The step of obtaining the initial baby video, converting the initial color space of the initial baby video into the HSV color space, recording the converted video as the baby video, and extracting each frame target image containing the key points of the baby's limbs in the baby video comprises: Obtain the conversion relationship between the initial color space of the baby's initial video and the HSV color space; Converting the initial baby video into the baby video in the HSV color space according to the conversion relationship; Obtaining a frame rate of the baby video, and decomposing the baby video into corresponding frame images according to the frame rate; The key points of the baby's limbs are detected for each frame of the image, and the target images of each frame containing the key points of the baby's limbs are output.

3. The method for capturing baby video highlights based on action classification according to claim 1, characterized in that: The classifying the target images of each frame by using a preset action classification model to determine the action image set comprises: Obtain the image size of each frame of the target image and the key point coordinates corresponding to each key point of the infant's limbs in the target image; According to each of the image sizes, the coordinates of each of the key points in the target image corresponding to each of the image sizes are standardized to obtain standardized coordinate values ​​of each of the key points of the infant's limbs; According to the standardized coordinate values ​​of the key points of the baby's limbs in each frame of the target image, each frame of the target image is classified and the action image set is output.

4. The method for capturing baby video highlights based on action classification according to claim 3, characterized in that: The step of classifying each frame of target image according to the standardized coordinate values ​​of each key point of each infant's limb in each frame of target image and outputting the action image set comprises: Taking the standardized coordinate values ​​of each key point of the baby's limbs in each frame of the target image as a group, obtaining a target coordinate group of each key point of the baby's limbs corresponding to each frame of the target image; The target coordinate group is input into a preset classifier to perform action classification on the target image, and an action image set is output; wherein the preset classifier includes an SVM classifier, and the SVM classifier identifies whether the target image includes an infant's face based on the input target image. When it is identified that the target image includes an infant's face, the target image is input into a classification subnetwork of the SVM classifier, and the probability of occurrence of each infant action category is determined by the classification subnetwork, and the action image set is output.

5. The method for capturing baby video highlights based on action classification according to claim 1, characterized in that: The step of editing the videos corresponding to the various actions in the baby video based on the reference images and outputting the target video comprises: Acquire the duration of each action and the time sequence of each of the reference images; Capturing the action image set before and / or after the reference image to obtain each action sub-video of the time length; The action sub-videos are spliced ​​according to the sequence of the moments, and the target video is output.

6. A device for capturing baby video highlights based on action classification, characterized in that: The device comprises: An image data extraction module is used to obtain an initial video of the baby, convert the initial color space of the initial video of the baby into an HSV color space, record the converted video as the baby video, and extract each frame target image containing key points of the baby's limbs in the baby video; An image data classification module is used to classify the target images of each frame using a preset action classification model to determine an action image set; A reference image determination module, for calculating the discreteness of the key points of the baby's limbs in each frame of the target image in the action image set according to the positions of the key points of each baby's limbs in the target image, and outputting reference images corresponding to various actions; A video editing module, used for editing the videos corresponding to various actions in the baby video based on the reference images, and outputting a target video; The step of calculating the discreteness of the key points of the baby's limbs in each frame of the target image in the action image set according to the position of each key point of the baby's limbs in the target image, and outputting the reference images corresponding to each type of action comprises: Segment each frame of the target image to obtain multiple sub-images of the same size; Obtaining the center coordinates of each of the sub-images, and determining a weight value according to the distance between the center position of each sub-image and the center position of the target image; Obtaining discrete values ​​of key points of the baby's limbs in each frame of the target image according to the central coordinates and weight values ​​of each of the sub-images in each frame of the target image; The discrete values ​​of the target images of each frame corresponding to each type of action are compared, and the reference images corresponding to each type of action are output.

7. An electronic device, characterized in that: include: At least one processor, at least one memory and computer program instructions stored in the memory, when the computer program instructions are executed by the processor, implement the method according to any one of claims 1 to 5.

8. A storage medium having computer program instructions stored thereon, characterized in that: When the computer program instructions are executed by a processor, the method according to any one of claims 1 to 5 is implemented.

Citation Information

Patent Citations

  • Key frame selection method based on local characteristics and word bag model human body motion identification process

    CN107220597A

  • Video clipping method and device, memory medium and terminal

    CN107566907A

  • Video editing method and apparatus

    CN108900896A

  • Action understanding method and device, computer equipment and storage medium

    CN111507137A

  • Keypoint based keyframe selection

    WO2013056311A1