1. A method for determining focus of an imaging system, the method comprising the steps of: a) acquiring a gray scale image of a test target; b) binarizing the acquired gray scale image; c) analyzing the binarized acquired image; d) adjusting focus of acquisition optics of the imaging system; e) repeating steps a) through d) until a substantially maximum number of line pairs of a plurality of groups of line pairs of the test target is obtained, wherein each group from the plurality of groups of line pairs has a predetermined spatial frequency; whereby focus of the imaging system is determined.