Closed johann-petrak closed 1 year ago
The cached_path
API was a private util for our downloads (note that we consider as private anything that is not in the main init). None of the research projects are actively maintained so they will only work with the version of Transformers corresponding to their creation.
You should use the huggingface_hub
library to manage downloads and cache of files on the Hub now. The closest thing we have to cached_path
is transformers.utils.hub.cached_file
in the current version.
Thanks, I will see if I can monkey-patch that tool/library accordingly.
System Info
transformers
version: 4.26.1Who can help?
No response
Information
Tasks
examples
folder (such as GLUE/SQuAD, ...)Reproduction
A tool using an older version of transformers uses
However, this api function disappeared sometime in 2022 but I could not find any information about what it should get replaced with or similar, change log or similar.
However even in the current transformers repo, this method gets used in some example files, sometimes re-defining this method, sometimes using the same import which does not work any longer:
Expected behavior
The import should be possible for backwards compatibility or documentation explain what to replace it with.
Version 4.21.0 seems the last version where that function could get imported