Introduction
Image-to-image (I2I) translation involves mapping an image from a source domain (e.g., sketches) to a target domain (e.g., photographs). While Generative Adversarial Networks (GANs) like Pix2Pix have long been the standard, they often suffer from training instability and mode collapse. Recent advances in diffusion models offer a stable alternative, yet most conditional variants rely on text prompts, which lack the precision required for high-fidelity structural preservation. This paper proposes a novel framework that replaces the traditional U-Net backbone with a Diffusion Transformer (DiT) and utilizes CLIP-based image conditioning to achieve superior stylistic and structural accuracy.
Methodology
The proposed Image-Conditioned DiT architecture departs from convolutional norms by operating in a compressed latent space via a pre-trained Variational Autoencoder (VAE).
Key technical components include:
- Transformer Backbone: By treating image latents as sequences of patches, the model leverages self-attention to capture global dependencies more effectively than local convolutions.
- CLIP-Based Conditioning: The model is conditioned on image embeddings from a pre-trained CLIP (ViT-L/14) encoder. These embeddings are integrated into DiT blocks through cross-attention and Adaptive Layer Normalization (AdaLN-Zero).
- Optimization: The training objective employs a composite loss function comprising L1 reconstruction loss, LPIPS perceptual loss, and CLIP similarity loss to ensure semantic and visual fidelity.
Experimental Setup
The model was evaluated on two primary paired benchmarks:
- face2comics: 10,000 pairs testing identity preservation under radical style shifts.
- edges2shoes: ~50,000 pairs testing structural-to-appearance translation.
Additionally, the CMP Facade Database was used to evaluate performance in low-data regimes.
Results and Discussion
Qualitative analysis demonstrates that the DiT-based model produces sharper textures and fewer artifacts compared to Pix2Pix and Pix2PixHD. In the face2comics task, the model excels at maintaining the recognizable features of the source subjects.
Key Insights
- Scalability: Transformers handle high-resolution details more gracefully than U-Nets, avoiding common "blurry" artifacts.
- Semantic Guidance: CLIP embeddings provide a high-level understanding of image content, facilitating better identity preservation.
- Data Sensitivity: While the model outperforms baselines on large datasets, it struggles on very small datasets (e.g., the 400-image Facade set), indicating that Diffusion Transformers are significantly more data-hungry than GANs.
Computational Costs
The performance gains come with substantial overhead. The DiT model (12.92 GB) is significantly larger than Pix2Pix (207 MB). Inference is approximately 900x slower (36.1s vs 0.04s per image) due to the iterative nature of diffusion sampling.
Conclusion
This work demonstrates the potential of Diffusion Transformers for high-quality I2I translation. While the computational cost remains a barrier for real-time applications, the improvements in structural and semantic fidelity are significant. Future work will focus on efficiency optimizations and extending the framework to unpaired translation tasks.
Summary updated