I had the same error. Seems as if the step to create the repository is missing from the tutorial.
# Lastly, to push our model to the Hub, we will need to create a Repository object in a
# working folder. First log in to Hugging Face, if you’re not logged in already. We’ll
# determine the repository name from the model ID we want to give our model (feel free
# to replace the repo_name with your own choice; it just needs to contain your username,
# which is what the function get_full_repo_name() does):
from huggingface_hub import Repository, get_full_repo_name, create_repo
model_name = "bert-finetuned-ner-accelerate"
repo_name = get_full_repo_name(model_name)
# Adding this line resolved the issue for me
# Also be sure to import "create_repo"
# Only need to run once, comment after first run
repo_url = create_repo(repo_id=repo_name)
# Clone
output_dir = "bert-finetuned-ner-accelerate"
repo = Repository(output_dir, clone_from=repo_name)