Component-Aware Sketch-to-Image Generation Using Self-Attention Encoding and Coordinate-Preserving Fusion
Organizations: School of Computing, Engineering and Mathematical Sciences La Trobe University. · Gujranwala Institute of Future Technologies(GIFT) University. · Data61, CSIRO. · Sino-Pak Centre for Artificial Intelligence Pak-Austria Fachhochschule Institute of Applied Sciences and Technology.
Abstract
Translating freehand sketches into photorealistic images remains a fundamental challenge in image synthesis, particularly due to the abstract, sparse, and stylistically diverse nature of sketches. Existing approaches, including GAN-based and diffusion-based models, often struggle to reconstruct fine-grained details, maintain spatial alignment, or adapt across different sketch domains. In this paper, we propose a component-aware, self-refining framework for sketch-to-image generation that addresses these challenges through a novel two-stage architecture. A Self-Attention-based Autoencoder Network (SA2N) first captures localised semantic and structural features from component-wise sketch regions, while a Coordinate-Preserving Gated Fusion (CGF) module integrates these into a coherent spatial layout. Finally, a Spatially Adaptive Refinement Revisor (SARR), built on a modified StyleGAN2 backbone, enhances realism and consistency through iterative refinement guided by spatial context. Extensive experiments across both facial (CelebAMask-HQ, CUFSF) and non-facial (Sketchy, ChairsV2, ShoesV2) datasets demonstrate the robustness and generalizability of our method. The proposed framework consistently outperforms state-of-the-art GAN and diffusion models, achieving significant gains in image fidelity, semantic accuracy, and perceptual quality. On CelebAMask-HQ, our model improves over prior methods by 21% (FID), 58% (IS), 41% (KID), and 20% (SSIM). These results, along with higher efficiency and visual coherence across diverse domains, position our approach as a strong candidate for applications in forensics, digital art restoration, and general sketch-based image synthesis.
Figures & tables
| Method | FID | IS | KID | SSIM | PSNR | LPIPS |
|---|---|---|---|---|---|---|
| CelebAMask-HQ dataset [ 31 ] | ||||||
| ControlNet [ 20 ] | 172.93 | 1.97 | 135.25 | 0.55 | 26.31 | 0.35 |
| T2I-Adapter [ 21 ] | 508.00 | 1.00 | 114.76 | 0.31 | 16.27 | 0.48 |
| Pix2PixHD [ 14 ] | 172.93 | 1.28 | 92.95 | 0.61 | 25.31 | 0.38 |
| CycleGAN [ 36 ] | 148.78 | 1.31 | 105.99 | 0.53 | 28.02 | 0.28 |
| pSp [ 18 ] | 99.16 | 1.74 | 73.58 | 0.66 | 29.32 | 0.17 |
| Sketch Type | FID | IS | KID | SSIM | PSNR | LPIPS |
|---|---|---|---|---|---|---|
| DFD [ 9 ] | ||||||
| Hand Drawn Sketch | 191.01 | 1.70 | 94.65 | 0.52 | 25.768 | 0.368 |
| Line Sketch | 130.88 | 1.49 | 38.87 | 0.67 | 27.570 | 0.259 |
| Photoshop Sketch | 115.63 | 1.51 | 59.15 | 0.65 | 28.027 | 0.278 |
| Ours | ||||||
| Hand Drawn Sketch | 131.26 | 1.63 | 63.12 | 0.67 | 27.558 | 0.259 |
| Method | FID | IS | KID | SSIM | PSNR | LPIPS |
|---|---|---|---|---|---|---|
| Sketchy Database [ 43 ] | ||||||
| ControlNet [ 20 ] | 198.32 | 1.82 | 152.47 | 0.53 | 24.12 | 0.462 |
| T2I-Adapter [ 21 ] | 247.66 | 1.65 | 178.13 | 0.50 | 22.35 | 0.507 |
| Pix2PixHD [ 14 ] | 172.14 | 1.91 | 129.86 | 0.61 | 25.87 | 0.389 |
| CycleGAN [ 36 ] | 215.43 | 1.75 | 141.73 | 0.55 | 25.54 | 0.378 |
| Ours | 131.72 | 2.70 | 115.60 | 0.76 | 28.38 | 0.320 |
| Model | Top-3 Hit Score (%) | LFW Score (%) |
|---|---|---|
| Facenet512 | 94.20 | 99.65 |
| ArcFace | 86.80 | 99.41 |
| Dlib | 84.60 | 99.38 |
| VGG-Face | 88.50 | 98.78 |
| SA | AFIG | GM | SARR | FID | IS | KID | SSIM | PSNR | LPIPS | ||
|---|---|---|---|---|---|---|---|---|---|---|---|
| 1 | 115.8407 | 1.53477 | 66.75375 | 0.6691 | 18.0213 | 0.2822 | |||||
| 2 | ✓ | 102.196 | 1.66641 | 61.48586 | 0.7414 | 17.3119 | 0.2735 | ||||
| 3 | ✓ | ✓ | 91.876 | 1.9865 | 53.5971 | 0.7536 | 23.5864 | 0.1466 | |||
| 4 | ✓ | ✓ | ✓ | 61.5866 | 1.86954 | 45.1064 | 0.7753 | 29.3125 | 0.1498 | ||
| 5 | ✓ | ✓ | ✓ | 71.444 | 1.7006 | 46.2568 | 0.7698 | 29.6437 | 0.1549 | ||
| 6 | ✓ | ✓ | 63.2837 | 1.795 | 44.6407 | 0.7665 | 28.5526 | 0.1395 |
| Method | CelebA | CUFSF | Sketchy | Chairs | Shoes |
|---|---|---|---|---|---|
| CycleGAN | 0.42 | 0.39 | 0.36 | 0.34 | 0.33 |
| Pix2PixHD | 0.47 | 0.44 | 0.40 | 0.38 | 0.37 |
| pSp | 0.53 | 0.49 | 0.46 | 0.43 | 0.42 |
| DFD | 0.61 | 0.59 | 0.55 | 0.52 | 0.50 |
| Ours | 0.74 | 0.71 | 0.69 | 0.67 | 0.66 |
Image Generation
Image generation studies models that create or edit images from text, examples, layouts, and other structured controls.
See all 463 papers