Change the current module to one with g++ module switch TCSuite GCC
The compute nodes do not have internet access, so you have to download all packages before installing. For python2.7.5, download the python package from the ssh node. And then go to the compute node.
The compute node and the ssh node do not have same architecture. So the above command works only from the compute nodes. To enter the compute node (say just a single node): pjsub --interact -L "mode=1"
Now configure the python package: ./configure --build=x86_64 --prefix=$HOME/source/install_pfx_comp make -j16 install
Ok, now append to the path and test that it works! :)
Now we will install numpy. Download numpy package from Python Package index website. Untar it on the compute node. And then python setup.py install--prefix=$HOME/source/install_pfx_comp
Change to home directory and see that importing numpy works.
Now download scipy from PyPI website. Untar it. To build scipy you also need LAPACK. Get it from the netlib website. cd lapack-x.x.x cp INSTALL/make.inc.gfortran make.inc
Change make.inc to have the following flags: OPTS = -O2 -fPIC DRVOPTS = $(OPTS) NOOPT = -O0 -fPIC
Let us now make and use all processors ;) make -j 16
Now let us build ATLAS. Download it from the website. It seems now-a-days you need to just provide the tarfile path to atlas (they say building atlas is getting easier, let us see! :) ). mkdir ../configure -Fa alg -fPIC --with-netlib-lapack-tarfile=/path/to/lapack-3.4.2.tgz --prefix=/home/d21004/source/install_pfx_comp/ make
This step takes quite some time as it is optimizing the code for the compilers, so you have to wait. It takes more than a couple of hours or so on one node to compile, I guess. This one bailed on me. No worries, scipy can be installed without ATLAS.
So add the following to the path: export BLAS=/path/to/libfblas.a export LAPACK=/path/to/liblapack.a
Then install scipy from the source. This one went through without issues. Next download matplotlib. There is a freetype dependency, so install that too. Add the following to include path -I/path/to/install_pfx_comp/include/ -I/path/to/install_pfx_comp/include/freetype2
Now there is another png.h dependency, so install libpng. And then install matplotlib.
After this importing pylab gives bus error. :( . So now first fix some pkg-config problems. Install pkg-config, first: export GLIB_CFLAGS=-I/usr/include/glib-2.0 export GLIB_LFLAGS=-L/usr/lib64/ -lglib-2.0 -liconv -lintl
and then configure the matplotlib package. This is completely useless installation. Such a waste of time. Waiting for Tanaka-san to reply.
List available modules:
module avail
Change the current module to one with g++
module switch TCSuite GCC
The compute nodes do not have internet access, so you have to download all packages before installing. For python2.7.5, download the python package from the ssh node. And then go to the compute node.
The compute node and the ssh node do not have same architecture. So the above command works only from the compute nodes. To enter the compute node (say just a single node):
pjsub --interact -L "mode=1"
Now configure the python package:
./configure --build=x86_64 --prefix=$HOME/source/install_pfx_comp
make -j16 install
Ok, now append to the path and test that it works! :)
Now we will install numpy. Download numpy package from Python Package index website. Untar it on the compute node. And then
python setup.py install --prefix=$HOME/source/install_pfx_comp
Change to home directory and see that importing numpy works.
Now download scipy from PyPI website. Untar it. To build scipy you also need LAPACK. Get it from the netlib website.
cd lapack-x.x.x
cp INSTALL/make.inc.gfortran make.inc
Change make.inc to have the following flags:
OPTS = -O2 -fPIC
DRVOPTS = $(OPTS)
NOOPT = -O0 -fPIC
Let us now make and use all processors ;)
make -j 16
Now let us build ATLAS. Download it from the website. It seems now-a-days you need to just provide the tarfile path to atlas (they say building atlas is getting easier, let us see! :) ).
mkdir
../configure -Fa alg -fPIC --with-netlib-lapack-tarfile=/path/to/lapack-3.4.2.tgz --prefix=/home/d21004/source/install_pfx_comp/
make
This step takes quite some time as it is optimizing the code for the compilers, so you have to wait. It takes more than a couple of hours or so on one node to compile, I guess. This one bailed on me. No worries, scipy can be installed without ATLAS.
So add the following to the path:
export BLAS=/path/to/libfblas.a
export LAPACK=/path/to/liblapack.a
Then install scipy from the source. This one went through without issues. Next download matplotlib. There is a freetype dependency, so install that too. Add the following to include path
-I/path/to/install_pfx_comp/include/ -I/path/to/install_pfx_comp/include/freetype2
Now there is another png.h dependency, so install libpng. And then install matplotlib.
After this importing pylab gives bus error. :( . So now first fix some pkg-config problems. Install pkg-config, first:
export GLIB_CFLAGS=-I/usr/include/glib-2.0
export GLIB_LFLAGS=-L/usr/lib64/ -lglib-2.0 -liconv -lintl
and then configure the matplotlib package. This is completely useless installation. Such a waste of time. Waiting for Tanaka-san to reply.