WO2022214001A1 - Video image stabilization method and apparatus, electronic device, and storage medium - Google Patents

Video image stabilization method and apparatus, electronic device, and storage medium Download PDF

Info

Publication number
WO2022214001A1
WO2022214001A1 PCT/CN2022/085382 CN2022085382W WO2022214001A1 WO 2022214001 A1 WO2022214001 A1 WO 2022214001A1 CN 2022085382 W CN2022085382 W CN 2022085382W WO 2022214001 A1 WO2022214001 A1 WO 2022214001A1
Authority
WO
WIPO (PCT)
Prior art keywords
video
frame
frames
smoothing
image
Prior art date
Application number
PCT/CN2022/085382
Other languages
French (fr)
Chinese (zh)
Inventor
杨松
刘宇龙
Original Assignee
北京字跳网络技术有限公司
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 北京字跳网络技术有限公司 filed Critical 北京字跳网络技术有限公司
Publication of WO2022214001A1 publication Critical patent/WO2022214001A1/en
Priority to US18/472,001 priority Critical patent/US20240013347A1/en

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T5/00Image enhancement or restoration
    • G06T5/70Denoising; Smoothing
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N23/00Cameras or camera modules comprising electronic image sensors; Control thereof
    • H04N23/60Control of cameras or camera modules
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N5/00Details of television systems
    • H04N5/222Studio circuitry; Studio devices; Studio equipment
    • H04N5/262Studio circuits, e.g. for mixing, switching-over, change of character of image, other special effects ; Cameras specially adapted for the electronic generation of special effects
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N5/00Details of television systems
    • H04N5/222Studio circuitry; Studio devices; Studio equipment
    • H04N5/262Studio circuits, e.g. for mixing, switching-over, change of character of image, other special effects ; Cameras specially adapted for the electronic generation of special effects
    • H04N5/2622Signal amplitude transition in the zone between image portions, e.g. soft edges
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/30Subject of image; Context of image processing
    • G06T2207/30241Trajectory

Definitions

  • the present disclosure relates to the technical field of video processing, and in particular, to a video anti-shake processing method, device, electronic device and storage medium.
  • the embodiments of the present disclosure provide a video anti-shake processing method, apparatus, electronic device, and storage medium.
  • an embodiment of the present disclosure provides a video anti-shake processing method, including:
  • the movement trajectory of the shooting position of the video is determined, wherein the movement trajectory is used to indicate the shooting position of different image frames in the video;
  • the shooting positions of the different image frames in the moving trajectory are respectively smoothed to obtain a smooth trajectory; wherein the smoothing radii corresponding to the different image frames in the video are based on the respective smoothing radii of the different image frames in the video Determine the number of feature points used for tracking in different image frames in the video;
  • the video is deformed to obtain an anti-shake processed video.
  • an embodiment of the present disclosure further provides a video anti-shake processing device, including:
  • a movement trajectory determination module configured to determine the movement trajectory of the shooting position of the video by tracking feature points between different image frames in the video, wherein the movement trajectory is used to indicate the shooting of different image frames in the video Location;
  • a smooth trajectory determination module configured to perform smooth processing on the shooting positions of different image frames in the moving trajectory based on the smoothing radii corresponding to different image frames in the video, respectively, to obtain a smooth trajectory; wherein, the different image frames in the video The corresponding smooth radius is determined based on the number of feature points used for tracking in different image frames in the video respectively;
  • a video anti-shake processing module configured to deform the video based on the difference between the smooth track and the moving track to obtain a video that has undergone anti-shake processing.
  • embodiments of the present disclosure further provide an electronic device, including a memory and a processor, wherein a computer program is stored in the memory, and when the computer program is executed by the processor, the electronic device is made to The device implements any of the video anti-shake processing methods provided in the embodiments of the present disclosure.
  • an embodiment of the present disclosure further provides a computer-readable storage medium, where a computer program is stored in the storage medium, and when the computer program is executed by a computing device, the computing device enables the computing device to implement the embodiment of the present disclosure Any of the provided video anti-shake processing methods.
  • an embodiment of the present disclosure further provides a computer program product, including a computer program/instruction, when the computer program/instruction is executed by a processor, the video anti-shake processing according to any one of the embodiments of the present disclosure is implemented. method.
  • the technical solutions provided by the embodiments of the present disclosure have at least the following advantages: in the embodiments of the present disclosure, based on the number of feature points used for tracking on different image frames in the video to be processed, the The smoothing radius corresponding to the image frame, that is, the embodiment of the present disclosure realizes the effect of adaptively adjusting the smoothing radius corresponding to the different image frames in the video to be processed based on the number of feature points on the image frame, and then based on the corresponding smoothing radius of the different image frames in the video.
  • the embodiment of the present disclosure effectively avoids a small number of feature points used for tracking (or called feature points used for feature matching) on the image frame through the dynamic value of the smooth radius.
  • the number is small, i.e. insufficient features
  • the motion estimation of the video shooting device used to shoot the video is inaccurate, that is, the estimation of the movement trend of the video shooting position is inaccurate, which in turn causes the phenomenon of video screen shaking and abnormal deformation, which effectively improves the video quality.
  • FIG. 1 is a flowchart of a video anti-shake processing method provided by an embodiment of the present disclosure
  • FIG. 2 is a flowchart of another video anti-shake processing method provided by an embodiment of the present disclosure
  • FIG. 3 is a schematic structural diagram of a video anti-shake processing apparatus according to an embodiment of the present disclosure
  • FIG. 4 is a schematic structural diagram of an electronic device according to an embodiment of the present disclosure.
  • FIG. 1 is a flowchart of a video anti-shake processing method provided by an embodiment of the present disclosure, which can be applied to a situation of performing anti-shake processing on a video.
  • the method can be performed by a video anti-shake processing apparatus, which can be implemented by software and/or hardware, and can be integrated on any electronic device with computing capability, such as a terminal or a server.
  • the video to be processed may be a video being shot or a video that has been shot, that is, the embodiment of the present disclosure may perform anti-shake processing on the shot video in real time during the video shooting process, or the video may be Anti-shake processing is performed on the video after shooting, which can improve the quality of the video.
  • the video anti-shake processing method may include:
  • S101 Determine the movement track of the shooting position of the video by tracking feature points between different image frames in the video, where the movement track is used to indicate the shooting position of different image frames in the video.
  • any available feature point extraction and tracking technology can be used to track the feature points between different image frames in the video (for example, starting from the first frame of the video, the feature points on each frame of the image are sequentially performed. point extraction and tracking), determine the matching feature points between different image frames (referring to the feature points of the same object in different image frames, the number of matching feature points can be determined according to the situation), and then calculate the video based on the matching feature points.
  • the shooting positions of different image frames or the relative variation of the shooting positions in the video are obtained to obtain the movement track of the shooting position of the video (or the motion track of the shooting device used for shooting the video).
  • the movement track of the video shooting position is determined, that is, the shaking trend of the video shooting position is determined.
  • the movement track is represented by a transformation matrix
  • different transformation matrices in the movement track respectively represent the shooting positions of different image frames in the video; correspondingly, by tracking feature points between different image frames in the video , determining the movement trajectory of the shooting position of the video, including: by tracking the feature points between different image frames in the video, determining the transformation matrix of the shooting position between different image frames in the video, and based on the shooting between different image frames in the video.
  • the transformation matrix of the position determines the movement trajectory of the shooting position of the video.
  • the transformation matrix may include a homography (homography) matrix, an affine transformation (affine transformation) matrix or a similarity transformation (similarity transformation) matrix.
  • Different transformation matrices correspond to different degrees of freedom.
  • a transformation matrix with a higher degree of freedom has a stronger motion fitting ability.
  • the type of transformation matrix can be flexibly selected according to requirements. The specific calculation of the transformation matrix can be implemented with reference to the prior art.
  • one frame of image in the video can be selected as the reference frame (specifically, it can be determined flexibly), and then based on the transformation matrix of the shooting position between different image frames, each frame of image can be determined separately.
  • the transformation matrix relative to the shooting position of the reference frame, and finally the required movement trajectory is obtained based on the transformation matrix of each frame of image relative to the shooting position of the reference frame.
  • the movement trajectory of the shooting position of the video is determined, include:
  • the matching feature points between the two adjacent frames of images are determined, and based on the matched feature points, the transformation matrix of the shooting position between the two adjacent frames of images is calculated;
  • the movement track of the shooting position of the video is determined.
  • the image is processed as follows:
  • the number of feature points used for tracking in different image frames in the video is related to the photographed object on each frame of image. Taking two adjacent frames of images as face images as an example, the complete face area is displayed on the previous frame image, including a large number of feature points, while only half of the face area is displayed on the next frame image, including the The number of feature points is small, and the feature points used for tracking on the subsequent frame image in the two adjacent frames of images may only be part of the feature points corresponding to the facial features in the facial feature points.
  • the corresponding relationship between the number of feature points and the smoothing radius is preset, so that the smoothing radius corresponding to the image frame can be dynamically determined according to the corresponding relationship and the number of feature points used for tracking on the image frame.
  • the value determines the number of image frames involved in smoothing. When the number of feature points used for tracking on the image frame is more (that is, there are more features), the more accurate the motion estimation of the shooting device used for shooting video is based on the image frame.
  • the image frame you can set a larger , so that the shooting position of the image frame is smoothed based on more adjacent image frames, and no larger cumulative error is introduced; when the number of feature points on the image frame is less (that is, less Then, based on the image frame, the accuracy of the motion estimation of the shooting device used for shooting the video is relatively low. Therefore, for the image frame, a smaller smoothing radius can be set, so that the image frame is based on fewer adjacent image frames. The shooting position is smoothed to avoid introducing large cumulative errors, so as to finally optimize the processing effect of video anti-shake.
  • the smoothing radii corresponding to different image frames in the video are respectively determined based on the number interval to which the number of feature points used for tracking of the different image frames in the video belong, and the corresponding relationship between the number interval and the smoothing radius.
  • the smooth radius r_i corresponding to each frame of image f_i in the video can be determined using the following correspondence:
  • each value can be set flexibly, for example, m 1 can be 50, m 2 can be 25, m 3 can be 10; n i represents each frame of image f i is relative to the number of feature points used for tracking in the previous frame image, r 0 represents the initial value of the smooth radius, and its value can also be flexibly determined. It should be noted that, in the above formula, for different feature point quantity intervals, the relationship between the value of the smooth radius ri and the initial value r 0 is just an example, and ri can be flexibly set according to processing requirements in actual processing. The value proportional relationship with r 0 .
  • the smoothing algorithm may be any available algorithm in the prior art that can achieve a smoothing effect, such as a Gaussian smoothing algorithm and the like.
  • the smooth trajectory obtained by smoothing can be expressed as, for example, The smoothing trajectory is used to indicate the shooting positions of different image frames in the smoothed video, such as Indicates the position where the shooting position of the nth frame image in the video has been smoothed.
  • smoothing is performed on the shooting positions of different image frames in the moving track respectively, to obtain a smooth track, including:
  • smoothing is performed on the shooting position of each frame of the image in the moving track to obtain a smooth track.
  • a weighted sum calculation may be performed on the shooting positions of the images of the preset number of frames involved in each smoothing process in the moving track, and the calculation result may be used as the smoothing result of the shooting positions of the current frame image.
  • n represents the number of image frames included in the video; then, according to the corresponding relationship between each sub-value in the adjustment parameter and each frame of image in the video, the corresponding image frame can be deformed based on each sub-value in the adjustment parameter, so as to obtain anti-shake processed video.
  • the deformation processing process it involves the rotation, translation, scaling or cropping of a specific frame image, which can be performed according to actual processing requirements.
  • deforming the video based on the difference between the smooth trajectory and the moving trajectory to obtain an anti-shake processed video includes: based on the difference between the smooth trajectory and the moving trajectory, Determine the adjustment parameters; use the adjustment parameters to deform the video to obtain a video that has undergone anti-shake processing.
  • the smooth radius corresponding to the different image frames in the video is dynamically determined, that is, the embodiment of the present disclosure realizes the The number of feature points, adaptively adjust the effect of the smoothing radius corresponding to different image frames in the video, and then based on the smoothing radius corresponding to different image frames in the video, respectively smooth the shooting positions of different image frames in the moving trajectory of the shooting position of the video. Finally, based on the difference between the smooth track and the moving track, the video is deformed to realize the anti-shake processing of the video, and the processing effect of the video anti-shake is optimized.
  • the embodiment of the present disclosure effectively avoids a small number of feature points used for tracking (or called feature points used for feature matching) on the image frame through the dynamic value of the smooth radius.
  • the number is small, i.e. insufficient features
  • the motion estimation of the video shooting device used to shoot the video is inaccurate, that is, the estimation of the movement trend of the video shooting position is inaccurate, which in turn causes the phenomenon of video screen shaking and abnormal deformation, which effectively improves the video quality.
  • FIG. 2 is a flowchart of another video anti-shake processing method provided by an embodiment of the present disclosure, which is further optimized and expanded based on the foregoing technical solution, and may be combined with the foregoing optional implementation manners.
  • the video anti-shake processing method may include:
  • S201 Determine the movement track of the shooting position of the video by tracking feature points between different image frames in the video, where the movement track is used to indicate the shooting position of different image frames in the video.
  • Exemplary one based on the smooth radius corresponding to each frame of image in the video, the previous frame image of the first preset number of frames before each frame of image can be determined in the video;
  • the embodiments of the present disclosure support anti-shake processing on the video while the video is being captured. After the video is captured, the video anti-shake processing also ends, thereby obtaining a captured video with better quality.
  • Exemplary two based on the smooth radius corresponding to each frame of image in the video, determine the previous frame image of the second preset number of frames before each frame of image in the video, and determine the second preset number of frames after each frame of image. the image in the later frame;
  • Each frame of image, the previous frame image of the second preset number of frames, and the subsequent frame image of the second preset number of frames are determined as the images of the preset number of frames participating in each smoothing process in the video; at this time, the The value of the second preset number of frames may be the value of the smoothing radius.
  • the embodiment of the present disclosure also supports the anti-shake processing of the video after shooting, and takes a certain number of images before and after each frame of image to participate in the smooth processing of the shooting position of each frame of image in the moving trajectory, which also improves the video quality. Effect.
  • the smoothing position of each frame image (that is, the shooting position after smoothing processing) can be expressed in the form of a matrix, the following is called a smoothing matrix.
  • the weight in the weighted sum calculation process may take adaptive values, which is not specifically limited in the embodiment of the present disclosure.
  • the smoothing matrix of each frame of image f i can be expressed as follows: :
  • Exemplary 2 take images of the same number of frames before and after each frame of image according to the smoothing radius corresponding to each frame of image, and participate in the smoothing processing of the shooting position of each frame of image as an example, the smoothing matrix of each frame of image f i It can be expressed as follows:
  • r is the smoothing radius corresponding to each frame of image
  • C t represents the shooting position (or called transformation matrix) of each frame of image participating in the smoothing process in the moving track C
  • w i ⁇ t is the participating smoothing
  • the smooth position corresponding to each frame of image is obtained by weighting and summing the shooting positions of the images with a preset number of frames in the moving trajectory.
  • the smoothing effect of the movement trajectory of the position is obtained by weighting and summing the shooting positions of the images with a preset number of frames in the moving trajectory.
  • the smooth radius corresponding to each frame of image is dynamically determined according to the number of feature points used for tracking in each frame of image in the video to be processed during the video anti-shake processing process, and then a certain number of image frames is dynamically determined, In order to participate in the smooth processing of the movement trajectory of the video shooting position, the processing effect of video anti-shake is optimized.
  • the embodiment of the present disclosure effectively avoids, through the dynamic value of the smooth radius, that when the number of feature points used for tracking on the image frame in the video is small, it is
  • the motion estimation of the shooting device is inaccurate, that is, the estimation of the movement trend of the video shooting position is inaccurate, which further causes the phenomenon of video picture shaking and abnormal deformation, which effectively improves the video quality.
  • FIG. 3 is a schematic structural diagram of a video anti-shake processing apparatus according to an embodiment of the present disclosure, which can be applied to a situation of performing anti-shake processing on a video.
  • the apparatus can be implemented by software and/or hardware, and can be integrated on any electronic device with computing capability, such as a terminal or a server.
  • the video anti-shake processing apparatus 300 may include a movement trajectory determination module 301, a smooth trajectory determination module 302, and a video anti-shake processing module 303, wherein:
  • the movement trajectory determination module 301 is used to determine the movement trajectory of the shooting position of the video by tracking the feature points between different image frames in the video, wherein the movement trajectory is used to indicate the shooting position of different image frames in the video;
  • the smooth trajectory determination module 302 is configured to perform smooth processing on the shooting positions of different image frames in the moving trajectory based on the smoothing radii corresponding to different image frames in the video, respectively, to obtain a smooth trajectory; wherein, the smoothing radii corresponding to different image frames in the video are respectively Determined based on the number of feature points used for tracking in different image frames in the video;
  • the video anti-shake processing module 303 is configured to deform the video based on the difference between the smooth track and the moving track, so as to obtain a video that has undergone anti-shake processing.
  • the corresponding smoothing radii of different image frames in the video are respectively determined based on the number interval to which the number of feature points used for tracking by different image frames in the video belongs, and the corresponding relationship between the number interval and the smoothing radius.
  • the smooth trajectory determination module 302 includes:
  • an image frame number determination unit configured to determine the images of the preset number of frames participating in each smoothing process in the video based on the smoothing radius corresponding to each frame of image in the video;
  • the smoothing processing unit is configured to perform smoothing processing on the shooting position of each frame of images in the moving trajectory based on the shooting positions of the images of the preset number of frames participating in each smoothing processing in the moving trajectory to obtain a smoothed trajectory.
  • the image frame number determination unit includes:
  • the first determining unit is used to determine the previous frame image of the first preset frame number before each frame image in the video based on the smooth radius corresponding to each frame image in the video;
  • a second determining unit configured to determine each frame of image and the previous frame image of the first preset number of frames as the image of the preset number of frames participating in each smoothing process in the video;
  • the third determining unit is configured to determine, based on the smooth radius corresponding to each frame of image in the video, the previous frame image of the second preset number of frames before each frame of image in the video, and to determine the second preset number of frames after each frame of image The following frame image of the frame number;
  • the fourth determining unit is used to determine each frame of image, the previous frame image of the second preset frame number and the subsequent frame image of the second preset frame number as the preset number of frames participating in each smoothing process in the video Image.
  • the smoothing processing unit includes:
  • the smoothing position determination subunit is used to perform the weighted sum calculation of the shooting position based on the shooting position of the image of the preset number of frames participating in each smoothing process in the moving track, so as to obtain the smoothing position of each frame of image;
  • the smoothed trajectory determination subunit is used to obtain a smoothed trajectory based on the smoothed position of each frame of image.
  • the movement track is represented by a transformation matrix, and different transformation matrices in the movement track respectively represent the shooting positions of different image frames in the video;
  • the movement trajectory determination module 301 is specifically used for:
  • the transformation matrix of the shooting position between different image frames in the video is determined, and the movement trajectory of the shooting position of the video is determined based on the transformation matrix of the shooting position between different image frames in the video.
  • the video anti-shake processing module 303 includes:
  • an adjustment parameter determination unit for determining an adjustment parameter based on the difference between the smooth trajectory and the moving trajectory
  • the video deformation unit is used to deform the video by using the adjustment parameters to obtain the video that has undergone anti-shake processing.
  • the video anti-shake processing apparatus provided by the embodiment of the present disclosure can execute any video anti-shake processing method provided by the embodiment of the present disclosure, and has functional modules and beneficial effects corresponding to the execution method.
  • any video anti-shake processing method provided by the embodiment of the present disclosure, and has functional modules and beneficial effects corresponding to the execution method.
  • Fig. 4 is a schematic structural diagram of an electronic device according to an embodiment of the present disclosure, and is used to exemplarily describe an electronic device that implements the video anti-shake processing method provided by the embodiment of the present disclosure.
  • the electronic devices in the embodiments of the present disclosure may include, but are not limited to, such as mobile phones, notebook computers, digital broadcast receivers, PDAs (personal digital assistants), PADs (tablets), PMPs (portable multimedia players), vehicle-mounted terminals (eg, Mobile terminals such as car navigation terminals), etc., and stationary terminals such as digital TVs, desktop computers, smart home devices, wearable electronic devices, servers, and the like.
  • the electronic device shown in FIG. 4 is only an example, and should not impose any limitation on the functions and occupancy scope of the embodiments of the present disclosure.
  • electronic device 400 includes one or more processors 401 and memory 402 .
  • Processor 401 may be a central processing unit (CPU) or other form of processing unit having data processing capabilities and/or instruction execution capabilities, and may control other components in electronic device 400 to perform desired functions.
  • CPU central processing unit
  • Processor 401 may be a central processing unit (CPU) or other form of processing unit having data processing capabilities and/or instruction execution capabilities, and may control other components in electronic device 400 to perform desired functions.
  • Memory 402 may include one or more computer program products, which may include various forms of computer-readable storage media, such as volatile memory and/or non-volatile memory.
  • Volatile memory may include, for example, random access memory (RAM) and/or cache memory, among others.
  • Non-volatile memory may include, for example, read only memory (ROM), hard disk, flash memory, and the like.
  • One or more computer program instructions may be stored on the computer-readable storage medium, and the processor 401 may execute the program instructions to implement the video anti-shake processing method provided by the embodiments of the present disclosure, and may also implement other desired functions.
  • Various contents such as input signals, signal components, noise components, etc. may also be stored in the computer-readable storage medium.
  • the video anti-shake processing method provided by the embodiment of the present disclosure may include: by tracking feature points between different image frames in the video, determining a movement trajectory of the shooting position of the video, wherein the movement trajectory is used to indicate different images in the video.
  • the shooting position of the frame based on the smoothing radii corresponding to different image frames in the video, the shooting positions of different image frames in the moving track are smoothed respectively to obtain a smooth track; wherein, the smoothing radii corresponding to different image frames in the video are based on the The number of feature points used for tracking in different image frames is determined; based on the difference between the smooth trajectory and the moving trajectory, the video is deformed to obtain an anti-shake processed video.
  • the electronic device 400 may also perform other optional implementations provided by the method embodiments of the present disclosure.
  • the electronic device 400 may also include an input device 403 and an output device 404 interconnected by a bus system and/or other form of connection mechanism (not shown).
  • the input device 403 may also include, for example, a keyboard, a mouse, and the like.
  • the output device 404 can output various information to the outside, including the determined distance information, direction information, and the like.
  • the output devices 404 may include, for example, displays, speakers, printers, and communication networks and their connected remote output devices, among others.
  • the electronic device 400 may also include any other appropriate components according to the specific application.
  • the embodiments of the present disclosure may also be computer program products, which include computer programs or computer program instructions, which, when executed by a processor, cause a computing device to implement what is provided by the embodiments of the present disclosure. Any video anti-shake processing method.
  • the computer program product includes one or more computer instructions.
  • the computer may be a general purpose computer, a special purpose computer, a computer network, or other programmable device.
  • the computer program product may write program code for performing operations of embodiments of the present disclosure in any combination of one or more programming languages, including object-oriented programming languages, such as Java, C++, etc., as well as conventional procedural programming language, such as "C" language or similar programming language.
  • the program code may execute entirely on the user electronic device, partly on the user electronic device, as a stand-alone software package, partly on the user electronic device and partly on the remote electronic device, or entirely on the remote electronic device execute on.
  • embodiments of the present disclosure may further provide a computer-readable storage medium on which computer program instructions are stored, and when the computer program instructions are executed by the processor, the computer program instructions enable the computing device to implement any video anti-shake processing provided by the embodiments of the present disclosure method.
  • the video anti-shake processing method provided by the embodiment of the present disclosure may include: by tracking feature points between different image frames in the video, determining a movement trajectory of the shooting position of the video, wherein the movement trajectory is used to indicate different images in the video.
  • the shooting position of the frame based on the smoothing radii corresponding to different image frames in the video, the shooting positions of different image frames in the moving track are smoothed respectively to obtain a smooth track; wherein, the smoothing radii corresponding to different image frames in the video are based on the The number of feature points used for tracking in different image frames is determined; based on the difference between the smooth trajectory and the moving trajectory, the video is deformed to obtain an anti-shake processed video.
  • the computer program instructions can also cause the computing device to implement other optional implementations provided by the method embodiments of the present disclosure.
  • a computer-readable storage medium can employ any combination of one or more readable media.
  • the readable medium may be a readable signal medium or a readable storage medium.
  • the readable storage medium may include, for example, but not limited to, electrical, magnetic, optical, electromagnetic, infrared, or semiconductor systems, apparatuses or devices, or any combination of the above. More specific examples (non-exhaustive list) of readable storage media include: electrical connections with one or more wires, portable disks, hard disks, random access memory (RAM), read only memory (ROM), erasable programmable read only memory (EPROM or flash memory), optical fiber, portable compact disk read only memory (CD-ROM), optical storage devices, magnetic storage devices, or any suitable combination of the foregoing.

Landscapes

  • Engineering & Computer Science (AREA)
  • Multimedia (AREA)
  • Signal Processing (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • Studio Devices (AREA)

Abstract

Embodiments of the present disclosure relate to a video image stabilization method and apparatus, an electronic device, and a storage medium. The method comprises: determining a movement trajectory of shooting positions of a video by means of performing feature point tracking between different image frames in the video; respectively performing smoothing on shooting positions of different image frames in the movement trajectory on the basis of smoothing radii corresponding to the different image frames in the video, and obtaining a smoothed trajectory, wherein the smoothing radii corresponding to the different image frames in the video are respectively determined on the basis of the number of feature points used for tracking of different image frames in the video; and performing shape transformation on the video on the basis of a difference between the smoothed trajectory and the movement trajectory, so as to obtain a video that has undergone image stabilization. An embodiment of the present disclosure achieves an effect of adaptively adjusting smoothing radii corresponding to image frames during video image stabilization according to the number of feature points on image frames in a video to be processed, a video image stabilization effect is optimized, and video quality is effectively improved.

Description

视频防抖处理方法、装置、电子设备和存储介质Video anti-shake processing method, device, electronic device and storage medium
相关申请的交叉引用CROSS-REFERENCE TO RELATED APPLICATIONS
本申请要求于2021年04月08日提交的,申请号为202110379627.2、发明名称为“视频防抖处理方法、装置、电子设备和存储介质”的中国专利申请的优先权,该申请的全部内容通过引用结合在本申请中。This application claims the priority of the Chinese patent application filed on April 8, 2021 with the application number of 202110379627.2 and the invention titled "video anti-shake processing method, device, electronic device and storage medium". The entire content of the application is approved by Reference is incorporated in this application.
技术领域technical field
本公开涉及视频处理技术领域,尤其涉及一种视频防抖处理方法、装置、电子设备和存储介质。The present disclosure relates to the technical field of video processing, and in particular, to a video anti-shake processing method, device, electronic device and storage medium.
背景技术Background technique
随着短视频的兴起,视频拍摄变得越来越重要。目前,用户一般都是使用手持设备进行视频拍摄,这很容易造成视频的抖动,导致视频质量欠佳。因此,如何对视频进行防抖处理,提高视频质量仍是当前待解决的问题。With the rise of short videos, video shooting has become more and more important. At present, users generally use handheld devices to shoot video, which can easily cause video jitter, resulting in poor video quality. Therefore, how to perform anti-shake processing on the video and improve the video quality is still a problem to be solved at present.
发明内容SUMMARY OF THE INVENTION
为了解决上述技术问题或者至少部分地解决上述技术问题,本公开实施例提供了一种视频防抖处理方法、装置、电子设备和存储介质。In order to solve the above technical problem or at least partially solve the above technical problem, the embodiments of the present disclosure provide a video anti-shake processing method, apparatus, electronic device, and storage medium.
第一方面,本公开实施例提供了一种视频防抖处理方法,包括:In a first aspect, an embodiment of the present disclosure provides a video anti-shake processing method, including:
通过对视频中不同图像帧之间进行特征点追踪,确定所述视频的拍摄位置的移动轨迹,其中,所述移动轨迹用于指示所述视频中不同图像帧的拍摄位置;By tracking feature points between different image frames in the video, the movement trajectory of the shooting position of the video is determined, wherein the movement trajectory is used to indicate the shooting position of different image frames in the video;
基于所述视频中不同图像帧对应的平滑半径,分别对所述移动轨迹中不同图像帧的拍摄位置进行平滑处理,得到平滑轨迹;其中,所述视频中不同图像帧对应的平滑半径分别基于所述视频中不同图像帧用于追踪的特征点的数量确定;Based on the smoothing radii corresponding to different image frames in the video, the shooting positions of the different image frames in the moving trajectory are respectively smoothed to obtain a smooth trajectory; wherein the smoothing radii corresponding to the different image frames in the video are based on the respective smoothing radii of the different image frames in the video Determine the number of feature points used for tracking in different image frames in the video;
基于所述平滑轨迹和所述移动轨迹之间的差异,对所述视频进行形变,以得到经过防抖处理的视频。Based on the difference between the smooth trajectory and the moving trajectory, the video is deformed to obtain an anti-shake processed video.
第二方面,本公开实施例还提供了一种视频防抖处理装置,包括:In a second aspect, an embodiment of the present disclosure further provides a video anti-shake processing device, including:
移动轨迹确定模块,用于通过对视频中不同图像帧之间进行特征点追踪,确定所述视频的拍摄位置的移动轨迹,其中,所述移动轨迹用于指示所述视频中不同图像帧的拍摄位置;A movement trajectory determination module, configured to determine the movement trajectory of the shooting position of the video by tracking feature points between different image frames in the video, wherein the movement trajectory is used to indicate the shooting of different image frames in the video Location;
平滑轨迹确定模块,用于基于所述视频中不同图像帧对应的平滑半径,分别对所述移 动轨迹中不同图像帧的拍摄位置进行平滑处理,得到平滑轨迹;其中,所述视频中不同图像帧对应的平滑半径分别基于所述视频中不同图像帧用于追踪的特征点的数量确定;A smooth trajectory determination module, configured to perform smooth processing on the shooting positions of different image frames in the moving trajectory based on the smoothing radii corresponding to different image frames in the video, respectively, to obtain a smooth trajectory; wherein, the different image frames in the video The corresponding smooth radius is determined based on the number of feature points used for tracking in different image frames in the video respectively;
视频防抖处理模块,用于基于所述平滑轨迹和所述移动轨迹之间的差异,对所述视频进行形变,以得到经过防抖处理的视频。A video anti-shake processing module, configured to deform the video based on the difference between the smooth track and the moving track to obtain a video that has undergone anti-shake processing.
第三方面,本公开实施例还提供了一种电子设备,包括存储器和处理器,其中,所述存储器中存储有计算机程序,当所述计算机程序被所述处理器执行时,使得所述电子设备实现本公开实施例提供的任一所述的视频防抖处理方法。In a third aspect, embodiments of the present disclosure further provide an electronic device, including a memory and a processor, wherein a computer program is stored in the memory, and when the computer program is executed by the processor, the electronic device is made to The device implements any of the video anti-shake processing methods provided in the embodiments of the present disclosure.
第四方面,本公开实施例还提供了一种计算机可读存储介质,所述存储介质中存储有计算机程序,当所述计算机程序被计算设备执行时,使得所述计算设备实现本公开实施例提供的任一所述的视频防抖处理方法。In a fourth aspect, an embodiment of the present disclosure further provides a computer-readable storage medium, where a computer program is stored in the storage medium, and when the computer program is executed by a computing device, the computing device enables the computing device to implement the embodiment of the present disclosure Any of the provided video anti-shake processing methods.
第五方面,本公开实施例还提供了一种计算机程序产品,包括计算机程序/指令,该计算机程序/指令被处理器执行时实现如本公开实施例提供的任一所述的视频防抖处理方法。In a fifth aspect, an embodiment of the present disclosure further provides a computer program product, including a computer program/instruction, when the computer program/instruction is executed by a processor, the video anti-shake processing according to any one of the embodiments of the present disclosure is implemented. method.
本公开实施例提供的技术方案与现有技术相比至少具有如下优点:在本公开实施例中,基于待处理视频中不同图像帧上用于追踪的特征点的数量,动态确定该视频中不同图像帧对应的平滑半径,即本公开实施例实现了基于图像帧上的特征点数量,自适应调整待处理视频中不同图像帧对应的平滑半径的效果,然后基于该视频中不同图像帧对应的平滑半径,分别对视频的拍摄位置的移动轨迹中不同图像帧的拍摄位置进行平滑处理,最后基于平滑轨迹和移动轨迹之间差异,对待处理视频进行形变,实现视频的防抖处理,优化了视频防抖的处理效果。相比于平滑半径的统一取值的情况,本公开实施例通过平滑半径的动态取值,有效避免了图像帧上用于追踪的特征点数量较少(或称为用于特征匹配的特征点数量较少,即特征不足)时,针对用于拍摄视频的拍摄装置的运动估计不准确,即视频拍摄位置的移动趋势估计不准确,进而引起视频画面晃动和异常形变的现象,有效改善了视频质量。Compared with the prior art, the technical solutions provided by the embodiments of the present disclosure have at least the following advantages: in the embodiments of the present disclosure, based on the number of feature points used for tracking on different image frames in the video to be processed, the The smoothing radius corresponding to the image frame, that is, the embodiment of the present disclosure realizes the effect of adaptively adjusting the smoothing radius corresponding to the different image frames in the video to be processed based on the number of feature points on the image frame, and then based on the corresponding smoothing radius of the different image frames in the video. Smooth radius, respectively smooth the shooting positions of different image frames in the moving track of the video shooting position, and finally deform the video to be processed based on the difference between the smooth track and the moving track, realize the anti-shake processing of the video, and optimize the video Anti-shake processing effect. Compared with the uniform value of the smooth radius, the embodiment of the present disclosure effectively avoids a small number of feature points used for tracking (or called feature points used for feature matching) on the image frame through the dynamic value of the smooth radius. When the number is small, i.e. insufficient features), the motion estimation of the video shooting device used to shoot the video is inaccurate, that is, the estimation of the movement trend of the video shooting position is inaccurate, which in turn causes the phenomenon of video screen shaking and abnormal deformation, which effectively improves the video quality.
附图说明Description of drawings
此处的附图被并入说明书中并构成本说明书的一部分,示出了符合本公开的实施例,并与说明书一起用于解释本公开的原理。The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the disclosure and together with the description serve to explain the principles of the disclosure.
为了更清楚地说明本公开实施例或现有技术中的技术方案,下面将对实施例或现有技术描述中所需要使用的附图作简单地介绍,显而易见地,对于本领域普通技术人员而言,在不付出创造性劳动性的前提下,还可以根据这些附图获得其他的附图。In order to more clearly illustrate the embodiments of the present disclosure or the technical solutions in the prior art, the accompanying drawings that are required to be used in the description of the embodiments or the prior art will be briefly introduced below. In other words, on the premise of no creative labor, other drawings can also be obtained from these drawings.
图1为本公开实施例提供的一种视频防抖处理方法的流程图;1 is a flowchart of a video anti-shake processing method provided by an embodiment of the present disclosure;
图2为本公开实施例提供的另一种视频防抖处理方法的流程图;2 is a flowchart of another video anti-shake processing method provided by an embodiment of the present disclosure;
图3为本公开实施例提供的一种视频防抖处理装置的结构示意图;3 is a schematic structural diagram of a video anti-shake processing apparatus according to an embodiment of the present disclosure;
图4为本公开实施例提供的一种电子设备的结构示意图。FIG. 4 is a schematic structural diagram of an electronic device according to an embodiment of the present disclosure.
具体实施方式Detailed ways
为了能够更清楚地理解本公开的上述目的、特征和优点,下面将对本公开的方案进行进一步描述。需要说明的是,在不冲突的情况下,本公开的实施例及实施例中的特征可以相互组合。In order to more clearly understand the above objects, features and advantages of the present disclosure, the solutions of the present disclosure will be further described below. It should be noted that the embodiments of the present disclosure and the features in the embodiments may be combined with each other under the condition of no conflict.
在下面的描述中阐述了很多具体细节以便于充分理解本公开,但本公开还可以采用其他不同于在此描述的方式来实施;显然,说明书中的实施例只是本公开的一部分实施例,而不是全部的实施例。Many specific details are set forth in the following description to facilitate a full understanding of the present disclosure, but the present disclosure can also be implemented in other ways different from those described herein; obviously, the embodiments in the specification are only a part of the embodiments of the present disclosure, and Not all examples.
图1为本公开实施例提供的一种视频防抖处理方法的流程图,可以适用于对视频进行防抖处理的情况。该方法可以由视频防抖处理装置执行,该装置可以采用软件和/或硬件实现,并可集成在任意具有计算能力的电子设备上,例如终端或者服务器等。FIG. 1 is a flowchart of a video anti-shake processing method provided by an embodiment of the present disclosure, which can be applied to a situation of performing anti-shake processing on a video. The method can be performed by a video anti-shake processing apparatus, which can be implemented by software and/or hardware, and can be integrated on any electronic device with computing capability, such as a terminal or a server.
在本公开实施例中,待处理视频可以是拍摄中的视频,也可以是拍摄完成的视频,即本公开实施例可以在视频拍摄过程中实时对拍摄的视频进行防抖处理,也可以在视频拍摄完成后对视频进行防抖处理,均可达到改善视频质量的效果。In the embodiment of the present disclosure, the video to be processed may be a video being shot or a video that has been shot, that is, the embodiment of the present disclosure may perform anti-shake processing on the shot video in real time during the video shooting process, or the video may be Anti-shake processing is performed on the video after shooting, which can improve the quality of the video.
如图1所示,本公开实施例提供的视频防抖处理方法可以包括:As shown in FIG. 1 , the video anti-shake processing method provided by the embodiment of the present disclosure may include:
S101、通过对视频中不同图像帧之间进行特征点追踪,确定视频的拍摄位置的移动轨迹,其中,移动轨迹用于指示视频中不同图像帧的拍摄位置。S101. Determine the movement track of the shooting position of the video by tracking feature points between different image frames in the video, where the movement track is used to indicate the shooting position of different image frames in the video.
在获取待处理视频后,可以利用任意可用的特征点提取与追踪技术,对视频中不同图像帧之间进行特征点追踪(例如从视频中第一帧图像开始,依次进行每帧图像上的特征点提取与追踪),确定不同图像帧之间的匹配特征点(指不同图像帧中针对同一拍摄对象的特征点,匹配特征点的数量可以视情况而定),然后基于匹配特征点,计算视频中不同图像帧的拍摄位置或者拍摄位置的相对变化量,得到视频的拍摄位置的移动轨迹(或称为用于拍摄视频的拍摄装置的运动轨迹)。确定视频拍摄位置的移动轨迹,也即确定了视频拍摄位置的抖动趋势。After acquiring the video to be processed, any available feature point extraction and tracking technology can be used to track the feature points between different image frames in the video (for example, starting from the first frame of the video, the feature points on each frame of the image are sequentially performed. point extraction and tracking), determine the matching feature points between different image frames (referring to the feature points of the same object in different image frames, the number of matching feature points can be determined according to the situation), and then calculate the video based on the matching feature points. The shooting positions of different image frames or the relative variation of the shooting positions in the video are obtained to obtain the movement track of the shooting position of the video (or the motion track of the shooting device used for shooting the video). The movement track of the video shooting position is determined, that is, the shaking trend of the video shooting position is determined.
在一种可选实施方式中,移动轨迹采用变换矩阵表示,移动轨迹中的不同变换矩阵分别表示视频中不同图像帧的拍摄位置;相应地,通过对视频中不同图像帧之间进行特征点追踪,确定视频的拍摄位置的移动轨迹,包括:通过对视频中不同图像帧之间进行特征点追踪,确定视频中不同图像帧之间拍摄位置的变换矩阵,并基于视频中不同图像帧之间拍摄位置的变换矩阵确定视频的拍摄位置的移动轨迹。In an optional implementation manner, the movement track is represented by a transformation matrix, and different transformation matrices in the movement track respectively represent the shooting positions of different image frames in the video; correspondingly, by tracking feature points between different image frames in the video , determining the movement trajectory of the shooting position of the video, including: by tracking the feature points between different image frames in the video, determining the transformation matrix of the shooting position between different image frames in the video, and based on the shooting between different image frames in the video. The transformation matrix of the position determines the movement trajectory of the shooting position of the video.
其中,变换矩阵可以包括单应变换(homography)矩阵、仿射变换(affine transformation) 矩阵或者相似变换(similarity transformation)矩阵。不同的变换矩阵对应的自由度不同,自由度越高的变换矩阵对应的运动拟合能力越强,在实际处理过程中可以根据需求灵活选择变换矩阵的类型。关于变换矩阵的具体计算可以参考现有技术实现。The transformation matrix may include a homography (homography) matrix, an affine transformation (affine transformation) matrix or a similarity transformation (similarity transformation) matrix. Different transformation matrices correspond to different degrees of freedom. A transformation matrix with a higher degree of freedom has a stronger motion fitting ability. In the actual processing process, the type of transformation matrix can be flexibly selected according to requirements. The specific calculation of the transformation matrix can be implemented with reference to the prior art.
在基于多个变换矩阵,确定移动轨迹的过程中,可以在视频中选择一帧图像作为参考帧(具体可以灵活确定),然后基于不同图像帧之间拍摄位置的变换矩阵,分别确定每帧图像相对参考帧的拍摄位置的变换矩阵,最后基于每帧图像相对参考帧的拍摄位置的变换矩阵,得到所需的移动轨迹。In the process of determining the movement trajectory based on multiple transformation matrices, one frame of image in the video can be selected as the reference frame (specifically, it can be determined flexibly), and then based on the transformation matrix of the shooting position between different image frames, each frame of image can be determined separately. The transformation matrix relative to the shooting position of the reference frame, and finally the required movement trajectory is obtained based on the transformation matrix of each frame of image relative to the shooting position of the reference frame.
以参考帧为视频中的第一帧图像,视频中不同图像帧指相邻的两帧图像为例,通过对视频中不同图像帧之间进行特征点追踪,确定视频的拍摄位置的移动轨迹,包括:Taking the reference frame as the first frame image in the video, and different image frames in the video refer to two adjacent frames of images as an example, by tracking the feature points between different image frames in the video, the movement trajectory of the shooting position of the video is determined, include:
通过对视频中相邻两帧图像进行特征点追踪,确定相邻两帧图像之间匹配的特征点,基于匹配的特征点,计算相邻两帧图像之间拍摄位置的变换矩阵;By tracking the feature points of two adjacent frames of images in the video, the matching feature points between the two adjacent frames of images are determined, and based on the matched feature points, the transformation matrix of the shooting position between the two adjacent frames of images is calculated;
基于相邻两帧图像之间拍摄位置的变换矩阵,确定视频中每帧图像相对视频中第一帧图像的拍摄位置的变换矩阵;Based on the transformation matrix of the shooting position between two adjacent frames of images, determine the transformation matrix of the shooting position of each frame of image in the video relative to the shooting position of the first frame of image in the video;
基于视频中每帧图像相对视频中第一帧图像的拍摄位置的变换矩阵,确定视频的拍摄位置的移动轨迹。Based on the transformation matrix of each frame of image in the video relative to the shooting position of the first frame of image in the video, the movement track of the shooting position of the video is determined.
例如,假设视频V共包含n帧图像,记第i帧图像为f i,则视频V={f 1,f 2,…,f n-1,f n,},依次对视频的每一帧图像进行以下处理: For example, assuming that the video V contains n frames of images in total, and denote the i-th frame image as f i , then the video V={f 1 ,f 2 ,...,f n-1 ,f n, }, and sequentially for each frame of the video The image is processed as follows:
1)对于第i帧图像f i,进行特征点提取,记为p i1) For the i-th frame image f i , extract feature points, denoted as p i .
2)在第i+1帧图像f i+1上对上一帧图像的特征点p i进行跟踪,跟踪到的特征点记为p i~i+1,即p i和p i~i+1分别为第i帧图像f i和第i+1帧图像f i+1上匹配成功的特征点; 2) Track the feature point p i of the previous frame image on the i+1th frame image f i+1 , and the tracked feature points are recorded as p i~i+1 , namely p i and p i~i+ 1 are the successfully matched feature points on the i-th frame image f i and the i+1-th frame image f i+1 ;
3)根据p i和p i~i+1的对应关系,拟合出第i帧图像f i到第i+1帧图像f i+1的拍摄位置的变换矩阵,记为T i3) According to the corresponding relationship of p i and p i~i+1 , fit the transformation matrix of the shooting position of the i-th frame image f i to the i+1-th frame image f i+1 , and denote it as T i ;
4)将第i帧图像f i以及第i帧图像之前的各相邻两帧图像之间的变换矩阵进行累积处理,例如进行累乘计算(具体可以根据实际处理而定),得到第i帧图像f i相对第一帧图像的拍摄位置的变换矩阵,表示如下: 4) Accumulate the transformation matrix between the ith frame image f i and the adjacent two frame images before the ith frame image, for example, perform cumulative multiplication calculation (specifically, it can be determined according to the actual processing), and obtain the ith frame. The transformation matrix of the image f i relative to the shooting position of the first frame image is expressed as follows:
Figure PCTCN2022085382-appb-000001
Figure PCTCN2022085382-appb-000001
依次得到视频中每帧图像相对第一帧图像的拍摄位置的变换矩阵,则视频的拍摄位置的移动轨迹可以表示为C={C 1,C 2,…,C n-1,C n},n表示视频中包括的图像帧数。 The transformation matrix of the shooting position of each frame of image in the video relative to the first frame of image is obtained in turn, then the movement trajectory of the shooting position of the video can be expressed as C={C 1 ,C 2 ,...,C n-1 ,C n }, n represents the number of image frames included in the video.
S102、基于视频中不同图像帧对应的平滑半径,分别对移动轨迹中不同图像帧的拍摄位置进行平滑处理,得到平滑轨迹;其中,视频中不同图像帧对应的平滑半径分别基于视 频中不同图像帧用于追踪的特征点的数量确定。S102. Based on the smoothing radii corresponding to different image frames in the video, perform smoothing processing on the shooting positions of different image frames in the moving trajectory respectively, to obtain a smooth trajectory; wherein, the smoothing radii corresponding to different image frames in the video are based on the different image frames in the video respectively. The number of feature points used for tracking is determined.
视频中不同图像帧用于追踪的特征点(或称为在后帧图像上与在前帧图像上匹配成功的特征点)的数量与每帧图像上的拍摄对象有关。以相邻两帧图像为人脸图像为例,在前帧图像上显示了完整的人脸区域,包括的特征点数量较多,而在后帧图像上只显示了一半的人脸区域,包括的特征点数量较少,进而相邻两帧图像中在后帧图像上用于追踪的特征点可以只是脸部特征点中对应五官区域的部分特征点。The number of feature points used for tracking in different image frames in the video (or called feature points that are successfully matched on the image of the subsequent frame and the image of the previous frame) is related to the photographed object on each frame of image. Taking two adjacent frames of images as face images as an example, the complete face area is displayed on the previous frame image, including a large number of feature points, while only half of the face area is displayed on the next frame image, including the The number of feature points is small, and the feature points used for tracking on the subsequent frame image in the two adjacent frames of images may only be part of the feature points corresponding to the facial features in the facial feature points.
本公开实施例中,预先设置特征点数量与平滑半径之间的对应关系,以使得可以根据该对应关系和图像帧上用于追踪的特征点数量动态确定图像帧对应的平滑半径,平滑半径的取值决定了参与平滑处理的图像帧数。当图像帧上用于追踪的特征点数量越多(即特征较多),则基于该图像帧对用于拍摄视频的拍摄装置的运动估计越准确,因此,针对该图像帧,可以设置较大的平滑半径,使得基于较多的邻近图像帧对该图像帧的拍摄位置进行平滑处理,并且不会引入较大的累计误差;当图像帧上的特征点数量越少(即特征较少),则基于该图像帧对用于拍摄视频的拍摄装置的运动估计的准确性相对较低,因此,针对该图像帧,可以设置较小的平滑半径,使得基于较少的邻近图像帧对该图像帧的拍摄位置进行平滑处理,避免引入较大的累计误差,从而最终优化视频防抖的处理效果。In the embodiment of the present disclosure, the corresponding relationship between the number of feature points and the smoothing radius is preset, so that the smoothing radius corresponding to the image frame can be dynamically determined according to the corresponding relationship and the number of feature points used for tracking on the image frame. The value determines the number of image frames involved in smoothing. When the number of feature points used for tracking on the image frame is more (that is, there are more features), the more accurate the motion estimation of the shooting device used for shooting video is based on the image frame. Therefore, for the image frame, you can set a larger , so that the shooting position of the image frame is smoothed based on more adjacent image frames, and no larger cumulative error is introduced; when the number of feature points on the image frame is less (that is, less Then, based on the image frame, the accuracy of the motion estimation of the shooting device used for shooting the video is relatively low. Therefore, for the image frame, a smaller smoothing radius can be set, so that the image frame is based on fewer adjacent image frames. The shooting position is smoothed to avoid introducing large cumulative errors, so as to finally optimize the processing effect of video anti-shake.
可选地,视频中不同图像帧对应的平滑半径分别基于视频中不同图像帧用于追踪的特征点的数量所属的数量区间、以及数量区间与平滑半径的对应关系确定。示例性地,视频中每帧图像f_i对应的平滑半径r_i可以利用以下对应关系确定:Optionally, the smoothing radii corresponding to different image frames in the video are respectively determined based on the number interval to which the number of feature points used for tracking of the different image frames in the video belong, and the corresponding relationship between the number interval and the smoothing radius. Exemplarily, the smooth radius r_i corresponding to each frame of image f_i in the video can be determined using the following correspondence:
Figure PCTCN2022085382-appb-000002
Figure PCTCN2022085382-appb-000002
其中,m 1>m 2>m 3,各个取值可以灵活设置,例如m 1可以取值为50,m 2可以取值为25,m 3可以取值为10;n i表示每帧图像f i相对在前帧图像用于追踪的特征点数量,r 0表示平滑半径的初始值,其取值也可以灵活确定。需要说明的是,上述公式中,针对不同的特征点数量区间,平滑半径r i的取值与初始值r 0的关系,只是作为一种示例,在实际处理中可以根据处理需求灵活设置r i与r 0之间的取值比例关系。 Among them, m 1 >m 2 >m 3 , each value can be set flexibly, for example, m 1 can be 50, m 2 can be 25, m 3 can be 10; n i represents each frame of image f i is relative to the number of feature points used for tracking in the previous frame image, r 0 represents the initial value of the smooth radius, and its value can also be flexibly determined. It should be noted that, in the above formula, for different feature point quantity intervals, the relationship between the value of the smooth radius ri and the initial value r 0 is just an example, and ri can be flexibly set according to processing requirements in actual processing. The value proportional relationship with r 0 .
通过预先设置特征点数量区间与平滑半径取值的对应关系,有助于提高确定每帧图像对应的平滑半径的效率。By presetting the corresponding relationship between the feature point quantity interval and the value of the smoothing radius, it is helpful to improve the efficiency of determining the smoothing radius corresponding to each frame of image.
在本公开实施例中,平滑处理算法可以是现有技术中任意可用的能够实现平滑处理效果的算法,例如高斯平滑处理算法等。经过平滑处理得到的平滑轨迹例如可以表示为
Figure PCTCN2022085382-appb-000003
平滑轨迹即用于指示平滑处理后的视频中不同图像帧的拍摄位置, 例如
Figure PCTCN2022085382-appb-000004
表示视频中第n帧图像的拍摄位置被平滑处理后的位置。
In this embodiment of the present disclosure, the smoothing algorithm may be any available algorithm in the prior art that can achieve a smoothing effect, such as a Gaussian smoothing algorithm and the like. The smooth trajectory obtained by smoothing can be expressed as, for example,
Figure PCTCN2022085382-appb-000003
The smoothing trajectory is used to indicate the shooting positions of different image frames in the smoothed video, such as
Figure PCTCN2022085382-appb-000004
Indicates the position where the shooting position of the nth frame image in the video has been smoothed.
可选地,基于视频中不同图像帧对应的平滑半径,分别对移动轨迹中不同图像帧的拍摄位置进行平滑处理,得到平滑轨迹,包括:Optionally, based on the smoothing radii corresponding to different image frames in the video, smoothing is performed on the shooting positions of different image frames in the moving track respectively, to obtain a smooth track, including:
基于视频中每帧图像对应的平滑半径,确定视频中参与每次平滑处理的预设帧数的图像;Based on the smoothing radius corresponding to each frame of image in the video, determine the images in the video that participate in the preset number of frames in each smoothing process;
基于参与每次平滑处理的预设帧数的图像在移动轨迹中的拍摄位置,对移动轨迹中每帧图像的拍摄位置进行平滑处理,得到平滑轨迹。例如可以将参与每次平滑处理的预设帧数的图像在移动轨迹中的拍摄位置进行加权求和计算,并将计算结果作为当前帧图像的拍摄位置的平滑结果。Based on the shooting positions of the images of the preset number of frames participating in each smoothing process in the moving track, smoothing is performed on the shooting position of each frame of the image in the moving track to obtain a smooth track. For example, a weighted sum calculation may be performed on the shooting positions of the images of the preset number of frames involved in each smoothing process in the moving track, and the calculation result may be used as the smoothing result of the shooting positions of the current frame image.
S103、基于平滑轨迹和移动轨迹之间的差异,对视频进行形变,以得到经过防抖处理的视频。S103 , deforming the video based on the difference between the smooth trajectory and the moving trajectory to obtain a video that has undergone anti-shake processing.
将平滑轨迹
Figure PCTCN2022085382-appb-000005
和平滑前的移动轨迹C进行比对,可以确定移动轨迹的调整参数W={W 1,W 2,…,W n-1,W n},调整参数W中的各个子值
Figure PCTCN2022085382-appb-000006
n表示视频中包括的图像帧数;然后可以按照调整参数中各个子值与视频中每帧图像的对应关系,基于调整参数中的每个子值对相应的图像帧进行形变处理,从而得到防抖处理后的视频。在形变处理过程中,涉及对特定帧图像的旋转、平移、缩放或者裁剪等处理,可以根据实际处理需求来执行。即可选地,在本公开实施例中,基于平滑轨迹和移动轨迹之间的差异,对视频进行形变,以得到经过防抖处理的视频,包括:基于平滑轨迹和移动轨迹之间的差异,确定调整参数;利用调整参数对视频进行形变,以得到经过防抖处理的视频。
will smooth the trajectory
Figure PCTCN2022085382-appb-000005
Comparing with the moving trajectory C before smoothing, the adjustment parameter W={W 1 , W 2 ,..., W n-1 , W n } of the moving trajectory can be determined, and each sub-value in the adjustment parameter W can be determined.
Figure PCTCN2022085382-appb-000006
n represents the number of image frames included in the video; then, according to the corresponding relationship between each sub-value in the adjustment parameter and each frame of image in the video, the corresponding image frame can be deformed based on each sub-value in the adjustment parameter, so as to obtain anti-shake processed video. In the deformation processing process, it involves the rotation, translation, scaling or cropping of a specific frame image, which can be performed according to actual processing requirements. That is, in the embodiment of the present disclosure, deforming the video based on the difference between the smooth trajectory and the moving trajectory to obtain an anti-shake processed video includes: based on the difference between the smooth trajectory and the moving trajectory, Determine the adjustment parameters; use the adjustment parameters to deform the video to obtain a video that has undergone anti-shake processing.
在本公开实施例中,基于待处理视频中不同图像帧上用于追踪的特征点的数量,动态确定该视频中不同图像帧对应的平滑半径,即本公开实施例实现了基于图像帧上的特征点数量,自适应调整视频中不同图像帧对应的平滑半径的效果,然后基于该视频中不同图像帧对应的平滑半径,分别对视频的拍摄位置的移动轨迹中不同图像帧的拍摄位置进行平滑处理,最后基于平滑轨迹和移动轨迹之间差异,对视频进行形变,实现视频的防抖处理,优化了视频防抖的处理效果。相比于平滑半径的统一取值的情况,本公开实施例通过平滑半径的动态取值,有效避免了图像帧上用于追踪的特征点数量较少(或称为用于特征匹配的特征点数量较少,即特征不足)时,针对用于拍摄视频的拍摄装置的运动估计不准确,即视频拍摄位置的移动趋势估计不准确,进而引起视频画面晃动和异常形变的现象,有效改善了视频质量。In the embodiment of the present disclosure, based on the number of feature points used for tracking on different image frames in the video to be processed, the smooth radius corresponding to the different image frames in the video is dynamically determined, that is, the embodiment of the present disclosure realizes the The number of feature points, adaptively adjust the effect of the smoothing radius corresponding to different image frames in the video, and then based on the smoothing radius corresponding to different image frames in the video, respectively smooth the shooting positions of different image frames in the moving trajectory of the shooting position of the video. Finally, based on the difference between the smooth track and the moving track, the video is deformed to realize the anti-shake processing of the video, and the processing effect of the video anti-shake is optimized. Compared with the uniform value of the smooth radius, the embodiment of the present disclosure effectively avoids a small number of feature points used for tracking (or called feature points used for feature matching) on the image frame through the dynamic value of the smooth radius. When the number is small, i.e. insufficient features), the motion estimation of the video shooting device used to shoot the video is inaccurate, that is, the estimation of the movement trend of the video shooting position is inaccurate, which in turn causes the phenomenon of video screen shaking and abnormal deformation, which effectively improves the video quality.
图2为本公开实施例提供的另一种视频防抖处理方法的流程图,基于上述技术方案进一步优化与扩展,并可以与上述各个可选实施方式进行结合。FIG. 2 is a flowchart of another video anti-shake processing method provided by an embodiment of the present disclosure, which is further optimized and expanded based on the foregoing technical solution, and may be combined with the foregoing optional implementation manners.
如图2所示,本公开实施例提供的视频防抖处理方法可以包括:As shown in FIG. 2 , the video anti-shake processing method provided by the embodiment of the present disclosure may include:
S201、通过对视频中不同图像帧之间进行特征点追踪,确定视频的拍摄位置的移动轨迹,其中,移动轨迹用于指示视频中不同图像帧的拍摄位置。S201. Determine the movement track of the shooting position of the video by tracking feature points between different image frames in the video, where the movement track is used to indicate the shooting position of different image frames in the video.
S202、基于视频中每帧图像对应的平滑半径,确定视频中参与每次平滑处理的预设帧数的图像。S202 , based on the smoothing radius corresponding to each frame of the image in the video, determine the images in the video with a preset number of frames participating in each smoothing process.
示例性一,可以基于视频中每帧图像对应的平滑半径,在视频中确定每帧图像之前的第一预设帧数的在前帧图像;Exemplary one, based on the smooth radius corresponding to each frame of image in the video, the previous frame image of the first preset number of frames before each frame of image can be determined in the video;
将每帧图像以及第一预设帧数的在前帧图像,确定为视频中参与每次平滑处理的预设帧数的图像;此时,该第一预设帧数的取值可以是平滑半径的取值1。Determine each frame of image and the previous frame image of the first preset number of frames as the image of the preset number of frames participating in each smoothing process in the video; at this time, the value of the first preset number of frames may be smoothing The value of the radius is 1.
本公开实施例支持在视频拍摄的同时对视频进行防抖处理,视频拍摄完成,视频防抖处理也随之结束,从而得到质量较佳的拍摄视频。The embodiments of the present disclosure support anti-shake processing on the video while the video is being captured. After the video is captured, the video anti-shake processing also ends, thereby obtaining a captured video with better quality.
示例性二,可以基于视频中每帧图像对应的平滑半径,在视频中确定每帧图像之前的第二预设帧数的在前帧图像,以及确定每帧图像之后的第二预设帧数的在后帧图像;Exemplary two, based on the smooth radius corresponding to each frame of image in the video, determine the previous frame image of the second preset number of frames before each frame of image in the video, and determine the second preset number of frames after each frame of image. the image in the later frame;
将每帧图像、第二预设帧数的在前帧图像以及第二预设帧数的在后帧图像,确定为视频中参与每次平滑处理的预设帧数的图像;此时,该第二预设帧数的取值可以是平滑半径的取值。Each frame of image, the previous frame image of the second preset number of frames, and the subsequent frame image of the second preset number of frames are determined as the images of the preset number of frames participating in each smoothing process in the video; at this time, the The value of the second preset number of frames may be the value of the smoothing radius.
本公开实施例还支持对拍摄完成的视频进行防抖处理,在每帧图像前后各取一定帧数的图像,参与每帧图像在移动轨迹中的拍摄位置的平滑处理,同样达到改善视频质量的效果。The embodiment of the present disclosure also supports the anti-shake processing of the video after shooting, and takes a certain number of images before and after each frame of image to participate in the smooth processing of the shooting position of each frame of image in the moving trajectory, which also improves the video quality. Effect.
S203、基于参与每次平滑处理的预设帧数的图像在移动轨迹中的拍摄位置,进行拍摄位置的加权求和计算,得到每帧图像的平滑位置。S203 , based on the shooting positions of the images of the preset number of frames participating in each smoothing process in the movement track, perform weighted summation calculation of the shooting positions to obtain the smoothing positions of each frame of images.
以移动轨迹包括多个变换矩阵,即视频中每帧图像的拍摄位置可以采用一个变换矩阵表示为例,每帧图像的平滑位置(即平滑处理后的拍摄位置)可以采用矩阵的形式表示,以下称为平滑矩阵。加权求和计算过程中的权重可以适应性取值,本公开实施例不作具体限定。Taking the movement trajectory including multiple transformation matrices, that is, the shooting position of each frame of image in the video can be represented by a transformation matrix as an example, the smoothing position of each frame image (that is, the shooting position after smoothing processing) can be expressed in the form of a matrix, the following is called a smoothing matrix. The weight in the weighted sum calculation process may take adaptive values, which is not specifically limited in the embodiment of the present disclosure.
示例性一,以按照每帧图像对应的平滑半径,在每帧图像之前取一定帧数的图像,参与每帧图像的拍摄位置的平滑处理为例,每帧图像f i的平滑矩阵可以表示如下: Exemplary one, according to the smoothing radius corresponding to each frame of image, take a certain number of images before each frame of image, and participate in the smoothing processing of the shooting position of each frame of image as an example, the smoothing matrix of each frame of image f i can be expressed as follows: :
Figure PCTCN2022085382-appb-000007
Figure PCTCN2022085382-appb-000007
示例性二,以按照每帧图像对应的平滑半径,分别在每帧图像之前和之后取相同帧数的图像,参与每帧图像的拍摄位置的平滑处理为例,每帧图像f i的平滑矩阵可以表示如下: Exemplary 2, take images of the same number of frames before and after each frame of image according to the smoothing radius corresponding to each frame of image, and participate in the smoothing processing of the shooting position of each frame of image as an example, the smoothing matrix of each frame of image f i It can be expressed as follows:
Figure PCTCN2022085382-appb-000008
Figure PCTCN2022085382-appb-000008
在上述两个示例中,r为每帧图像对应的平滑半径,C t表示参与平滑处理的每帧图像在移动轨迹C中的拍摄位置(或称为变换矩阵),w i~t为参与平滑处理的每帧图像的权重,取值可以适应性设置。得到视频中每帧图像对应的平滑矩阵后,平滑轨迹可以表示如下: In the above two examples, r is the smoothing radius corresponding to each frame of image, C t represents the shooting position (or called transformation matrix) of each frame of image participating in the smoothing process in the moving track C, and w i~t is the participating smoothing The weight of each frame of image processed, the value can be set adaptively. After obtaining the smoothing matrix corresponding to each frame of image in the video, the smoothing trajectory can be expressed as follows:
Figure PCTCN2022085382-appb-000009
Figure PCTCN2022085382-appb-000009
通过对预设帧数的图像在移动轨迹中的拍摄位置进行加权求和计算,得到对应每帧图像的平滑位置,不仅计算方式简捷、高效,可以满足实时处理的需求,而且还可以保证视频拍摄位置的移动轨迹的平滑处理效果。The smooth position corresponding to each frame of image is obtained by weighting and summing the shooting positions of the images with a preset number of frames in the moving trajectory. The smoothing effect of the movement trajectory of the position.
S204、基于每帧图像的平滑位置,得到平滑轨迹。S204 , obtaining a smooth trajectory based on the smoothed position of each frame of the image.
S205、基于平滑轨迹和移动轨迹之间的差异,对视频进行形变,以得到经过防抖处理的视频。S205 , deforming the video based on the difference between the smooth trajectory and the moving trajectory to obtain a video that has undergone anti-shake processing.
在本公开实施例中,通过在视频防抖处理过程中根据待处理视频中每帧图像用于追踪的特征点数量,动态确定每帧图像对应的平滑半径,进而动态确定一定的图像帧数,以参与视频拍摄位置的移动轨迹的平滑处理,优化了视频防抖的处理效果。相比于平滑半径的统一取值的情况,本公开实施例通过平滑半径的动态取值,有效避免了当视频中图像帧上用于追踪的特征点数量较少时,针对用于拍摄视频的拍摄装置的运动估计不准确,即视频拍摄位置的移动趋势估计不准确,进而引起视频画面晃动和异常形变的现象,有效改善了视频质量。In the embodiment of the present disclosure, the smooth radius corresponding to each frame of image is dynamically determined according to the number of feature points used for tracking in each frame of image in the video to be processed during the video anti-shake processing process, and then a certain number of image frames is dynamically determined, In order to participate in the smooth processing of the movement trajectory of the video shooting position, the processing effect of video anti-shake is optimized. Compared with the case where the smooth radius is uniformly valued, the embodiment of the present disclosure effectively avoids, through the dynamic value of the smooth radius, that when the number of feature points used for tracking on the image frame in the video is small, it is The motion estimation of the shooting device is inaccurate, that is, the estimation of the movement trend of the video shooting position is inaccurate, which further causes the phenomenon of video picture shaking and abnormal deformation, which effectively improves the video quality.
图3为本公开实施例提供的一种视频防抖处理装置的结构示意图,可以适用于对视频进行防抖处理的情况。该装置可以采用软件和/或硬件实现,并可集成在任意具有计算能力的电子设备上,例如终端或者服务器等。FIG. 3 is a schematic structural diagram of a video anti-shake processing apparatus according to an embodiment of the present disclosure, which can be applied to a situation of performing anti-shake processing on a video. The apparatus can be implemented by software and/or hardware, and can be integrated on any electronic device with computing capability, such as a terminal or a server.
如图3所示,本公开实施例提供的视频防抖处理装置300可以包括移动轨迹确定模块301、平滑轨迹确定模块302和视频防抖处理模块303,其中:As shown in FIG. 3 , the video anti-shake processing apparatus 300 provided by the embodiment of the present disclosure may include a movement trajectory determination module 301, a smooth trajectory determination module 302, and a video anti-shake processing module 303, wherein:
移动轨迹确定模块301,用于通过对视频中不同图像帧之间进行特征点追踪,确定视频的拍摄位置的移动轨迹,其中,移动轨迹用于指示视频中不同图像帧的拍摄位置;The movement trajectory determination module 301 is used to determine the movement trajectory of the shooting position of the video by tracking the feature points between different image frames in the video, wherein the movement trajectory is used to indicate the shooting position of different image frames in the video;
平滑轨迹确定模块302,用于基于视频中不同图像帧对应的平滑半径,分别对移动轨迹中不同图像帧的拍摄位置进行平滑处理,得到平滑轨迹;其中,视频中不同图像帧对应的平滑半径分别基于视频中不同图像帧用于追踪的特征点的数量确定;The smooth trajectory determination module 302 is configured to perform smooth processing on the shooting positions of different image frames in the moving trajectory based on the smoothing radii corresponding to different image frames in the video, respectively, to obtain a smooth trajectory; wherein, the smoothing radii corresponding to different image frames in the video are respectively Determined based on the number of feature points used for tracking in different image frames in the video;
视频防抖处理模块303,用于基于平滑轨迹和移动轨迹之间的差异,对视频进行形变,以得到经过防抖处理的视频。The video anti-shake processing module 303 is configured to deform the video based on the difference between the smooth track and the moving track, so as to obtain a video that has undergone anti-shake processing.
可选地,视频中不同图像帧对应的平滑半径分别基于视频中不同图像帧用于追踪的特 征点的数量所属的数量区间、以及数量区间与平滑半径的对应关系确定。Optionally, the corresponding smoothing radii of different image frames in the video are respectively determined based on the number interval to which the number of feature points used for tracking by different image frames in the video belongs, and the corresponding relationship between the number interval and the smoothing radius.
可选地,平滑轨迹确定模块302包括:Optionally, the smooth trajectory determination module 302 includes:
图像帧数确定单元,用于基于视频中每帧图像对应的平滑半径,确定视频中参与每次平滑处理的预设帧数的图像;an image frame number determination unit, configured to determine the images of the preset number of frames participating in each smoothing process in the video based on the smoothing radius corresponding to each frame of image in the video;
平滑处理单元,用于基于参与每次平滑处理的预设帧数的图像在移动轨迹中的拍摄位置,对移动轨迹中每帧图像的拍摄位置进行平滑处理,得到平滑轨迹。The smoothing processing unit is configured to perform smoothing processing on the shooting position of each frame of images in the moving trajectory based on the shooting positions of the images of the preset number of frames participating in each smoothing processing in the moving trajectory to obtain a smoothed trajectory.
可选地,图像帧数确定单元包括:Optionally, the image frame number determination unit includes:
第一确定单元,用于基于视频中每帧图像对应的平滑半径,在视频中确定每帧图像之前的第一预设帧数的在前帧图像;The first determining unit is used to determine the previous frame image of the first preset frame number before each frame image in the video based on the smooth radius corresponding to each frame image in the video;
第二确定单元,用于将每帧图像以及第一预设帧数的在前帧图像,确定为视频中参与每次平滑处理的预设帧数的图像;或者a second determining unit, configured to determine each frame of image and the previous frame image of the first preset number of frames as the image of the preset number of frames participating in each smoothing process in the video; or
第三确定单元,用于基于视频中每帧图像对应的平滑半径,在视频中确定每帧图像之前的第二预设帧数的在前帧图像,以及确定每帧图像之后的第二预设帧数的在后帧图像;The third determining unit is configured to determine, based on the smooth radius corresponding to each frame of image in the video, the previous frame image of the second preset number of frames before each frame of image in the video, and to determine the second preset number of frames after each frame of image The following frame image of the frame number;
第四确定单元,用于将每帧图像、第二预设帧数的在前帧图像以及第二预设帧数的在后帧图像,确定为视频中参与每次平滑处理的预设帧数的图像。The fourth determining unit is used to determine each frame of image, the previous frame image of the second preset frame number and the subsequent frame image of the second preset frame number as the preset number of frames participating in each smoothing process in the video Image.
可选地,平滑处理单元包括:Optionally, the smoothing processing unit includes:
平滑位置确定子单元,用于基于参与每次平滑处理的预设帧数的图像在移动轨迹中的拍摄位置,进行拍摄位置的加权求和计算,得到每帧图像的平滑位置;The smoothing position determination subunit is used to perform the weighted sum calculation of the shooting position based on the shooting position of the image of the preset number of frames participating in each smoothing process in the moving track, so as to obtain the smoothing position of each frame of image;
平滑轨迹确定子单元,用于基于每帧图像的平滑位置,得到平滑轨迹。The smoothed trajectory determination subunit is used to obtain a smoothed trajectory based on the smoothed position of each frame of image.
可选地,移动轨迹采用变换矩阵表示,移动轨迹中的不同变换矩阵分别表示视频中不同图像帧的拍摄位置;Optionally, the movement track is represented by a transformation matrix, and different transformation matrices in the movement track respectively represent the shooting positions of different image frames in the video;
移动轨迹确定模块301具体用于:The movement trajectory determination module 301 is specifically used for:
通过对视频中不同图像帧之间进行特征点追踪,确定视频中不同图像帧之间拍摄位置的变换矩阵,并基于视频中不同图像帧之间拍摄位置的变换矩阵确定视频的拍摄位置的移动轨迹。By tracking feature points between different image frames in the video, the transformation matrix of the shooting position between different image frames in the video is determined, and the movement trajectory of the shooting position of the video is determined based on the transformation matrix of the shooting position between different image frames in the video. .
可选地,视频防抖处理模块303包括:Optionally, the video anti-shake processing module 303 includes:
调整参数确定单元,用于基于平滑轨迹和移动轨迹之间的差异,确定调整参数;an adjustment parameter determination unit for determining an adjustment parameter based on the difference between the smooth trajectory and the moving trajectory;
视频形变单元,用于利用调整参数对视频进行形变,以得到经过防抖处理的视频。The video deformation unit is used to deform the video by using the adjustment parameters to obtain the video that has undergone anti-shake processing.
本公开实施例所提供的视频防抖处理装置可执行本公开实施例所提供的任意视频防抖处理方法,具备执行方法相应的功能模块和有益效果。本公开装置实施例中未详尽描述的内容可以参考本公开任意方法实施例中的描述。The video anti-shake processing apparatus provided by the embodiment of the present disclosure can execute any video anti-shake processing method provided by the embodiment of the present disclosure, and has functional modules and beneficial effects corresponding to the execution method. For the content that is not described in detail in the apparatus embodiment of the present disclosure, reference may be made to the description in any method embodiment of the present disclosure.
图4为本公开实施例提供的一种电子设备的结构示意图,用于对实现本公开实施例提 供的视频防抖处理方法的电子设备进行示例性说明。本公开实施例中的电子设备可以包括但不限于诸如移动电话、笔记本电脑、数字广播接收器、PDA(个人数字助理)、PAD(平板电脑)、PMP(便携式多媒体播放器)、车载终端(例如车载导航终端)等等的移动终端以及诸如数字TV、台式计算机、智能家居设备、可穿戴电子设备、服务器等等的固定终端。图4示出的电子设备仅仅是一个示例,不应对本公开实施例的功能和占用范围带来任何限制。Fig. 4 is a schematic structural diagram of an electronic device according to an embodiment of the present disclosure, and is used to exemplarily describe an electronic device that implements the video anti-shake processing method provided by the embodiment of the present disclosure. The electronic devices in the embodiments of the present disclosure may include, but are not limited to, such as mobile phones, notebook computers, digital broadcast receivers, PDAs (personal digital assistants), PADs (tablets), PMPs (portable multimedia players), vehicle-mounted terminals (eg, Mobile terminals such as car navigation terminals), etc., and stationary terminals such as digital TVs, desktop computers, smart home devices, wearable electronic devices, servers, and the like. The electronic device shown in FIG. 4 is only an example, and should not impose any limitation on the functions and occupancy scope of the embodiments of the present disclosure.
如图4所示,电子设备400包括一个或多个处理器401和存储器402。As shown in FIG. 4 , electronic device 400 includes one or more processors 401 and memory 402 .
处理器401可以是中央处理单元(CPU)或者具有数据处理能力和/或指令执行能力的其他形式的处理单元,并且可以控制电子设备400中的其他组件以执行期望的功能。 Processor 401 may be a central processing unit (CPU) or other form of processing unit having data processing capabilities and/or instruction execution capabilities, and may control other components in electronic device 400 to perform desired functions.
存储器402可以包括一个或多个计算机程序产品,计算机程序产品可以包括各种形式的计算机可读存储介质,例如易失性存储器和/或非易失性存储器。易失性存储器例如可以包括随机存取存储器(RAM)和/或高速缓冲存储器(cache)等。非易失性存储器例如可以包括只读存储器(ROM)、硬盘、闪存等。在计算机可读存储介质上可以存储一个或多个计算机程序指令,处理器401可以运行程序指令,以实现本公开实施例提供的视频防抖处理方法,还可以实现其他期望的功能。在计算机可读存储介质中还可以存储诸如输入信号、信号分量、噪声分量等各种内容。 Memory 402 may include one or more computer program products, which may include various forms of computer-readable storage media, such as volatile memory and/or non-volatile memory. Volatile memory may include, for example, random access memory (RAM) and/or cache memory, among others. Non-volatile memory may include, for example, read only memory (ROM), hard disk, flash memory, and the like. One or more computer program instructions may be stored on the computer-readable storage medium, and the processor 401 may execute the program instructions to implement the video anti-shake processing method provided by the embodiments of the present disclosure, and may also implement other desired functions. Various contents such as input signals, signal components, noise components, etc. may also be stored in the computer-readable storage medium.
其中,本公开实施例提供的视频防抖处理方法可以包括:通过对视频中不同图像帧之间进行特征点追踪,确定视频的拍摄位置的移动轨迹,其中,移动轨迹用于指示视频中不同图像帧的拍摄位置;基于视频中不同图像帧对应的平滑半径,分别对移动轨迹中不同图像帧的拍摄位置进行平滑处理,得到平滑轨迹;其中,视频中不同图像帧对应的平滑半径分别基于视频中不同图像帧用于追踪的特征点的数量确定;基于平滑轨迹和移动轨迹之间的差异,对视频进行形变,以得到经过防抖处理的视频。应当理解,电子设备400还可以执行本公开方法实施例提供的其他可选实施方案。The video anti-shake processing method provided by the embodiment of the present disclosure may include: by tracking feature points between different image frames in the video, determining a movement trajectory of the shooting position of the video, wherein the movement trajectory is used to indicate different images in the video. The shooting position of the frame; based on the smoothing radii corresponding to different image frames in the video, the shooting positions of different image frames in the moving track are smoothed respectively to obtain a smooth track; wherein, the smoothing radii corresponding to different image frames in the video are based on the The number of feature points used for tracking in different image frames is determined; based on the difference between the smooth trajectory and the moving trajectory, the video is deformed to obtain an anti-shake processed video. It should be understood that the electronic device 400 may also perform other optional implementations provided by the method embodiments of the present disclosure.
在一个示例中,电子设备400还可以包括:输入装置403和输出装置404,这些组件通过总线系统和/或其他形式的连接机构(未示出)互连。In one example, the electronic device 400 may also include an input device 403 and an output device 404 interconnected by a bus system and/or other form of connection mechanism (not shown).
此外,该输入装置403还可以包括例如键盘、鼠标等等。In addition, the input device 403 may also include, for example, a keyboard, a mouse, and the like.
该输出装置404可以向外部输出各种信息,包括确定出的距离信息、方向信息等。该输出装置404可以包括例如显示器、扬声器、打印机、以及通信网络及其所连接的远程输出设备等等。The output device 404 can output various information to the outside, including the determined distance information, direction information, and the like. The output devices 404 may include, for example, displays, speakers, printers, and communication networks and their connected remote output devices, among others.
当然,为了简化,图4中仅示出了该电子设备400中与本公开有关的组件中的一些,省略了诸如总线、输入/输出接口等等的组件。除此之外,根据具体应用情况,电子设备400还可以包括任何其他适当的组件。Of course, for simplicity, only some of the components in the electronic device 400 related to the present disclosure are shown in FIG. 4 , and components such as buses, input/output interfaces, and the like are omitted. Besides, the electronic device 400 may also include any other appropriate components according to the specific application.
除了上述方法和设备以外,本公开的实施例还可以是计算机程序产品,其包括计算机程序或计算机程序指令,计算机程序或计算机程序指令在被处理器执行时使得计算设备实现本公开实施例所提供的任意视频防抖处理方法。In addition to the above-mentioned methods and devices, the embodiments of the present disclosure may also be computer program products, which include computer programs or computer program instructions, which, when executed by a processor, cause a computing device to implement what is provided by the embodiments of the present disclosure. Any video anti-shake processing method.
当使用软件实现时,可以全部或部分地以计算机程序产品的形式实现。该计算机程序产品包括一个或多个计算机指令。在计算机上加载和执行该计算机程序指令时,全部或部分地产生按照本申请实施例该的流程或功能。该计算机可以是通用计算机、专用计算机、计算机网络、或者其他可编程装置。When implemented in software, it can be implemented in whole or in part in the form of a computer program product. The computer program product includes one or more computer instructions. When the computer program instructions are loaded and executed on a computer, all or part of the processes or functions according to the embodiments of the present application are generated. The computer may be a general purpose computer, a special purpose computer, a computer network, or other programmable device.
计算机程序产品可以以一种或多种程序设计语言的任意组合来编写用于执行本公开实施例操作的程序代码,程序设计语言包括面向对象的程序设计语言,诸如Java、C++等,还包括常规的过程式程序设计语言,诸如“C”语言或类似的程序设计语言。程序代码可以完全地在用户电子设备上执行、部分地在用户电子设备上执行、作为一个独立的软件包执行、部分在用户电子设备上且部分在远程电子设备上执行、或者完全在远程电子设备上执行。The computer program product may write program code for performing operations of embodiments of the present disclosure in any combination of one or more programming languages, including object-oriented programming languages, such as Java, C++, etc., as well as conventional procedural programming language, such as "C" language or similar programming language. The program code may execute entirely on the user electronic device, partly on the user electronic device, as a stand-alone software package, partly on the user electronic device and partly on the remote electronic device, or entirely on the remote electronic device execute on.
此外,本公开实施例还可以提供一种计算机可读存储介质,其上存储有计算机程序指令,计算机程序指令在被处理器运行时使得计算设备实现本公开实施例所提供的任意视频防抖处理方法。In addition, the embodiments of the present disclosure may further provide a computer-readable storage medium on which computer program instructions are stored, and when the computer program instructions are executed by the processor, the computer program instructions enable the computing device to implement any video anti-shake processing provided by the embodiments of the present disclosure method.
其中,本公开实施例提供的视频防抖处理方法可以包括:通过对视频中不同图像帧之间进行特征点追踪,确定视频的拍摄位置的移动轨迹,其中,移动轨迹用于指示视频中不同图像帧的拍摄位置;基于视频中不同图像帧对应的平滑半径,分别对移动轨迹中不同图像帧的拍摄位置进行平滑处理,得到平滑轨迹;其中,视频中不同图像帧对应的平滑半径分别基于视频中不同图像帧用于追踪的特征点的数量确定;基于平滑轨迹和移动轨迹之间的差异,对视频进行形变,以得到经过防抖处理的视频。应当理解,计算机程序指令在被处理器运行时,还可以使得计算设备实现本公开方法实施例提供的其他可选实施方案。The video anti-shake processing method provided by the embodiment of the present disclosure may include: by tracking feature points between different image frames in the video, determining a movement trajectory of the shooting position of the video, wherein the movement trajectory is used to indicate different images in the video. The shooting position of the frame; based on the smoothing radii corresponding to different image frames in the video, the shooting positions of different image frames in the moving track are smoothed respectively to obtain a smooth track; wherein, the smoothing radii corresponding to different image frames in the video are based on the The number of feature points used for tracking in different image frames is determined; based on the difference between the smooth trajectory and the moving trajectory, the video is deformed to obtain an anti-shake processed video. It should be understood that, when the computer program instructions are executed by the processor, the computer program instructions can also cause the computing device to implement other optional implementations provided by the method embodiments of the present disclosure.
计算机可读存储介质可以采用一个或多个可读介质的任意组合。可读介质可以是可读信号介质或者可读存储介质。可读存储介质例如可以包括但不限于电、磁、光、电磁、红外线、或半导体的系统、装置或器件,或者任意以上的组合。可读存储介质的更具体的例子(非穷举的列表)包括:具有一个或多个导线的电连接、便携式盘、硬盘、随机存取存储器(RAM)、只读存储器(ROM)、可擦式可编程只读存储器(EPROM或闪存)、光纤、便携式紧凑盘只读存储器(CD-ROM)、光存储器件、磁存储器件、或者上述的任意合适的组合。A computer-readable storage medium can employ any combination of one or more readable media. The readable medium may be a readable signal medium or a readable storage medium. The readable storage medium may include, for example, but not limited to, electrical, magnetic, optical, electromagnetic, infrared, or semiconductor systems, apparatuses or devices, or any combination of the above. More specific examples (non-exhaustive list) of readable storage media include: electrical connections with one or more wires, portable disks, hard disks, random access memory (RAM), read only memory (ROM), erasable programmable read only memory (EPROM or flash memory), optical fiber, portable compact disk read only memory (CD-ROM), optical storage devices, magnetic storage devices, or any suitable combination of the foregoing.
需要说明的是,在本文中,诸如“第一”和“第二”等之类的关系术语仅仅用来将一个实体或者操作与另一个实体或操作区分开来,而不一定要求或者暗示这些实体或操作之 间存在任何这种实际的关系或者顺序。而且,术语“包括”、“包含”或者其任何其他变体意在涵盖非排他性的包含,从而使得包括一系列要素的过程、方法、物品或者设备不仅包括那些要素,而且还包括没有明确列出的其他要素,或者是还包括为这种过程、方法、物品或者设备所固有的要素。在没有更多限制的情况下,由语句“包括一个……”限定的要素,并不排除在包括要素的过程、方法、物品或者设备中还存在另外的相同要素。It should be noted that, in this document, relational terms such as "first" and "second" etc. are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply these There is no such actual relationship or sequence between entities or operations. Moreover, the terms "comprising", "comprising" or any other variation thereof are intended to encompass a non-exclusive inclusion such that a process, method, article or device that includes a list of elements includes not only those elements, but also includes not explicitly listed or other elements inherent to such a process, method, article or apparatus. Without further limitation, an element qualified by the phrase "comprising a..." does not preclude the presence of additional identical elements in the process, method, article, or device that includes the element.
以上仅是本公开的具体实施方式,使本领域技术人员能够理解或实现本公开。对这些实施例的多种修改对本领域的技术人员来说将是显而易见的,本文中所定义的一般原理可以在不脱离本公开的精神或范围的情况下,在其它实施例中实现。因此,本公开将不会被限制于本文的这些实施例,而是要符合与本文所公开的原理和新颖特点相一致的最宽的范围。The above are only specific embodiments of the present disclosure, so that those skilled in the art can understand or implement the present disclosure. Various modifications to these embodiments will be readily apparent to those skilled in the art, and the generic principles defined herein may be implemented in other embodiments without departing from the spirit or scope of the present disclosure. Therefore, the present disclosure is not to be limited to the embodiments herein, but is to be accorded the widest scope consistent with the principles and novel features disclosed herein.

Claims (11)

  1. 一种视频防抖处理方法,其特征在于,包括:A video anti-shake processing method, comprising:
    通过对视频中不同图像帧之间进行特征点追踪,确定所述视频的拍摄位置的移动轨迹,其中,所述移动轨迹用于指示所述视频中不同图像帧的拍摄位置;By tracking feature points between different image frames in the video, the movement trajectory of the shooting position of the video is determined, wherein the movement trajectory is used to indicate the shooting position of different image frames in the video;
    基于所述视频中不同图像帧对应的平滑半径,分别对所述移动轨迹中不同图像帧的拍摄位置进行平滑处理,得到平滑轨迹;其中,所述视频中不同图像帧对应的平滑半径分别基于所述视频中不同图像帧用于追踪的特征点的数量确定;Based on the smoothing radii corresponding to different image frames in the video, the shooting positions of the different image frames in the moving trajectory are respectively smoothed to obtain a smooth trajectory; wherein the smoothing radii corresponding to the different image frames in the video are based on the respective smoothing radii of the different image frames in the video Determine the number of feature points used for tracking in different image frames in the video;
    基于所述平滑轨迹和所述移动轨迹之间的差异,对所述视频进行形变,以得到经过防抖处理的视频。Based on the difference between the smooth trajectory and the moving trajectory, the video is deformed to obtain an anti-shake processed video.
  2. 根据权利要求1所述的方法,其特征在于,所述视频中不同图像帧对应的平滑半径分别基于所述视频中不同图像帧用于追踪的特征点的数量所属的数量区间、以及数量区间与平滑半径的对应关系确定。The method according to claim 1, wherein the smoothing radii corresponding to different image frames in the video are based on the number interval to which the number of feature points used for tracking of the different image frames in the video belong, and the number interval and The correspondence of the smoothing radius is determined.
  3. 根据权利要求1所述的方法,其特征在于,基于所述视频中不同图像帧对应的平滑半径,分别对所述移动轨迹中不同图像帧的拍摄位置进行平滑处理,得到平滑轨迹,包括:The method according to claim 1, wherein, based on the smoothing radii corresponding to different image frames in the video, smoothing is performed on the shooting positions of different image frames in the moving track respectively to obtain a smooth track, comprising:
    基于所述视频中每帧图像对应的平滑半径,确定所述视频中参与每次平滑处理的预设帧数的图像;Based on the smoothing radius corresponding to each frame of image in the video, determine the image of the preset number of frames participating in each smoothing process in the video;
    基于参与每次平滑处理的预设帧数的图像在所述移动轨迹中的拍摄位置,对所述移动轨迹中每帧图像的拍摄位置进行平滑处理,得到平滑轨迹。Based on the shooting positions of the images of the preset number of frames participating in each smoothing process in the moving track, smoothing is performed on the shooting position of each frame of the image in the moving track to obtain a smooth track.
  4. 根据权利要求3所述的方法,其特征在于,基于所述视频中每帧图像对应的平滑半径,确定所述视频中参与每次平滑处理的预设帧数的图像,包括:The method according to claim 3, wherein, based on the smoothing radius corresponding to each frame of image in the video, determining the images of the preset number of frames participating in each smoothing process in the video, comprising:
    基于所述视频中每帧图像对应的平滑半径,在所述视频中确定每帧图像之前的第一预设帧数的在前帧图像;Based on the smooth radius corresponding to each frame of image in the video, determine the previous frame image of the first preset number of frames before each frame of image in the video;
    将每帧图像以及所述第一预设帧数的在前帧图像,确定为所述视频中参与每次平滑处理的预设帧数的图像;或者Determining each frame of image and the previous frame image of the first preset number of frames as the image of the preset number of frames participating in each smoothing process in the video; or
    基于所述视频中每帧图像对应的平滑半径,在所述视频中确定每帧图像之前的第二预设帧数的在前帧图像,以及确定每帧图像之后的第二预设帧数的在后帧图像;Based on the smooth radius corresponding to each frame of image in the video, determine the previous frame image of the second preset number of frames before each frame of image in the video, and determine the second preset number of frames after each frame of image in the video. image in later frame;
    将每帧图像、所述第二预设帧数的在前帧图像以及所述第二预设帧数的在后帧图像,确定为所述视频中参与每次平滑处理的预设帧数的图像。Determining each frame of image, the previous frame image of the second preset frame number, and the subsequent frame image of the second preset frame number as the number of preset frames participating in each smoothing process in the video. image.
  5. 根据权利要求3所述的方法,其特征在于,基于参与每次平滑处理的预设帧数的图像在所述移动轨迹中的拍摄位置,对所述移动轨迹中每帧图像的拍摄位置进行平滑处理,得到平滑轨迹,包括:The method according to claim 3, wherein the shooting position of each frame of images in the moving track is smoothed based on the shooting positions of the images of the preset number of frames participating in each smoothing process in the moving track processing to obtain a smooth trajectory, including:
    基于参与每次平滑处理的预设帧数的图像在所述移动轨迹中的拍摄位置,进行拍摄位置的加权求和计算,得到每帧图像的平滑位置;Based on the shooting positions of the images of the preset number of frames participating in each smoothing process in the moving track, a weighted sum calculation of the shooting positions is performed to obtain the smoothing position of each frame of image;
    基于每帧图像的平滑位置,得到所述平滑轨迹。The smoothed trajectory is obtained based on the smoothed position of each frame of image.
  6. 根据权利要求1所述的方法,其特征在于,所述移动轨迹采用变换矩阵表示,所述移动轨迹中的不同变换矩阵分别表示所述视频中不同图像帧的拍摄位置;The method according to claim 1, wherein the movement track is represented by a transformation matrix, and different transformation matrices in the movement track respectively represent the shooting positions of different image frames in the video;
    通过对视频中不同图像帧之间进行特征点追踪,确定所述视频的拍摄位置的移动轨迹,包括:By tracking feature points between different image frames in the video, the movement trajectory of the shooting position of the video is determined, including:
    通过对所述视频中不同图像帧之间进行特征点追踪,确定所述视频中不同图像帧之间拍摄位置的变换矩阵,并基于所述视频中不同图像帧之间拍摄位置的变换矩阵确定所述视频的拍摄位置的移动轨迹。By tracking the feature points between different image frames in the video, the transformation matrix of the shooting position between different image frames in the video is determined, and the transformation matrix of the shooting position between different image frames in the video is determined based on the transformation matrix of the shooting position between the different image frames in the video. The movement trajectory of the shooting position of the video.
  7. 根据权利要求1所述的方法,其特征在于,基于所述平滑轨迹和所述移动轨迹之间的差异,对所述视频进行形变,以得到经过防抖处理的视频,包括:The method according to claim 1, wherein the video is deformed based on the difference between the smooth trajectory and the moving trajectory to obtain an anti-shake processed video, comprising:
    基于所述平滑轨迹和所述移动轨迹之间的差异,确定调整参数;determining an adjustment parameter based on the difference between the smooth trajectory and the moving trajectory;
    利用所述调整参数对所述视频进行形变,以得到经过防抖处理的视频。The video is deformed by using the adjustment parameter to obtain an anti-shake processed video.
  8. 一种视频防抖处理装置,其特征在于,包括:A video anti-shake processing device, comprising:
    移动轨迹确定模块,用于通过对视频中不同图像帧之间进行特征点追踪,确定所述视频的拍摄位置的移动轨迹,其中,所述移动轨迹用于指示所述视频中不同图像帧的拍摄位置;A movement trajectory determination module, configured to determine the movement trajectory of the shooting position of the video by tracking feature points between different image frames in the video, wherein the movement trajectory is used to indicate the shooting of different image frames in the video Location;
    平滑轨迹确定模块,用于基于所述视频中不同图像帧对应的平滑半径,分别对所述移动轨迹中不同图像帧的拍摄位置进行平滑处理,得到平滑轨迹;其中,所述视频中不同图像帧对应的平滑半径分别基于所述视频中不同图像帧用于追踪的特征点的数量确定;A smooth trajectory determination module, configured to perform smooth processing on the shooting positions of different image frames in the moving trajectory based on the smoothing radii corresponding to different image frames in the video, respectively, to obtain a smooth trajectory; wherein, the different image frames in the video The corresponding smooth radius is determined based on the number of feature points used for tracking in different image frames in the video respectively;
    视频防抖处理模块,用于基于所述平滑轨迹和所述移动轨迹之间的差异,对所述视频进行形变,以得到经过防抖处理的视频。A video anti-shake processing module, configured to deform the video based on the difference between the smooth track and the moving track to obtain a video that has undergone anti-shake processing.
  9. 一种电子设备,其特征在于,包括存储器和处理器,其中,所述存储器中存储有计算机程序,当所述计算机程序被所述处理器执行时,使得所述电子设备实现权利要求1-7中任一项所述的视频防抖处理方法。An electronic device, characterized by comprising a memory and a processor, wherein a computer program is stored in the memory, and when the computer program is executed by the processor, the electronic device is made to implement claims 1-7 The video anti-shake processing method described in any one.
  10. 一种计算机可读存储介质,其特征在于,所述存储介质中存储有计算机程序,当所述计算机程序被计算设备执行时,使得所述计算设备实现权利要求1-7中任一项所述的视频防抖处理方法。A computer-readable storage medium, characterized in that, a computer program is stored in the storage medium, and when the computer program is executed by a computing device, the computing device is made to implement any one of claims 1-7. The video anti-shake processing method.
  11. 一种计算机程序产品,包括计算机程序/指令,其特征在于,该计算机程序/指令被处理器执行时实现如权利要求1-7中任一所述的视频防抖处理方法。A computer program product, comprising a computer program/instruction, characterized in that, when the computer program/instruction is executed by a processor, the video anti-shake processing method according to any one of claims 1-7 is implemented.
PCT/CN2022/085382 2021-04-08 2022-04-06 Video image stabilization method and apparatus, electronic device, and storage medium WO2022214001A1 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
US18/472,001 US20240013347A1 (en) 2021-04-08 2023-09-21 Method for video anti-shake processing, electronic apparatus, and storage medium

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202110379627.2 2021-04-08
CN202110379627.2A CN115209030B (en) 2021-04-08 2021-04-08 Video anti-shake processing method and device, electronic equipment and storage medium

Related Parent Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2022/085634 Continuation-In-Part WO2022214037A1 (en) 2021-04-08 2022-04-07 Video anti-shake processing method and apparatus, electronic device, and storage medium

Related Child Applications (1)

Application Number Title Priority Date Filing Date
US18/472,001 Continuation-In-Part US20240013347A1 (en) 2021-04-08 2023-09-21 Method for video anti-shake processing, electronic apparatus, and storage medium

Publications (1)

Publication Number Publication Date
WO2022214001A1 true WO2022214001A1 (en) 2022-10-13

Family

ID=83545997

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2022/085382 WO2022214001A1 (en) 2021-04-08 2022-04-06 Video image stabilization method and apparatus, electronic device, and storage medium

Country Status (2)

Country Link
CN (1) CN115209030B (en)
WO (1) WO2022214001A1 (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116797497B (en) * 2023-08-24 2023-11-14 摩尔线程智能科技(北京)有限责任公司 Image processing method, device, equipment and storage medium

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20130120600A1 (en) * 2010-09-14 2013-05-16 Hailin Jin Methods and Apparatus for Subspace Video Stabilization
WO2014092193A1 (en) * 2012-12-14 2014-06-19 株式会社コンセプト Image processing device, image processing method, image processing program, program, and mobile terminal device with camera
CN108564554A (en) * 2018-05-09 2018-09-21 上海大学 A kind of video stabilizing method based on movement locus optimization
CN108596858A (en) * 2018-05-10 2018-09-28 中国科学技术大学 A kind of traffic video jitter removing method of feature based track
CN110047091A (en) * 2019-03-14 2019-07-23 河海大学 One kind is based on the estimation of camera track and the matched digital image stabilization method of characteristic block
CN110139031A (en) * 2019-05-05 2019-08-16 南京大学 A kind of video stabilization system and its working method based on inertia perception

Family Cites Families (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105409196B (en) * 2013-07-23 2018-11-30 微软技术许可有限责任公司 Adaptive Path for video stabilization is smooth
CN108632501B (en) * 2017-03-23 2020-07-03 展讯通信(上海)有限公司 Video anti-shake method and device and mobile terminal
WO2018223381A1 (en) * 2017-06-09 2018-12-13 厦门美图之家科技有限公司 Video shake-prevention method and mobile device
CN112492223B (en) * 2019-07-23 2023-05-12 影石创新科技股份有限公司 Camera lens smoothing method and device and portable terminal
CN111901678B (en) * 2020-07-31 2022-08-23 成都云格致力科技有限公司 Anti-jitter smoothing method and system for TCP real-time video stream

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20130120600A1 (en) * 2010-09-14 2013-05-16 Hailin Jin Methods and Apparatus for Subspace Video Stabilization
WO2014092193A1 (en) * 2012-12-14 2014-06-19 株式会社コンセプト Image processing device, image processing method, image processing program, program, and mobile terminal device with camera
CN108564554A (en) * 2018-05-09 2018-09-21 上海大学 A kind of video stabilizing method based on movement locus optimization
CN108596858A (en) * 2018-05-10 2018-09-28 中国科学技术大学 A kind of traffic video jitter removing method of feature based track
CN110047091A (en) * 2019-03-14 2019-07-23 河海大学 One kind is based on the estimation of camera track and the matched digital image stabilization method of characteristic block
CN110139031A (en) * 2019-05-05 2019-08-16 南京大学 A kind of video stabilization system and its working method based on inertia perception

Also Published As

Publication number Publication date
CN115209030A (en) 2022-10-18
CN115209030B (en) 2024-02-27

Similar Documents

Publication Publication Date Title
WO2022214037A1 (en) Video anti-shake processing method and apparatus, electronic device, and storage medium
CN109788189B (en) Five-dimensional video stabilization device and method for fusing camera and gyroscope
US9697587B2 (en) Adaptive path smoothing for video stabilization
WO2020140976A1 (en) Image acquisition method, device, point-reading device, electronic device and storage medium
JP2022508988A (en) Compression for Face Recognition-Extended Depth Directional Convolutional Neural Network
WO2018228330A1 (en) Focusing method and apparatus for realizing clear human face, and computer device
WO2021115136A1 (en) Anti-shake method and apparatus for video image, electronic device, and storage medium
US9953400B2 (en) Adaptive path smoothing for video stabilization
WO2021114990A1 (en) Method and apparatus for correcting face distortion, electronic device, and storage medium
CN110111241B (en) Method and apparatus for generating dynamic image
CN109194878B (en) Video image anti-shake method, device, equipment and storage medium
WO2022214001A1 (en) Video image stabilization method and apparatus, electronic device, and storage medium
WO2020147698A1 (en) Picture optimization method and device, terminal and corresponding storage medium
WO2018058476A1 (en) Image correction method and device
US20110196916A1 (en) Client terminal, server, cloud computing system, and cloud computing method
WO2021170123A1 (en) Video generation method and device, and corresponding storage medium
WO2022100690A1 (en) Animal face style image generation method and apparatus, model training method and apparatus, and device
CN110211017B (en) Image processing method and device and electronic equipment
CN111966473B (en) Operation method and device of linear regression task and electronic equipment
WO2024021504A1 (en) Facial recognition model training method and apparatus, recognition method, and device and medium
CN110223220B (en) Method and device for processing image
CN111429353A (en) Image splicing method and device, panorama splicing method and device, storage medium and electronic equipment
WO2022222922A1 (en) Voice signal processing method and apparatus
CN113223185B (en) Image processing method and device, electronic equipment and storage medium
WO2021170122A1 (en) Image editing method and apparatus, and corresponding storage medium

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 22784067

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 22784067

Country of ref document: EP

Kind code of ref document: A1