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

⬆️ UPDATE: Siesta MaX-1.1 #12

Merged
merged 38 commits into from
Dec 4, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
38 commits
Select commit Hold shift + click to select a range
069814d
Added plstm to Utils
albgar Oct 23, 2020
6a3752e
Remove duplicate instructions for utilities. Add fftw3
albgar Oct 23, 2020
c9b133b
Add support for xmlf90 and libpsml
albgar Oct 23, 2020
c1d6cfc
Added support for libgridxc
albgar Oct 23, 2020
2cc5051
Update for MaX interim version
albgar Oct 23, 2020
6998f8e
Add flook
albgar Oct 25, 2020
5a1c346
Use ldconfig. Wrap flook role
albgar Oct 25, 2020
dfef9cc
Use psml pseudos. Add Lua test
albgar Oct 25, 2020
f44dd66
Add libxc support. Enable tests in defaults/main.yml
albgar Oct 26, 2020
0c03293
Add more utilities
albgar Oct 26, 2020
e9c1544
Add psml pseudopotentials
albgar Oct 27, 2020
040633d
First stage of linting
albgar Oct 27, 2020
a3ecc15
Second pass of linting
albgar Oct 27, 2020
3b720b4
Merge branch 'update-max-1.1'
albgar Oct 27, 2020
e494edb
Fix idempotency of libpsml and psml-files
albgar Oct 27, 2020
ddc081c
Disable libxc for Ubuntu16. Add tests for Ubuntu20
albgar Oct 28, 2020
314d635
Fix blacs and make issues for ubuntu20
albgar Oct 29, 2020
b366f02
Improve test logic
albgar Oct 29, 2020
4f6eb2e
Remove blacs variable from main vars file
albgar Oct 29, 2020
cc046cf
Merge branch 'ub20'
albgar Oct 29, 2020
40c560c
Update logic in siesta tests
albgar Oct 30, 2020
9a81c24
Some documentation and cosmetics. Fix 'siesta_executables'
albgar Nov 2, 2020
1a99b72
Cosmetic fixes after review
albgar Nov 28, 2020
3d32e99
Add focal to meta/main.yml
albgar Nov 28, 2020
50b31aa
Fix pre-commit issues
albgar Nov 28, 2020
be1cae9
More comments in README.md regarding versions supported
albgar Nov 29, 2020
78aff19
First version of libxc sub-role
albgar Dec 2, 2020
b3763fc
libxc logic now works
albgar Dec 2, 2020
b648a0b
Disable shared libs for libgridxc if using current libxc role
albgar Dec 2, 2020
5759fb9
Merge branch 'add-libxc'
albgar Dec 2, 2020
aff21e6
Fix tag for 4.1 version
albgar Dec 2, 2020
04b2a8c
Install Max-1.2.0 by default. Update README.md
albgar Dec 2, 2020
f12f8df
Fix molecule files to deal with libxc role
albgar Dec 2, 2020
f0e8362
Remove libxc test line from molecule.yml
albgar Dec 4, 2020
0f12092
Move siesta_libxc_root var to defaults/main.yml
albgar Dec 4, 2020
ecb4db3
Remove 'minor_version' variables
albgar Dec 4, 2020
2382723
Use tarballs from Gitlab tags for the libraries
albgar Dec 4, 2020
10455c7
Merge branch 'reconf' into dec4-fix
albgar Dec 4, 2020
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .ansible-lint
Original file line number Diff line number Diff line change
Expand Up @@ -3,3 +3,4 @@ warn_list: # or 'skip_list' to silence them completely
- '208' # File permissions unset or incorrect
- '305' # Use shell only when shell functionality is required
- '503' # Tasks that run when changed should likely be handlers

2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ jobs:

strategy:
matrix:
distro: [ubuntu1604, ubuntu1804]
distro: [ubuntu1604, ubuntu1804, ubuntu2004]
fail-fast: false

runs-on: ubuntu-latest
Expand Down
38 changes: 36 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,22 +4,56 @@

# Ansible Role: marvel-nccr.siesta

An Ansible role that installs [Siesta](https://launchpad.net/siesta) on Ubuntu.
An Ansible role that installs [Siesta](https://gitlab.com/siesta-project/siesta) on Ubuntu.

It can install any MaX-1.X version. These are 'preview' versions with
important features (PSML, etc), not yet merged into the master
version.

PSML support is important to access databases and prepare
pseudopotentials for all elements, as needed by the aiida-siesta
package, which supports PSML since the 1.1.0 version. Fuller support
for protocols, also heavily dependent on the PSML feature, appeared in
the 1.1.1 version. Older versions of aiida-siesta can also work with
this version of Siesta, although they will not be able to access all
the features.

Note that support for the ELSI library (the other major feature of the
rel-MaX-1 branch) is not compiled in for deployments in the QuantumMobile,
as it is mostly a performance feature.

With minor changes detailed in the defaults/main.yml file, this role can also
compile the 4.1-rc2 version of Siesta, in the beta branch.

Future versions along the rel-MaX-1 and rel-4.1 branches could in
principle be built, as long as they can still use the same libraries,
and as long as they have a proper tag in the Gitlab repository.


## Installation

`ansible-galaxy install marvel-nccr.siesta`

## Role Variables

See `defaults/main.yml`
See `defaults/main.yml`.

In particular, `siesta_version` can be set to the desired tag. By default,
it is set to `MaX-1.2.0`.

This role uses the marvel-nccr.libxc role to install versions of libxc
in those systems where libxc package support is sub-standard. The required
libxc version can be set through the variable `siesta_libxc_version`, which
is `4.3.4` by default.

## Example Playbook

```yaml
- hosts: servers
roles:
- role: marvel-nccr.siesta
vars:
siesta_version: "MaX-1.2.0" # tag in GitLab
```

## Development and testing
Expand Down
220 changes: 150 additions & 70 deletions defaults/main.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,38 @@
siesta_version: "v4.1-rc2"
siesta_minor_version: "v4.1"
#
# These variables control the optional features.
#
siesta_enable_mpi: "1"
siesta_enable_netcdf: "1"
siesta_enable_ncdf: "1"
siesta_enable_flook: "1"

#
run_tests: true
#--------------------------
#
# We install by default the MaX-1.X series of versions. These have
# important features (PSML pseudopotentials, etc), not yet merged into the
# master version.
# PSML support is important to access databases of pseudopotentials for all elements.
#
# Note that support for the ELSI library is not compiled in
# in this deployment for the QuantumMobile, as it is mostly a performance
# feature.
#
# Any version in GitLab with a tag of the form MaX.1* can be used here.
#
siesta_version: "MaX-1.2.0"
#------------------------------------------------------------------------------------
#
# Still, it is possible to install the "rel-4.1" version of Siesta
# by setting
#
#### siesta_version: "v4.1-rc2"
#
# **AND** removing "unfold" from the list of 'siesta_utils' futher below
#------------------------------------------------------------------------------------


siesta_src: siesta-{{ siesta_version }}
siesta_src_archive: "{{ siesta_src }}.tar.gz"
siesta_code_folder: "/tmp"
Expand All @@ -8,118 +41,165 @@ siesta_data_folder: "{{ siesta_prefix }}/share/siesta"
siesta_url: "https://gitlab.com/siesta-project/siesta/-/archive/{{ siesta_version }}/{{ siesta_src_archive }}"
siesta_topdir: "{{ siesta_code_folder }}/siesta-{{ siesta_version }}"

siesta_enable_netcdf: "1"
siesta_enable_ncdf: "1"
siesta_xmlf90_root: ""
siesta_psml_root: ""
siesta_gridxc_root: ""
siesta_libxc_root: ""
siesta_xmlf90_version: "1.5.5"
siesta_xmlf90_src: xmlf90-{{ siesta_xmlf90_version }}
siesta_xmlf90_src_archive: "{{ siesta_xmlf90_src }}.tar.gz"
siesta_xmlf90_code_folder: "/tmp"
siesta_xmlf90_prefix: "/usr/local"
siesta_xmlf90_url: "https://gitlab.com/siesta-project/libraries/xmlf90/-/archive/{{ siesta_xmlf90_version }}/{{ siesta_xmlf90_src_archive }}"
siesta_xmlf90_topdir: "{{ siesta_xmlf90_code_folder }}/xmlf90-{{ siesta_xmlf90_version }}"

siesta_libpsml_version: "1.1.10"
siesta_libpsml_src: libpsml-{{ siesta_libpsml_version }}
siesta_libpsml_src_archive: "{{ siesta_libpsml_src }}.tar.gz"
siesta_libpsml_code_folder: "/tmp"
siesta_libpsml_prefix: "/usr/local"
siesta_libpsml_url: "https://gitlab.com/siesta-project/libraries/libpsml/-/archive/{{ siesta_libpsml_version }}/{{ siesta_libpsml_src_archive }}"
siesta_libpsml_topdir: "{{ siesta_libpsml_code_folder }}/libpsml-{{ siesta_libpsml_version }}"

# The libxc version (to be used through libgridxc). The (Quantum
# Mobile) libxc role has the installation path hardwired now, and it
# installs by default the 4.3.4 version. Since it suits us, we set
# this version here, to save on building time if the libxc role was
# invoked earlier (see the full logic in tasks/libxc.yml, including
# how we simply install a system package if the distribution is modern enough)

siesta_libxc_version: "4.3.4"
siesta_libxc_root: "/usr/local/libxc-{{ siesta_libxc_version }}"

siesta_libgridxc_version: "0.9.6"
siesta_libgridxc_src: libgridxc-{{ siesta_libgridxc_version }}
siesta_libgridxc_src_archive: "{{ siesta_libgridxc_src }}.tar.gz"
siesta_libgridxc_code_folder: "/tmp"
siesta_libgridxc_prefix: "/usr/local"
siesta_libgridxc_url: "https://gitlab.com/siesta-project/libraries/libgridxc/-/archive/{{ siesta_libgridxc_version }}/{{ siesta_libgridxc_src_archive }}"
siesta_libgridxc_topdir: "{{ siesta_libgridxc_code_folder }}/libgridxc-{{ siesta_libgridxc_version }}"

siesta_flook_version: "0.8.1"
siesta_flook_src: flook-{{ siesta_flook_version }}
siesta_flook_src_archive: "{{ siesta_flook_src }}.tar.gz"
siesta_flook_code_folder: "/tmp"
siesta_flook_prefix: "/usr/local"
siesta_flook_url: "https://github.com/ElectronicStructureLibrary/flook/archive/v0.8.1.tar.gz"
siesta_flook_topdir: "{{ siesta_flook_code_folder }}/flook-{{ siesta_flook_version }}"

siesta_xmlf90_root: "{{ siesta_xmlf90_prefix }}"
siesta_psml_root: "{{ siesta_libpsml_prefix }}"
siesta_gridxc_root: "{{ siesta_libgridxc_prefix }}"
siesta_flook_root: "{{ siesta_flook_prefix }}"
siesta_fftw_root: "/usr/lib"

#----------
siesta_netcdf_incflags: "-I/usr/include"
siesta_netcdf_libs: "-lnetcdff -lnetcdf"
siesta_blacs_libs: "-lblacsF77init-openmpi -lblacsCinit-openmpi -lblacs-openmpi"
siesta_fftw_incflags: "-I/usr/include"
siesta_fftw_libs: "-lfftw3f -lfftw3"
siesta_scalapack_libs: "-lscalapack-openmpi {{ siesta_blacs_libs }}"
siesta_lapack_libs: "-llapack -lblas"

#
# This variable will be picked up by the Aiida role
#
siesta_executables:
- name: siesta
folder: "{{ siesta_prefix }}"
folder: "{{ siesta_prefix }}/bin"
plugin: siesta.siesta
#
# After a recent upgrade, this program is not compatible with the STM plugin :-(
# The version shipped with siesta-4.0.X is still appropriate
# - name: plstm
# folder: "{{ siesta_prefix }}/Util/STM/simple-stm/plstm"
# plugin: siesta.stm

# Utilities in Util/
- name: plstm
folder: "{{ siesta_prefix }}/bin"
plugin: siesta.stm

#--------------------------------------------------

# Siesta utilities, installed together with the main Siesta executable

siesta_utils:
- name: plstm
dir: Util/STM/simple-stm
description: >-
Post-processor for LDOS or RHO data for STM imaging

- name: stm
dir: Util/STM/ol-stm/Src
description: >-
Generator of LDOS data (with opt wf projection) for STM imaging

- name: unfold
dir: Util/Unfolding/Src
description: >-
Unfolding utility

- name: denchar
dir: Util/Denchar/Src
description: >-
Charge density and wave-function plotting

- name: g2c_ng
dir: Util/Grid
description: >-
Converter from native grid to Cube format

- name: macroave
dir: Util/Macroave/Src
description: >-
Macroscopic averages processor

- name: mprop
dir: Util/COOP
description: >-
COOP/COHP processor

- name: fat
dir: Util/COOP
description: >-
Fat-bands processor

- name: gnubands
dir: Util/Bands
description: >-
Band-structure plotting

- name: eigfat2plot
dir: Util/Bands
description: >-
Fat-bands plotting

- name: readwfx
dir: Util/WFS
description: >-
Read contents of WFSX files

- name: vibra
dir: Util/Vibra/Src
description: >-
Computes phonon frequencies

- name: fcbuild
dir: Util/Vibra/Src
description: >-
Pre-processor for force-constant calculation

- name: tbtrans
dir: Util/TS/TBtrans
description: >-
Transport post-processor

siesta_pps:
# - name: nc-sr-pbe-stringent-0.4
# folder: nc-sr-pbe-stringent-0.4
# file: nc-sr-04_pbe_stringent_psml.tgz
# url: http://departments.icmab.es/leem/SIESTA_MATERIAL/tmp_PseudoDojo/
# home_page: http://www.pseudo-dojo.org/
# description: >-
# Norm-conserving scalar-relativistic pseudopotentials v0.4 for the PBE
# functional (NC SR ONCVPSP v0.4) from pseudo-dojo.org.
# Accuracy "stringent", format PSML.
# - name: nc-sr-pbe-standard-0.4
# folder: nc-sr-pbe-standard-0.4
# file: nc-sr-04_pbe_standard_psml.tgz
# url: http://departments.icmab.es/leem/SIESTA_MATERIAL/tmp_PseudoDojo/
# home_page: http://www.pseudo-dojo.org/
# description: >-
# Norm-conserving scalar-relativistic pseudopotentials v0.4 for the PBE
# functional (NC SR ONCVPSP v0.4) from pseudo-dojo.org.
# Accuracy "standard", format PSML.
- name: nc-sr-pbe-standard-0.4
file: nc-sr-04_pbe_standard-psf.tgz
url: https://icmab.es/leem/SIESTA_MATERIAL/tmp_PseudoDojo
home_page: http://www.pseudo-dojo.org/
description: >-
Norm-conserving scalar-relativistic pseudopotentials v0.4 for the PBE
functional (NC SR ONCVPSP v0.4) from pseudo-dojo.org.
Accuracy "standard", format PSF.
# - name: nc-fr-pbe-stringent-0.4
# folder: nc-fr-pbe-stringent-0.4
# file: nc-fr-04_pbe_stringent_psml.tgz
# url: http://departments.icmab.es/leem/SIESTA_MATERIAL/tmp_PseudoDojo/
# home_page: http://www.pseudo-dojo.org/
# description: >-
# Norm-conserving fully-relativistic pseudopotentials v0.4 for the PBE
# functional (NC FR ONCVPSP v0.4) from pseudo-dojo.org.
# Accuracy "stringent", format PSML.
# - name: nc-fr-pbe-standard-0.4
# folder: nc-fr-pbe-standard-0.4
# file: nc-fr-04_pbe_standard_psml.tgz
# url: http://departments.icmab.es/leem/SIESTA_MATERIAL/tmp_PseudoDojo/
# home_page: http://www.pseudo-dojo.org/
# description: >-
# Norm-conserving fully-relativistic pseudopotentials v0.4 for the PBE
# functional (NC FR ONCVPSP v0.4) FRom pseudo-dojo.org.
# Accuracy "standard", format PSML.
- name: nc-fr-pbe-standard-0.4
file: nc-fr-04_pbe_standard-psf.tgz
url: https://icmab.es/leem/SIESTA_MATERIAL/tmp_PseudoDojo
home_page: http://www.pseudo-dojo.org/
description: >-
Norm-conserving fully-relativistic pseudopotentials v0.4 for the PBE
functional (NC FR ONCVPSP v0.4) FRom pseudo-dojo.org.
Accuracy "standard", format PSF.
#
# Pseudopotential packages -------------------------
#

siesta_psml_pps_version: "qm"
siesta_psml_pps_src: psml-files-{{ siesta_psml_pps_version }}
siesta_psml_pps_src_archive: "{{ siesta_psml_pps_src }}.tar.gz"
siesta_psml_pps_code_folder: "/tmp"
siesta_psml_pps_url: "https://gitlab.com/garalb/psml-files/-/archive/{{ siesta_psml_pps_version }}/{{ siesta_psml_pps_src_archive }}"

#
# Tests. Just a few
#
siesta_tests:
- h2o
- mno_ldau

siesta_lua_tests:
- lua_h2o
1 change: 1 addition & 0 deletions meta/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ galaxy_info:
versions:
- xenial
- bionic
- focal
galaxy_tags:
- ubuntu
- application
Expand Down
18 changes: 15 additions & 3 deletions molecule/default/molecule.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
dependency:
name: galaxy
# requirements_file: molecule/default/requirements.yml
requirements_file: molecule/default/requirements.yml
driver:
name: docker
platforms:
Expand All @@ -16,7 +16,19 @@ platforms:
LANG: "en_US.UTF-8"
provisioner:
name: ansible
# log: true # for debugging
playbooks:
converge: converge.yml
# Remove Ansible no_log settings for debugging
# log: true
config_options:
defaults:
# nicer stdout printing
stdout_callback: yaml
bin_ansible_callbacks: true
# add timing to tasks
callback_whitelist: profile_tasks
inventory:
hosts:
all:
vars:
ansible_python_interpreter: /usr/bin/python3
run_tests: true
2 changes: 2 additions & 0 deletions molecule/default/requirements.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
- role: marvel-nccr.libxc
version: v0.1.0
Loading