BAAI
/

BoyaWu10 commited on
Commit
45417f7
1 Parent(s): dfa75da

Update README.md

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