mananchawla2005 / signaturematchingCL

An implementation of Siamese Network using pytorch for signature matching and forgery

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Signature Matching using Contrastive Learning

Model

This repository explores the task of signature analysis and matching using the power of contrastive learning and Siamese networks. It helps to provide a robust solution for comparing and matching handwriting samples.

  • Siamese Network:
    image

  • Contrastive Loss: In the below image, Dw represents the euclidian distance between two pairs of images. Y is an indicator function which is 1 for positive pairs and 0 for dissimilar pairs. For the positive part, we just calculate the euclidian distance whereas for the negative part, there is a slight change. As it is being calculate for negative pairs, there comes a minus sign in front of it and we use a small number m to set the threshold value. The loss function in all is given below: image

Results:

faafcfc5-4877-40ce-8591-923238b2e8dd def2f0a0-2e99-42a3-b93e-00e65430768a

About

An implementation of Siamese Network using pytorch for signature matching and forgery

License:Apache License 2.0


Languages

Language:Jupyter Notebook 100.0%