CN108989846A - A kind of video transformation assay method, apparatus, equipment and medium - Google Patents
A kind of video transformation assay method, apparatus, equipment and medium Download PDFInfo
- Publication number
- CN108989846A CN108989846A CN201810743286.0A CN201810743286A CN108989846A CN 108989846 A CN108989846 A CN 108989846A CN 201810743286 A CN201810743286 A CN 201810743286A CN 108989846 A CN108989846 A CN 108989846A
- Authority
- CN
- China
- Prior art keywords
- target
- video
- format
- target video
- frame
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
- 230000009466 transformation Effects 0.000 title claims abstract description 20
- 238000003556 assay Methods 0.000 title claims abstract description 18
- 238000004458 analytical method Methods 0.000 claims abstract description 69
- 238000006243 chemical reaction Methods 0.000 claims abstract description 44
- 238000000034 method Methods 0.000 claims abstract description 39
- 238000004590 computer program Methods 0.000 claims description 13
- 238000003860 storage Methods 0.000 claims description 11
- 239000000284 extract Substances 0.000 claims description 10
- 238000012545 processing Methods 0.000 abstract description 10
- 230000000694 effects Effects 0.000 abstract description 4
- 238000010586 diagram Methods 0.000 description 10
- 230000008569 process Effects 0.000 description 9
- 238000004364 calculation method Methods 0.000 description 6
- 238000000605 extraction Methods 0.000 description 5
- 238000012986 modification Methods 0.000 description 5
- 230000004048 modification Effects 0.000 description 5
- 230000008901 benefit Effects 0.000 description 4
- 230000008859 change Effects 0.000 description 4
- 238000005516 engineering process Methods 0.000 description 4
- 238000012512 characterization method Methods 0.000 description 3
- 238000012790 confirmation Methods 0.000 description 3
- 230000006870 function Effects 0.000 description 3
- 238000011161 development Methods 0.000 description 2
- 238000012544 monitoring process Methods 0.000 description 2
- 208000025174 PANDAS Diseases 0.000 description 1
- 208000021155 Paediatric autoimmune neuropsychiatric disorders associated with streptococcal infection Diseases 0.000 description 1
- 240000000220 Panda oleosa Species 0.000 description 1
- 235000016496 Panda oleosa Nutrition 0.000 description 1
- 238000004891 communication Methods 0.000 description 1
- 238000004519 manufacturing process Methods 0.000 description 1
- 230000003287 optical effect Effects 0.000 description 1
- 238000003825 pressing Methods 0.000 description 1
- 238000005086 pumping Methods 0.000 description 1
- 230000000007 visual effect Effects 0.000 description 1
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04N—PICTORIAL COMMUNICATION, e.g. TELEVISION
- H04N21/00—Selective content distribution, e.g. interactive television or video on demand [VOD]
- H04N21/20—Servers specifically adapted for the distribution of content, e.g. VOD servers; Operations thereof
- H04N21/23—Processing of content or additional data; Elementary server operations; Server middleware
- H04N21/234—Processing of video elementary streams, e.g. splicing of video streams or manipulating encoded video stream scene graphs
- H04N21/2343—Processing of video elementary streams, e.g. splicing of video streams or manipulating encoded video stream scene graphs involving reformatting operations of video signals for distribution or compliance with end-user requests or end-user device requirements
- H04N21/234309—Processing of video elementary streams, e.g. splicing of video streams or manipulating encoded video stream scene graphs involving reformatting operations of video signals for distribution or compliance with end-user requests or end-user device requirements by transcoding between formats or standards, e.g. from MPEG-2 to MPEG-4 or from Quicktime to Realvideo
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04N—PICTORIAL COMMUNICATION, e.g. TELEVISION
- H04N21/00—Selective content distribution, e.g. interactive television or video on demand [VOD]
- H04N21/20—Servers specifically adapted for the distribution of content, e.g. VOD servers; Operations thereof
- H04N21/23—Processing of content or additional data; Elementary server operations; Server middleware
- H04N21/234—Processing of video elementary streams, e.g. splicing of video streams or manipulating encoded video stream scene graphs
- H04N21/23418—Processing of video elementary streams, e.g. splicing of video streams or manipulating encoded video stream scene graphs involving operations for analysing video streams, e.g. detecting features or characteristics
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04N—PICTORIAL COMMUNICATION, e.g. TELEVISION
- H04N21/00—Selective content distribution, e.g. interactive television or video on demand [VOD]
- H04N21/40—Client devices specifically adapted for the reception of or interaction with content, e.g. set-top-box [STB]; Operations thereof
- H04N21/43—Processing of content or additional data, e.g. demultiplexing additional data from a digital video stream; Elementary client operations, e.g. monitoring of home network or synchronising decoder's clock; Client middleware
- H04N21/44—Processing of video elementary streams, e.g. splicing a video clip retrieved from local storage with an incoming video stream or rendering scenes according to encoded video stream scene graphs
- H04N21/44008—Processing of video elementary streams, e.g. splicing a video clip retrieved from local storage with an incoming video stream or rendering scenes according to encoded video stream scene graphs involving operations for analysing video streams, e.g. detecting features or characteristics in the video stream
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04N—PICTORIAL COMMUNICATION, e.g. TELEVISION
- H04N21/00—Selective content distribution, e.g. interactive television or video on demand [VOD]
- H04N21/40—Client devices specifically adapted for the reception of or interaction with content, e.g. set-top-box [STB]; Operations thereof
- H04N21/43—Processing of content or additional data, e.g. demultiplexing additional data from a digital video stream; Elementary client operations, e.g. monitoring of home network or synchronising decoder's clock; Client middleware
- H04N21/44—Processing of video elementary streams, e.g. splicing a video clip retrieved from local storage with an incoming video stream or rendering scenes according to encoded video stream scene graphs
- H04N21/4402—Processing of video elementary streams, e.g. splicing a video clip retrieved from local storage with an incoming video stream or rendering scenes according to encoded video stream scene graphs involving reformatting operations of video signals for household redistribution, storage or real-time display
- H04N21/440218—Processing of video elementary streams, e.g. splicing a video clip retrieved from local storage with an incoming video stream or rendering scenes according to encoded video stream scene graphs involving reformatting operations of video signals for household redistribution, storage or real-time display by transcoding between formats or standards, e.g. from MPEG-2 to MPEG-4
Landscapes
- Engineering & Computer Science (AREA)
- Multimedia (AREA)
- Signal Processing (AREA)
- Two-Way Televisions, Distribution Of Moving Picture Or The Like (AREA)
Abstract
It includes: acquisition first time interval that the present invention, which discloses a kind of video transformation assay method, apparatus, equipment and medium, method,;During downloading target video and decoding the target video or after decoding the target video, target frame is extracted in the frame after decoding the target video according to the first time interval;Rgb format is converted by yuv format by the format of the target frame;To conversion of other frames without yuv format to rgb format in addition to the target frame;Video analysis is carried out to the target frame after conversion.Method and apparatus provided by the present application can solve video analysis in the prior art, existing computationally intensive, the slow technical problem of processing speed.Realize the technical effect of the efficiency and speed that improve video analysis.
Description
Technical field
The present invention relates to field of computer technology more particularly to a kind of video transformation assay method, apparatus, equipment and Jie
Matter.
Background technique
Currently, with the progress of network communication technology and the speed-raising of broadband network, network direct broadcasting has been obtained more and more
Development and application.In order to guarantee the benign development of live streaming and obtain the data information of live streaming process, monitoring live streaming view is generally required
Frequency whether there is undesirable video image, or analysis obtains the critical data in live video, for platform is broadcast live
Take corrective measure.This is required by during live streaming or after obtaining video, carrying out video analysis to carry out.
Still existing video is analyzed however, either synchronizing video analysis during live streaming, is all needed
It expends more resource to be decoded, convert and analyze etc. and calculate, computationally intensive, processing speed is also slow.
As it can be seen that video analysis in the prior art, there are computationally intensive, the slow technical problems of processing speed.
Summary of the invention
The present invention provides a kind of video transformation assay method, apparatus, equipment and medium, to solve view in the prior art
Frequency analysis, existing computationally intensive, the slow technical problem of processing speed.
In a first aspect, the present invention provides a kind of video transformation assay methods, comprising:
Obtain first time interval;
During downloading target video and decoding the target video or after decoding the target video, according to institute
It states first time interval and extracts target frame in the frame after decoding the target video;
Rgb format is converted by yuv format by the format of the target frame;To other frames in addition to the target frame not into
Row yuv format to rgb format conversion;
Video analysis is carried out to the target frame after conversion.
Optionally, the acquisition first time interval, comprising: determine the target scene type of the target video;According to
The corresponding relationship of preset scene type and time interval determined between the target scene type corresponding first time
Every.
Optionally, the target scene type of the determination target video includes: the attribute according to the target video
Preset scene identity in information, determines the scene type of the target video;Alternatively, downloading described in target video and decoding
During target video, the present frame of the newest decoded target video of comparison and preset scene characteristic, according to comparison result
Determine the scene type of the target video.
Optionally, the format by the target frame is converted into rgb format by yuv format, comprising:
Rgb format is converted by yuv format by the format of the target frame according to the following formula:
Wherein, R is the R channel parameters value of rgb format, and G is the G channel parameters value of rgb format, and B is that the B of rgb format is logical
Road parameter value;Y is the Y channel parameters value of yuv format, and U is the U channel parameters value of yuv format, and V is that the channel V of yuv format is joined
Numerical value.
Second aspect provides a kind of video transformation assay device, comprising:
Module is obtained, for obtaining first time interval;
Abstraction module, for during downloading target video and decoding the target video or in the decoding target
After video, target frame is extracted in the frame after decoding the target video according to the first time interval;
Conversion module, for converting rgb format by yuv format for the format of the target frame;To except the target frame
Conversion of other the outer frames without yuv format to rgb format;
Analysis module, for carrying out video analysis to the target frame after conversion.
Optionally, the acquisition module is used for: determining the target scene type of the target video;According to preset scene
The corresponding relationship of type and time interval determines the corresponding first time interval of the target scene type.
Optionally, the acquisition module is also used to: according to scene identity preset in the attribute information of the target video,
Determine the scene type of the target video;Alternatively, being compared during downloading target video and decoding the target video
The present frame of newest decoded target video and preset scene characteristic, the scene of the target video is determined according to comparison result
Type.
Optionally, the conversion module is also used to:
Rgb format is converted by yuv format by the format of the target frame according to the following formula:
Wherein, R is the R channel parameters value of rgb format, and G is the G channel parameters value of rgb format, and B is that the B of rgb format is logical
Road parameter value;Y is the Y channel parameters value of yuv format, and U is the U channel parameters value of yuv format, and V is that the channel V of yuv format is joined
Numerical value.
The third aspect, provides a kind of electronic equipment, including memory, processor and storage on a memory and can handled
The computer program run on device, the processor realize method described in first aspect when executing described program.
Fourth aspect provides a kind of computer readable storage medium, is stored thereon with computer program, and the program is processed
Method described in first aspect is realized when device executes.
The one or more technical solutions provided in the embodiment of the present invention, have at least the following technical effects or advantages:
Method, apparatus, equipment and medium provided by the embodiments of the present application, according to first time interval from decoding the target
Target frame is extracted in frame after video;Conversion and video analysis of the yuv format to rgb format only are carried out to the target frame of extraction,
Conversion and analysis to other frames in addition to the target frame without format, thus the biggish meter reduced in video analysis
Calculation amount and calculating time, effectively raise the efficiency of video analysis.
The above description is only an overview of the technical scheme of the present invention, in order to better understand the technical means of the present invention,
And it can be implemented in accordance with the contents of the specification, and in order to allow above and other objects of the present invention, feature and advantage can
It is clearer and more comprehensible, the followings are specific embodiments of the present invention.
Detailed description of the invention
In order to more clearly explain the embodiment of the invention or the technical proposal in the existing technology, to embodiment or will show below
There is attached drawing needed in technical description to be briefly described, it should be apparent that, the accompanying drawings in the following description is this hair
Bright some embodiments for those of ordinary skill in the art without creative efforts, can be with root
Other attached drawings are obtained according to these attached drawings.
Fig. 1 is the flow chart of video transformation assay method in the embodiment of the present invention;
Fig. 2 is the structural schematic diagram of video transformation assay device in the embodiment of the present invention;
Fig. 3 is the structural schematic diagram of equipment in the embodiment of the present invention;
Fig. 4 is the structural schematic diagram of medium in the embodiment of the present invention.
Specific embodiment
The embodiment of the present application solves existing skill by providing a kind of video transformation assay method, apparatus, equipment and medium
Video analysis in art, existing computationally intensive, the slow technical problem of processing speed.Realize improve video analysis efficiency and
The technical effect of speed.
Technical solution in the embodiment of the present application, general thought are as follows:
Obtain first time interval;During downloading target video and decoding the target video, according to described the
One time interval extracts target frame in the frame after decoding the target video;The format of the target frame is turned by yuv format
Turn to rgb format;To conversion of other frames without yuv format to rgb format in addition to the target frame;To the mesh after conversion
It marks frame and carries out video analysis.
The above method extracts target frame from the frame after the decoding target video according to first time interval;Only to extraction
Target frame carry out conversion and video analysis of the yuv format to rgb format, to other frames in addition to the target frame without lattice
The conversion and analysis of formula, so that the biggish calculation amount reduced in video analysis and calculating time, effectively raise video
The efficiency of analysis.
In order to make the object, technical scheme and advantages of the embodiment of the invention clearer, below in conjunction with the embodiment of the present invention
In attached drawing, technical scheme in the embodiment of the invention is clearly and completely described, it is clear that described embodiment is
A part of the embodiment of the present invention, instead of all the embodiments.Based on the embodiments of the present invention, those of ordinary skill in the art
Every other embodiment obtained without creative efforts, shall fall within the protection scope of the present invention.
Embodiment one
The present embodiment provides a kind of video transformation assay methods, as shown in Figure 1, comprising:
Step S101 obtains first time interval;
Step S102 during downloading target video and decoding the target video or is decoding the target video
Afterwards, target frame is extracted in the frame according to the first time interval after decoding the target video;
Step S103 converts rgb format by yuv format for the format of the target frame;To in addition to the target frame
Conversion of other frames without yuv format to rgb format;
Step S104 carries out video analysis to the target frame after conversion.
It should be noted that the method provided in the present embodiment both can be used for the real-time video point during live video
Analysis, can be used for the video analysis of the video of historical storage, this is not restricted.
The method can be applied to single server, server group or Cloud Server, and this is not restricted.
Below with reference to Fig. 1, the specific implementation step of method provided by the present application is described in detail:
Before executing step S101, it can also first judge whether target video belongs to the default view for showing key message
Frequency type, if it is just using video transformation assay method provided by the embodiments of the present application.
Specifically, in certain video types, continuously display there can be key message, for such video, can pass through
Key message on decoded image tends not to continue change come the key message for carrying out video analysis, however showing on video
Change, therefore to the video analysis scheme that such video is converted using the extraction frame of the present embodiment, video analysis can not only be improved
Efficiency can also avoid the occurrence of analysis and omit.
For example, in killing class game, often on the picture of game it is continuously display it is current we kill time
Several and other side to kill number, then the number that kills shown is the key message, such kill game belong to it is described pre-
Setting video type.
In the embodiment of the present application, judge whether target video belongs to the side for showing the default video type of key message
There are many methods, for example, can modify the category of the video by staff after manual confirmation video is default video type
Property information, preset mark is added wherein, then can be preset in the attribute information according to the target video in server
Mark, show the default video type of key message to judge whether the target video belongs to.
It is of course also possible to the partial frame of target video is decoded in advance, it is preset by being combined to decoded frame
The characteristics of image of key message carries out Image Feature Matching to judge whether target video belongs to and show the default of key message
Video type, this is not restricted.
It is of course also possible to not make type judgement, it is all made of video transformation assay method provided in this embodiment.
Firstly, executing step S101, first time interval is obtained.
In the embodiment of the present application, the target scene type of the target video can be first determined;According to preset scene
The corresponding relationship of type and time interval determines the corresponding first time interval of the target scene type.
Specifically, not identical to the switching average frequency of different scenes often its key message, when corresponding first
Between be spaced it is also not identical.For example, it kills killing for class game live streaming and is spaced first time interval that is often longer, therefore being arranged
Longer, the interval of playing a card of chess and card games live streaming is often shorter, therefore the first time interval being arranged is shorter.It specifically can be by working
Personnel pre-establish corresponding table of the scene type with time interval, obtain first time interval by tabling look-up.And target scene class
The determination of type can preset scene identity in the attribute information according to the target video, determine the scene of the target video
Type;Alternatively, comparing working as newest decoded target video during downloading target video and decoding the target video
Previous frame and preset scene characteristic, the scene type of the target video are determined according to comparison result, herein with no restrictions.
Then, step S102 is executed, during downloading target video and decoding the target video or in decoding institute
After stating target video, target frame is extracted in the frame after decoding the target video according to the first time interval.
In the embodiment of the present application, different according to the classification of video, the process for extracting target frame is not also identical, illustrates below
It is illustrated:
The first, live video.
When the target video is live video, during server downloads live video stream from main broadcaster end, meeting
Side foradownloaded video, side decoding video, side are carried out the extraction of target frame by preset first time interval to just-downloaded video, with
Multiple target frames for efficiently extracting during live streaming carry out real-time format conversion and video analysis.
Second, historical storage video.
It, can be directly to every in decoded video when the target video is video stored on server
Frame is traversed, and according to the time that frame every in the target video generates, extracts multiple mesh by preset first time interval
Frame is marked to carry out format conversion and video analysis.
In the embodiment of the present application, after extracting multiple target frames, format conversion and video point only are carried out to target frame
Analysis, remaining frame is no longer dealt with, and to greatly reduce calculation amount, improves the speed of video analysis.
Then, step S103 and S104 are executed, rgb format is converted by yuv format by the format of the target frame;To removing
Conversion of other frames without yuv format to rgb format outside the target frame;Video point is carried out to the target frame after conversion
Analysis.
It specifically,, can also be by the format of target frame from yuv format (YUV for the ease of analysis after extracting target frame
Refer to brightness parameter and the separately shown pixel format of coloration parameter) it is converted into rgb format (color mode), then to format conversion
Target frame afterwards carries out video analysis and output analysis result.
In the specific implementation process, RGB lattice can be converted by yuv format by the format of the target frame according to the following formula
Formula:
Wherein, R is the R channel parameters value of rgb format, and G is the G channel parameters value of rgb format, and B is that the B of rgb format is logical
Road parameter value;Y is the Y channel parameters value of yuv format, and U is the U channel parameters value of yuv format, and V is that the channel V of yuv format is joined
Numerical value.
Scheme provided in this embodiment is understood for the ease of whole, names a specific example, described in server first obtains
Then the target video is downloaded in the stream address of target video.During downloading, the frame downloaded is decoded.It is pressing
Preset first time interval extracts decoded frame, obtains target frame, only carries out yuv format to target frame and is converted into
Then rgb format carries out video analysis and analysis result output to the target frame after conversion again.
In one embodiment, can also be arranged according to formula R=Y, G=Y and B=Y, it will be in the target video
The format of frame is converted into rgb format by yuv format;Wherein, R is the R channel parameters value of rgb format, and G is the channel G of rgb format
Parameter value, B are the channel B parameter value of rgb format;Y is the Y channel parameters value of yuv format, and U is the U channel parameters of yuv format
Value, V are the V channel parameters value of yuv format.
Further, it can also first judge whether target video belongs to the single scene of color, if it is just using formula R=
Y, G=Y and B=Y carry out video conversion.
Specific judgment method can there are many, be set forth below for two kinds:
The first, preset attribute information.
Identify whether target video is the single scene of color, then modifies target video in this way in advance by staff
The color identification of attribute information determines if preset color identification in attribute information of the server according to the target video
The target video is the single scene of color, then according to formula R=Y, G=Y and B=Y, by the frame in the target video
Format is converted into rgb format by yuv format.
For example, staff sets 0 for the color identification in target video attribute information and is expressed as color list
The color identification in target video attribute information is set 1 scene visual for indicating not single for color by one scene video
Frequently.Server can determine if to convert using video provided in this embodiment according to the value of color identification in attribute information
Method.
Second, aspect ratio pair.
Preset multiple scene characteristics with the single video matching of color, compare decoded target video with it is preset
Scene characteristic determines that the target video is the single scene of color according to comparison result, then according to formula R=Y, G=Y and B
=Y converts rgb format by yuv format for the format of the frame in the target video.
For example, being arranged has with the scene characteristic of the single video matching of color: checkerboard features image, sieve characteristic pattern
Picture, panda characteristic image.Server compares decoded image and preset scene characteristic, if there is matched feature, then really
The fixed target video is the single scene of color, determines and uses video method for transformation provided in this embodiment.
In another embodiment, consider to extract target frame to be converted and be analyzed it is possible that omitting.In order to
Convenient for analysis, can also video analysis be carried out to the target frame after format conversion, generate analysis feedback information.It is anti-according to the analysis
Feedforward information monitors whether that there are identification point omissions.It is omitted if there is identification point, then switches transformation mode, to what is currently downloaded
Each frame of the target video is converted, and carries out video analysis to each frame after conversion.
The generating process of the analysis feedback information, which may is that, extracts preset identification point diagram in the decoded target frame
As information, and judge whether the identification point image information is continuous;If it is continuous, then generating characterization, there is no identifications
The analysis feedback information that point is omitted;If not continuous, then generating characterization, there are the analysis feedback informations that identification point is omitted.
For example, in killing class game, often on the picture of game it is continuously display it is current we kill time
Number, then it is to identify point image that display, which kills the image of number position, can extract identification point by analyzing the parts of images
Image information specifically kills number.If without identification point omit, the identification point image information (killing number) should be by
The arrangement of continuous number as 1,2,3,4,5 ..., be directly after 3 if analysis finds the identification point image information
5, then it is the information near 4 that confirmation, which misses and kills number, and there are identification point omissions for confirmation, and generating characterization, there are identification point omissions
Analysis feedback information.
Certainly, in the specific implementation process, above-mentioned identification point image information is continuous, not only can be the company referred to numerically
It is continuous, it is also possible to continuous on letter, or comes by preset continuous information table continuous, this is not restricted.
It can preset, when there are identification point omission, setting analysis feedback information is the characters such as 0 or N, and there is no know
Not Dian when omitting, setting analysis feedback information is the characters such as 1 or Y.Therefore it can be supervised by analyzing the particular content of feedback information
Control is omitted with the presence or absence of identification point.
It in another embodiment, can also be before executing step S102, in the process for downloading the target video
In, the target video of downloading is updated storage to caching, makes to be stored with current time in the caching past to current time
The target video downloaded in preceding preset duration;Then the target frame that the target video is extracted by first time interval, to described
Target frame carries out format conversion, and only carries out video analysis to the target frame after conversion, generates analysis feedback information;According to
The analysis feedback information monitors whether that there are identification point omissions;It is omitted if there is identification point, then extracts and deposited in the caching
The buffered video section of storage is decoded each frame of the buffered video section, video format conversion and video analysis, and clear
The empty caching.
In the embodiment of the present application, the caching to the video in downloading process is carried out using buffer register buffer,
It is realized in caching by fifo and persistently preserves the target video downloaded in current time to current time forward preset duration.Institute
Stating preset duration can be 1 minute or 40 seconds etc., and this is not restricted.
For example, it is assumed that preset duration is 1 minute, is currently downloading the 25th minute video frame of target video,
24-25 minutes video frames of drop are then stored in caching.With the continuation of downloading, earliest partial video can be removed in caching,
It is always ensured that and is cached with the video away from modern 1 minute duration.
After monitoring discovery is omitted there are identification point, in order to make up certain identification point information, just extract existing in caching
Video frame, and each frame is decoded, video format conversion and analysis.Due to equal to each frame in the caching
Transformation assay has been carried out, then can empty current cache, to save spatial cache and avoid repeating to convert.After emptying the cache,
It will continue to store the video for currently continuing downloading by aforementioned cache way in caching, make to be stored with current time extremely in the caching
The target video of the current time interior downloading of preset duration forward.
Specifically, target frame is extracted in the frame according to first time interval after decoding the target video;Only to pumping
The target frame that takes carries out conversion and video analysis of the yuv format to rgb format, to other frames in addition to the target frame without
The conversion and analysis of format, so that the biggish calculation amount reduced in video analysis and calculating time, effectively raise view
The efficiency of frequency analysis.
Based on the same inventive concept, present invention also provides dresses corresponding with video transformation assay method in embodiment one
It sets, detailed in Example two.
Embodiment two
A kind of video transformation assay device is present embodiments provided, as shown in Fig. 2, the device includes:
Module 201 is obtained, for obtaining first time interval;
Abstraction module 202, for during downloading target video and decoding the target video or described in the decoding
After target video, target frame is extracted in the frame after decoding the target video according to the first time interval;
Conversion module 203, for converting rgb format by yuv format for the format of the target frame;To except the target
Conversion of other frames without yuv format to rgb format outside frame;
Analysis module 204, for carrying out video analysis to the target frame after conversion.
In the embodiment of the present application, the acquisition module 201 is also used to: determining the target scene class of the target video
Type;According to the corresponding relationship of preset scene type and time interval, the target scene type corresponding described first is determined
Time interval.
In the embodiment of the present application, the acquisition module 201 is also used to: according to pre- in the attribute information of the target video
If scene identity, determine the scene type of the target video;Alternatively, in downloading target video and decoding the target video
During, the present frame of the newest decoded target video of comparison and preset scene characteristic, according to comparison result determination
The scene type of target video.
In the embodiment of the present application, the conversion module 203 is also used to:
Rgb format is converted by yuv format by the format of the target frame according to the following formula:
Wherein, R is the R channel parameters value of rgb format, and G is the G channel parameters value of rgb format, and B is that the B of rgb format is logical
Road parameter value;Y is the Y channel parameters value of yuv format, and U is the U channel parameters value of yuv format, and V is that the channel V of yuv format is joined
Numerical value.
By the device that the embodiment of the present invention two is introduced, filled used by the method to implement the embodiment of the present invention one
It sets, so based on the method that the embodiment of the present invention one is introduced, the affiliated personnel in this field can understand the specific structure of the device
And deformation, so details are not described herein.Device used by the method for all embodiment of the present invention one belongs to the present invention and is intended to
The range of protection.
Based on the same inventive concept, the embodiment of the invention also provides the corresponding electronic equipments of method in embodiment one to implement
Example, is shown in embodiment three.
Embodiment three
The present embodiment provides a kind of electronic equipment, as shown in figure 3, including memory 310, processor 320 and being stored in
On reservoir 310 and the computer program 311 that can run on the processor 320 can when processor 320 executes computer program 311
To realize any embodiment in embodiment one.
Since the electronic equipment that the present embodiment is introduced is equipment used by method in implementation the embodiment of the present application one, therefore
And the method introduced based on the embodiment of the present application one, those skilled in the art can understand the electronic equipment of the present embodiment
Specific embodiment and its various change form, so how to be realized in the embodiment of the present application at this for the electronic equipment
Method be no longer discussed in detail.As long as those skilled in the art implement to set used by the method in the embodiment of the present application
It is standby, belong to the range to be protected of the application.
Based on the same inventive concept, this application provides the corresponding storage medium of embodiment one, detailed in Example four.
Example IV
The present embodiment provides a kind of computer readable storage mediums 400, as shown in figure 4, being stored thereon with computer program
411, when which is executed by processor, one any embodiment of embodiment may be implemented.
The technical solution provided in the embodiment of the present application, has at least the following technical effects or advantages:
Method, apparatus, equipment and medium provided by the embodiments of the present application, according to first time interval from decoding the target
Target frame is extracted in frame after video;Conversion and video analysis of the yuv format to rgb format only are carried out to the target frame of extraction,
Conversion and analysis to other frames in addition to the target frame without format, thus the biggish meter reduced in video analysis
Calculation amount and calculating time, effectively raise the efficiency of video analysis.
It should be understood by those skilled in the art that, the embodiment of the present invention can provide as method, system or computer program
Product.Therefore, complete hardware embodiment, complete software embodiment or reality combining software and hardware aspects can be used in the present invention
Apply the form of example.Moreover, it wherein includes the computer of computer usable program code that the present invention, which can be used in one or more,
The computer program implemented in usable storage medium (including but not limited to magnetic disk storage, CD-ROM, optical memory etc.) produces
The form of product.
The present invention be referring to according to the method for the embodiment of the present invention, the process of equipment (system) and computer program product
Figure and/or block diagram describe.It should be understood that every one stream in flowchart and/or the block diagram can be realized by computer program instructions
The combination of process and/or box in journey and/or box and flowchart and/or the block diagram.It can provide these computer programs
Instruct the processor of general purpose computer, special purpose computer, Embedded Processor or other programmable data processing devices to produce
A raw machine, so that being generated by the instruction that computer or the processor of other programmable data processing devices execute for real
The device for the function of being specified in present one or more flows of the flowchart and/or one or more blocks of the block diagram.
These computer program instructions, which may also be stored in, is able to guide computer or other programmable data processing devices with spy
Determine in the computer-readable memory that mode works, so that it includes referring to that instruction stored in the computer readable memory, which generates,
Enable the manufacture of device, the command device realize in one box of one or more flows of the flowchart and/or block diagram or
The function of being specified in multiple boxes.
These computer program instructions also can be loaded onto a computer or other programmable data processing device, so that counting
Series of operation steps are executed on calculation machine or other programmable devices to generate computer implemented processing, thus in computer or
The instruction executed on other programmable devices is provided for realizing in one or more flows of the flowchart and/or block diagram one
The step of function of being specified in a box or multiple boxes.
Although preferred embodiments of the present invention have been described, it is created once a person skilled in the art knows basic
Property concept, then additional changes and modifications may be made to these embodiments.So it includes excellent that the following claims are intended to be interpreted as
It selects embodiment and falls into all change and modification of the scope of the invention.
Obviously, those skilled in the art can carry out various modification and variations without departing from this hair to the embodiment of the present invention
The spirit and scope of bright embodiment.In this way, if these modifications and variations of the embodiment of the present invention belong to the claims in the present invention
And its within the scope of equivalent technologies, then the present invention is also intended to include these modifications and variations.
Claims (10)
1. a kind of video transformation assay method characterized by comprising
Obtain first time interval;
During downloading target video and decoding the target video or after decoding the target video, according to described the
One time interval extracts target frame in the frame after decoding the target video;
Rgb format is converted by yuv format by the format of the target frame;To other frames in addition to the target frame without
Yuv format to rgb format conversion;
Video analysis is carried out to the target frame after conversion.
2. the method as described in claim 1, which is characterized in that the acquisition first time interval, comprising:
Determine the target scene type of the target video;
According to the corresponding relationship of preset scene type and time interval, the target scene type corresponding described first is determined
Time interval.
3. method according to claim 2, which is characterized in that the target scene type packet of the determination target video
It includes:
According to scene identity preset in the attribute information of the target video, the scene type of the target video is determined;Or
Person,
During downloading target video and decoding the target video, compare the present frame of newest decoded target video with
Preset scene characteristic determines the scene type of the target video according to comparison result.
4. the method as described in claim 1, which is characterized in that the format by the target frame is converted by yuv format
Rgb format, comprising:
Rgb format is converted by yuv format by the format of the target frame according to the following formula:
R=Y+1.4075* (V-128)
G=Y-0.3455* (U-128) -0.7169* (V-128)
B=Y+1.779* (U-128)
Wherein, R is the R channel parameters value of rgb format, and G is the G channel parameters value of rgb format, and B is that the channel B of rgb format is joined
Numerical value;Y is the Y channel parameters value of yuv format, and U is the U channel parameters value of yuv format, and V is the V channel parameters value of yuv format.
5. a kind of video transformation assay device characterized by comprising
Module is obtained, for obtaining first time interval;
Abstraction module, for during downloading target video and decoding the target video or in the decoding target video
Afterwards, target frame is extracted in the frame according to the first time interval after decoding the target video;
Conversion module, for converting rgb format by yuv format for the format of the target frame;To in addition to the target frame
Conversion of other frames without yuv format to rgb format;
Analysis module, for carrying out video analysis to the target frame after conversion.
6. device as claimed in claim 5, which is characterized in that the acquisition module is used for:
Determine the target scene type of the target video;
According to the corresponding relationship of preset scene type and time interval, the target scene type corresponding described first is determined
Time interval.
7. device as claimed in claim 6, which is characterized in that the acquisition module is also used to:
According to scene identity preset in the attribute information of the target video, the scene type of the target video is determined;Or
Person,
During downloading target video and decoding the target video, compare the present frame of newest decoded target video with
Preset scene characteristic determines the scene type of the target video according to comparison result.
8. device as claimed in claim 5, which is characterized in that the conversion module is also used to:
Rgb format is converted by yuv format by the format of the target frame according to the following formula:
R=Y+1.4075* (V-128)
G=Y-0.3455* (U-128) -0.7169* (V-128)
B=Y+1.779* (U-128)
Wherein, R is the R channel parameters value of rgb format, and G is the G channel parameters value of rgb format, and B is that the channel B of rgb format is joined
Numerical value;Y is the Y channel parameters value of yuv format, and U is the U channel parameters value of yuv format, and V is the V channel parameters value of yuv format.
9. a kind of electronic equipment including memory, processor and stores the calculating that can be run on a memory and on a processor
Machine program, which is characterized in that the processor realizes claim 1-4 any method when executing described program.
10. a kind of computer readable storage medium, is stored thereon with computer program, which is characterized in that the program is by processor
Claim 1-4 any method is realized when execution.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201810743286.0A CN108989846A (en) | 2018-07-09 | 2018-07-09 | A kind of video transformation assay method, apparatus, equipment and medium |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201810743286.0A CN108989846A (en) | 2018-07-09 | 2018-07-09 | A kind of video transformation assay method, apparatus, equipment and medium |
Publications (1)
Publication Number | Publication Date |
---|---|
CN108989846A true CN108989846A (en) | 2018-12-11 |
Family
ID=64537515
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201810743286.0A Pending CN108989846A (en) | 2018-07-09 | 2018-07-09 | A kind of video transformation assay method, apparatus, equipment and medium |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN108989846A (en) |
Cited By (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN110740344A (en) * | 2019-09-17 | 2020-01-31 | 浙江大华技术股份有限公司 | Video extraction method and related device |
CN112055212A (en) * | 2020-08-24 | 2020-12-08 | 深圳市青柠互动科技开发有限公司 | System and method for centralized analysis and processing of multiple paths of videos |
CN113365018A (en) * | 2020-03-06 | 2021-09-07 | 杭州海康威视数字技术股份有限公司 | Period adjusting method, device and equipment |
Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN106331849A (en) * | 2016-09-14 | 2017-01-11 | 北京金山安全软件有限公司 | Video image processing method and device and electronic equipment |
CN107040795A (en) * | 2017-04-27 | 2017-08-11 | 北京奇虎科技有限公司 | The monitoring method and device of a kind of live video |
CN107172481A (en) * | 2017-05-09 | 2017-09-15 | 深圳市炜光科技有限公司 | Video segment splices method of combination and system |
-
2018
- 2018-07-09 CN CN201810743286.0A patent/CN108989846A/en active Pending
Patent Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN106331849A (en) * | 2016-09-14 | 2017-01-11 | 北京金山安全软件有限公司 | Video image processing method and device and electronic equipment |
CN107040795A (en) * | 2017-04-27 | 2017-08-11 | 北京奇虎科技有限公司 | The monitoring method and device of a kind of live video |
CN107172481A (en) * | 2017-05-09 | 2017-09-15 | 深圳市炜光科技有限公司 | Video segment splices method of combination and system |
Cited By (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN110740344A (en) * | 2019-09-17 | 2020-01-31 | 浙江大华技术股份有限公司 | Video extraction method and related device |
CN110740344B (en) * | 2019-09-17 | 2022-10-04 | 浙江大华技术股份有限公司 | Video extraction method and device and storage device |
CN113365018A (en) * | 2020-03-06 | 2021-09-07 | 杭州海康威视数字技术股份有限公司 | Period adjusting method, device and equipment |
CN113365018B (en) * | 2020-03-06 | 2022-07-01 | 杭州海康威视数字技术股份有限公司 | Period adjusting method, device and equipment |
CN112055212A (en) * | 2020-08-24 | 2020-12-08 | 深圳市青柠互动科技开发有限公司 | System and method for centralized analysis and processing of multiple paths of videos |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN109089126A (en) | A kind of video analysis method, apparatus, equipment and medium | |
CN108989846A (en) | A kind of video transformation assay method, apparatus, equipment and medium | |
CN109120995B (en) | Video cache analysis method, device, equipment and medium | |
CN107801093B (en) | Video rendering method and device, computer equipment and readable storage medium | |
WO2018133825A1 (en) | Method for processing video images in video call, terminal device, server, and storage medium | |
CN105760238B (en) | The treating method and apparatus and system of graphics instructional data | |
JP6015267B2 (en) | Image processing apparatus, image processing program, computer-readable recording medium recording the same, and image processing method | |
CN113297937A (en) | Image processing method, device, equipment and medium | |
KR102082766B1 (en) | Method and apparatus for distinguishing objects | |
CN106658107A (en) | Multi-path multi-mode image display method | |
CN113163202B (en) | Image frame compression method and device | |
CN110414596B (en) | Video processing method, video processing device, model training method, model training device, storage medium and electronic device | |
CN110796689B (en) | Video processing method, electronic device and storage medium | |
CN109120911B (en) | A kind of video method for transformation, device, equipment and medium | |
CN112565887A (en) | Video processing method, device, terminal and storage medium | |
JP5817052B2 (en) | Information processing apparatus, control method, program, and recording medium | |
CN108924575A (en) | A kind of video decoding and analyzing method, device, equipment and medium | |
CN116071623A (en) | Model training method, image-based processing method, device, equipment and medium | |
CN115205163A (en) | Method, device and equipment for processing identification image and storage medium | |
JP2022534620A (en) | Client-side forensic watermarking device, system and method | |
CN104240191A (en) | Batch-image enhancement processing method | |
CN105631866B (en) | A kind of extraction calculation optimization method of the foreground target method based on heterogeneous platform | |
JP6251651B2 (en) | Digital watermark information embedding system, digital watermark information embedding method, and digital watermark information embedding program | |
CN106599882A (en) | Body sensing motion identification device | |
CN109391817A (en) | Data texturing transmission method and device |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
RJ01 | Rejection of invention patent application after publication |
Application publication date: 20181211 |
|
RJ01 | Rejection of invention patent application after publication |