Introduction
Colorization is a fundamentally ill-posed problem. For any given grayscale image, there is no single "correct" colorization; a shirt might be blue or red, and a building could be brick-red or grey. Traditional deep learning approaches often treat this as a regression task using standard $L_2$ loss. However, this typically leads to "regression to the mean," resulting in desaturated, grayish, or blurry outputs as the model attempts to minimize average error across all possible colors.
Alternative methods that attempt to sample colors pixel-by-pixel often suffer from "speckle noise"—spatially inconsistent colors where neighboring pixels lack coordination. The challenge lies in generating colorizations that are both diverse and spatially coherent.
The Proposed Framework
To address these challenges, this paper introduces a novel framework that decouples color representation from color prediction. The architecture consists of two main components: a Variational Autoencoder (VAE) and a Mixture Density Network (MDN).
1. Learning a Latent Color Space (VAE)
The first step involves training a VAE to learn a low-dimensional embedding ($z$) of color fields ($C$). This latent space is designed to capture the "long-scale spatial co-ordination" of colors, ensuring that generated colorizations are spatially coherent rather than noisy. To ensure high-quality and vibrant outputs, the authors introduce three specialized loss terms:
- Specificity ($L_{mah}$): Utilizes Mahalanobis distance based on PCA to ensure the model captures the directions of maximum variance in color fields, preventing "washed out" results.
- Colorfulness ($L_{hist}$): Re-weights the loss to favor rarer, more vibrant colors over common grayish tones.
- Gradient ($L_{grad}$): Matches the spatial gradients of the predicted color field to the ground truth to maintain sharpness.
2. Conditional Modeling (MDN)
Once the latent space is established, a Mixture Density Network (MDN) is trained to predict the distribution of these latent variables ($z$) given a grayscale image ($G$). By modeling the output as a mixture of Gaussians, the MDN can represent multiple distinct "modes" of colorization (e.g., one mode for a blue car, another for a red car), effectively avoiding the "mode collapse" common in standard Conditional VAEs or GANs.
During testing, multiple $z$ values are sampled from the MDN and passed through the VAE decoder to produce a variety of realistic, diverse colorizations.
Experimental Results
The model was evaluated on three datasets: LFW (faces), LSUN-Church (complex textures), and ImageNet-Val (diverse categories).
Qualitatively, the proposed method produces colorizations that are significantly more diverse and lack the "speckle" artifacts found in pixel-wise sampling methods. Quantitatively, the authors employed "Error-of-best" (Eob) and "Variance" (Var) as metrics. The method consistently achieved higher variance (indicating greater diversity) while maintaining low error rates compared to baselines like CVAE and cGAN. Ablation studies further confirmed that the combination of the three custom loss terms was essential for producing the most plausible and vivid results.
Conclusion
By combining a latent color representation with a mixture density model, this framework successfully generates diverse and spatially coherent colorizations. While the model excels at global coordination, future work aims to improve the encoding of fine-grained spatial details. This "latent space + MDN" paradigm holds promise for other ambiguous computer vision tasks, such as motion-field generation or future frame synthesis.
Summary updated