Skip to content

Commit

Permalink
update the description of resume training.
Browse files Browse the repository at this point in the history
  • Loading branch information
mtjhl authored and Chilicyy committed Nov 4, 2022
1 parent 12d302a commit 4ee4300
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 1 deletion.
6 changes: 6 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -179,14 +179,20 @@ python -m torch.distributed.launch --nproc_per_node 8 tools/train.py \

If your training process is corrupted, you can resume training by
```
# single GPU training.
python tools/train.py --resume
# multi GPU training.
python -m torch.distributed.launch --nproc_per_node 8 tools/train.py --resume
```
Above command will automatically find the latest checkpoint in YOLOv6 directory, then resume the training process.

Your can also specify a checkpoint path to `--resume` parameter by
```
# remember to replace /path/to/your/checkpoint/path to the checkpoint path which you want to resume training.
--resume /path/to/your/checkpoint/path
```
This will resume from the specific checkpoint you provide.

</details>
</details>
Expand Down
9 changes: 8 additions & 1 deletion README_cn.md
Original file line number Diff line number Diff line change
Expand Up @@ -167,14 +167,21 @@ python -m torch.distributed.launch --nproc_per_node 8 tools/train.py \

如果您的训练进程中断了,您可以这样恢复先前的训练进程。
```
# 多卡训练.
# 单卡训练
python tools/train.py --resume
# 多卡训练
python -m torch.distributed.launch --nproc_per_node 8 tools/train.py --resume
```
上面的命令将自动在 YOLOv6 目录中找到最新保存的模型,然后恢复训练。

您也可以通过 `--resume` 参数指定要恢复的模型路径
```
# 记得把 /path/to/your/checkpoint/path 替换为您要恢复训练的模型权重路径
--resume /path/to/your/checkpoint/path
```
这将从您提供的模型路径恢复训练。

</details>
</details>

Expand Down

0 comments on commit 4ee4300

Please sign in to comment.