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
55ab71ee
Unverified
Commit
55ab71ee
authored
Dec 01, 2022
by
Sanchit Gandhi
Committed by
GitHub
Dec 01, 2022
Browse files
[modelcard] Update dataset tags (#20506)
parent
e342ac7e
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
2 deletions
+2
-2
src/transformers/modelcard.py
src/transformers/modelcard.py
+2
-2
No files found.
src/transformers/modelcard.py
View file @
55ab71ee
...
...
@@ -559,8 +559,8 @@ class TrainingSummary:
dataset_args
=
None
,
):
# Infer default from dataset
one_dataset
=
trainer
.
train
_dataset
if
trainer
.
train
_dataset
is
not
None
else
trainer
.
eval
_dataset
if
is_hf_dataset
(
one_dataset
)
and
(
dataset_tags
is
None
or
dataset_args
is
None
):
one_dataset
=
trainer
.
eval
_dataset
if
trainer
.
eval
_dataset
is
not
None
else
trainer
.
train
_dataset
if
is_hf_dataset
(
one_dataset
)
and
(
dataset_tags
is
None
or
dataset_args
is
None
or
dataset_metadata
is
None
):
default_tag
=
one_dataset
.
builder_name
# Those are not real datasets from the Hub so we exclude them.
if
default_tag
not
in
[
"csv"
,
"json"
,
"pandas"
,
"parquet"
,
"text"
]:
...
...
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