Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -1015,7 +1015,9 @@ with gr.Blocks(fill_width=True, fill_height=False) as app:
|
|
| 1015 |
val = re.sub(r'<[^>]+>', '', val) # Delete html and loras
|
| 1016 |
print("Removed LoRA written in the prompt")
|
| 1017 |
if key in ["prompt", "neg_prompt"]:
|
| 1018 |
-
val = re.sub(
|
|
|
|
|
|
|
| 1019 |
if key in ["Steps", "width", "height", "Seed", "Hires steps", "Image resolution"]:
|
| 1020 |
val = int(val)
|
| 1021 |
if key == "FreeU":
|
|
|
|
| 1015 |
val = re.sub(r'<[^>]+>', '', val) # Delete html and loras
|
| 1016 |
print("Removed LoRA written in the prompt")
|
| 1017 |
if key in ["prompt", "neg_prompt"]:
|
| 1018 |
+
val = re.sub(
|
| 1019 |
+
r"[^\S\r\n]+", " ", re.sub(r"[ \t]*,[ \t,]*", ", ", val)
|
| 1020 |
+
).strip()
|
| 1021 |
if key in ["Steps", "width", "height", "Seed", "Hires steps", "Image resolution"]:
|
| 1022 |
val = int(val)
|
| 1023 |
if key == "FreeU":
|