We develop a fully automatic image colorization system. Our approach leverages recent advances in deep networks, exploiting both low-level and semantic representations during colorization. As many scene elements naturally appear according to multimodal color distributions, we train our model to predict per-pixel color histograms. This intermediate output can be used to automatically generate a color image, or further manipulated prior to image formation; our experiments consider both scenarios. On both fully and partially automatic colorization tasks, our system significantly outperforms all existing methods.
You can install the colorizer via pip (make sure you have Caffe with Python bindings installed):
pip install autocolorize
This will install the command autocolorize:
autocolorize grayscale.jpg -o colorized.jpg
There is a start-up cost to loading in the model, so to colorize a batch, use:
autocolorize *.jpg -o output
The colorized images will be saved to the output directory.
Automatic colorization has gained a lot of interest recently. In particular, Zhang et al. and Iizuka & Simo-Serra et al. who concurrently developed a colorization system.