Spaces:
Running
on
Zero
Running
on
Zero
mikonvergence
commited on
Commit
·
ee37e55
1
Parent(s):
65328d9
zero gpu update
Browse files- app.py +2 -4
- src/utils.py +5 -1
app.py
CHANGED
|
@@ -60,11 +60,9 @@ with gr.Blocks(theme=theme) as demo:
|
|
| 60 |
)
|
| 61 |
|
| 62 |
generate_button.click(
|
| 63 |
-
|
| 64 |
inputs=[s2l1c_input, s2l2a_input, s1rtc_input, dem_input, num_inference_steps_slider, guidance_scale_slider, seed_number, seed_checkbox],
|
| 65 |
outputs=[s2l1c_output, s2l2a_output, s1rtc_output, dem_output],
|
| 66 |
)
|
| 67 |
|
| 68 |
-
demo.launch()
|
| 69 |
-
|
| 70 |
-
demo.launch(share=True)
|
|
|
|
| 60 |
)
|
| 61 |
|
| 62 |
generate_button.click(
|
| 63 |
+
fn=generate_output,
|
| 64 |
inputs=[s2l1c_input, s2l2a_input, s1rtc_input, dem_input, num_inference_steps_slider, guidance_scale_slider, seed_number, seed_checkbox],
|
| 65 |
outputs=[s2l1c_output, s2l2a_output, s1rtc_output, dem_output],
|
| 66 |
)
|
| 67 |
|
| 68 |
+
demo.queue().launch()
|
|
|
|
|
|
src/utils.py
CHANGED
|
@@ -167,4 +167,8 @@ def sample_shuffle(interface=True):
|
|
| 167 |
out = []
|
| 168 |
for el in images:
|
| 169 |
out += [el, True]
|
| 170 |
-
return out
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 167 |
out = []
|
| 168 |
for el in images:
|
| 169 |
out += [el, True]
|
| 170 |
+
return out
|
| 171 |
+
|
| 172 |
+
@spaces.GPU
|
| 173 |
+
def generate_output():
|
| 174 |
+
pass
|