WO2020063688A1 - 视频场景变化的检测方法、装置及视频采集设备 - Google Patents

视频场景变化的检测方法、装置及视频采集设备 Download PDF

Info

Publication number
WO2020063688A1
WO2020063688A1 PCT/CN2019/107936 CN2019107936W WO2020063688A1 WO 2020063688 A1 WO2020063688 A1 WO 2020063688A1 CN 2019107936 W CN2019107936 W CN 2019107936W WO 2020063688 A1 WO2020063688 A1 WO 2020063688A1
Authority
WO
WIPO (PCT)
Prior art keywords
video
scene
fluctuation
block
array
Prior art date
Application number
PCT/CN2019/107936
Other languages
English (en)
French (fr)
Inventor
宋佳阳
陈瑶
周秋芳
章勇
曹李军
陈卫东
Original Assignee
苏州科达科技股份有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 苏州科达科技股份有限公司 filed Critical 苏州科达科技股份有限公司
Priority to EP19864103.7A priority Critical patent/EP3840381A4/en
Publication of WO2020063688A1 publication Critical patent/WO2020063688A1/zh

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N5/00Details of television systems
    • H04N5/14Picture signal circuitry for video frequency region
    • H04N5/147Scene change detection
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/10Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding
    • H04N19/134Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the element, parameter or criterion affecting or controlling the adaptive coding
    • H04N19/142Detection of scene cut or scene change
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/10Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding
    • H04N19/169Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the coding unit, i.e. the structural portion or semantic portion of the video signal being the object or the subject of the adaptive coding
    • H04N19/17Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the coding unit, i.e. the structural portion or semantic portion of the video signal being the object or the subject of the adaptive coding the unit being an image region, e.g. an object
    • H04N19/176Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the coding unit, i.e. the structural portion or semantic portion of the video signal being the object or the subject of the adaptive coding the unit being an image region, e.g. an object the region being a block, e.g. a macroblock
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/85Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using pre-processing or post-processing specially adapted for video compression
    • H04N19/87Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using pre-processing or post-processing specially adapted for video compression involving scene cut or scene change detection in combination with video compression
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N5/00Details of television systems
    • H04N5/14Picture signal circuitry for video frequency region
    • H04N5/144Movement detection
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N7/00Television systems
    • H04N7/18Closed-circuit television [CCTV] systems, i.e. systems in which the video signal is not broadcast
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N7/00Television systems
    • H04N7/18Closed-circuit television [CCTV] systems, i.e. systems in which the video signal is not broadcast
    • H04N7/183Closed-circuit television [CCTV] systems, i.e. systems in which the video signal is not broadcast for receiving images from a single remote source

Definitions

  • the present application relates to the field of video surveillance, and in particular, to a method, a device, and a video acquisition device for detecting a scene change in a video.
  • a video capture device is an indispensable device for scene monitoring.
  • cameras are the most widely used.
  • the camera needs to adjust the camera parameters using algorithms such as auto exposure, auto focus, and auto white balance according to the image conditions of the current scene to ensure that the output image is in a high quality state, which is manifested in clear images, correct exposure, and correct colors.
  • the shooting target may change, such as people entering or leaving, the distance between the subject and the camera changes, and the proportion of the subject in the screen changes. This may cause image quality problems such as blurred images or color distortion.
  • image quality problems such as blurred images or color distortion.
  • the image content is constantly changing: that is, the shooting target in the image is constantly changing.
  • the surveillance cameras on the road, the movement of vehicles and people, each frame of the image and the next frame may be different; ordinary outdoor scenes, flowers and trees sway with the wind; people's sitting posture changes, head and body shaking in a video conference.
  • whether a video scene is changed is detected by judging the statistical information of video frames, for example, using a brightness value of two adjacent video frames or a sharpness value of two adjacent video frames for comparative analysis. Find out whether the video scene has changed.
  • the inventor of the present application found in the research process of the existing video scene change detection method that in addition to the obvious changes in the above scenes, the changes in the video scene also include the fluctuations due to the noise of the camera itself. Degree); and the detection methods in the prior art determine that the interference caused by noise fluctuations is a change in the video scene, which leads to a lower accuracy of the video scene change detection.
  • embodiments of the present application provide a method, a device, and a video acquisition device for detecting a video scene change to solve the problem of low accuracy of detecting a video scene change.
  • the first aspect of the present application provides a method for detecting a video scene change, including:
  • the second block divided by the observation video frame corresponds one-to-one, and each of the elements is used to represent fluctuations of the second block at the same position in all the observation video frames;
  • the method for detecting a change in a video scene before detecting a change in the video scene, first determine whether the video scene is stable by observing the fluctuation of the second block of the video frame; that is, first determine that the detected video scene is stable At this time, the detection of the video scene change is performed.
  • the method uses the fluctuation of the video scene to perform stable detection of the video scene, which can better exclude the noise generated by the video collection device itself from disturbing the judgment of the video scene change and improve the video. Accuracy of scene change detection.
  • the obtaining a second block scene fluctuation array of a second video bitstream includes:
  • the second statistical information list includes the second preset number of second statistical information arrays, and the second statistical information array corresponds to the observed video frames one to one, and The elements of the second statistical information array correspond one-to-one with the second block of the observation video frame, and are used to represent scene statistical values of the second blocks;
  • the fluctuations of each of the second blocks are calculated using the extracted elements to form an array of scene fluctuations of the second block.
  • the method for detecting a scene change in a video provided in the embodiment of the present application calculates a degree of scene change corresponding to each second block by observing a scene statistical value of each second block in a video frame, so as to facilitate subsequent use of the scene corresponding to the second block.
  • the degree of change is used to judge whether the video scene is stable or not. It has high judgment accuracy.
  • the following formula is used to calculate the fluctuation of the second block:
  • c 2 is the second preset number
  • S ′′ k, i, j are elements in the i-th row and j-th column of the k-th second statistical information array in the second statistical information list.
  • the determining whether the video scene of the second video stream is stable based on the second block scene fluctuation array includes:
  • the method for detecting a video scene change uses the average value of all elements in the scene fluctuation array of the second block to judge the video scene stability of the second video bitstream, on the premise of ensuring the accuracy of the judgment To improve detection efficiency.
  • the following formula is used to calculate the fluctuation of the video scene of the second video bitstream:
  • M is the number of rows divided by the observation video frame
  • N is the number of columns divided by the observation video frame
  • the detecting a change in a video scene by using the first block scene fluctuation array and the second block scene fluctuation array includes:
  • the method for detecting a change in a video scene uses a stable first video code stream of a video scene as a reference for determining whether a video scene changes, and in combination with whether a second video code stream is stable, the method is disturbed for a short time in a video scene This situation is considered as the video scene has not changed, which can avoid frequent adjustment of the parameters of the video acquisition device and ensure the stability of the parameters of the video acquisition device.
  • a video scene fluctuation of the first video bitstream is calculated using the following formula:
  • M is the number of rows divided by the reference video frame
  • N is the number of columns divided by the reference video frame
  • the present application further provides a video scene change detection device, including:
  • a first obtaining module configured to obtain a first block scene fluctuation array of a first video code stream; wherein the video scene of the first video code stream is stable; the first video code stream includes a first preset number
  • the number of elements in the scene fluctuation array of the first block is the same as the number of the first blocks divided by the reference video frame, and each of the elements is used to represent the same in all the reference video frames Fluctuations of all the first blocks of the location, the fluctuations are used to indicate the degree of change of the scene;
  • a second obtaining module configured to obtain a second block scene fluctuation array of a second video code stream; wherein the second video code stream includes a second preset number of observation video frames; the second block scene The elements of the fluctuation array correspond one-to-one to the second block divided by the observation video frame, and each element is used to represent fluctuations of all the second blocks at the same position in all the observation video frames;
  • a judging module configured to judge whether the video scene of the second video bitstream is stable based on the second block scene fluctuation array
  • a determining module configured to detect changes in the video scene by using the fluctuation pattern array of the first block scene and the fluctuation pattern array of the second block scene when the video scene of the second video stream is stable.
  • the apparatus for detecting a change in a video scene determines whether the video scene is stable by observing the fluctuation of the second block of the video frame before detecting the change of the video scene; that is, first determines that the detected video scene is stable At this time, the detection of the video scene change is performed.
  • the method uses the fluctuation of the video scene to perform stable detection of the video scene, which can better exclude the noise generated by the video collection device itself from disturbing the judgment of the video scene change and improve the video. Accuracy of scene change detection.
  • an embodiment of the present application further provides a video capture device, including: at least one processor; and a memory communicably connected to the at least one processor; wherein the memory stores a memory that can be used by the one Instructions executed by a processor, the instructions being executed by the at least one processor, so that the at least one processor executes the first aspect described above, or a method for detecting a video scene change described in any implementation manner of the first aspect .
  • an embodiment of the present application further provides a computer-readable storage medium having stored thereon computer instructions that, when executed by a processor, implement the foregoing first aspect, or any one of the implementations of the first aspect.
  • the steps of the method for detecting a scene change in a video are described.
  • FIG. 1 is a flowchart of a method for detecting a video scene change according to an embodiment of the present application
  • FIG. 2 is a flowchart of a method for detecting a video scene change according to an embodiment of the present application
  • FIG. 3 is a flowchart of a method for detecting a video scene change according to an embodiment of the present application
  • FIG. 4 is a flowchart of a method for detecting a video scene change according to an embodiment of the present application
  • FIG. 5 is a structural block diagram of a video scene change detection device according to an embodiment of the present application.
  • FIG. 6 is a structural block diagram of a video scene change detection device according to an embodiment of the present application.
  • FIG. 7 is a schematic diagram of a hardware structure of a video capture device according to an embodiment of the present application.
  • an embodiment of a method for detecting a change in a video scene is provided. It should be noted that the steps shown in the flowchart of the accompanying drawings can be executed in a computer system such as a set of computer-executable instructions, and Although the logical order is shown in the flowchart, in some cases the steps shown or described may be performed in a different order than here.
  • an image sensor and an image processing module may be provided in the video capture device involved in the embodiments of the present application, where the image sensor is used to obtain a video image, and the image processing module is used to obtain the image sensor Perform statistics on video images and obtain statistical information on multiple index images.
  • the video image of the image processing module is divided into blocks of M rows and N columns (that is, M ⁇ N blocks), and each of the divided blocks corresponds to statistical information of one block. Therefore, for one statistical Index, a frame image can obtain scene statistics of M ⁇ N blocks, that is, each video frame corresponds to an M ⁇ N statistical information array.
  • the scene statistical value may be a sharpness value or a brightness value.
  • a frame of image is divided into M ⁇ N blocks, and each block can be counted as an FV value representing the degree of cleaning, that is, an FV array can be obtained for each frame of image. It is M rows and N columns.
  • the sharpness value is an accumulated statistic after filtering a frame of image, and an index for measuring the local and overall cleanliness of the image is the main data basis of autofocus.
  • the scene statistics are brightness information
  • a frame of image is divided into M ⁇ N blocks, and each block can be counted as a Y value representing the brightness, that is, each frame of image can get a brightness array with a size of M rows N columns.
  • the brightness information of a frame of image is counted as the main data basis for autofocus.
  • the statistical information array of the block corresponding to each frame of video image can be obtained by the image processing module in the video acquisition device processing the obtained video image, or it can be obtained by other modules or devices. It can be ensured that the video capture device in the embodiment of the present application can obtain the statistical information array of the block corresponding to each frame of the video image.
  • the number of blocks divided by each video frame can be specifically set according to the actual situation.
  • FIG. 1 is a flowchart of a video capture device according to an embodiment of the present application. As shown in FIG. 1, the flow includes the following: step:
  • the video scene of the first video stream is stable; the first video stream includes a first preset number of reference video frames; the number of elements of the first block scene fluctuation array and the first block of the reference video frame divided by The number is the same, and each element is used to represent the fluctuations of all the first blocks at the same position in all the reference video frames, and the fluctuations are used to represent the degree of change of the scene.
  • the first video bitstream may be a stable bitstream of a video scene determined in advance, or a stable bitstream of a video scene determined in real time. Regardless of which method is used to determine the scene stability of the video code stream, it is only necessary to ensure that the video image acquisition device can obtain the first block scene fluctuation array of the first video code stream where the video scene is stable.
  • the first video stream includes a first preset number of reference video frames (for example, c 1 , where c 1 is a constant greater than 1), and each reference video frame is divided into M ⁇ N first blocks.
  • the first video stream corresponds to a first block scene fluctuation array, and the first block scene fluctuation array includes M ⁇ N elements, corresponding to the (i, j) th element, where 1 ⁇ i ⁇ M, 1 ⁇ j ⁇ N; that is, the element in the i-th row and j-th column in the scene fluctuation array of the first block, which is used to represent the (i, j) -th first block in all reference video frames Fluctuations.
  • the fluctuations of the (i, j) th first block in all reference video frames can use the statistical values of all (i, j) th first blocks and all the first The block's statistical value, calculated standard deviation, or variance, etc.
  • the calculated standard deviation or variance is the fluctuation of the (i, j) th first block, that is, the array of scene fluctuations in the first block The element in row i and column j.
  • the second video stream includes a second preset number of observation video frames.
  • the elements of the scene fluctuation array of the second block correspond to the second block divided by the observation video frame, and each element is used to represent all observations.
  • the fluctuation of the second block at the same position in the video frame.
  • the second video stream includes a second preset number of observation video frames (for example, c 2 , where c 2 is a constant greater than 1), and each observation video frame is divided into M ⁇ N second blocks.
  • the second video stream corresponds to a second block scene fluctuation array, and the second block scene fluctuation array includes M ⁇ N elements, corresponding to the (i, j) th element, that is, the second region An element in the i-th row and j-th column of the block scene fluctuation array, which is used to represent the fluctuation of the (i, j) -th second block in all observation video frames.
  • the fluctuations of the (i, j) second block in all observation video frames may use the statistical values of all (i, j) second blocks and all second The block's statistical value, calculated standard deviation, or variance, etc.
  • the calculated standard deviation or variance is the fluctuation of the (i, j) second block, which is also the array of scene fluctuations in the second block.
  • the video capture device After the video capture device obtains the scene fluctuation array of the second block, it uses it to determine whether the video scene of the second video stream is stable. For example, the size relationship between each element in the scene fluctuation array of the second block and the preset value may be used for judgment, or the average value of all elements in the scene fluctuation array of the second block and the preset value may be used. To determine the size of the relationship, and so on.
  • step S14 is performed; otherwise, other operations may be performed.
  • the other operations may be returning to S12 to obtain the scene fluctuation array of the second block again to determine whether the scene of the second video bitstream is stable again.
  • the other operations may also be performed at preset intervals. After that, the second block scene fluctuation array is obtained again.
  • the video capture device determines that the video scene of the second video stream is stable, the first video stream corresponding to the first block scene fluctuation array and the second video stream corresponding to the second block scene fluctuation array are stable. All video scenes are stable. Therefore, based on the fluctuation array of scenes in the first block and the fluctuation array of scenes in the second block, detecting changes in the video scene can improve the accuracy of detection.
  • the difference between the scene fluctuation array of the first block and the scene fluctuation array of the second block can be calculated, and the obtained difference array and the preset array can be used to judge the size relationship.
  • Calculate the average of the fluctuation array of the scene in the first block and the fluctuation array of the scene in the second block use the difference between the two averages to make a judgment, and so on.
  • the method for detecting a change in a video scene before detecting a change in the video scene, first determine whether the video scene is stable by observing the fluctuation of the second block of the video frame; that is, first determine that the detected video scene is stable At this time, the detection of the video scene change is performed.
  • the method uses the fluctuation of the video scene to perform stable detection of the video scene, which can better exclude the noise generated by the video collection device itself from disturbing the judgment of the video scene change and improve the video. Accuracy of scene change detection.
  • An embodiment of the present application further provides a method for detecting a change in a video scene. As shown in FIG. 2, the method includes:
  • S21 Obtain a scene fluctuation array of a first block of a first video stream.
  • the video scene of the first video stream is stable; the first video stream includes a first preset number of reference video frames; the number of elements of the first block scene fluctuation array and the first block of the reference video frame divided by The number is the same, and each element is used to represent the fluctuations of all the first blocks at the same position in all the reference video frames, and the fluctuations are used to represent the degree of change of the scene.
  • the second video stream includes a second preset number of observation video frames.
  • the elements of the scene fluctuation array of the second block correspond to the second block divided by the observation video frame, and each element is used to represent all observations.
  • the fluctuation of the second block at the same position in the video frame.
  • the scene fluctuation array of the second block is obtained by the following steps:
  • the second statistical information list includes a second preset number of second statistical information arrays, the second statistical information array corresponds to the observation video frame one-to-one, and the elements of the second statistical information array correspond to the second block of the observation video frame.
  • One-to-one correspondence used to represent the scene statistics of each second block.
  • the second video stream includes a second preset number (for example, c 2 ) of observation video frames, each observation video frame corresponding to a second statistical information array, and all the second statistical information arrays are stored in a second statistical information list , Specifically, in the following form:
  • SL watch ⁇ S watch 1, S watch 2, S watch 3, ..., S watch k, ..., S watch c 2 ⁇ ; where SL watch is the second statistical information list and S watch k is the second statistical information list
  • the k-th second statistical information array in the middle that is, the second statistical information array corresponding to the k-th observation video frame in the second video stream.
  • S watch k is a two-dimensional array of M ⁇ N
  • SL watch is a three-dimensional array, and the three dimensions are frames, rows, and columns.
  • S watch (k, i, j) is in the second statistical information list. Statistics of the i-th row and j-th column in the k-th frame. Among them, 1 ⁇ k ⁇ c 2
  • the video acquisition device continuously acquires observation video frames, and fills the second statistical information array corresponding to the acquired observation video frames in SL watch until it is filled with c2; if it is not filled, it continues to wait for the next observation
  • the second statistics array of video frames is continuously filled in SL watch .
  • the video capture device uses the extracted elements to calculate the fluctuation of each second block, that is, the following formula is used to calculate the fluctuation of the second block:
  • c 2 is the second preset number
  • S watch (k, i, j) is an element in the i-th row and j-th column of the k-th second statistical information array in the second statistical information list.
  • the scene fluctuation array of the second block can be expressed as follows:
  • the video acquisition device calculates an average value of all elements in the scene fluctuation array of the second block based on the scene fluctuation array of the second block, and uses the average value to determine whether the video scene of the second video stream is stable. These include:
  • the video capture device uses the following formula to calculate the fluctuation of the video scene of the second video bitstream:
  • M is the number of rows divided by the observation video frame
  • N is the number of columns divided by the observation video frame
  • the first threshold may be a constant value, and may be specifically set according to actual conditions.
  • step S24 is performed; otherwise, step S221 is performed.
  • the method for detecting a scene change in a video calculates a degree of scene change corresponding to each second block by using a scene statistical value of each second block in a video frame, so as to facilitate Subsequently, the degree of scene change corresponding to the second block is used to determine whether the video scene is stable, and has high judgment accuracy.
  • weighting calculation may also be performed first, that is, a weight array W is set, where the size of W is M rows and N columns, and Are the same size. Utilizing weight array W pairs Weighted average
  • An embodiment of the present application further provides a method for detecting a change in a video image. As shown in FIG. 3, the method includes:
  • the video scene of the first video stream is stable; the first video stream includes a first preset number of reference video frames; the number of elements of the first block scene fluctuation array and the first block of the reference video frame divided by The number is the same, and each element is used to represent the fluctuations of all the first blocks at the same position in all the reference video frames, and the fluctuations are used to represent the degree of change of the scene.
  • the first statistical information list includes a first preset number of first statistical information arrays, the first statistical information array corresponds to the reference video frame one by one, and the elements of the first statistical information array correspond to the second block of the reference video frame.
  • One-to-one correspondence used to represent the scene statistics of each first block.
  • SL ref ⁇ S ref 1, S ref 2, S ref 3, ..., S ref q, ..., S ref c 1 ⁇ ;
  • S ref is the first statistical information list and S ref q is the first statistical information list
  • the q-th first statistical information array in the first video information stream that is, the first statistical information array corresponding to the k-th reference video frame in the first video stream.
  • S ref q is a two-dimensional array of M ⁇ N
  • SL ref is a three-dimensional array, and the three dimensions are frames, rows, and columns.
  • S ref (q, i, j) is in the first statistical information list.
  • S313 Calculate fluctuations of each first block by using the extracted elements to form a scene fluctuation array of the first block.
  • the video capture device uses the extracted elements to calculate the fluctuation of each first block, that is, the following formula is used to calculate the fluctuation of the first block:
  • c 1 is the first preset number
  • S ref (q, i, j) is an element in the i-th row and j-th column of the q-th first statistical information array in the first statistical information list.
  • the array of scene fluctuations in the first block can be expressed as follows:
  • S314 Determine whether the video scene of the first video bitstream is stable based on the scene fluctuation array of the first block.
  • M is the number of rows divided by the reference video frame
  • N is the number of columns divided by the reference video frame
  • the threshold for determining whether the video scene of the first video bitstream is stable may be a constant, and may be specifically set according to actual conditions. If it is determined that the current first video bitstream is unstable, return to step S331; otherwise, perform step S32.
  • the second video stream includes a second preset number of observation video frames.
  • the elements of the scene fluctuation array of the second block correspond to the second block divided by the observation video frame, and each element is used to represent all observations.
  • the fluctuation of the second block at the same position in the video frame.
  • the video capture device detects changes in the video scene through the following steps:
  • the fluctuation of the first video scene is the fluctuation of the video scene of the first video stream
  • the fluctuation of the second video scene is the fluctuation of the video scene of the second video stream.
  • the absolute value of the difference is calculated using the following formula:
  • the fluctuation of the video scene of the first video stream that is, the fluctuation of the first video scene
  • the fluctuation of the video scene of the second video stream that is, the fluctuation of the second video scene
  • S343 Determine whether the calculated absolute value is greater than a second threshold.
  • Th diff is the second threshold.
  • the difference array ⁇ diff is a two-dimensional array of M ⁇ N, where: ⁇ diff (i, j) is the element in the i-th row and j-th column of the difference array, 1 ⁇ i ⁇ M, 1 ⁇ j ⁇ N.
  • each element in the difference array ⁇ diff is greater than the second threshold, and if it is greater than the second threshold, the statistical value is increased by one.
  • the statistical value is cnt change .
  • the video capture device determines that the video scene changes when the cnt change is greater than the third threshold Th cnt ; therefore, two necessary conditions must be met for the video scene to change: (1) the absolute value of the difference in S343 is greater than the second threshold; (2) ) The number calculated in S346 is greater than the third threshold. When both are satisfied, it is confirmed that the video scene has changed; otherwise, it is considered that the video scene has not changed, and the process returns to S32 to continue judgment.
  • the method for detecting a change in a video scene uses a stable first video bitstream of the video scene as a reference for determining whether the video scene changes, and combines whether the second video bitstream is
  • the method is stable for the video scene being disturbed for a short period of time and quickly recovering as it is. It is considered that the video scene has not changed. It can avoid frequent adjustment of the parameters of the video acquisition device and ensure the stability of the parameters of the video acquisition device.
  • This embodiment of the present application also provides an application example of a method for detecting a change in a video scene.
  • the block fv information is used to determine whether the autofocus scene has changed. If the autofocus scene changes, it needs to be triggered. .
  • the video capture device includes a camera with a power zoom and auto focus module, a focusing lens group, and a device (motor) that drives focus, a resolution value (FV) acquisition module, a data storage module, and a calculation module.
  • a camera with a power zoom and auto focus module, a focusing lens group, and a device (motor) that drives focus, a resolution value (FV) acquisition module, a data storage module, and a calculation module.
  • step (2) Determine whether the current scene is stable. It is considered that the SL ref is stable, that is, the current scene is stable, and it enters the SL watch to obtain the block statistics information list of the observation frame. Otherwise, if the statistical data during this period is considered unstable, proceed to step (1) and continue to fill in SL ref by rolling and refreshing to cover the earliest frame of data in the array.
  • step (3) Determine whether the current scene is stable, and if it meets The SL watch is considered stable, that is, the current scene is stable, and it is determined whether the scene changes. Otherwise, it is considered that the statistical data during this period is unstable, then proceed to step (3) and continue to fill SL watch by rolling and refreshing, covering the earliest frame of data in the array.
  • step (5) Determine whether the scene has changed. There are two necessary conditions for judging the change of the scene. One is to determine whether the average value of the standard deviation of the block statistics information list has changed, and the other is to determine whether the number of block changes Cnt change exceeds the threshold Th cnt . If the above two conditions are met, the scene is considered to have changed, and the process proceeds to step (6). If the scene has not changed, then proceed to step (3) and continue to scroll and fill in the watch frame block statistics information list SL watch .
  • a device for detecting a video scene change is also provided.
  • the device is used to implement the foregoing embodiments and preferred implementation manners, and the descriptions will not be repeated.
  • the term "module” may implement a combination of software and / or hardware for a predetermined function.
  • the devices described in the following embodiments are preferably implemented in software, implementation in hardware, or a combination of software and hardware is also possible and conceived.
  • This embodiment provides a device for detecting a change in a video scene, as shown in FIG. 5, including:
  • the first obtaining module 51 is configured to obtain a first block scene fluctuation array of a first video stream.
  • the video scene of the first video stream is stable; the first video stream includes a first preset number of reference video frames; the number of elements of the first block scene fluctuation array and the first block of the reference video frame divided by The number is the same.
  • Each element is used to represent the fluctuation of all the first blocks at the same position in all reference video frames, and the fluctuation is used to represent the degree of change of the scene.
  • the second obtaining module 52 is configured to obtain a second block scene fluctuation array of a second video bitstream.
  • the second video stream includes a second preset number of observation video frames.
  • the elements of the scene fluctuation array of the second block correspond to the second block divided by the observation video frame, and each element is used to represent all observations. Fluctuations of all second blocks at the same position in a video frame.
  • the judging module 53 is configured to judge whether the video scene of the second video bitstream is stable based on the second block scene fluctuation array.
  • a determining module 54 is configured to detect changes in the video scene by using the fluctuation array of the first block scene and the fluctuation array of the second block scene when the video scene of the second video bitstream is stable.
  • the apparatus for detecting a change in a video scene determines whether the video scene is stable by observing the fluctuation of the second block of the video frame before detecting the change of the video scene; that is, first determines that the detected video scene is stable At this time, the detection of the video scene change is performed.
  • the method uses the fluctuation of the video scene to perform stable detection of the video scene, which can better exclude the noise generated by the video collection device itself from disturbing the judgment of the video scene change and improve the video. Accuracy of scene change detection.
  • the second obtaining module 52 includes:
  • the obtaining unit 521 is configured to obtain a second list of statistical information, where the second list of statistical information includes a second preset number of second statistical information arrays, the second statistical information array corresponds to the observed video frames one to one, and the second statistics The elements of the information array correspond to the second block of the observation video frame on a one-to-one basis, and are used to represent the scene statistics of each second block.
  • the extraction unit 522 is configured to sequentially extract all elements in the second statistical information array corresponding to the second blocks.
  • a calculation unit 523 is configured to calculate fluctuations of each second block by using the extracted elements to form an array of scene fluctuations of the second block.
  • c 2 is the second preset number
  • S watch (k, i, j) is an element in the i-th row and j-th column of the k-th second statistical information array in the second statistical information list.
  • the device for detecting a scene change in the video in this embodiment is presented in the form of a functional unit.
  • the unit here refers to an ASIC circuit, a processor and a memory that execute one or more software or fixed programs, and / or other devices that can provide the foregoing.
  • Functional device refers to an ASIC circuit, a processor and a memory that execute one or more software or fixed programs, and / or other devices that can provide the foregoing.
  • An embodiment of the present application further provides a video acquisition device, which includes the video scene change detection device shown in FIG. 5 or FIG. 6.
  • FIG. 7 is a schematic structural diagram of a video capture device according to an optional embodiment of the present application.
  • the video capture device may include at least one processor 71, such as a CPU (Central Processing Unit) , Central processing unit), at least one communication interface 74, memory 74, and at least one communication bus 72.
  • the communication bus 72 is used to implement connection and communication between these components.
  • the communication interface 74 may include a display screen and a keyboard, and the optional communication interface 74 may further include a standard wired interface and a wireless interface.
  • the memory 74 may be a high-speed RAM memory (Random Access Memory), or a non-volatile memory (non-volatile memory), such as at least one disk memory.
  • the memory 74 may optionally be at least one storage device located far from the foregoing processor 71.
  • the processor 71 may be combined with the device described in FIG. 5 or FIG. 6, the application program is stored in the memory 74, and the processor 71 calls the program code stored in the memory 74 to perform any of the foregoing method steps.
  • the communication bus 72 may be a peripheral component interconnect (PCI) bus or an extended industry standard architecture (EISA) bus, or the like.
  • PCI peripheral component interconnect
  • EISA extended industry standard architecture
  • the communication bus 72 can be divided into an address bus, a data bus, a control bus, and the like. For ease of representation, only one thick line is used in FIG. 7, but it does not mean that there is only one bus or one type of bus.
  • the memory 74 may include volatile memory (English: volatile memory), such as random access memory (English: random-access memory, abbreviation: RAM); the memory may also include non-volatile memory (English: non-volatile) memory), such as flash memory (English: flash memory), hard disk (English: hard disk drive (abbreviation: HDD)) or solid state hard disk (English: solid-state drive (abbreviation: SSD)); the memory 74 may also include the above-mentioned types of Memory combination.
  • volatile memory English: volatile memory
  • RAM random access memory
  • non-volatile memory English: non-volatile memory
  • flash memory English: flash memory
  • hard disk English: hard disk drive (abbreviation: HDD)
  • SSD solid state hard disk
  • the memory 74 may also include the above-mentioned types of Memory combination.
  • the processor 71 may be a central processing unit (English: central processing unit, abbreviation: CPU), a network processor (English: network processor, abbreviation: NP), or a combination of CPU and NP.
  • CPU central processing unit
  • NP network processor
  • the processor 71 may further include a hardware chip.
  • the hardware chip may be an application-specific integrated circuit (English: application-specific integrated circuit (abbreviation: ASIC)), a programmable logic device (English: programmable logic device (abbreviation: PLD)), or a combination thereof.
  • the PLD may be a complex programmable logic device (English: complex programmable device, abbreviation: CPLD), a field programmable logic gate array (English: field-programmable gate array, abbreviation: FPGA), general array logic (English: generic array) logic, abbreviation: GAL) or any combination thereof.
  • the memory 74 is also used to store program instructions.
  • the processor 71 may call a program instruction to implement a method for detecting a change in a video image as shown in the embodiments of FIGS. 1 to 4 of the present application.
  • An embodiment of the present application further provides a non-transitory computer storage medium, where the computer storage medium stores computer-executable instructions, and the computer-executable instructions can execute the method for detecting a video image change in any of the foregoing method embodiments.
  • the storage medium may be a magnetic disk, a compact disc, a read-only memory (ROM), a random access memory (RAM), a flash memory (Flash), and a hard disk (Hard). Disk Drive (abbreviation: HDD) or Solid State Drive (SSD), etc .; the storage medium may further include a combination of the above types of storage.

Landscapes

  • Engineering & Computer Science (AREA)
  • Multimedia (AREA)
  • Signal Processing (AREA)
  • Compression Or Coding Systems Of Tv Signals (AREA)
  • Television Signal Processing For Recording (AREA)

Abstract

本申请实施例提供了一种视频场景变化的检测方法、装置及视频采集设备,其中,方法包括获取第一视频码流的第一区块场景涨落数组;获取第二视频码流的第二区块场景涨落数组;基于所述第二区块场景涨落数组,判断所述第二视频码流的视频场景是否稳定;当所述第二视频码流的视频场景稳定时,利用所述第一区块场景涨落数组以及第二区块场景涨落数组,检测视频场景的变化。该方法先确定检测的视频场景稳定,再进行视频场景变化的检测,利用视频场景的涨落情况进行视频场景稳定的检测,能够较好地排除视频采集装置自身所产生的噪声对视频场景变化判断的干扰,提高了视频场景变化检测的准确性。

Description

视频场景变化的检测方法、装置及视频采集设备 技术领域
本申请涉及视频监控领域,具体涉及一种视频场景变化的检测方法、装置及视频采集设备。
背景技术
在视频监控系统中,视频采集装置是实现场景监控不可或缺的设备。其中,摄像机的应用最为广泛。摄像机需要根据当前场景的图像情况,使用自动曝光、自动聚焦、自动白平衡等算法来调整摄像机参数,以保证输出的图像处于高质量的状态,具体表现在图像清晰、曝光正确以及颜色正确等。
很多摄像机的应用场景下,拍摄目标可能会变化,如人物进入或者离开,被拍摄物离摄像机距离发生了变化,被拍摄物占画面的比例发生了变化。这都可能导致图像模糊,或者颜色失真等图像质量问题。其中,对于摄像机的很多典型应用场景,如监控和视频会议,一般情况下图像内容是不断变化的:即图像内拍摄目标物在不断变化。如马路上的监控摄像机,车辆和人员的来往,每帧图像和下一帧可能都不一样;普通室外场景,花草树木随风摆动;视频会议中人的坐姿变化、头和身体的晃动。
现有技术中对视频场景是否变化的检测是通过对视频帧的统计信息进行判断,例如,利用相邻两个视频帧的亮度值,或相邻两个视频帧的清晰度值进行对比分析,得出视频场景是否发生变化。
然而,本申请发明人在对现有的视频场景变化的检测方法的研究过程中发现,视频场景的变化除了包括以上场景所发生的明显变化以外,还包括由于摄像机自身噪声涨落(噪声变化的程度)所带来的干扰;而现有技术中的检测方法将噪声涨落所导致的干扰也判定为视频场景的变化,进而导致视频场景变化检测的准确性较低。
发明内容
有鉴于此,本申请实施例提供了一种视频场景变化的检测方法、装置及视频采集设备,以解决视频场景变化检测的准确性低的问题。
为此,本申请实施例提供了如下技术方案:
本申请第一方面提供了一种视频场景变化的检测方法,包括:
获取第一视频码流的第一区块场景涨落数组;其中,所述第一视频码流的视频场景稳定;所述第一视频码流包括第一预设数量的参考视频帧;所述第一区块场景涨落数组的元素数量与所述参考视频帧划分的第一区块的数量相同,每个所述元素用于表示所有所述参考视频帧中相同位置的所有第一区块的涨落,所述涨落用于表示场景的变化程度;
获取第二视频码流的第二区块场景涨落数组;其中,所述第二视频码流包括第二预设数量的观察视频帧;所述第二区块场景涨落数组的元素与所述观察视频帧划分的第二区块一一对应,每个所述元素用于表示所有所述观察视频帧中相同位置的第二区块的涨落;
基于所述第二区块场景涨落数组,判断所述第二视频码流的视频场景是否稳定;
当所述第二视频码流的视频场景稳定时,利用所述第一区块场景涨落数组以及第二区块场景涨落数组,检测视频场景的变化。
本申请实施例提供的视频场景变化的检测方法,在检测视频场景的变化之前,先通过观察视频帧的第二区块的涨落来确定视频场景是否稳定;即,先确定检测的视频场景稳定时,再进行视频场景变化的检测,该方法利用视频场景的涨落情况进行视频场景稳定的检测,能够较好地排除视频采集装置自身所产生的噪声对视频场景变化判断的干扰,提高了视频场景变化检测的准确性。
根据第一方面,在第一方面第一实施方式中,所述获取第二视频码流的第二区块场景涨落数组,包括:
获取第二统计信息列表;其中,所述第二统计信息列表包括所述第二预设数量的第二统计信息数组,所述第二统计信息数组与所述观察视频帧 一一对应,且所述第二统计信息数组的元素与所述观察视频帧的第二区块一一对应,用于表示各所述第二区块的场景统计值;
依次提取所有所述第二统计信息数组中与各所述第二区块对应的元素;
利用提取出的所述元素,计算各所述第二区块的涨落,以形成所述第二区块场景涨落数组。
本申请实施例提供的视频场景变化的检测方法,利用观察视频帧中各第二区块的场景统计值计算各第二区块对应的场景变化程度,以便于后续利用第二区块对应的场景变化程度,进行视频场景是否稳定的判断,具有较高的判断准确性。
根据第一方面第一实施方式,在第一方面第二实施方式中,采用如下公式计算所述第二区块的涨落:
Figure PCTCN2019107936-appb-000001
其中,
Figure PCTCN2019107936-appb-000002
上式中,c 2为所述第二预设数量,S″ k,i,j为所述第二统计信息列表中第k个第二统计信息数组的第i行第j列的元素,
Figure PCTCN2019107936-appb-000003
为所述第二区块场景涨落数组中第i行第j列的元素。
根据第一方面第二实施方式,在第一方面第三实施方式中,所述基于所述第二区块场景涨落数组,判断所述第二视频码流的视频场景是否稳定,包括:
计算所述第二区块场景涨落数组中所有元素的平均值,以得到所述第二视频码流的视频场景的涨落;
利用所述第二视频码流的视频场景的涨落与第一阈值的大小关系,判断所述第二视频码流的视频场景是否稳定。
本申请实施例提供的视频场景变化的检测方法,利用第二区块场景涨落数组中所有元素的平均值进行第二视频码流的视频场景稳定性的判断,在保证判断准确度的前提下,提高了检测效率。
根据第一方面第三实施方式,在第一方面第四实施方式中,采用如下 公式计算所述第二视频码流的视频场景的涨落:
Figure PCTCN2019107936-appb-000004
式中,M为所述观察视频帧所划分的行数,N为所述观察视频帧所划分的列数,
Figure PCTCN2019107936-appb-000005
为所述第二视频码流的视频场景的涨落。
根据第一方面,在第一方面第五实施方式中,所述利用所述第一区块场景涨落数组以及第二区块场景涨落数组,检测视频场景的变化,包括:
基于所述第一区块场景涨落数组,计算所述第一视频码流的视频场景的涨落;
计算第一视频场景涨落与第二视频场景涨落的差值的平均值,其中,所述第一视频场景涨落为所述第一视频码流的视频场景的涨落,所述第二视频场景涨落为所述第二视频码流的视频场景的涨落;
判断计算出的所述平均值是否大于第二阈值;
当所述平均值大于第二阈值时,计算所述第一区块场景涨落数组以及第二区块场景涨落数组的差值的绝对值,以得到差值数组;
统计所述差值数组中数值大于所述第二阈值的数量;
当统计出的数量大于第三阈值时,检测出所述视频场景发生变化。
本申请提供的视频场景变化的检测方法,利用视频场景稳定的第一视频码流作为视频场景是否变化的判断基准,在结合第二视频码流是否稳定,该方法对于视频场景短时间内受到干扰,并迅速恢复原样这一情况认定为视频场景并没有发生变化,能够避免频繁调整视频采集装置的参数,保证了视频采集装置参数的稳定性。
根据第一方面第六实施方式,在第一方面第七实施方式中,采用如下公式计算所述第一视频码流的视频场景涨落:
Figure PCTCN2019107936-appb-000006
式中,M为所述参考视频帧所划分的行数,N为所述参考视频帧所划分的列数,
Figure PCTCN2019107936-appb-000007
为所述第一区块场景涨落数组中第i行第j列的元素,
Figure PCTCN2019107936-appb-000008
为所述第一视频码流的视频场景的涨落。
根据第二方面,本申请还提供了一种视频场景变化检测装置,包括:
第一获取模块,用于获取第一视频码流的第一区块场景涨落数组;其中,所述第一视频码流的视频场景稳定;所述第一视频码流包括第一预设数量的参考视频帧;所述第一区块场景涨落数组的元素数量与所述参考视频帧划分的第一区块的数量相同,每个所述元素用于表示所有所述参考视频帧中相同位置的所有第一区块的涨落,所述涨落用于表示场景的变化程度;
第二获取模块,用于获取第二视频码流的第二区块场景涨落数组;其中,所述第二视频码流包括第二预设数量的观察视频帧;所述第二区块场景涨落数组的元素与所述观察视频帧划分的第二区块一一对应,每个所述元素用于表示所有所述观察视频帧中相同位置的所有第二区块的涨落;
判断模块,用于基于所述第二区块场景涨落数组,判断所述第二视频码流的视频场景是否稳定;
确定模块,用于当所述第二视频码流的视频场景稳定时,利用所述第一区块场景涨落数组以及第二区块场景涨落数组,检测视频场景的变化。
本申请实施例提供的视频场景变化的检测装置,在检测视频场景的变化之前,先通过观察视频帧的第二区块的涨落来确定视频场景是否稳定;即,先确定检测的视频场景稳定时,再进行视频场景变化的检测,该方法利用视频场景的涨落情况进行视频场景稳定的检测,能够较好地排除视频采集装置自身所产生的噪声对视频场景变化判断的干扰,提高了视频场景变化检测的准确性。
根据第三方面,本申请实施例还提供了一种视频采集设备,包括:至少一个处理器;以及与所述至少一个处理器通信连接的存储器;其中,所述存储器存储有可被所述一个处理器执行的指令,所述指令被所述至少一个处理器执行,以使所述至少一个处理器执行上述第一方面,或第一方面任一实施方式中所述的视频场景变化的检测方法。
根据第四方面,本申请实施例还提供了一种计算机可读存储介质,其 上存储有计算机指令,该指令被处理器执行时实现上述第一方面,或第一方面任一实施方式中所述视频场景变化的检测方法的步骤。
附图说明
为了更清楚地说明本申请具体实施方式或现有技术中的技术方案,下面将对具体实施方式或现有技术描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图是本申请的一些实施方式,对于本领域普通技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的附图。
图1是根据本申请实施例的视频场景变化的检测方法的流程图;
图2是根据本申请实施例的视频场景变化的检测方法的流程图;
图3是根据本申请实施例的视频场景变化的检测方法的流程图;
图4是根据本申请实施例的视频场景变化的检测方法的流程图;
图5是根据本申请实施例的视频场景变化的检测装置的结构框图;
图6是根据本申请实施例的视频场景变化的检测装置的结构框图;
图7是本申请实施例提供的视频采集装置的硬件结构示意图。
具体实施方式
为使本申请实施例的目的、技术方案和优点更加清楚,下面将结合本申请实施例中的附图,对本申请实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例是本申请一部分实施例,而不是全部的实施例。基于本申请中的实施例,本领域技术人员在没有作出创造性劳动前提下所获得的所有其他实施例,都属于本申请保护的范围。
根据本申请实施例,提供了一种视频场景变化的检测方法实施例,需要说明的是,在附图的流程图示出的步骤可以在诸如一组计算机可执行指令的计算机系统中执行,并且,虽然在流程图中示出了逻辑顺序,但是在某些情况下,可以以不同于此处的顺序执行所示出或描述的步骤。
需要说明的是,本申请实施例中所涉及的视频采集装置内可以设置有图像传感器以及图像处理模块,其中,图像传感器用于获取视频图像,图 像处理模块用于对图像传感器其所获取到的视频图像进行统计,获取多个指标图像统计信息。可选地,图像处理模块视频图像分为M行N列的区块(即M×N个区块),所划分出的每一区块对应于一个区块的统计信息,因此,对于一个统计指标,一帧图像可获得M×N个区块的场景统计值,即每一个视频帧对应于一个M×N的统计信息数组。
进一步地,场景统计值可以是清晰度值,也可以是亮度值。当场景统计值为清晰度值时,一帧图像分为M×N个区块,每个区块可统计出一个代表代表清洗度的FV值,即每一帧图像可得到一个FV数组,大小是M行N列。具体地,清晰度值是对一帧图像经过滤波后进行累加统计,衡量图像局部以及整体清洗度的指标,是自动聚焦的主要数据依据。当场景统计值为亮度信息时,一帧图像分为M×N个区块,每个区块可统计出一个代表亮度的Y值,即每一帧图像可得到一个亮度数组,大小是M行N列。具体地,亮度信息时对一帧图像的亮度信息进行统计,是自动聚焦的主要数据依据。
需要说明的是,每帧视频图像对应的区块的统计信息数组可以是视频采集装置中的图像处理模块对获取的视频图像进行处理得到的,也可以是其他模块或装置处理得到的,只需保证本申请实施例中的视频采集装置能够获取到每帧视频图像对应的区块的统计信息数组即可。此外,每个视频帧所划分出的区块的数量可以根据实际情况进行具体设置即可。
在本实施例中提供了一种视频场景变化的检测方法,可用于上述的视频采集装置,图1是根据本申请实施例的视频采集装置的流程图,如图1所示,该流程包括如下步骤:
S11,获取第一视频码流的第一区块场景涨落数组。
其中,第一视频码流的视频场景稳定;第一视频码流包括第一预设数量的参考视频帧;第一区块场景涨落数组的元素数量与参考视频帧划分的第一区块的数量相同,每个元素用于表示所有所述参考视频帧中相同位置的所有第一区块的涨落,涨落用于表示场景的变化程度。
具体地,关于第一视频码流,可以是事先确定的视频场景稳定的码流,也可以是在实时确定出的视频场景稳定的码流。不论采用何种方式确定视 频码流的场景稳定,只需保证视频图像采集设备能够获取到视频场景稳定的第一视频码流的第一区块场景涨落数组即可。
第一视频码流包括第一预设数量(例如,c 1,其中,c 1为大于1的常数)的参考视频帧,每个参考视频帧划分出M×N个第一区块。其中,第一视频码流对应于一个第一区块场景涨落数组,该第一区块场景涨落数组包括M×N个元素,对应于第(i,j)个元素,其中,1≤i≤M,1≤j≤N;即第一区块场景涨落数组中第i行第j列的元素,该元素用于表示所有参考视频帧中第(i,j)个第一区块的涨落。
可选地,所有参考视频帧中第(i,j)个第一区块的涨落,可以利用所有第(i,j)个第一区块的统计值以及所有参考视频帧的所有第一区块的统计值,计算标准差,或方差等等,计算出的标准差或方差即为第(i,j)个第一区块的涨落,也即是第一区块场景涨落数组中第i行第j列的元素。
S12,获取第二视频码流的第二区块场景涨落数组。
其中,第二视频码流包括第二预设数量的观察视频帧;第二区块场景涨落数组的元素与观察视频帧划分的第二区块一一对应,每个元素用于表示所有观察视频帧中相同位置的第二区块的涨落。
第二视频码流包括第二预设数量(例如,c 2,其中,c 2为大于1的常数)的观察视频帧,每个观察视频帧划分出M×N个第二区块。其中,第二视频码流对应于一个第二区块场景涨落数组,该第二区块场景涨落数组包括M×N个元素,对应于第(i,j)个元素,即第二区块场景涨落数组中第i行第j列的元素,该元素用于表示所有观察视频帧中第(i,j)个第二区块的涨落。
可选地,所有观察视频帧中第(i,j)个第二区块的涨落,可以利用所有第(i,j)个第二区块的统计值以及所有观察视频帧的所有第二区块的统计值,计算标准差,或方差等等,计算出的标准差或方差即为第(i,j)个第二区块的涨落,也即是第二区块场景涨落数组中第i行第j列的元素。
S13,基于第二区块场景涨落数组,判断第二视频码流的视频场景是否稳定。
视频采集设备在获取到第二区块场景涨落数组之后,利用其进行第二视频码流的视频场景是否稳定的判断。例如,可以利用第二区块场景涨落数组中的每个元素与预设值之间的大小关系进行判断,也可以利用第二区场景涨落数组中所有元素的平均值与预设值之间的大小关系进行判断,等等。
当确定出第二视频码流的视频场景稳定时,执行S14;否则,可以执行其他操作。其中,可选地,其他操作可以是返回执行S12,再次获取第二区块场景涨落数组,以便再次进行第二视频码流的场景是否稳定的判断;其他操作也可以是间隔预设时间段之后,再次获取第二区块场景涨落数组等等。
S14,当第二视频码流的视频场景稳定时,利用第一区块场景涨落数组以及第二区块场景涨落数组,检测视频场景的变化。
在视频采集设备确定出第二视频码流的视频场景稳定时,由于第一区块场景涨落数组对应的第一视频码流,以及第二区块场景涨落数组对应的第二视频码流的视频场景全部是稳定的,因此,在第一区块场景涨落数组以及第二区块场景涨落数组的基础上,检测视频场景的变化能够提高检测的准确性。
具体在检测视频场景的变化时,可以计算第一区块场景涨落数组与第二区块场景涨落数组的差值,得到的差值数组与预设数组进行大小关系的判断,也可以分别计算第一区块场景涨落数组与第二区块场景涨落数组的平均值,利用两者平均值的差值进行判断等等。
本申请实施例提供的视频场景变化的检测方法,在检测视频场景的变化之前,先通过观察视频帧的第二区块的涨落来确定视频场景是否稳定;即,先确定检测的视频场景稳定时,再进行视频场景变化的检测,该方法利用视频场景的涨落情况进行视频场景稳定的检测,能够较好地排除视频采集装置自身所产生的噪声对视频场景变化判断的干扰,提高了视频场景 变化检测的准确性。
本申请实施例还提供了一种视频场景变化的检测方法,如图2所示,该方法包括:
S21,获取第一视频码流的第一区块场景涨落数组。
其中,第一视频码流的视频场景稳定;第一视频码流包括第一预设数量的参考视频帧;第一区块场景涨落数组的元素数量与参考视频帧划分的第一区块的数量相同,每个元素用于表示所有所述参考视频帧中相同位置的所有第一区块的涨落,涨落用于表示场景的变化程度。
详细请参见图1所示实施例的S11,在此不再赘述。
S22,获取第二视频码流的第二区块场景涨落数组。
其中,第二视频码流包括第二预设数量的观察视频帧;第二区块场景涨落数组的元素与观察视频帧划分的第二区块一一对应,每个元素用于表示所有观察视频帧中相同位置的第二区块的涨落。
具体地,第二区块场景涨落数组通过如下步骤获取:
S221,获取第二统计信息列表。
其中,第二统计信息列表包括第二预设数量的第二统计信息数组,第二统计信息数组与观察视频帧一一对应,且第二统计信息数组的元素与观察视频帧的第二区块一一对应,用于表示各第二区块的场景统计值。
第二视频码流包括第二预设数量(例如,c 2)的观察视频帧,每一个观察视频帧对应于一个第二统计信息数组,所有第二统计信息数组存储在第二统计信息列表中,具体地,采用如下形式表示:
SL watch={S watch1,S watch2,S watch3,…,S watchk,…,S watchc 2};其中,SL watch为第二统计信息列表,S watchk为第二统计信息列表中第k个第二统计信息数组,即第二视频码流中第k帧观察视频帧对应的第二统计信息数组。由于S watchk为M×N的二维数组,因此,SL watch为三维数组,三个维度分别为帧、行和列,例如,S watch(k,i,j)为第二统计信息列表中第k帧中第i行第j列的统计信息。其中,1≤k≤c 2
具体地,视频采集设备在不断获取观察视频帧,将获取到的观察视频 帧对应的第二统计信息数组填入SL watch中,直至填满c2为止;若未填满,则继续等待下一观察视频帧的第二统计信息数组,继续填入SL watch中。
S222,依次提取所有第二统计信息数组中与各第二区块对应的元素。
具体地,依次所有观察视频帧中第(i,j)个第二区块对应的第二统计信息数组中的元素,即,依次提取S watch(1,i,j),S watch(2,i,j),…,S watch(k,i,j),…,S watch(c 2,i,j),其中,1≤i≤M,1≤j≤N。
S223,利用提取出的元素,计算各第二区块的涨落,以形成第二区块场景涨落数组。
视频采集设备利用提取出的元素,计算各第二区块的涨落,即采用如下公式计算所述第二区块的涨落:
Figure PCTCN2019107936-appb-000009
其中,
Figure PCTCN2019107936-appb-000010
Figure PCTCN2019107936-appb-000011
上式中,c 2为所述第二预设数量,S watch(k,i,j)为所述第二统计信息列表中第k个第二统计信息数组的第i行第j列的元素,
Figure PCTCN2019107936-appb-000012
为所述第二区块场景涨落数组中第i行第j列的元素。
具体地,第二区块场景涨落数组可以采用如下方式表示:
Figure PCTCN2019107936-appb-000013
其中,1≤i≤M,1≤j≤N。
S23,基于第二区块场景涨落数组,判断第二视频码流的视频场景是否稳定。
视频采集装置基于第二区块场景涨落数组,计算第二区块场景涨落数组中所有元素的平均值,利用该平均值判断第二视频码流的视频场景是否稳定。具体包括:
S231,计算第二区块场景涨落数组中所有元素的平均值,以得到第二视频码流的视频场景的涨落。
视频采集装置采用如下公式计算所述第二视频码流的视频场景的涨落:
Figure PCTCN2019107936-appb-000014
式中,M为所述观察视频帧所划分的行数,N为所述观察视频帧所划分的列数,
Figure PCTCN2019107936-appb-000015
为所述第二视频码流的视频场景的涨落。
S232,利用第二视频码流的视频场景的涨落与第一阈值的大小关系,判断第二视频码流的视频场景是否稳定。
具体地,若
Figure PCTCN2019107936-appb-000016
小于
Figure PCTCN2019107936-appb-000017
则确定第二视频码流的视频场景稳定;否则,则认为第二视频码流的视频场景不稳定。其中,
Figure PCTCN2019107936-appb-000018
为判断第二视频码流的视频场景是否稳定的第一阈值,该值可以是一个常数,具体可以根据实际情况进行设置。
当第二视频码流的视频场景稳定时,执行S24;否则,执行S221。
S24,当第二视频码流的视频场景稳定时,利用第一区块场景涨落数组以及第二区块场景涨落数组,检测视频场景的变化。详细请参见图1所示实施例的S14,在此不再赘述。
与图1所示实施例相比,本实施例提供的视频场景变化的检测方法,利用观察视频帧中各第二区块的场景统计值计算各第二区块对应的场景变化程度,以便于后续利用第二区块对应的场景变化程度,进行视频场景是否稳定的判断,具有较高的判断准确性。
作为本实施例的一种可选实施方式,在S231中,还可以先进行加权计算,即设置一个权重数组W,其中W的大小是M行N列的,和
Figure PCTCN2019107936-appb-000019
的大小相同。利用权重数组W对
Figure PCTCN2019107936-appb-000020
进行加权平均得到
Figure PCTCN2019107936-appb-000021
本申请实施例还提供了一种视频图像变化的检测方法,如图3所示, 该方法包括:
S31,获取第一视频码流的第一区块场景涨落数组。
其中,第一视频码流的视频场景稳定;第一视频码流包括第一预设数量的参考视频帧;第一区块场景涨落数组的元素数量与参考视频帧划分的第一区块的数量相同,每个元素用于表示所有所述参考视频帧中相同位置的所有第一区块的涨落,涨落用于表示场景的变化程度。
具体地,包括以下步骤:
S311,获取第一统计信息列表。
其中,第一统计信息列表包括第一预设数量的第一统计信息数组,第一统计信息数组与参考视频帧一一对应,且第一统计信息数组的元素与参考视频帧的第二区块一一对应,用于表示各第一区块的场景统计值。
SL ref={S ref1,S ref2,S ref3,…,S refq,…,S refc 1};其中,SL ref为第一统计信息列表,S refq为第一统计信息列表中第q个第一统计信息数组,即第一视频码流中第k帧参考视频帧对应的第一统计信息数组。由于S refq为M×N的二维数组,因此,SL ref为三维数组,三个维度分别为帧、行和列,例如,S ref(q,i,j)为第一统计信息列表中第q帧中第i行第j列的统计信息。其中,1≤q≤c 1
S312,依次提取所有第二统计信息数组中与各第二区块对应的元素。
依次提取S ref(1,i,j),S ref(2,i,j),…,S ref(q,i,j),…,S ref(c 1,i,j),其中,1≤i≤M,1≤j≤N。
S313,利用提取出的元素,计算各第一区块的涨落,以形成第一区块场景涨落数组。
视频采集设备利用提取出的元素,计算各第一区块的涨落,即采用如下公式计算所述第一区块的涨落:
Figure PCTCN2019107936-appb-000022
其中,
Figure PCTCN2019107936-appb-000023
Figure PCTCN2019107936-appb-000024
上式中,c 1为所述第一预设数量,S ref(q,i,j)为所述第一统计信息列表中 第q个第一统计信息数组的第i行第j列的元素,
Figure PCTCN2019107936-appb-000025
为所述第一区块场景涨落数组中第i行第j列的元素。
具体地,第一区块场景涨落数组可以采用如下方式表示:
Figure PCTCN2019107936-appb-000026
其中,1≤i≤M,1≤j≤N。
S314,基于第一区块场景涨落数组,判断第一视频码流的视频场景是否稳定。
具体地,采用如下公式计算所述第一视频码流的视频场景的涨落:
Figure PCTCN2019107936-appb-000027
式中,M为所述参考视频帧所划分的行数,N为所述参考视频帧所划分的列数,
Figure PCTCN2019107936-appb-000028
为所述第一区块场景涨落数组中第i行第j列的元素,
Figure PCTCN2019107936-appb-000029
为所述第一视频码流的视频场景的涨落。
Figure PCTCN2019107936-appb-000030
小于
Figure PCTCN2019107936-appb-000031
则确定第一视频码流的视频场景稳定;否则,则认为第一视频码流的视频场景不稳定。其中,
Figure PCTCN2019107936-appb-000032
为判断第一视频码流的视频场景是否稳定的阈值,该值可以是一个常数,具体可以根据实际情况进行设置。若判断出当前第一视频码流不稳定时,返回执行S331;否则,执行S32。
其余具体过程请参见图2所示实施例的S22至S23,在此不再赘述。
S32,获取第二视频码流的第二区块场景涨落数组。
其中,第二视频码流包括第二预设数量的观察视频帧;第二区块场景涨落数组的元素与观察视频帧划分的第二区块一一对应,每个元素用于表示所有观察视频帧中相同位置的第二区块的涨落。
详细请参见图2所示实施例的S22,在此不再赘述。
S33,基于第二区块场景涨落数组,判断第二视频码流的视频场景是否稳定。
详细请参见图2所示实施例的S23,在此不再赘述。
S34,当第二视频码流的视频场景稳定时,利用第一区块场景涨落数组以及第二区块场景涨落数组,检测视频场景的变化。
视频采集设备通过如下步骤,检测视频场景的变化,具体为:
S341,基于第一区块场景涨落数组,计算第一视频码流的视频场景的涨落。
第一视频码流的视频场景的涨落
Figure PCTCN2019107936-appb-000033
可参见S314的描述,在该步骤中直接提取出
Figure PCTCN2019107936-appb-000034
即可。
S342,计算第一视频场景涨落与第二视频场景涨落的差值的绝对值。
其中,第一视频场景涨落为第一视频码流的视频场景的涨落,第二视频场景涨落为第二视频码流的视频场景的涨落。具体地,采用如下公式计算差值的绝对值:
Figure PCTCN2019107936-appb-000035
其中,
Figure PCTCN2019107936-appb-000036
为第一视频码流的视频场景的涨落,即为第一视频场景涨落;
Figure PCTCN2019107936-appb-000037
为第二视频码流的视频场景的涨落,即为第二视频场景涨落;
Figure PCTCN2019107936-appb-000038
为差值的绝对值。
S343,判断计算出的绝对值是否大于第二阈值。
Figure PCTCN2019107936-appb-000039
大于Th diff时,则执行S344;否则,确定视频场景没有发生变化。
其中,Th diff为第二阈值。
S344,当平均值大于第二阈值时,计算第一区块场景涨落数组以及第二区块场景涨落数组的差值的绝对值,以得到差值数组。
具体地,差值数组σ diff为M×N的二维数组,其中,
Figure PCTCN2019107936-appb-000040
σ diff(i,j)为差值数组中第i行第j列的元素,1≤i≤M,1≤j≤N。
S345,统计差值数组中数值大于第二阈值的数量。
依次判断差值数组σ diff中每个元素是否大于第二阈值,若大于第二阈值,则将统计值加1。其中,统计值为cnt change
S346,当统计出的数量大于第三阈值时,检测出视频场景发生变化。
视频采集装置在cnt change大于第三阈值Th cnt时,确定视频场景发生变化;因此,视频场景发生变化需具备两个必要条件:(1)S343中差值的绝对值大于第二阈值;(2)S346中统计出的数量大于第三阈值。当两者同时满足时,确认出视频场景发生变化;否则,都认为视频场景没有发生变化,返回S32继续进行判断。
与图2所示实施例相比,本申请实施例提供的视频场景变化的检测方法,利用视频场景稳定的第一视频码流作为视频场景是否变化的判断基准,在结合第二视频码流是否稳定,该方法对于视频场景短时间内受到干扰,并迅速恢复原样这一情况认定为视频场景并没有发生变化,能够避免频繁调整视频采集装置的参数,保证了视频采集装置参数的稳定性。
本申请实施例还提供了一种视频场景变化的检测方法的应用实例,如图4所示,在本实施例中用区块fv信息判断自动聚焦场景是否发生变化,如果变化则需要触发自动聚焦。
视频采集设备包括:具有电动变焦和自动聚焦模块的摄像机、聚焦镜片组、以及驱动聚焦的装置(电机)、清晰度值(FV)获取模块、数据储存模块以及计算模块。
(1)填写参考帧FV区块统计信息列表SL ref,每帧进行一次,将获取到新一帧区块统计信息S new填入SL ref,直到填满c 1(c_1为大于1的常数)帧,如果填满,则计算
Figure PCTCN2019107936-appb-000041
Figure PCTCN2019107936-appb-000042
否则继续等待下一帧区块统计信息,继续填入SL ref。这里在根据
Figure PCTCN2019107936-appb-000043
计算其均值
Figure PCTCN2019107936-appb-000044
时,可进行加权计算,设置一个权重数组W(W的大小是M行N列,和
Figure PCTCN2019107936-appb-000045
相同大小),对数组
Figure PCTCN2019107936-appb-000046
进行加权平均。
(2)判断当前场景是否稳定,如果满足
Figure PCTCN2019107936-appb-000047
则认为SL ref稳定,即当前场景是稳定的,进入获取观察帧区块统计信息列表SL watch。否则认为这段时间内统计的数据不稳定,则进入步骤(1),继续填SL ref,方法是滚 动刷新,覆盖掉数组中最早一帧的数据。
(3)填写观察帧FV区块统计信息列表SL watch,方法和参考帧区块统计信息列表SL ref一样,将获取到新一帧区块统计信息S new填入SL watch,直到填满c 2(c 2为大于1的常数)帧,如果填满,则计算
Figure PCTCN2019107936-appb-000048
Figure PCTCN2019107936-appb-000049
否则继续等待下一帧区块统计信息,继续填入SL watch。这里在根据
Figure PCTCN2019107936-appb-000050
计算其均值
Figure PCTCN2019107936-appb-000051
时,如果
Figure PCTCN2019107936-appb-000052
是用权重矩阵W加权平均计算出来的,那么用权重矩阵W对数组
Figure PCTCN2019107936-appb-000053
进行加权平均求
Figure PCTCN2019107936-appb-000054
(4)判断当前场景是否稳定,如果满足
Figure PCTCN2019107936-appb-000055
则认为SL watch稳定,即当前场景是稳定的,进入判断场景是否变化。否则认为这段时间内统计的数据不稳定,则进入步骤(3),继续填SL watch,方法是滚动刷新,覆盖掉数组中最早一帧的数据。
(5)判断场景是否发生变化。判断场景发生变化的必要条件有两个,一是判断区块统计信息列表的标准差的平均值是否发生变化,二是判断区块发生变化的个数Cnt change是否超过阈值Th cnt。如果以上两个条件都满足,则认为场景发生了变化,进入步骤(6)。如果场景没有变化,则进入步骤(3),继续滚动填写观察帧区块统计信息列表SL watch
(6)通知自动聚焦模块场景发生了变化,即触发自动聚焦,清空参考帧区块统计信息列表SL ref和观察帧区块统计信息列表SL watch
(7)等待自动聚焦完成后进入步骤(1)。
在本实施例中还提供了一种视频场景变化的检测装置,该装置用于实现上述实施例及优选实施方式,已经进行过说明的不再赘述。如以下所使用的,术语“模块”可以实现预定功能的软件和/或硬件的组合。尽管以下实施例所描述的装置较佳地以软件来实现,但是硬件,或者软件和硬件的组合的实现也是可能并被构想的。
本实施例提供一种视频场景变化的检测装置,如图5所示,包括:
第一获取模块51,用于获取第一视频码流的第一区块场景涨落数组。其中,第一视频码流的视频场景稳定;第一视频码流包括第一预设数量的参考视频帧;第一区块场景涨落数组的元素数量与参考视频帧划分的第一 区块的数量相同,每个元素用于表示所有参考视频帧中相同位置的所有第一区块的涨落,涨落用于表示场景的变化程度。
第二获取模块52,用于获取第二视频码流的第二区块场景涨落数组。其中,第二视频码流包括第二预设数量的观察视频帧;第二区块场景涨落数组的元素与观察视频帧划分的第二区块一一对应,每个元素用于表示所有观察视频帧中相同位置的所有第二区块的涨落。
判断模块53,用于基于第二区块场景涨落数组,判断第二视频码流的视频场景是否稳定。
确定模块54,用于当第二视频码流的视频场景稳定时,利用第一区块场景涨落数组以及第二区块场景涨落数组,检测视频场景的变化。
本申请实施例提供的视频场景变化的检测装置,在检测视频场景的变化之前,先通过观察视频帧的第二区块的涨落来确定视频场景是否稳定;即,先确定检测的视频场景稳定时,再进行视频场景变化的检测,该方法利用视频场景的涨落情况进行视频场景稳定的检测,能够较好地排除视频采集装置自身所产生的噪声对视频场景变化判断的干扰,提高了视频场景变化检测的准确性。
在本实施例的一些可选实施方式中,如图6所示,其中,第二获取模块52包括:
获取单元521,用于获取第二统计信息列表;其中,第二统计信息列表包括第二预设数量的第二统计信息数组,第二统计信息数组与观察视频帧一一对应,且第二统计信息数组的元素与观察视频帧的第二区块一一对应,用于表示各第二区块的场景统计值。
提取单元522,用于依次提取所有第二统计信息数组中与各第二区块对应的元素。
计算单元523,用于利用提取出的所述元素,计算各第二区块的涨落,以形成第二区块场景涨落数组。
在本实施例的另一些可选实施方式中,采用如下公式计算第二区块的涨落:
Figure PCTCN2019107936-appb-000056
其中,
Figure PCTCN2019107936-appb-000057
Figure PCTCN2019107936-appb-000058
上式中,c 2为所述第二预设数量,S watch(k,i,j)为所述第二统计信息列表中第k个第二统计信息数组的第i行第j列的元素,
Figure PCTCN2019107936-appb-000059
为所述第二区块场景涨落数组中第i行第j列的元素。
本实施例中的视频场景变化的检测装置是以功能单元的形式来呈现,这里的单元是指ASIC电路,执行一个或多个软件或固定程序的处理器和存储器,和/或其他可以提供上述功能的器件。
上述各个模块的更进一步的功能描述与上述对应实施例相同,在此不再赘述。
本申请实施例还提供一种视频采集设备,具有上述图5或图6所示的视频场景变化的检测装置。
请参阅图7,图7是本申请可选实施例提供的一种视频采集设备的结构示意图,如图7所示,该视频采集设备可以包括:至少一个处理器71,例如CPU(Central Processing Unit,中央处理器),至少一个通信接口74,存储器74,至少一个通信总线72。其中,通信总线72用于实现这些组件之间的连接通信。其中,通信接口74可以包括显示屏(Display)、键盘(Keyboard),可选通信接口74还可以包括标准的有线接口、无线接口。存储器74可以是高速RAM存储器(Random Access Memory,易挥发性随机存取存储器),也可以是非不稳定的存储器(non-volatile memory),例如至少一个磁盘存储器。存储器74可选的还可以是至少一个位于远离前述处理器71的存储装置。其中处理器71可以结合图5或图6所描述的装置,存储器74中存储应用程序,且处理器71调用存储器74中存储的程序代码,以用于执行上述任一方法步骤。
其中,通信总线72可以是外设部件互连标准(peripheral component interconnect,简称PCI)总线或扩展工业标准结构(extended industry  standard architecture,简称EISA)总线等。通信总线72可以分为地址总线、数据总线、控制总线等。为便于表示,图7中仅用一条粗线表示,但并不表示仅有一根总线或一种类型的总线。
其中,存储器74可以包括易失性存储器(英文:volatile memory),例如随机存取存储器(英文:random-access memory,缩写:RAM);存储器也可以包括非易失性存储器(英文:non-volatile memory),例如快闪存储器(英文:flash memory),硬盘(英文:hard disk drive,缩写:HDD)或固态硬盘(英文:solid-state drive,缩写:SSD);存储器74还可以包括上述种类的存储器的组合。
其中,处理器71可以是中央处理器(英文:central processing unit,缩写:CPU),网络处理器(英文:network processor,缩写:NP)或者CPU和NP的组合。
其中,处理器71还可以进一步包括硬件芯片。上述硬件芯片可以是专用集成电路(英文:application-specific integrated circuit,缩写:ASIC),可编程逻辑器件(英文:programmable logic device,缩写:PLD)或其组合。上述PLD可以是复杂可编程逻辑器件(英文:complex programmable logic device,缩写:CPLD),现场可编程逻辑门阵列(英文:field-programmable gate array,缩写:FPGA),通用阵列逻辑(英文:generic array logic,缩写:GAL)或其任意组合。
可选地,存储器74还用于存储程序指令。处理器71可以调用程序指令,实现如本申请图1至4实施例中所示的视频图像变化的检测方法。
本申请实施例还提供了一种非暂态计算机存储介质,所述计算机存储介质存储有计算机可执行指令,该计算机可执行指令可执行上述任意方法实施例中的视频图像变化的检测方法。其中,所述存储介质可为磁碟、光盘、只读存储记忆体(Read-Only Memory,ROM)、随机存储记忆体(Random Access Memory,RAM)、快闪存储器(Flash Memory)、硬盘(Hard Disk Drive,缩写:HDD)或固态硬盘(Solid-State Drive,SSD)等;所述存储介质还可以包括上述种类的存储器的组合。
虽然结合附图描述了本申请的实施例,但是本领域技术人员可以在不脱离本申请的精神和范围的情况下作出各种修改和变型,这样的修改和变型均落入由所附权利要求所限定的范围之内。

Claims (10)

  1. 一种视频场景变化的检测方法,其特征在于,包括:
    获取第一视频码流的第一区块场景涨落数组;其中,所述第一视频码流的视频场景稳定;所述第一视频码流包括第一预设数量的参考视频帧;所述第一区块场景涨落数组的元素数量与所述参考视频帧划分的第一区块的数量相同,每个所述元素用于表示所有所述参考视频帧中相同位置的所有第一区块的涨落,所述涨落用于表示场景的变化程度;
    获取第二视频码流的第二区块场景涨落数组;其中,所述第二视频码流包括第二预设数量的观察视频帧;所述第二区块场景涨落数组的元素与所述观察视频帧划分的第二区块一一对应,每个所述元素用于表示所有所述观察视频帧中相同位置的第二区块的涨落;
    基于所述第二区块场景涨落数组,判断所述第二视频码流的视频场景是否稳定;
    当所述第二视频码流的视频场景稳定时,利用所述第一区块场景涨落数组以及第二区块场景涨落数组,检测视频场景的变化。
  2. 根据权利要求1所述的方法,其特征在于,所述获取第二视频码流的第二区块场景涨落数组,包括:
    获取第二统计信息列表;其中,所述第二统计信息列表包括所述第二预设数量的第二统计信息数组,所述第二统计信息数组与所述观察视频帧一一对应,且所述第二统计信息数组的元素与所述观察视频帧的第二区块一一对应,用于表示各所述第二区块的场景统计值;
    依次提取所有所述第二统计信息数组中与各所述第二区块对应的元素;
    利用提取出的所述元素,计算各所述第二区块的涨落,以形成所述第二区块场景涨落数组。
  3. 根据权利要求2所述的方法,其特征在于,采用如下公式计算所述第二区块的涨落:
    Figure PCTCN2019107936-appb-100001
    其中,
    Figure PCTCN2019107936-appb-100002
    上式中,c 2为所述第二预设数量,S″ k,i,j为所述第二统计信息列表中第k个第二统计信息数组的第i行第j列的元素,
    Figure PCTCN2019107936-appb-100003
    为所述第二区块场景涨落数组中第i行第j列的元素。
  4. 根据权利要求3所述的方法,其特征在于,所述基于所述第二区块场景涨落数组,判断所述第二视频码流的视频场景是否稳定,包括:
    计算所述第二区块场景涨落数组中所有元素的平均值,以得到所述第二视频码流的视频场景的涨落;
    利用所述第二视频码流的视频场景的涨落与第一阈值的大小关系,判断所述第二视频码流的视频场景是否稳定。
  5. 根据权利要求4所述的方法,其特征在于,采用如下公式计算所述第二视频码流的视频场景的涨落:
    Figure PCTCN2019107936-appb-100004
    式中,M为所述观察视频帧所划分的行数,N为所述观察视频帧所划分的列数,
    Figure PCTCN2019107936-appb-100005
    为所述第二视频码流的视频场景的涨落。
  6. 根据权利要求1所述的方法,其特征在于,所述利用所述第一区块场景涨落数组以及第二区块场景涨落数组,检测视频场景的变化,包括:
    基于所述第一区块场景涨落数组,计算所述第一视频码流的视频场景的涨落;
    计算第一视频场景涨落与第二视频场景涨落的差值的平均值,其中,所述第一视频场景涨落为所述第一视频码流的视频场景的涨落,所述第二视频场景涨落为所述第二视频码流的视频场景的涨落;
    判断计算出的所述平均值是否大于第二阈值;
    当所述平均值大于第二阈值时,计算所述第一区块场景涨落数组以及第二区块场景涨落数组的差值的绝对值,以得到差值数组;
    统计所述差值数组中数值大于所述第二阈值的数量;
    当统计出的数量大于第三阈值时,检测出所述视频场景发生变化。
  7. 根据权利要求6所述的方法,其特征在于,采用如下公式计算所述第一视频码流的视频场景涨落:
    Figure PCTCN2019107936-appb-100006
    式中,M为所述参考视频帧所划分的行数,N为所述参考视频帧所划分的列数,
    Figure PCTCN2019107936-appb-100007
    为所述第一区块场景涨落数组中第i行第j列的元素,
    Figure PCTCN2019107936-appb-100008
    为所述第一视频码流的视频场景的涨落。
  8. 一种视频场景变化检测装置,其特征在于,包括:
    第一获取模块,用于获取第一视频码流的第一区块场景涨落数组;其中,所述第一视频码流的视频场景稳定;所述第一视频码流包括第一预设数量的参考视频帧;所述第一区块场景涨落数组的元素数量与所述参考视频帧划分的第一区块的数量相同,每个所述元素用于表示所有所述参考视频帧中相同位置的所有第一区块的涨落,所述涨落用于表示场景的变化程度;
    第二获取模块,用于获取第二视频码流的第二区块场景涨落数组;其中,所述第二视频码流包括第二预设数量的观察视频帧;所述第二区块场景涨落数组的元素与所述观察视频帧划分的第二区块一一对应,每个所述元素用于表示所有所述观察视频帧中相同位置的所有第二区块的涨落;
    判断模块,用于基于所述第二区块场景涨落数组,判断所述第二视频码流的视频场景是否稳定;
    确定模块,用于当所述第二视频码流的视频场景稳定时,利用所述第一区块场景涨落数组以及第二区块场景涨落数组,检测视频场景的变化。
  9. 一种视频采集设备,其特征在于,包括:至少一个处理器;以及与所述至少一个处理器通信连接的存储器;其中,所述存储器存储有可被所述一个处理器执行的指令,所述指令被所述至少一个处理器执行,以使所述至少一个处理器执行上述权利要求1-7中任一所述的视频场景变化的检测方法。
  10. 一种计算机可读存储介质,其上存储有计算机指令,其特征在于,该指令被处理器执行时实现上述权利要求1-7中任一所述视频场景变化的检测方法的步骤。
PCT/CN2019/107936 2018-09-27 2019-09-25 视频场景变化的检测方法、装置及视频采集设备 WO2020063688A1 (zh)

Priority Applications (1)

Application Number Priority Date Filing Date Title
EP19864103.7A EP3840381A4 (en) 2018-09-27 2019-09-25 VIDEO SCENE CHANGE DETECTION METHOD AND DEVICE, AND VIDEO ACQUISITION DEVICE

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201811133555.8 2018-09-27
CN201811133555.8A CN109168001B (zh) 2018-09-27 2018-09-27 视频场景变化的检测方法、装置及视频采集设备

Publications (1)

Publication Number Publication Date
WO2020063688A1 true WO2020063688A1 (zh) 2020-04-02

Family

ID=64892598

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2019/107936 WO2020063688A1 (zh) 2018-09-27 2019-09-25 视频场景变化的检测方法、装置及视频采集设备

Country Status (3)

Country Link
EP (1) EP3840381A4 (zh)
CN (1) CN109168001B (zh)
WO (1) WO2020063688A1 (zh)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109168001B (zh) * 2018-09-27 2021-02-12 苏州科达科技股份有限公司 视频场景变化的检测方法、装置及视频采集设备
CN112203092B (zh) * 2020-09-27 2024-01-30 深圳市梦网视讯有限公司 一种全局运动场景的码流分析方法、系统及设备

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20030228056A1 (en) * 2002-06-10 2003-12-11 Pulsent Corporation Scene change detection by segmentation analysis
JP2013225728A (ja) * 2012-04-19 2013-10-31 Sharp Corp 画像処理装置、画像表示装置、シーンチェンジ発生検出方法、コンピュータプログラム及び記録媒体
CN104168462A (zh) * 2014-08-27 2014-11-26 重庆大学 基于图像角点集特征的摄像头场景变换检测方法
CN104270553A (zh) * 2014-09-28 2015-01-07 北京奇艺世纪科技有限公司 一种视频场景切换检测方法及装置
CN104796660A (zh) * 2014-01-20 2015-07-22 腾讯科技(深圳)有限公司 一种防盗告警的方法及装置
CN104811586A (zh) * 2015-04-24 2015-07-29 福建星网锐捷安防科技有限公司 场景变换视频智能分析方法、装置、网络摄像机及监控系统
CN109168001A (zh) * 2018-09-27 2019-01-08 苏州科达科技股份有限公司 视频场景变化的检测方法、装置及视频采集设备

Family Cites Families (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7483484B2 (en) * 2003-10-09 2009-01-27 Samsung Electronics Co., Ltd. Apparatus and method for detecting opaque logos within digital video signals
JP2009088686A (ja) * 2007-09-27 2009-04-23 Fujifilm Corp シーン切り替え点検出装置及びシーン切り替え点検出方法
US8103116B1 (en) * 2009-03-02 2012-01-24 Sandia Corporation Estimating pixel variances in the scenes of staring sensors
EP2362396B1 (en) * 2010-02-26 2014-06-04 Comcast Cable Communications, LLC Video scene segmentation and classification to skip advertisements.
JP5451494B2 (ja) * 2010-04-06 2014-03-26 キヤノン株式会社 画像処理装置および画像処理方法
JP6462119B2 (ja) * 2014-09-30 2019-01-30 マイクロソフト テクノロジー ライセンシング,エルエルシー コンピューティングデバイス
CN104822009B (zh) * 2015-04-14 2017-11-28 无锡天脉聚源传媒科技有限公司 一种视频场景变换识别的方法及装置
CN107770538B (zh) * 2016-08-23 2020-09-11 华为技术有限公司 一种检测场景切换帧的方法、装置和系统

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20030228056A1 (en) * 2002-06-10 2003-12-11 Pulsent Corporation Scene change detection by segmentation analysis
JP2013225728A (ja) * 2012-04-19 2013-10-31 Sharp Corp 画像処理装置、画像表示装置、シーンチェンジ発生検出方法、コンピュータプログラム及び記録媒体
CN104796660A (zh) * 2014-01-20 2015-07-22 腾讯科技(深圳)有限公司 一种防盗告警的方法及装置
CN104168462A (zh) * 2014-08-27 2014-11-26 重庆大学 基于图像角点集特征的摄像头场景变换检测方法
CN104270553A (zh) * 2014-09-28 2015-01-07 北京奇艺世纪科技有限公司 一种视频场景切换检测方法及装置
CN104811586A (zh) * 2015-04-24 2015-07-29 福建星网锐捷安防科技有限公司 场景变换视频智能分析方法、装置、网络摄像机及监控系统
CN109168001A (zh) * 2018-09-27 2019-01-08 苏州科达科技股份有限公司 视频场景变化的检测方法、装置及视频采集设备

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
BINDU, R. ET AL.: "Comparison of Scene Change Detection Algorithms for Videos", 2015 FIFTH INTERNATIONAL CONFERENCE ON ADVANCED COMPUTING & COMMUNICATION TECHNOLOGIES, 31 December 2015 (2015-12-31), pages 84 - 89, XP032760072 *

Also Published As

Publication number Publication date
CN109168001B (zh) 2021-02-12
EP3840381A4 (en) 2021-10-20
CN109168001A (zh) 2019-01-08
EP3840381A1 (en) 2021-06-23

Similar Documents

Publication Publication Date Title
CN110149482B (zh) 对焦方法、装置、电子设备和计算机可读存储介质
US11790504B2 (en) Monitoring method and apparatus
US8184196B2 (en) System and method to generate depth data using edge detection
EP3783564A1 (en) Image processing method, computer readable storage medium, and electronic device
EP2549738B1 (en) Method and camera for determining an image adjustment parameter
WO2020094091A1 (zh) 一种图像抓拍方法、监控相机及监控系统
WO2021047345A1 (zh) 图像降噪方法、装置、存储介质及电子设备
JP6903816B2 (ja) 画像処理方法および装置
CN108605087B (zh) 终端的拍照方法、拍照装置和终端
CN112805996B (zh) 一种用于生成慢动作视频片段的设备和方法
CN109922275B (zh) 曝光参数的自适应调整方法、装置及一种拍摄设备
WO2019221013A4 (en) Video stabilization method and apparatus and non-transitory computer-readable medium
CN106600548B (zh) 鱼眼摄像头图像处理方法和系统
CN107704798B (zh) 图像虚化方法、装置、计算机可读存储介质和计算机设备
CN110248101B (zh) 对焦方法和装置、电子设备、计算机可读存储介质
JP6914007B2 (ja) 情報処理装置および情報処理方法
WO2020063688A1 (zh) 视频场景变化的检测方法、装置及视频采集设备
CN110114801B (zh) 图像前景检测装置及方法、电子设备
CN113313626A (zh) 图像处理方法、装置、电子设备及存储介质
CN110365897B (zh) 图像修正方法和装置、电子设备、计算机可读存储介质
US10937124B2 (en) Information processing device, system, information processing method, and storage medium
US20200364832A1 (en) Photographing method and apparatus
CN106488128B (zh) 一种自动拍照的方法及装置
US20210289119A1 (en) Information processing apparatus, imaging apparatus, method, and storage medium
CN110536066B (zh) 一种全景相机拍摄方法、装置、电子设备及存储介质

Legal Events

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

Ref document number: 19864103

Country of ref document: EP

Kind code of ref document: A1

ENP Entry into the national phase

Ref document number: 2019864103

Country of ref document: EP

Effective date: 20210319

NENP Non-entry into the national phase

Ref country code: DE