Git lfs error on training diffusers

Getting this error on this notebook notebooks/training_example.ipynb at main 路 huggingface/notebooks 路 GitHub

Launching training on one GPU.
Cloning https://huggingface.co/mwitiderrick/catsdiffusion into local empty directory.
---------------------------------------------------------------------------
CalledProcessError                        Traceback (most recent call last)
/opt/conda/lib/python3.7/site-packages/huggingface_hub/repository.py in clone_from(self, repo_url, token)
    691                         self.local_dir,
--> 692                         env=env,
    693                     )

/opt/conda/lib/python3.7/site-packages/huggingface_hub/utils/_subprocess.py in run_subprocess(command, folder, check, **kwargs)
     68         cwd=folder or os.getcwd(),
---> 69         **kwargs,
     70     )

/opt/conda/lib/python3.7/subprocess.py in run(input, capture_output, timeout, check, *popenargs, **kwargs)
    511             raise CalledProcessError(retcode, process.args,
--> 512                                      output=stdout, stderr=stderr)
    513     return CompletedProcess(process.args, retcode, stdout, stderr)

CalledProcessError: Command '['git', 'lfs', 'clone', 'https://user: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@huggingface.co/mwitiderrick/catsdiffusion', '.']' returned non-zero exit status 2.

During handling of the above exception, another exception occurred:

OSError                                   Traceback (most recent call last)
/tmp/ipykernel_23/2823307728.py in <module>
      2 args = (config, model, noise_scheduler, optimizer, train_dataloader, lr_scheduler)
      3 
----> 4 notebook_launcher(train_loop, args, num_processes=1)

/opt/conda/lib/python3.7/site-packages/accelerate/launchers.py in notebook_launcher(function, args, num_processes, use_fp16, mixed_precision, use_port)
     81             else:
     82                 print("Launching training on one CPU.")
---> 83             function(*args)
     84 
     85     else:

/tmp/ipykernel_23/3930790771.py in train_loop(config, model, noise_scheduler, optimizer, train_dataloader, lr_scheduler)
     26         if config.push_to_hub:
     27             repo_name = get_full_repo_name(Path(config.output_dir).name)
---> 28             repo = Repository(config.output_dir, clone_from=repo_name)
     29         elif config.output_dir is not None:
     30             os.makedirs(config.output_dir, exist_ok=True)

/opt/conda/lib/python3.7/site-packages/huggingface_hub/utils/_validators.py in _inner_fn(*args, **kwargs)
    122             )
    123 
--> 124         return fn(*args, **kwargs)
    125 
    126     return _inner_fn  # type: ignore

/opt/conda/lib/python3.7/site-packages/huggingface_hub/repository.py in __init__(self, local_dir, clone_from, repo_type, token, git_user, git_email, revision, skip_lfs_files, client)
    516 
    517         if clone_from is not None:
--> 518             self.clone_from(repo_url=clone_from)
    519         else:
    520             if is_git_repo(self.local_dir):

/opt/conda/lib/python3.7/site-packages/huggingface_hub/utils/_validators.py in _inner_fn(*args, **kwargs)
    122             )
    123 
--> 124         return fn(*args, **kwargs)
    125 
    126     return _inner_fn  # type: ignore

/opt/conda/lib/python3.7/site-packages/huggingface_hub/repository.py in clone_from(self, repo_url, token)
    731 
    732         except subprocess.CalledProcessError as exc:
--> 733             raise EnvironmentError(exc.stderr)
    734 
    735     def git_config_username_and_email(

OSError: WARNING: 'git lfs clone' is deprecated and will not be updated
          with new flags from 'git clone'

'git clone' has been updated in upstream Git to have comparable
speeds to 'git lfs clone'.
Cloning into '.'...
remote: Repository not found
fatal: repository 'https://huggingface.co/mwitiderrick/catsdiffusion/' not found
Error(s) during clone:
git clone failed: exit status 128

This looks like there was an issue in your local git client talking to the hub. Could you try to pull the repository manually from the command line?

Please kindly advise the way to overcome this issue, if someone knows.

Thank you, but I overcome already.

how? i have same error.

Hello, I have the same error, how to solve it, thank you very much!

I fixed this issue. Here is my method.
-Go to last line of the error find what repo is not found.
-Go to Hugging Face 鈥 The AI community building the future. to create the repository that is missing
-Run the code again

1 Like