Note 2025: This is a reupload of my work in the state it was in when I changed jobs in June 2015 — the old link found in some publications referencing my university account is no longer working. This is likely out of date, please contact whoever has referenced LibHadronAnalysis. I am not supporting this.
This library provides routines for computing Baryon Disribution Amplitudes (BDA), Meson Distribution Amplitudes (MDA), and Baryon Spectra (Light and Heavy). It was written to replace the (Regensburg-)Chroma-internal implementation, which was very slow. The corresponding functions in Chroma are
mda_prop(),bdacomp(), andbdaopen()inchroma/lib/meas/hadron/mda_prop_w.h,chroma/lib/meas/hadron/bdacomp_w.h, andchroma/lib/meas/hadron/bdaopen_w.h
for the distribution amplitudes and
barhqlq_qcdsf()andbarhqsqlq_qcdsf()inbarhqlq_qcdsf_w.handbarhqsqlq_qcdsf_w.h
for the baryon spectra.
- Simon Heybrock, University of Regensburg, January/February 2015
Advisory:
- Benjamin Gläßle, University of Regensburg (Chroma, general)
- Fabian Hutzler, University of Regensburg (MDA and BDA)
- Paula Pérez, University of Regensburg (Heavy and Light Baryon Spectra)
- double precision
- both icc and gcc seem to manage decent auto-vectorization (due to according changes in the C++ code)
- optional: Chroma compatible interface for direct calls to the library from Chroma
- optional: testing with Google Test
With icc on processors with AVX support, we observe a speedup of 5x or more with respect to the QDP++-based implementation in (Regensburg-)Chroma.
-
Dependencies:
cmake- MPI
- on the MIC: Intel Compiler
- optional: Chroma to build the interface
- optional: Google Test
- optional: QDP++ for all tests
- optional: Chroma for some tests
- The C++ compiler must support C++11 to some extent, for example gcc 4.6 or later should be fine.
-
Get the code:
git clone git@rqcd.ur.de:hes10653/lib-hadron-analysis- Set compiler:
export CXX=mpicxxor, when compiling for the MIC, the Intel Compiler:
export CXX=mpiicpc- We recommend an out-of-source build, run
cmakewith (or without) optional flags according to your requirements:
mkdir build && cd build
cmake \
-DCMAKE_INSTALL_PREFIX:PATH=/install/path/for/this/library \
-DQDPXX:PATH=/path/to/qdpxx/root/directory \
-DCHROMA_SOURCE:PATH=/path/to/chroma_source/root/directory \
../lib-hadron-analysis- Add `-DBUILD_MIC_VERSION=on` to build for the MIC.
- Add `-DBUILD_OPENMP_VERSION=off` to disable compilation with OpenMP.
- Add `-DGTEST:PATH=/path/to/googletest/root/directory` if you wish to build the tests.
- Add `-DCHROMA:PATH=/path/to/chroma/root/directory` to build tests of the Chroma interface. When linking to Chroma for the test programs, make sure to use a Chroma version that is **not** built with this library, otherwise the test would compare the result to itself.
- The recommended way to build this library with Chroma interface is to use `-DQDPXX` and `-DCHROMA_SOURCE`.
- Available targets are:
make # builds intermediate libraries and the library with Chroma interface (if possible)
make test # builds all tests (apart from the Chroma-dependent ones), needs gtest and QDP++
make test-chroma # builds tests for the Chroma interface- The default target builds the Chroma interface if Chroma was found, you can then install it with:
make install-
If you are using a recent version of the "Regensburg" Chroma code, chances are that the library has already been included, the only thing you might need to do is to run the Chroma
configurewith the option--with-lib-hadron-analysis=/install/path/of/lib-hadron-analysisand (re-)compile.If this is not the case, to use this library in your Chroma program use, e.g., for an MDA (function signature chosen identical to
mda_prop()inchroma/lib/meas/hadron/mda_prop_w.h):
#include "chroma_meson_distribution_amplitude.h"
LibHadronAnalysis::MDA::compute(
multi2d<MesonDA>& mdaprop,
const LatticePropagator& quark_propagator_1,
const LatticePropagator& quark_propagator_2,
const SftMom& phases,
int t0);Similarly for an BDA or baryon spectrum, see the corresponding header files provided by this library for details: - MDA: chroma_meson_distribution_amplitude.h - BDA: chroma_baryon_distribution_amplitude.h - Baryon spectrum: chroma_baryon_spectrum.h