1
0
mirror of https://github.com/paboyle/Grid.git synced 2024-11-09 23:45:36 +00:00

Pre-release cleanup in progress

This commit is contained in:
Michael Marshall 2019-04-29 22:18:29 +01:00
parent 4203105104
commit d74d443d1b
2 changed files with 16 additions and 12 deletions

View File

@ -75,7 +75,7 @@ struct LanczosParameters: Serializable {
int, MaxIt,
//int, MinRes,
double, resid,
std::string, Log) // Any non-empty string will enable logging
int, IRLLog)
LanczosParameters() = default;
template <class ReaderClass> LanczosParameters(Reader<ReaderClass>& Reader){read(Reader,"Lanczos",*this);}
};
@ -208,10 +208,6 @@ void TLapEvec<GImpl>::execute(void)
const LanczosParameters &LPar{par().Lanczos};
const int &nvec{LPar.Nvec};
// Enable IRL logging if requested
if( LPar.Log.size() > 0 )
GridLogIRL.Active(1);
//const bool exact_distillation{TI==Nt && LI==nvec};
//const bool full_tdil{TI==Nt};
//const int &Nt_inv{full_tdil ? 1 : TI};
@ -224,6 +220,11 @@ void TLapEvec<GImpl>::execute(void)
//else
//assert(nnoise>1);
// Disable IRL logging if requested
LOG(Message) << "IRLLog=" << LPar.IRLLog << std::endl;
const int PreviousIRLLogState{GridLogIRL.isActive()};
GridLogIRL.Active( LPar.IRLLog == 0 ? 0 : 1 );
auto &Umu = envGet(GaugeField, par().gauge);
envGetTmp(GaugeField, Umu_smear);
@ -302,6 +303,8 @@ void TLapEvec<GImpl>::execute(void)
sEigenPackName.append(".");
sEigenPackName.append(std::to_string(vm().getTrajectory()));
eig4d.write(sEigenPackName,false);
GridLogIRL.Active( PreviousIRLLogState );
}
END_MODULE_NAMESPACE

View File

@ -114,6 +114,7 @@ void test_LapEvec(Application &application)
p.Lanczos.Np = 2;
p.Lanczos.MaxIt = 1000;
p.Lanczos.resid = 1e-2;
p.Lanczos.IRLLog = 0;
application.createModule<MDistil::LapEvec>("LapEvec",p);
}
@ -190,9 +191,9 @@ void test_MultiPerambulators(Application &application)
MDistil::DistilVectors::Par DistilVecPar;
DistilVecPar.noise="Peramb5_noise";
DistilVecPar.perambulator="Peramb2";
DistilVecPar.eigenPack="LapEvec";
DistilVecPar.lapevec ="LapEvec";
DistilVecPar.tsrc = 0;
DistilVecPar.nnoise = 1;
//DistilVecPar.nnoise = 1;
DistilVecPar.LI=2;
DistilVecPar.SI=4;
DistilVecPar.TI=8;
@ -266,9 +267,9 @@ void test_DistilVectors(Application &application)
DistilVecPar.noise="Peramb_noise";
//DistilVecPar.perambulator="Peramb_perambulator_light";
DistilVecPar.perambulator="Peramb";
DistilVecPar.eigenPack="LapEvec";
DistilVecPar.lapevec="LapEvec";
DistilVecPar.tsrc = 0;
DistilVecPar.nnoise = 1;
//DistilVecPar.nnoise = 1;
DistilVecPar.LI=5;
DistilVecPar.SI=4;
DistilVecPar.TI=8;
@ -313,9 +314,9 @@ void test_DistilVectorsS(Application &application)
DistilVecPar.noise="PerambS_noise";
//DistilVecPar.perambulator="PerambS_perambulator_light";
DistilVecPar.perambulator="PerambS";
DistilVecPar.eigenPack="LapEvec";
DistilVecPar.lapevec="LapEvec";
DistilVecPar.tsrc = 0;
DistilVecPar.nnoise = 1;
//DistilVecPar.nnoise = 1;
DistilVecPar.LI=5;
DistilVecPar.SI=4;
DistilVecPar.TI=32;
@ -1203,7 +1204,7 @@ int main(int argc, char *argv[])
LOG(Message) << "====== XML creation for test " << iTestNum << " complete ======" << std::endl;
// execution
application.saveParameterFile("test_hadrons_distil.xml");
application.saveParameterFile("test_distil.xml");
application.run();
// epilogue