Analyzing Diffusion Models: Transformer Integration and Prompt Optimization for Text-To-Image Generation
Abstract
This paper delves into the analysis of various diffusion models, focusing on their utilization of text-conditional sampling and assessment using the contrastive language-image pre-training (CLIP) score as a metric. Leveraging Bidirectional Transformers (BERT) and Vision Transformers (ViT) within the CLIP model framework, it crucially compares models incorporating transformer blocks with those that do not. Specifically, it examines the structures of latent diffusion models and diffusion transformer models, emphasizing the use of Unet and Transformer block decoders, respectively. Additionally, the study explores different prompts to generate similar images, aiming to optimize conditioning training for text-to-image generation. Furthermore, the paper investigates the performance of the Latent Diffusion Model (LDM) and the DiT model in object generation, analyzing their interaction with text embeddings and prompt structures. The findings underscore the significance of prompt structures on model performance, with implications for future research into multimodal models and prompt optimization.
References
- Li A. C, Prabhudesai, M., Duggal, S., Brown, E., & Pathak, D. (2023). Your diffusion model is secretly a zero-shot classifier. In Proceedings of the IEEE/CVF International Conference on Computer Vision (pp. 2206-2217).
- Bond-Taylor S, Leach A, Long Y, & Willcocks C. G. (2021). Deep generative modelling: A comparative review of vaes, gans, normalizing flows, energy-based and autoregressive models. IEEE transactions on pattern analysis and machine intelligence, 44(11), 7327-7347.
- Ho J, Jain A, & Abbeel P. (2020). Denoising diffusion probabilistic models. Advances in neural information processing systems, 33, 6840-6851.
- Rombach R, Blattmann A, Lorenz D, Esser P, & Ommer B. (2022). High-resolution image synthesis with latent diffusion models. In Proceedings of the IEEE/CVF conference on computer vision and pattern recognition (pp. 10684-10695).
- Vaswani A, Shazeer N, Parmar N, Uszkoreit J, Jones L, Gomez A. N, ... & Polosukhin I (2017). Attention is all you need. Advances in neural information processing systems, 30.
- Peebles W, & Xie S (2023). Scalable diffusion models with transformers. In Proceedings of the IEEE/CVF International Conference on Computer Vision (pp. 4195-4205).
- Radford A, Kim J. W, Hallacy C, Ramesh A, Goh G, Agarwal S, ... & Sutskever I. (2021, July). Learning transferable visual models from natural language supervision. In International conference on machine learning (pp. 8748-8763). PMLR.
- Hessel J, Holtzman A, Forbes M, Bras R. L, & Choi Y (2021). Clipscore: A reference-free evaluation metric for image captioning. arXiv preprint arXiv:2104.08718.
- Devlin J, Chang M. W, Lee K, & Toutanova K (2018). Bert: Pre-training of deep bidirectional transformers for language understanding. arXiv preprint arXiv:1810.04805.
- Dosovitskiy A, Beyer L, Kolesnikov A, Weissenborn D, Zhai X, Unterthiner T, ... & Houlsby N (2020). An image is worth 16x16 words: Transformers for image recognition at scale. arXiv preprint arXiv:2010.11929.
- Krizhevsky A, & Hinton G (2009). Learning multiple layers of features from tiny images.
- Deng J, Dong W, Socher R, Li L. J, Li K, & Li F (2009, June). Imagenet: A large-scale hierarchical image database. In 2009 IEEE conference on computer vision and pattern recognition (pp. 248-255). Ieee.