Update 0.get_started.md

This commit is contained in:
Chao Fan
2022-10-31 16:51:53 +08:00
committed by GitHub
parent bb61874e90
commit 5669c398fd
+2 -2
View File
@@ -37,7 +37,7 @@ See [prepare dataset](2.prepare_dataset.md).
## Train ## Train
Train a model by Train a model by
``` ```
CUDA_VISIBLE_DEVICES=0,1 python -m torch.distributed.launch --nproc_per_node=2 opengait/main.py --cfgs ./config/baseline/baseline.yaml --phase train CUDA_VISIBLE_DEVICES=0,1 python -m torch.distributed.launch --nproc_per_node=2 opengait/main.py --cfgs ./configs/baseline/baseline.yaml --phase train
``` ```
- `python -m torch.distributed.launch` [DDP](https://pytorch.org/tutorials/intermediate/ddp_tutorial.html) launch instruction. - `python -m torch.distributed.launch` [DDP](https://pytorch.org/tutorials/intermediate/ddp_tutorial.html) launch instruction.
- `--nproc_per_node` The number of gpus to use, and it must equal the length of `CUDA_VISIBLE_DEVICES`. - `--nproc_per_node` The number of gpus to use, and it must equal the length of `CUDA_VISIBLE_DEVICES`.
@@ -51,7 +51,7 @@ You can run commands in [train.sh](train.sh) for training different models.
## Test ## Test
Evaluate the trained model by Evaluate the trained model by
``` ```
CUDA_VISIBLE_DEVICES=0,1 python -m torch.distributed.launch --nproc_per_node=2 opengait/main.py --cfgs ./config/baseline/baseline.yaml --phase test CUDA_VISIBLE_DEVICES=0,1 python -m torch.distributed.launch --nproc_per_node=2 opengait/main.py --cfgs ./configs/baseline/baseline.yaml --phase test
``` ```
- `--phase` Specified as `test`. - `--phase` Specified as `test`.
- `--iter` Specify a iteration checkpoint. - `--iter` Specify a iteration checkpoint.