Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -736,41 +736,29 @@ def main_ui():
|
|
| 736 |
return None
|
| 737 |
return update_live_preview(image, bbox_x1, bbox_y1, bbox_x2, bbox_y2, face_preserve)
|
| 738 |
|
| 739 |
-
|
| 740 |
-
|
| 741 |
-
|
| 742 |
-
|
| 743 |
-
|
| 744 |
-
outputs=preview_output,
|
| 745 |
-
# LÖSUNG 2: Debouncing für bessere Performance
|
| 746 |
-
#queue=True, # In Warteschlange stellen
|
| 747 |
-
preprocess=False # Keine Vorverarbeitung
|
| 748 |
)
|
| 749 |
-
|
| 750 |
-
|
| 751 |
-
|
| 752 |
-
|
| 753 |
-
outputs=preview_output,
|
| 754 |
-
#queue=True,
|
| 755 |
-
preprocess=False
|
| 756 |
)
|
| 757 |
-
|
| 758 |
-
|
| 759 |
-
|
| 760 |
-
|
| 761 |
-
outputs=preview_output,
|
| 762 |
-
#queue=True,
|
| 763 |
-
preprocess=False
|
| 764 |
)
|
| 765 |
-
|
| 766 |
-
|
| 767 |
-
|
| 768 |
-
|
| 769 |
-
outputs=preview_output,
|
| 770 |
-
#queue=True,
|
| 771 |
-
preprocess=False
|
| 772 |
)
|
| 773 |
|
|
|
|
| 774 |
# Live-Update bei Modus-Änderung
|
| 775 |
face_preserve.change(
|
| 776 |
fn=update_live_preview,
|
|
|
|
| 736 |
return None
|
| 737 |
return update_live_preview(image, bbox_x1, bbox_y1, bbox_x2, bbox_y2, face_preserve)
|
| 738 |
|
| 739 |
+
# Ändere die Schieberegler-Definitionen:
|
| 740 |
+
bbox_x1 = gr.Slider(
|
| 741 |
+
label="Links (x1)",
|
| 742 |
+
minimum=0, maximum=512, value=0, step=1, # value=0 statt 100
|
| 743 |
+
info="Linke Kante des Bildelementbereichs"
|
|
|
|
|
|
|
|
|
|
|
|
|
| 744 |
)
|
| 745 |
+
bbox_y1 = gr.Slider(
|
| 746 |
+
label="Oben (y1)",
|
| 747 |
+
minimum=0, maximum=512, value=0, step=1, # value=0 statt 100
|
| 748 |
+
info="Obere Kante des Bildelementbereichs"
|
|
|
|
|
|
|
|
|
|
| 749 |
)
|
| 750 |
+
bbox_x2 = gr.Slider(
|
| 751 |
+
label="Rechts (x2)",
|
| 752 |
+
minimum=0, maximum=512, value=0, step=1, # value=0 statt 300
|
| 753 |
+
info="Rechte Kante des Bildelementbereichs"
|
|
|
|
|
|
|
|
|
|
| 754 |
)
|
| 755 |
+
bbox_y2 = gr.Slider(
|
| 756 |
+
label="Unten (y2)",
|
| 757 |
+
minimum=0, maximum=512, value=0, step=1, # value=0 statt 300
|
| 758 |
+
info="Untere Kante des Bildelementbereichs"
|
|
|
|
|
|
|
|
|
|
| 759 |
)
|
| 760 |
|
| 761 |
+
|
| 762 |
# Live-Update bei Modus-Änderung
|
| 763 |
face_preserve.change(
|
| 764 |
fn=update_live_preview,
|