etmc / tmLQCD

tmLQCD is a freely available software suite providing a set of tools to be used in lattice QCD simulations. This is mainly a HMC implementation (including PHMC and RHMC) for Wilson, Wilson Clover and Wilson twisted mass fermions and inverter for different versions of the Dirac operator. The code is fully parallelised and ships with optimisations for various modern architectures, such as commodity PC clusters and the Blue Gene family.
http://www.itkp.uni-bonn.de/~urbach/software.html
GNU General Public License v3.0
32 stars 47 forks source link

QPhiX defaults to relative residual, need to adjust interface #405

Closed kostrzewa closed 6 years ago

kostrzewa commented 6 years ago

Since the MG mods have been merged into QPhiX, all solvers have been equipped with an additional flag to switch between absolute and relative residual, the latter being the default. In the QPhiX interface, we currently calculate the appropriate absolute residual to fulfil whatever criterion has been set in the tmLQCD input file, but since the changes in QPhiX are new, we don't explicitly set the absolute residual flag.

As a first step, we should explicitly pass the absolute residual flag in all QPhiX solver calls or, if more time is available to implement the changes, we should switch to let QPhiX handle this directly as it is now supported.

kostrzewa commented 6 years ago

Okay, it seems that the merges and developments on QPhiX have introduced a bug somewhere, which causes NaNs with all single flavour monomials. At least the NaN appears from iteration one and the initial |r|^2 is zero, so it's pretty clear that the relative residual mechanism doesn't work properly. The first step will be to explicitly do absolute residual.

kostrzewa commented 6 years ago

Okay, the problem does not seem to go away by doing that... damn.

kostrzewa commented 6 years ago

Ah, maybe the problem is in my test. tmLQCD itself also nans...

kostrzewa commented 6 years ago

Okay, luckily the issue was simply that I had no timescale defined for the monomials under test which meant that there were no valid pseudofermion fields..

kostrzewa commented 6 years ago

Okay, I think I've worked out all the kinks. So, QPhiX was doing RELATIVE by default and the interface was built with that in mind already, which is god news. In #407 I make this more explicit. This can be closed for now.