1
0
mirror of https://github.com/paboyle/Grid.git synced 2025-04-07 04:35:56 +01:00

added debug output, perambulators now agree up to 8 digits

This commit is contained in:
ferben 2019-01-29 16:24:59 +00:00
parent d8831fe925
commit 67a3d7aeed
2 changed files with 22 additions and 1 deletions
Hadrons/Modules/MDistil

@ -257,7 +257,7 @@ void TLapEvec<GImpl>::execute(void)
//envGetTmp(GaugeField, Umu);
auto &Umu = envGet(GaugeField, par().gauge);
envGetTmp(GaugeField, Umu_smear);
if((0)) {
if((1)) {
const std::vector<int> seeds({1, 2, 3, 4, 5});
GridParallelRNG pRNG4d(gridHD);
pRNG4d.SeedFixedIntegers(seeds);
@ -381,6 +381,7 @@ void TLapEvec<GImpl>::execute(void)
for (int i=0;i<LPar.Nvec;i++){
std::cout << "Inserting Timeslice " << t << " into vector " << i << std::endl;
InsertSliceLocal(eig[t].evec[i],eig4d.evec[i],0,t,3);
eig4d.eval[i] = eig[0].eval[i];
}
}

@ -163,6 +163,25 @@ void TPerambLight<FImpl>::execute(void)
std::cout << GridLogMessage << "now hot config" << std::endl;
SU<Nc>::HotConfiguration(pRNG4d, Umu);
std::cout << GridLogMessage << "hot cfg done." << std::endl;
// Set up the SAME gauge field on every time plane
// int Nt = grid4d->gDimensions()[Tdir];
Grid_unquiesce_nodes();
auto Usft = Umu;
Lattice<iScalar<vInteger> > coor(grid4d);
LatticeCoordinate(coor,Tdir);
for(int t=1;t<par().Nt;t++){
// t=1
// Umu Usft
// 0,1,2,3,4,5,6,7 -> 7,0,1,2,3,4,5,6 t=1
// 0,0,2,3,4,5,6,7 6,7,0,1,2,3,4,5 t=2
// 0,0,0,3,4,5,6,7 5,6,7,0,1,2,3,4 t=3
//...
Usft = Cshift(Usft,Tdir,-1);
Umu = where(coor==t,Usft,Umu);
}
} else {
std::string fileName( "/home/dp008/dp008/dc-rich6/Scripts/ConfigsDeflQED/ckpoint_lat.3000" );
std::cout << GridLogMessage << "Loading NERSC configuration from '" << fileName << "'" << std::endl;
@ -285,6 +304,7 @@ void TPerambLight<FImpl>::execute(void)
for (int ivec = 0; ivec < nvec; ivec++) {
ExtractSliceLocal(evec3d,epack.evec[ivec],0,t,3);
pokeSpin(perambulator(t, ivec, dk, inoise,dt,ds),innerProduct(evec3d, result_3d),is);
std::cout << "perambulator(t, ivec, dk, inoise,dt,ds)(is) = (" << t << "," << ivec << "," << dk << "," << inoise << "," << dt << "," << ds << ")(" << is << ") = " << perambulator(t, ivec, dk, inoise,dt,ds)()(is)() << std::endl;
}
}
}