PaddleFL icon indicating copy to clipboard operation
PaddleFL copied to clipboard

/PaddleFL/python/paddle_fl/mpc/examples/logistic_with_mnist/train_fc_sigmoid.py numpy报错

Open Yuchen-Li opened this issue 3 years ago • 1 comments

Hi guys,

当我想在单机上尝试logistic_with_mnist的时候,在跟随README.md执行后,在本步遇到报错

sh run_standalone.sh train_fc_sigmoid.py

在脚本中python执行过程中报错

Traceback (most recent call last):
  File "logistic_with_mnist/train_fc_sigmoid.py", line 22, in <module>
    import numpy as np
Traceback (most recent call last):
ImportError  File "logistic_with_mnist/train_fc_sigmoid.py", line 22, in <module>
: No module named numpy
    import numpy as np
ImportError: No module named numpy
Traceback (most recent call last):
  File "logistic_with_mnist/train_fc_sigmoid.py", line 22, in <module>
    import numpy as np
ImportError: No module named numpy

看上去是因为没有找到numpy安装的原因,但是当我检查环境中的numpy库,

[root@docker-desktop examples]# pip list | grep numpy
numpy                              1.15.4

请问各位知不知道是什么导致了这个问题?谢谢啦~(虽然我知道这个问题可能有点弱智)

Best regards, RL

Yuchen-Li avatar Apr 28 '21 03:04 Yuchen-Li

please check and ensure the var PYTHON=${PYTHON} is correctly set in the run_standalone.sh, which should point to the python installation in which the numpy, paddle and paddle fl is setup correctly.

honshj avatar May 07 '21 03:05 honshj