You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Right now, bool args are converted and passed to the script like --do_the_thing True if you passed do_the_thing=True as a kwarg to run. Sometimes, like in the case of action='store_true', argparse doesn't like this. It also doesn't like --do_the_thing=True sometimes as well. Note I ran into this while running this script from diffusers.
Reproducible Example
You'll need a local instance data dir with some images, and may want to update the instance prompt/validation prompt.
fuego_run.py
frompathlibimportPathimportfuegobase_model='stabilityai/stable-diffusion-2-1-base'instance_data_dir='./rexxliferaj_images'output_dir='./outputs'instance_prompt="a photo of sks rexxliferaj"resolution=512# 768gradient_accumulation=1learning_rate=1e-4n_steps=1000checkpointing_steps=100validation_prompt="a photo of sks rexxliferaj at the Eiffel Tower"validation_epochs=100seed=42fp16=Trueuse_8bit_adam=Trueuse_wandb=Falsespace_url, dataset_url=fuego.run(
script=Path(__file__).parent/"run_lora_finetuning.py",
requirements_file=Path(__file__).parent/"requirements.txt",
delete_space_on_completion=False,
space_hardware="t4-small",
downgrade_hardware_on_completion=False,
# Kwargspretrained_model_name_or_path=base_model,
instance_data_dir=instance_data_dir,
output_dir=output_dir,
instance_prompt=instance_prompt,
resolution=resolution,
train_batch_size=1,
gradient_accumulation_steps=gradient_accumulation,
learning_rate=learning_rate,
lr_scheduler="constant",
lr_warmup_steps=0,
max_train_steps=n_steps,
checkpointing_steps=checkpointing_steps,
validation_prompt=validation_prompt,
validation_epochs=validation_epochs,
seed=seed,
mixed_precision="fp16"iffp16elseNone,
use_8bit_adam=use_8bit_adam,
report_to="wandb"ifuse_wandbelse"tensorboard",
)
print(f"Space: {space_url}")
print(f"Dataset: {dataset_url}")
Right now, bool args are converted and passed to the script like
--do_the_thing True
if you passeddo_the_thing=True
as a kwarg torun
. Sometimes, like in the case ofaction='store_true'
, argparse doesn't like this. It also doesn't like--do_the_thing=True
sometimes as well. Note I ran into this while running this script from diffusers.Reproducible Example
You'll need a local instance data dir with some images, and may want to update the instance prompt/validation prompt.
fuego_run.py
requirements.txt
The text was updated successfully, but these errors were encountered: