Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
|
@@ -238,7 +238,11 @@ def run_main_app(semantic_concept, word, letter, font_name, num_steps, example=0
|
|
| 238 |
|
| 239 |
image = os.path.join(cfg.experiment_dir,f"{cfg.font}_{cfg.word}_{cfg.optimized_letter}.svg")
|
| 240 |
# yield gr.update(value=filename_init,visible=True),gr.update(visible=False),gr.update(value=image,visible=True)
|
| 241 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
| 242 |
|
| 243 |
|
| 244 |
with gr.Blocks() as demo:
|
|
|
|
| 238 |
|
| 239 |
image = os.path.join(cfg.experiment_dir,f"{cfg.font}_{cfg.word}_{cfg.optimized_letter}.svg")
|
| 240 |
# yield gr.update(value=filename_init,visible=True),gr.update(visible=False),gr.update(value=image,visible=True)
|
| 241 |
+
|
| 242 |
+
with open(filename_init, "r") as f:
|
| 243 |
+
svg_content = f.read()
|
| 244 |
+
|
| 245 |
+
yield gr.update(value=f"<div>{svg_content}</div>",visible=True),gr.update(visible=False),gr.update(value=image,visible=True)
|
| 246 |
|
| 247 |
|
| 248 |
with gr.Blocks() as demo:
|