×

Passive and interactive real-time image recognition software method

  • US 20070292033A1
  • Filed: 06/19/2006
  • Published: 12/20/2007
  • Est. Priority Date: 06/19/2006
  • Status: Abandoned Application
First Claim
Patent Images

1. Whereas, the passive real-time image recognition method is described as follows:

  • Step 1;

    Capture an image projected by an image projection apparatus to image areas as reference images (5×

    5 grey-level value) by using a video camera;

    Step 2;

    Continuously capture real-time images (5×

    5 grey-level value) projected by an image projection apparatus to image areas by using a video camera, and check if any foreign object touches the reactive area.The difference value between the reference image from step 1 and the real-time image from step 2 can be denoted as follows (1);


    DIFF(x,y)=|REF(x,y)−

    NEW(x,y)| 



    (1)Step 3;

    Difference of the grey-level value of real-time image in step 2 and the grey-level value of reference image in step 1 to have the grey-level distribution of remaining images, which means foreign objects exist.Step 4;

    The image which is subject to differencing through step 3 usually has noises, which can be present as in formula (2) BIN

    ( x , y )
    = { 255 DIFF

    ( x , y )


    T *
    0 DIFF

    ( x , y )
    <

    T *
    ( 2 )
    The binarization method eliminates the noises;

    in which, T* represents a threshold, in 8 bit grey-scale image and the threshold ranges from 0 to 255. The optimal threshold can be decided by a statistical method. The optimal threshold is on the wave trough of the grey-level value;

    when T* is decided, the image can be segmented into two sections. The requirement for the optimal threshold T* is when the sum of variances in C1 and the variances in C2 has the minimum value. It is assumed that the size of the image is N=5×

    5, and the grey-level value number of 8 bit grey-level image is I=256. Then the probability of grey-level value is I can be denoted as;

    P

    ( i )
    = n i N
    ( 3 )
    Wherein ni indicates the appearance number of grey-level value I, and the range of I is 0≦

    i≦

    I−

    1. According to the probability principle, the following can be obtained;



    i = 0 I - 1


    P

    ( i )
    = 1
    ( 4 )
    Suppose the ratio of the pixel number in C1 is;

    W 1 = Pr

    ( C 1 )
    =

    i = 0 T *


    P

    ( i )
    ( 5 )
    While the ratio of the pixel number in C2 is;

    W 2 = Pr

    ( C 2 )
    =

    i = T * + 1 I - 1


    P

    ( i )
    ( 6 )
    Here W1+W2=1 can be satisfied. The expect value of C1 can be calculated as;

    U 1 =

    i = 0 T *


    P

    ( i )
    W 1
    ×

    i
    ( 7 )
    The expect value of C2 is;

    U 2 =

    i = T * + 1 I - 1


    P

    ( i )
    W 2
    ×

    i
    ( 8 )
    The variance of C1 and C2 can be obtained by using the formula (7) and (8). σ

    1 2
    =

    i = 0 T *


    ( i - U 1 ) 2

    P

    ( i )
    W 1
    ( 9 )
    σ

    2 2
    =

    i = T * + 1 I - 1


    ( i - U 2 ) 2

    P

    ( i )
    W 2
    ( 10 )
    The sum of variance in C1 and C2 are;


    σ

    w2=W1σ

    12+W2σ

    22



    (11) Substitute the value 0-255 for formula (11). When the formula (11) has the minimum value, then the optimal threshold T* can be obtained. Step 5;

    Although the residual noises have been removed through binarization in step 4, however, the moving object becomes dilapidated. This can be removed by using four connected masks and the inflation and erosion algorithm. The inflation algorithm is described as follows;

    when Mb(i,j)=255, set the mask of the 4-neighbor points as
    Mb(i,j−

    1)=Mb(i,j+1)=Mb(i−

    1,i)=Mb(i+1,j)=255  



    (12) The erosion algorithm is described as follows;

    when Mb(i,j)=0, set the mask of the 4 neighbor points as
    Mb(i,j−

    1)=Mb(i,j+1)=Mb(i−

    1,j)=Mb(i+1,j)=0  



    (13) Convoluting the above-mentioned mask and binarized image can eliminate the dilapidation. Step 6;

    Next, the lateral mask can be used to obtain the contours of the moving object. Where, the Sobel (the image contour operation mask) is used to obtain the object contours. Convolute the Sobel (the image contour operation mask) mask and the real-time image, which can be denoted by formula (14) and (15);


    Gx(x,y)=(NEW(x−

    1,y+1)+2×

    NEW(x,y+1)+NEW(x+1,y+1))−

    (NEW(x−

    1,y−

    1)+2×

    NEW(x,y−

    1)+NEW(x+1,y−

    1))  



    (14)
    Gy(i,j)=(NEW(x+1,y−

    1)+2×

    NEW(x+1,y)+NEW(x+1,y+1))−

    (NEW(x−

    1,y−

    1)+2×

    NEW(x−

    1,y)+NEW(x−

    1,y+1)) The rim of the acquired image can be obtained by using formula (16).
    G(x,y)=√

    {square root over (Gx(x,y)2+Gy(x,y)2)}{square root over (Gx(x,y)2+Gy(x,y)2)} 



    (16) Then the above rim image is binarized. E

    ( x , y )
    = { 255 G

    ( x , y )


    T e *
    0 G

    ( x , y )
    <

    T e *
    ( 17 )
    Wherein Te* represents the optimal threshold, the optimal threshold can be obtained using the prior method;

    then, after mixing the binarization contour pattern of the real-time image and the differentiated binary image BIN(x,y), the periphery contour of the moving object can be obtained. Step 7;

    Check if the contour point coordinates of the moving object is touched by the reactive area and run the corresponding movement. Step 8;

    Repeat all the steps above;

View all claims
  • 0 Assignments
Timeline View
Assignment View
    ×
    ×