Reorganize file utils (#16264)
* Split file_utils in several submodules * Fixes * Add back more objects * More fixes * Who exactly decided to import that from there? * Second suggestion to code with code review * Revert wront move * Fix imports * Adapt all imports * Adapt all imports everywhere * Revert this import, will fix in a separate commit
This commit is contained in:
@@ -35,7 +35,7 @@ from requests import HTTPError
|
||||
|
||||
from . import __version__
|
||||
from .dynamic_module_utils import custom_object_save
|
||||
from .file_utils import (
|
||||
from .utils import (
|
||||
EntryNotFoundError,
|
||||
ExplicitEnum,
|
||||
PaddingStrategy,
|
||||
@@ -43,11 +43,6 @@ from .file_utils import (
|
||||
RepositoryNotFoundError,
|
||||
RevisionNotFoundError,
|
||||
TensorType,
|
||||
_is_jax,
|
||||
_is_numpy,
|
||||
_is_tensorflow,
|
||||
_is_torch,
|
||||
_is_torch_device,
|
||||
add_end_docstrings,
|
||||
cached_path,
|
||||
copy_func,
|
||||
@@ -59,10 +54,11 @@ from .file_utils import (
|
||||
is_tf_available,
|
||||
is_tokenizers_available,
|
||||
is_torch_available,
|
||||
logging,
|
||||
to_py_obj,
|
||||
torch_required,
|
||||
)
|
||||
from .utils import logging
|
||||
from .utils.generic import _is_jax, _is_numpy, _is_tensorflow, _is_torch, _is_torch_device
|
||||
|
||||
|
||||
if TYPE_CHECKING:
|
||||
|
||||
Reference in New Issue
Block a user