Update README.md
Browse files
README.md
CHANGED
@@ -76,7 +76,9 @@ output_ids = model.generate(
|
|
76 |
input_ids,
|
77 |
images=image_tensor,
|
78 |
max_new_tokens=100,
|
79 |
-
use_cache=True
|
|
|
|
|
80 |
|
81 |
print(tokenizer.decode(output_ids[input_ids.shape[1]:], skip_special_tokens=True).strip())
|
82 |
```
|
|
|
76 |
input_ids,
|
77 |
images=image_tensor,
|
78 |
max_new_tokens=100,
|
79 |
+
use_cache=True,
|
80 |
+
repetition_penalty=1.0 # increase this to avoid chattering
|
81 |
+
)[0]
|
82 |
|
83 |
print(tokenizer.decode(output_ids[input_ids.shape[1]:], skip_special_tokens=True).strip())
|
84 |
```
|