retouch / push.py
DuySota's picture
Upload folder using huggingface_hub
defb4d0 verified
raw
history blame contribute delete
475 Bytes
from huggingface_hub import Repository, HfApi
# # Initialize repository
# repo = Repository(
# local_dir="/home/duyht/ShotXRetouch",
# clone_from="DuySota/retouch"
# )
# # Add, commit, and push files
# repo.git_add(auto_lfs_track=True)
# repo.git_commit("Initial commit")
# repo.git_push()
# Alternatively, you can use the HfApi for more granular control
api = HfApi()
api.upload_folder(
repo_id="DuySota/retouch",
folder_path="/home/duyht/ShotXRetouch"
)