9#ifndef IMPISD_LOG_WRAPPER_H
10#define IMPISD_LOG_WRAPPER_H
12#include <IMP/isd/isd_config.h>
15#include <cereal/access.hpp>
16#include <cereal/types/base_class.hpp>
28 friend class cereal::access;
29 template<
class Archive>
void serialize(Archive &ar) {
30 ar(cereal::base_class<RestraintSet>(
this));
34 void show_it(std::ostream &out)
const;
38 LogWrapper(Model *m,
double weight,
const std::string &name =
"LogWrapper %1%");
40 LogWrapper(Model *m,
const std::string &name =
"LogWrapper %1%");
43 const std::string &name =
"LogWrapper %1%");
52 void do_add_score_and_derivatives_moved(
Used to hold a set of related restraints.
Class for adding derivatives from restraints to the model.
RestraintSet(Model *m, double weight, const std::string &name="RestraintSet %1%")
Create an empty set that is registered with the model.
Class for adding up scores during ScoringFunction evaluation.
LogWrapper(Model *m, const std::string &name="LogWrapper %1%")
Create an empty set that is registered with the model.
LogWrapper(const RestraintsTemp &rs, double weight, const std::string &name="LogWrapper %1%")
Create a set that is registered with the model.
void do_add_score_and_derivatives(ScoreAccumulator sa) const override
Add the score and (if requested) derivatives to the accumulator.
LogWrapper(Model *m, double weight, const std::string &name="LogWrapper %1%")
Create an empty set that is registered with the model.
virtual double unprotected_evaluate_moved(IMP::DerivativeAccumulator *accum, const ParticleIndexes &moved_pis, const ParticleIndexes &reset_pis) const override
Return the unweighted score, taking moving particles into account.
virtual double unprotected_evaluate(IMP::DerivativeAccumulator *accum) const override
Return the unweighted score for the restraint.
Macros to define containers of objects.
Vector< ParticleIndex, std::allocator< ParticleIndex > > ParticleIndexes
A list of particles, each identified by its ParticleIndex.
IMP::Vector< IMP::WeakPointer< Restraint > > RestraintsTemp
#define IMP_OBJECT_SERIALIZE_DECL(Name)
Declare methods needed for serialization of Object pointers.
#define IMP_OBJECT_METHODS(Name)
Define the basic things needed by any Object.