Stable-Diffusion-Vertex/Diffusers/train_wo_nfs.py [67:87]:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    if METHOD == "diffuser_dreambooth":
        os.chdir("/root/diffusers/examples/dreambooth")
        # for complex commands, with many args, use string + `shell=True`:
        cmd_str = (f'accelerate launch train_dreambooth.py '
                   f'--pretrained_model_name_or_path="{MODEL_NAME}" '
                   f'--instance_data_dir="{INSTANCE_DIR}" '
                   f'--output_dir="{OUTPUT_DIR}" '
                   f'--instance_prompt="{PROMPT}" '
                   f'--class_data_dir="{OUTPUT_DIR}/class_data" '
                   f'--with_prior_preservation --prior_loss_weight=1.0 '
                   f'--class_prompt="{CLASS_PROMPT}" '
                   f'--resolution={RESOLUTION} '
                   f'--train_batch_size={BATCH_SIZE} '                   
                   f'--gradient_checkpointing '
                   f'--gradient_accumulation_steps={GRADIENT_ACCU_STEPS} '
                   f'--mixed_precision="fp16" '
                   f'--learning_rate={LR} '
                   f'--lr_scheduler="constant" '
                   f'--lr_warmup_steps=0 '
                   f'--num_class_images={NUM_CLASS_IMAGES} '
                   f'--enable_xformers_memory_efficient_attention '
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -



Stable-Diffusion-Vertex/hpo/diffusers/train_diffusers.py [68:88]:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    if METHOD == "diffuser_dreambooth":
        os.chdir("/root/diffusers/examples/dreambooth")
        # for complex commands, with many args, use string + `shell=True`:
        cmd_str = (f'accelerate launch train_dreambooth.py '
                   f'--pretrained_model_name_or_path="{MODEL_NAME}" '
                   f'--instance_data_dir="{INSTANCE_DIR}" '
                   f'--output_dir="{OUTPUT_DIR}" '
                   f'--instance_prompt="{PROMPT}" '
                   f'--class_data_dir="{OUTPUT_DIR}/class_data" '
                   f'--with_prior_preservation --prior_loss_weight=1.0 '
                   f'--class_prompt="{CLASS_PROMPT}" '
                   f'--resolution={RESOLUTION} '
                   f'--train_batch_size={BATCH_SIZE} '                   
                   f'--gradient_checkpointing '
                   f'--gradient_accumulation_steps={GRADIENT_ACCU_STEPS} '
                   f'--mixed_precision="fp16" '
                   f'--learning_rate={LR} '
                   f'--lr_scheduler="constant" '
                   f'--lr_warmup_steps=0 '
                   f'--num_class_images={NUM_CLASS_IMAGES} '
                   f'--enable_xformers_memory_efficient_attention '
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -



