Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Install Request: GPAW #585

Open
kaibinary opened this issue Aug 27, 2024 · 5 comments
Open

Install Request: GPAW #585

kaibinary opened this issue Aug 27, 2024 · 5 comments

Comments

@kaibinary
Copy link
Contributor

GPAW is a density-functional theory (DFT) Python code based on the projector-augmented wave (PAW) method and the atomic simulation environment (ASE).

Application: GPAW version 24.6.0

Link: https://gitlab.com/gpaw/gpaw

Cluster: Young

License: GNU General Public License v3.0 or later

Request 1279990

@kaibinary
Copy link
Contributor Author

Testing personal install;

module purge
module load python3/3.9-gnu-10.2.0
module load mpi/openmpi/4.0.5/gnu-10.2.0
virtualenv ~/py-gpaw
source ~/py-gpaw/bin/activate
pip install --no-cache-dir pip --upgrade

wget https://gitlab.com/libxc/libxc/-/archive/6.2.2/libxc-6.2.2.tar.bz2
tar -xf libxc-6.2.2.tar.bz2 
cd libxc-6.2.2 
autoreconf -i
CFLAGS="-fPIC" ./configure --enable-shared --enable-static --disable-fortran --prefix=$HOME/libxc-6.2.2
make -j8
make install
cd ..

wget https://pypi.org/packages/source/g/gpaw/gpaw-24.6.0.tar.gz
tar -xf gpaw-24.6.0.tar.gz
cd gpaw-24.6.0
cat <<EOF > siteconfig.py
# MPI:
mpi = True
if mpi:
    compiler = 'mpicc'
    extra_compile_args += ['-fopenmp']
    extra_link_args += ['-fopenmp']

# OpenBlas:
libraries = ['blas']
library_dirs = ['/shared/ucl/apps/openblas/0.3.13-serial/gnu-10.2.0/lib']
include_dirs = ['/shared/ucl/apps/openblas/0.3.13-serial/gnu-10.2.0/include']
runtime_library_dirs = ['/shared/ucl/apps/openblas/0.3.13-serial/gnu-10.2.0/lib']

# FFTW3:
fftw = True
if fftw:
    libraries += ['fftw3']
    library_dirs += ['/shared/ucl/apps/fftw/3.3.9/gnu-10.2.0/lib']
    include_dirs += ['/shared/ucl/apps/fftw/3.3.9/gnu-10.2.0/include']
    runtime_library_dirs += ['/shared/ucl/apps/fftw/3.3.9/gnu-10.2.0/lib']

if 1:
    xc = '$HOME/libxc-6.2.2/'
    include_dirs += [xc + 'include']
    library_dirs += [xc + 'lib']
    extra_link_args += [xc + 'lib/libxc.a']
    runtime_library_dirs += [xc + 'lib']
EOF
pip install --no-cache-dir . 2>&1 | tee ~/gpaw_install_output.txt

Install went well.

@kaibinary
Copy link
Contributor Author

Testing a parallel calculation.

(py-gpaw) [mmm0001@login02 gpaw-24.6.0]$ gpaw install-data ~/
Available setups and pseudopotentials
  [*] https://wiki.fysik.dtu.dk/gpaw-files/gpaw-setups-24.1.0.tar.gz
      https://wiki.fysik.dtu.dk/gpaw-files/gpaw-setups-0.9.20000.tar.gz
      https://wiki.fysik.dtu.dk/gpaw-files/gpaw-setups-0.9.11271.tar.gz
      https://wiki.fysik.dtu.dk/gpaw-files/gpaw-setups-0.9.9672.tar.gz
      https://wiki.fysik.dtu.dk/gpaw-files/gpaw-setups-0.8.7929.tar.gz
      https://wiki.fysik.dtu.dk/gpaw-files/gpaw-setups-0.6.6300.tar.gz
      https://wiki.fysik.dtu.dk/gpaw-files/gpaw-setups-0.5.3574.tar.gz

Selected gpaw-setups-24.1.0.tar.gz.  Downloading...
Extracting tarball into /home/mmm0001/
Setups installed into /home/mmm0001/gpaw-setups-24.1.0.
Register this setup path in /home/mmm0001/.gpaw/rc.py? [y/n] y
Setup path registered in /home/mmm0001/.gpaw/rc.py.
Current GPAW setup paths in order of search priority:
   1. /home/mmm0001/gpaw-setups-24.1.0
Installation complete.
(py-gpaw) [mmm0001@login02 gpaw-24.6.0]$ gpaw -P 4 test
 -----------------------------------------------------------------------------------------------------------------
| python-3.9.6      /lustre/home/mmm0001/py-gpaw/bin/python                                                       |
| gpaw-24.6.0       /lustre/home/mmm0001/gpaw-24.6.0/gpaw/                                                        |
| ase-3.23.0        /lustre/home/mmm0001/py-gpaw/lib/python3.9/site-packages/ase/                                 |
| numpy-1.26.4      /lustre/home/mmm0001/py-gpaw/lib/python3.9/site-packages/numpy/                               |
| scipy-1.13.1      /lustre/home/mmm0001/py-gpaw/lib/python3.9/site-packages/scipy/                               |
| libxc-6.2.2       yes                                                                                           |
| _gpaw             /lustre/home/mmm0001/py-gpaw/lib/python3.9/site-packages/_gpaw.cpython-39-x86_64-linux-gnu.so |
| MPI enabled       yes                                                                                           |
| OpenMP enabled    yes                                                                                           |
| GPU enabled       no                                                                                            |
| GPU-aware MPI     no                                                                                            |
| CUPY              /lustre/home/mmm0001/gpaw-24.6.0/gpaw/gpu/cpupy/__init__.py                                   |
| scalapack         no                                                                                            |
| Elpa              no                                                                                            |
| FFTW              yes                                                                                           |
| libvdwxc          no                                                                                            |
| PAW-datasets (1)  /home/mmm0001/gpaw-setups-24.1.0                                                              |
 -----------------------------------------------------------------------------------------------------------------
Doing a test calculation (cores: 4): ... Done

Looks ok.

@kaibinary
Copy link
Contributor Author

User requires a scalapack enabled version.

https://www.netlib.org/scalapack/

@kaibinary
Copy link
Contributor Author

ScaLAPACK doesn't like GCC 10.2.0 b/c of Reference-ScaLAPACK/scalapack#73

@kaibinary
Copy link
Contributor Author

Trying out the ScaLAPACK's master branch (commit 25935e1);

module purge
module load python3/3.9-gnu-10.2.0
module load mpi/openmpi/4.0.5/gnu-10.2.0
module load cmake/3.27.3
virtualenv ~/py-gpaw
source ~/py-gpaw/bin/activate
pip install --no-cache-dir pip --upgrade

# libxc-6.2.2
wget https://gitlab.com/libxc/libxc/-/archive/6.2.2/libxc-6.2.2.tar.bz2
tar -xf libxc-6.2.2.tar.bz2 
cd libxc-6.2.2 
autoreconf -i
CFLAGS="-fPIC" ./configure --enable-shared --enable-static --disable-fortran --prefix=$HOME/libxc-6.2.2
make -j8
make install
cd ..

# scalapack
git clone https://github.com/Reference-ScaLAPACK/scalapack.git
cd scalapack
git checkout 25935e1
cmake CMakeLists.txt -DBUILD_SHARED_LIBS=ON -DCMAKE_INSTALL_PREFIX=$HOME/scalapack-25935e1
make -j8
make install
cd ..

# gpaw
wget https://pypi.org/packages/source/g/gpaw/gpaw-24.6.0.tar.gz
tar -xf gpaw-24.6.0.tar.gz
cd gpaw-24.6.0
cat <<EOF > siteconfig.py
# MPI:
mpi = True
if mpi:
    compiler = 'mpicc'
    extra_compile_args += ['-fopenmp']
    extra_link_args += ['-fopenmp']

# OpenBlas:
libraries = ['blas']
library_dirs = ['/shared/ucl/apps/openblas/0.3.13-serial/gnu-10.2.0/lib']
include_dirs = ['/shared/ucl/apps/openblas/0.3.13-serial/gnu-10.2.0/include']
runtime_library_dirs = ['/shared/ucl/apps/openblas/0.3.13-serial/gnu-10.2.0/lib']

# FFTW3:
fftw = True
if fftw:
    libraries += ['fftw3']
    library_dirs += ['/shared/ucl/apps/fftw/3.3.9/gnu-10.2.0/lib']
    include_dirs += ['/shared/ucl/apps/fftw/3.3.9/gnu-10.2.0/include']
    runtime_library_dirs += ['/shared/ucl/apps/fftw/3.3.9/gnu-10.2.0/lib']

scalapack = True
if scalapack:
    libraries += ['scalapack']
    library_dirs += ['$HOME/scalapack-25935e1/lib']
    include_dirs += ['$HOME/scalapack-25935e1/include']
    runtime_library_dirs += ['$HOME/scalapack-25935e1/lib']

if 1:
    xc = '$HOME/libxc-6.2.2/'
    include_dirs += [xc + 'include']
    library_dirs += [xc + 'lib']
    extra_link_args += [xc + 'lib/libxc.a']
    runtime_library_dirs += [xc + 'lib']
EOF
pip install --no-cache-dir . 2>&1 | tee ~/gpaw_install_output.txt
cd ..

Testing a parallel run...

(py-gpaw) [mmm0001@login01 scalapack]$ gpaw -P 4 test
 -----------------------------------------------------------------------------------------------------------------
| python-3.9.6      /lustre/home/mmm0001/py-gpaw/bin/python                                                       |
| gpaw-24.6.0       /lustre/home/mmm0001/py-gpaw/lib/python3.9/site-packages/gpaw/                                |
| ase-3.23.0        /lustre/home/mmm0001/py-gpaw/lib/python3.9/site-packages/ase/                                 |
| numpy-1.26.4      /lustre/home/mmm0001/py-gpaw/lib/python3.9/site-packages/numpy/                               |
| scipy-1.13.1      /lustre/home/mmm0001/py-gpaw/lib/python3.9/site-packages/scipy/                               |
| libxc-6.2.2       yes                                                                                           |
| _gpaw             /lustre/home/mmm0001/py-gpaw/lib/python3.9/site-packages/_gpaw.cpython-39-x86_64-linux-gnu.so |
| MPI enabled       yes                                                                                           |
| OpenMP enabled    yes                                                                                           |
| GPU enabled       no                                                                                            |
| GPU-aware MPI     no                                                                                            |
| CUPY              /lustre/home/mmm0001/py-gpaw/lib/python3.9/site-packages/gpaw/gpu/cpupy/__init__.py           |
| scalapack         yes                                                                                           |
| Elpa              no                                                                                            |
| FFTW              yes                                                                                           |
| libvdwxc          no                                                                                            |
| PAW-datasets (1)  /home/mmm0001/gpaw-setups-24.1.0                                                              |
 -----------------------------------------------------------------------------------------------------------------
Doing a test calculation (cores: 4): ... Done

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant