3
$\begingroup$

I'm a student I'm completely new to this technology maybe my approach could be completely wrong, I want to create an algorithm that compares the similarity between two binarized images.

I'll explain: I have 2 pictures as input. The RGB colors of these images can only be 0 or 255

(R = G = B = 255) or (R = G = B = 0). I take these two letters as an example.

1. symbol1 2. symbol2

I thought so: the 255 value is the background of the image which is white. The 0 value is the shape (letter) formed in the image. So I thought of creating a matrix with 0 and 1 values where value 0 represents the background and value 1 represents the shape.

So now i would like to create an algorithm that understands the shape created in the two matrices and that returns a similarity percentage.

Update: I'm creating this app that tries to recognize the font of a text in a image (https://github.com/Sirvasile/Typefont), I want to create this algorithm to improve the comparison between the input letters and the alphabet of my fonts in the database.

$\endgroup$
  • 1
    $\begingroup$ I think you need to define what you mean by shape. One could compute the hamming distance between the images and get an answer but I don't think that is what you want. Try looking up convolutional NNs and MNIST. It should help. $\endgroup$ – Jaden Travnik Apr 30 '17 at 21:40
1
$\begingroup$

I think you look for the meaning of the image (pic of 'a' = a) rather than the regular image similarity. For example, you would like the two images of the 'a' you posted to be classified to the same label instead of, for example, to be classified as similar to an 'o' image which would give a smaller Hamming distance or mean square error.
So as @Jaden Travnik suggested, MNIST digits classification is a good start. It classifies handwritten digits and has human-level solutions implemented by any existing CNN framework. (TensorFlow, Caffe, Theano, to name a few).

|improve this answer|||||
$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.