CN108171153A - Scene change detection method, equipment and computer readable storage medium - Google Patents
Scene change detection method, equipment and computer readable storage medium Download PDFInfo
- Publication number
- CN108171153A CN108171153A CN201711439708.7A CN201711439708A CN108171153A CN 108171153 A CN108171153 A CN 108171153A CN 201711439708 A CN201711439708 A CN 201711439708A CN 108171153 A CN108171153 A CN 108171153A
- Authority
- CN
- China
- Prior art keywords
- histogram
- value
- peak value
- time
- picture
- 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.)
- Granted
Links
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06V—IMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
- G06V20/00—Scenes; Scene-specific elements
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06V—IMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
- G06V10/00—Arrangements for image or video recognition or understanding
- G06V10/40—Extraction of image or video features
- G06V10/50—Extraction of image or video features by performing operations within image blocks; by using histograms, e.g. histogram of oriented gradients [HoG]; by summing image-intensity values; Projection analysis
Abstract
The invention discloses a kind of scene change detection method, including:Acquisition currently needs the detect first detection picture and the second detection picture, corresponding first spatial histogram of generation the first detection picture and the corresponding second space histogram of the second detection picture;Calculate the similar value of first spatial histogram and the second space histogram;According to the similar value and preset threshold range, determine that the first detection picture detects whether picture is Same Scene with described second.The invention also discloses a kind of scene change detection equipment and computer readable storage mediums.The present invention realizes a kind of efficient scene change detection method, overcome the problem of traditional algorithm detection efficiency is low, the histogram of time dimension is converted to simultaneously also by the histogram of Spatial Dimension, detection efficiency is further increased, realizes the efficiently and in real time detection switched to high pixel video Scene.
Description
Technical field
The present invention relates to a kind of technical field of image processing more particularly to scene change detection method, equipment and computers
Readable storage medium storing program for executing.
Background technology
Video scene change detection is the basic technology of video automatic segmentation, many relevant Video Applications of scene such as videos
Abstract and auto color adjusting all rely on quickly and effectively scene-detection algorithms.At present, many effective algorithms utilize non-complete
Office piecemeal image information and the relevant feature of non-color such as edge detection come improve recall rate and reduce false drop rate.However,
The algorithm of the current piecemeal and characteristics of image all inefficiency of extraction complexity, can not meet current high pixel video and examine in real time
The needs of survey.
The above is only used to facilitate the understanding of the technical scheme, and is not represented and is recognized that the above is existing skill
Art.
Invention content
It is a primary object of the present invention to provide a kind of scene change detection method, equipment and computer-readable storage medium
Matter, it is intended to the technical issues of solving efficiently detect current high pixel video in real time.
To achieve the above object, the present invention provides a kind of scene change detection method, the scene change detection method packet
Include following steps:
Acquisition currently needs the detect first detection picture and the second detection picture, and generation the first detection picture corresponds to
The first spatial histogram and the corresponding second space histogram of the second detection picture;
Calculate the similar value of first spatial histogram and the second space histogram;
According to the similar value and preset threshold range, determine that the first detection picture is with the described second detection picture
No is Same Scene.
In one embodiment, it is described according to the similar value and preset threshold range, determine the first detection picture
Detect that the step of whether picture is Same Scene includes with described second:
When the similar value is within preset threshold range, first spatial histogram is converted as first time Nogata
Figure, the second space histogram are the second time histrogram;
Obtain corresponding first extreme point of the first time histogram, corresponding second pole of second time histrogram
Value point;
According to first extreme point and secondary extremal point, the first detection picture and the described second detection are determined
Whether picture is Same Scene.
In one embodiment, it is described according to first extreme point and secondary extremal point, determine first inspection
Mapping piece detects that the step of whether picture is Same Scene includes with described second:
According to first extreme point and secondary extremal point, the first time histogram corresponding the is determined respectively
One filtering peak value and the corresponding second filtering peak value of second time histrogram;
According to the described first filtering peak value and the second filtering peak value, the first time histogram and described the are calculated
The peak value matching degree of two time histrograms;When the peak value matching degree is spent more than preset matching, the first detection figure is determined
Piece and the second detection picture are Same Scene.
In one embodiment, the peak value for calculating the first time histogram and second time histrogram
With including the step of spending:
It determines to whether there is the peak point equal with the described first filtering peak value in second time histrogram;
When existing in second time histrogram with the described first filtering equal peak point of peak value, described the is determined
First matching degree of one time histrogram and second time histrogram determines value for first;
When the peak point equal with the described first filtering peak value being not present in second time histrogram, determine described
First time histogram and the first matching degree of second time histrogram determine value for second;
It determines to whether there is the peak point equal with the described second filtering peak value in the first time histogram;
When existing in the first time histogram with the described second filtering equal peak point of peak value, described the is determined
Second matching degree of one time histrogram and second time histrogram determines value for first;
When the peak point equal with the described second filtering peak value being not present in the first time histogram, determine described
First time histogram and the second matching degree of second time histrogram determine value for second;
According to first matching degree and second matching degree, when calculating the first time histogram with described second
Between histogram peak value matching degree.
In one embodiment, it is described according to first extreme point and secondary extremal point, described the is determined respectively
The step of corresponding first filtering peak value of one time histrogram and second time histrogram corresponding second filter peak value is wrapped
It includes:
Determine corresponding first history peak value of first extreme point and the corresponding second history peak of secondary extremal point
Value;
Peak value filtering is carried out to first history peak value and second history peak value respectively, obtains the first time
The corresponding first filtering peak value of histogram and the corresponding second filtering peak value of second time histrogram.
In one embodiment, it is described according to the similar value and preset threshold range, determine the first detection picture
Detect that the step of whether picture is Same Scene further includes with described second:
When the similar value is not less than the limit on the right-right-hand limit value of preset threshold range, the first detection picture and described is determined
Second detection picture is Same Scene;
When the similar value is not more than the left limit value of preset threshold range, the first detection picture and described is determined
The second detection non-Same Scene of picture.
In one embodiment, corresponding first spatial histogram of the generation the first detection picture and described second
The step of detection picture corresponding second space histogram, includes:
It obtains respectively in the first detection picture and the second detection picture, the intrinsic brilliance value and reason of each pixel
By brightness value;
According to the intrinsic brilliance value and the theoretical brightness value, the corresponding statistical information of each pixel is obtained, respectively root
According to the intrinsic brilliance value and the statistical information, corresponding first spatial histogram of generation the first detection picture and described
The corresponding second space histogram of second detection picture.
In one embodiment, the similar value for calculating first spatial histogram and the second space histogram
The step of include:
First spatial histogram statistics letter corresponding with pixel each in the second space histogram is obtained respectively
Breath, to obtain the second statistical information of the first statistical information of first spatial histogram and the second space histogram;
According to first statistical information and second statistical information, first spatial histogram and described the are calculated
The similar value of two spatial histograms.
In addition, to achieve the above object, the present invention also provides a kind of scene change detection equipment, the scene change detections
Equipment includes:The scene change inspection that memory, processor and being stored in can be run on the memory and on the processor
Ranging sequence, the scene change detection program realize scene change detection described in any one of the above embodiments when being performed by the processor
The step of method.
In addition, to achieve the above object, it is described computer-readable the present invention also provides a kind of computer readable storage medium
Scene change detection program is stored on storage medium, the scene change detection program realizes above-mentioned when being executed by processor
The step of scene change detection method described in one.
The present invention proposes a kind of scene change detection method, currently needs detect first to detect picture and the by obtaining
Two detection pictures, generation first corresponding first spatial histogram of detection picture and the second detection picture corresponding the
Two spatial histograms then calculate the similar value of first spatial histogram and the second space histogram, then basis
The similar value and preset threshold range determine that the first detection picture detects whether picture is same field with described second
Scape realizes a kind of efficient scene change detection method, and overcoming traditional algorithm needs to extract big measure feature to calculate, so as to
The problem of causing detection efficiency low, is converted to the histogram of time dimension simultaneously also by the histogram of Spatial Dimension, into one
Detection efficiency is improved to step, realizes the efficiently and in real time detection switched to high pixel video Scene.
Description of the drawings
Fig. 1 is the structural representation of the scene change detection equipment in the hardware running environment that the embodiment of the present invention is related to
Figure;
Fig. 2 is the flow diagram of scene change detection method first embodiment of the present invention;
Fig. 3 is the flow diagram of scene change detection method second embodiment of the present invention;
Fig. 4 is the flow diagram of scene change detection method 3rd embodiment of the present invention;
Fig. 5 is the flow diagram of scene change detection method fourth embodiment of the present invention;
Fig. 6 is the flow diagram of the 5th embodiment of scene change detection method of the present invention;
Fig. 7 is the flow diagram of scene change detection method sixth embodiment of the present invention;
Fig. 8 is the flow diagram of the 7th embodiment of scene change detection method of the present invention;
Fig. 9 is the flow diagram of the 8th embodiment of scene change detection method of the present invention.
The embodiments will be further described with reference to the accompanying drawings for the realization, the function and the advantages of the object of the present invention.
Specific embodiment
It should be appreciated that the specific embodiments described herein are merely illustrative of the present invention, it is not intended to limit the present invention.
Scene change detection equipment in the hardware running environment being related to as shown in FIG. 1, FIG. 1 is the embodiment of the present invention
Structure diagram.
Equipment of the embodiment of the present invention can be PC or smart mobile phone, tablet computer, E-book reader, MP3
(Moving Picture Experts Group Audio Layer III, dynamic image expert's compression standard audio level 3)
Player, MP4 (Moving Picture Experts Group Audio Layer IV, dynamic image expert's compression standard sound
Frequency level 4) player, pocket computer etc. have the packaged type terminal device of display function.
As shown in Figure 1, the equipment can include:Processor 1001, such as CPU, network interface 1004, user interface
1003, memory 1005, communication bus 1002.Wherein, communication bus 1002 is used to implement the connection communication between these components.
User interface 1003 can include display screen (Display), input unit such as keyboard (Keyboard), optional user interface
1003 can also include standard wireline interface and wireless interface.Network interface 1004 can optionally connect including the wired of standard
Mouth, wireless interface (such as WI-FI interfaces).Memory 1005 can be high-speed RAM memory or the memory of stabilization
(non-volatile memory), such as magnetic disk storage.Memory 1005 optionally can also be independently of aforementioned processor
1001 storage device.
Optionally, equipment can also include camera, RF (Radio Frequency, radio frequency) circuit, sensor, audio
Circuit, WiFi module etc..Wherein, sensor such as optical sensor, motion sensor and other sensors.Specifically, light
Sensor may include ambient light sensor and proximity sensor, wherein, ambient light sensor can according to the light and shade of ambient light come
The brightness of display screen is adjusted, proximity sensor can close display screen and/or backlight when mobile terminal is moved in one's ear.As
One kind of motion sensor, gravity accelerometer can detect in all directions the size of (generally three axis) acceleration, quiet
It can detect that size and the direction of gravity when only, the application that can be used to identify mobile terminal posture is (such as horizontal/vertical screen switching, related
Game, magnetometer pose calibrating), Vibration identification correlation function (such as pedometer, tap) etc.;Certainly, mobile terminal can also match
The other sensors such as gyroscope, barometer, hygrometer, thermometer, infrared ray sensor are put, details are not described herein.
It will be understood by those skilled in the art that the device structure shown in Fig. 1 does not form the restriction to equipment, can wrap
It includes and either combines certain components or different components arrangement than illustrating more or fewer components.
As shown in Figure 1, it can lead to as in a kind of memory 1005 of computer storage media including operating system, network
Believe module, Subscriber Interface Module SIM and scene change detection program.
In terminal shown in Fig. 1, network interface 1004 is mainly used for connecting background server, is carried out with background server
Data communicate;User interface 1003 is mainly used for connecting client (user terminal), with client into row data communication;And processor
1001 can be used for calling the scene change detection program stored in memory 1005.
When processor 1001 calls the scene change detection program stored in memory 1005, following operate is performed:
Acquisition currently needs the detect first detection picture and the second detection picture, and generation the first detection picture corresponds to
The first spatial histogram and the corresponding second space histogram of the second detection picture;
Calculate the similar value of first spatial histogram and the second space histogram;
According to the similar value and preset threshold range, determine that the first detection picture is with the described second detection picture
No is Same Scene.
Further, following operation is also realized when the scene change detection program is performed by the processor:
When the similar value is within preset threshold range, first spatial histogram is converted as first time Nogata
Figure, the second space histogram are the second time histrogram;
Obtain corresponding first extreme point of the first time histogram, corresponding second pole of second time histrogram
Value point;
According to first extreme point and secondary extremal point, the first detection picture and the described second detection are determined
Whether picture is Same Scene.
Further, following operation is also realized when the scene change detection program is performed by the processor:
According to first extreme point and secondary extremal point, the first time histogram corresponding the is determined respectively
One filtering peak value and the corresponding second filtering peak value of second time histrogram;
According to the described first filtering peak value and the second filtering peak value, the first time histogram and described the are calculated
The peak value matching degree of two time histrograms;When the peak value matching degree is spent more than preset matching, the first detection figure is determined
Piece and the second detection picture are Same Scene.
Further, following operation is also realized when the scene change detection program is performed by the processor:
It determines to whether there is the peak point equal with the described first filtering peak value in second time histrogram;
When existing in second time histrogram with the described first filtering equal peak point of peak value, described the is determined
First matching degree of one time histrogram and second time histrogram determines value for first;
When the peak point equal with the described first filtering peak value being not present in second time histrogram, determine described
First time histogram and the first matching degree of second time histrogram determine value for second;
It determines to whether there is the peak point equal with the described second filtering peak value in the first time histogram;
When existing in the first time histogram with the described second filtering equal peak point of peak value, described the is determined
Second matching degree of one time histrogram and second time histrogram determines value for first;
When the peak point equal with the described second filtering peak value being not present in the first time histogram, determine described
First time histogram and the second matching degree of second time histrogram determine value for second;
According to first matching degree and second matching degree, when calculating the first time histogram with described second
Between histogram peak value matching degree.
Further, following operation is also realized when the scene change detection program is performed by the processor:
Determine corresponding first history peak value of first extreme point and the corresponding second history peak of secondary extremal point
Value;
Peak value filtering is carried out to first history peak value and second history peak value respectively, obtains the first time
The corresponding first filtering peak value of histogram and the corresponding second filtering peak value of second time histrogram.
Further, following operation is also realized when the scene change detection program is performed by the processor:
When the similar value is not less than the limit on the right-right-hand limit value of preset threshold range, the first detection picture and described is determined
Second detection picture is Same Scene;
When the similar value is not more than the left limit value of preset threshold range, the first detection picture and described is determined
The second detection non-Same Scene of picture.
Further, following operation is also realized when the scene change detection program is performed by the processor:
It obtains respectively in the first detection picture and the second detection picture, the intrinsic brilliance value and reason of each pixel
By brightness value;
According to the intrinsic brilliance value and the theoretical brightness value, the corresponding statistical information of each pixel is obtained, respectively root
According to the intrinsic brilliance value and the statistical information, corresponding first spatial histogram of generation the first detection picture and described
The corresponding second space histogram of second detection picture.
Further, following operation is also realized when the scene change detection program is performed by the processor:
First spatial histogram statistics letter corresponding with pixel each in the second space histogram is obtained respectively
Breath, to obtain the second statistical information of the first statistical information of first spatial histogram and the second space histogram;
According to first statistical information and second statistical information, first spatial histogram and described the are calculated
The similar value of two spatial histograms.
The present invention provides a kind of scene change detection method, and with reference to Fig. 2, Fig. 2 is scene change detection method of the present invention the
The flow diagram of one embodiment.
In the present embodiment, which includes:
Step S1000, acquisition currently need the detect first detection picture and the second detection picture, generation first inspection
Corresponding first spatial histogram of mapping piece and the corresponding second space histogram of the second detection picture;
The picture that first detection picture and the second detection picture need to carry out scene comparison detection for two, is getting this
When the first detection picture and the second detection picture, the first detection picture and the corresponding sky of the second detection picture are obtained respectively
Between dimension histogram;The histogram that the first detection picture corresponds to Spatial Dimension is the first spatial histogram, second inspection
The histogram that mapping piece corresponds to Spatial Dimension is second space histogram.
The brightness of picture can be divided into 0 to 255 totally 256 numerical value, and numerical value is bigger and represents that brightness is higher, the histogram
Abscissa is brightness value, and ordinate is the pixel quantity of corresponding brightness value in picture, which represents in the figure
How many pixel is the brightness value in piece.In the present embodiment, 256 brightness values are divided into 32 sections, each section
In then include 8 brightness and index, which is the bins of the histogram of the Spatial Dimension generated;The first detection is schemed respectively
The intrinsic brilliance value of piece and each pixel in the second detection picture is counted, so as to get each intrinsic brilliance value pair
The number for the pixel answered, the number of the pixel is the corresponding statistical information of intrinsic brilliance value;According to intrinsic brilliance value and it is somebody's turn to do
Statistical information generates the histogram of the first detection picture and the corresponding Spatial Dimension of the second detection picture.Wherein, should
Statistical information can be acquired according to the intrinsic brilliance value and theoretical brightness value, specifically, in the intrinsic brilliance value of a certain pixel
During equal to the theory brightness value, it is determined that the pixel is that the probability of the intrinsic brilliance is 1, i.e., 100% determines that the pixel is the reality
Border brightness value;When the intrinsic brilliance value is not equal to the theory brightness value, it is determined that the pixel is that the probability of the intrinsic brilliance is
0, i.e. the brightness value of the pixel is not equal to the intrinsic brilliance value;Each intrinsic brilliance that statistical probability is 1 as a result, is worth corresponding picture
The number of element, the number of the pixel is the corresponding statistical information of intrinsic brilliance value.
Step S2000 calculates the similar value of first spatial histogram and the second space histogram;
It obtains respectively in the first spatial histogram and second space histogram, the corresponding statistical information of each pixel, wherein,
The statistical information of first spatial histogram is the first statistical information, and the statistical information of the second space histogram is the second statistics
Information;According to first statistical information and second statistical information, first spatial histogram and the second space Nogata are calculated
The similar value of figure.Specifically, the first spatial histogram uses H respectively with second space histogram1With H2It represents, first space is straight
Similar value Correlation (the H of side's figure and the second space histogram1,H2) represent, the calculation formula of the similar value is as follows:
Wherein,K represents which bins, K=32, and j values are 1,2, H1With H2It represents respectively
First spatial histogram and the second space histogram, the H1(k) and H2(k) the corresponding system of the first detection picture is represented respectively
Count information and the corresponding statistical information of the second detection picture.
Step S3000 according to the similar value and preset threshold range, determines the first detection picture and described second
Detect whether picture is Same Scene.
When obtaining the similar value of the first detection picture and the second detection picture, preset threshold range is obtained, the default threshold
Value range is range of the minimum predetermined threshold value to highest predetermined threshold value, and the minimum predetermined threshold value and the highest predetermined threshold value are pre-
The threshold value first set;Can be to the first detection picture and the second detection picture according to the preset threshold range and the similar value
It is no to be detected judgement for Same Scene.
When similar value is not less than the limit on the right-right-hand limit value of the preset threshold range, the first detection picture and second inspection are determined
Mapping piece is Same Scene;When the similar value is not more than the left limit value of the preset threshold range, the first detection figure is determined
Piece and the second detection non-Same Scene of picture, the i.e. first detection picture and the second detection picture are scene switching;Wherein,
The limit on the right-right-hand limit value of the preset threshold range is the highest predetermined threshold value, and the left limit value of the preset threshold range is that this is minimum
Predetermined threshold value.
When the similar value is within the preset threshold range, it is to the first detection picture and the second detection picture then
The no judgement for Same Scene needs further to detect determining;Only each brightness value is corresponded in the histogram of Spatial Dimension
The numerical statistic of number of pixels, while the sequence for exchanging the bins of two test charts can't influence the similar value of this two figures
The testing result of (i.e. Correlation);Therefore, the statistics with histogram of Spatial Dimension is not carried directly in any sequential
Information.It being found based on a large amount of data observation, there are the phenomenon that luminance shift to occur for the scene change with technical transition, and
This phenomenon is not appeared in generally in the scene switching of moment.Based on this difference, by the way that the information of time dimension is increased
To in the histogram counted, even TH (k)=H (k), wherein, TH (k) is k-th of moment for representing the time histrogram
Statistical information, H (k) are k-th of statistical information for representing the spatial histogram;So that H (k) in the histogram of original space dimension
With H (k+1) there is no temporal sequencing, by the histogram and time dimension of Spatial Dimension histogram conversion it
Afterwards, the sequencing in new histogram (i.e. the histogram of time dimension) on TH (k) and TH (k+1) existence time;Exchanging should
The sequence of bins is by the peak position of affect histogram in the histogram of time dimension, so as to influence the result of detection.Therefore, root
According to two detection pictures correspond to respectively time dimension histogram peak value matching result, can to this two detect pictures whether be
Same Scene carries out further detection and judges.
Specifically, when the similar value is within the preset threshold range, then convert this first detection picture with this second
Detection picture corresponds to histogram of the histogram of Spatial Dimension for two time dimensions, which corresponds to time dimension
Histogram for first time histogram, the histogram which corresponds to time dimension is the second time histrogram;
It obtains the first time histogram and the corresponding extreme point of the second time histrogram, the first time histogram is corresponding
Extreme point is the first extreme point, which is secondary extremal point.By the time histrogram
Statistical information represents that the TH (k) is the statistical information at k-th of moment for representing the time histrogram, with corresponding sky with TH (k)
Between dimension histogram statistical information it is identical, wherein, the time histrogram then include the first time histogram and this second
Time histrogram.The extreme point in the first time histogram and second time histrogram is obtained respectively, according to obtained
One extreme point and secondary extremal point determine the history peak value in the first time histogram and second time histrogram respectively;
Specifically, according to the statistical information at current time, the statistical information of the last moment at current time and the lower a period of time at current time
The statistical information at quarter carries out size judgement, determines the history peak value in time histrogram;Determining current time corresponding extreme value
When point is peak point, it is determined that the history peak value of the time histrogram is 1, is determining that current time corresponding extreme point is valley
During point, it is determined that the history peak value of the time histrogram is -1;Wherein, in the present embodiment, the first time histogram is with being somebody's turn to do
Second time histrogram is referred to as time histrogram.
The deterministic process can be represented with equation below:
In TH (k)>TH (k+1) and TH (k)>TH (k-1), it is determined that P (k)=1;
In TH (k)<TH (k+1) and TH (k)<TH (k-1), it is determined that P (k)=- 1;
Wherein, TH (k) represents the statistical information at current time, and TH (k+1) represents the statistics of the subsequent time at current time
Information, TH (k-1) represent the statistical information of the last moment at current time, and P (k) is history peak value.
When getting the history peak value, respectively to the history peak value in first time histogram and the second time histrogram
It is filtered, larger peak value is fluctuated so as to get characterization, after first time histogram and the second time histrogram filter
Obtained peak value then respectively first filters peak value and the second filtering peak value.Calculate the first filtering peak value and second filtering
The peak value matching degree of peak value, and obtain preset matching degree;When the peak value matching degree is spent more than the preset matching, determine this first
It is Same Scene to detect picture and the second detection picture, otherwise non-Same Scene, i.e. scene switching.
Specifically, it when acquiring the first filtering peak value and the second filtering peak value, obtains straight in the first time
At the time of the first filtering peak value corresponds in square figure, if in the second time histrogram, in the range of the default bias at the moment,
The second filtering peak value equal with the first filtering peak value can be found, it is determined that the first filtering peak value and the second filtering peak
First matching degree M of value1(k) it is 1, otherwise, first matching degree M1(k) it is 0;According to the same manner, acquire this second
When filtering peak value, at the time of obtaining in second time histrogram the second filtering peak value and correspond to, if in first time Nogata
In figure, in the range of the default bias at the moment, the first filtering peak value equal with the second filtering peak value can be found, then really
The second matching degree M of the fixed second filtering peak value and the first filtering peak value2(k) it is 1, otherwise, second matching degree M2(k) it is
0;Wherein, default bias ranging from presets the range for allowing instants offset, according to first matching degree and second matching
The peak value matching degree of the first time histogram and second time histrogram is calculated by formula for degree.
The calculation formula of the peak value matching degree is as follows:
Wherein, P'1Represent the first time histogram after filtering, P'2Represent the second time histrogram after filtering, M1(k)
Represent the first matching degree, M2(k) the second matching degree is represented.
The scene change detection method that the present embodiment proposes currently needs detect first to detect picture and the by obtaining
Two detection pictures, generation first corresponding first spatial histogram of detection picture and the second detection picture corresponding the
Two spatial histograms then calculate the similar value of first spatial histogram and the second space histogram, then basis
The similar value and preset threshold range determine that the first detection picture detects whether picture is same field with described second
Scape realizes a kind of efficient scene change detection method, and overcoming traditional algorithm needs to extract big measure feature to calculate, so as to
The problem of causing detection efficiency low, is converted to the histogram of time dimension simultaneously also by the histogram of Spatial Dimension, into one
Detection efficiency is improved to step, realizes the efficiently and in real time detection switched to high pixel video Scene.
Based on first embodiment, the second embodiment of scene change detection method of the present invention is proposed, with reference to Fig. 3, in this reality
It applies in example, step S3000 includes:
Step S3100 when the similar value is within preset threshold range, converts first spatial histogram as first
Time histrogram, the second space histogram are the second time histrogram;
When the similar value is within the preset threshold range, that is, represent the first detection picture and the second detection picture
It is possible that for Same Scene, it is also possible to non-Same Scene;Therefore, it when the similar value is within the preset threshold range, needs
Will to this first detection picture and this second detection picture whether be Same Scene judgement need further to detect it is determining.Tool
Body, corresponding first spatial histogram of picture and second space histogram are detected for the first detection picture and second,
The information of time dimension is increased respectively in first spatial histogram and the second space histogram, i.e., it is straight in script space
K-th of statistical information that side's figure represents, is represented with H (k), is changed into the statistical information at k-th of moment in time histrogram, is used
TH (k) is represented;Even TH (k)=H (k) so that after space-time conversion, new statistic histogram TH (k) and TH (k+1) exist
Temporal sequencing.
Step S3200 obtains corresponding first extreme point of the first time histogram, second time histrogram pair
The secondary extremal point answered;
When getting first time histogram and the second time histrogram, respectively to the first time histogram and this
Statistical information in two time histrograms carries out size judgement;Specifically, obtain current time corresponding statistical information TH (k),
The statistical information TH (k+1) of the statistical information TH (k-1) and the subsequent time TH at current time of the last moment at current time;
If there are TH (k)>TH (k+1) and TH (k)>TH (k-1) or there are TH (k)<TH (k+1) and TH (k)<TH (k-1), then really
The point for determining current time is extreme point;Respectively in the first extreme point and the second time histrogram in first time histogram
Secondary extremal point counted.
Step S3300 according to first extreme point and secondary extremal point, determines the first detection picture and institute
State whether the second detection picture is Same Scene.
When obtaining the first extreme point, which is judged, if first extreme point at current time is
Peak point, it is determined that corresponding first history peak value of first extreme point at current time is 1;If current time corresponding first
When extreme point is valley point, it is determined that corresponding first history peak value of first extreme point at current time is -1;Secondary extremal
Corresponding second history peak value of point is identical with the method for determination of first history peak value, and details are not described herein.Getting first
When history peak value and the second history peak value, first history peak value and second history peak value are filtered respectively, filtered out
Smaller peak value is wherein fluctuated, further improves the matched detection efficiency of peak value;After filtration, then can obtain this first when
Between the second filtering peak value in the first filtering peak value and the second time histrogram in histogram;According to the first filtering peak value
And the second filtering peak value, calculate the peak value matching degree of first time histogram and the second time histrogram;This is being calculated
During peak value matching degree, preset matching degree is obtained, which is the matching degree standard of preset peak value;At the peak
When value matching degree is spent more than the preset matching, determine that the first detection picture and the second detection picture are Same Scene, otherwise
Non- Same Scene, as scene switching.
The scene change detection method that the present embodiment proposes during by the similar value within preset threshold range, turns
First spatial histogram is changed as first time histogram, the second space histogram is the second time histrogram, then
Obtain corresponding first extreme point of the first time histogram, the corresponding secondary extremal point of second time histrogram, and
Afterwards according to first extreme point and secondary extremal point, determine that the first detection picture is with the described second detection picture
No is Same Scene, is realized when similar value is within preset threshold range, further real by the matched detection of peak value
The quickly and efficiently detection to scene switching is showed.
Based on second embodiment, the 3rd embodiment of scene change detection method of the present invention is proposed, with reference to Fig. 4, in this reality
It applies in example, step S3300 includes:
Step S3310 according to first extreme point and secondary extremal point, determines the first time Nogata respectively
Scheme corresponding first filtering peak value and the corresponding second filtering peak value of second time histrogram;
When getting the first extreme point and secondary extremal point, first extreme point and the secondary extremal point are carried out respectively
Judge, if judging the extreme point for peak point, the corresponding history peak value of extreme point at the moment is 1;If judge the extreme point
For valley point, then the corresponding history peak value of the extreme point at the moment is -1;Such as the first extreme point, if judging first pole
Value point is peak point, then corresponding first history peak value of first extreme point at the moment is 1;If judge first extreme point for paddy
It is worth point, then corresponding first history peak value of first extreme point at the moment is -1;Corresponding second history peak value of secondary extremal point
Deterministic process, the deterministic process of the first history peak value corresponding with above-mentioned first extreme point is identical.It first is gone through getting this
When history peak value and second history peak value, then peak value filtering is carried out to first history peak value and second history peak value respectively,
I.e. by judging the size of the history peak value at current time and the history peak value of previous moment, so as to filter out wherein fluctuate it is smaller
Peak value, with this obtain it is corresponding first filtering peak value and second filtering peak value.
Step S3320 according to the described first filtering peak value and the second filtering peak value, calculates the first time Nogata
The peak value matching degree of figure and second time histrogram;
Step S3330 when the peak value matching degree is spent more than preset matching, determines the first detection picture and described
Second detection picture is Same Scene.
When acquiring the first filtering peak value and the second filtering peak value, obtaining should in the first time histogram
At the time of first filtering peak value corresponds to, if in the second time histrogram, in the range of the default bias at the moment, it can find
The second filtering peak value equal with the first filtering peak value, it is determined that the first filtering peak value and the first of the second filtering peak value
Matching degree M1(k) value is determined for first, wherein, which is 1, otherwise, first matching degree M1(k) it is determined for second
Value, wherein, which is 0;According to the same manner, when acquiring the second filtering peak value, obtain this second
At the time of the filtering peak value of this in time histrogram second corresponds to, if in first time histogram, in the default bias at the moment
In the range of, the first filtering peak value equal with the second filtering peak value can be found, it is determined that the second filtering peak value with this
Second matching degree M of one filtering peak value2(k) value is determined for first, wherein, which is 1, otherwise, second matching
Spend M2(k) value is determined for second, wherein, which is 0;When determining first matching degree and second matching degree,
The peak value matching degree of the first time histogram and second time histrogram is calculated according to formula, while obtains default
With degree, which is the matching degree standard of preset peak value;It is more than the preset matching in the peak value matching degree
When spending when the peak value matching degree is spent more than the preset matching, determine that the first detection picture and the second detection picture are
Same Scene.
The scene change detection method that the present embodiment proposes, by according to first extreme point and the secondary extremal
Point determines the corresponding first filtering peak value of the first time histogram and second time histrogram corresponding second respectively
Filter peak value, then according to described first filtering peak value and it is described second filtering peak value, calculate the first time histogram with
The peak value matching degree of second time histrogram then when the peak value matching degree is spent more than preset matching, determines described
First detection picture and the second detection picture are Same Scene, are realized in time histrogram compared with the mistake of the peak value of minor swing
Filter, improves the matched accuracy rate of peak value, and pass through the matched detection of peak value, further realizes in similar value in default threshold
When within the scope of value, the quickly and efficiently detection to scene switching.
Based on 3rd embodiment, the fourth embodiment of scene change detection method of the present invention is proposed, with reference to Fig. 5, in this reality
It applies in example, step S3320 includes:
Step S3321 judges to whether there is in second time histrogram equal with the described first filtering peak value
Peak point;
Step S3322, when there is the peak point equal with the described first filtering peak value in second time histrogram,
Determine that the first matching degree of the first time histogram and second time histrogram determines value for first;
The peak point equal with the described first filtering peak value is not present in step S3323 in second time histrogram
When, determine that the first matching degree of the first time histogram and second time histrogram determines value for second;
Step S3324 judges to whether there is in the first time histogram equal with the described second filtering peak value
Peak point;
Step S3325, when there is the peak point equal with the described second filtering peak value in the first time histogram,
Determine that the second matching degree of the first time histogram and second time histrogram determines value for first;
The peak point equal with the described second filtering peak value is not present in step S3326 in the first time histogram
When, determine that the second matching degree of the first time histogram and second time histrogram determines value for second;
Step S3327, according to first matching degree and second matching degree, calculate the first time histogram with
The peak value matching degree of second time histrogram.
When acquiring the first filtering peak value, obtain the first filtering peak value in the first time histogram and correspond to
At the time of;If in the second time histrogram, in the range of the default bias at the moment, can find and the first filtering peak value
The second equal filtering peak value, it is determined that there is the peak value equal with the first filtering peak value in second time histrogram
Point, so that it is determined that the first matching degree M of the first filtering peak value and the second filtering peak value1(k) value is determined for first, this first
Determine that value is equal to 1, otherwise, first matching degree M1(k) value is determined for second, which is equal to 0.
When acquiring the second filtering peak value, obtain the second filtering peak value in second time histrogram and correspond to
At the time of;If in first time histogram, in the range of the default bias at the moment, can find and the second filtering peak value
The first equal filtering peak value, it is determined that there is the peak value equal with the second filtering peak value in the first time histogram
Point, so that it is determined that the second matching degree M of the second filtering peak value and the first filtering peak value2(k) value is determined for first, this first
Determine that value is equal to 1, otherwise, second matching degree M2(k) value is determined for second, which is equal to 0.
When getting first matching degree and second matching degree, according to the calculation formula of peak value matching degree, you can meter
It calculates and obtains the peak value matching degree of the first time histogram and second time histrogram;The calculation formula of the peak value matching degree is such as
Under:
Wherein, P'1Represent the first time histogram after filtering, P'2Represent the second time histrogram after filtering, M1(k)
Represent the first matching degree, M2(k) the second matching degree is represented.
The scene change detection method that the present embodiment proposes, determines peak value matching degree by the above-mentioned means, realizing,
So as to be judged according to the peak value matching degree with preset matching degree, further realize in similar value in preset threshold range
Within when, the quickly and efficiently detection to scene switching.
Based on 3rd embodiment, the 5th embodiment of scene change detection method of the present invention is proposed, with reference to Fig. 6, in this reality
It applies in example, step S3310 includes:
Step S3311 determines that corresponding first history peak value of first extreme point and secondary extremal point are corresponding
Second history peak value;
In moment each in getting time histrogram corresponding extreme point, which is judged, if judging
The extreme point is peak point, then the corresponding history peak value of the extreme point at the moment is 1;If judging the extreme point for valley point,
The corresponding history peak value of extreme point at the moment is -1.Specifically, current time corresponding statistical information TH (k), current is obtained
The statistical information TH (k+1) of the statistical information TH (k-1) and the subsequent time TH at current time of the last moment at moment;If TH
(k)>TH (k+1) and TH (k)>TH (k-1), then corresponding extreme point of the current moment is peak point, that is, determines history peak value P
(k)=1;If TH (k)<TH (k+1) and TH (k)<TH (k-1), then corresponding extreme point of the current moment is valley point, that is, is determined
History peak value P (k)=- 1.
In the present embodiment, the first time histogram and second time histrogram are referred to as time histrogram, and first
Extreme point is referred to as extreme point with secondary extremal point, and the first history peak value is referred to as history peak value with the second history peak value;According to
The method of determination of above-mentioned history peak value respectively carries out the history peak value in first histogram and second histogram true one by one
It is fixed.
Step S3312 carries out peak value filtering to first history peak value and second history peak value respectively, obtains institute
State the corresponding first filtering peak value of first time histogram and the corresponding second filtering peak value of second time histrogram.
First time histogram and the second time histrogram can be there are some smaller fluctuations, by these fluctuations in sequential
The noise of generation matched accuracy rate will impact peak value, and therefore, it is necessary to the first history peak value and the second history peak
Value filtering, so as to filter out these smaller fluctuations.Specifically, before peak value matching is carried out, first Nogata is being got
During the second history peak value in the first history peak value and second histogram in figure, respectively to first history peak value and
Second history peak value is filtered;The peak value being obtained by filtration is respectively then the first filtering peak value and the second filtering peak value.
Specific filter process is the history peak value P (k) for obtaining current time, the previous history peak of the history peak value
K' at the time of value P (k') and the previous history peak value correspond to, if the history peak value P (k) at current time is previous not equal to this
A history peak value P (k'), and the corresponding statistical information TH (k) of history peak value at current time are corresponding with previous history peak value
At the time of k' statistical information TH (k') difference absolute value, less than preset difference value size θ, then enable the history peak at current time
Value P (k) filters out the history peak value at current time equal to zero;Wherein, preset difference value size is big for preset difference
It is small.
I.e. at P (k) ≠ P (k') ≠ 0, if | TH (k)-TH (k') |<θ then enables P (k)=0, wherein, when P (k) is current
The history peak value at quarter, P (k') be previous history peak value, TH (k) be current time the corresponding statistical information of history peak value, TH
(k') statistical information of k' at the time of correspondence for previous history peak value.
Further, when having filtered at least one history peak value, if the history peak value P (k) there are current time
Equal to the previous history peak value P (k') and 1, and the corresponding statistical information TH (k) of history peak value at current time are equal to, it is small
The statistical information TH (k') of k' at the time of previous history peak value corresponds to then enables previous history peak value P (k') equal to zero;If
History peak value P (k) there are current time equal to the previous history peak value P (k') and is equal to 1, and the history at current time
The corresponding statistical information TH (k) of peak value, the statistical information TH (k') of k', then enable at the time of correspondence not less than previous history peak value
The history peak value P (k) at current time is equal to zero.
I.e. at P (k)=P (k')=1, if TH (k)<TH (k') then enables P (k')=0;If at P (k)=P (k')=1
When, TH (k) >=TH (k') then enables P (k)=0;Wherein, P (k) is the history peak value at current time, and P (k') is previous history
Peak value, TH (k) is the corresponding statistical information of history peak value at current time, at the time of TH (k') is corresponded to for previous history peak value
The statistical information of k'.
Further, when having filtered at least one history peak value, if the history peak value P (k) there are current time
Equal to the previous history peak value P (k') and -1, and the corresponding statistical information TH (k) of history peak value at current time are equal to,
The statistical information TH (k') of k' at the time of correspondence more than previous history peak value then enables previous history peak value P (k') equal to zero;
If the history peak value P (k) there are current time equal to the previous history peak value P (k') and is equal to -1, and current time
The corresponding statistical information TH (k) of history peak value, the statistical information TH (k') of k' at the time of correspondence no more than previous history peak value,
The history peak value P (k) at current time is then enabled equal to zero.
I.e. at P (k)=P (k')=- 1, if TH (k)>TH (k') then enables P (k')=0;If at P (k)=P (k')=- 1
When, TH (k)≤TH (k') then enables P (k)=0;Wherein, P (k) is the history peak value at current time, and P (k') is previous history
Peak value, TH (k) is the corresponding statistical information of history peak value at current time, at the time of TH (k') is corresponded to for previous history peak value
The statistical information of k'.
The scene change detection method that the present embodiment proposes, by determining the corresponding first history peak of first extreme point
Value the second history peak value corresponding with the secondary extremal point, then respectively to first history peak value and second history
Peak value carries out peak value filtering, obtains the corresponding first filtering peak value of the first time histogram and second time histrogram
Corresponding second filtering peak value is realized to, compared with the filtering of the peak value of minor swing, reducing in time histrogram by these fluctuations
The influence of the noise of generation matched accuracy rate to peak value further increases the matched accuracy rate of peak value, improves to field
The efficiency and accuracy rate of scape change detection.
Based on first embodiment, the sixth embodiment of scene change detection method of the present invention is proposed, with reference to Fig. 7, in this reality
It applies in example, step S3000 includes:
Step S3400 when the similar value is not less than the limit on the right-right-hand limit value of preset threshold range, determines first detection
Picture and the second detection picture are Same Scene;
Range of the preset threshold range for minimum predetermined threshold value to highest predetermined threshold value, which is should
The limit on the right-right-hand limit of preset threshold range;The similar value of picture is detected in the first detection picture being calculated and second, not less than this
During the limit on the right-right-hand limit value of preset threshold range, that is, represent that the first detection picture and the second detection picture are closely similar,
Then determine that the first detection picture and the second detection picture are Same Scene.
Step S3500 when the similar value is not more than the left limit value of preset threshold range, determines first detection
Picture and the second detection non-Same Scene of picture.
The minimum predetermined threshold value of the preset threshold range is the limit on the left of the preset threshold range;In be calculated
The similar value that one detection picture detects picture with second, no more than the preset threshold range left limit value when, that is, represent this
One detection picture and the second detection picture similarity are very low, it is determined that the first detection picture and the second detection picture are non-
Same Scene, the i.e. first detection picture are scene switching with the second detection picture.
The scene change detection method that the present embodiment proposes, by the right side for being not less than preset threshold range in the similar value
During limiting value, determine that the first detection picture and the second detection picture are Same Scene, then in the similar value not
More than preset threshold range left limit value when, determine the first detection picture and the second detection picture non-same field
Scape is realized in the similar value when except preset threshold range, according to high-low threshold value to the first detection picture and the second detection
Picture whether be Same Scene detection judge.
Based on first embodiment, the 7th embodiment of scene change detection method of the present invention is proposed, with reference to Fig. 8, in this reality
It applies in example, step S1000 includes:
Step S1100 is obtained in the first detection picture and the second detection picture, the reality of each pixel respectively
Brightness value and theoretical brightness value;
Intrinsic brilliance value is in the first detection picture and the second detection picture, the corresponding practical brightness of each pixel
Value, which is each pixel brightness value obtained by calculation;Getting the first detection picture and second
When detecting picture, the intrinsic brilliance value of the first detection picture and each pixel in the second detection picture is counted respectively.Tool
Body, in the histogram of Spatial Dimension, the number of bins of the theoretical brightness of each pixel to generating histogram is related;At this
In embodiment, the histogram of the Spatial Dimension of generation is the statistic histogram of 32 bins, can be calculated according to N × (k-1)+i
To theoretical brightness value, wherein, the value range of k is then 1 to 32,That is the value range of N=8, i are 1 to 8.
Step S1200 according to the intrinsic brilliance value and the theoretical brightness value, obtains the corresponding statistics letter of each pixel
Breath, respectively according to the intrinsic brilliance value and the statistical information, it is straight that generation described first detects corresponding first space of picture
Side's figure second space histogram corresponding with the described second detection picture.
The intrinsic brilliance value of each pixel in the first detection picture and the second detection picture is counted respectively, from
And the number of the corresponding pixel of each intrinsic brilliance value is got, the number of the pixel is the corresponding statistics of intrinsic brilliance value
Information.The statistical information can be acquired according to the intrinsic brilliance value and theoretical brightness value, specifically, in the reality of a certain pixel
When brightness value is equal to the theory brightness value, it is determined that the pixel is that the probability of the intrinsic brilliance is 1, i.e., 100% determines the pixel
For the intrinsic brilliance value;When the intrinsic brilliance value is not equal to the theory brightness value, it is determined that the pixel is the intrinsic brilliance
Probability is 0, i.e., the brightness value of the pixel is not equal to the intrinsic brilliance value;Statistical probability is 1 each intrinsic brilliance value pair as a result,
The number for the pixel answered, the number of the pixel is the corresponding statistical information of intrinsic brilliance value.The calculating of the statistical information is public
Formula is as follows:
If Ip=N × (k-1)+i, then
If Ip≠ N × (k-1)+i, then
Wherein,K=32, k represent which bins, p are pixel, and H (k) is statistical information, IPFor reality
Brightness value, (N × (k-1)+i) are calculated as theoretical brightness value,Represent the probability of the pixel.
When getting the statistical information, according to intrinsic brilliance value and the statistical information, generate the first detection picture and
The histogram of the corresponding Spatial Dimension of second detection picture.
The scene change detection method that the present embodiment proposes, by obtaining the first detection picture and described second respectively
It detects in picture, the intrinsic brilliance value of each pixel and theoretical brightness value, then according to the intrinsic brilliance value and the theory
Brightness value obtains the corresponding statistical information of each pixel, respectively according to the intrinsic brilliance value and the statistical information, generates institute
Corresponding first spatial histogram of the first detection picture and the corresponding second space histogram of the second detection picture are stated, is realized
According to brightness value and the histogram of statistical information generation Spatial Dimension, the Nogata according to the Spatial Dimension is further realized
Figure to first detection picture with second detection picture whether be Same Scene preliminary analysis judgement.
Based on first embodiment, the 8th embodiment of scene change detection method of the present invention is proposed, with reference to Fig. 9, in this reality
It applies in example, step S2000 includes:
Step S2100 obtains first spatial histogram and pixel pair each in the second space histogram respectively
The statistical information answered, to obtain the second of the first statistical information of first spatial histogram and the second space histogram
Statistical information;
Statistical information in first spatial histogram is the first statistical information, the statistical information in second space histogram
As the second statistical information;When generating the first spatial histogram and second space histogram respectively, according to the meter of statistical information
Corresponding first statistical information of the first spatial histogram and second space histogram correspondence can be directly obtained respectively by calculating formula
The second statistical information.
Step S2200 according to first statistical information and second statistical information, calculates first space Nogata
The similar value of figure and the second space histogram.
When getting the first statistical information and the second statistical information, then according to the calculation formula of similar value to first sky
Between the similar value of histogram and the second space histogram calculated;Specifically, first spatial histogram and second sky
Between histogram similar value Correlation (H1,H2) represent, the calculation formula of the similar value is as follows:
Wherein,K represents which bins, K=32, and j values are 1,2, H1With H2It represents respectively
First spatial histogram and the second space histogram, the H1(k) and H2(k) the corresponding system of the first detection picture is represented respectively
Count information and the corresponding statistical information of the second detection picture.
The scene change detection method that the present embodiment proposes, by obtaining first spatial histogram and described the respectively
The corresponding statistical information of each pixel in two spatial histograms, with obtain the first statistical information of first spatial histogram and
Second statistical information of the second space histogram, then according to first statistical information and second statistical information,
Calculate the similar value of first spatial histogram and the second space histogram, realize according to the similar value to this first
Detection picture and this second detection picture whether be Same Scene preliminary analysis judge.
In addition, to achieve the above object, it is described computer-readable the present invention also provides a kind of computer readable storage medium
Scene change detection program is stored on storage medium, following step is realized when the scene change detection program is executed by processor
Suddenly:
Acquisition currently needs the detect first detection picture and the second detection picture, and generation the first detection picture corresponds to
The first spatial histogram and the corresponding second space histogram of the second detection picture;
Calculate the similar value of first spatial histogram and the second space histogram;
According to the similar value and preset threshold range, determine that the first detection picture is with the described second detection picture
No is Same Scene.
Further, following operation is also realized when the scene change detection program is performed by the processor:
When the similar value is within preset threshold range, first spatial histogram is converted as first time Nogata
Figure, the second space histogram are the second time histrogram;
Obtain corresponding first extreme point of the first time histogram, corresponding second pole of second time histrogram
Value point;
According to first extreme point and secondary extremal point, the first detection picture and the described second detection are determined
Whether picture is Same Scene.
Further, following operation is also realized when the scene change detection program is performed by the processor:
According to first extreme point and secondary extremal point, the first time histogram corresponding the is determined respectively
One filtering peak value and the corresponding second filtering peak value of second time histrogram;
According to the described first filtering peak value and the second filtering peak value, the first time histogram and described the are calculated
The peak value matching degree of two time histrograms;When the peak value matching degree is spent more than preset matching, the first detection figure is determined
Piece and the second detection picture are Same Scene.
Further, following operation is also realized when the scene change detection program is performed by the processor:
It determines to whether there is the peak point equal with the described first filtering peak value in second time histrogram;
When existing in second time histrogram with the described first filtering equal peak point of peak value, described the is determined
First matching degree of one time histrogram and second time histrogram determines value for first;
When the peak point equal with the described first filtering peak value being not present in second time histrogram, determine described
First time histogram and the first matching degree of second time histrogram determine value for second;
It determines to whether there is the peak point equal with the described second filtering peak value in the first time histogram;
When existing in the first time histogram with the described second filtering equal peak point of peak value, described the is determined
Second matching degree of one time histrogram and second time histrogram determines value for first;
When the peak point equal with the described second filtering peak value being not present in the first time histogram, determine described
First time histogram and the second matching degree of second time histrogram determine value for second;
According to first matching degree and second matching degree, when calculating the first time histogram with described second
Between histogram peak value matching degree.
Further, following operation is also realized when the scene change detection program is performed by the processor:
Determine corresponding first history peak value of first extreme point and the corresponding second history peak of secondary extremal point
Value;
Peak value filtering is carried out to first history peak value and second history peak value respectively, obtains the first time
The corresponding first filtering peak value of histogram and the corresponding second filtering peak value of second time histrogram.
Further, following operation is also realized when the scene change detection program is performed by the processor:
When the similar value is not less than the limit on the right-right-hand limit value of preset threshold range, the first detection picture and described is determined
Second detection picture is Same Scene;
When the similar value is not more than the left limit value of preset threshold range, the first detection picture and described is determined
The second detection non-Same Scene of picture.
Further, following operation is also realized when the scene change detection program is performed by the processor:
It obtains respectively in the first detection picture and the second detection picture, the intrinsic brilliance value and reason of each pixel
By brightness value;
According to the intrinsic brilliance value and the theoretical brightness value, the corresponding statistical information of each pixel is obtained, respectively root
According to the intrinsic brilliance value and the statistical information, corresponding first spatial histogram of generation the first detection picture and described
The corresponding second space histogram of second detection picture.
Further, following operation is also realized when the scene change detection program is performed by the processor:
First spatial histogram statistics letter corresponding with pixel each in the second space histogram is obtained respectively
Breath, to obtain the second statistical information of the first statistical information of first spatial histogram and the second space histogram;
According to first statistical information and second statistical information, first spatial histogram and described the are calculated
The similar value of two spatial histograms.
It should be noted that herein, term " comprising ", "comprising" or its any other variant are intended to non-row
His property includes, so that process, method, article or system including a series of elements not only include those elements, and
And it further includes other elements that are not explicitly listed or further includes intrinsic for this process, method, article or system institute
Element.In the absence of more restrictions, the element limited by sentence "including a ...", it is not excluded that including this
Also there are other identical elements in the process of element, method, article or system.
The embodiments of the present invention are for illustration only, do not represent the quality of embodiment.
Through the above description of the embodiments, those skilled in the art can be understood that above-described embodiment side
Method can add the mode of required general hardware platform to realize by software, naturally it is also possible to by hardware, but in many cases
The former is more preferably embodiment.Based on such understanding, technical scheme of the present invention substantially in other words does the prior art
Going out the part of contribution can be embodied in the form of software product, which is stored in one as described above
In storage medium (such as ROM/RAM, magnetic disc, CD), including some instructions use so that a station terminal equipment (can be mobile phone,
Computer, server, air conditioner or network equipment etc.) perform method described in each embodiment of the present invention.
It these are only the preferred embodiment of the present invention, be not intended to limit the scope of the invention, it is every to utilize this hair
The equivalent structure or equivalent flow shift that bright specification and accompanying drawing content are made directly or indirectly is used in other relevant skills
Art field, is included within the scope of the present invention.
Claims (10)
- A kind of 1. scene change detection method, which is characterized in that the scene change detection method includes:Acquisition currently needs the detect first detection picture and the second detection picture, generates described first and detects picture corresponding the One spatial histogram and the corresponding second space histogram of the second detection picture;Calculate the similar value of first spatial histogram and the second space histogram;According to the similar value and preset threshold range, determine the first detection picture with described second detect picture whether be Same Scene.
- 2. scene change detection method as described in claim 1, which is characterized in that described according to the similar value and default threshold It is worth range, determines that the first detection picture detects that the step of whether picture is Same Scene includes with described second:When the similar value is within preset threshold range, first spatial histogram is converted as first time histogram, institute Second space histogram is stated as the second time histrogram;Obtain corresponding first extreme point of the first time histogram, the corresponding secondary extremal of second time histrogram Point;According to first extreme point and secondary extremal point, the first detection picture and the described second detection picture are determined Whether it is Same Scene.
- 3. scene change detection method as claimed in claim 2, which is characterized in that described according to first extreme point and institute Secondary extremal point is stated, determines that the first detection picture detects that the step of whether picture is Same Scene includes with described second:According to first extreme point and secondary extremal point, corresponding first mistake of the first time histogram is determined respectively Filter peak value and the corresponding second filtering peak value of second time histrogram;Peak value is filtered according to the described first filtering peak value and described second, when calculating the first time histogram with described second Between histogram peak value matching degree;When the peak value matching degree is spent more than preset matching, determine it is described first detection picture and The second detection picture is Same Scene.
- 4. scene change detection method as claimed in claim 3, which is characterized in that described to calculate the first time histogram Include with the step of peak value matching degree of second time histrogram:It determines to whether there is the peak point equal with the described first filtering peak value in second time histrogram;When there is the peak point equal with the described first filtering peak value in second time histrogram, when determining described first Between the first matching degree of histogram and second time histrogram determine value for first;When the peak point equal with the described first filtering peak value being not present in second time histrogram, described first is determined First matching degree of time histrogram and second time histrogram determines value for second;It determines to whether there is the peak point equal with the described second filtering peak value in the first time histogram;When there is the peak point equal with the described second filtering peak value in the first time histogram, when determining described first Between the second matching degree of histogram and second time histrogram determine value for first;When the peak point equal with the described second filtering peak value being not present in the first time histogram, described first is determined Second matching degree of time histrogram and second time histrogram determines value for second;According to first matching degree and second matching degree, calculate the first time histogram and second time is straight The peak value matching degree of square figure.
- 5. scene change detection method as claimed in claim 3, which is characterized in that described according to first extreme point and institute Secondary extremal point is stated, determines the corresponding first filtering peak value of the first time histogram and second time histrogram respectively The step of corresponding second filtering peak value, includes:Determine corresponding first history peak value of first extreme point and corresponding second history peak value of secondary extremal point;Peak value filtering is carried out to first history peak value and second history peak value respectively, obtains the first time Nogata Scheme corresponding first filtering peak value and the corresponding second filtering peak value of second time histrogram.
- 6. scene change detection method as described in claim 1, which is characterized in that described according to the similar value and default threshold It is worth range, determines that the first detection picture detects that the step of whether picture is Same Scene further includes with described second:When the similar value is not less than the limit on the right-right-hand limit value of preset threshold range, the first detection picture and described second is determined Detection picture is Same Scene;When the similar value is not more than the left limit value of preset threshold range, the first detection picture and described second is determined Detect the non-Same Scene of picture.
- 7. scene change detection method as described in claim 1, which is characterized in that generation the first detection picture pair The step of the first spatial histogram for answering and the second detection picture corresponding second space histogram, includes:It obtains respectively in the first detection picture and the second detection picture, the intrinsic brilliance value and theory of each pixel are bright Angle value;According to the intrinsic brilliance value and the theoretical brightness value, the corresponding statistical information of each pixel is obtained, respectively according to institute State intrinsic brilliance value and the statistical information, corresponding first spatial histogram of generation the first detection picture and described second Detect the corresponding second space histogram of picture.
- 8. scene change detection method as described in claim 1, which is characterized in that described to calculate first spatial histogram Include with the step of similar value of the second space histogram:First spatial histogram statistical information corresponding with pixel each in the second space histogram is obtained respectively, with Obtain the first statistical information of first spatial histogram and the second statistical information of the second space histogram;According to first statistical information and second statistical information, first spatial histogram and the described second sky are calculated Between histogram similar value.
- 9. a kind of scene change detection equipment, which is characterized in that the scene change detection equipment includes:Memory, processor And it is stored in the scene change detection program that can be run on the memory and on the processor, the scene change detection It is realized when program is performed by the processor such as the step of scene change detection method described in any item of the claim 1 to 8.
- 10. a kind of computer readable storage medium, which is characterized in that scene change is stored on the computer readable storage medium Detection program is changed, is realized when the scene change detection program is executed by processor as described in any item of the claim 1 to 8 The step of scene change detection method.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201711439708.7A CN108171153B (en) | 2017-12-26 | 2017-12-26 | Scene change detection method, apparatus and computer-readable storage medium |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201711439708.7A CN108171153B (en) | 2017-12-26 | 2017-12-26 | Scene change detection method, apparatus and computer-readable storage medium |
Publications (2)
Publication Number | Publication Date |
---|---|
CN108171153A true CN108171153A (en) | 2018-06-15 |
CN108171153B CN108171153B (en) | 2021-10-01 |
Family
ID=62521895
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201711439708.7A Active CN108171153B (en) | 2017-12-26 | 2017-12-26 | Scene change detection method, apparatus and computer-readable storage medium |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN108171153B (en) |
Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN1471306A (en) * | 2002-07-09 | 2004-01-28 | ���ǵ�����ʽ���� | Scene change detectorand method thereof |
US20110051010A1 (en) * | 2009-08-27 | 2011-03-03 | Rami Jiossy | Encoding Video Using Scene Change Detection |
-
2017
- 2017-12-26 CN CN201711439708.7A patent/CN108171153B/en active Active
Patent Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN1471306A (en) * | 2002-07-09 | 2004-01-28 | ���ǵ�����ʽ���� | Scene change detectorand method thereof |
US20110051010A1 (en) * | 2009-08-27 | 2011-03-03 | Rami Jiossy | Encoding Video Using Scene Change Detection |
Also Published As
Publication number | Publication date |
---|---|
CN108171153B (en) | 2021-10-01 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
KR101903626B1 (en) | Automatic white balancing with chromaticity measure of raw image data | |
US9706111B2 (en) | No-reference image and video quality evaluation | |
RU2731370C1 (en) | Method of living organism recognition and terminal device | |
CN111225150B (en) | Method for processing interpolation frame and related product | |
CN106951346B (en) | Response time testing method and device | |
CN108024065B (en) | Terminal shooting method, terminal and computer readable storage medium | |
CN108701439B (en) | Image display optimization method and device | |
US8570403B2 (en) | Face image replacement system and method implemented by portable electronic device | |
CN105760884B (en) | The recognition methods of picture type and device | |
CN109167910A (en) | focusing method, mobile terminal and computer readable storage medium | |
CN105513067B (en) | A kind of Approach for detecting image sharpness and device | |
CN104793742B (en) | Shooting preview method and device | |
CN107818283A (en) | Quick Response Code image pickup method, mobile terminal and computer-readable recording medium | |
CN110084204B (en) | Image processing method and device based on target object posture and electronic equipment | |
CN106599758A (en) | Image quality processing method and terminal | |
CN109313797B (en) | Image display method and terminal | |
CN108806638B (en) | Image display method and device | |
CN114096994A (en) | Image alignment method and device, electronic equipment and storage medium | |
CN109104578B (en) | Image processing method and mobile terminal | |
US20230245441A9 (en) | Image detection method and apparatus, and electronic device | |
CN104202448A (en) | System and method for solving shooting brightness unevenness of mobile terminal camera | |
CN111028276A (en) | Image alignment method and device, storage medium and electronic equipment | |
CN112055190A (en) | Image processing method, device and storage medium | |
CN106773453B (en) | Camera exposure method and device and mobile terminal | |
CN108932703B (en) | Picture processing method, picture processing device and terminal equipment |
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 | ||
GR01 | Patent grant | ||
GR01 | Patent grant |