Skip to main content

Colorize and recolorize large images

Project description

ColorizeXL

Python implementation of the following paper by Anat Levin, Dani Lischinski, Yair Weiss, puublished in SIGGRAPH04.

We have adapted their technique to make it suitable for large images, by using overlapping patches with annotations.

Installation:

pip install colorizexl

Usage

Colorization of Black & White images

Previous to using the package, you have to setup the following:

  • original black & white image
  • annotation color image (please check details in the paper)

Recolorization of color images

Previous to using the package, you have to setup the following:

  • original color image
  • annotation image (please check details in the paper): white where the color stays the same, different colo where yo want to recolorize

Command line

Call the colorizexl.py from command line, to colorize or recolorize images.

python colorizexl.py --annotated=<path_to_annotated_image> --grayscale=<path_to_image_to_(re)colorize> --output=<path_to_(re)colorized_image> --recolorize=True/False

Python code

from colorizexl import ColorizeXL

colorizer = ColorizeXL(
        input_grayscale_name, input_annotation_name, recolorize=False
    )

output = colorizer.colorize(step_size=patch_size, overlap=overlap, n=neighbour)

Project details


Download files

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

Source Distribution

colorizexl-0.1.0.tar.gz (680.9 kB view details)

Uploaded Source

Built Distribution

colorizexl-0.1.0-py3-none-any.whl (679.8 kB view details)

Uploaded Python 3

File details

Details for the file colorizexl-0.1.0.tar.gz.

File metadata

  • Download URL: colorizexl-0.1.0.tar.gz
  • Upload date:
  • Size: 680.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/46.1.3 requests-toolbelt/0.9.1 tqdm/4.45.0 CPython/3.7.1

File hashes

Hashes for colorizexl-0.1.0.tar.gz
Algorithm Hash digest
SHA256 0cedbc25e14eba2d895a5ffa5235ecd19d083f9b1e1df7cb99cb3ba614b4a2db
MD5 6e3c3226d482854e558860ea500bb484
BLAKE2b-256 da61b273c272224a716028c5d1125009b527b4710e3f2724e1cdddf7a191179d

See more details on using hashes here.

File details

Details for the file colorizexl-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: colorizexl-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 679.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/46.1.3 requests-toolbelt/0.9.1 tqdm/4.45.0 CPython/3.7.1

File hashes

Hashes for colorizexl-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 5570a45f244491cfa1dcd17d011aee6deccfdf79a54232dce4fe28dccf5fb595
MD5 7b6ce6f4d0b48bbd6f662f8e25b70504
BLAKE2b-256 3cf6d98a39c1e718f0f9554870672ee197ac6dcb9642f36e1a28109987caaf1d

See more details on using hashes here.

Supported by

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