Correct docstrings and a typo in comments (#27047)

* docs(training_args): correct docstrings

Correct docstrings of these methods in `TrainingArguments`:

- `set_save`
- `set_logging`

* docs(training_args): adjust words in docstrings

Co-authored-by: Steven Liu <59462357+stevhliu@users.noreply.github.com>

* docs(trainer): correct a typo in comments

---------

Co-authored-by: Steven Liu <59462357+stevhliu@users.noreply.github.com>
This commit is contained in:
L. Yeung 2023-10-26 23:46:17 +08:00 committed by GitHub
parent 8214d6e7b1
commit 1892592530
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 4 deletions

View File

@ -1911,7 +1911,7 @@ class Trainer:
logger.info("\n\nTraining completed. Do not forget to share your model on huggingface.co/models =)\n\n")
if args.load_best_model_at_end and self.state.best_model_checkpoint is not None:
# Wait for everyone to get here so we are sur the model has been saved by process 0.
# Wait for everyone to get here so we are sure the model has been saved by process 0.
if is_torch_tpu_available():
xm.rendezvous("load_best_model_at_end")
elif args.parallel_mode == ParallelMode.DISTRIBUTED:

View File

@ -2178,7 +2178,7 @@ class TrainingArguments:
jit_mode: bool = False,
):
"""
A method that regroups all arguments linked to the evaluation.
A method that regroups all arguments linked to evaluation.
Args:
strategy (`str` or [`~trainer_utils.IntervalStrategy`], *optional*, defaults to `"no"`):
@ -2276,7 +2276,7 @@ class TrainingArguments:
on_each_node: bool = False,
):
"""
A method that regroups all arguments linked to the evaluation.
A method that regroups all arguments linked to checkpoint saving.
Args:
strategy (`str` or [`~trainer_utils.IntervalStrategy`], *optional*, defaults to `"steps"`):
@ -2329,7 +2329,7 @@ class TrainingArguments:
replica_level: str = "passive",
):
"""
A method that regroups all arguments linked to the evaluation.
A method that regroups all arguments linked to logging.
Args:
strategy (`str` or [`~trainer_utils.IntervalStrategy`], *optional*, defaults to `"steps"`):