Patent ID: 8019157

Claim:
A method of vehicle segmentation and counting for night video frames, comprising: generating a background frame according to the video frames; converting the video frames from RGB data to HSI data; converting the background frame from RGB data to HSI data; inputting the HSI data of the video frames and the HSI data of the background frame to a Gaussian filter so as to generate Gaussian data of the video frames and Gaussian data of the background frame; updating the Gaussian data of the background frame; determining changed regions and unchanged region of the video frames to generate a frame difference mask and a background subtraction mask according to the Gaussian data of the video frames and the Gaussian data of the background frame; detecting an object region of the video frames to generate a static region mask and a moving region mask according to the frame difference mask and the background subtraction mask; combining the static region mask and the moving region mask to generate an initial object mask; detecting characteristic information of the moving object to calculate the amount of the moving objects; excluding an interference region of the moving object and compensating the object region of the video frames to generate a final object mask; and obtaining the moving object from the video frames according to the final object mask.