Disclosed are a method and apparatus for inspection by pattern comparison
enabling cell-cell comparison by software processing even when the array pitch
R of the cells is not a whole multiple of the pixel pitch P, wherein provision
is made of an imaging device for capturing an image of patterns having a plurality
of basic patterns repeating at a predetermined pitch and generating pixel data,
a memory for storing the image data, and an image processor unit for successively
comparing corresponding pixel data of the basic patterns based on the pixel data,
the image processor unit setting a first whole number by which the length of the
predetermined pitch multiplied by the first whole number becomes a whole multiple
of the pixel pitch when the predetermined pitch is expressed by a resolution of
at least a predetermined resolution pitch smaller than the pixel pitch and successively
comparing the corresponding pixel data of basic patterns said first whole number
of pattern away.