make taper warnings consistent between Kokkos and CPU and avoid multiple outputs
This commit is contained in:
@ -385,13 +385,13 @@ void PairReaxFFKokkos<DeviceType>::init_md()
|
||||
swb = api->control->nonb_cut;
|
||||
enobondsflag = api->control->enobondsflag;
|
||||
|
||||
if (fabs(swa) > 0.01)
|
||||
error->warning(FLERR,"Warning: non-zero lower Taper-radius cutoff");
|
||||
if ((fabs(swa) > 0.01) && (comm->me == 0))
|
||||
error->warning(FLERR, "Non-zero lower Taper-radius cutoff");
|
||||
|
||||
if (swb < 0)
|
||||
error->one(FLERR,"Negative upper Taper-radius cutoff");
|
||||
else if (swb < 5)
|
||||
error->one(FLERR,"Warning: very low Taper-radius cutoff: {}\n", swb);
|
||||
if (swb < 0.0) {
|
||||
error->all(FLERR,"Negative upper Taper-radius cutoff");
|
||||
} else if ((swb < 5.0) && (comm->me ==0))
|
||||
error->warning(FLERR,"Very low Taper-radius cutoff: {}\n", swb);
|
||||
|
||||
d1 = swb - swa;
|
||||
d7 = powint(d1,7);
|
||||
|
||||
@ -80,15 +80,14 @@ namespace ReaxFF {
|
||||
swa = control->nonb_low;
|
||||
swb = control->nonb_cut;
|
||||
|
||||
if (fabs(swa) > 0.01 && control->me == 0)
|
||||
if ((fabs(swa) > 0.01) && (control->me == 0))
|
||||
error->warning(FLERR, "Non-zero lower Taper-radius cutoff");
|
||||
|
||||
if (swb < 0) {
|
||||
if (swb < 0.0) {
|
||||
error->all(FLERR,"Negative upper Taper-radius cutoff");
|
||||
}
|
||||
else if (swb < 5 && control->me == 0)
|
||||
error->warning(FLERR,fmt::format("Warning: very low Taper-radius cutoff: "
|
||||
"{}\n", swb));
|
||||
} else if ((swb < 5.0) && (control->me == 0))
|
||||
error->warning(FLERR,fmt::format("Very low Taper-radius cutoff: {}\n", swb));
|
||||
|
||||
d1 = swb - swa;
|
||||
d7 = pow(d1, 7.0);
|
||||
swa2 = SQR(swa);
|
||||
|
||||
Reference in New Issue
Block a user