Skip to content
Snippets Groups Projects
Commit b6c39cf6 authored by Giovanni Bussi's avatar Giovanni Bussi
Browse files

Merge branch 'v2.4'

# Conflicts:
#	regtest/basic/rt-maxent-4/config
#	regtest/basic/rt-maxent-5/config
#	regtest/basic/rt63c-mpi/config
#	src/cltools/Driver.cpp
parents 0058162c 2ad83022
No related branches found
No related tags found
No related merge requests found
...@@ -233,3 +233,6 @@ For developers: ...@@ -233,3 +233,6 @@ For developers:
For users: For users:
- Fixed a problem leading to NaN derivatives of \ref switchingfunction `Q` when distance between two atoms is large. - Fixed a problem leading to NaN derivatives of \ref switchingfunction `Q` when distance between two atoms is large.
For developers:
- Fixed small issue in debug options of \ref driver (see \issue{245}).
mpiprocs=4 mpiprocs=4
type=driver type=driver
# this is to test a different name # this is to test a different name
arg="--plumed plumed.dat --timestep=0.005 --initial-step=1 --ixyz trajectory.xyz --dump-forces ff --pdb test.pdb --debug-dd" arg="--plumed plumed.dat --timestep=0.005 --initial-step=1 --ixyz trajectory.xyz --dump-forces ff --pdb test.pdb --debug-dd yes"
mpiprocs=4 mpiprocs=4
type=driver type=driver
# this is to test a different name # this is to test a different name
arg="--plumed plumed.dat --timestep=0.005 --initial-step=1 --ixyz trajectory.xyz --dump-forces ff --pdb test.pdb --debug-pd" arg="--plumed plumed.dat --timestep=0.005 --initial-step=1 --ixyz trajectory.xyz --dump-forces ff --pdb test.pdb --debug-pd yes"
mpiprocs=6 mpiprocs=6
type=driver type=driver
arg="--plumed plumed.dat --mf_xtc traj.xtc --dump-forces forces --dump-forces-fmt=%8.4f --debug-dd" arg="--plumed plumed.dat --mf_xtc traj.xtc --dump-forces forces --dump-forces-fmt=%8.4f --debug-dd yes"
mpiprocs=6 mpiprocs=6
type=driver type=driver
arg="--plumed plumed.dat --mf_xtc traj.xtc --dump-forces forces --multi 3 --dump-forces-fmt=%8.4f --debug-dd" arg="--plumed plumed.dat --mf_xtc traj.xtc --dump-forces forces --multi 3 --dump-forces-fmt=%8.4f --debug-dd yes"
mpiprocs=4 mpiprocs=4
type=driver type=driver
# this is to test a different name # this is to test a different name
arg="--plumed=plumed.dat --timestep=0.05 --ixyz trajectory.xyz --dump-forces ff --debug-pd" arg="--plumed=plumed.dat --timestep=0.05 --ixyz trajectory.xyz --dump-forces ff --debug-pd yes"
extra_files="../../trajectories/trajectory.xyz" extra_files="../../trajectories/trajectory.xyz"
mpiprocs=6 mpiprocs=6
type=driver type=driver
arg="--plumed=plumed.dat --timestep=0.05 --ixyz trajectory.xyz --dump-forces ff --pdb test.pdb --multi 3 --debug-dd --debug-grex 6 --debug-grex-log log.grex --initial-step 3" arg="--plumed=plumed.dat --timestep=0.05 --ixyz trajectory.xyz --dump-forces ff --pdb test.pdb --multi 3 --debug-dd yes --debug-grex 6 --debug-grex-log log.grex --initial-step 3"
mpiprocs=4 mpiprocs=4
type=driver type=driver
# this is to test a different name # this is to test a different name
arg="--plumed=plumed.dat --timestep=0.05 --ixyz trajectory.xyz --dump-forces ff --pdb test.pdb --debug-dd" arg="--debug-dd yes --plumed=plumed.dat --timestep=0.05 --ixyz trajectory.xyz --dump-forces ff --pdb test.pdb"
extra_files="../../trajectories/trajectory.xyz" extra_files="../../trajectories/trajectory.xyz"
mpiprocs=4 mpiprocs=4
type=driver type=driver
# this is to test a different name # this is to test a different name
arg="--plumed=plumed.dat --timestep=0.05 --ixyz trajectory.xyz --dump-forces ff --pdb test.pdb --debug-dd" arg="--plumed=plumed.dat --timestep=0.05 --ixyz trajectory.xyz --dump-forces ff --pdb test.pdb --debug-dd yes"
extra_files="../../trajectories/trajectory.xyz" extra_files="../../trajectories/trajectory.xyz"
export PLUMED_ASYNC_SHARE=no export PLUMED_ASYNC_SHARE=no
...@@ -2,4 +2,4 @@ mpiprocs=6 ...@@ -2,4 +2,4 @@ mpiprocs=6
type=driver type=driver
# this is to test a different name # this is to test a different name
arg="--plumed=plumed.dat --timestep=0.05 --ixyz trajectory.xyz --dump-forces ff --pdb test.pdb --multi 3 arg="--plumed=plumed.dat --timestep=0.05 --ixyz trajectory.xyz --dump-forces ff --pdb test.pdb --multi 3
--debug-dd --debug-grex 2 --debug-grex-log log.grex" --debug-dd yes --debug-grex 2 --debug-grex-log log.grex"
...@@ -2,4 +2,4 @@ mpiprocs=6 ...@@ -2,4 +2,4 @@ mpiprocs=6
type=driver type=driver
# this is to test a different name # this is to test a different name
arg="--plumed=plumed.dat --timestep=0.05 --ixyz trajectory.xyz --dump-forces ff --pdb test.pdb --multi 3 arg="--plumed=plumed.dat --timestep=0.05 --ixyz trajectory.xyz --dump-forces ff --pdb test.pdb --multi 3
--debug-dd --debug-grex 2 --debug-grex-log log.grex" --debug-dd yes --debug-grex 2 --debug-grex-log log.grex"
...@@ -2,4 +2,4 @@ mpiprocs=6 ...@@ -2,4 +2,4 @@ mpiprocs=6
type=driver type=driver
# this is to test a different name # this is to test a different name
arg="--plumed=plumed.dat --timestep=0.05 --ixyz trajectory.xyz --dump-forces ff --multi 3 arg="--plumed=plumed.dat --timestep=0.05 --ixyz trajectory.xyz --dump-forces ff --multi 3
--debug-dd --debug-grex 2 --debug-grex-log log.grex" --debug-dd yes --debug-grex 2 --debug-grex-log log.grex"
type=driver type=driver
mpiprocs=2 mpiprocs=2
arg="--plumed plumed.dat --trajectory-stride 10 --timestep 0.005 --igro helix.input.gro --dump-forces ff --dump-full-virial --debug-dd" arg="--plumed plumed.dat --trajectory-stride 10 --timestep 0.005 --igro helix.input.gro --dump-forces ff --dump-full-virial --debug-dd yes"
type=driver type=driver
mpiprocs=2 mpiprocs=2
arg="--plumed plumed.dat --trajectory-stride 10 --timestep 0.005 --igro helix.input.gro --dump-forces ff --dump-full-virial --dump-forces-fmt=%7.4f --debug-dd" arg="--plumed plumed.dat --trajectory-stride 10 --timestep 0.005 --igro helix.input.gro --dump-forces ff --dump-full-virial --dump-forces-fmt=%7.4f --debug-dd yes"
...@@ -241,9 +241,9 @@ void Driver<real>::registerKeywords( Keywords& keys ) { ...@@ -241,9 +241,9 @@ void Driver<real>::registerKeywords( Keywords& keys ) {
keys.add("optional","--initial-step","provides a number for the initial step, default is 0"); keys.add("optional","--initial-step","provides a number for the initial step, default is 0");
keys.add("optional","--debug-forces","output a file containing the forces due to the bias evaluated using numerical derivatives " keys.add("optional","--debug-forces","output a file containing the forces due to the bias evaluated using numerical derivatives "
"and using the analytical derivatives implemented in plumed"); "and using the analytical derivatives implemented in plumed");
keys.add("hidden","--debug-float","turns on the single precision version (to check float interface)"); keys.add("hidden","--debug-float","[yes/no] turns on the single precision version (to check float interface)");
keys.add("hidden","--debug-dd","use a fake domain decomposition"); keys.add("hidden","--debug-dd","[yes/no] use a fake domain decomposition");
keys.add("hidden","--debug-pd","use a fake particle decomposition"); keys.add("hidden","--debug-pd","[yes/no] use a fake particle decomposition");
keys.add("hidden","--debug-grex","use a fake gromacs-like replica exchange, specify exchange stride"); keys.add("hidden","--debug-grex","use a fake gromacs-like replica exchange, specify exchange stride");
keys.add("hidden","--debug-grex-log","log file for debug=grex"); keys.add("hidden","--debug-grex-log","log file for debug=grex");
#ifdef __PLUMED_HAS_MOLFILE_PLUGINS #ifdef __PLUMED_HAS_MOLFILE_PLUGINS
...@@ -277,9 +277,9 @@ int Driver<real>::main(FILE* in,FILE*out,Communicator& pc) { ...@@ -277,9 +277,9 @@ int Driver<real>::main(FILE* in,FILE*out,Communicator& pc) {
if( printhelpdebug ) { if( printhelpdebug ) {
fprintf(out,"%s", fprintf(out,"%s",
"Additional options for debug (only to be used in regtest):\n" "Additional options for debug (only to be used in regtest):\n"
" [--debug-float] : turns on the single precision version (to check float interface)\n" " [--debug-float yes] : turns on the single precision version (to check float interface)\n"
" [--debug-dd] : use a fake domain decomposition\n" " [--debug-dd yes] : use a fake domain decomposition\n"
" [--debug-pd] : use a fake particle decomposition\n" " [--debug-pd yes] : use a fake particle decomposition\n"
); );
return 0; return 0;
} }
...@@ -287,16 +287,39 @@ int Driver<real>::main(FILE* in,FILE*out,Communicator& pc) { ...@@ -287,16 +287,39 @@ int Driver<real>::main(FILE* in,FILE*out,Communicator& pc) {
bool noatoms; parseFlag("--noatoms",noatoms); bool noatoms; parseFlag("--noatoms",noatoms);
std::string fakein; std::string fakein;
bool debugfloat=parse("--debug-float",fakein); bool debug_float=false;
if(debugfloat && sizeof(real)!=sizeof(float)) { fakein="";
if(parse("--debug-float",fakein)) {
if(fakein=="yes") debug_float=true;
else if(fakein=="no") debug_float=false;
else error("--debug-float should have argument yes or no");
}
if(debug_float && sizeof(real)!=sizeof(float)) {
std::unique_ptr<CLTool> cl(cltoolRegister().create(CLToolOptions("driver-float"))); std::unique_ptr<CLTool> cl(cltoolRegister().create(CLToolOptions("driver-float")));
cl->setInputData(this->getInputData()); cl->setInputData(this->getInputData());
int ret=cl->main(in,out,pc); int ret=cl->main(in,out,pc);
return ret; return ret;
} }
bool debug_pd=parse("--debug-pd",fakein); bool debug_pd=false;
bool debug_dd=parse("--debug-dd",fakein); fakein="";
if(parse("--debug-pd",fakein)) {
if(fakein=="yes") debug_pd=true;
else if(fakein=="no") debug_pd=false;
else error("--debug-pd should have argument yes or no");
}
if(debug_pd) fprintf(out,"DEBUGGING PARTICLE DECOMPOSITION\n");
bool debug_dd=false;
fakein="";
if(parse("--debug-dd",fakein)) {
if(fakein=="yes") debug_dd=true;
else if(fakein=="no") debug_dd=false;
else error("--debug-dd should have argument yes or no");
}
if(debug_dd) fprintf(out,"DEBUGGING DOMAIN DECOMPOSITION\n");
if( debug_pd || debug_dd ) { if( debug_pd || debug_dd ) {
if(noatoms) error("cannot debug without atoms"); if(noatoms) error("cannot debug without atoms");
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment