Skip to main content

Docoskin

"Onion-skin" visual differences between a reference document image and a scanned copy.

Given an image of a reference document, docoskin will attempt to find key points of the document in a scanned copy, align the two, auto-correct the image contrasts and display a combined image, featuring sections in red which were "removed from" the reference document and sections in green which were added to the document.

The intended use for this is comparing a signed, returned scan of a contract with the original version as provided to the signer to check for unagreed amendments.

Implemented as a python library with a command-line interface. Significantly more power and flexibility is achievable through accessing the python components.

Depends on opencv and six (and, on python2.7, the futures backport).

opencv is always going to be a slightly painful dependency from a python point of view because a) it's a native library and b) it doesn't really play by python packaging rules supplying an egg. I advocate use of Nix to solve both these problems and provide a default.nix so that nix users can simply perform a

$ nix-shell .

in the source directory for a development-ready shell (somthing like a non-python-specific virtualenv).

Those wishing to attempt using the pypi opencv-python package can try installing the package with the 'extra' pypi_opencv, which hypothetically should download & install opencv from pypi

$ pip install -e .[pypi_opencv]

but the author has never had any luck with that and has unfavourable opinions of pip in general, not to mention the concept of downloading & installing binaries from pypi.

Preliminary license is GPLv3.

Tests

The test suite makes use of images which are kept in a git submodule due to their size. Performing a

$ git submodule init
$ git submodule update

should fetch the required data. If this data is not present, the tests will quietly skip tests requiring images (which is most of them, though).

Metadata

Release files for docoskin 0.1.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for docoskin 0.1.0
File Size Uploaded
docoskin-0.1.0.tar.gz 11.6 kB Details

Release files / docoskin-0.1.0.tar.gz

Download URL docoskin-0.1.0.tar.gz
Size 11.6 kB
Tags Source
SHA-256 checksum
How to use checksums
f4707307bc303e1cc7ed9a52d2099cebf84d3f8cbe0f42265f730baff50c80e1
BLAKE2b-256 checksum
How to use checksums
044ea6d570193cd4ae87fcc1a5f0cce65b923094ce217752895b9cfae1ee5595
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/1.15.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.32.2 CPython/3.7.5

Release history Release notifications | RSS feed

This release

0.1.0 This release

1 release file

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page