ybelkada commited on
Commit
d2c1632
·
1 Parent(s): 58675f8

Update modeling_chatglm.py

Browse files
Files changed (1) hide show
  1. modeling_chatglm.py +2 -2
modeling_chatglm.py CHANGED
@@ -871,7 +871,7 @@ class ChatGLMModel(ChatGLMPreTrainedModel):
871
  layer_ret = torch.utils.checkpoint.checkpoint(
872
  layer,
873
  hidden_states,
874
- attention_mask,
875
  rotary_pos_emb,
876
  past_key_values[index],
877
  use_cache
@@ -879,7 +879,7 @@ class ChatGLMModel(ChatGLMPreTrainedModel):
879
  else:
880
  layer_ret = layer(
881
  hidden_states,
882
- attention_mask,
883
  rotary_pos_emb,
884
  kv_cache=past_key_values[index],
885
  use_cache=use_cache
 
871
  layer_ret = torch.utils.checkpoint.checkpoint(
872
  layer,
873
  hidden_states,
874
+ full_attention_mask,
875
  rotary_pos_emb,
876
  past_key_values[index],
877
  use_cache
 
879
  else:
880
  layer_ret = layer(
881
  hidden_states,
882
+ full_attention_mask,
883
  rotary_pos_emb,
884
  kv_cache=past_key_values[index],
885
  use_cache=use_cache