Yambo 2016

From HPC users
Jump to navigationJump to search

Introduction

YAMBO implements Many-Body Perturbation Theory (MBPT) methods (such as GW and BSE) and Time-Dependent Density Functional Theory (TDDFT), which allows for accurate prediction of fundamental properties as band gaps of semiconductors, band alignments, defect quasi-particle energies, optics and out-of-equilibrium properties of materials. ¹

Installed version(s)

The following versions are installed and currently available on environment hpc-env/8.3:

  • Yambo/5.0.2-intel-2019b

Loading / Using Yambo

To load the desired version of the module, use the module load command, e.g.

module load hpc-env/8.3
module load Yambo

Always remember: this command is case sensitive!


After loading the Yambo module, yambo and its associated executables (a2y, c2y, p2y, ypp) can be called from within every directory. But since the software package was installes with intel MPI to ensure parallel computing, you must call the desired executables with mpirun -np <threads> <executable> , for example like this:

 mpirun -np 4 yambo


Start Working with Yambo: Quick Tutorial

Our installed module version of Yambo on CARL differs slightly in how to call the specific commands. For this reason you can find a shortened and slightly modified tutorial which is based on the wikipages Bulk material: h-BN and Initialization from the yambo tutorial wiki.
On our tutorial version, we will focus on the commands and output files, and not much about the scientifical substance of the results. If you want to know more about that we highly recommend visiting the wiki pages that this tutorial is based on.


Bulk material: h-BN

Prerequisites

We will use the following modules, executables and files:

  • PWSCF input files and pseudopotentials for hBN bulk
  • the modules QuantumESPRESSO/6.6-intel-2019b and Yambo/5.0.2-intel-2019b on hpc-env/8.3
  • pw.x executable, version 5.0 or later
  • p2y and yambo executables

DFT calculations

Firstly, create a test folder and get the test files for this tutorial:

mkdir $HOME/yambo_test && cd $HOME/yambo_test
wget http://www.yambo-code.org/educational/tutorials/files/hBN.tar.gz
tar xvf hBN.tar.gz 

Load the modules and cd into the untarred directory

ml hpc-env/8.3
ml QuantumESPRESSO/6.6-intel-2019b   # It must be this version, not the 6.7 version based on intel-iompi. Otherwise, you will run into MPI errors
ml Yambo/5.0.2-intel-2019b

cd hBN/PWSCF

Now, run the SCF calculation to generate the ground-state charge density, occupations, Fermi level, and so on. For this step we need the executable pw.x which is part of QuantumESPRESSO and not callable from only the Yambo module. Also, since QuantumESPRESSO and Yambo are built on MPI, you always have to call the executables with mpirun

mpirun  pw.x < hBN_scf.in > hBN_scf.out   # can take up to 1 minute

Next run a non-SCF calculation to generate a set of Kohn-Sham eigenvalues and eigenvectors for both occupied and unoccupied states (100 bands):

mpirun -np 4  pw.x < hBN_nscf.in > hBN_nscf.out  # this step can be parallelized, here with 4 threads (-np 4)

Here we use a 6x6x2 grid giving 14 k-points, but denser grids should be used for checking convergence of Yambo runs.

Note the presence of the following flags in the input file:

wf_collect=.true.
force_symmorphic=.true.
diago_thr_init=5.0e-6,
diago_full_acc=.true.

which are needed for generating the Yambo databases accurately. Full explanations of these variables are given on the quantum-ESPRESSO input variables page.

After these two runs, you should have a hBN.save directory:

$ ls hBN.save
data-file.xml charge-density.dat gvectors.dat B.pz-vbc.UPF N.pz-vbc.UPF
K00001	K00002 .... 	K00035	K00036


Conversion to Yambo format

The PWscf bBN.save output is converted to the Yambo format using the p2y executable (pwscf to yambo), found in the yambo bin directory ($EBROOTYAMBO/bin - callable from everywhere). Enter hBN.save and launch p2y:

cd hBN.save
mpirun p2y

This output repeats some information about the system and generates a SAVE directory

ls SAVE
ns.db1  ns.wf  ns.kb_pp_pwscf
ns.wf_fragments_1_1 ...
ns.kb_pp_pwscf_fragment_1 ...

These files, with an n prefix, indicate that they are in netCDF format, and thus not human readable. However, they are perfectly transferable across different architectures. You can check that the databases contain the information you expect by launching Yambo using the -D option:

mpirun yambo -D

Initialization

Cite Yambo

The yambo team kindly asks everyone who uses yambo to cite theyr work about yambo as well, which we think is a very supportable request for reasons of scientific fairness.
Theyr quote:

"Cite us

It is scientifically fair to cite the two following articles in any publication based on results obtained with Yambo

  • Many-body perturbation theory calculations using the yambo code, Davide Sangalli and Andrea Ferretti and Henrique Miranda and Claudio Attaccalite and Ivan Marri and Elena Cannuccia and Pedro Miguel Melo and Margherita Marsili and Fulvio Paleari and Antimo Marrazzo and Gianluca Prandini and Pietro Bonf\`a and Michael O Atambo and Fabio Affinito and Maurizia Palummo and Alejandro Molina Sanchez and Conor Hogan and Myrta Gr\xFCning and Daniele Varsano and Andrea Marini, Journal of Physics: Condensed Matter 31, 325902 (2019).
  • Yambo: an ab initio tool for excited state calculations, Andrea Marini, Conor Hogan, Myrta Grüning, Daniele Varsano, Comp. Phys. Comm. 144, 180 (2009).

Check the Yambo researcher ID page for citation information." ²

Documentation

The developers created a very elaborate wiki including tutorials for learning and using Yambo. You you can find the wiki entry page here.
You can find the softwares main page here