主权项 |
1. A focusing device comprising:
a processor; and a memory device operatively coupled to the processor, the memory device storing instructions that cause the processor, in cooperation with the memory device, to: (a) generate a first image associated with a sample and a second image associated with the sample; (b) determine disparities between: (i) the second image associated with the sample; and (ii) a third image associated with the sample; and (c) for a lens, determine a focusing position based on the determined disparities, wherein the lens:
(i) has a first depth of field which corresponds to a maximum depth of field, wherein a first value corresponds to the first depth of field; and(ii) is set at a second depth of field, wherein a second value corresponds to the second depth of field, wherein the instructions, when executed by the processor, cause the processor to:
(i) determine a third value which corresponds to a difference between a first value of disparity and a second value of disparity; and(ii) in response to the third value being: (A) smaller than the first value; and (B) larger than the second value, set the lens at a third depth of field, the third depth of field being larger than the second depth of field, and wherein the instructions, when executed by the processor, cause the processor to, in response to the third value being larger than a predetermined threshold, for the lens, divide an imaging area into a plurality of layers, the number of layers being based on the first depth of field of the lens. |