Abstract:
The present invention discloses an apparatus for automatically detecting television advertisements comprising: a video frame buffer for storing a first group of video frames and a second group of video frames received by a television in which a scene change rate of the second group of video frames is substantially different from that of the first group of video frames; a video scene change detection and calculation unit for reading the first and second groups of video frames stored in the video frame buffer, determining the last frame immediately before the first group of video frames changes into the second group of video frames as a prompting frame, and calculating a correlation between a newly received video frame and the prompting frame; a prompting signal generation unit for generating a prompting signal when the correlation between the newly received video frame and the prompting frame, which is detected by the video scene change detection and calculation unit, is equal to or larger than a predetermined threshold; and a control unit for controlling the operation of the video scene change detection and calculation unit. The present invention also discloses a method for automatically detecting television advertisements.

Description:
BACKGROUND OF THE INVENTION  
       [0001]     1. Field of Invention  
         [0002]     The application relates to an apparatus for detecting advertisements received by a television receiver and method thereof, more particularly, to an apparatus for detecting advertisements played in a received television program and prompting the viewers that the advertisements are over when the advertisements is played out and to continually watching the television program, and method of the same.  
         [0003]     2. Description of Prior Art  
         [0004]     At present, there are a lot of commercial advertisements inserted in the broadcast television programs. These advertisements not only have redundant contents but also has a long playing period, which might cause the television viewers feel boring. Heretofore, many methods have already been suggested to avoid these commercial advertisements, for example, turning the sound of the played advertisements off, changing channels, or temporally leaving the television set away to deal with other things. However, since it is difficult to determine the played period of the advertisements, when the television viewers come back to continue watching the desired programs, the advertisements has still not finished, or the desired programs have been played for a moment, so that a part of program is missed.  
         [0005]     The most direct solution of avoiding advertisements is to hide some information in the television advertisement programs, for example, using digital watermark technique or flag information, or embedding the information into the program code stream by using a specific identifier when the program is digitally encoded. Thus, when the television reception party receives these programs, a certain program can be determined to be advertisements by detecting the specific digital watermark or identifier. However, this method not only increases the processing load of the television program transmission party, but also is not accepted by the advertisement producer. A system used to avoid the recording of advertisements while recording programs is disclosed in Chinese Patent Publication No. CN1118967A entitle “Broadcast recording system for recording broadcast contents without recording advertisement” published on Mar. 30, 1996. This publication discloses a method and an apparatus for removing advertisement contents from the recorded television broadcasts. The utilized technical solution consists in that a central station monitors the television broadcasts, and sends control and indicative broadcasts to a receiver located in the user&#39;s premises. The indicative broadcast includes a schedule table for the television programs and control data for the video recorder. A processor receiving broadcasts pauses and resumes the recording procedure of the recognized broadcasts according to this control broadcast. The user can phone the central station to request to program the user&#39;s video recorder so that the video recorder can record a certain broadcast program.  
         [0006]     The disclosed broadcast recording system avoids advertisements present in the recorded television program through a predetermined procedure based on the pre-scheduled television play timetable. However, this system has a complex structure, and needs communication with the central station so as to program the video recorder and thus has a troublesome procedure. In addition, this publication only avoids advertisement present in the recorded video programs, but does not solve the problem of avoiding advertisement while watching television. Furthermore, since the schedule of programs may be changed at any time, therefore the problem to avoid watching advertisements can not be completely solved only based on the time factors.  
         [0007]     An automatically activated advertisement information timer is disclosed in Chinese Patent ZL901000863 (Publication No. CN1022661C) granted to RCA Licensing S. A. on Nov. 3, 1996. The disclosed advertisement timer stores data about the previous tuned channel according to a channel changing instruction and repeats timing with a predetermined time limit. Each time the predetermined time limit is reached, the user will be noticed that the advertisements on the previous tuned channel might be over. The user can avoid the advertisements on the previous tuned channel by activating the time and searching for other channels. In the disclosed information timer, it is still time-relevant.  
         [0008]     All the apparatus and method to avoid watching advertisements mentioned in the above conventional techniques require the user to preset a time period without establishing direct connections with the advertisement picture played on the television. Therefore, there are still the problems of not avoiding or not completely avoiding the advertisements due to the inappropriate setting of the time period or the changes in the play time of the programs, or missing a part of the desired program due to not changing back to the channel after the advertisements are over. For this reason, the prior art has a disadvantage of unable to accurately determine when the advertisements are played out in order to notify the viewer to watch the desired program in time.  
         [0009]     The conventional methods and apparatuses do not fully consider the characteristics of the advertisements themselves and the continuity possibly owned by the programs. If an advertisement is inserted in the middle of a program, then the program will have a great continuity before and after the advertisement. And, an advertisement is apparently different from a common program. The length of one television advertisement is generally very shot such as several seconds to tens of seconds. In so short duration, in order to clearly and concisely express the characters of goods, it requires the number of the pictures as many as possible so as to fully deliver information. Thus, the scene change rate of the advertisement is fast, and the color contrast thereof is strong.  
         [0010]     In view of the above problems residing in the prior art, this application provides an apparatus and a method which is capable of detecting the played advertisement pictures and determining when the advertisement is finished so as to accurately notify the viewer that the advertisement has been played out.  
       SUMMARY OF THE INVENTION  
       [0011]     According to one aspect of the present invention, there is provided an apparatus for automatically detecting television advertisements comprising: a video frame buffer for storing a first group of video frames and a second group of video frames received by a television in which a scene change rate of the second group of video frames is substantially different from that of the first group of video frames; a video scene change detection and calculation unit for reading the first and second groups of video frames stored in the video frame buffer, determining the last frame immediately before the first group of video frames changes into the second group of video frames as a prompting frame, and calculating a correlation between a newly received video frame and the prompting frame; a prompting signal generation unit for generating a prompting signal when the correlation between the newly received video frame and the prompting frame, which is detected by the video scene change detection and calculation unit, is equal to or larger than a predetermined threshold; and a control unit for controlling the operations of the video scene change detection and calculation unit.  
         [0012]     According to another aspect of the present invention, there is provided an apparatus for automatically detecting television advertisements comprising: a video frame buffer for storing a first group of video frames and a second group of video frames received by a television in which a scene change rate of the second group of video frames is substantially different from that of the first group of video frames; a video scene change detection and calculation unit for reading the first and second groups of video frames stored in the video frame buffer, determining the last frame immediately before the first group of video frames changes into the second group of video frames as a prompting frame, and calculating a correlation between a newly received video frame and the prompting frame; a prompting signal generation unit for generating a prompting signal when the correlation between the newly received video frame and the prompting frame, which is detected by the video scene change detection and calculation unit, is equal to or larger than a predetermined threshold; and a control unit for controlling the prompting signal generation unit to generate the prompting signal in accordance with the changing from the second group of video frames to the first group of video frames detected by the video scene change detection and calculation unit.  
         [0013]     According to still another aspect of the present invention, there is provided a method for automatically detecting television advertisements comprising the steps of: storing a first group of video frames and a second group of video frames received by a television in which a scene change rate of the second group of video frames is substantially different from that of the first group of video frames; when an instruction to prompt an end of the advertisements is received, reading the stored first and second groups of video frames, and detecting when the second group of video frames is changed into a video frame associated with the first group of video frames; generating a prompting signal when the second group of video frames is changed into the first group of video frames.  
         [0014]     The apparatus and method for automatically detecting television advertisements according to the application can make the viewer not wait for the end of the television advertisements any more, and not worry about the missing of the previous watched program while doing other things or watching other channels. 
     
    
     BRIEF DESCRIPTION OF THE DRAWINGS  
       [0015]     The above and other objects, features and advantages of the present invention will be more apparent from the following detailed description about the non-limited embodiments of the application taken in conjunction with the accompanied drawings, in which:  
         [0016]      FIG. 1  is a block diagram showing a configuration of an apparatus for automatically detecting television advertisements according to an embodiment of the application;  
         [0017]      FIG. 2  is a flowchart showing operations for automatically detecting television advertisements according to the embodiment;  
         [0018]      FIG. 3  is a schematic diagram showing the video scene change characteristics of television advertisements and normal television programs; and  
         [0019]      FIG. 4  is a block diagram showing a configuration of an apparatus for automatically detecting television advertisements according to another embodiment of the application. 
     
    
     DETAILED DESCRIPTION OF PREFERRED EMBODIMENTS  
       [0020]     First of all, the principles of the apparatus and method for automatically detecting television advertisements according to the application will be briefly introduced. The application fully takes consideration about the apparent differences between the video images for advertisements and those for normal television programs, and uses the correlation between the video image frames to detect whether a television advertisement is finished.  
         [0021]     Generally, there is a strong correlation between the video image frames of a television program. If an advertisement is inserted into the television program being played, then the video image will be changed greatly. And when the television program is resumed to be played after the end of the advertisement, then the played video image frame of the television program will strongly correlate with the last frame or the several frame played immediately before the advertisement was played in continuity. Therefore, whether the advertisements are played out or not can be detected by comparing the correlation among the video images.  
         [0022]     The embodiments of the apparatus for automatically detecting television advertisements according to the application will be described in detail with reference to the drawings in the following.  
         [0023]      FIG. 1  shows the apparatus for automatically detecting television advertisements according to an embodiment of the application. As shown in  FIG. 1 , the apparatus for automatically detecting television advertisements according to the embodiment may include two portions, a television set and a remote controller. An advertisement finish prompting button for prompting that the advertisements are played out is newly added into the remote controller portion. It should note that the present invention is not limited thereto and may have only a television set. When the television begins to play advertisements, a viewer may send an instruction to prompt the end of the advertisements to the television set via a signal transmitter  9  by pressing the advertisement finish prompting button  10  provided on the remote controller.  
         [0024]     The television receiver portion comprises a program signal source  1 , a television program control unit  2 , a display unit  3 , a video frame buffer  4 , a controller  5 , a video scene change detection and calculation unit  6 , a prompting signal generation unit  7  and a receiver  8 .  
         [0025]     In the apparatus for automatically detecting television advertisements according to the embodiment, in addition to the existing units in the television set, the video frame buffer  4 , the controller  5 , the video scene change detection and calculation unit  6 , the prompting signal generation unit  7  and the receiver  8  are newly added. The receiver  8  can be omitted, and in this case, the controller  5  directly receives the instruction to prompt the end of the advertisements sent from the signal transmitter  9  of the remote controller.  
         [0026]     The television program control unit  2  receives video signals transmitted from the program signal source  1  via an antenna (not shown), and obtains video signals to be displayed after a tuner component therein (not shown) performs tuning and conversion. The television program control unit  2  inputs the processed video signals into the display unit  3  for displaying the program. The display unit  3  can be a display such as a cathode-ray tube, a liquid crystal display or a plasma display.  
         [0027]     Furthermore, as the apparatus for automatically detecting television advertisements according to the embodiment, the video frame buffer  4  receives the video signals to be displayed from the television program control unit  2 . The video frame buffer  4  stores the video signals which can be played for several seconds such as 5 to 10 seconds. Those video frame data input from the television program control unit  2  into the video frame buffer  4  can be sequentially stored in the video frame buffer  4  frame by frame. The video frame buffer  4  is connected to the video scene change detection and calculation unit  6 . The video scene change detection and calculation unit  6  reads the video frames stored in the video frame buffer  4 , and determines scene changes of the read video frames. When the last advertisement image is played out and changed into the television program played before the advertisement was played, a signal is output to the prompting signal generation unit  7 . As an example, the video frame buffer  4  is provided with a dedicated storage area for storing a previous frame before the video switching occurs. The video scene change detection and calculation unit  6  stores the previous frame before the determined video switching frame into the dedicated storage area within the video frame buffer  4 . For instance, the video frame buffer  4 , the controller  5  and the video scene change detection and calculation unit  6  can be implemented by a central processing unit (CPU). Further,  
         [0028]     The receiver  8  in the television set receives the instruction to prompt the end of the advertisements transmitted from the signal transmitter  9  of the remote controller. The receiver  8  is connected to the controller  5 , and after the instruction to prompt the end of the advertisements is received, the receiver  8  inputs an activating signal to the controller  5 . After the controller  5  receives the activating signal, it provides a control signal to the video scene change detection and calculation unit  6  so that the video scene change detection and calculation unit  6  is controlled to read the stored video frame from the video frame buffer  4  and to perform the calculation function for calculating the switching frame and detecting the newly received video frames associated with the switching frame. When the received video frame associated with the video frame stored in the dedicated storage area is detected, a control signal is output to the prompting signal generation unit  7  so that the prompting signal generation unit  7  generates a signal for prompting the end of the advertisements. The signal for prompting the end of the advertisements can be a caption displayed on the display  3  or in other forms of signals such as audible sound signals to prompt the viewers.  
         [0029]     Next, the operations of the apparatus for automatically detecting television advertisements according to the present invention will be described. The television program control unit  2  of the television set receives broadcast television programs. The output of the television program control unit  2  is connected to the video frame buffer  4  and the display  3 , and the played television program is displayed on the display  3 . In order to fulfill the needs for the following described process, the video frame buffer  4  records relevant information, for example, 5 to 10 seconds before current program. For a case of 25 frames per second, there are about 200 frames of the program contents to be stored. The actual storage capacity is related to the resolution standard of the television picture and predetermined time to be stored, and whether a certain image compress method is employed. For example, it maybe need a storage space of several millions of bytes. In order to reduce the storage capacity, a large compress ratio can be used for the video data. By way of an example, the method described below only uses information about two relevant frames, and thus in fact, only images of the adjacent two frames currently processed and the image frame maintained before the scene changes are necessarily stored. Therefore, the necessary storage capacity can be greatly reduced.  
         [0030]     The television program control unit  2  stores the previous video frame for 5 to 10 seconds, for example, before the currently received video contents into the video frame buffer  4 , in addition to inputting the video images into the display  3 . When advertisements are started in the progress of the viewer&#39;s watching the television programs, the viewer can press the advertisement finish prompting button  10  on the remote controller immediately, and the transmitter  9  in the remote controller sends the instruction to prompt the end of the advertisements to the receiver  8  included in the television set. After receiving the instruction transmitted by the transmitter  9 , the receiver  8  provides the activating signal to the controller  5 . Thereafter, the controller  5  controls the video scene change detection and calculation unit  6  to detect a switching video image when the advertisements start in accordance with a video image switching detection algorithm, and to select the previous frame of the switching image as a prompting frame stored in the buffer. It should note that a memory for storing the prompting frame may be provided separately from the video frame buffer. For example, the video image switching detection algorithm is performed based on the correlations among the continuous frames of the played images. Because there are great differences between the program images and the advertisement images and there are great correlations among the advertisement images, the video scene change detection and calculation unit  6 , after receiving the control signal from the controller  5 , calculates frame by frame, the correlation between a frame and its previous frame from the last stored frame of the video images. When it is determined that the correlation between one stored frame and its previous frame is smaller than a preset threshold, this previous frame of image is determined as the last frame before changing, i.e., the last frame of the television program before the advertisements stating. Hereafter, this frame will be referred as a prompting frame, and the last frame of the television program is stored in the dedicated storage area provided in the video frame buffer  4  to be used later. Alternatively, the prompting frame can be stored in a memory (not shown). For instance, the video image frames of the played television program can be referred as a first group of video frames, and the video image frames of the played advertisements can be referred as a second group of video frames.  
         [0031]     During the advertisements are being played, the video frame buffer  4  still stores image data which is currently played previous 5 to 10 seconds for example, and the video scene change detection and calculation unit  6  compares the latest received image frame with the stored prompting frame. Generally, there are great correlations between the images of the television before and after the advertisements. When the correlation obtained as a result of comparing the latest received image frame with the prompting frame is larger than a predetermined threshold, it is then considered that the advertisement images have already been changed into the program images. That is, the program is resumed. At this time, the video scene change detection and calculation unit  6  outputs the control signal to the prompting signal generation unit  7 . The prompting signal generation unit  7  generates the signal for prompting the end of the advertisement to display it on the display  3 , or generates sounds to prompt the viewers.  
         [0032]     In the image processing field, there are many methods for inter-frame correlation analysis, and the mostly used is template matching in which the grey values or color values for pixels at the same positions in two images are compared and the sum of the respective grey differences or color differences is calculated.  
         [0033]     For example, when an image has a size of X*Y, then the inter-frame difference is calculated according to the following equation (1).  
               d   ⁡     (       I   i     ,     I   j       )       =       ∑       x   =   0     ,     y   =   0           x   &lt;   X     ,     y   &lt;   Y         ⁢              I   i     ⁡     (     x   ,   y     )       -       I   j     ⁡     (     x   ,   y     )                        (   1   )             
 
 wherein I i  and I j  denote the two frames of images respectively, x and y denote horizontal and vertical coordinates of the image respectively, and I i (x, y) represents the grey values of the image at the point (x, y). 
 
         [0034]     Since the continuity of the program is mainly in the consistence of the scene, it can achieve a better effect preferably using the histogram matching in order to avoid influences from interferences and movements of objects etc.  
         [0035]     For grey (non-color) images, the inter-frame difference is calculated according to the following equation (2).  
               d   ⁡     (       I   i     ,     I   j       )       =       ∑     k   =   1     n     ⁢              H   i     ⁡     (   k   )       -       H   j     ⁡     (   k   )                        (   2   )             
 
 where H denotes a color histogram representation. 
 
         [0036]     H i  is the histogram of the image I i , where I i  is classified into n grey scales (n is a natural number), the sum of the number of pixels having the k th  grey scale is H i (k).  
         [0037]     For color images, histograms of difference color channels can be respectively calculated and finally the results are summed up. For example, for images represented by RGB, the histograms thereof can be obtained according to three channels R (red), G (green) and B (blue), and finally the results are summed up as shown by the Equation (3) as follow.  
               d   ⁡     (       I   i     ,     I   j       )       =         ∑     k   =   1     n     ⁢              H   i   R     ⁡     (   k   )       -       H   j   R     ⁡     (   k   )                +       ∑     k   =   1     n     ⁢              H   i   G     ⁢     (   k   )       -       H   j   G     ⁡     (   k   )                +       ∑     k   =   1     n     ⁢              H   i   B     ⁢           i     ⁢     (   k   )         -       H   j   B     ⁢     (   k   )                          (   3   )             
 
         [0038]     Taking account of the variety of the forms of the television programs, sometimes the program has little correlations, and thus the above method for calculating the correlations between images might fail. Alternatively, the following assistant method for detecting advertisement can be used. Specifically, the detection is performed by using the characteristics of the advertisement contents themselves. There are apparent differences between the advertisements and the normal programs. The length of one television advertisement is generally very shot, and in order to clearly and concisely express the characters of goods, it requires the number of the pictures as many as possible so as to fully deliver information. Thus, the scene change rate of the advertisement is fast, and the color contrast thereof is strong.  
         [0039]      FIG. 3   a  shows the change rate of the video images for advertisements, and  FIG. 3   b  shows the change rate of the video images for normal television programs. The position where a peak occurs in the drawings means that the image changes dramatically at this position. As shown in the drawings, for an advertisement with a length of about 8 seconds, more than 5 changing scenes can be detected, and the time lengths of the scenes are all not longer than 2 seconds. However, in a normal television program (as shown in  FIG. 3   b ), scenes lasting 5 seconds or more frequently occur. Therefore, the scene change rate of advertisements is generally faster than that of normal programs. In a preferred embodiment, the long time scene detection is employed, that is, if the time interval between two scene changes is not less than a certain threshold, it is then considered that the advertisements are already ended. For instance, the threshold can be set to about 5 seconds or can be adjusted if necessary.  
         [0040]     The primary principle of the scene change detection is to search for a good inter-frame difference comparison method to detect these peaks, in which where a difference goes beyond the set value is a scene change point. Similar to the inter-frame correlation analysis, the inter-frame difference analysis is performed preferably by using color histograms. The embodied calculation method is the same as above, and thus the detailed description will be omitted.  
         [0041]     The operation flow of the method for automatically detecting the television advertisements will be described with reference to  FIG. 2  as follows. As shown in  FIG. 2 , in step S 201 , the television set is powered on firstly, and video frames for about 5 to 10 seconds for example are stored in the buffer  4 . When the advertisements occur in a progress of watching the television programs, the viewer can press the advertisement finish prompting button  10  to transmit the instruction to prompt the end of the advertisements to the receiver  8  included in the television set. In step S 202 , the receiver  8  detects whether the instruction to prompt the end of the advertisements transmitted from the signal transmitter  9  on the remote controller side is received or not. If the judgment result of step S 202  is “No”, it is then continuously detected whether the instruction to prompt the end of the advertisements is received. If it is determined in step S 202  that the instruction to prompt the end of the advertisements is received, the activating signal is provided to the controller  5  in step S 203  to activate the controller  5 . The controller  5  controls the video scene change detection and calculation unit  6  to detect an abrupt change in the video image frames, and the previous frame immediately before the abrupt change occurs is stored as a prompting frame in the buffer  4 . In step S 204 , it is determined whether the latest received video frame stored in the buffer matches (correlates) with the prompting frame or not. If the latest received video frame matches (correlates) with the prompting frame, or the time interval between the scene changes is longer than the predetermined threshold, then the flow goes to step S 207  in which the prompting signal generation unit  7  is controlled to generate the signal for prompting the end of the advertisements. The viewer is notified that the playing of the advertisements is ended in an appropriate manner such as sounding or displaying the prompting captions if the playing of the advertisements is end. If it is determined in step S 204  that the latest received image does not match (correlate) with the stored prompting frame and the time interval between the scene changes is smaller than the predetermined threshold, the flow then goes to step S 205 . In step S 205 , it is determined that the playing of the advertisement is not ended and returns to step S 204  to continue the correlation detection until it is detected that the received image frame matches with or correlate with the stored prompting frame. The method for detecting the image matching or correlating, or the changing from the advertisement images into the television program images can be the algorithm described above with respect to the apparatus of the present invention, and thus will be omitted.  
         [0042]      FIG. 4  is a block diagram showing a configuration of an apparatus for automatically detecting television advertisements according to another embodiment of the present invention, in which the units which are used in the present embodiment are the same as those in the embodiment as shown in  FIG. 1  and are denoted with the same references as those in  FIG. 1 . The difference between the present embodiment and that as shown in  FIG. 1  is in that on the television set side, the receiver  8  is directly connected to the video scene change detection and calculation unit  6 , and activates the video scene change detection and calculation unit  6  to perform the image correlation detection when receiving the instruction to prompt the end of the advertisements. The controller  5  is connected between the video scene change detection and calculation unit  6  and the prompting signal generation unit  7 . When the video scene change detection and calculation unit  6  detects an image frame matching or correlating with the prompting frame, it provides the activating signal to the controller  5 , and the controller  5  controls the prompting signal generation unit  7  to generate the signal for prompting the end of the advertisements. In the present embodiment, the video scene change detection and calculation unit  6  detects the scene changes all the time no matter whether the prompting button transmits signals or not. Thus, only two frames of images adjacent to currently processed frame and the maintained image frame before the scene change are necessarily stored, such that the necessary storage capacity can be greatly reduced.  
         [0043]     Although the application is illustrated with reference to the certain embodiments thereof, it is for the purpose of description only. It should be understood that various changes and modifications to the application are possible without departing from the spirit or scope of the application.  
       INDUSTRIAL APPLICABILITY  
       [0044]     The apparatus and method for automatically detecting television advertisements according to the application are able to automatically detect the end of the advertisements such that the viewers need not wait for the replaying of the program in front of the television, and need not worry about the missing of the previous watched program while doing other things or watching other channels.