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
66f675eb
Unverified
Commit
66f675eb
authored
May 03, 2024
by
Pavel Iakubovskii
Committed by
GitHub
May 03, 2024
Browse files
Fix W&B run name (#30462)
* Remove comparison to output_dir * Update docs for `run_name` * Add warning
parent
425e1a04
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
10 additions
and
5 deletions
+10
-5
src/transformers/integrations/integration_utils.py
src/transformers/integrations/integration_utils.py
+8
-3
src/transformers/training_args.py
src/transformers/training_args.py
+2
-2
No files found.
src/transformers/integrations/integration_utils.py
View file @
66f675eb
...
...
@@ -762,9 +762,14 @@ class WandbCallback(TrainerCallback):
if
trial_name
is
not
None
:
init_args
[
"name"
]
=
trial_name
init_args
[
"group"
]
=
args
.
run_name
else
:
if
not
(
args
.
run_name
is
None
or
args
.
run_name
==
args
.
output_dir
):
elif
args
.
run_name
is
not
None
:
init_args
[
"name"
]
=
args
.
run_name
if
args
.
run_name
==
args
.
output_dir
:
self
.
_wandb
.
termwarn
(
"The `run_name` is currently set to the same value as `TrainingArguments.output_dir`. If this was "
"not intended, please specify a different run name by setting the `TrainingArguments.run_name` parameter."
,
repeat
=
False
,
)
if
self
.
_wandb
.
run
is
None
:
self
.
_wandb
.
init
(
...
...
src/transformers/training_args.py
View file @
66f675eb
...
...
@@ -420,9 +420,9 @@ class TrainingArguments:
the past hidden states for their predictions. If this argument is set to a positive int, the `Trainer` will
use the corresponding output (usually index 2) as the past state and feed it to the model at the next
training step under the keyword argument `mems`.
run_name (`str`, *optional*):
run_name (`str`, *optional*
, defaults to `output_dir`
):
A descriptor for the run. Typically used for [wandb](https://www.wandb.com/) and
[mlflow](https://www.mlflow.org/) logging.
[mlflow](https://www.mlflow.org/) logging.
If not specified, will be the same as `output_dir`.
disable_tqdm (`bool`, *optional*):
Whether or not to disable the tqdm progress bars and table of metrics produced by
[`~notebook.NotebookTrainingTracker`] in Jupyter Notebooks. Will default to `True` if the logging level is
...
...
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