27 #ifndef LBANN_OBJECTIVE_FUNCTION_HPP_INCLUDED 28 #define LBANN_OBJECTIVE_FUNCTION_HPP_INCLUDED 52 template <
class Archive>
56 void add_term(std::unique_ptr<objective_function_term> term);
58 std::vector<objective_function_term*>
get_terms();
126 void write_proto(lbann_data::ObjectiveFunction& proto)
const;
130 std::vector<std::unique_ptr<objective_function_term>>
m_terms;
143 #endif // LBANN_OBJECTIVE_FUNCTION_INCLUDED
void compute_weight_regularization()
EvalType m_differentiation_time
std::vector< objective_function_term * > get_terms()
void set_layer_pointers(std::vector< ViewingLayerPtr > layers)
std::vector< ViewingWeightsPtr > get_weights_pointers() const
int get_statistics_num_samples(execution_mode mode) const
Abstract base class for neural network models.
~objective_function()=default
std::vector< std::unique_ptr< objective_function_term > > m_terms
std::map< execution_mode, metric_statistics > m_statistics
execution_mode
Neural network execution mode.
EvalType get_mean_value(execution_mode mode) const
void write_proto(lbann_data::ObjectiveFunction &proto) const
void set_weights_pointers(std::vector< ViewingWeightsPtr > w)
EvalType finish_evaluation(execution_mode mode, int mini_batch_size)
EvalType get_evaluation_time() const
std::vector< ViewingLayerPtr > get_layer_pointers() const
void start_evaluation(execution_mode mode, int mini_batch_size)
void reset_statistics(execution_mode mode)
void serialize(Archive &ar)
void add_term(std::unique_ptr< objective_function_term > term)
objective_function * copy() const
EvalType m_evaluation_time
EvalType get_differentiation_time() const
objective_function & operator=(const objective_function &other)