Image optimization method and system in short video

By setting multiple rectangular areas and using a super-resolution reconstruction algorithm in short video editing, the problem of content jumping and local detail amplification in key frame additions in short video editing is solved, and the production efficiency and user experience of short videos are improved.

CN114630193BActive Publication Date: 2024-08-30HUNAN MASS MEDIA VOCATIONAL TECHN COLLEGE
View PDF 4 Cites 0 Cited by

Patent Information

Application Number
CN202210317130.2
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-03-29
Publication Date
2024-08-30
Estimated Expiration
2042-03-29

AI Technical Summary

Technical Problem

During the short video editing process, users need to specify key frames one by one, causing the content to jump, and zooming in on local details during editing requires re-shooting, which wastes manpower and material resources and reduces the output efficiency and user experience of short videos.

Method used

By determining the target frame in video editing mode, setting multiple rectangular areas, using a super-resolution reconstruction algorithm to calculate the pixel information of new key frames, and adjusting the audio playback speed according to the video duration ratio, the effect of local amplification is achieved.

Benefits of technology

It improves the production efficiency of short videos, ensures the clarity of newly added key frames and the continuity of audio content, provides flexible system settings and user participation, and achieves the same focusing effect.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114630193B
    Figure CN114630193B
Patent Text Reader

Abstract

The present invention relates to the field of image processing technology, and discloses a method and system for optimizing images in short videos to improve the production efficiency of short videos. The method includes: determining a target frame selected by a user in a video editing mode; obtaining the number N of added key frames set by the user at the segmentation point where the target frame is located, and equally dividing N-2 intermediate rectangular areas between the first rectangular area and the second rectangular area set by the user; establishing a one-to-one mapping relationship between the first rectangular area, the intermediate rectangular areas, and the second rectangular area in order from large to small in size and the time sequence from front to back of the added key frames; according to the mapping relationship, the pixel information in the first rectangular area, the intermediate rectangular areas, and the second rectangular area is calculated by a super-resolution reconstruction algorithm to obtain the pixel information of each added key frame that is enlarged to the same image size as the target frame; synchronizing the audio corresponding to the original video with the overall playback speed of the image frame after the key frame is added.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of image processing technology, and in particular to a method and system for optimizing images in short videos. Background Art

[0002] Short videos have become a hot topic in recent years. As a result, many short video platforms have been born. At the same time, in addition to professional video editing software, video editing software is also configured in the gallery function of each smartphone, allowing users to shoot and create short videos anytime and anywhere.

[0003] However, in the existing short video editing process, adding keyframes to the target video requires the user to specify one by one independent and standard single or multiple photos and / or videos that are locally available. This way of adding keyframes often causes jumps between content and has limited significance for short videos. On the other hand, in most application scenarios, since the short video is edited away from the original shooting scene, if the user wants to zoom in on some local details during the editing process, he can only return to the shooting scene and reshoot the video by adjusting the focus, etc., which wastes manpower and material resources and brings many inconveniences, and also reduces the output efficiency and user experience of short videos. Summary of the invention

[0004] The present invention aims to disclose a method and system for optimizing images in short videos, so as to improve the production efficiency of short videos.

[0005] To achieve the above object, the present invention discloses a method for optimizing images in short videos, comprising:

[0006] Determine the target frame selected by the user in the video editing mode;

[0007] Obtain the number N of additional key frames set by the user at the segmentation point where the target frame is located, and obtain the first rectangular area and the second rectangular area set by the user in the image size of the target frame rectangle; wherein N is a positive integer greater than or equal to 2, and the size of the first rectangular area is greater than the size of the second rectangular area;

[0008] Divide N-2 intermediate rectangular areas equally between the first rectangular area and the second rectangular area;

[0009] A one-to-one mapping relationship is established between the first rectangular area, the middle rectangular areas and the second rectangular area in order of size from large to small and the time sequence of the added key frames from front to back;

[0010] According to the mapping relationship, pixel information in the first rectangular area, each middle rectangular area and the second rectangular area is calculated by a super-resolution reconstruction algorithm to obtain pixel information of each key frame added and enlarged to the same size as the target frame;

[0011] Calculate the ratio between the original video duration before adding the key frame and the cumulative video duration after adding the key frame;

[0012] According to the proportional relationship, the audio playback speed corresponding to the original video is proportionally reduced to synchronize with the overall playback speed of the image frame after the key frame is added.

[0013] Preferably, the method of this embodiment further includes: prohibiting secondary segmentation in the N added key frames.

[0014] Furthermore, the method of this embodiment further includes: correcting the first rectangular area set by the user to have a planar geometric similarity with the second rectangular area.

[0015] To achieve the above-mentioned purpose, the present invention also discloses a picture optimization system in a short video, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements the steps corresponding to the above-mentioned method when executing the computer program.

[0016] The present invention has the following beneficial effects:

[0017] 1. The user needs to filter the target frame and set the first rectangular area and the second rectangular area to ensure user participation.

[0018] 2. Users can reasonably set the number of new key frames according to actual needs to ensure the flexibility of the system.

[0019] 3. The clarity of the newly added key frames is ensured through the super-resolution reconstruction algorithm.

[0020] 4. The audio playback rate is dynamically adjusted according to the duration of the newly added key frames, so that the newly added series of image frames are continuous and integrated with the audio content before and after cutting.

[0021] 5. The overall process is scientific, practical and easy to implement. It can achieve equivalent focusing to present the effect of gradual local magnification and improve the production efficiency of short videos.

[0022] The present invention will be further described in detail below with reference to the accompanying drawings. BRIEF DESCRIPTION OF THE DRAWINGS

[0023] The drawings constituting a part of this application are used to provide a further understanding of the present invention. The exemplary embodiments of the present invention and their descriptions are used to explain the present invention and do not constitute an improper limitation of the present invention. In the drawings:

[0024] Figure 1 It is a schematic diagram of the flow of the picture optimization method in the short video disclosed in an embodiment of the present invention. DETAILED DESCRIPTION

[0025] The embodiments of the present invention are described in detail below with reference to the accompanying drawings, but the present invention can be implemented in many different ways as defined and covered by the claims.

[0026] Example 1

[0027] This embodiment discloses a method for optimizing the picture in a short video. Figure 1 As shown, including:

[0028] Step S1: determining a target frame selected by a user in a video editing mode.

[0029] In this step, the user can filter the corresponding target frame by dragging the video track in the editing interface, and the split point usually cannot be set at the start or end point of the original video.

[0030] Step S2: obtaining the number N of additional key frames set by the user at the segmentation point of the target frame, and obtaining the first rectangular area and the second rectangular area set by the user in the rectangular picture size of the target frame.

[0031] In this step, N is a positive integer greater than or equal to 2, and the size of the first rectangular area is less than or equal to the target frame image size and greater than the size of the second rectangular area. Optionally, the pixel size corresponding to the target frame image size can be conventional 640*480, 1024*768, 1600*1200 or 2048*1536, etc.

[0032] Preferably, the present embodiment corrects the first rectangular area set by the user to have a planar geometric similarity with the second rectangular area, so as to simplify the equal division process in the subsequent step S3. Based on the same purpose, the present embodiment can further correct the aspect ratio of the first rectangular area and the second rectangular area to be consistent with the aspect ratio of the target frame image size (such as the common 16:9 or 9:16); thereby, visual deformation between adjacent newly added image frames and between the newly added first and last image frames and the image frames adjacent to and before the original video segmentation point can be effectively avoided. Of course, as a deformation, if the user expects to achieve a special effect through deformation, the corresponding boundary relationship restrictions on the first rectangular area and the second rectangular area can be cancelled.

[0033] Step S3: equally divide N-2 intermediate rectangular areas between the first rectangular area and the second rectangular area.

[0034] In this step, each equally divided rectangular area forms a layer-by-layer covering relationship with the first and second rectangular areas, and there are corresponding intervals between the sides of adjacent rectangular areas. The so-called equal division means that the intervals between the sides of the adjacent rectangular areas (specifically, top to top, bottom to bottom, left to left, right to right) are equal, and the intervals between the four relative sides in the four directions of up, down, left and right are independent of each other. Optionally, in a specific case, if the first rectangular area and the second rectangular area are based on a square with the same center symmetry, then the upper, lower, left and right sides of the two adjacent rectangular areas are equally spaced after the first rectangular area, the middle rectangular areas and the second rectangular area are equally divided; if the upper, lower, left and right sides of the first rectangular area and the second rectangular area are not equally spaced, then the upper, lower, left and right sides of the two adjacent rectangular areas are also not equally spaced after being equally divided.

[0035] Step S4: establish a one-to-one mapping relationship between the first rectangular area, the middle rectangular areas and the second rectangular area in order of size from large to small and the time sequence of the added key frames from front to back.

[0036] Step S5: Calculate the pixel information in the first rectangular area, the middle rectangular areas and the second rectangular area through a super-resolution reconstruction algorithm according to the mapping relationship to obtain pixel information of each key frame added to be enlarged to the same image size as the target frame. Based on this step, in the subsequent process of playing the added key frames, equivalent focusing is achieved to present a local gradual enlargement effect.

[0037] In this step, the super-resolution reconstruction method includes but is not limited to: regularized reconstruction method, non-uniform space sample interpolation method, iterative back projection method (IBP), set theory reconstruction method (convex set projection POCS), statistical reconstruction method (maximum a posteriori probability MAP and maximum likelihood estimation ML), hybrid ML / MAP / POCS method, adaptive filtering / Wiener filtering / Kalman filtering method, deterministic reconstruction method or method based on learning and pattern recognition, etc. In other words, the specific reconstruction method of super-resolution adopted in this embodiment is a prior art and will not be described in detail.

[0038] Step S6, calculating the ratio between the original video duration before adding the key frame and the accumulated video duration after adding the key frame.

[0039] Step S7: according to the proportional relationship, the audio playback speed corresponding to the original video is proportionally reduced to synchronize with the overall playback speed of the image frame after the key frame is added.

[0040] In this step, short videos usually do not exceed 5 or 10 minutes, and some common short videos are often between 1 and 2 minutes long. Since the number of image frames in the original video is usually much greater than the number of key frames added, slowing down the audio will not affect the user's auditory experience when watching.

[0041] In this step, the so-called "proportional speed reduction" means that the ratio between the audio playback speed after speed reduction and the original audio playback speed is equal to the proportional relationship calculated in step S6. For example, if the number of frames of the original short video is 97, and the total number of frames is 100 after adding 3 frames, then the corresponding audio playback speed after speed reduction should be adjusted to 97% of the original normal audio playback speed.

[0042] Preferably, the method of this embodiment further includes: prohibiting secondary segmentation in the N added key frames to avoid damaging the planned local magnification effect and the special effect produced by deformation.

[0043] Example 2

[0044] Corresponding to the above-mentioned embodiment, this embodiment discloses a picture optimization system in a short video, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements the steps corresponding to the above-mentioned method embodiment when executing the computer program.

[0045] In summary, the picture optimization method and system in the short video disclosed in the embodiments of the present invention have at least the following beneficial effects:

[0046] 1. The user needs to filter the target frame and set the first rectangular area and the second rectangular area to ensure user participation.

[0047] 2. Users can reasonably set the number of new key frames according to actual needs to ensure the flexibility of the system.

[0048] 3. The clarity of the newly added key frames is ensured through the super-resolution reconstruction algorithm.

[0049] 4. The audio playback rate is dynamically adjusted according to the duration of the newly added key frames, so that the newly added series of image frames are continuous and integrated with the audio content before and after cutting.

[0050] 5. The overall process is scientific, practical and easy to implement. It can achieve equivalent focusing to present the effect of gradual local magnification and improve the production efficiency of short videos.

[0051] The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. For those skilled in the art, the present invention may have various modifications and variations. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present invention shall be included in the protection scope of the present invention.

Claims

1. A method for optimizing images in short videos, characterized in that: include: Determine the target frame selected by the user in the video editing mode; Obtain the number N of additional key frames set by the user at the segmentation point where the target frame is located, and obtain the first rectangular area and the second rectangular area set by the user in the rectangular picture size of the target frame; wherein N is a positive integer greater than or equal to 2, and the size of the first rectangular area is smaller than the target frame picture size and larger than the size of the second rectangular area; Divide N-2 intermediate rectangular areas equally between the first rectangular area and the second rectangular area; A one-to-one mapping relationship is established between the first rectangular area, the middle rectangular areas and the second rectangular area in order of size from large to small and the time sequence of the added key frames from front to back; According to the mapping relationship, pixel information in the first rectangular area, each middle rectangular area and the second rectangular area is respectively calculated by a super-resolution reconstruction algorithm to obtain pixel information of each key frame added to be enlarged to the same image size as the target frame, so as to gradually transition the enlarged content of the target frame from the first rectangular area to the second rectangular area; Calculate the ratio between the original video duration before adding the key frame and the cumulative video duration after adding the key frame; According to the proportional relationship, the audio playback speed corresponding to the original video is proportionally reduced to synchronize with the overall playback speed of the image frame after the key frame is added.

2. The method according to claim 1, characterized in that The pixel size corresponding to the target frame image size is 640*480, 1024*768, 1600*1200 or 2048*1536.

3. The method according to claim 1, characterized in that: Also includes: Disable secondary splitting in N increasing keyframes.

4. The method according to any one of claims 1 to 3, characterized in that: Also includes: The first rectangular area set by the user is corrected to have planar geometric similarity with the second rectangular area.

5. A system for optimizing images in short videos, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that: When the processor executes the computer program, the steps of the method according to any one of claims 1 to 4 are implemented.

Citation Information

Patent Citations

  • Method for detail real-time replay of digital television

    CN101247489A

  • Video playing speed regulation method and system applied to flash

    CN103747287A

  • Method, device for inserting advertisement into video, and medium

    CN110225389A

  • Reduced representations of video sequences

    US20030189588A1