Python Virtualenv

We recommend usage of virtualenv to create Python environments in one's own home area on the cluster. As an example, here we want to create a virtualenv with the Python 2.7.5 installation. To do this, please enter the following in a shell:

The above alters your current PATH to include the Python 2.7.5 executable. It then creates a new virtualenv that includes all of the system installed packages listed above. You will now be able to install your own python packages as needed using pip.

To default to using this environment during an interactive (bsub -Is bash) session, add this to the bottom of your .bashrc file:

Shown above is using virtualenv to create a new custom python environment in your home folder that pulled in numpy/scipy and other system install python libraries . Also shown was installation of a local python package.