Gong Baitao commited on
Commit
bc85147
1 Parent(s): 02840c5

fix repetition penalty

Browse files
Files changed (1) hide show
  1. modeling_cpmbee.py +2 -2
modeling_cpmbee.py CHANGED
@@ -1840,10 +1840,10 @@ class CpmBeeForCausalLM(CpmBeePreTrainedModel):
1840
  next_token_logits,
1841
  batch_size,
1842
  num_beams,
1843
- model_inputs["input_ids"],
1844
  repetition_penalty,
1845
  pred_start_index,
1846
- model_inputs["input_ids"].size(-1) - 1,
1847
  None,
1848
  )
1849
 
 
1840
  next_token_logits,
1841
  batch_size,
1842
  num_beams,
1843
+ input_ids,
1844
  repetition_penalty,
1845
  pred_start_index,
1846
+ input_ids.size(-1) - 1,
1847
  None,
1848
  )
1849