Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
@@ -47,6 +47,8 @@ def train_dreambooth_blora_sdxl(instance_data_dir, b_lora_trained_folder, instan
|
|
47 |
print(f"An error occurred: {e}")
|
48 |
|
49 |
def main(image_path, b_lora_trained_folder, instance_prompt):
|
|
|
|
|
50 |
|
51 |
local_dir = "image_to_train"
|
52 |
# Check if the directory exists and create it if necessary
|
@@ -56,8 +58,8 @@ def main(image_path, b_lora_trained_folder, instance_prompt):
|
|
56 |
shutil.copy(image_path, local_dir)
|
57 |
print(f"source image has been copied in {local_dir} directory")
|
58 |
|
59 |
-
max_train_steps =
|
60 |
-
checkpoint_steps =
|
61 |
|
62 |
train_dreambooth_blora_sdxl(local_dir, b_lora_trained_folder, instance_prompt, max_train_steps, checkpoint_steps)
|
63 |
|
|
|
47 |
print(f"An error occurred: {e}")
|
48 |
|
49 |
def main(image_path, b_lora_trained_folder, instance_prompt):
|
50 |
+
|
51 |
+
instance_prompt = str(instance_prompt)
|
52 |
|
53 |
local_dir = "image_to_train"
|
54 |
# Check if the directory exists and create it if necessary
|
|
|
58 |
shutil.copy(image_path, local_dir)
|
59 |
print(f"source image has been copied in {local_dir} directory")
|
60 |
|
61 |
+
max_train_steps = 10
|
62 |
+
checkpoint_steps = 10
|
63 |
|
64 |
train_dreambooth_blora_sdxl(local_dir, b_lora_trained_folder, instance_prompt, max_train_steps, checkpoint_steps)
|
65 |
|