add npu examples

Former-commit-id: 0f21e68e2dbd84c820d66d5c6d980004efc51d51
This commit is contained in:
hiyouga
2024-05-14 23:32:53 +08:00
parent 0a82e15e7c
commit ba0da83031
8 changed files with 85 additions and 19 deletions

View File

@@ -6,7 +6,7 @@ RANK=0
MASTER_ADDR=192.168.0.1
MASTER_PORT=29500
CUDA_VISIBLE_DEVICES=0,1,2,3 python -m torch.distributed.run \
CUDA_VISIBLE_DEVICES=0,1,2,3 torchrun \
--nproc_per_node $NPROC_PER_NODE \
--nnodes $NNODES \
--node_rank $RANK \