Skip to main content

Python package to compare images with metrics

Project description

Image Comparator (imco)

Compare image similarity with metrics printed automatically below every image. See example image below.

comparison_image

Installation

pip install imco

To get the latest version, install:

pip install git+https://github.com/pettod/imco.git@main

Usage

Import following function:

from imco import compareImages

Here is a sample code to use the comparison function:

import cv2

# Paths to images
image_paths = [
    "path/to/image_1.png",
    "path/to/image_2.png",
    "path/to/image_3.png",
]

# Read images
images = [cv2.imread(image_path) for image_path in image_paths]

# Define image names
names = ["Input", "Prediction 1", "Ground Truth"]

# Create comparison image
comparison_image = compareImages(images, names, True, 256, (10, 30))
cv2.imwrite("comparison_image.png", comparison_image)

License

License

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

imco-0.1.4-py2.py3-none-any.whl (7.9 kB view details)

Uploaded Python 2Python 3

File details

Details for the file imco-0.1.4-py2.py3-none-any.whl.

File metadata

  • Download URL: imco-0.1.4-py2.py3-none-any.whl
  • Upload date:
  • Size: 7.9 kB
  • Tags: Python 2, Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.7.11

File hashes

Hashes for imco-0.1.4-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 4685e4dc94185bb943813d04b0d3917dffd41e5a2f9947ed7fb9fdccaa11dbc8
MD5 4e8e32f3819b41dda0dc8b0f91849d95
BLAKE2b-256 1cfa3791253e182fe72fca58924f09159a1498f627a2dc653ddd2e76b7c26bb6

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page