Openeye python libraries

From DISI
Jump to: navigation, search

They provide a "nice" python package that can be installed in a virtualenv.

I've copied the contents of this to /nfs/soft/openeye/current/python to emulate the Cluster 0 behavior.

However the "best" approach may be to create a virtualenv and install it in there. That way you're isolated from any changes that may happened on the cluster versions: This should do it all:

/nfs/soft/python/install/scripts/create-virtualenv.sh /nfs/soft/python/envs/vanilla/python-2.7.7 ~/my-python-env
  1. Wait a bit
/nfs/soft/python/envs/vanilla/python-2.7.7/bin/pip freeze > ~/my-python-env/requirements.txt
source ~/my-python-env/bin/activate.[c]sh
pip install -r ~/my-python-env/requirements.txt
pip install /nfs/soft/openeye/install/centos/OpenEye-python2.7-redhat-6-x64-2014.2.2/dist/OpenEye_python2.7_redhat_6_x64-2014.2.2-py2.7.egg

Alternatively you can use the /nfs/soft/python/envs/complete/latest environment. It has openeye installed.

OpenEye Python 3 Toolkit 2018

Due to the nature of nfs-soft being a CentOS 6 server, we must run the most current version of OpenEye through a conda/miniconda with Python3 environment.
See page on conda: http://wiki.docking.org/index.php/Install_Miniconda
Here is the page on OpenEye website explaining different ways to set it up.

If you run openeye from nfs-soft without a conda environment, you will run into an issue with a /usr/lib64/libstdc++.so.6 error

ImportError: /usr/lib64/libstdc++.so.6: version `GLIBCXX_3.4.15' not found 
(required by /nfs/soft/openeye/OpenEye-toolkits-python3-linux-x64-2018.2.1/openeye/libs/python3-linux-x64-g++4.x/liboebio-2.1.4.so)

Here is how to install with Conda environment

Download Conda3 installer file to directory that you would like to install (Please check /nfs/soft if there is one already installed)

wget https://repo.anaconda.com/archive/Anaconda3-2018.12-Linux-x86_64.sh
bash Anaconda3-2018.12-Linux-x86_64.sh
# pre-end /path/to/install/tools/anaconda3 for install path and let installer finish

After Conda3 is installed, create conda environment for OpenEye Python Toolkit

conda create -n oepython3 python=3

Activate compatible conda python environment

$ source activate oepython3

source relevant openeye environment and license

(oepython3) $ source /mnt/nfs/soft/openeye/OpenEye-toolkits-python3-linux-x64-2018.2.1/env.sh 


Running some commands may run into below error. This is a pip issue with pip version >10.

AttributeError: module 'pip' has no attribute 'main'
(oepython3) $ pip -V
pip 10.0.1 from /home/s_bwong1/miniconda3/envs/oepython3/lib/python3.7/site-packages/pip (python 3.7)

Downgrade to pip 9.0.3 to avoid it.

$ pip install --upgrade pip==9.0.3

Run OpenEye tests to see if configuration works:

(oepython3) $ python /mnt/nfs/soft/openeye/OpenEye-toolkits-python3-linux-x64-2018.2.1/openeye/examples/openeye_tests.py
(oepython3) $ python /mnt/nfs/soft/openeye/OpenEye-toolkits-python3-linux-x64-2018.2.1/openeye/examples/oechem/oecheminfo.py 
Installed OEChem version: 2.1.4 platform: linux-g++4.x-x64 built: 20180215