Update app.py
Browse files
app.py
CHANGED
@@ -60,7 +60,7 @@ def generate_caption_and_image(image):
|
|
60 |
|
61 |
pixel_values = feature_extractor(images=[img], return_tensors="pt").pixel_values.to(device)
|
62 |
output_ids = model.generate(pixel_values, **gen_kwargs)
|
63 |
-
|
64 |
|
65 |
|
66 |
|
|
|
60 |
|
61 |
pixel_values = feature_extractor(images=[img], return_tensors="pt").pixel_values.to(device)
|
62 |
output_ids = model.generate(pixel_values, **gen_kwargs)
|
63 |
+
caption1 = tokenizer.decode(output_ids[0], skip_special_tokens=True).strip()
|
64 |
|
65 |
|
66 |
|