Comments (12)
paddlepaddle has not been tested against anaconda python. Can you check which python paddlepaddle is linked with by looking at build/CMakeCache file?
from paddle.
Maybe you need install PaddlePaddle's python package manually. Try to find the file paddle*.whl in your install directory. It normally at "/usr/local/opt/paddle/share/wheels/" if you did not change DESTDIR or CMAKE_INSTALL_PREFIX.
During make process, PaddlePaddle will install some python package to default python interpreter in system, not anaconda.
from paddle.
I added this to build:
cmake -DWITH_GPU=ON -DWITH_DOC=OFF -DWITH_SWIG_PY=ON -DCMAKE_INSTALL_PREFIX=/home/youhost -DPYTHON_INCLUDE_DIR=/home/youhost/anaconda/include/python2.7 -DPYTHON_LIBRARY=/home/youhost/anaconda/lib/libpython2.7.so ..
From cmake file , I found this:
if(WITH_PYTHON)
find_package(PythonLibs 2.7 REQUIRED)
find_package(PythonInterp REQUIRED)
find_package(NumPy REQUIRED)
endif()
so to make python find my python libs I added : -DPYTHON_LIBRARY=/home/youhost/anaconda/lib
ref: https://cmake.org/cmake/help/v3.0/module/FindPythonLibs.html
build successed
-- Found PythonLibs: /home/youhost/anaconda/lib/libpython2.7.so (found suitable version "2.7.12", minimum required is "2.7")
-- Found PythonInterp: /home/youhost/anaconda/bin/python2.7 (found suitable version "2.7.12", minimum required is "2.7")
but But still has this error ...
F0831 20:01:44.284020 28877 PythonUtil.cpp:120] Check failed: (pyModule) != nullptr Python Error: <type 'exceptions.ImportError'> : No module named paddle.trainer.config_parser
太多坑了啊.
Another: gflags no found .
-- No preference for use of exported gflags CMake configuration set, and no hints for include/library directories provided. Defaulting to preferring an installed/exported gflags CMake configuration if available.
-- Failed to find installed gflags CMake configuration, searching for gflags build directories exported with CMake.
-- Failed to find an installed/exported CMake configuration for gflags, will perform search for installed gflags components.
Hope your team slove this , Thank you every much~
from paddle.
@reyoung yes . pypaddle_.whl and paddle_.whl in my install path.
from paddle.
@mingtop Just run anaconda's pip install these wheels, and will solve this problem
like this http://stackoverflow.com/questions/28002897/wheel-file-installation
from paddle.
I'm having the same problem when calling train.sh
from paddle.
@mingtop @Xiaomi2008 I have tested against anaconda2 python, I can run train.sh successfully. And the python package is installed in /home/xxx/anaconda2/lib/python2.7/site-packages/paddle-0.8.0b0-py2.7.egg
on my machine which is CentOS.
@Xiaomi2008 You may need to install PaddlePaddle's python package manually as @reyoung mentioned above.
from paddle.
@qingqing01
I used pip install pypaddle__.whl and paddle__.whl , the problem is still exist and I use python2.7, not anaconda python. please help.
from paddle.
@Xiaomi2008 You should ensure that the python used for compiling and running PaddlePaddle is the same. Then if you have install paddle-xxx.wh successfully. You maybe see the package like: your/python/path(or system lib path)/lib/python2.7/site-packages/paddle-0.8.0b0-py2.7.egg/
.
You can test it as follows. If there is no problem when importing, then installation is successful and I think it will be ok when run train.sh.
python
import paddle.trainer.config_parser
from paddle.
@qingqing01 I did see paddle in xxx/lib/python2.7/site-packages/paddle-0.8.0b0-py2.7.egg/
and I import paddle.trainer.config_parser with no error. But still got No this error when running train.sh.
BTW, my system is Ubuntu 14.04 server
from paddle.
@Xiaomi2008 Will the latest PaddlePaddle get this error? We did some fixes in 674d69c .
from paddle.
还是有 ImportError: No module named _sysconfigdata_nd的错误
需要将paddle\utils\PythonUtil.cpp的
Py_SetProgramName(argv[0]);
改为
Py_SetProgramName((char*)"python");
就正常了
from paddle.
Related Issues (20)
- 缺少torch.nn.utils.rnn.pad_sequence的API或者实现 HOT 2
- 在瑞芯微3568上已经部署好Fastdeploy。请问example中Yolov5的自己的onnx模型怎么使用呢? HOT 1
- paddlepaddle==2.6.0和2.6.1适配国产化与非国产化代码返回不一致问题 HOT 1
- Torch MultiHeadAttention To Paddle MultiHeadAttention Issue HOT 2
- softmax_with_cross_entropy API在软标签下label是否需要归一化 HOT 3
- 单机多卡问题 HOT 4
- Reported errors after running paddle.utils.run_check() HOT 1
- paddle.sparse.matmul两个参数都是sparse_csr_tensor时报错RuntimeError: (NotFound) The kernel `matmul_csr_csr` is not registered. HOT 2
- 这个教程代码有问题,https://www.paddlepaddle.org.cn/documentation/docs/zh/practices/nlp/transformer_in_English-to-Spanish.html
- Paddle的 Dataloader 遇到纯文本数据时报错 StopIteration HOT 1
- How to solve "license/cla Expected — Waiting for status to be reported" HOT 1
- 使用--use_trt出错 HOT 9
- 单机多卡问题 HOT 1
- templatedoc 机制清理 HOT 2
- 在华为Atlas310pro编译Paddle_npu版本,cmake有警告,make报错 HOT 3
- 【快乐开源】PIR模式下单测问题修复与适配
- 【开源之夏】动转静支持子图高阶微分
- phi::Device::SynchronizeStream传入的stream的raw_stream成员为空指针是否是正常的? HOT 24
- Does PP has a flowchart recognize product? HOT 2
- 如何将一个Tensor在内存中(不要保存到硬盘)序列化成可以通过网络传输的二进制格式? HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from paddle.