单机多卡训练出错,ABORT!!! Out of all 2 trainers, the trainer process with rank=[1] was aborted.
为使您的问题得到快速解决,在建立Issues前,请您先通过如下方式搜索是否有相似问题:【搜索issue关键字】【使用labels筛选】【官方文档】
如果您没有查询到相似问题,为快速解决您的提问,建立issue时请提供如下细节信息:
- 标题:单机多卡训练出错,ABORT!!! Out of all 2 trainers, the trainer process with rank=[1] was aborted.
- 版本、环境信息: 1)PaddlePaddle版本:conda虚拟环境下cudatoolkit=10.1.243, cudnn=7.6.5, paddlepaddle-gpu=2.1.3 2)CPU:Intel(R) Xeon(R) CPU E5-2650 v4 @ 2.20GHz 48核 3)GPU:Tesla M40, 2个GPU, 24GB, cuda 10.1 4)系统环境:Ubuntu16.04, Linux 内核 4.15.0-128-generic 注:您可以通过执行summary_env.py获取以上信息。
- 训练信息 1)单机,多卡 2)显卡信息
+-----------------------------------------------------------------------------+
| NVIDIA-SMI 430.64 Driver Version: 430.64 CUDA Version: 10.1 |
|-------------------------------+----------------------+----------------------+
| GPU Name Persistence-M| Bus-Id Disp.A | Volatile Uncorr. ECC |
| Fan Temp Perf Pwr:Usage/Cap| Memory-Usage | GPU-Util Compute M. |
|===============================+======================+======================|
| 0 Tesla M40 24GB Off | 00000000:02:00.0 Off | 0 |
| N/A 39C P0 59W / 250W | 1730MiB / 22945MiB | 0% Default |
+-------------------------------+----------------------+----------------------+
| 1 Tesla M40 24GB Off | 00000000:82:00.0 Off | 0 |
| N/A 26C P8 16W / 250W | 11MiB / 22945MiB | 0% Default |
+-------------------------------+----------------------+----------------------+
+-----------------------------------------------------------------------------+
| Processes: GPU Memory |
| GPU PID Type Process name Usage |
|=============================================================================|
+-----------------------------------------------------------------------------+
3)Operator信息
- 复现信息:如为报错,请给出复现环境、复现步骤
- 问题描述:单机单卡可以正常训练,但是单机多卡训练出错,ABORT!!! Out of all 2 trainers, the trainer process with rank=[1] was aborted.
输出信息:
----------- Configuration Arguments -----------
gpus: None
heter_worker_num: None
heter_workers:
http_port: None
ips: 127.0.0.1
log_dir: log
nproc_per_node: None
run_mode: None
server_num: None
servers:
training_script: main.py
training_script_args: []
worker_num: None
workers:
------------------------------------------------
WARNING 2021-10-21 15:01:46,410 launch.py:358] Not found distinct arguments and compiled with cuda or xpu. Default use collective mode
launch train in GPU mode!
INFO 2021-10-21 15:01:46,411 launch_utils.py:507] Local start 2 processes. First process distributed environment info (Only For Debug):
+=======================================================================================+
| Distributed Envs Value |
+---------------------------------------------------------------------------------------+
| PADDLE_TRAINER_ID 0 |
| PADDLE_CURRENT_ENDPOINT 127.0.0.1:51299 |
| PADDLE_TRAINERS_NUM 2 |
| PADDLE_TRAINER_ENDPOINTS 127.0.0.1:51299,127.0.0.1:38475 |
| PADDLE_RANK_IN_NODE 0 |
| PADDLE_LOCAL_DEVICE_IDS 0 |
| PADDLE_WORLD_DEVICE_IDS 0,1 |
| FLAGS_selected_gpus 0 |
| FLAGS_selected_accelerators 0 |
+=======================================================================================+
INFO 2021-10-21 15:01:46,411 launch_utils.py:512] details abouts PADDLE_TRAINER_ENDPOINTS can be found in log/endpoints.log, and detail running logs maybe found in log/workerlog.0
launch proc_id:46365 idx:0
launch proc_id:46368 idx:1
log_dir: ./work_dir/fsd/runs already exist
W1021 15:01:47.634395 46365 device_context.cc:404] Please NOTE: device: 0, GPU Compute Capability: 5.2, Driver API Version: 10.1, Runtime API Version: 10.1
W1021 15:01:47.642663 46365 device_context.cc:422] device: 0, cuDNN Version: 7.6.
INFO 2021-10-21 15:01:52,465 launch_utils.py:327] terminate all the procs
ERROR 2021-10-21 15:01:52,466 launch_utils.py:582] ABORT!!! Out of all 2 trainers, the trainer process with rank=[1] was aborted. Please check its log.
INFO 2021-10-21 15:01:55,469 launch_utils.py:327] terminate all the procs
W1021 15:04:09.448792 46671 device_context.cc:404] Please NOTE: device: 0, GPU Compute Capability: 5.2, Driver API Version: 10.1, Runtime API Version: 10.1
W1021 15:04:09.456403 46671 device_context.cc:422] device: 0, cuDNN Version: 7.6.
log/workerlog.0 的输出
--------------------------------------
C++ Traceback (most recent call last):
--------------------------------------
0 paddle::imperative::Tracer::TraceOp(std::string const&, paddle::imperative::NameVarBaseMap const&, paddle::imperative::NameVarBaseMap const&, paddle::framework::AttributeMap, paddle::platform::Place const&, bool, std::map<std::string, std::string, std::less<std::string >, std::allocator<std::pair<std::string const, std::string > > > const&)
1 paddle::imperative::PreparedOp::Prepare(paddle::imperative::NameVarBaseMap const&, paddle::imperative::NameVarBaseMap const&, paddle::framework::OperatorWithKernel const&, paddle::platform::Place const&, paddle::framework::AttributeMap const&)
2 paddle::imperative::PreparedOp paddle::imperative::PrepareImpl<paddle::imperative::VarBase>(paddle::imperative::details::NameVarMapTrait<paddle::imperative::VarBase>::Type const&, paddle::imperative::details::NameVarMapTrait<paddle::imperative::VarBase>::Type const&, paddle::framework::OperatorWithKernel const&, paddle::platform::Place const&, paddle::framework::AttributeMap const&)
3 paddle::platform::DeviceContextPool::Get(paddle::platform::Place const&)
4 std::__future_base::_Deferred_state<std::_Bind_simple<paddle::platform::EmplaceDeviceContext<paddle::platform::CUDADeviceContext, paddle::platform::CUDAPlace>(std::map<paddle::platform::Place, std::shared_future<std::unique_ptr<paddle::platform::DeviceContext, std::default_delete<paddle::platform::DeviceContext> > >, std::less<paddle::platform::Place>, std::allocator<std::pair<paddle::platform::Place const, std::shared_future<std::unique_ptr<paddle::platform::DeviceContext, std::default_delete<paddle::platform::DeviceContext> > > > > >*, paddle::platform::Place)::{lambda()#1} ()>, std::unique_ptr<paddle::platform::DeviceContext, std::default_delete<paddle::platform::DeviceContext> > >::_M_complete_async()
5 std::__future_base::_State_baseV2::_M_set_result(std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>, bool)
6 std::__future_base::_State_baseV2::_M_do_set(std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*, bool*)
7 std::_Function_handler<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> (), std::__future_base::_Task_setter<std::unique_ptr<std::__future_base::_Result<std::unique_ptr<paddle::platform::DeviceContext, std::default_delete<paddle::platform::DeviceContext> > >, std::__future_base::_Result_base::_Deleter>, std::_Bind_simple<paddle::platform::EmplaceDeviceContext<paddle::platform::CUDADeviceContext, paddle::platform::CUDAPlace>(std::map<paddle::platform::Place, std::shared_future<std::unique_ptr<paddle::platform::DeviceContext, std::default_delete<paddle::platform::DeviceContext> > >, std::less<paddle::platform::Place>, std::allocator<std::pair<paddle::platform::Place const, std::shared_future<std::unique_ptr<paddle::platform::DeviceContext, std::default_delete<paddle::platform::DeviceContext> > > > > >*, paddle::platform::Place)::{lambda()#1} ()>, std::unique_ptr<paddle::platform::DeviceContext, std::default_delete<paddle::platform::DeviceContext> > > >::_M_invoke(std::_Any_data const&)
8 paddle::platform::CUDADeviceContext::CUDADeviceContext(paddle::platform::CUDAPlace)
9 paddle::platform::CUDAContext::CUDAContext(paddle::platform::CUDAPlace const&, paddle::platform::stream::Priority const&)
10 paddle::platform::CublasHandleHolder::CublasHandleHolder(CUstream_st*, cublasMath_t)
11 cublasCreate_v2
12 paddle::framework::SignalHandle(char const*, int)
13 paddle::platform::GetCurrentTraceBackString[abi:cxx11]()
----------------------
Error Message Summary:
----------------------
FatalError: `Termination signal` is detected by the operating system.
[TimeInfo: *** Aborted at 1634799851 (unix time) try "date -d @1634799851" if you are using GNU date ***]
[SignalInfo: *** SIGTERM (@0x3e80000b643) received by PID 46671 (TID 0x7fb6e2226700) from PID 46659 ***]
使用paddle.utils.run_check()得到的信息
>>> paddle.utils.run_check()
Running verify PaddlePaddle program ...
W1021 15:06:05.165225 46852 device_context.cc:404] Please NOTE: device: 0, GPU Compute Capability: 5.2, Driver API Version: 10.1, Runtime API Version: 10.1
W1021 15:06:05.172127 46852 device_context.cc:422] device: 0, cuDNN Version: 7.6.
PaddlePaddle works well on 1 GPU.
W1021 15:06:08.362532 46852 parallel_executor.cc:601] Cannot enable P2P access from 0 to 1
W1021 15:06:08.362567 46852 parallel_executor.cc:601] Cannot enable P2P access from 1 to 0
W1021 15:06:11.824173 46852 fuse_all_reduce_op_pass.cc:76] Find all_reduce operators: 2. To make the speed faster, some all_reduce ops are fused during training, after fusion, the number of all_reduce ops is 2.
PaddlePaddle works well on 2 GPUs.
PaddlePaddle is installed successfully! Let's start deep learning with PaddlePaddle now.
您好,我们已经收到了您的问题,会安排技术人员尽快解答您的问题,请耐心等待。请您再次检查是否提供了清晰的问题描述、复现代码、环境&版本、报错信息等。同时,您也可以通过查看官网API文档、常见问题、历史Issue、AI社区来寻求解答。祝您生活愉快~
Hi! We've received your issue and please be patient to get responded. We will arrange technicians to answer your questions as soon as possible. Please make sure that you have posted enough message to demo your request. You may also check out the API,FAQ,Github Issue and AI community to get the answer.Have a nice day!
您好,看着cuda的环境有点问题,尝试使用docker使用镜像的方式来使用paddle
你好,请提供一下workerlog.1的日志
你好,请提供一下workerlog.1的日志
log/workerlog.1 的输出
Traceback (most recent call last):
File "/data/yuanxu/Project/CTR-GCN-Paddle/main.py", line 415, in <module>
processor = Processor(args)
File "/data/yuanxu/Project/CTR-GCN-Paddle/main.py", line 57, in __init__
self.load_model()
File "/data/yuanxu/Project/CTR-GCN-Paddle/main.py", line 100, in load_model
self.model = Model(**self.arg.model_args)
File "/data/yuanxu/Project/CTR-GCN-Paddle/model/ctrgcn.py", line 333, in __init__
self.data_bn = nn.BatchNorm1D(num_person * in_channels * num_point)
File "/home/amax1/miniconda3/envs/yuanxu/lib/python3.9/site-packages/paddle/nn/layer/norm.py", line 750, in __init__
super(BatchNorm1D,
File "/home/amax1/miniconda3/envs/yuanxu/lib/python3.9/site-packages/paddle/nn/layer/norm.py", line 577, in __init__
self.weight = self.create_parameter(
File "/home/amax1/miniconda3/envs/yuanxu/lib/python3.9/site-packages/paddle/fluid/dygraph/layers.py", line 411, in create_parameter
return self._helper.create_parameter(temp_attr, shape, dtype, is_bias,
File "/home/amax1/miniconda3/envs/yuanxu/lib/python3.9/site-packages/paddle/fluid/layer_helper_base.py", line 369, in create_parameter
return self.main_program.global_block().create_parameter(
File "/home/amax1/miniconda3/envs/yuanxu/lib/python3.9/site-packages/paddle/fluid/framework.py", line 2920, in create_parameter
initializer(param, self)
File "/home/amax1/miniconda3/envs/yuanxu/lib/python3.9/site-packages/paddle/fluid/initializer.py", line 156, in __call__
op = block.append_op(
File "/home/amax1/miniconda3/envs/yuanxu/lib/python3.9/site-packages/paddle/fluid/framework.py", line 2946, in append_op
_dygraph_tracer().trace_op(type,
File "/home/amax1/miniconda3/envs/yuanxu/lib/python3.9/site-packages/paddle/fluid/dygraph/tracer.py", line 43, in trace_op
self.trace(type, inputs, outputs, attrs,
NotImplementedError: (Unimplemented) Place CUDAPlace(0) is not supported. Please check that your paddle compiles with WITH_GPU, WITH_XPU or WITH_ASCEND_CL option or check that your train pr
ocess set the correct device id if you use Executor. (at /paddle/paddle/fluid/platform/device_context.cc:88)
[operator < fill_constant > error]
请确认下是不是GPU版本的paddle 确认命令: python3 -c 'import paddle, print(paddle.is_compiled_with_cuda())' 如果输出是True,表示是GPU版本;输出是False,则不是GPU版本。 如果不是GPU版本,请更换为GPU版本的apddle 如果是True, 请在启动任务前执行export GLOG_v=3 ,执行任务后提供一下全量日志
你好,我也遇到这个问题了,请问解决了么
你好,我也遇到这个问题了,请问解决了么
没有,最后只用了单卡。 你可以尝试一下@wenming2014 提到的用docker方式使用paddle,我不想折腾了,没试。