1. A method for preventing a collision between a motor vehicle and a pedestrian using a camera and a processor mountable in a motor vehicle, wherein the processor is operably connectible to the camera and the processor is configured to capture a plurality of image frames from the camera of the environment of the motor vehicle in the field of view of the camera, the method comprising: detecting an image patch in at least one of the image frames, wherein the image patch includes a candidate image of a pedestrian in the field of view of the camera; validating detection of the candidate image by analyzing optical flow between the image frames of the image patch; and providing a collision warning or a collision prevention control signal, when the analyzed optical flow is consistent with an upright pedestrian.