Madiy commited on
Commit
03c23b0
·
verified ·
1 Parent(s): 0c19fda

Upload app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -0
app.py CHANGED
@@ -97,6 +97,7 @@ def is_greyscale(image):
97
  return (diff_rg < 10 and diff_rb < 10)
98
 
99
  def get_caption(image):
 
100
  inputs = blip_processor(
101
  image.convert("RGB"),
102
  return_tensors="pt"
 
97
  return (diff_rg < 10 and diff_rb < 10)
98
 
99
  def get_caption(image):
100
+ blip_model.to("cuda")
101
  inputs = blip_processor(
102
  image.convert("RGB"),
103
  return_tensors="pt"