zhiqiulin commited on
Commit
6376e7e
·
verified ·
1 Parent(s): 828b75a

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +4 -3
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
- result = model_pipe(images=[image], texts=[text])
29
- return result
 
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