nielsr HF staff commited on
Commit
526fd72
1 Parent(s): afc6b0d

Add print statements

Browse files
Files changed (1) hide show
  1. modeling_cogvlm.py +2 -1
modeling_cogvlm.py CHANGED
@@ -522,7 +522,8 @@ class CogVLMModel(CogVLMPreTrainedModel):
522
  if output_hidden_states:
523
  all_hidden_states += (hidden_states,)
524
 
525
- print(f"Hidden states before layer {idx}", hidden_states[0,:3,:3])
 
526
 
527
  past_key_value = past_key_values[idx] if past_key_values is not None else None
528
  layer_outputs = decoder_layer(
 
522
  if output_hidden_states:
523
  all_hidden_states += (hidden_states,)
524
 
525
+ if idx in [0, 31]:
526
+ print(f"Hidden states before layer {idx}", hidden_states[0,:3,:3])
527
 
528
  past_key_value = past_key_values[idx] if past_key_values is not None else None
529
  layer_outputs = decoder_layer(