nielsr HF staff commited on
Commit
4bacabb
1 Parent(s): 5d66e7a

Add print statements

Browse files
Files changed (1) hide show
  1. modeling_cogvlm.py +7 -3
modeling_cogvlm.py CHANGED
@@ -602,33 +602,37 @@ class CogVLMModel(CogVLMPreTrainedModel):
602
  from huggingface_hub import HfApi
603
 
604
  api = HfApi()
 
605
  api.upload_file(
606
  path_or_fileobj="hidden_states_step_1.pt",
607
  path_in_repo="hidden_states_step_1.pt",
608
  repo_id="nielsr/test-cogvlm",
609
  repo_type="dataset",
610
  )
611
- api = HfApi()
612
  api.upload_file(
613
  path_or_fileobj="attention_mask_step_1.pt",
614
  path_in_repo="attention_mask_step_1.pt",
615
  repo_id="nielsr/test-cogvlm",
616
  repo_type="dataset",
617
  )
618
- api = HfApi()
619
  api.upload_file(
620
  path_or_fileobj="token_type_ids_step_1.pt",
621
  path_in_repo="token_type_ids_step_1.pt",
622
  repo_id="nielsr/test-cogvlm",
623
  repo_type="dataset",
624
  )
625
- api = HfApi()
626
  api.upload_file(
627
  path_or_fileobj="position_ids_step_1.pt",
628
  path_in_repo="position_ids_step_1.pt",
629
  repo_id="nielsr/test-cogvlm",
630
  repo_type="dataset",
631
  )
 
 
 
 
 
 
632
 
633
  # decoder layers
634
  all_hidden_states = () if output_hidden_states else None
 
602
  from huggingface_hub import HfApi
603
 
604
  api = HfApi()
605
+
606
  api.upload_file(
607
  path_or_fileobj="hidden_states_step_1.pt",
608
  path_in_repo="hidden_states_step_1.pt",
609
  repo_id="nielsr/test-cogvlm",
610
  repo_type="dataset",
611
  )
 
612
  api.upload_file(
613
  path_or_fileobj="attention_mask_step_1.pt",
614
  path_in_repo="attention_mask_step_1.pt",
615
  repo_id="nielsr/test-cogvlm",
616
  repo_type="dataset",
617
  )
 
618
  api.upload_file(
619
  path_or_fileobj="token_type_ids_step_1.pt",
620
  path_in_repo="token_type_ids_step_1.pt",
621
  repo_id="nielsr/test-cogvlm",
622
  repo_type="dataset",
623
  )
 
624
  api.upload_file(
625
  path_or_fileobj="position_ids_step_1.pt",
626
  path_in_repo="position_ids_step_1.pt",
627
  repo_id="nielsr/test-cogvlm",
628
  repo_type="dataset",
629
  )
630
+ api.upload_file(
631
+ path_or_fileobj="past_key_value_step_1.pt",
632
+ path_in_repo="past_key_value_step_1.pt",
633
+ repo_id="nielsr/test-cogvlm",
634
+ repo_type="dataset",
635
+ )
636
 
637
  # decoder layers
638
  all_hidden_states = () if output_hidden_states else None