BAAI
/

BoyaWu10 commited on
Commit
540de87
1 Parent(s): 799a126

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +3 -1
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)[0]
 
 
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
  ```