SlowGuess/NeurIPS_2023_OCR huggingface dataset:
In the main paper, we visualize the created medical samples by GIF-SD. Here, we further visualize the created medical samples by GIF-MAE and discuss them. As shown in Figure 17, RandAugment randomly varies the medical images based on a set of pre-defined transformations. However, due to its randomness, RandAugment may crop the lesion location of medical images and cannot guarantee the created samples to be informative, even leading to noise samples. In contrast, our GIF-MAE can generate content-consistent images with diverse styles, so it can enrich the medical images while maintaining their lesion location unchanged. Therefore, GIF-MAE is able to expand medical image datasets better than RandAugment, leading to higher model performance improvement (cf. Table 1). However, GIF-MAE is unable to generate images with diverse content, which limits its effectiveness. In comparison, SD, after fine-tuning, is able to generate class-maintained samples with more diverse content and styles, and thus achieves better expansion effectiveness (cf. Table 1). To summarize, our methods can expand medical image datasets more effectively than data augmentation.
Figure 17: Examples of the created samples for PathMNIST by RandAugment and GIF.
C Theoretical Analysis
In this appendix, we seek to analyze the benefits of our dataset expansion to model generalization performance. Inspired by [67], we resort to the concept of  $\delta$ -cover [62, 29] to analyze how data diversity influences the generalization error bound. Specifically, "a dataset  $E$  is a  $\delta$ -cover of a dataset  $S$  " means a set of balls with radius  $\delta$  centered at each sample of the dataset  $E$  can cover the entire dataset  $S$ .
Definition C.1. ( $\delta$ -cover [62]) Let  $(\mathcal{M}, \rho)$  be a metric space, let  $S \subseteq \mathcal{M}$  and let  $\mu > 0$ . A set  $E \subseteq \mathcal{M}$  is a  $\delta$ -cover for  $S$ , if for every  $s \in S$ , there is an  $e \in E$  such that  $\rho(s, e) \leq \delta$ . The minimal  $\delta$  regarding  $S$  and  $E$  is denoted by  $\delta_{\min}$ .
In this work, we follow the assumptions of the work [67] and extend its Theorem 1 to the version of the generalization error bound. Let  $A$  be a learning algorithm that outputs a set of parameters, given a training dataset  $\mathcal{D} = \{x_i, y_i\}_{i \in [n]}$  with  $n$  i.i.d. samples drawn from the data distribution  $\mathcal{P}_{\mathcal{Z}}$ . Assume that the hypothesis function is  $\lambda^{\eta}$ -Lipschitz continuous, the loss function  $\ell(x, y)$  is  $\lambda^{\ell}$ -Lipschitz continuous for all  $y$  and bounded by  $L$ , and  $\ell(x_i, y_i; A) = 0$  for  $\forall i \in [n]$ . If the training set  $\mathcal{D}$  is a  $\delta$ -cover of  $\mathcal{P}_{\mathcal{Z}}$ , with probability at least  $1 - \gamma$ , the generalization error bound satisfies:
$$
\left| \mathbb {E} _ {x, y \sim \mathcal {P} _ {\mathcal {Z}}} [ \ell (x, y; A) ] - \frac {1}{n} \sum_ {i \in [ n ]} \ell \left(x _ {i}, y _ {i}; A\right) \right| \leq \delta_ {\min } \left(\lambda^ {\ell} + \lambda^ {\eta} L C\right), \tag {3}
$$
where  $C$  is a constant, and the symbol  $\leq$  indicates "smaller than" up to an additive constant. According to the property of the  $\delta$ -cover, we then define the dataset diversity, called  $\delta$ -diversity, by the inverse of the minimal  $\delta_{min}$ :
Definition C.2. ( $\delta$ -diversity) If a dataset  $E$  is a  $\delta$ -cover of the full dataset  $S$ , then the  $\delta$ -diversity of the set  $E$  regarding the full set  $S$  is  $\delta_{div} = \frac{1}{\delta_{min}}$ .
The  $\delta$ -diversity is easy to understand: given a training set  $\mathcal{D} = \{x_i, y_i\}_{i \in [n]}$  that is a  $\delta$ -cover of the data distribution  $\mathcal{P}_{\mathcal{Z}}$ , if the radius  $\delta_{min}$  is high, the diversity of this dataset must be low. Then, we have:
Theorem C.1. Let  $A$  denote a learning algorithm that outputs a set of parameters given a dataset  $\mathcal{D} = \{x_i, y_i\}_{i \in [n]}$  with  $n$  i.i.d. samples drawn from distribution  $\mathcal{P}_{\mathcal{Z}}$ . Assume the hypothesis function is  $\lambda^\eta$ -Lipschitz continuous, the loss function  $\ell(x, y)$  is  $\lambda^\ell$ -Lipschitz continuous for all  $y$ , and is bounded by  $L$ , with  $\ell(x_i, y_i; A) = 0$  for all  $i \in [n]$ . If  $\mathcal{D}$  constitutes a  $\delta$ -cover of  $\mathcal{P}_{\mathcal{Z}}$ , then with probability at least  $1 - \gamma$ , the generalization error bound satisfies:
$$
\left| \mathbb {E} _ {x, y \sim \mathcal {P} _ {\mathcal {Z}}} [ \ell (x, y; A) ] - \frac {1}{n} \sum_ {i \in [ n ]} \ell \left(x _ {i}, y _ {i}; A\right) \right| \leq \frac {\lambda^ {\ell} + \lambda^ {\eta} L C}{\delta_ {d i v}}, \tag {4}
$$
This theorem shows that the generalization error is bounded by the inverse of  $\delta$ -diversity. That is, the more diverse samples are created by a dataset expansion method, the more improvement of generalization performance would be made in model training. In real small-data applications, the data limitation issue leads the covering radius  $\delta$  to be very large and thus the  $\delta$ -diversity is low, which severely affects the generalization performance of the trained model. More critically, simply increasing the data number (e.g., via data repeating) does not help the generalization since it does not increase  $\delta$ -diversity. Instead of simply increasing the number of samples, our proposed GIF framework adopts two key imagination criteria (i.e., "class-maintained informativeness boosting" and "sample diversity promotion") to guide advanced generative models (e.g., DALL-E2 and Stable Diffusion) to synthesize informative and diversified new samples. Therefore, the expanded dataset would have higher data diversity than random augmentation, which helps to increase  $\delta$ -diversity and thus improves model generalization performance.
D More Method and Implementation Details
D.1 Method details of GIF-DALLE
Thanks to strong image generation abilities, GIF-DALLE applies DALL-E2 [56] as its prior model which follows the pipeline described in Section 4. Its pseudo-code is provided in Algorithm 1, where the image embedding obtained by  $f_{\mathrm{CLIP - I}}$  serves as diffusion guidance to help the diffusion decoder to generate new images. GIF-DALLE conducts guided imagination on the CLIP embedding space.
We further clarify the implementation of the proposed guidance. Specifically, class-maintained informativeness  $S_{inf}$  encourages the consistency between the predicted classification scores  $s$  and  $s'$ , and improves the information entropy for the predicted score of the generated sample  $s'$ :
$$
\mathcal {S} _ {\text {i n f}} = s _ {j} ^ {\prime} + \left(s \log (s) - s ^ {\prime} \log \left(s ^ {\prime}\right)\right), \quad \text {s . t .}, \quad j = \arg \max  (s). \tag {5}
$$
Here,  $j = \arg\max(s)$  is the predicted class label of the original latent feature. Such a criterion helps to keep the class semantics of the optimized feature the same as that of the original one in the CLIP embedding space while encouraging the perturbed feature to have higher information entropy regarding CLIP zero-shot predictions. This enables the generated samples to be more informative for follow-up model training. To promote sample diversity, the diversity  $S_{div}$  is computed by the Kullback-Leibler (KL) divergence among all perturbed latent features of a seed sample as follows:
$$
\mathcal {S} _ {d i v} = \mathcal {D} _ {K L} \left(f ^ {\prime} \| \bar {f}\right) = \sigma \left(f ^ {\prime}\right) \log \left(\sigma \left(f ^ {\prime}\right) / \sigma (\bar {f})\right), \tag {6}
$$
where  $f'$  denotes the current perturbed latent feature and  $\bar{f}$  indicates the mean over the  $K$  perturbed latent features of this seed sample. In implementing diversity promotion  $S_{div}$ , we measure the dissimilarity of two feature vectors by applying the softmax function  $\sigma(\cdot)$  to the latent features, and then measuring the KL divergence between the resulting probability vectors.
Algorithm 1: GIF-DALLE Algorithm
Initialize: Synthetic data set  $\mathcal{D}_{\mathrm{s}} = \emptyset$
Input: Original small dataset  $\mathcal{D}_o$ ; CLIP image encoder  $f_{\mathrm{CLIP - 1}}(\cdot)$ ; DALL-E2 diffusion decoder  $G(\cdot)$ ; CLIP zero-shot classifier  $w(\cdot)$ ; Expansion ratio  $K$ ; Perturbation constraint  $\varepsilon$ .
end
Output: Expanded dataset  $\mathcal{D}_o\cup \mathcal{D}_s$
for  $x\in \mathcal{D}_o$  do   
 $\begin{array}{rl} & {\mathcal{S}_{inf} = 0;}\\ & {f = f_{\mathrm{CLIP - I}}(x);}\\ & {s = w(f);} \end{array}$  // latent feature encoding for seed sample   
for  $i = 1,\ldots ,K$  do Initialize noise  $z_{i}\sim \mathcal{U}(0,1)$  and bias  $b_{i}\sim \mathcal{N}(0,1)$  .  $f_{i}^{\prime} = \mathcal{P}_{f,\epsilon}((1 + z_{i})f + b_{i})$  // noise perturbation (Eq.(1))  $s^\prime = w(f_i^\prime)$  // CLIP zero-shot prediction  $\mathcal{S}_{inf} + = s_j' + (s\log (s) - s'\log (s'))$  , s.t.  $j = \arg \max (s)$  // class-maintained informativeness (Eq.(5))   
end   
 $\bar{f} = mean(\{f_i'\}_{i = 1}^K)$ $\mathcal{S}_{div} = \sum_{i}\{\mathcal{D}_{KL}(\sigma (f_i')||\sigma (\bar{f}))\}_{i = 1}^{K} = \sum_{i}\sigma (f_i')\log (\sigma (f_i') / \sigma (\bar{f}))$  // diversity (Eq.(6))   
 $\{z_i',b_i'\}_{i = 1}^K\gets \arg \max_{z,b}\mathcal{S}_{inf} + \mathcal{S}_{div}$  // guided latent optimization (Eq.(2))   
for  $i = 1,\ldots ,K$  do   
 $f_{i}^{\prime \prime} = \mathcal{P}_{f,\epsilon}((1 + z_{i}^{\prime})f + b_{i}^{\prime})$  // guided noise perturbation (Eq.(1))  $x_{i}^{\prime \prime} = G(f_{i}^{\prime \prime})$  // sample creation   
Add  $x_{i}^{\prime \prime}\rightarrow \mathcal{D}_{s}$
More implementation details. In our experiment, DALL-E2 is pre-trained on Laion-400M [66] and then used for dataset expansion. The resolution of the created images by GIF-DALLE is  $64 \times 64$  for model training without further super-resolution. Only when visualizing the created images, we use super-resolution to up-sample the generated images to  $256 \times 256$  for clarification. Moreover, we set  $\varepsilon = 0.1$  in the guided latent feature optimization. During the diffusion process, we set the guidance scale as 4 and adopt the DDIM sampler [70] for 100-step diffusion. For expanding medical image datasets, it is necessary to fine-tune the prior model for alleviating domain shifts.
D.2 Method details of GIF-SD
GIF-SD applies Stable Diffusion (SD) [59] as its prior model. As its encoder differs from the CLIP image encoder, we slightly modify the pipeline of GIF-SD.
Pipeline. As shown in Algorithm 2, GIF-SD first generates a latent feature for the seed image via its image encoder. Following that, GIF-SD conducts prompt-based diffusion for the latent feature, where the generation rule of prompts will be elaborated in Eq. (7). Please note that, with a suitable prompt design, the prompt-based diffusion helps to create more diversified samples. Afterward, GIF-SD conducts channel-wise noise perturbation. Here, the latent feature of SD has three dimensions: two spatial dimensions and one channel dimension. As discussed in our preliminary (cf. Appendix B.2), the channel-level latent feature encodes more subtle style information, whereas the spatial-level latent features encode more content information. In light of the findings in this preliminary study, we particularly conduct channel-level noise to optimize the latent features in GIF-SD for further diversifying the style of the generated images while maintaining the content semantics of the latent features (after prompt-guided diffusion) unchanged. Based on the randomly perturbed feature, GIF-SD generates an intermediate image via its image decoder and applies CLIP to conduct zero-shot prediction for both the seed and the intermediate image to compute the guidance. With the guidance, GIF-SD optimizes the latent features for creating more style-diverse samples. Here, GIF-SD conducts guided imagination on its own latent space.
Algorithm 2: GIF-SD Algorithm
Input: Original small dataset  $\mathcal{D}_o$ ; SD image encoder  $f(\cdot)$  and image decoder  $G(\cdot)$ ; SD diffusion module  $f_{\mathrm{diff}}(\cdot; [prompt])$ ; CLIP image encoder  $f_{\mathrm{CLIP-I}}(\cdot)$ ; CLIP zero-shot classifier  $w(\cdot)$ ; Expansion ratio  $K$ ; Perturbation constraint  $\varepsilon$ .  
Initialize: Synthetic data set  $\mathcal{D}_{\mathrm{s}} = \emptyset$ ;  
for  $x \in \mathcal{D}_o$  do  
\[
\begin{aligned}
& S_{inf} = 0; \\
& f = f(x); \\
& \text{Randomly sample a [prompt]}; \\
& f = f_{\mathrm{diff}}(f; [prompt]); \\
& s = w(f_{\mathrm{CLIP-I}}(x)); \\
& // CLIP zero-shot prediction for seed sample for  $i = 1, \ldots, K$  do
\[
\begin{aligned}
& \text{Initialize noise } z_i \sim \mathcal{U}(0, 1) \text{ and bias } b_i \sim \mathcal{N}(0, 1); \\
& f_i' = \mathcal{P}_{f,\epsilon}((1 + z_i)f + b_i); \\
& s' = w(f_i'); \\
& \mathcal{S}_{inf} += s_j' + (s\log(s) - s'\log(s')), \text{ s.t. } j = \arg \max(s); \\
& \text{informativeness (Eq.(5))}
\end{aligned}
\end{aligned}
\]  
end  
\[
\bar{f} = \text{mean}(\{f_i'\}_{i=1}^K);
\]
\[
\begin{aligned}
& S_{div} = \sum_i \{\mathcal{D}_{KL}(\sigma(f_i')|\sigma(\bar{f}))\}_{i=1}^K = \sum_i \sigma(f_i')\log(\sigma(f_i') / \sigma(\bar{f})); \\
& \{z_i', b_i'\}_{i=1}^K \leftarrow \arg \max_{z,b} S_{inf} + S_{div};
\end{aligned}
\]  
for  $i = 1, \ldots, K$  do  
\[
\begin{aligned}
& f_i'' = \mathcal{P}_{f,\epsilon}((1 + z_i')f + b_i'); \\
& x_i'' = G(f_i''); \\
& Add x_i'' \rightarrow \mathcal{D}_s.
\end{aligned}
\]  
end
Output: Expanded dataset  $\mathcal{D}_o\cup \mathcal{D}_s$
Rule of prompt design. In our preliminary studies in Appendix B.3, we find that domain labels, class labels, and adjective words are necessary to make the prompts semantically effective. Therefore, we design the prompts using the following rule:
$$
\text {P r o m p t} := [ \text {d o m a i n} ] \text {o f} \mathrm {a} (\mathrm {n}) [ \text {a d j} ] [ \text {c l a s s} ]. \tag {7}
$$
For example, "an oil painting of a colorful fox". To enable the prompts to be diversified, inspired by our preliminary studies, we design a set of domain labels and adjective words for natural image datasets as follows.
- Domain label set: ["an image of", "a real-world photo of", "a cartoon image of", "an oil painting of", "a sketch of"]
- Adjective word set: [" ", "colorful", "stylized", "high-contrast", "low-contrast", "posterized", "solarized", "sheared", "bright", "dark"]
For a seed sample, we randomly sample a domain label and an adjective word from the above sets to construct a prompt. Note that, for medical image datasets, we cancel the domain label set and replace it as the modality of the medical images, e.g., ["Abdominal CT image of"], ["Colon pathological image of"].
Implementation details. In our experiment, we implement GIF-SD based on CLIP VIT-B/32 and Stable Diffusion v1-4, which are pre-trained on large datasets and then used for dataset expansion. Here, we use the official checkpoints of CLIP VIT-B/32 and Stable Diffusion v1-4. The resolution of the created images by GIF-SD is  $512 \times 512$  for all datasets. Moreover, for guided latent feature optimization in GIF-SD, we set  $\varepsilon = 0.8$  for natural image datasets and  $\varepsilon = 0.1$  for medical image datasets. Here, we further adjust  $\varepsilon = 4$  for Caltech101 to increase image diversity for better performance. During the diffusion process, we adopt the DDIM sampler [70] for 50-step latent diffusion. Moreover, the hyper-parameters of strength and scale in SD depend on datasets, while more analysis is provided in Appendix B.4. Note that, for expanding medical image datasets, it is necessary to fine-tune the prior model for alleviating domain shifts.
D.3 Method details of GIF-MAE
Thanks to strong image reconstruction abilities, our GIF-MAE applies the MAE-trained model [24] as its prior model. As its encoder is different from the CLIP image encoder, we slightly modify the pipeline of GIF-MAE.
Pipeline. As shown in Algorithm 3, GIF-MAE first generates a latent feature for the seed image via its encoder, and conducts channel-wise noise perturbation. Here, the latent feature of MAE has two dimensions: spatial dimension and channel dimension. As discussed in our preliminary (cf. Appendix B.2), the channel-level latent feature encodes more subtle style information, whereas the token-level latent feature encodes more content information. Motivated by the findings in this preliminary study, we particularly conduct channel-level noise to optimize the latent features in our GIF-MAE method for maintaining the content semantics of images unchanged. Based on the perturbed feature, GIF-MAE generates an intermediate image via its decoder and applies CLIP to conduct zero-shot prediction for both the seed and the intermediate image to compute the guidance. With the guidance, GIF-MAE optimizes the latent features for creating content-consistent samples of diverse styles. Here, GIF-MAE conducts guided imagination on its own latent space.
Algorithm 3: GIF-MAE Algorithm
Input: Original small dataset  $\mathcal{D}_o$  ; MAE image encoder  $f(\cdot)$  and image decoder  $G(\cdot)$  ; CLIP image encoder  $f_{\mathrm{CLIP - I}}(\cdot)$  ; CLIP zero-shot classifier  $w(\cdot)$  ; Expansion ratio  $K$  ; Perturbation constraint  $\varepsilon$    
Initialize: Synthetic data set  $\mathcal{D}_s = \emptyset$    
for  $x\in \mathcal{D}_o$  do   
 $\begin{array}{l}\mathcal{S}_{inf} = 0;\\ f = f(x);\\ s = w(f_{\mathrm{CLIP - I}}(x));\\ \end{array}$  // latent feature encoding for seed sample // CLIP zero-shot prediction for seed sample   
for  $i = 1,\dots,K$  do Initialize noise  $z_{i}\sim \mathcal{U}(0,1)$  and bias  $b_{i}\sim \mathcal{N}(0,1)$  .  $\begin{array}{r}f_i' = \mathcal{P}_{f,\epsilon}((1 + z_i)f + b_i);\qquad \text{// channel - level noise perturbation (Eq.(1))}\\ x_i' = G(f_i');\qquad \text{// intermediate image generation}\\ s' = w(f_{\mathrm{CLIP - I}}(x_i'));\\ \end{array}$ $\mathcal{S}_{inf} + = s_j^{\prime} + (s\log (s) - s^{\prime}\log (s^{\prime}))$  , s.t.  $j = \arg \max (s)$  // class-maintained informativeness (Eq.(5))   
end   
 $\bar{f} = mean(\{f_i'\}_{i = 1}^K)$ $\mathcal{S}_{div} = \sum_{i}\{\mathcal{D}_{KL}(\sigma (f_i')||\sigma (\bar{f}))\}_{i = 1}^{K} = \sum_{i}\sigma (f_i')\log (\sigma (f_i') / \sigma (\bar{f}))$  // diversity (Eq.(6))   
 $\{z_i',b_i'\}_{i = 1}^K\gets \arg \max_{z,b}\mathcal{S}_{inf} + \mathcal{S}_{div};$  // guided latent optimization (Eq.(2))   
for  $i = 1,\ldots ,K$  do   
 $f_{i}^{\prime \prime} = \mathcal{P}_{f,\epsilon}((1 + z_i')f + b_i')$  // guided channel-wise noise perturbation (Eq.(1))   
 $x_{i}^{\prime \prime} = G(f_{i}^{\prime \prime})$  // sample creation   
end   
Output: Expanded dataset  $\mathcal{D}_o\cup \mathcal{D}_s$
Implementation details. In our experiment, we implement GIF-MAE based on CLIP VIT-B/32 and MAE VIT-L/16, which are pre-trained on large datasets and then fixed for dataset expansion. Here, we use the official checkpoints of CLIP VIT-B/32 and MAE VIT-L/16. The resolution of the created images by GIF-MAE is  $224 \times 224$  for all datasets. Moreover, we set  $\varepsilon = 5$  for guided latent feature optimization in GIF-MAE.
D.4 Implementation details of model training
We implement GIF in PyTorch based on CLIP VIT-B/32, DALL-E2, MAE VIT-L/16, and Stable Diffusion (SD) V1-4, which are pre-trained on large datasets and then fixed for dataset expansion. We use the official checkpoints of CLIP VIT-B/32, MAE VIT-L/16, and SD v1-4, and use the DALL-E2 pre-trained on Laion-400M [66]. On medical datasets, since DALL-E2 and SD were initially trained on natural images and suffer from domain shifts to medical domains (please see the discussion in Appendix B.6), we fine-tune them on the target dataset before dataset expansion.
To fairly evaluate the expansion effectiveness of different methods, we use them to expand the original small datasets by the same ratios, followed by training models from scratch on the expanded dataset with the same number of epochs and the same data pre-processing. In this way, the models are trained with the same number of update steps, so that all expansion methods are fairly compared. The expansion ratio depends on the actual demand of real applications. In the experiment of Table 1, CIFAR100-Subset is expanded by  $5 \times$ , Pets is expanded by  $30 \times$ , and all other datasets are expanded by  $20 \times$ . Moreover, all medical image datasets are expanded by  $5 \times$ . In addition, all augmentation baselines expand datasets with the same expansion ratio for fair comparisons.
After expansion, we train ResNet-50 [25] from scratch for 100 epochs based on the expanded datasets. During model training, we process images via random resize to  $224 \times 224$  through bicubic sampling, random rotation, and random flips. If not specified, we use the SGD optimizer with a momentum of 0.9. We set the initial learning rate (LR) to 0.01 with cosine LR decay, except the initial LR of CIFAR100-Subset and OrganSMNIST is 0.1. The model performance is averaged over three runs in terms of micro accuracy on natural image datasets and macro accuracy on medical image datasets.
D.5 Discussions on limitations and broader impact
Limitations. We next discuss the limitations of our method.
1. Performance of generated samples. The expanded samples are still less informative than real samples. For example, a ResNet-50 trained from scratch on our 5x-expanded CIFAR100-Subset achieves an accuracy of  $61.1\%$ , which lags behind the  $71.0\%$  accuracy on the original CIFAR100. This gap signals the potential for advancing algorithmic dataset expansion. Please see Appendix F.6 for detailed discussions. We expect that this pioneering work can inspire more studies to explore dataset expansion so that it can even outperform a human-collected dataset of the same size.
2. Quality of generated samples. Some samples might have noise, as exemplified in Figure 5b. Despite seeming less realistic, those samples are created following our guidance (e.g., class-maintained informativeness boosting). This ensures the class consistency of these samples, mitigating potential negative effects on model training. Nonetheless, refining the expansion method to address these noisy cases can further enhance the effectiveness of dataset expansion.
3. Scope of work. Our current focus is predominantly on image classification. Exploring the adaptability of our method to other tasks, such as object detection and semantic segmentation, is an intriguing next step.
Broader impact. We further summarize our broader impact. Our method can offer a notable reduction in the time and cost associated with manual data collection and annotation for dataset expansion, as discussed in Section 5.1. This can revolutionize how small datasets are expanded, making deep learning more accessible to scenarios with limited data availability (cf. Table 1).
E Dataset Statistics
The statistics of natural image datasets. We evaluate our method on six small-scale natural image datasets, including Caltech-101 [18], CIFAR100-Subset [41], Standard Cars [40], Oxford 102 Flowers [49], Oxford-IIIT Pets [50] and DTD [10]. Here, CIFAR100-Subset is an artificial dataset for simulating small-scale datasets by randomly sampling 100 instances per class from the original CIFAR100 dataset, and the total sample number is 10,000. These datasets cover a wide range of classification tasks, including coarse-grained object classification (i.e., CIFAR100-Subset and Caltech-101), fine-grained object classification (i.e., Cars, Flowers and Pets) and texture classification (i.e., DTD). The data statistics of these natural image datasets are given in Table 10. Note that the higher number of classes or the lower number of average samples per class a dataset has, the more challenging the dataset is.