Metadata-Version: 2.0
Name: imagecrop
Version: 0.0.1
Summary: Use OpenCV to extract image crops using homography and feature matching
Home-page: UNKNOWN
Author: Stephan Hügel
Author-email: stephan.hugel.12@ucl.ac.uk
License: MIT License
Keywords: openCV,homography
Platform: UNKNOWN
Classifier: Programming Language :: Python
Classifier: Programming Language :: Python :: 2.7
Classifier: Programming Language :: Python :: 3.4
Classifier: Programming Language :: Python :: 3.5
Classifier: Programming Language :: Python :: 3.6
Classifier: Intended Audience :: Developers
Classifier: Intended Audience :: Education
Classifier: License :: OSI Approved :: MIT License
Classifier: Operating System :: OS Independent
Classifier: Topic :: Software Development :: Libraries :: Python Modules
Requires-Dist: sqlalchemy
Requires-Dist: pathlib2
Requires-Dist: opencv-contrib-python
Requires-Dist: requests
Requires-Dist: numpy

Image extraction using a template. Uses homography and feature matching,
and stores results in a SQLite database for faster reprocessing. Usage:

.. code-block:: python

    from image_extract.extract import Extracter
    ex = Extracter()
    ex.crop_images(image_directory, crop_template, file_extension)

Successful crops are extracted to a directory called ``successful_crops``,
directly underneath ``image_directory``. Each template used creates a subdirectory, named after its
MD5:

.. code-block:: plain

    image_directory
        - img1.jpg
        - …
        - imgn.jpg
        - successful_crops
            - 2a1bdab44c5e81af34f47f3395a3da7e
                - img1_cropped.jpg

Call ``ex.summary(path)`` to see information on extracted crops for a given directory.

Call ``ex.delete(path[, template_md5])`` to delete extracted crops for a given template.
If no template value is given, all extracted crops in that directory are removed.

For best results, the template image should be of the same (or similar) resolution
as the image from which the crop is to be extracted.


