QUDA
1.0.0
|
#include <invert_quda.h>
Public Member Functions | |
IncEigCG (DiracMatrix &mat, DiracMatrix &matSloppy, DiracMatrix &matPrecon, SolverParam ¶m, TimeProfile &profile) | |
virtual | ~IncEigCG () |
void | increment (ColorSpinorField &V, int nev) |
Expands deflation space. More... | |
void | RestartVT (const double beta, const double rho) |
void | UpdateVm (ColorSpinorField &res, double beta, double sqrtr2) |
int | eigCGsolve (ColorSpinorField &out, ColorSpinorField &in) |
int | initCGsolve (ColorSpinorField &out, ColorSpinorField &in) |
void | operator() (ColorSpinorField &out, ColorSpinorField &in) |
![]() | |
Solver (SolverParam ¶m, TimeProfile &profile) | |
virtual | ~Solver () |
virtual void | blocksolve (ColorSpinorField &out, ColorSpinorField &in) |
bool | convergence (double r2, double hq2, double r2_tol, double hq_tol) |
bool | convergenceHQ (double r2, double hq2, double r2_tol, double hq_tol) |
Test for HQ solver convergence – ignore L2 residual. More... | |
bool | convergenceL2 (double r2, double hq2, double r2_tol, double hq_tol) |
Test for L2 solver convergence – ignore HQ residual. More... | |
void | PrintStats (const char *name, int k, double r2, double b2, double hq2) |
Prints out the running statistics of the solver (requires a verbosity of QUDA_VERBOSE) More... | |
void | PrintSummary (const char *name, int k, double r2, double b2, double r2_tol, double hq_tol) |
Prints out the summary of the solver convergence (requires a verbosity of QUDA_SUMMARIZE). Assumes SolverParam.true_res and SolverParam.true_res_hq has been set. More... | |
void | constructDeflationSpace (const ColorSpinorField &meta, const DiracMatrix &mat, bool svd) |
Constructs the deflation space. More... | |
virtual double | flops () const |
Private Attributes | |
DiracMatrix & | mat |
DiracMatrix & | matSloppy |
DiracMatrix & | matPrecon |
Solver * | K |
SolverParam | Kparam |
ColorSpinorFieldSet * | Vm |
ColorSpinorField * | rp |
ColorSpinorField * | yp |
residual vector More... | |
ColorSpinorField * | p |
high precision accumulator More... | |
ColorSpinorField * | Ap |
ColorSpinorField * | tmpp |
ColorSpinorField * | Az |
temporary for mat-vec More... | |
ColorSpinorField * | r_pre |
ColorSpinorField * | p_pre |
residual passed to preconditioner More... | |
EigCGArgs * | eigcg_args |
preconditioner result More... | |
TimeProfile & | profile |
bool | init |
Additional Inherited Members | |
![]() | |
static Solver * | create (SolverParam ¶m, DiracMatrix &mat, DiracMatrix &matSloppy, DiracMatrix &matPrecon, TimeProfile &profile) |
static double | stopping (double tol, double b2, QudaResidualType residual_type) |
Set the solver L2 stopping condition. More... | |
![]() | |
EigenSolver * | eig_solve |
bool | deflate_init = false |
std::vector< ColorSpinorField * > | defl_tmp1 |
std::vector< ColorSpinorField * > | defl_tmp2 |
![]() | |
SolverParam & | param |
TimeProfile & | profile |
int | node_parity |
Definition at line 1225 of file invert_quda.h.
quda::IncEigCG::IncEigCG | ( | DiracMatrix & | mat, |
DiracMatrix & | matSloppy, | ||
DiracMatrix & | matPrecon, | ||
SolverParam & | param, | ||
TimeProfile & | profile | ||
) |
Definition at line 252 of file inv_eigcg_quda.cpp.
References quda::SolverParam::deflation_grid, errorQuda, quda::fillEigCGInnerSolverParam(), quda::fillInitCGSolverParam(), quda::SolverParam::inv_type, quda::SolverParam::inv_type_precondition, K, Kparam, quda::SolverParam::m, quda::SolverParam::nev, printfQuda, QUDA_CG_INVERTER, QUDA_EIGCG_INVERTER, QUDA_INC_EIGCG_INVERTER, QUDA_INVALID_INVERTER, QUDA_MR_INVERTER, QUDA_SD_INVERTER, and quda::SolverParam::rhs_idx.
|
virtual |
int quda::IncEigCG::eigCGsolve | ( | ColorSpinorField & | out, |
ColorSpinorField & | in | ||
) |
Definition at line 381 of file inv_eigcg_quda.cpp.
References Ap, quda::blas::axpyNorm(), quda::blas::axpyZpbx(), Az, checkLocation, commGlobalReductionSet(), quda::ColorSpinorParam::composite_dim, quda::Solver::convergence(), quda::blas::copy(), quda::ColorSpinorParam::create, quda::ColorSpinorField::Create(), csParam, eigcg_args, errorQuda, quda::blas::flops, quda::DiracMatrix::flops(), quda::SolverParam::gflops, quda::EigCGArgs::global_stop, quda::blas::HeavyQuarkResidualNorm(), init, quda::SolverParam::inv_type, quda::ColorSpinorParam::is_composite, quda::SolverParam::iter, quda::EigCGArgs::k, K, Kparam, quda::TimeProfile::Last(), quda::SolverParam::m, matSloppy, quda::SolverParam::maxiter, quda::SolverParam::nev, quda::blas::norm2(), p, p_pre, quda::Solver::param, quda::LatticeField::Precision(), quda::SolverParam::precision_precondition, quda::SolverParam::precision_ritz, quda::SolverParam::precision_sloppy, printfQuda, quda::Solver::PrintStats(), quda::Solver::PrintSummary(), profile, QUDA_COPY_FIELD_CREATE, QUDA_CUDA_FIELD_LOCATION, QUDA_DOUBLE_PRECISION, QUDA_HEAVY_QUARK_RESIDUAL, QUDA_INC_EIGCG_INVERTER, quda::QUDA_PROFILE_COMPUTE, quda::QUDA_PROFILE_EPILOGUE, quda::QUDA_PROFILE_FREE, quda::QUDA_PROFILE_INIT, quda::QUDA_PROFILE_PREAMBLE, QUDA_ZERO_FIELD_CREATE, r_pre, quda::blas::reDotProduct(), quda::EigCGArgs::ResetArgs(), quda::SolverParam::residual_type, quda::EigCGArgs::restarts, rp, quda::EigCGArgs::run_residual_correction, quda::SolverParam::secs, quda::EigCGArgs::SetLanczos(), quda::ColorSpinorParam::setPrecision(), quda::sqrt(), quda::Solver::stopping(), tmp, tmpp, quda::SolverParam::tol, quda::SolverParam::tol_hq, quda::SolverParam::true_res, quda::SolverParam::true_res_hq, UpdateVm(), quda::EigCGArgs::V2k, Vm, warningQuda, quda::blas::xmyNorm(), quda::blas::xpy(), yp, and quda::blas::zero().
Referenced by operator()().
void quda::IncEigCG::increment | ( | ColorSpinorField & | V, |
int | nev | ||
) |
Expands deflation space.
V | Composite field container of new eigenvectors |
nev | number of vectors to load |
int quda::IncEigCG::initCGsolve | ( | ColorSpinorField & | out, |
ColorSpinorField & | in | ||
) |
Definition at line 583 of file inv_eigcg_quda.cpp.
References quda::ColorSpinorParam::create, quda::ColorSpinorField::Create(), csParam, quda::deflated_solver::defl, quda::SolverParam::deflation_op, getVerbosity(), quda::SolverParam::gflops, quda::SolverParam::inc_tol, quda::SolverParam::iter, K, Kparam, mat, matPrecon, quda::SolverParam::max_restart_num, quda::Solver::param, quda::SolverParam::precision, quda::SolverParam::precision_ritz, printfQuda, profile, QUDA_VERBOSE, QUDA_ZERO_FIELD_CREATE, rp, quda::SolverParam::secs, quda::ColorSpinorParam::setPrecision(), tmp2, quda::SolverParam::tol, quda::SolverParam::tol_restart, and quda::blas::xpay().
Referenced by operator()().
|
virtual |
Implements quda::Solver.
Definition at line 656 of file inv_eigcg_quda.cpp.
References quda::ColorSpinorParam::create, quda::ColorSpinorField::Create(), csParam, quda::deflated_solver::defl, quda::SolverParam::deflation_grid, quda::SolverParam::deflation_op, eigcg_args, quda::SolverParam::eigcg_max_restarts, eigCGsolve(), quda::SolverParam::eigenval_tol, errorQuda, getVerbosity(), quda::blas::HeavyQuarkResidualNorm(), quda::SolverParam::inc_tol, quda::Deflation::increment(), initCGsolve(), quda::Deflation::is_complete(), quda::SolverParam::iter, K, Kparam, mat, matPrecon, matSloppy, quda::max_eigcg_cycles, quda::SolverParam::nev, quda::norm2(), quda::Solver::param, quda::SolverParam::precision, quda::SolverParam::precision_sloppy, printfQuda, quda::Solver::PrintSummary(), profile, QUDA_VERBOSE, QUDA_ZERO_FIELD_CREATE, quda::Deflation::reduce(), quda::EigCGArgs::restarts, quda::SolverParam::rhs_idx, rp, quda::EigCGArgs::run_residual_correction, quda::ColorSpinorParam::setPrecision(), quda::Deflation::size(), quda::sqrt(), quda::SolverParam::tol, quda::SolverParam::tol_hq, quda::SolverParam::true_res, quda::SolverParam::true_res_hq, quda::Deflation::verify(), Vm, warningQuda, quda::blas::xmyNorm(), quda::blas::xpy(), and quda::blas::zero().
void quda::IncEigCG::RestartVT | ( | const double | beta, |
const double | rho | ||
) |
Definition at line 316 of file inv_eigcg_quda.cpp.
References Ap, Az, quda::blas::caxpy(), quda::ColorSpinorField::Component(), quda::ColorSpinorField::Components(), quda::blas::copy(), eigcg_args, errorQuda, quda::SolverParam::extlib_type, quda::EigCGArgs::k, quda::EigCGArgs::m, omega, quda::Solver::param, quda::LatticeField::Precision(), QUDA_EIGEN_EXTLIB, QUDA_MAGMA_EXTLIB, quda::EigCGArgs::RestartLanczos(), quda::EigCGArgs::ritzVecs, quda::EigCGArgs::V2k, Vm, quda::blas::xpay(), and quda::blas::zero().
Referenced by UpdateVm().
void quda::IncEigCG::UpdateVm | ( | ColorSpinorField & | res, |
double | beta, | ||
double | sqrtr2 | ||
) |
Definition at line 357 of file inv_eigcg_quda.cpp.
References Ap, quda::blas::ax(), Az, quda::ColorSpinorField::Component(), quda::blas::copy(), eigcg_args, quda::EigCGArgs::id, quda::SolverParam::m, quda::Solver::param, quda::EigCGArgs::ResetSearchIdx(), RestartVT(), quda::EigCGArgs::run_residual_correction, and Vm.
Referenced by eigCGsolve().
|
private |
Definition at line 1240 of file invert_quda.h.
Referenced by eigCGsolve(), RestartVT(), UpdateVm(), and ~IncEigCG().
|
private |
temporary for mat-vec
Definition at line 1242 of file invert_quda.h.
Referenced by eigCGsolve(), RestartVT(), UpdateVm(), and ~IncEigCG().
|
private |
preconditioner result
Definition at line 1246 of file invert_quda.h.
Referenced by eigCGsolve(), operator()(), RestartVT(), UpdateVm(), and ~IncEigCG().
|
private |
Definition at line 1250 of file invert_quda.h.
Referenced by eigCGsolve(), and ~IncEigCG().
|
private |
Definition at line 1232 of file invert_quda.h.
Referenced by eigCGsolve(), IncEigCG(), initCGsolve(), operator()(), and ~IncEigCG().
|
private |
Definition at line 1233 of file invert_quda.h.
Referenced by eigCGsolve(), IncEigCG(), initCGsolve(), and operator()().
|
private |
Definition at line 1228 of file invert_quda.h.
Referenced by initCGsolve(), and operator()().
|
private |
Definition at line 1230 of file invert_quda.h.
Referenced by initCGsolve(), and operator()().
|
private |
Definition at line 1229 of file invert_quda.h.
Referenced by eigCGsolve(), and operator()().
|
private |
high precision accumulator
Definition at line 1239 of file invert_quda.h.
Referenced by eigCGsolve(), and ~IncEigCG().
|
private |
residual passed to preconditioner
Definition at line 1244 of file invert_quda.h.
Referenced by eigCGsolve(), and ~IncEigCG().
|
private |
Definition at line 1248 of file invert_quda.h.
Referenced by eigCGsolve(), initCGsolve(), and operator()().
|
private |
Definition at line 1243 of file invert_quda.h.
Referenced by eigCGsolve(), and ~IncEigCG().
|
private |
Definition at line 1237 of file invert_quda.h.
Referenced by eigCGsolve(), initCGsolve(), operator()(), and ~IncEigCG().
|
private |
Definition at line 1241 of file invert_quda.h.
Referenced by eigCGsolve(), and ~IncEigCG().
|
private |
Definition at line 1235 of file invert_quda.h.
Referenced by eigCGsolve(), operator()(), RestartVT(), UpdateVm(), and ~IncEigCG().
|
private |
residual vector
Definition at line 1238 of file invert_quda.h.
Referenced by eigCGsolve(), and ~IncEigCG().