Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
|
@@ -5,8 +5,8 @@ from transformers import BlipForConditionalGeneration, AutoProcessor
|
|
| 5 |
|
| 6 |
logging.set_verbosity_error()
|
| 7 |
|
| 8 |
-
model = BlipForConditionalGeneration.from_pretrained("
|
| 9 |
-
processor = AutoProcessor.from_pretrained("
|
| 10 |
|
| 11 |
def caption_image(image):
|
| 12 |
inputs = processor(image, return_tensors="pt")
|
|
|
|
| 5 |
|
| 6 |
logging.set_verbosity_error()
|
| 7 |
|
| 8 |
+
model = BlipForConditionalGeneration.from_pretrained("Salesforce/blip-image-captioning-base")
|
| 9 |
+
processor = AutoProcessor.from_pretrained("Salesforce/blip-image-captioning-base")
|
| 10 |
|
| 11 |
def caption_image(image):
|
| 12 |
inputs = processor(image, return_tensors="pt")
|