Title: RAPHAEL: Text-to-Image Generation via Large Mixture of Diffusion Paths
Venue: NeurIPS 2023
Accepted: yes
Keywords: Diffusion Model

Text-to-Image Generation
Abstract: Text-to-image generation has recently witnessed remarkable achievements. We introduce a text-conditional image diffusion model, termed RAPHAEL, to generate highly artistic images, which accurately portray the text prompts, encompassing multiple nouns, adjectives, and verbs. This is achieved by  stacking tens of mixture-of-experts (MoEs) layers, i.e., space-MoE  and time-MoE layers,  enabling billions of diffusion paths (routes) from the network input to the output. Each path intuitively functions as a "painter" for depicting a particular textual concept onto a specified image region at a diffusion timestep. Comprehensive experiments reveal that RAPHAEL outperforms recent cutting-edge models, such as Stable Diffusion, ERNIE-ViLG 2.0, DeepFloyd, and DALL-E 2, in terms of both image quality and aesthetic appeal.  Firstly, RAPHAEL exhibits superior performance in switching images across diverse styles, such as Japanese comics, realism, cyberpunk, and ink illustration. Secondly, a single model with three billion parameters, trained on 1,000 A100 GPUs for two months, achieves a state-of-the-art zero-shot FID score of 6.61 on the COCO dataset. Furthermore, RAPHAEL significantly surpasses its counterparts in human evaluation on the ViLG-300 benchmark. We believe that RAPHAEL holds the potential to propel the frontiers of image generation research in both academia and industry, paving the way for future breakthroughs in this rapidly evolving field. More details can be found on a webpage: https://raphael-painter.github.io/.

RAPHAEL: Text-to-Image Generation via Large Mixture of Diffusion Paths

Abstract

Text-to-image generation has recently witnessed remarkable achievements. We introduce a text-conditional image diffusion model, termed RAPHAEL, to generate highly artistic images, which accurately portray the text prompts, encompassing multiple nouns, adjectives, and verbs. This is achieved by stacking tens of mixtureof-experts (MoEs) layers, i.e., space-MoE and time-MoE layers, enabling billions of diffusion paths (routes) from the network input to the output. Each path intuitively functions as a 'painter' for depicting a particular textual concept onto a specified image region at a diffusion timestep. Comprehensive experiments reveal that RAPHAEL outperforms recent cutting-edge models, such as Stable Diffusion, ERNIE-ViLG 2.0, DeepFloyd, and DALL-E 2, in terms of both image quality and aesthetic appeal. Firstly, RAPHAEL exhibits superior performance in switching images across diverse styles, such as Japanese comics, realism, cyberpunk, and ink illustration. Secondly, a single model with three billion parameters, trained on 1 , 000 A100 GPUs for two months, achieves a state-of-the-art zero-shot FID score of 6 . 61 on the COCO dataset. Furthermore, RAPHAEL significantly surpasses its counterparts in human evaluation on the ViLG-300 benchmark. We believe that RAPHAEL holds the potential to propel the frontiers of image generation research in both academia and industry, paving the way for future breakthroughs in this rapidly evolving field. More details can be found on a webpage: https: //raphael-painter.github.io/ § .

RAPHAEL

StableDiffusion XL

DeepFloyd

DALL-E 2

ERNIE-ViLG 2.0

A parrot with a pearl earring , Vermeer style.

A car playing soccer , digital art.

A Pikachu with an angry expression and red eyes, with lightning around it, hyper realistic style.

There are five cars in the street.

Street shot of a fashionable Chinese lady in Shanghai, wearing black high ­ waisted trousers .

Moonlight Maiden, cute girl in school uniform, long white hair , standing under the moon , celluloid style, Japanese manga style.

Half human , half robot , repaired human, human flesh warrior, mech display, man in mech, cyberpunk .

A

sign

that

says

RAPHAEL

.

OB

RAPUPEL

Raahe

03

RAPHAEL

RAPEEL

1 Introduction

Recent advancements in text-to-image generators, such as Imagen [1], Stable Diffusion [2], DALLE 2 [3], eDiff-I [4], and ERNIE-ViLG 2.0 [5], have yielded remarkable success and found wide applications in computer graphics, culture and art, and the generation of medical and biological data.

Despite the substantial progress made in text-to-image diffusion models [1, 2, 3, 4, 5], there remains a pressing need for research to further achieve more precise alignment between text and image. As

illustrated in Fig.1, existing models often fail to adequately preserve textual concepts within the generated images. This is primarily due to the reliance on a classic cross-attention mechanism for integrating text descriptions into visual representations, resulting in relatively coarse control of the diffusion process, and leading to compromised results.

To address this issue, we introduce RAPHAEL, a text-to-image generator, which yields images with superior artistry and fidelity compared to prior work, as demonstrated in Fig.2. RAPHAEL, an acronym that stands for 'distinct image r egions a lign with different text ph ases in a tt e ntion l earning', offers an appealing benefit not found in existing approaches.

Specifically, we observe that different text concepts influence distinct image regions during the generation process [6], and the conventional cross-attention layer often struggles to preserve these varying concepts adequately in an image. To mitigate this issue, we employ a diffusion model stacking tens of mixture-of-experts (MoE) layers [7, 8], including both space-MoE and time-MoE layers. Concretely, the space-MoE layers are responsible for depicting different concepts in specific image regions, while the time-MoE layers focus on painting these concepts at different diffusion timesteps.

This configuration leads to billions of diffusion paths from the network input to the output. Naturally, each path can act as a 'painter' responsible for rendering a particular concept to an image region at a specific timestep. The result is a more precise alignment between text tokens and image regions, enabling the generated images that accurately represent the associated text prompt. This approach sets RAPHAEL apart from existing models and even sheds light on future studies of the explainability of the generation process. Additionally, we propose an edge-supervised learning module to further enhance the image quality and aesthetic appeal of the generated images.

Extensive experiments demonstrate that RAPHAEL outperforms preceding approaches, such as Stable Diffusion, ERNIE-ViLG 2.0, DeepFloyd, and DALL-E 2. (1) RAPHAEL exhibits superior performance in switching images across diverse styles, such as Japanese comics, realism, cyberpunk, and ink illustration. (2) RAPHAEL establishes a new state-of-the-art with a zero-shot FID-30k score of 6 . 61 on the COCO dataset. (3) RAPHAEL, a single model with three billion parameters trained on 1 , 000 A100 GPUs, significantly surpasses its counterparts in human evaluation on the ViLG-300 benchmark.

The contributions of this work are three-fold: (i) We propose a novel text-to-image generator, RAPHAEL, which, through the implementation of several carefully-designed techniques, generates images that more accurately reflect textual prompts than previous works. (ii) We thoroughly explore RAPHAEL's potential for switching images in diverse styles, such as Japanese comics, realism, cyberpunk, and ink illustration, and for extension using LoRA [9], ControlNet [10], and SR-GAN [11]. (iii) We will release a programming API for RAPHAEL to the public. We believe that RAPHAEL holds the potential to advance the frontiers of image generation in both academia and industry, paving the way for future breakthroughs in this rapidly evolving field.

2 Notation and Preliminary

We present the necessary notations and the Denoising Diffusion Probabilistic Model (DDPM) [12] for text-to-image generation. Given a collection of N images, denoted as { x i } N i =1 , the aim is to learn a generative model, p ( x ) , that is capable of accurately representing the underlying distribution.

In forward diffusion, Gaussian noise is progressively introduced into the source images. At an arbitrary timestep t , it is possible to directly sample from the Gaussian distribution following the T -step noise schedule { α t } T t =1 , without iterative forward sampling. Consequently, the noisy image at timestep t , denoted as x t , can be expressed as x t = √ 1 -¯ α t x 0 + √ ¯ α t ϵ t , where ¯ α t = ∏ t i =1 α i . In this expression, x 0 represents the source image, while ϵ t ∼ N (0 , I ) indicates the Gaussian noise at step t . In the reverse process, a denoising neural network, denoted as D θ ( · ) , is employed to estimate the additive Gaussian noise. The optimization of this network is achieved by minimizing the loss

By employing the Bayes' theorem, it is feasible to iteratively estimate the image at timestep t -1 through sampling from the posterior distribution, p θ ( x t -1 | x t ) . We have x t -1 =

1 √ α t ( x t -1 -α t √ 1 -¯ α t D θ ( x t , t ) ) + σ t z , where σ t signifies the standard deviation of the newly injected noise into the image at each step, and z represents the Gaussian noise.

In essence, the denoising neural network estimates the score function at varying time steps, thereby progressively recovering the structure of the image distribution. The fundamental insight provided by the DDPM lies in the fact that the perturbation of data points with noise serves to populate regions of low data density, ultimately enhancing the accuracy of estimated scores. This results in stable training and sampling.

U-Net with Text Prompts. The denoising network is commonly implemented using a U-Net [13] architecture, as depicted in Fig.8 in Appendix 7.3. To incorporate textual prompts (denoted by y ) into the U-Net, a text encoder neural network, E θ ( y ) , is employed to extract the textual representation.

1

Self

Attention

Cross

Attention

Time

MoE

Space

MoE

(a) Transformer Block

Attn map

M

A furry bear

under sky

𝐿

!"#!

N x Conv

(b) Space-MoE

A furry bear under sky

Text Gate

Bear

Sky

Features

Attn map

Furry

Mask

Expert 1

Expert n

Expert 2

…

❄

❄

🔥

🔥

🔥

❄

M

∗,#

M

∗,$

M

∗,%

M

!

#

M

!

$

M

!

%

The extracted text tokens are input into the U-Net through a cross-attention layer. The text tokens possess a size of n y × d y , where n y represents the number of text tokens, and d y signifies the dimension of a text token ( e.g., d y = 768 in [14]).

The cross-attention layer can be formulated as attention( Q , K , V ) = softmax ( QK ⊤ √ d ) V , where Q , K , and V correspond to the query, key, and value matrices, respectively. These matrices are computed as Q = h ( x t ) W qry x , K = E θ ( y ) W key y , and V = E θ ( y ) W val y , where W qry x ∈ R d × d and W key y , W val y ∈ R d y × d represent the parametric projection matrices for the image and text, respectively. Additionally, d denotes the dimension of an image token, h ( x t ) ∈ R n x × d indicates the flattened intermediate representation within the U-Net, with n x being the number of tokens in an image. A cross-attention map between the text and image, M = softmax ( QK ⊤ √ d ) ∈ R n x × n y , is defined, which plays a crucial role in the proposed approach, as described in the following sections.

3 Our Approach

The overall framework of RAPHAEL is illustrated in Fig.3, with the network configuration details provided in the Appendix 7.1. Employing a U-Net architecture, the framework consists of 16 transformer blocks, each containing four components: a self-attention layer, a cross-attention layer, a space-MoE layer, and a time-MoE layer. The space-MoE is responsible for depicting different text concepts in specific image regions at a given scale, while the time-MoE handles different diffusion timesteps.

3.1 Space-MoE and Time-MoE

Space-MoE. Regarding the space-MoE layer, distinct text tokens correspond to various regions within an image, as previously mentioned. For instance, when provided with the prompt 'a furry bear under the sky', each text token and its corresponding image region (represented by a binary mask) are fed into separate experts, as illustrated in Fig.3b. The space-MoE layer's output is the mean of all experts, calculated using the following formula: 1 n y ∑ n y i =1 e route( y i ) ( h ′ ( x t ) ◦ ̂ M i ) . In this equation, ̂ M i is a binary two-dimensional matrix, indicating the image region the i -th text token should correspond to, as shown in Fig.3b. Here, ◦ represents hadamard product, and h ′ ( x t ) is the features from time-MoE. The gating (routing) function route( y i ) returns the index of an expert in the space-MoE, with { e 1 , e 2 , . . . , e k } being a set of k experts.

Text Gate Network. The Text Gate Network is employed to distribute an image region to a specific expert, as shown in Fig.3b. The function route( y i ) = argmax (softmax ( G ( E θ ( y i )) + ϵ )) is used, where G : R d y ↦→ R k is a feed forward network, which uses a text token representation E θ ( y i ) as input and assigns a space expert. To prevent mode collapse, random noise ϵ is incorporated. The

Expert index:

1

2

3

4

5

6

7

8

9

10

11

12

13

14

15

0

1

2

3

4

5

Expert index:

Block index:

0

1

2

3

4

5

6

7

8

9

10

11

12

13

14

15

0

1

2

3

4

5

Block index:

0

donut

banana

cake

chair

horse

laptop

orange

pizza

train

aeroplane

argmax function ensures that one expert exclusively handles the corresponding image region for each text token, without increasing computational complexity.

From Text to Image Region. Recall that M is the cross-attention map between text and image, where each element, M j,i , represents a correspondence value between the j -th image token and the i -th text token. In the space-MoE, each entry in the binary mask ̂ M i equals '1' if M j,i ≥ η i , otherwise '0' if M j,i < η i , as illustrated in Fig.3b. A thresholding mechanism is introduced to determine the values in the mask. The threshold value η i = α max( M ∗ ,i ) is defined, where max( M ∗ ,i ) represents the maximum correspondence between text token i and all image regions. The hyper-parameter α will be evaluated through an ablation study.

Discussions. The insight behind the space-MoE is to effectively model the intricate relationships between text tokens and their corresponding regions in the image, accurately reflecting concepts in the generated images. As illustrated in Fig.4, the employment of 16 space-MoE layers, each containing 6 experts, results in billions of spatial diffusion paths ( i.e., 6 16 possible routes). It is evident that each diffusion path is closely associated with a specific textual concept.

To investigate this further, we generate 100 prevalent adjectives that are the most frequently occurring adjectives for describing artworks as suggested by GPT-3.5 [15, 16]. Given that GPT-3.5 has been trained on trillions of tokens, we posit that these adjectives reflect a diverse, real-world distribution. We input each adjective into the RAPHAEL model to generate 100 distinct images and collect their corresponding diffusion paths. Consequently, we obtain ten thousand paths for the 100 words. By treating these pathways as features ( i.e., each path is a vector of 16 entries), we train a straightforward classifier ( e.g., XGBoost [17]) to categorize the words. The classifier after 5-fold cross-validation achieves over 93% accuracy for open-world adjectives, demonstrating that different diffusion paths distinctively represent various textual concepts. We observe analogous phenomena within the 80 object categories of the COCO dataset. Further details on verbs and visualization are provided in the Appendix 7.5.

Time-MoE. We can further enhance the image quality by employing a time-mixture-of-experts (time-MoE) approach, which is inspired by previous works such as [4, 5]. Given that the diffusion process iteratively corrupts an image with Gaussian noise over a series of timesteps t = 1 , . . . , T , the image generator is trained to denoise the images in reverse order from t = T to t = 1 . All timesteps aim to denoise a noisy image, progressively transforming random noise into an artistic image. Intuitively, the difficulty of these denoising steps varies depending on the noise ratio presented in the image. For example, when t = T , the denoising network's input image x t is highly noisy. When t = 1 , the image x t is closer to the original image.

To address this issue, we employ a time-MoE before each space-MoE in each transformer block. In contrast to [4, 5] , which necessitate hand-crafted time expert assignments, we implement an additional gate network to automatically learn to assign different timesteps to various time experts. Further details can be found in the Appendix 7.3.

3.2 Edge-supervised Learning

In order to further enhance the image quality, we propose incorporating an edge-supervised learning strategy to train the transformer block. By implementing an edge detection module, we aim to extract rich boundary information from an image. These intricate boundaries can serve as supervision to guide the model in preserving detailed image features across various styles.

Consider a neural network module, P θ ( M ) , with parameters of N convolutional layers ( e.g., N = 5 ). This module is designed to predict an edge map given an attention map M (refer to Fig.7a in the Appendix 7.2). We utilize the edge map of the input image, denoted as I edge , to supervise the network P θ . I edge can be obtained by the holistically-nested edge detection algorithm [18] (Fig.7b). Intuitively, the network P θ can be trained by minimizing the loss function, L edge = Focal( P θ ( M ) , I edge ) , where Focal( · , · ) denotes the focal loss [19] employed to measure the discrepancy between the predicted and the 'ground-truth' edge maps. Moreover, as discussed in [5, 6], the attention map M is prone to becoming vague when the timestep t is large. Consequently, it is essential to adopt a timestep threshold value to inactivate (pause) edge-supervised learning when t is large. This timestep threshold value ( T c ) is a hyper-parameter that will be evaluated through an ablation study.

Overall, the RAPHAEL model is trained by combining two loss functions, L = L denoise + L edge . As demonstrated in Fig.7d in the Appendix 7.2, edge-supervised learning substantially improves the image quality and aesthetic appeal of the generated images.

4 Experiments

This section presents the experimental setups, the quantitative results compared to recent state-ofthe-art models, and the ablation study to demonstrate the effectiveness of RAPHAEL. More artistic images generated by RAPHAEL and comparisons between RAPHAEL and other diffusion models can be found in Appendix 7.6 and 7.7.

Dataset . The training dataset consists of a subset of LAION-5B [20] and some internal datasets, including 730M text-images pairs in total. To collect training data from LAION-5B, we filter the images using the aesthetic scorer same as Stable Diffusion [2] and remove the image-text pairs that have scores smaller than 4 . 7 . We remove the images with watermarks either. Since the text descriptions in LAION-5B are noisy, we clean them by removing useless information such as URLs, HTML tags, and email addresses, inspired by [2, 4, 21].

Multi-scale Training . To improve text-image alignment, instead of cropping images to a fixed scale [2], we resize an image to its nearest size into different buckets, which has 9 different image scales. Additionally, the GPU resources will be automatically allocated to each bucket depending on the number of images it contains, enabling effective use of computational resources * .

Implementations . To reduce training and sampling complexity, we use a Variational Autoencoder (VAE) [22, 23] to compress images using Latent Diffusion Model [2]. We first pre-train an image encoder to transform an image from pixel space to a latent space, and an image decoder to convert it back. Unlike previous works, the cross-attention layers in RAPHAEL are augmented with space-MoE and time-MoE layers. The entire model is implemented in PyTorch [24], and is trained by AdamW [25] optimizer with a learning rate of 1 e -4 , a weight decay of 0 , a batch size of 2 , 000 , on 1 , 000 NVIDIA A100s for two months. More details on the hyper-parameter settings can be found in the Appendix 7.1.

4.1 Comparisons

Results on COCO . Following previous works [1, 2, 4], we evaluate RAPHAEL on the COCO 256 × 256 dataset using zero-shot Frechet Inception Distance (FID), which measures the quality and diversity of images. Similar to [1, 2, 4, 5, 32], 30 , 000 images are randomly selected from the validation set for evaluation. Table 1 shows that RAPHAEL achieves a new state-of-the-art

performance of text-to-image generation, with 6 . 61 zero-shot FID-30k on MS-COCO, surpassing prominent image generators such as Stable Diffusion, Imagen, ERNIE-ViLG 2.0, and DALL-E 2.

Human Evaluations . We employ the ViLG-300 benchmark [5], a bilingual prompt set, which enables to systematically evaluate text-to-image models given various text prompts in Chinese and English. ViLG-300 allows us to convincingly compare RAPHAEL with recent-advanced models including DALL-E 2, Stable Diffusion, ERNIE-ViLG 2.0, and DeepFloyd, in terms of both image quality and text-image alignment. For example, human artists are presented with two sets of images generated by RAPHAEL and a competitor, respectively. They are asked to compare these images from two aspects respectively, including image-text alignment, and image quality and aesthetics. Throughout the entire process, human artists are unaware of which model the image is generated from. Fig.5 shows that RAPHAEL surpasses all other models in both image-text alignment and image quality in the user study, indicating that RAPHAEL can generate high-artistry images that conform to the text.

Extensions to LoRA, ControlNet, and SR-GAN. RAPHAEL can be further extended by incorporating LoRA, ControlNet, and SR-GAN. In Appendix 7.8, we present a comparison between RAPHAEL and Stable Diffusion utilizing LoRA. RAPHAEL demonstrates superior robustness against overfitting compared to Stable Diffusion. We also demonstrate RAPHAEL with a canny-based ControlNet. Furthermore, by employing a tailormade SR-GAN model, we enhance the image resolution to 4096 × 6144 .

4.2 Ablation Study

Evaluate every module in RAPHAEL. We conduct a comprehensive assessment of each module within the RAPHAEL model, utilizing the CLIP [14] score to measure image-text alignment. Given the significance of classifier-free guidance weight in controlling image quality and text alignment, we present ablation results as trade-off curves between CLIP and FID scores across a range of

(a) Impact of

!

and

"

!

.

(c) Impact of experts.

(b) FID-CLIP score curves.

guidance weights [33], specifically 1 . 5 , 3 . 0 , 4 . 5 , 6 . 0 , 7 . 5 , and 9 . 0 . Fig.6b compares these curves for the complete RAPHAEL model and its variants without space-MoE, edge-supervised learning, and time-MoE, respectively. Our findings indicate that all modules contribute effectively. For example, space-MoE substantially enhances the CLIP score and the optimal guidance weight for the sampler shifts from 3.0 to 4.5. Moreover, at the same guidance weight, space-MoE considerably reduces the FID, resulting in a significant improvement in image quality.

Choice of α and T c . As depicted in Fig.6a, we observe that α = 0 . 2 delivers the best performance, implying a balance between preserving adequate features and avoiding the use of the entire latent features. An appropriate threshold value for T c terminates edge-supervised learning when the diffusion timestep is large. Our experiments reveal that a suitable choice for T c is 500, ensuring the effective learning of texture information.

Performance and Runtime Analysis on Number of Experts. We offer an examination of the number of experts, ranging from 0 to 8 , in Fig.6c. For each setting, we employ 100 million training samples. Our results demonstrate that increasing the number of experts improves FID (lower values are preferable). However, adding spatial experts introduces additional computations, with the computational complexity bounded by the total number of experts. Once all available experts have been deployed, the computational complexity ceases to grow. In the right-hand side of Fig.6c, we provide a runtime analysis for 40 input tokens, ensuring the utilization of all space experts. For instance, when the number of experts is 6, the inference speed decreases by 24% but yields superior fidelity. This remains faster than previous diffusion models such as Imagen [1] and eDiff-I [4].

5 Related Work

We review related works from two perspectives, mixture-of-experts and text-to-image generation. More related works can be found in Appendix 7.4. Firstly, the Mixture-of-Experts (MoE) method [7, 8] partitions model parameters into distinct subsets, each termed an 'expert'. The MoE paradigm finds applicability beyond language processing tasks, extending to visual models [35] and Mixtureof-Modality-Experts within multi-modal transformers [36]. Additionally, efforts are being made to accelerate the training or inference processes for MoE [37, 38]. Secondly, text-to-image generation is to synthesize images from natural language descriptions. Early approaches relied on generative adversarial networks (GANs) [39, 40, 41, 42] to generate images. More recently, with the transformative success of transformers in generative tasks, models such as DALL-E [43], Cogview [44], and Make-A-Scene [29] have treated text-to-image generation as a sequence-to-sequence problem, utilizing auto-regressive transformers as generators and employing text/image tokens as input/output sequences. Recently, another research direction has focused on diffusion models by integrating textual conditioning within denoising steps, like Stable Diffusion [2], DALL-E 2 [3], eDiff-I [4], ERNIE-ViLG 2.0 [5], and Imagen [1].

6 Conclusion

This paper introduces RAPHAEL, a novel text-conditional image diffusion model capable of generating highly-artistic images using a large-scale mixture of diffusion paths. We carefully design space-MoE and time-MoE within an edge-supervised learning framework, enabling RAPHAEL to accurately portray text prompts, enhance the alignment between textual concepts and image regions, and produce images with superior aesthetic appeal. Comprehensive experiments demonstrate that RAPHAEL surpasses previous approaches, such as Stable Diffusion, ERNIE-ViLG 2.0, DeepFloyd, and DALL-E 2, in both FID-30k and the human evaluation benchmark ViLG-300. Additionally, RAPHAEL can be extended using LoRA, ControlNet, and SR-GAN. We believe that RAPHAEL has the potential to advance image generation research in both academia and industry.

Limitation and Potential Negative Societal Impact. We acknowledge some limitations in our paper that require attention. One limitation is the direct binarization of the attention map, which may result in the loss of some information. An adaptive module should be proposed to address this issue effectively. Additionally, the performance may be affected by failure cases of the edge detector, leading to potential degradation. We plan to explore solutions for these limitations in our future work. The potential negative social impact is to use the RAPHAEL API to create images containing misleading or false information. This issue potentially presents in all powerful text-toimage generators. We will solve this issue ( e.g., by prompt filtering) before releasing the API to the public.

Acknowledgments and Disclosure of Funding

This paper is partially supported by the National Key R&D Program of China No.2022ZD0161000 and the General Research Fund of Hong Kong No.17200622.

References

Chitwan Saharia, William Chan, Saurabh Saxena, Lala Li, Jay Whang, Emily L Denton, Kamyar Ghasemipour, Raphael Gontijo Lopes, Burcu Karagol Ayan, Tim Salimans, et al. Photorealistic text-to-image diffusion models with deep language understanding. Advances in Neural Information Processing Systems , 35:36479-36494, 2022.

Robin Rombach, Andreas Blattmann, Dominik Lorenz, Patrick Esser, and Björn Ommer. Highresolution image synthesis with latent diffusion models. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition , pages 10684-10695, 2022.

Aditya Ramesh, Prafulla Dhariwal, Alex Nichol, Casey Chu, and Mark Chen. Hierarchical text-conditional image generation with clip latents. arXiv preprint arXiv:2204.06125 , 2022.

Yogesh Balaji, Seungjun Nah, Xun Huang, Arash Vahdat, Jiaming Song, Karsten Kreis, Miika Aittala, Timo Aila, Samuli Laine, Bryan Catanzaro, et al. ediffi: Text-to-image diffusion models with an ensemble of expert denoisers. arXiv preprint arXiv:2211.01324 , 2022.

Zhida Feng, Zhenyu Zhang, Xintong Yu, Yewei Fang, Lanxin Li, Xuyi Chen, Yuxiang Lu, Jiaxiang Liu, Weichong Yin, Shikun Feng, et al. Ernie-vilg 2.0: Improving text-to-image diffusion model with knowledge-enhanced mixture-of-denoising-experts. arXiv preprint arXiv:2210.15257 , 2022.

Amir Hertz, Ron Mokady, Jay Tenenbaum, Kfir Aberman, Yael Pritch, and Daniel Cohen-Or. Prompt-to-prompt image editing with cross attention control. arXiv preprint arXiv:2208.01626 , 2022.

Noam Shazeer, Azalia Mirhoseini, Krzysztof Maziarz, Andy Davis, Quoc Le, Geoffrey Hinton, and Jeff Dean. Outrageously large neural networks: The sparsely-gated mixture-of-experts layer. arXiv preprint arXiv:1701.06538 , 2017.

William Fedus, Barret Zoph, and Noam Shazeer. Switch transformers: Scaling to trillion parameter models with simple and efficient sparsity. The Journal of Machine Learning Research , 23(1):5232-5270, 2022.

Edward J Hu, Yelong Shen, Phillip Wallis, Zeyuan Allen-Zhu, Yuanzhi Li, Shean Wang, Lu Wang, and Weizhu Chen. Lora: Low-rank adaptation of large language models. arXiv preprint arXiv:2106.09685 , 2021.

Lvmin Zhang and Maneesh Agrawala. Adding conditional control to text-to-image diffusion models. arXiv preprint arXiv:2302.05543 , 2023.

Xintao Wang, Liangbin Xie, Chao Dong, and Ying Shan. Real-esrgan: Training real-world blind super-resolution with pure synthetic data. In Proceedings of the IEEE/CVF International Conference on Computer Vision , pages 1905-1914, 2021.

Jonathan Ho, Ajay Jain, and Pieter Abbeel. Denoising diffusion probabilistic models. Advances in Neural Information Processing Systems , 33:6840-6851, 2020.

Olaf Ronneberger, Philipp Fischer, and Thomas Brox. U-net: Convolutional networks for biomedical image segmentation. In Medical Image Computing and Computer-Assisted Intervention-MICCAI 2015: 18th International Conference, Munich, Germany, October 5-9, 2015, Proceedings, Part III 18 , pages 234-241. Springer, 2015.

Alec Radford, Jong Wook Kim, Chris Hallacy, Aditya Ramesh, Gabriel Goh, Sandhini Agarwal, Girish Sastry, Amanda Askell, Pamela Mishkin, Jack Clark, et al. Learning transferable visual models from natural language supervision. In International Conference on Machine Learning , pages 8748-8763. PMLR, 2021.

Tom Brown, Benjamin Mann, Nick Ryder, Melanie Subbiah, Jared D Kaplan, Prafulla Dhariwal, Arvind Neelakantan, Pranav Shyam, Girish Sastry, Amanda Askell, et al. Language models are few-shot learners. Advances in Neural Information Processing Systems , 33:1877-1901, 2020.

Long Ouyang, Jeffrey Wu, Xu Jiang, Diogo Almeida, Carroll Wainwright, Pamela Mishkin, Chong Zhang, Sandhini Agarwal, Katarina Slama, Alex Ray, et al. Training language models to follow instructions with human feedback. Advances in Neural Information Processing Systems , 35:27730-27744, 2022.

Tianqi Chen, Tong He, Michael Benesty, Vadim Khotilovich, Yuan Tang, Hyunsu Cho, Kailong Chen, Rory Mitchell, Ignacio Cano, Tianyi Zhou, et al. Xgboost: extreme gradient boosting. R package version 0.4-2 , 1(4):1-4, 2015.

Saining Xie and Zhuowen Tu. Holistically-nested edge detection. In Proceedings of the IEEE International Conference on Computer Vision , pages 1395-1403, 2015.

Tsung-Yi Lin, Priya Goyal, Ross Girshick, Kaiming He, and Piotr Dollár. Focal loss for dense object detection. In Proceedings of the IEEE International Conference on Computer Vision , pages 2980-2988, 2017.

Christoph Schuhmann, Romain Beaumont, Richard Vencu, Cade Gordon, Ross Wightman, Mehdi Cherti, Theo Coombes, Aarush Katta, Clayton Mullis, Mitchell Wortsman, et al. Laion5b: An open large-scale dataset for training next generation image-text models. arXiv preprint arXiv:2210.08402 , 2022.

Fan Bao, Shen Nie, Kaiwen Xue, Chongxuan Li, Shi Pu, Yaole Wang, Gang Yue, Yue Cao, Hang Su, and Jun Zhu. One transformer fits all distributions in multi-modal diffusion at scale. arXiv preprint arXiv:2303.06555 , 2023.

Aaron Van Den Oord, Oriol Vinyals, et al. Neural discrete representation learning. Advances in Neural Information Processing Systems , 30, 2017.

Diederik P Kingma, Max Welling, et al. An introduction to variational autoencoders. Foundations and Trends in Machine Learning , 12(4):307-392, 2019.

Adam Paszke, Sam Gross, Francisco Massa, Adam Lerer, James Bradbury, Gregory Chanan, Trevor Killeen, Zeming Lin, Natalia Gimelshein, Luca Antiga, et al. Pytorch: An imperative style, high-performance deep learning library. Advances in Neural Information Processing Systems , 32, 2019.

Ilya Loshchilov and Frank Hutter. Decoupled weight decay regularization. arXiv preprint arXiv:1711.05101 , 2017.

Ming Tao, Hao Tang, Fei Wu, Xiao-Yuan Jing, Bing-Kun Bao, and Changsheng Xu. Df-gan: A simple and effective baseline for text-to-image synthesis. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition , pages 16515-16525, 2022.

Minfeng Zhu, Pingbo Pan, Wei Chen, and Yi Yang. Dm-gan: Dynamic memory generative adversarial networks for text-to-image synthesis. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition , pages 5802-5810, 2019.

Yufan Zhou, Ruiyi Zhang, Changyou Chen, Chunyuan Li, Chris Tensmeyer, Tong Yu, Jiuxiang Gu, Jinhui Xu, and Tong Sun. Lafite: Towards language-free training for text-to-image generation. arXiv preprint arXiv:2111.13792 , 2021.

Oran Gafni, Adam Polyak, Oron Ashual, Shelly Sheynin, Devi Parikh, and Yaniv Taigman. Make-a-scene: Scene-based text-to-image generation with human priors. In Computer VisionECCV 2022: 17th European Conference, Tel Aviv, Israel, October 23-27, 2022, Proceedings, Part XV , pages 89-106. Springer, 2022.

Alex Nichol, Prafulla Dhariwal, Aditya Ramesh, Pranav Shyam, Pamela Mishkin, Bob McGrew, Ilya Sutskever, and Mark Chen. Glide: Towards photorealistic image generation and editing with text-guided diffusion models. arXiv preprint arXiv:2112.10741 , 2021.

Minguk Kang, Jun-Yan Zhu, Richard Zhang, Jaesik Park, Eli Shechtman, Sylvain Paris, and Taesung Park. Scaling up gans for text-to-image synthesis. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition , pages 10124-10134, 2023.

Huiwen Chang, Han Zhang, Jarred Barber, AJ Maschinot, Jose Lezama, Lu Jiang, Ming-Hsuan Yang, Kevin Murphy, William T Freeman, Michael Rubinstein, et al. Muse: Text-to-image generation via masked generative transformers. arXiv preprint arXiv:2301.00704 , 2023.

Jonathan Ho and Tim Salimans. Classifier-free diffusion guidance. arXiv preprint arXiv:2207.12598 , 2022.

Jiaming Song, Chenlin Meng, and Stefano Ermon. Denoising diffusion implicit models. arXiv preprint arXiv:2010.02502 , 2020.

Carlos Riquelme, Joan Puigcerver, Basil Mustafa, Maxim Neumann, Rodolphe Jenatton, André Susano Pinto, Daniel Keysers, and Neil Houlsby. Scaling vision with sparse mixture of experts. Advances in Neural Information Processing Systems , 34:8583-8595, 2021.

Sheng Shen, Zhewei Yao, Chunyuan Li, Trevor Darrell, Kurt Keutzer, and Yuxiong He. Scaling vision-language models with sparse mixture of experts. arXiv preprint arXiv:2303.07226 , 2023.

Jiaao He, Jiezhong Qiu, Aohan Zeng, Zhilin Yang, Jidong Zhai, and Jie Tang. Fastmoe: A fast mixture-of-expert training system. arXiv preprint arXiv:2103.13262 , 2021.

Dmitry Lepikhin, HyoukJoong Lee, Yuanzhong Xu, Dehao Chen, Orhan Firat, Yanping Huang, Maxim Krikun, Noam Shazeer, and Zhifeng Chen. Gshard: Scaling giant models with conditional computation and automatic sharding. arXiv preprint arXiv:2006.16668 , 2020.

Antonia Creswell, Tom White, Vincent Dumoulin, Kai Arulkumaran, Biswa Sengupta, and Anil A Bharath. Generative adversarial networks: An overview. IEEE Signal Processing Magazine , 35(1):53-65, 2018.

Ting-Chun Wang, Ming-Yu Liu, Jun-Yan Zhu, Andrew Tao, Jan Kautz, and Bryan Catanzaro. High-resolution image synthesis and semantic manipulation with conditional gans. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition , pages 8798-8807, 2018.

Tero Karras, Samuli Laine, Miika Aittala, Janne Hellsten, Jaakko Lehtinen, and Timo Aila. Analyzing and improving the image quality of stylegan. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition , pages 8110-8119, 2020.

Ian Goodfellow, Jean Pouget-Abadie, Mehdi Mirza, Bing Xu, David Warde-Farley, Sherjil Ozair, Aaron Courville, and Yoshua Bengio. Generative adversarial networks. Communications of the ACM , 63(11):139-144, 2020.

Aditya Ramesh, Mikhail Pavlov, Gabriel Goh, Scott Gray, Chelsea Voss, Alec Radford, Mark Chen, and Ilya Sutskever. Zero-shot text-to-image generation. In International Conference on Machine Learning , pages 8821-8831. PMLR, 2021.

Ming Ding, Zhuoyi Yang, Wenyi Hong, Wendi Zheng, Chang Zhou, Da Yin, Junyang Lin, Xu Zou, Zhou Shao, Hongxia Yang, et al. Cogview: Mastering text-to-image generation via transformers. Advances in Neural Information Processing Systems , 34:19822-19835, 2021.

Zeyue Xue, Jianming Liang, Guanglu Song, Zhuofan Zong, Liang Chen, Yu Liu, and Ping Luo. Large-batch optimization for dense visual predictions. arXiv preprint arXiv:2210.11078 , 2022.

David Eigen, Marc'Aurelio Ranzato, and Ilya Sutskever. Learning factored representations in a deep mixture of experts. arXiv preprint arXiv:1312.4314 , 2013.

Nan Du, Yanping Huang, Andrew M Dai, Simon Tong, Dmitry Lepikhin, Yuanzhong Xu, Maxim Krikun, Yanqi Zhou, Adams Wei Yu, Orhan Firat, et al. Glam: Efficient scaling of language models with mixture-of-experts. In International Conference on Machine Learning , pages 5547-5569. PMLR, 2022.

Margaret Li, Suchin Gururangan, Tim Dettmers, Mike Lewis, Tim Althoff, Noah A Smith, and Luke Zettlemoyer. Branch-train-merge: Embarrassingly parallel training of expert language models. arXiv preprint arXiv:2208.03306 , 2022.

Nataniel Ruiz, Yuanzhen Li, Varun Jampani, Yael Pritch, Michael Rubinstein, and Kfir Aberman. Dreambooth: Fine tuning text-to-image diffusion models for subject-driven generation. arXiv preprint arXiv:2208.12242 , 2022.

Chenlin Meng, Yutong He, Yang Song, Jiaming Song, Jiajun Wu, Jun-Yan Zhu, and Stefano Ermon. Sdedit: Guided image synthesis and editing with stochastic differential equations. In International Conference on Learning Representations , 2021.

Bahjat Kawar, Shiran Zada, Oran Lang, Omer Tov, Huiwen Chang, Tali Dekel, Inbar Mosseri, and Michal Irani. Imagic: Text-based real image editing with diffusion models. arXiv preprint arXiv:2210.09276 , 2022.

Shaozhe Hao, Kai Han, Shihao Zhao, and Kwan-Yee K Wong. Vico: Detail-preserving visual condition for personalized text-to-image generation. arXiv preprint arXiv:2306.00971 , 2023.

Zhiheng Liu, Ruili Feng, Kai Zhu, Yifei Zhang, Kecheng Zheng, Yu Liu, Deli Zhao, Jingren Zhou, and Yang Cao. Cones: Concept neurons in diffusion models for customized generation. arXiv preprint arXiv:2303.05125 , 2023.

Zhiheng Liu, Yifei Zhang, Yujun Shen, Kecheng Zheng, Kai Zhu, Ruili Feng, Yu Liu, Deli Zhao, Jingren Zhou, and Yang Cao. Cones 2: Customizable image synthesis with multiple subjects. arXiv preprint arXiv:2305.19327 , 2023.

Xi Chen, Lianghua Huang, Yu Liu, Yujun Shen, Deli Zhao, and Hengshuang Zhao. Anydoor: Zero-shot object-level image customization. arXiv preprint arXiv:2307.09481 , 2023.

Lingting Zhu, Zeyue Xue, Zhenchao Jin, Xian Liu, Jingzhen He, Ziwei Liu, and Lequan Yu. Make-a-volume: Leveraging latent diffusion models for cross-modality 3d brain mri synthesis. In International Conference on Medical Image Computing and Computer-Assisted Intervention , pages 592-601. Springer, 2023.

Chen-Hsuan Lin, Jun Gao, Luming Tang, Towaki Takikawa, Xiaohui Zeng, Xun Huang, Karsten Kreis, Sanja Fidler, Ming-Yu Liu, and Tsung-Yi Lin. Magic3d: High-resolution text-to-3d content creation. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition , pages 300-309, 2023.

Ben Poole, Ajay Jain, Jonathan T Barron, and Ben Mildenhall. Dreamfusion: Text-to-3d using 2d diffusion. arXiv preprint arXiv:2209.14988 , 2022.

Xiang Wang, Hangjie Yuan, Shiwei Zhang, Dayou Chen, Jiuniu Wang, Yingya Zhang, Yujun Shen, Deli Zhao, and Jingren Zhou. Videocomposer: Compositional video synthesis with motion controllability. arXiv preprint arXiv:2306.02018 , 2023.

Andreas Blattmann, Robin Rombach, Huan Ling, Tim Dockhorn, Seung Wook Kim, Sanja Fidler, and Karsten Kreis. Align your latents: High-resolution video synthesis with latent diffusion models. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition , pages 22563-22575, 2023.

Lingting Zhu, Xian Liu, Xuanyu Liu, Rui Qian, Ziwei Liu, and Lequan Yu. Taming diffusion models for audio-driven co-speech gesture generation. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition , pages 10544-10553, 2023.

Shihao Zhao, Dongdong Chen, Yen-Chun Chen, Jianmin Bao, Shaozhe Hao, Lu Yuan, and Kwan-Yee K Wong. Uni-controlnet: All-in-one control to text-to-image diffusion models. Advances in Neural Information Processing Systems , 2023.

Peer reviews:
{"IS_META_REVIEW": false, "comments": "SUMMARY:\nThis paper presents a new large model RAPHEL (short for distinct image regions align with different text phases in attention learning ) for text-to-image generation. Technically, RAPHEL builds upon the LDM pipeline, with VAEs as image encoder-decoder, and then incorporates the MOE layers for spatial and temporal (in terms of diffusion steps) refinement in the diffusion generation process to improve the text and image fidelity. For the experiments and evaluations, the model is trained with LAION-5B and some confidential internal data, comparisons w/ other large models show better performance using the zero-shot FID on the COCO.\n\nSTRENGTHS:\n- The paper is well written with a clear structure and easy to follow.\n\n- The model achieves sota FID and qualitative results compared to other strong and powerful similar scale models like Stable Diffusion, DeepFloyd and DALLE2.\n\n- The high-level idea to incorporate MoEs to refine the spatial and temporal details in DPMs for text2image synthesis is intuitive and reasonable, with effectiveness proved in ablation studies.\n\nWEAKNESSES:\n- This is another large-scale model work that requires 1000 A100 GPUs with 2-month training on LAION-5B plus internal dataset, while the reviewer acknowledges the popularity of the topic and its superiority in performance, it is another work that can be hardly reproduced by most researchers in the field, especially w/ internal training data inaccessible for the community.\n\n- In terms of the methodology design, while the idea to refine the generation process w/ MoEs is intuitive, the technical novelties are rather limited, and are largely limited to this specific text2img task, as there are several existing works w/ similar ideas [4,5].\n\n- Some technical details remain rather coarse and unclear. See details in my questions.\n\nQUESTIONS:\nI have several questions regarding several technical aspects listed below:\n\n- I am still confused on the working mechanism of time-MoE after reading the paper and appendix. For the time-MoE, it is a Time Gate Network at each diffusion step, located between the cross-attention and space MoE. The output of time-MoE is fed into the space-MoE, then what does this info depict for space-MoE at different diffusion steps? \n\n- How does this work in inference, if the info from time-MoE does convey critical information in terms of steps, then how can the info be used in inference especially with the skipping sampling steps?\n\n- What is the inference time cost using the proposed RAPHEL compared to other popular models?\n\n- How does the internal data impact the final performance? Does the performance change evidently w/o the inaccessible internal dataset?\n\nLIMITATIONS:\nThe paper discusses the limitations and potential negative impact on the risk of generating images with misleading and false information.", "TITLE": "Official Review", "RECOMMENDATION": 5, "REVIEWER_CONFIDENCE": 4, "SOUNDNESS_CORRECTNESS": 3, "DATE": "2023-06-27"}

{"IS_META_REVIEW": false, "comments": "SUMMARY:\nThe paper trains a large-scale latent diffusion model for image synthesis. It trains on a mix of LAION-5B (post-processed + filtered by aesthetic score) and in-house data. It proposes two novel technical contributions: 1) using a \"spatial\" mixture-of-experts (MoE) where an expert is predicted from each text token and processes the attended features; and 2) supervising attention weights via edge maps. Interestingly (and differently from most of the prior works), it also uses multi-scale training. Qualitatively, the generated images look substantially better than the ones from the baselines. It achieves SOTA FID on COCO, which is the main metric/benchmark for text-to-image generators.\n\nSTRENGTHS:\n- The method achieves the very best known results for large-scale text-to-image synthesis (among those models which could be rigorously benchmarked against).\n- There are two novel ideas explored in the work: using spatial MoEs (for attended features) and using edge supervision for attention weights. Both ideas make sense and should be easily extendable to other setups. For spatial MoEs, there are also test-time visualizations provided which helps in understanding their influence.\n- The comparison to other methods is careful and thorough: a lot of non-cherry-picked qualitative results provided; human studies are performed, quantitative metrics are reported.\n\nWEAKNESSES:\nI have two big concerns: 1) spatial MoE and edges supervision are not properly ablated; and 2) the paper does not contain enough technical details to be reproduced. I will elaborate on them below:\n\n1. Improper ablations. After spending ~5 hours on reading the paper, it's still not clear to me where exactly the SotA FID score on COCO is coming from — architecture, data, or optimization, since they are all intermixed in the final model. Fig 6 denotes several ablation experiments, but it's not specified anywhere how were they trained. Does each run in Figure 6 was trained for 2 months on 1,000 GPUs as well? On the same dataset? Such lack of details about ablations makes them impossible to understand and analyze. For Figure 6c, what the FID scores for the line \"Computational complexity\" denote? This is confusing.\n\n2. Lack of details. The current manuscript is something between an academic paper and a technical report. Here are some (of many) missing details:\n  - How exactly does your U-net and VAE look like? Are they equivalent to LDM ones, but with larger channel sizes? Or there are other modifications (apart from spatial/time MoEs)?\n  - How many images are in your in-house dataset, what are their resolutions and how it was collected?\n  - How exactly was multi-scale training implemented? What are the resolution distributions in your final dataset? Do I get it right that different batches on different GPUs have different amount of images in them (since the resolutions are different)? Do you allocate the same amount of GPUs per bucket? Do I get it right that your VAE is multi-scale, while the diffusion model is not? Or vice-versa?\n  - How random noise \\epsilon is sampled for expert routing (L122)?\n  - What is the motivation of using focal loss for edge prediction instead of other loss types? Using focal loss here is quite non-intuitive to me. Did you try ablating it?\n\nThere are also several smaller (but still reasonable) concerns:\n- It's not clear whether spatial experts reflect any text semantics. Judging by Figure 4, the expert assignments are completely random. I would expect to see that visually similar concepts (\"tiger\"/\"cat\"/\"leopard\"; \"dog\"/\"wolf\"/\"fox\"; \"tv\"/\"monitor\") would get assigned to the same expert. Could you please provide any support or refutation to such intuition (e.g., buy checking the clusters)?\n- The writing quality could be improved. There are many variables introduced, and it would ease reading if they would be described in text, i.e., instead of writing \"we set \\lambda to X\", one should write \"we set learning rate \\lambda to X\". Otherwise, a reader needs to jump back and forth trying to recall the variable meaning.\n- There is a quite confusing notation clash:\n  - \\epsilon denotes random noise in diffusion and random noise (L74) in experts routing (L122)\n  - \\alpha denotes variance schedule (L74), focal loss hyperparameter (Figure 6a), routing multiplier (L129)\n- Limitations are not properly discussed (see the \"Limitations\" form below)\n- GigaGAN is a missed reference since they also use MoEs, routed by text tokens.\n- It's not clear why SR-GAN is included into the exposition since there is nothing special about it, and SR-GAN can be combined with any other image generator. Does it work better for RAPHAEL than for other image generators? If so, then it's interesting. But if not — then it's not clear why claiming that RAPHAEL can generate 4096 x 6144 images when combined with it. Following such arguments, what prevents one saying that StyleGAN can generate 100,000 x 100,000 images when combined with tailor-mode bilinear interpolation?\n\nTypos and minor comments:\n- L114: \"mean of all experts\" => \"weighted average of all experts\"?\n\nI look forward to discussing my concerns with the authors and fellow reviewers and improving my rating.\n\nQUESTIONS:\nI raised several concerns in the \"Weaknesses\" section and would be grateful to hearing the author's opinion on them. My main concerns are the lack of details about the method and experiments.\n\nLIMITATIONS:\nThere is a brief limitations discussion on potential negative societal impact. In this regard, I wouldn't demand more discussion from the authors since a potential misuse of powerful image generators is a well-known issue to the community and should be discussed at a \"higher\" level, rather than in this particular work.\n\nHowever, it would be good to see the discussion of other potential limitations of the work, for example, what are the disadvantages of binarizing the attention maps? whether it is possible to ablate the model properly — at least via convergence plots for partial runs (I understand that training a full model for each ablation is infeasible)? what could be a problem with edge maps supervision of the attention maps (i.e., I guess there should be failure cases in edge map detection)? And so on.", "TITLE": "Official Review", "RECOMMENDATION": 7, "REVIEWER_CONFIDENCE": 4, "SOUNDNESS_CORRECTNESS": 2, "DATE": "2023-07-05"}

comments: SUMMARY:
The paper proposed RAPHAEL, a text-to-image diffusion model. The model adopt MoE layers, including space-MoE and time-MoE layers.  In addition, edge-supervised learning is proposed to enhance performance. RAPHAEL establishes a new state-of-the-art with a zero-shot FID-30k score of 6.61 on the COCO dataset, and surpasses its counterparts in human evaluation on the ViLG-300 benchmark.

STRENGTHS:
1. The authors promised to release a programming API for RAPHAEL to the public. 
2. Explore spatial- and time-moe, and perform some abaltion study. 
3. visualize spatial- and time-moe in the appendix. 
4. achieved sota zero-shot FID score on coco.

WEAKNESSES:
As a paper focusing on pretraining, more clarification of experiment details is needed. Including:

a. data. The paper mentioned that "The training dataset consists of LAION-5B and a few internal data.". How many internal data is used? Its category distribution and collecting sources?

b. model structure and hyperparameters. including VAE, and each stage of diffusion model.

QUESTIONS:
1. Is the space-moe performed only on text-image cross attention? How about applying moe to self-attention within image?
2. In abstract the authors mentioned that "RAPHAEL exhibits superior performance in switching images across diverse styles" (L13). Is it benefit from spatial-moe? if so, is there any pattern in moe paths regarding different styles?

LIMITATIONS:
see weakness and questions.
TITLE: Official Review
SOUNDNESS_CORRECTNESS: 3
DATE: 2023-07-06

{"IS_META_REVIEW": false, "comments": "SUMMARY:\nThis paper proposes RAPHAEL, a new text-to-image generative model, based on the latent diffusion model framework. The main methodological contribution is the use of space-mixture-of-experts (space-MoE) layers. These are layers that focus on different concepts from the text prompt in different spatial areas of the synthesized image. Different space-MoEs are automatically chosen for the different text tokens, and they are assigned to the relevant regions in the image, which can be found through the cross-attention maps. A similar time-MoE is also incorporated, although that is less novel. The model is validated on standard benchmarks and achieves state-of-the-art performance. Ablations over all relevant new components and hyperparameters are performed. The paper shows various qualitative results and model samples, which are quite impressive. The authors also demonstrate that RAPHAEL can be easily combined with ControlNet, LoRA fine-tuning, and super resolution GANs to enhance the image resolution.\n\nSTRENGTHS:\nThe main strengths of the paper are:\n- State-of-the-art text-to-image generation performance, including visually impressive results.\n- Extensive ablation studies on all relevant components.\n- The space-MoE idea is well motivated, novel, and boosts performance non-negligibly.\n- I like in particular the gating mechanisms in both the space- and the time-MoE, which, for instance in the time-MoE case, automatically learn to assign different timesteps to various time experts. Previous work manually assigned experts to different diffusion time intervals (for instance, eDiff-I).\n\n**Clarity:** The paper is well written and easy to read and follow. There are no major concerns regarding clarity. However, some details seem to be missing (see below).\n\n**Originality:** In general, the mixture-of-experts idea is not new and has existed in language models and was also used in the text-to-image literature, for instance in the related eDiff-I (only time experts). However, the space-MoE technique specifically in the context of text-to-image generation is new, to the best of my knowledge, and it is well-motivated and seems to meaningfully boost performance. Hence, while the paper's originality is not groundbreaking, the main technical contribution is well-motivated and novel.\n\n**Significance:** Text-to-image generation is a highly relevant and impactful topic, and RAPHAEL achieves state-of-the-art performance in this competitive area. Its mixture-of-experts approach is well-motivated and may find wider adoption. Apart from the quantitative evaluations, its visual results are stunning. Hence, I think the paper is impactful and significant.\n\n**Quality:** The overall quality of the paper is high. The paper is easy to read, appropriately discusses the related literature, provides a background section, runs extensive ablation studies for all new relevant parameters, and supports its claims by appropriate experiments. The qualitative and quantitative results are strong. There are only relatively minor concerns with respect to missing details (see below).\n\nWEAKNESSES:\nThe paper does not have any major weaknesses. However, I have some minor concerns:\n1. Many details are missing:\n    - The paper only mentions on the side (Line 192) that it is using a latent diffusion model framework and does not operate in pixel space. \n       That is fine; however, this requires more details. For instance:\n         - Was the autoencoder regularized? The LDM paper uses either KL-based or VQ-based regularization.\n         - Was the autoencoder trained only with a reconstruction loss? Or also with a (patch-wise) discriminator?\n         - What was the downsampling ratio?\n   - The work should explain the multi-scale training in more detail. How exactly is the model trained at all these different resolutions and aspect ratios at once?\n   - The gating mechanisms incorporate an $argmax$ function. The $argmax$ is usually not differentiable. How did the authors deal with that, to enable regular backpropagation for training? I think it would be helpful to discuss this in a bit more detail.\n   - The paper says that RAPHAEL is trained on LAION \"and a few internal data\". What is this internal data? Even if this data is internal and not released, the authors should describe it and what value it brings on top of LAION. E.g. what is the size of that internal data? Does it have any special characteristics? Only high-quality, for instance? Etc.\n2. A discussion on limitations is missing. This would further strengthen the paper.\n\nIn conclusion, the paper's main weaknesses are all related to missing details and I believe these issues can be addressed easily. I do not see any other major concerns. Considering the paper's strengths discussed above, I am consequently suggesting acceptance of the paper.\n\nQUESTIONS:\nI have only one minor question (just curiosity, not impacting the paper rating):\n\nFigure 4 shows the diffusion paths for different simple concepts. Do more related or similar concepts also have more similar diffusion paths? For instance, would \"strawberry\" and \"raspberry\" share much of their paths, while \"strawberry\" and \"car\" would not?\n\nLIMITATIONS:\nPotential negative societal impacts have been briefly, but sufficiently addressed. Limitations have not been discussed. What are RAPHAEL's limitations? I would like to encourage the authors to add a critical discussion on this.", "TITLE": "Official Review", "RECOMMENDATION": 7, "REVIEWER_CONFIDENCE": 5, "SOUNDNESS_CORRECTNESS": 4, "DATE": "2023-07-07"}