Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -12,8 +12,8 @@ examples =[
|
|
12 |
['https://i.imgur.com/dFeN6bs.jpg', 'A black dog stands on a <mask>, green fields behind him.'],
|
13 |
]
|
14 |
device = "cuda" if torch.cuda.is_available() else "cpu"
|
15 |
-
|
16 |
-
model, img_transform, tokenizer, post_processor, plot_results = torch.hub.load('.', 'flickr_base_model', source='local')
|
17 |
model = model.to(device)
|
18 |
|
19 |
def plot_inference(img, caption):
|
|
|
12 |
['https://i.imgur.com/dFeN6bs.jpg', 'A black dog stands on a <mask>, green fields behind him.'],
|
13 |
]
|
14 |
device = "cuda" if torch.cuda.is_available() else "cpu"
|
15 |
+
model, img_transform, tokenizer, post_processor, plot_results = torch.hub.load('Jiayi-Pan/RefCloze_Pub', 'flickr_base_model')
|
16 |
+
# model, img_transform, tokenizer, post_processor, plot_results = torch.hub.load('.', 'flickr_base_model', source='local')
|
17 |
model = model.to(device)
|
18 |
|
19 |
def plot_inference(img, caption):
|