Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
chenpangpang
transformers
Commits
03935d30
"tests/models/data2vec/test_modeling_data2vec_audio.py" did not exist on "d5ff69fce92bb1aab9273d674e762a8eddcb2e3f"
Unverified
Commit
03935d30
authored
May 24, 2024
by
Lucain
Committed by
GitHub
May 24, 2024
Browse files
Do not trigger autoconversion if local_files_only (#31004)
parent
21e259d8
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
1 deletion
+1
-1
src/transformers/modeling_utils.py
src/transformers/modeling_utils.py
+1
-1
No files found.
src/transformers/modeling_utils.py
View file @
03935d30
...
@@ -3393,7 +3393,7 @@ class PreTrainedModel(nn.Module, ModuleUtilsMixin, GenerationMixin, PushToHubMix
...
@@ -3393,7 +3393,7 @@ class PreTrainedModel(nn.Module, ModuleUtilsMixin, GenerationMixin, PushToHubMix
if
resolved_archive_file
is
not
None
:
if
resolved_archive_file
is
not
None
:
is_sharded
=
True
is_sharded
=
True
if
resolved_archive_file
is
not
None
:
if
not
local_files_only
and
resolved_archive_file
is
not
None
:
if
filename
in
[
WEIGHTS_NAME
,
WEIGHTS_INDEX_NAME
]:
if
filename
in
[
WEIGHTS_NAME
,
WEIGHTS_INDEX_NAME
]:
# If the PyTorch file was found, check if there is a safetensors file on the repository
# If the PyTorch file was found, check if there is a safetensors file on the repository
# If there is no safetensors file on the repositories, start an auto conversion
# If there is no safetensors file on the repositories, start an auto conversion
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment