使用 Python 3.6 在 Raspberry Pi 3 模型 B 上安装 virtualenvwrapper

Installing virtualenvwrapper on a Raspberry Pi 3 Model B with Python 3.6

我一直在尝试 download/install 在 Raspberry Pi 3 模型 B 上使用 virtualenvwrapper,但在终端中使用命令 "source ~/.profile" 时收到错误消息。我正在尝试使用 python 3.6 安装 OpenCV,但我需要设置 virtualenvwrapper。 运行 "source ~/.profile" 时出现的错误是:

/usr/bin/python: No module named virtualenvwrapper
virtualenvwrapper.sh: There was a problem running the initialization hooks.

If Python could not import the module virtualenvwrapper.hook_loader,
check that virtualenvwrapper has been installed for
VIRTUALENVWRAPPER_PYTHON=/usr/bin/python and that PATH is
set properly.

我正在遵循此在线指南:https://www.pyimagesearch.com/2017/09/04/raspbian-stretch-install-opencv-3-python-on-your-raspberry-pi/

任何帮助将不胜感激,提前致谢。

设法修复它,不得不重写“~/.profile”。

改变

VIRTUALENVWRAPPER_PYTHON=/usr/bin/python

VIRTUALENVWRAPPER_PYTHON=/usr/local/bin/pythonx.x

x.x 是 Python 版本)。