PaddlePaddle运行时出现paddle.fluid.core_avx.EnforceNotMet: Invoke operator fill_constant error错误

在运行PaddlePaddle模型时遇到`paddle.fluid.core_avx.EnforceNotMet: Invoke operator fill_constant error`错误。问题解决方法是通过设置CUDA_VISIBLE_DEVICES环境变量,指定使用的GPU设备。
摘要由CSDN通过智能技术生成
  • 问题描述:在使用paddlepaddle启动模型时遇到下列问题:
Traceback (most recent call last):
  File "test.py", line 131, in <module>
    test(args)
  File "test.py", line 77, in test
    exe.run(fluid.default_startup_program())
  File "/home/spwux/anaconda3/envs/fall/lib/python3.6/site-packages/paddle/fluid/executor.py", line 657, in run
    use_program_cache=use_program_cache)
  File "/home/spwux/anaconda3/envs/fall/lib/python3.6/site-packages/paddle/fluid/executor.py", line 755, in _run
    exe.run(program.desc, scope, 0, True, True, fetch_var_name)
paddle.fluid.core_avx.EnforceNotMet: Invoke operator fill_constant error.
Python Call stacks: 
  File "/home/spwux/anaconda3/envs/fall/lib/python3.6/site-packages/paddle/fluid/framework.py", line 1845, in _prepend_op
    attrs=kwargs.get("attrs", None))
  File "/home/spwux/anaconda3/envs/fall/lib/python3.6/site-packages/paddle/fluid/initializer.py", line 189, in __call__
    stop_gradient=True)
  File "/home/spwux/anaconda3/envs/fall/lib/python3.6/site-packages/paddle/fluid/framework.py", line 1730, in create_parameter
    initializer(param, self)
  File "/home/spwux/anaconda3/envs/fall/lib/python3.6/site-packages/paddle/fluid/layer_helper_base.py", line 316, in create_parameter
    **attr._to_kwargs(with_initializer=True))
  File "/home/spwux/anaconda3/envs/fall/lib/python3.6/site-packages/paddle/fluid/layer_helper.py", line 128, in append_bias_op
    attr=bias_attr, shape=size, dtype=input_var.dtype, is_bias=True)
  File "/home/spwux/anaconda3/envs/fall/lib/python3.6/site-packages/paddle/fluid/layers/nn.py", line 2184, in conv2d
    pre_act = helper.append_bias_op(pre_bias, dim_start=1, dim_end=2)
  File "/home/spwux/Desktop/fall/human_pose_estimation/lib/pose_resnet.py", line 110, in net
    initializer=fluid.initializer.Normal(0., 0.001)))
  File "test.py", line 74, in test
    output = model.net(input=image, target=None, target_weight=None)
  File "test.py", line 131, in <module>
    test(args)
C++ Call stacks: 
cudaM
  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 1
    评论
评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值