19

My users draw their signature in my application using touch events and I convert it to a bitmap. I want to extract unique specifications of each signature and compare it by its specifications stored in main server.

How can I do that?

What is the main and enterprise algorithm for extracting unique features of a signature?

Thanks in advance,

vpiTriumph
  • 3,116
  • 2
  • 27
  • 39
Bob
  • 22,810
  • 38
  • 143
  • 225
  • This is way too broad for a Stack Overflow post, but you should look into siamese neural networks, triplet loss, contrastive loss, or metric learning more generally. – Nicolas Gervais Jan 14 '22 at 18:45

5 Answers5

21

I'm not a computer vision expert, but as a grad student that's dabbled, it sounds like feature exaction is what you're looking for. The first thing that comes to mind is SIFT (Scale-Invariant Feature Transform). This algorithm would allow you to compare stored features of an original signature to copies and identify a match with a high level of accuracy, even in the cases that the sample is scaled or rotated.

With a simple Google search you can find a number of scholarly papers, for example this one or this one that are specifically related to using the algorithm for signatures/biometrics.

There is a discussion of using OpenCV with SIFT in this Stack Overflow Article.

If there are better vision algorithms that I'm unaware of that are particularly well suited to this problem I encourage the community to chime in.

Community
  • 1
  • 1
vpiTriumph
  • 3,116
  • 2
  • 27
  • 39
  • 2
    I did a bit more research on the topic tonight out of my own curiosity. There is shockingly little material on 'signature recognition', but if you broaden your search to handwriting forensics you find some commercial solutions such as this [Cedar Fox](http://www.cedartech.com/products_cedarfox.html#image_proc) and [Neuro Script](http://www.neuroscript.net/forensics.php). Both have free demos that you can probably use to get a sense of their process. I'm still a bit shocked nothing open source exists that does this out of the box... – vpiTriumph Apr 27 '12 at 05:23
  • 1
    If you are going to consider SIFT, you should also consider SURF and ORB. Similar algorithms, also implemented in opencv, but that run faster. – Rui Marques Jun 10 '12 at 15:50
3

Try looking at this resource which uses a neural network to do handwriting recognition. Try looking at this resource too which shows you how to recognize hand written digits. Both projects have full source code.

Icemanind
  • 47,519
  • 50
  • 171
  • 296
1

There is a similar question asked: Bitmap (of a signature) comparison in c#

I have also found one article in channel9 http://channel9.msdn.com/coding4fun/blog/Contour-Analysis-for-Image-Recognition-in-C

It requires a complex logic to be created, there are various products available for signature verification and recognition, I have found following code written in vb 6.0 which might be of some help: http://www.planet-source-code.com/vb/scripts/ShowCode.asp?txtCodeId=38215&lngWId=1

In nutshell it requires lots of efforts, so you can ask client if by specifying some unique code or question the requirement "matching of signature" can be fulfilled.

Community
  • 1
  • 1
mannu2050
  • 403
  • 3
  • 11
0

In UNI couple years back I did handwriting recognition system. From experience which i gained during working on that project i will tel you, do not convert signature to image, but collect set of points where pen was touching screen and order them by timestamp. Dealing with that will be much easier than dealing with signature as image.

If anyone will follow your footsteps, I recommend read something about Online/Offline handwriting recognition

user902383
  • 8,420
  • 8
  • 43
  • 63
0

Well you can transform the image in a bytes array, send that to your server and do whatever you want.

Next I will place some tips and tricks with decode and encode methods you can use

There is a question here Decode byte array to bitmap that has been compressed in Java about how to decode bytes array

And to create the bytes array from your bitmap using this tips: http://www.anddev.org/advanced-tutorials-f21/how-to-convert-bitmap-to-byte-array-in-android-t12985.html

Hope this helps, Arkde

Community
  • 1
  • 1
Aurelian Cotuna
  • 3,076
  • 3
  • 29
  • 49
  • I want to store those specifications in my database for working offline. So converting image to byte array is not my solution and storing a big image in database is not good solution for a pocket pc device. I have to do my operations on my device. – Bob Jan 18 '12 at 09:41
  • well storing images in database may not be a good solution. Try keeping it on /sdcard and it's path on database might be. Also you can store locally parts of image, as bytes array, and compare it with another bytes array from image you compare. – Aurelian Cotuna Jan 18 '12 at 10:42
  • signature detection is something like fingerprint detection. it is not pixel to pixel comparison. – Bob Jan 18 '12 at 11:02