  --resolution=256 Many of the basic parameters are described in the DreamBooth training guide, so this guide focuses on the parameters unique to Custom Diffusion: --freeze_model: freezes the key and value parameters in the cross-attention layer; the default is crossattn_kv, but you can set it to crossattn to train all the parameters in the cross-attention layer --concepts_list: to learn multiple concepts, provide a path to a JSON file containing the concepts --modifier_token: a special word used to represent the learned concept --initializer_token:  Prior preservation loss Prior preservation loss is a method that uses a model’s own generated samples to help it learn how to generate more diverse images. Because these generated sample images belong to the same class as the images you provided, they help the model retain what it has learned about the class and how it can use what it already knows about the class to make new compositions. Many of the parameters for prior preservation loss are described in the DreamBooth training guide.  Regularization Custom Diffusion includes training the target images with a small set of real images to prevent overfitting. As you can imagine, this can be easy to do when you’re only training on a few images! Download 200 real images with clip_retrieval. The class_prompt should be the same category as the target images. These images are stored in class_data_dir.   Copied python retrieve.py --class_prompt cat --class_data_dir real_reg/samples_cat --num_class_images 200 To enable regularization, add the following parameters: --with_prior_preservation: whether to use prior preservation loss --prior_loss_weight: controls the influence of the prior preservation loss on the model --real_prior: whether to use a small set of real images to prevent overfitting   Copied accelerate launch train_custom_diffusion.py \