Video processing method and device, electronic equipment and storage medium

文档序号:1508911 发布日期:2020-02-07 浏览:23次 中文

阅读说明:本技术 一种视频处理方法、装置、电子设备及存储介质 (Video processing method and device, electronic equipment and storage medium ) 是由 宋雪 姜育刚 于 2019-11-18 设计创作,主要内容包括:本发明实施例公开了一种视频处理方法、装置、电子设备及存储介质。通过对第一视频进行分割,得到至少两个视频片段,基于第二视频的特征编码和各视频片段的特征编码进行匹配,确定与第二视频的特征编码相匹配的中间视频片段,以实现在低维度下将视频与广告进行粗匹配,然后基于第二视频在预设维度下的第二视频特征分别与各中间视频片段在预设维度下的第一视频特征进行匹配,根据在各预设维度下的匹配结果确定与第二视频相匹配的目标视频片段,解决了现有技术中由于插播广告和投放点衔接度差的问题,达到先通过特征编码进行粗匹配,然后在预设维度下,将视频和广告进行细匹配的目的,实现提高插播广告和投放点衔接度,提高用户体验度的效果。(The embodiment of the invention discloses a video processing method, a video processing device, electronic equipment and a storage medium. The method comprises the steps of obtaining at least two video segments by segmenting a first video, determining an intermediate video segment matched with the feature code of a second video based on the feature code of the second video and the feature code of each video segment for matching so as to realize rough matching of the video and the advertisement under low dimensionality, then, on the basis of the second video characteristics of the second video in the preset dimension, the second video characteristics are respectively matched with the first video characteristics of each intermediate video segment in the preset dimension, the target video segment matched with the second video is determined according to the matching result under each preset dimension, the problem of poor engagement degree of the spot and the spot due to the advertisement insertion in the prior art is solved, the purpose of rough matching through the characteristic coding is achieved, then, under the preset dimensionality, the video and the advertisement are finely matched, so that the linking degree of the spot advertisement and the spot advertisement is improved, and the effect of the user experience degree is improved.)

1. A video processing method, comprising:

segmenting a first video to obtain at least two video segments;

matching based on the feature coding of a second video and the feature coding of each video segment, and determining an intermediate video segment matched with the feature coding of the second video;

and respectively matching second video features of the second video in a preset dimension with first video features of the intermediate video segments in the preset dimension, and determining a target video segment matched with the second video according to a matching result in each preset dimension, wherein an end point of the target video segment is an insertion point of the second video.

2. The method of claim 1, wherein matching the second video-based feature coding with the feature coding of each of the video segments comprises:

and segmenting the second video, and matching based on the characteristic code of the first video segment of the second video and the characteristic codes of the video segments.

3. The method according to claim 2, wherein the feature code is a hash code, and the hash code is determined according to the video feature of each video frame in a preset dimension;

wherein the matching based on the feature coding of the first video segment of the second video and the feature coding of each of the video segments comprises:

extracting a first coded frame sequence of each of the video segments of the first video and a second coded frame sequence of the first video segment, respectively;

matching the second sequence of encoded frames with each of the first sequence of encoded frames based on the order of play of each of the video segments of the first video.

4. The method according to claim 1 or 2, characterized in that the method further comprises:

respectively inputting each video clip of the first video to a first feature extraction model trained in advance to obtain first video features of each video clip under a preset dimensionality;

inputting the second video or the first video segment of the second video to a pre-trained second feature extraction model to obtain a second video feature of the second video or the first video segment of the second video in a preset dimension.

5. The method of claim 4, wherein determining the target video segment matched with the second video according to the matching result in each preset dimension based on the matching of the second video feature of the second video in the preset dimension with the first video feature of each intermediate video segment in the preset dimension comprises:

for any intermediate video clip, respectively determining the matching degree of the second video features and the first video features under each preset dimension;

and determining a matching value of a second video and the intermediate video clip according to the matching degree of each preset dimension, and determining the intermediate video clip with the highest matching value as a target video clip matched with the second video.

6. The method of claim 5, wherein the separately determining a matching degree of the second video feature with the first video feature in each predetermined dimension comprises:

calculating the Hamming distance between the second video characteristic and the first video characteristic under each preset dimension;

and determining the matching degree of the second video features and the first video features according to the Hamming distance, wherein the matching degree is inversely related to the Hamming distance.

7. The method according to claim 5, wherein the determining the matching value of the second video and the intermediate video segment according to the matching degree of each preset dimension comprises:

determining a matching value of a second video and the intermediate video clip according to the matching degree of the preset dimension and the weight value of the preset dimension:

S=N1S1+N2S2+N3S3+…+NmSmwherein N is1+N2+N3+…+Nm=1;

Wherein 1 and 2 … m are dimension marks, S1、S2…SmFeature matching degrees, N, in the 1 st and 2 … m dimensions, respectively1、N2、N3…NmIs the weight value of dimension 1, 2 … m.

8. The method of claim 1, wherein the second video is an advertisement video, and wherein the preset dimensions include at least one of an object dimension, a scene dimension, a brand dimension, and a landmark dimension.

9. The method of claim 1, wherein the segmenting the first video comprises:

determining a current tracking target in the first video, and performing target tracking in the first video based on the current tracking target;

determining a video division point according to a first video frame without the current tracking target, updating the current tracking target, and determining a next video division point according to the updated current tracking target;

and segmenting the first video according to the video segmentation point.

10. The method of claim 9, wherein prior to partitioning the first video according to the video partitioning point, further comprising:

determining a color distribution histogram of video frames before and after a video division point based on any video division point;

performing chi-square calculation on color distribution histograms of video frames before and after the video segmentation point;

and when the chi-square calculation result is smaller than the chi-square threshold value, the video segmentation point is cancelled.

11. The method of claim 1, further comprising:

inserting the second video after a target video segment of the first video; alternatively, the first and second electrodes may be,

and sending the first video, the second video and the identification of the target video segment to a client so that the client can insert and play the second video when the first video is played to the end point of the target video segment.

12. A video processing apparatus, comprising:

the segmentation module is used for segmenting the first video to obtain at least two video segments;

the matching module is used for matching based on the feature codes of a second video and the feature codes of the video segments and determining an intermediate video segment matched with the feature codes of the second video;

and the target video segment determining module is used for respectively matching second video features of the second video in a preset dimension with the first video features of the intermediate video segments in the preset dimension, and determining a target video segment matched with the second video according to a matching result in each preset dimension.

13. An electronic device comprising a memory, a processor and a computer program stored on the memory and executable on the processor, characterized in that the processor implements a video processing method according to any of claims 1-11 when executing the computer program.

14. A storage medium containing computer-executable instructions, which when executed by a computer processor implement a video processing method as claimed in any one of claims 1 to 11.

Technical Field

The embodiment of the invention relates to a computer video understanding technology, in particular to a video processing method, a video processing device, electronic equipment and a storage medium.

Background

With the development of information technology, videos gradually become a main information transmission mode, and in the face of massive videos, the manual processing speed is far from enough, and a computer video understanding technology is needed to intelligently analyze video contents, so that the application value of the videos is better explored.

Nowadays, the network video industry is continuously expanding, and network video platforms are more and more developed, on these platforms, people can conveniently watch videos, TV plays, movies, heddles and the like, and the dependence of users on the video platforms is higher. Meanwhile, the video platform can insert advertisements in the video to obtain advertising income, and advertisers can attract a large number of consumers. The quality of the advertisement is particularly important for advertisement delivery on a network video platform. For the content of the advertisement, the advertisement should be story-like and contextual in order to allow the user to have a better viewing experience, and to increase the amount and exposure of the advertisement. There is also a requirement for the duration of the advertisement, and most long advertisements will be clipped to 15 and 30 second formats. Most of the existing advertisement putting modes are forced insertion, the advertisement content is not linked with the video content at the putting point, and the user's repugnance is easily caused, so that the advertisement income of a platform is reduced, and even the brand image of an advertiser is influenced.

Therefore, in the advertisement inserting mode in the prior art, the linking degree of the inserted advertisement and the putting point is poor, and poor experience is brought to the user.

Disclosure of Invention

The embodiment of the invention provides a video processing method and device, electronic equipment and a storage medium, which are used for improving the engagement degree of spot advertisements and advertisement spots and further improving the user experience degree.

In a first aspect, an embodiment of the present invention provides a video processing method, where the method includes:

segmenting a first video to obtain at least two video segments;

matching based on the feature coding of a second video and the feature coding of each video segment, and determining an intermediate video segment matched with the feature coding of the second video;

and respectively matching second video features of the second video in a preset dimension with first video features of the intermediate video segments in the preset dimension, and determining a target video segment matched with the second video according to a matching result in each preset dimension, wherein an end point of the target video segment is an insertion point of the second video.

In a second aspect, an embodiment of the present invention further provides a video processing apparatus, where the video processing apparatus includes:

the segmentation module is used for segmenting the first video to obtain at least two video segments;

the matching module is used for matching based on the feature codes of a second video and the feature codes of the video segments and determining an intermediate video segment matched with the feature codes of the second video;

and the target video segment determining module is used for respectively matching second video features of the second video in a preset dimension with the first video features of the intermediate video segments in the preset dimension, and determining a target video segment matched with the second video according to a matching result in each preset dimension.

In a third aspect, an embodiment of the present invention further provides an electronic device, including a memory, a processor, and a computer program stored on the memory and executable on the processor, where the processor implements a video processing method according to any one of the first aspect when executing the computer program.

In a fourth aspect, embodiments of the present invention also provide a storage medium containing computer-executable instructions, where the computer-executable instructions, when executed by a computer processor, implement a video processing method as described in any one of the first aspect.

In the technical scheme provided by this embodiment, at least two video segments are obtained by segmenting a first video, matching is performed based on feature codes of a second video and feature codes of the video segments, an intermediate video segment matched with the feature codes of the second video is determined to realize coarse matching of the video and an advertisement in a low dimension, then matching is performed respectively with first video features of the intermediate video segments in a preset dimension based on second video features of the second video in the preset dimension, a target video segment matched with the second video is determined according to a matching result in each preset dimension to further improve the matching degree, the problem of poor experience degree brought to a user due to poor splicing degree of advertisement insertion and a delivery point in the prior art is solved, coarse matching is performed through feature codes first, then in the preset dimension, the purpose of finely matching the video and the advertisement is realized, the linking degree of the spot advertisement and the spot advertisement is improved, and the effect of the user experience degree is improved.

Drawings

Fig. 1 is a schematic flowchart of a video processing method according to an embodiment of the present invention;

fig. 2 is a schematic flowchart of a video processing method according to a second embodiment of the present invention;

fig. 3 is a schematic flowchart of a video processing method according to a third embodiment of the present invention;

fig. 4 is a logic diagram of a video processing method according to a third embodiment of the present invention;

fig. 5 is a logic diagram of another video processing method according to a third embodiment of the present invention;

fig. 6 is a logic diagram of another video processing method according to a third embodiment of the present invention;

fig. 7 is a schematic structural diagram of a video processing apparatus according to a fourth embodiment of the present invention;

fig. 8 is a schematic structural diagram of an electronic device according to a fifth embodiment of the present invention.

Detailed Description

The present invention will be described in further detail with reference to the accompanying drawings and examples. It is to be understood that the specific embodiments described herein are merely illustrative of the invention and are not limiting of the invention. It should be further noted that, for the convenience of description, only some of the structures related to the present invention are shown in the drawings, not all of the structures.

18页详细技术资料下载
上一篇:一种医用注射器针头装配设备
下一篇:一种人工交互型智能化电视机顶盒

网友询问留言

已有0条留言

还没有人留言评论。精彩留言会获得点赞!

精彩留言,会给你点赞!

技术分类