VerSign: Easy Signature Verification in Python

Overview

VerSign: Easy Signature Verification in Python

versign is a small Python package which can be used to perform verification of offline signatures.

It assumes no prior knowledge of any machine learning tools or machine learning itself, and therefore can be used by ML experts and anyone else who wants to quickly integrate this functionality into their project.

Getting Started

Installation

This package requires python 3. Installation can be done with pip:

pip install versign

You might also need to manually install the following dependencies:

pip install git+git://github.com/luizgh/visdom_logger#egg=visdom_logger
pip install git+https://github.com/luizgh/sigver.git

Installation inside a virtual environment is recommended.

Download Trained Models

Before you can get started with, there is one more step you need to complete. versign comes with some pre-trained models which give it its magic.

Download the compressed models here, and extract them to models/ directory in your project root. Your project directory should look something like this:

_ $PROJECT_ROOT
 |__ models/
 |   |__ signet.pth
 |   |__ versign_segment.pkl
 |__ ...

Organise Your Dataset

This model treats signature verification as a single-class learning problem where only positive samples (i.e. genuine signatures) are available during training. This is because, in real-world situations where we want to enrol users into a signature verification system for verifying their signatures later, we don't have any forgeries available unless we specifically obtain them. Which is not practical. However, both genuine and forged signatures can be present during testing.

Write Your First Program with VerSign

import os
from versign import VerSign


# Load training data
train_data # folder containing training data (only genuine samples)
x_train = [os.path.join(train_data, f) for f in sorted(os.listdir(train_data))]

# Load test data and labels
test_data # folder containing test data
x_test = [os.path.join(test_data, f) for f in sorted(os.listdir(test_data))]

# Train a writer-dependent model from training data
v = VerSign('models/signet.pth', (150, 220))
v.fit(x_train)

# Predict labels of test data
y_pred = v.predict(x_test)

For a more complete example and additional features such as measuring test accuracy if groundtruth is known, see example.py.

You might also like...
Application for easy configuration of swap file and swappiness priority in slackware and others linux distributions.

Swap File Program created with the objective of assisting in the configuration of swap file in Distributions such as Slackware. Required packages: pyt

Regression Metrics Calculation Made easy

Regression Metrics Mean Absolute Error Mean Square Error Root Mean Square Error Root Mean Square Logarithmic Error Root Mean Square Logarithmic Error

✨ Voici un code en Python par moi, et en français qui permet d'exécuter du Javascript en Python.
✨ Voici un code en Python par moi, et en français qui permet d'exécuter du Javascript en Python.

JavaScript In Python ❗ Voici un code en Python par moi, et en français qui permet d'exécuter du Javascript en Python. 🔮 Une vidéo pour vous expliquer

Simple python module to get the information regarding battery in python.
Simple python module to get the information regarding battery in python.

Battery Stats A python3 module created for easily reading the current parameters of Battery in realtime. It reads battery stats from /sys/class/power_

ticktock is a minimalist library to view Python time performance of Python code.

ticktock is a minimalist library to view Python time performance of Python code.

Python @deprecat decorator to deprecate old python classes, functions or methods.

deprecat Decorator Python @deprecat decorator to deprecate old python classes, functions or methods. Installation pip install deprecat Usage To use th

A python package containing all the basic functions and classes for python. From simple addition to advanced file encryption.
A python package containing all the basic functions and classes for python. From simple addition to advanced file encryption.

A python package containing all the basic functions and classes for python. From simple addition to advanced file encryption.

Find dependent python scripts of a python script in a project directory.

Find dependent python scripts of a python script in a project directory.

A functional standard library for Python.

Toolz A set of utility functions for iterators, functions, and dictionaries. See the PyToolz documentation at https://toolz.readthedocs.io LICENSE New

Comments
  • Source Code of model files

    Source Code of model files

    Hi, this is an amazing project. Just wanna ask is it possible to get predictions in the range of 0 to 1 instead of a definite 0 or 1 or simply is it possible for me to get the source code of the model files

    Thank You

    opened by YScheung 1
  • how to get the dataset used in `example.py`

    how to get the dataset used in `example.py`

    Can i get the data set used in the example.py file please!!!!

    ../../authentica/sources/db/datasets/Signatures/CustomDataset/' this folder structure like any zip file or a drive link as in like models

    Amazing work bro !!

    opened by homimickey 1
  • Example of train and test data

    Example of train and test data

    Hi @saifkhichi96,

    Could you add a sample train and test dataset with the example.py for reference? The project looks interesting, would want to try it on my own dataset, but its a bit confusing as it doesn't mention the format in which the data is expected.

    Thanks, Monica

    opened by mon28 3
  • Scikit learn module SKlearn.Tree.Tree Deprecated, any workarounds?

    Scikit learn module SKlearn.Tree.Tree Deprecated, any workarounds?

    I have been trying to run the code with the latest scikit learn but to no avail as they have deprecated certain functions, could you help me get the code updated to work with current modules? (No module named Sklearn.tree.tree)

    opened by Aur0raN 1
Releases(v.0.0.2)
Owner
Muhammad Saif Ullah Khan
Mobile developer and ML engineer.
Muhammad Saif Ullah Khan
🌲 A simple BST (Binary Search Tree) generator written in python

Tree-Traversals (BST) 🌲 A simple BST (Binary Search Tree) generator written in python Installation Use the package manager pip to install BST. Usage

Jan Kupczyk 1 Dec 12, 2021
Quickly edit your slack posts.

Lightning Edit Quickly edit your Slack posts. Heavily inspired by @KhushrajRathod's LightningDelete. Usage: Note: Before anything, be sure to head ove

14 Nov 19, 2021
腾讯云轻量服务流量超出限制自动关机

LightHouse_Automatic_Shutdown 腾讯云轻量服务流量超出限制自动关机

132 Dec 14, 2022
Bounding Boxes Python Utils

Bounding Boxes Python Utils

Vadim 4 May 01, 2022
Dependency Injector is a dependency injection framework for Python.

What is Dependency Injector? Dependency Injector is a dependency injection framework for Python. It helps implementing the dependency injection princi

ETS Labs 2.6k Jan 04, 2023
This is Cool Utility tools that you can use in python.

This is Cool Utility tools that you can use in python. There are a few tools that you might find very useful, you can use this on pretty much any project and some utils might help you a lot and save

Senarc Studios 6 Apr 18, 2022
Dynamic key remapper for Wayland Window System, especially for Sway

wayremap Dynamic keyboard remapper for Wayland. It works on both X Window Manager and Wayland, but focused on Wayland as it intercepts evdev input and

Kay Gosho 50 Nov 29, 2022
ecowater-softner is a Python library for collecting information from Ecowater water softeners.

Ecowater Softner ecowater-softner is a Python library for collecting information from Ecowater water softeners. Installation Use the package manager p

6 Dec 08, 2022
Tools to connect to and interact with the Mila cluster

milatools The milatools package provides the mila command, which is meant to help with connecting to and interacting with the Mila cluster. Install Re

Mila 32 Dec 01, 2022
Link-tree - Script that iterate over the links found in each page

link-tree Script that iterate over the links found in each page, recursively fin

Rodrigo Stramantinoli 2 Jan 05, 2022
Various importers for cointracker

cointracker_importers Various importers for cointracker To convert nexo .csv format to cointracker .csv format: Download nexo csv file. run python Nex

Stefanos Anastasiou 9 Oct 24, 2022
A Python package implementing various colour checker detection algorithms and related utilities.

A Python package implementing various colour checker detection algorithms and related utilities.

colour-science 147 Dec 29, 2022
Enable ++x and --x expressions in Python

By default, Python supports neither pre-increments (like ++x) nor post-increments (like x++). However, the first ones are syntactically correct since Python parses them as two subsequent +x operation

Alexander Borzunov 85 Dec 29, 2022
Python based utilities for interacting with digital multimeters that are built on the FS9721-LP3 chipset.

Python based utilities for interacting with digital multimeters that are built on the FS9721-LP3 chipset.

Fergus 1 Feb 02, 2022
Export watched content from Tautulli to the Letterboxd CSV Import Format

Export watched content from Tautulli to the Letterboxd CSV Import Format

Evan J 5 Aug 31, 2022
Give you a better view of your Docker registry disk usage.

registry-du Give you a better view of your Docker registry disk usage. This small tool will analysis your Docker registry(vanilla or Harbor both work)

Nova Kwok 16 Jan 07, 2023
Factoral Methods using two different method

Factoral-Methods-using-two-different-method Here, I am finding the factorial of a number by using two different method. The first method is by using f

Sachin Vinayak Dabhade 4 Sep 24, 2021
NFT-Generator is the best way to generate thousands of NFTs quick and easily with Python.

NFT-Generator is the best way to generate thousands of NFTs quick and easily with Python. Just add your files, set your configuration and run the scri

78 Dec 27, 2022
Package that allows for validate and sanitize of string values.

py.validator A library of string validators and sanitizers Insipired by validator.js Strings only This library validates and sanitizes strings only. P

Sanel Hadzini 22 Nov 08, 2022
Retrying is an Apache 2.0 licensed general-purpose retrying library, written in Python, to simplify the task of adding retry behavior to just about anything.

Retrying Retrying is an Apache 2.0 licensed general-purpose retrying library, written in Python, to simplify the task of adding retry behavior to just

Ray Holder 1.9k Dec 29, 2022