Skip to content

Commit

Permalink
remove Bfactor groups - useless
Browse files Browse the repository at this point in the history
  • Loading branch information
Massimiliano Bonomi committed Sep 30, 2023
1 parent 3fe8d60 commit 4455163
Showing 1 changed file with 3 additions and 13 deletions.
16 changes: 3 additions & 13 deletions src/isdb/EMMIVox.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -143,8 +143,6 @@ class EMMIVOX : public Colvar {
double MCBtrials_;
// residue neighbor list
std::vector< std::vector<unsigned> > nl_res_;
unsigned bfactcount_;
unsigned bfactgroup_;
bool bfactemin_;
// Martini scattering factors
bool martini_;
Expand Down Expand Up @@ -248,7 +246,6 @@ void EMMIVOX::registerKeywords( Keywords& keys ) {
keys.add("optional","BFACT_MAX","Bfactor maximum value");
keys.add("optional","MCBFACT_STRIDE", "Bfactor MC stride");
keys.add("optional","BFACT_SIGMA","Bfactor sigma prior");
keys.add("optional","BFACT_GROUP","sample Bfactors in groups");
keys.add("optional","STATUS_FILE","write a file with all the data useful for restart");
keys.add("optional","SCALE","scale factor");
keys.add("optional","OFFSET","offset");
Expand All @@ -266,7 +263,6 @@ void EMMIVOX::registerKeywords( Keywords& keys ) {
keys.addOutputComponent("scoreb","default","Bayesian score");
keys.addOutputComponent("scale", "default","scale factor");
keys.addOutputComponent("offset","default","offset");
keys.addOutputComponent("accS", "default","scale MC acceptance");
keys.addOutputComponent("accB", "default", "Bfactor MC acceptance");
keys.addOutputComponent("kbt", "default", "temperature in energy unit");
keys.addOutputComponent("corr", "CORRELATION", "correlation coefficient");
Expand All @@ -279,8 +275,7 @@ EMMIVOX::EMMIVOX(const ActionOptions&ao):
scale_(1.), offset_(0.),
dbfact_(0.0), bfactmin_(0.05), bfactmax_(5.0),
bfactsig_(0.1), bfactnoc_(false), bfactread_(false),
MCBstride_(1), MCBaccept_(0.), MCBtrials_(0.),
bfactcount_(0), bfactgroup_(1), bfactemin_(false),
MCBstride_(1), MCBaccept_(0.), MCBtrials_(0.), bfactemin_(false),
martini_(false), statusstride_(0), first_status_(true),
eps_(0.0001), mapstride_(0), gpu_(false)
{
Expand Down Expand Up @@ -345,7 +340,6 @@ EMMIVOX::EMMIVOX(const ActionOptions&ao):
parse("MCBFACT_STRIDE",MCBstride_);
parse("BFACT_MAX",bfactmax_);
parse("BFACT_SIGMA",bfactsig_);
parse("BFACT_GROUP",bfactgroup_);
parseFlag("BFACT_MINIMIZE",bfactemin_);
// checks
if(MCBstride_<=0) error("you must specify a positive MCBFACT_STRIDE");
Expand Down Expand Up @@ -1074,10 +1068,10 @@ void EMMIVOX::get_close_residues()
void EMMIVOX::doMonteCarloBfact()
{
// update residue neighbor list
if(bfactcount_==0) get_close_residues();
get_close_residues();

// cycle over residues/chains
for(unsigned ir=bfactcount_; ir<Model_rlist_.size(); ir=ir+bfactgroup_) {
for(unsigned ir=0; ir<Model_rlist_.size(); ++ir) {

// key: pair of residue/chain IDs
std::pair<unsigned,std::string> key = Model_rlist_[ir];
Expand Down Expand Up @@ -1208,10 +1202,6 @@ void EMMIVOX::doMonteCarloBfact()

} // end cycle on bfactors

// update offset sampling
bfactcount_ += 1;
// reset if needed
if(bfactcount_==bfactgroup_) bfactcount_ = 0;
// update auxiliary lists (to update pref_gpu_, invs2_gpu_, and cut_ on CPU/GPU)
get_auxiliary_vectors();
// update neighbor list (new cut_ + update pref_nl_gpu_ and invs2_nl_gpu_ on GPU)
Expand Down

1 comment on commit 4455163

@PlumedBot
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Found broken examples in automatic/a-masterclass-22-09.txt
Found broken examples in automatic/a-masterclass-22-11.txt
Found broken examples in automatic/a-masterclass-22-12.txt
Found broken examples in automatic/performance-optimization.txt
Found broken examples in automatic/a-trieste-6.txt
Found broken examples in automatic/munster.txt
Found broken examples in automatic/ANN.tmp
Found broken examples in automatic/EDS.tmp
Found broken examples in automatic/EMMI.tmp
Found broken examples in automatic/ENVIRONMENTSIMILARITY.tmp
Found broken examples in automatic/FOURIER_TRANSFORM.tmp
Found broken examples in automatic/FUNCPATHGENERAL.tmp
Found broken examples in automatic/FUNCPATHMSD.tmp
Found broken examples in automatic/FUNNEL.tmp
Found broken examples in automatic/FUNNEL_PS.tmp
Found broken examples in automatic/GHBFIX.tmp
Found broken examples in automatic/INCLUDE.tmp
Found broken examples in automatic/MAZE_MEMETIC_SAMPLING.tmp
Found broken examples in automatic/MAZE_OPTIMIZER_BIAS.tmp
Found broken examples in automatic/MAZE_RANDOM_ACCELERATION_MD.tmp
Found broken examples in automatic/MAZE_RANDOM_WALK.tmp
Found broken examples in automatic/MAZE_SIMULATED_ANNEALING.tmp
Found broken examples in automatic/MAZE_STEERED_MD.tmp
Found broken examples in automatic/PIV.tmp
Found broken examples in automatic/PLUMED.tmp
Found broken examples in MiscelaneousPP.md

Please sign in to comment.