Spaces:
Running
on
Zero
Running
on
Zero
Update app.py
Browse files
app.py
CHANGED
@@ -24,9 +24,10 @@ def generate(model_name, image, text):
|
|
24 |
# model_pipe.to("cuda")
|
25 |
print("Generating!")
|
26 |
# with torch.autocast(device_type='cuda'):
|
27 |
-
with torch.autocast(device_type='cuda', dtype=torch.float):
|
28 |
-
|
29 |
-
|
|
|
30 |
|
31 |
iface = gr.Interface(
|
32 |
fn=generate, # function to call
|
|
|
24 |
# model_pipe.to("cuda")
|
25 |
print("Generating!")
|
26 |
# with torch.autocast(device_type='cuda'):
|
27 |
+
# with torch.autocast(device_type='cuda', dtype=torch.float):
|
28 |
+
# result = model_pipe(images=[image], texts=[text])
|
29 |
+
# return result
|
30 |
+
return 10
|
31 |
|
32 |
iface = gr.Interface(
|
33 |
fn=generate, # function to call
|