| """Basic script which can be edited | |
| for uploading a data dir to huggingface.""" | |
| if __name__ == "__main__": | |
| # NB: Need to have HF_TOKEN environment variable set. | |
| from huggingface_hub import HfApi | |
| api = HfApi() | |
| hf_repo_id = "AngstromAI/csp_train_42k_charges_30Dec2025" | |
| dir_to_upload = "/home/ubuntu/efs/ajc/csp/csp-prod/csp_42ktrain_processed" | |
| # api.create_repo( | |
| # repo_id=hf_repo_id, | |
| # repo_type="dataset", | |
| # exist_ok=True, | |
| # private=True, | |
| # ) | |
| api.upload_large_folder( | |
| folder_path=dir_to_upload, | |
| repo_id=hf_repo_id, | |
| repo_type="dataset", | |
| ) | |