from huggingface_hub import HfApi | |
state_path = '/home/jovyan/simson_training_bolgov/simson_checkpoints_1M/checkpoint_best_model.bin' | |
from huggingface_hub import HfApi | |
api = HfApi() | |
upload_folder = True | |
if not upload_folder: | |
api.upload_file( | |
path_or_fileobj=state_path, | |
path_in_repo="polymer_1M_weights.bin", | |
repo_id="Defetya/simson_base", | |
repo_type="model", | |
) | |
else: | |
api.upload_folder( | |
folder_path="/home/jovyan/simson_training_bolgov", | |
repo_id="Defetya/simson_base", | |
path_in_repo="simson_modeling", | |
repo_type="model", | |
) |