18nproc = rem.get_number_of_replicas()
20temp = rem.create_temperatures(TEMPMIN_, TEMPMAX_, nproc)
22myindex = rem.get_my_index()
24rem.set_my_parameter(
"temp", [temp[myindex]])
34 d.set_coordinates_are_optimized(
True)
51mc.set_scoring_function(sf)
52mc.set_kt(temp[myindex])
53mc.set_return_best(
False)
57log = open(
"log" + str(myindex),
"w")
60for istep
in range(0, 100):
62 score = mc.optimize(100)
65 myindex = rem.get_my_index()
66 mytemp = rem.get_my_parameter(
"temp")[0]
68 myscore = score / mytemp
71 log.write(
"%4d %2d %6.3f\n" % (istep, myindex, score))
74 findex = rem.get_friend_index(istep)
75 ftemp = rem.get_friend_parameter(
"temp", findex)[0]
77 fscore = score / ftemp
80 flag = rem.do_exchange(myscore, fscore, findex)
Class for storing model, its restraints, constraints, and particles.
Class to handle individual particles of a Model object.
Move continuous particle variables by perturbing them within a ball.
Distance restraint between two particles.
Harmonic function (symmetric about the mean)
Create a scoring function on a list of restraints.
Applies a list of movers one at a time.
static XYZ setup_particle(Model *m, ParticleIndex pi)
A class to implement Hamiltonian Replica Exchange.
Basic functionality that is expected to be used by a wide variety of IMP users.
Code that uses the MPI parallel library.
void setup_from_argv(int argc, char **argv, std::string description)
Parse the command line flags and return the positional arguments.