I want to compare images to give a sort of score for similarity to a target image, as in the example below (scores just chosen to give an idea of the sort of similarity I'm after.) The scores represent a sort of edit distance.
All the images would be short words or sets of characters like this, and just black and white. The number of elements could vary- e.g. the bottom one has 9 elements but it could be different. The comparison needs to be pretty fast- fractions of a second, which I assume rules out an OCR-based approach.
Is there anything I could use in a library like AForge for something like this (template matching maybe...?) or is it a harder problem? I guess I could look at classifiers but I'd rather not go down that route just yet.