Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -100,6 +100,48 @@ with gr.Blocks() as demo:
|
|
100 |
btn = gr.Button(value="Ready to Deploy!")
|
101 |
# btn.click(mirror, inputs=[im], outputs=[im_2])
|
102 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
103 |
gr.TabbedInterface(
|
104 |
-
[demoInterface, demo,
|
105 |
).launch(enable_queue=True)
|
|
|
100 |
btn = gr.Button(value="Ready to Deploy!")
|
101 |
# btn.click(mirror, inputs=[im], outputs=[im_2])
|
102 |
|
103 |
+
with gr.Blocks() as demo2:
|
104 |
+
gr.Markdown(
|
105 |
+
"""
|
106 |
+
# Deploy your own Stable Diffusion on Google Cloud Platform
|
107 |
+
""")
|
108 |
+
|
109 |
+
with gr.Row():
|
110 |
+
gr.Markdown(
|
111 |
+
"""
|
112 |
+
GCP project ID
|
113 |
+
""")
|
114 |
+
gr.Markdown(
|
115 |
+
"""
|
116 |
+
GCP region
|
117 |
+
""")
|
118 |
+
|
119 |
+
with gr.Row():
|
120 |
+
gcp_project_id = gr.Textbox()
|
121 |
+
gcp_region = gr.Dropdown(
|
122 |
+
["us-central1", "asia‑east1", "asia-northeast1"],
|
123 |
+
value="us-central1",
|
124 |
+
interactive=True
|
125 |
+
)
|
126 |
+
|
127 |
+
gr.Markdown(
|
128 |
+
"""
|
129 |
+
Configurations on scalability
|
130 |
+
""")
|
131 |
+
with gr.Row():
|
132 |
+
min_nodes = gr.Slider(
|
133 |
+
label="minimum number of nodes",
|
134 |
+
minimum=1,
|
135 |
+
maximum=10)
|
136 |
+
|
137 |
+
max_nodes = gr.Slider(
|
138 |
+
label="maximum number of nodes",
|
139 |
+
minimum=1,
|
140 |
+
maximum=10)
|
141 |
+
|
142 |
+
btn = gr.Button(value="Ready to Deploy!")
|
143 |
+
# btn.click(mirror, inputs=[im], outputs=[im_2])
|
144 |
+
|
145 |
gr.TabbedInterface(
|
146 |
+
[demoInterface, demo, demo2], ["Try-out", "🚀 Deploy on GCP", "🤗 Deploy on HF Endpoint"]
|
147 |
).launch(enable_queue=True)
|