首页 Paddle框架 帖子详情
_distributor_init 错误,求解
收藏
快速回复
Paddle框架 问答深度学习 1482 4
_distributor_init 错误,求解
收藏
快速回复
Paddle框架 问答深度学习 1482 4

Ubuntu16.04  显示安装成功了 cuda 10 ,但是验证出错

Installing collected packages: paddlepaddle-gpu
Successfully installed paddlepaddle-gpu-1.8.3.post107

验证出错:

import paddle.fluid as fluid
Traceback (most recent call last):
File "", line 1, in
File "/home/wellhoo/.local/lib/python2.7/site-packages/paddle/__init__.py", line 31, in
import paddle.dataset
File "/home/wellhoo/.local/lib/python2.7/site-packages/paddle/dataset/__init__.py", line 29, in
import paddle.dataset.flowers
File "/home/wellhoo/.local/lib/python2.7/site-packages/paddle/dataset/flowers.py", line 38, in
import scipy.io as scio
File "/home/wellhoo/.local/lib/python2.7/site-packages/scipy/__init__.py", line 77, in
from . import _distributor_init
ImportError: cannot import name _distributor_init

 

环境如下:

python --version
Python 2.7.18

python -c "import platform;print(platform.architecture()[0]);print(platform.machine())"
64bit
x86_64

nvcc -V
nvcc: NVIDIA (R) Cuda compiler driver
Copyright (c) 2005-2018 NVIDIA Corporation
Built on Sat_Aug_25_21:08:01_CDT_2018
Cuda compilation tools, release 10.0, V10.0.130

pip show wheel
DEPRECATION: Python 2.7 reached the end of its life on January 1st, 2020. Please upgrade your Python as Python 2.7 is no longer maintained. pip 21.0 will drop support for Python 2.7 in January 2021. More details about Python 2 support in pip, can be found at https://pip.pypa.io/en/latest/development/release-process/#python-2-support
Name: wheel
Version: 0.34.2
Summary: A built-package format for Python
Home-page: https://github.com/pypa/wheel
Author: Daniel Holth
Author-email: dholth@fastmail.fm
License: MIT
Location: /usr/local/python2715/lib/python2.7/site-packages

 

python -m ensurepip
DEPRECATION: Python 2.7 will reach the end of its life on January 1st, 2020. Please upgrade your Python as Python 2.7 won't be maintained after that date. A future version of pip will drop support for Python 2.7. More details about Python 2 support in pip, can be found at https://pip.pypa.io/en/latest/development/release-process/#python-2-support
Looking in links: /tmp/tmpAuS8Tc
Requirement already satisfied: setuptools in /usr/local/python2715/lib/python2.7/site-packages (44.1.1)
Requirement already satisfied: pip in /usr/local/python2715/lib/python2.7/site-packages/pip-20.1.1-py2.7.egg (20.1.1)

0
收藏
回复
全部评论(4)
时间顺序
c
cxmzlxb
#2 回复于2020-07

pip show scipy
DEPRECATION: Python 2.7 reached the end of its life on January 1st, 2020. Please upgrade your Python as Python 2.7 is no longer maintained. pip 21.0 will drop support for Python 2.7 in January 2021. More details about Python 2 support in pip, can be found at https://pip.pypa.io/en/latest/development/release-process/#python-2-support
Name: scipy
Version: 1.2.1
Summary: SciPy: Scientific Library for Python
Home-page: https://www.scipy.org
Author: None
Author-email: None
License: BSD
Location: /home/wellhoo/.local/lib/python2.7/site-packages
Requires: numpy
Required-by: paddlepaddle-gpu

scipy 的版本

0
回复
thinc
#3 回复于2020-07

你试着新建一个虚拟环境 再安装paddlepaddle-gpu  看会不会出现上述问题

0
回复
c
cxmzlxb
#4 回复于2020-07
thinc #3
你试着新建一个虚拟环境 再安装paddlepaddle-gpu  看会不会出现上述问题

我用conda 新建了环境,重新安装,出现如下错误:

(paddle_37) wellhoo@Vehicle-Server:~/download$ python3
Python 3.7.7 (default, Mar 26 2020, 15:48:22)
[GCC 7.3.0] :: Anaconda, Inc. on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import paddle.fluid as fluid
>>> fluid.install_check.run_check()
Running Verify Fluid Program ...
W0727 19:17:50.077417 11242 device_context.cc:252] Please NOTE: device: 0, CUDA Capability: 61, Driver API Version: 11.0, Runtime API Version: 10.0
W0727 19:17:50.084745 11242 device_context.cc:260] device: 0, cuDNN Version: 7.6.
Your Paddle Fluid works well on SINGLE GPU or CPU.
W0727 19:17:56.220106 11242 init.cc:216] Warning: PaddlePaddle catches a failure signal, it may not work properly
W0727 19:17:56.220144 11242 init.cc:218] You could check whether you killed PaddlePaddle thread/process accidentally or report the case to PaddlePaddle
W0727 19:17:56.220149 11242 init.cc:221] The detail failure signal is:

W0727 19:17:56.220155 11242 init.cc:224] *** Aborted at 1595848676 (unix time) try "date -d @1595848676" if you are using GNU date ***
W0727 19:17:56.222936 11242 init.cc:224] PC: @ 0x0 (unknown)
W0727 19:17:56.223068 11242 init.cc:224] *** SIGSEGV (@0x0) received by PID 11242 (TID 0x7fbcc8fce700) from PID 0; stack trace: ***
W0727 19:17:56.225515 11242 init.cc:224] @ 0x7fbcc8bcb390 (unknown)
W0727 19:17:56.228000 11242 init.cc:224] @ 0x0 (unknown)
Segmentation fault

0
回复
thinc
#5 回复于2020-07
cxmzlxb #4
我用conda 新建了环境,重新安装,出现如下错误: (paddle_37) wellhoo@Vehicle-Server:~/download$ python3 Python 3.7.7 (default, Mar 26 2020, 15:48:22) [GCC 7.3.0] :: Anaconda, Inc. on linux Type "help", "copyright", "credits" or "license" for more information. >>> import paddle.fluid as fluid >>> fluid.install_check.run_check() Running Verify Fluid Program ... W0727 19:17:50.077417 11242 device_context.cc:252] Please NOTE: device: 0, CUDA Capability: 61, Driver API Version: 11.0, Runtime API Version: 10.0 W0727 19:17:50.084745 11242 device_context.cc:260] device: 0, cuDNN Version: 7.6. Your Paddle Fluid works well on SINGLE GPU or CPU. W0727 19:17:56.220106 11242 init.cc:216] Warning: PaddlePaddle catches a failure signal, it may not work properly W0727 19:17:56.220144 11242 init.cc:218] You could check whether you killed PaddlePaddle thread/process accidentally or report the case to PaddlePaddle W0727 19:17:56.220149 11242 init.cc:221] The detail failure signal is: W0727 19:17:56.220155 11242 init.cc:224] *** Aborted at 1595848676 (unix time) try "date -d @1595848676" if you are using GNU date *** W0727 19:17:56.222936 11242 init.cc:224] PC: @ 0x0 (unknown) W0727 19:17:56.223068 11242 init.cc:224] *** SIGSEGV (@0x0) received by PID 11242 (TID 0x7fbcc8fce700) from PID 0; stack trace: *** W0727 19:17:56.225515 11242 init.cc:224] @ 0x7fbcc8bcb390 (unknown) W0727 19:17:56.228000 11242 init.cc:224] @ 0x0 (unknown) Segmentation fault
展开

辛苦提一下issue吧:https://github.com/PaddlePaddle/Paddle/issues

0
回复
需求/bug反馈?一键提issue告诉我们
发现bug?如果您知道修复办法,欢迎提pr直接参与建设飞桨~
在@后输入用户全名并按空格结束,可艾特全站任一用户