TIC: Text-Guided Image Colorization

Subhankar Ghosh, Prasun Roy, Saumik Bhattacharya, Umapada Pal, Michael BlumensteinarXiv 2022 · DOI

TL;DR

This paper introduces a novel approach to image colorization by incorporating textual descriptions of image content as an auxiliary condition. By feeding both the grayscale image and its corresponding text description into a GAN-based network, the authors achieve more realistic and visually appealing colorized images compared to existing methods that rely solely on the grayscale input.

What Problem Does This Paper Address?

Image colorization, the task of adding color to grayscale images, is notoriously ill-posed. This means a single grayscale image can correspond to many different plausible color images, making it difficult for automatic systems to produce consistently accurate and aesthetically pleasing results. Existing deep learning-based colorization methods often struggle with this ambiguity, leading to unrealistic or dull colorizations because they lack sufficient contextual information. The paper aims to bridge this gap by leveraging textual descriptions to guide the colorization process, providing explicit color cues for objects within the image.

Methods

The core of the proposed method is a Generative Adversarial Network (GAN) architecture that takes two inputs: the grayscale image (converted to the 'L' channel of the CIE LAB color space) and an encoded textual description of the image content.

  • Generator: The generator network has two pathways: one for processing the image information and another for processing the text information. These pathways merge, and the text encoding is fused with image features at a late stage using an element-wise dot product. This fused representation is then fed through a series of Residual in Residual Dense Blocks (RRDBs) for feature extraction and refinement, followed by an expanding pathway to predict the 'A' and 'B' channels of the LAB color space. The final color image is reconstructed by combining the predicted 'AB' channels with the original 'L' channel.
  • Discriminator: A PatchGAN discriminator is employed to assess the local quality of the generated colorized images. It distinguishes between real and fake image patches, encouraging the generator to produce realistic textures and details. The discriminator is trained on stacks of the grayscale 'L' channel and either the ground truth 'AB' channels (real) or the generated 'AB' channels (fake).
  • Loss Functions: The training involves a combination of adversarial loss (for the GAN framework), L1 loss to ensure fidelity of low-frequency information, and perceptual loss using a pre-trained VGG19 network to improve visual quality.

Datasets

The authors evaluated their framework on three publicly available datasets:

  • Caltech-UCSD Birds 200 (CUB-200-2011): Contains bird images with detailed color information.
  • MS COCO Stuff: A subset of the MS COCO dataset that includes text descriptions for images. The authors specifically extracted color-related sentences from these descriptions.
  • Natural Color Dataset (NCD): A dataset of fruit images. For training, the class label of each fruit was converted to a single representative color.

Key Insights and Ideas

  • Textual Conditioning is Powerful: The most significant insight is that providing explicit textual descriptions of image content dramatically improves colorization fidelity. This goes beyond simply learning color distributions from pixels and allows for more targeted and accurate color assignment.
  • Text Guides Color Gamut Prediction: The textual descriptions act as an "auxiliary condition," helping the network predict the correct color gamut for objects, leading to more perceptually appealing results.
  • Recolorization Capability: The framework can be used for recolorization by simply providing a different textual description than the one corresponding to the ground truth image, demonstrating its flexibility.
  • Foreground vs. Background: The current approach primarily focuses on textual descriptions of foreground objects, which can lead to less fidelity in background colors. This highlights a potential area for improvement.

Key Results

  • Qualitative Improvement: The proposed method consistently produces more realistic and colorful images compared to state-of-the-art (SOTA) algorithms, as evidenced by visual comparisons. SOTA methods are noted to produce less colorful and sometimes inaccurate colors.
  • Quantitative Improvement: The model outperforms SOTA algorithms in quantitative metrics such as SSIM, PSNR, and LPIPS (both VGG and SqueezeNet versions). For instance, the proposed method achieved an SSIM of 0.917 and a PSNR of 23.27, surpassing other methods.
  • Validation of Textual Importance: Experiments showed that removing textual conditioning significantly degraded the colorization quality, underscoring the importance of the proposed text-guided approach.

Limitations and Future Work

  • Foreground Object Focus: The current method's reliance on foreground object descriptions leads to less accurate background colors. The authors suggest that incorporating background color descriptions would be a valuable future direction.
  • Less Colorful Backgrounds: In some cases, the method produces less colorful backgrounds, which can be a consequence of the foreground-centric textual descriptions.
  • Exhaustive Textual Descriptions: The paper notes the necessity of more exhaustive textual descriptions for better overall colorization, especially for backgrounds.
  • Future Work: The authors implicitly suggest exploring more comprehensive textual descriptions and potentially incorporating scene-level context for improved background colorization.

Summary updated

BibTeX
@misc{ghosh2022tic,
  author = {Subhankar Ghosh and Prasun Roy and Saumik Bhattacharya and Umapada Pal and Michael Blumenstein},
  title = {{TIC: Text-Guided Image Colorization}},
  year = {2022},
  eprint = {2208.02843},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2208.02843},
}
Figure