PaddleNLP icon indicating copy to clipboard operation
PaddleNLP copied to clipboard

paddle.distributed.launch 可以使用非分布式吗?

Open sifuhr opened this issue 3 years ago • 7 comments

软件环境

paddlepaddle == 2.3.2
paddlenlp == 2.5.2
paddleocr == 2.6.1.3

重复问题

  • [X] I have searched the existing issues

错误描述

ValueError: Operator "gen_nccl_id" has not been registered.
LAUNCH INFO 2023-05-30 10:42:54,298 Exit code 1

稳定复现步骤 & 代码

paddle.distributed.launch python -m paddle.distributed.launch --log_dir log ./src/train_ce.py --use_cuda false --verbose true --do_train true --do_val false --do_test false --use_mix_precision false --train_data_size 40000 --batch_size 32 --init_pretraining_params checkpoints/base_model --train_set data/train.tsv --save_steps 1250 --validation_steps 1250 --checkpoints output --weight_decay 0.01 --warmup_proportion 0.0 --epoch 50 --max_seq_len 384 --for_cn true --vocab_path config/ernie_base_1.0_CN/vocab.txt --ernie_config_path config/ernie_base_1.0_CN/ernie_config.json --learning_rate 1e-5 --skip_steps 10 --num_iteration_per_drop_scope 1 --num_labels 2 --random_seed 1 不采用paddle.distributed.launch 行吗?使用单节点怎么运行

sifuhr avatar May 31 '23 06:05 sifuhr

单节点单卡:python train_ce.py 单节点多卡/多节点多卡:python -m paddle.distributed.launch train_ce.py

gongel avatar May 31 '23 07:05 gongel

哦哦,好的我试试,谢谢

sifuhr avatar May 31 '23 07:05 sifuhr

paddle\fluid\incubate\fleet\base\role_maker.py", line 539, in generate_role assert self._worker_endpoints is not None, "can't find PADDLE_TRAINER_ENDPOINTS"

sifuhr avatar May 31 '23 07:05 sifuhr

命令如下:python ./src/train_ce.py --use_cuda True --verbose true --do_train true --do_val false --do_test false --use_mix_precision false --train_data_size 40000 --batch_size 32 --init_pretraining_params checkpoints/base_model --train_set data/train.tsv --save_steps 1250 --validation_steps 1250 --checkpoints output --weight_decay 0.01 --warmup_proportion 0.0 --epoch 50 --max_seq_len 384 --for_cn true --vocab_path config/ernie_base_1.0_CN/vocab.txt --ernie_config_path config/ernie_base_1.0_CN/ernie_config.json --learning_rate 1e-5 --skip_steps 10 --num_iteration_per_drop_scope 1 --num_labels 2 --random_seed 1

sifuhr avatar May 31 '23 07:05 sifuhr

File "F:\classes_different\PaddleNLP-develop\applications\document_intelligence\doc_vqa\Rerank\src\train_ce.py", line 354, in main(args) File "F:\classes_different\PaddleNLP-develop\applications\document_intelligence\doc_vqa\Rerank\src\train_ce.py", line 92, in main fleet.init(role) File "D:\anaconda\envs\llm\lib\site-packages\paddle\fluid\incubate\fleet\base\fleet_base.py", line 210, in init self._role_maker.generate_role() File "D:\anaconda\envs\llm\lib\site-packages\paddle\fluid\incubate\fleet\base\role_maker.py", line 539, in generate_role assert self._worker_endpoints is not None, "can't find PADDLE_TRAINER_ENDPOINTS" AssertionError: can't find PADDLE_TRAINER_ENDPOINTS

sifuhr avatar May 31 '23 07:05 sifuhr

请问作者这个问题解决了没有

Longer767 avatar Jun 06 '23 05:06 Longer767

同问

galaxystatistics avatar Jun 06 '23 13:06 galaxystatistics