Spaces:
Runtime error
Runtime error
change branding
Browse files
app.py
CHANGED
@@ -10,9 +10,9 @@ PUBLIC_DEMO = getenv("SPACE_ID") == "waleko/TikZ-Assistant"
|
|
10 |
|
11 |
if PUBLIC_DEMO and not cuda.is_available():
|
12 |
center = ".gradio-container {text-align: center}"
|
13 |
-
with gr.Blocks(css=center, theme=remove_darkness(gr.themes.Soft()), title="
|
14 |
badge = "https://huggingface.co/datasets/huggingface/badges/resolve/main/duplicate-this-space-xl.svg"
|
15 |
-
link = "https://huggingface.co/spaces/
|
16 |
html = f'<a style="display:inline-block" href="{link}"> <img src="{badge}" alt="Duplicate this Space"> </a>'
|
17 |
message = dedent("""\
|
18 |
The size of our models exceeds the resource constraints offered by the
|
|
|
10 |
|
11 |
if PUBLIC_DEMO and not cuda.is_available():
|
12 |
center = ".gradio-container {text-align: center}"
|
13 |
+
with gr.Blocks(css=center, theme=remove_darkness(gr.themes.Soft()), title="TikZ-Assistant") as demo:
|
14 |
badge = "https://huggingface.co/datasets/huggingface/badges/resolve/main/duplicate-this-space-xl.svg"
|
15 |
+
link = "https://huggingface.co/spaces/waleko/TikZ-Assistant?duplicate=true"
|
16 |
html = f'<a style="display:inline-block" href="{link}"> <img src="{badge}" alt="Duplicate this Space"> </a>'
|
17 |
message = dedent("""\
|
18 |
The size of our models exceeds the resource constraints offered by the
|
webui.py
CHANGED
@@ -104,19 +104,19 @@ def check_inputs(image: Image.Image):
|
|
104 |
|
105 |
def get_banner():
|
106 |
return dedent('''\
|
107 |
-
#
|
108 |
|
109 |
<p>
|
110 |
-
<a style="display:inline-block" href="https://github.com/potamides/AutomaTikZ">
|
111 |
-
|
112 |
-
</a>
|
113 |
-
<a style="display:inline-block" href="https://arxiv.org/abs/2310.00367">
|
114 |
-
|
115 |
-
</a>
|
116 |
-
<a style="display:inline-block" href="https://colab.research.google.com/drive/14S22x_8VohMr9pbnlkB4FqtF4n81khIh">
|
117 |
-
|
118 |
-
</a>
|
119 |
-
<a style="display:inline-block" href="https://huggingface.co/spaces/
|
120 |
<img src="https://huggingface.co/datasets/huggingface/badges/resolve/main/open-in-hf-spaces-sm.svg" alt="Open in HF Spaces">
|
121 |
</a>
|
122 |
</p>
|
@@ -138,7 +138,7 @@ def remove_darkness(stylable):
|
|
138 |
|
139 |
def build_ui(model=list(models)[0], lock=False, rasterize=False, force_light=False, lock_reason="locked", timeout=120):
|
140 |
theme = remove_darkness(gr.themes.Soft()) if force_light else gr.themes.Soft()
|
141 |
-
with gr.Blocks(theme=theme, title="
|
142 |
if force_light: remove_darkness(demo)
|
143 |
gr.Markdown(get_banner())
|
144 |
with gr.Row(variant="panel"):
|
|
|
104 |
|
105 |
def get_banner():
|
106 |
return dedent('''\
|
107 |
+
# Ti*k*Z Assistant: Sketches to Vector Graphics with Ti*k*Z
|
108 |
|
109 |
<p>
|
110 |
+
# <a style="display:inline-block" href="https://github.com/potamides/AutomaTikZ">
|
111 |
+
# <img src="https://img.shields.io/badge/View%20on%20GitHub-green?logo=github&labelColor=gray" alt="View on GitHub">
|
112 |
+
# </a>
|
113 |
+
# <a style="display:inline-block" href="https://arxiv.org/abs/2310.00367">
|
114 |
+
# <img src="https://img.shields.io/badge/View%20on%20arXiv-B31B1B?logo=arxiv&labelColor=gray" alt="View on arXiv">
|
115 |
+
# </a>
|
116 |
+
# <a style="display:inline-block" href="https://colab.research.google.com/drive/14S22x_8VohMr9pbnlkB4FqtF4n81khIh">
|
117 |
+
# <img src="https://colab.research.google.com/assets/colab-badge.svg" alt="Open in Colab">
|
118 |
+
# </a>
|
119 |
+
<a style="display:inline-block" href="https://huggingface.co/spaces/waleko/TikZ-Assistant">
|
120 |
<img src="https://huggingface.co/datasets/huggingface/badges/resolve/main/open-in-hf-spaces-sm.svg" alt="Open in HF Spaces">
|
121 |
</a>
|
122 |
</p>
|
|
|
138 |
|
139 |
def build_ui(model=list(models)[0], lock=False, rasterize=False, force_light=False, lock_reason="locked", timeout=120):
|
140 |
theme = remove_darkness(gr.themes.Soft()) if force_light else gr.themes.Soft()
|
141 |
+
with gr.Blocks(theme=theme, title="TikZ Assistant") as demo: # type: ignore
|
142 |
if force_light: remove_darkness(demo)
|
143 |
gr.Markdown(get_banner())
|
144 |
with gr.Row(variant="panel"):
|