Update app.py
Browse files
app.py
CHANGED
@@ -40,7 +40,7 @@ def generate(
|
|
40 |
sd_model = "minecraft-skins-sdxl"
|
41 |
|
42 |
|
43 |
-
subprocess.run(["python", f"Python_Scripts/{sd_model}.py", f'{prompt}', num_inference_steps, guidance_scale, num_images_per_prompt, model_precision_type, output_image_name, verbose_opt])
|
44 |
|
45 |
return os.path.join(f"output_minecraft_skins/{output_image_name}")
|
46 |
|
@@ -57,7 +57,7 @@ num_images_per_prompt = gr.Number(value=1, minimum=1, precision=0, interactive=T
|
|
57 |
|
58 |
model_precision_type = gr.Dropdown(["fp16", "fp32"], value="fp16", interactive=True, label="Model Precision Type", info="The precision type to load the model, like fp16 which is faster, or fp32 which gives better results")
|
59 |
|
60 |
-
seed = gr.Number(value=42, interactive=True, label="Seed", info="A starting point to initiate the generation process, put 0 for a random one")
|
61 |
|
62 |
output_image_name = gr.Textbox(label="Name of Generated Skin Output", interactive=True, value="output.png")
|
63 |
|
|
|
40 |
sd_model = "minecraft-skins-sdxl"
|
41 |
|
42 |
|
43 |
+
subprocess.run(["python", f"Python_Scripts/{sd_model}.py", f'{prompt}', int(num_inference_steps), float(guidance_scale), int(num_images_per_prompt), str(model_precision_type), int(seed), str(output_image_name), str(verbose_opt)])
|
44 |
|
45 |
return os.path.join(f"output_minecraft_skins/{output_image_name}")
|
46 |
|
|
|
57 |
|
58 |
model_precision_type = gr.Dropdown(["fp16", "fp32"], value="fp16", interactive=True, label="Model Precision Type", info="The precision type to load the model, like fp16 which is faster, or fp32 which gives better results")
|
59 |
|
60 |
+
seed = gr.Number(value=42, interactive=True, precision=0, label="Seed", info="A starting point to initiate the generation process, put 0 for a random one")
|
61 |
|
62 |
output_image_name = gr.Textbox(label="Name of Generated Skin Output", interactive=True, value="output.png")
|
63 |
|