Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
@@ -102,7 +102,7 @@ def get_depth_map(image, depth_estimator):
|
|
102 |
depth_map = depth_map.permute(2, 0, 1) # Меняем порядок осей (C, H, W)
|
103 |
return depth_map
|
104 |
|
105 |
-
pipe_default = get_lora_sd_pipeline(lora_dir='lora_man_animestyle', base_model_name_or_path=model_default, dtype=torch_dtype).to(device)
|
106 |
|
107 |
# ----------------------------------------------------------------------------------------------------------------------------------------------------
|
108 |
def infer(
|
@@ -830,19 +830,21 @@ with gr.Blocks(css=css) as demo:
|
|
830 |
|
831 |
# DDIMScheduler ------------------------------------------------------------------------------------------------
|
832 |
# Checkbox для DDIMScheduler
|
833 |
-
|
834 |
-
|
835 |
-
|
836 |
-
|
837 |
-
|
|
|
838 |
|
839 |
# Удаление фона------------------------------------------------------------------------------------------------
|
840 |
# Checkbox для удаления фона
|
841 |
-
|
842 |
-
|
843 |
-
|
844 |
-
|
845 |
-
|
|
|
846 |
# -------------------------------------------------------------------------------------------------------------
|
847 |
|
848 |
gr.Examples(examples=examples, inputs=[prompt], label="Examples for prompt:")
|
|
|
102 |
depth_map = depth_map.permute(2, 0, 1) # Меняем порядок осей (C, H, W)
|
103 |
return depth_map
|
104 |
|
105 |
+
#pipe_default = get_lora_sd_pipeline(lora_dir='lora_man_animestyle', base_model_name_or_path=model_default, dtype=torch_dtype).to(device)
|
106 |
|
107 |
# ----------------------------------------------------------------------------------------------------------------------------------------------------
|
108 |
def infer(
|
|
|
830 |
|
831 |
# DDIMScheduler ------------------------------------------------------------------------------------------------
|
832 |
# Checkbox для DDIMScheduler
|
833 |
+
with gr.Blocks():
|
834 |
+
use_DDIMScheduler = gr.Checkbox(
|
835 |
+
label="Use DDIMScheduler",
|
836 |
+
value=False,
|
837 |
+
interactive=True
|
838 |
+
)
|
839 |
|
840 |
# Удаление фона------------------------------------------------------------------------------------------------
|
841 |
# Checkbox для удаления фона
|
842 |
+
with gr.Blocks():
|
843 |
+
remove_bg = gr.Checkbox(
|
844 |
+
label="Remove Background",
|
845 |
+
value=False,
|
846 |
+
interactive=True
|
847 |
+
)
|
848 |
# -------------------------------------------------------------------------------------------------------------
|
849 |
|
850 |
gr.Examples(examples=examples, inputs=[prompt], label="Examples for prompt:")
|