Update app.py
Browse files
app.py
CHANGED
@@ -5,8 +5,8 @@ from transformers import BlipProcessor, BlipForConditionalGeneration
|
|
5 |
|
6 |
device = torch.device('cuda' if torch.cuda.is_available() else 'cpu')
|
7 |
|
8 |
-
processor = BlipProcessor.from_pretrained("noamrot/
|
9 |
-
model = BlipForConditionalGeneration.from_pretrained("noamrot/
|
10 |
|
11 |
def inference(raw_image):
|
12 |
text = "a picture of "
|
|
|
5 |
|
6 |
device = torch.device('cuda' if torch.cuda.is_available() else 'cpu')
|
7 |
|
8 |
+
processor = BlipProcessor.from_pretrained("noamrot/FuseCap_Image_Captioning")
|
9 |
+
model = BlipForConditionalGeneration.from_pretrained("noamrot/FuseCap_Image_Captioning").to(device)
|
10 |
|
11 |
def inference(raw_image):
|
12 |
text = "a picture of "
|