python2.7.12 不包含 numpy 也不包含 pip 所以我无法在 gromacs 中运行我的程序

标签 python g++

我手动下载Python 2.7.12,因为在我的 super 文件中,python2.7.15+ 不起作用。

在我的Python 2.7.12中没有pip命令,所以我无法安装networkx和numpy包。

我可以做什么来运行

python cgenff_charmm2gmx.py JZ4 jz4_fix.mol2 jz4.str charmm36-mar2019.ff

我正在尝试在我的 python 2.7.12 上 boostrap pip。但这也给出了一个错误:

suchi@DESKTOP-TR0BVV2:/mnt/c/Users/Microsoft/Desktop/Gromacs/Complex1$ python cgenff_charmm2gmx_py3.py UNK1 jz4_fix.mol2 jz4.str charmm36-jul2017.ff Traceback (most recent call last): File "cgenff_charmm2gmx_py3.py", line 50, in import numpy as np ImportError: No module named 'numpy' suchi@DESKTOP-TR0BVV2:/mnt/c/Users/Microsoft/Desktop/Gromacs/Complex1$

============ DONE ============
Conversion complete.
The molecule topology has been written to jz4.itp
Additional parameters needed by the molecule are written to jz4.prm, which needs to be included in the system .top
============ DONE ============

最佳答案

您可以先手动安装pip。下载get-pip.py然后执行它 使用下面的命令。

# download the get-pip.py
wget https://bootstrap.pypa.io/get-pip.py

# use these 2 commands to make sure you have selected the right python
which python
python --version

# install pip, should work for both python2 and python3
python get-pip.py

然后,您可以安装几乎所有您需要的软件包。 例如,

python -m pip install numpy

安装numpy

关于python2.7.12 不包含 numpy 也不包含 pip 所以我无法在 gromacs 中运行我的程序,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/57238153/

相关文章:

python - 如何限制pyTelegramBotAPI中少数用户的访问?

python - matplotlib 在 pandas DataFrame 中绘制日期时间

python - Django 没有读取表中的所有列

gcc - Fedora 29 中的 c++config.h

c++ - 为什么 g++ 允许返回不可复制的类?

c++ - 使用 g++ 将多个源文件编译成一个 .o

python - 如何在Python中以8位编码16位WAV文件?

python - Numpy - 如何将向量索引数组转换为掩码?

gcc - 生成文件中的 CC?= 是什么意思?

C++ 和对 XML_Parser 的 undefined reference