8 #ifndef IMPKERNEL_OPTIMIZER_STATE_H
9 #define IMPKERNEL_OPTIMIZER_STATE_H
11 #include <IMP/kernel/kernel_config.h>
18 IMPKERNEL_BEGIN_NAMESPACE
45 unsigned int period_, call_number_, update_number_;
69 virtual void update();
76 virtual void set_is_optimizing(
bool);
80 "Must call set_optimizer before get_optimizer on state");
81 return optimizer_.get();
91 void set_period(
unsigned int p);
100 virtual void reset();
105 void update_always();
121 virtual void do_set_is_optimizing(
bool) {}
135 IMPKERNEL_END_NAMESPACE
A weak pointer to an Object or RefCountedObject.
IMP::base::Vector< IMP::base::WeakPointer< kernel::ModelObject > > ModelObjectsTemp
virtual void do_update(unsigned int)
unsigned int get_period() const
#define IMP_FINAL
Have the compiler report an error if anything overrides this method.
Shared optimizer state that is invoked upon commitment of new coordinates.
IMP::kernel::Optimizer Optimizer
#define IMP_REF_COUNTED_DESTRUCTOR(Name)
Ref counted objects should have private destructors.
virtual ModelObjectsTemp do_get_inputs() const
#define IMP_INTERNAL_CHECK(expr, message)
An assertion to check for internal errors in IMP. An IMP::ErrorException will be thrown.
Single variable function.
A nullptr-initialized pointer to an Object.
Base class for all optimizers.
unsigned int get_number_of_updates() const
Return the number of times update has been called.
A shared base class to help in debugging and things.
virtual ModelObjectsTemp do_get_outputs() const
IMP::kernel::OptimizerState OptimizerState
#define IMP_OVERRIDE
Cause a compile error if this method does not override a parent method.
Class for storing model, its restraints, constraints, and particles.
void set_number_of_updates(unsigned int n)
Set the counter.