Update README.md
Browse filesthe original example code included two BOS tokens during inference.
modified it so that only one BOS token is included.
README.md
CHANGED
@@ -103,7 +103,7 @@ prompt = processor.tokenizer.apply_chat_template(
|
|
103 |
)
|
104 |
url = "https://www.ilankelman.org/stopsigns/australia.jpg"
|
105 |
image = Image.open(requests.get(url, stream=True).raw)
|
106 |
-
inputs = processor(text=prompt, images=image, return_tensors="pt")
|
107 |
|
108 |
# Generate
|
109 |
generate_ids = model.generate(**inputs, max_length=30)
|
|
|
103 |
)
|
104 |
url = "https://www.ilankelman.org/stopsigns/australia.jpg"
|
105 |
image = Image.open(requests.get(url, stream=True).raw)
|
106 |
+
inputs = processor(text=prompt[5:], images=image, return_tensors="pt")
|
107 |
|
108 |
# Generate
|
109 |
generate_ids = model.generate(**inputs, max_length=30)
|