Spaces:
Running
on
Zero
Running
on
Zero
Update app.py
Browse files
app.py
CHANGED
@@ -31,17 +31,13 @@ def generate(
|
|
31 |
else:
|
32 |
verbose_opt = ''
|
33 |
|
34 |
-
if stable_diffusion_model == '
|
35 |
-
sd_model = "minecraft-skins"
|
36 |
-
else:
|
37 |
sd_model = "minecraft-skins-sdxl"
|
|
|
|
|
38 |
|
39 |
-
|
40 |
-
|
41 |
-
subprocess.run(["python", f"{sd_model}.py", prompt, num_inference_steps, guidance_scale, num_images_per_prompt, model_precision_type, seed, output_image_name, verbose_opt])
|
42 |
|
43 |
-
os.chdir("..")
|
44 |
-
|
45 |
return os.path.join(f"output_minecraft_skins/{output_image_name}")
|
46 |
|
47 |
|
|
|
31 |
else:
|
32 |
verbose_opt = ''
|
33 |
|
34 |
+
if stable_diffusion_model == 'xl':
|
|
|
|
|
35 |
sd_model = "minecraft-skins-sdxl"
|
36 |
+
else:
|
37 |
+
sd_model = "minecraft-skins"
|
38 |
|
39 |
+
subprocess.run(["python", f"Python_Script/{sd_model}.py", prompt, num_inference_steps, guidance_scale, num_images_per_prompt, model_precision_type, seed, output_image_name, verbose_opt])
|
|
|
|
|
40 |
|
|
|
|
|
41 |
return os.path.join(f"output_minecraft_skins/{output_image_name}")
|
42 |
|
43 |
|