DLR-RM / rl-baselines3-zoo

A training framework for Stable Baselines3 reinforcement learning agents, with hyperparameter optimization and pre-trained agents included.
https://rl-baselines3-zoo.readthedocs.io
MIT License
2k stars 510 forks source link

Replace deprecated use of 'Repository' when pushing to hub with `HfApi` #462

Closed cochaviz closed 2 months ago

cochaviz commented 3 months ago

Remove deprecated use of 'Repository' when pushing to huggingface hub

Description

As mentioned above, use of the Repository class is deprecated: https://hu…ggingface.co/docs/huggingface_hub/concepts/git_vs_http.

Motivation and Context

Closes #463 🥳

Types of changes

Checklist:

Note: we are using a maximum length of 127 characters per line

araffin commented 3 months ago

Hello, thanks for the PR, could you rebase your PR from master instead of the update/hf branch?

cochaviz commented 3 months ago

Hello, thanks for the PR, could you rebase your PR from master instead of the update/hf branch?

I just want to double-check whether what I'm doing now is also okay: I will cherry-pick the commits I made to the branch and add them to master. Should I then create a new PR that originates from master?

Sorry for the hassle, I haven't contributed much to open-source so I'm not incredibly familiar with all the conventions! 🥲 (I was following the huggingface course when I found this issue, and though hf stood for that... Now I realize it probably stands for hotfix 😅 )

araffin commented 3 months ago

I will cherry-pick the commits I made to the branch and add them to master. Should I then create a new PR that originates from master?

Almost. Start from master, create a new branch, cherry-pick the commits and then push (you could even force push to this branch).

EDIT: hf was for huggingface but this branch has been merged a while ago, I will delete it now.

qgallouedec commented 2 months ago

Closing in favour of #465