 and training loop are found in the main() function. If you need to adapt the training script, this is where you’ll need to make your changes. The train_text_to_image script starts by loading a scheduler and tokenizer. You can choose to use a different scheduler here if you want:   Copied noise_scheduler = DDPMScheduler.from_pretrained(args.pretrained_model_name_or_path, subfolder="scheduler")
tokenizer = CLIPTokenizer.from_pretrained(
    args