File example_weights_real_valued.hpp

Functions

std::unique_ptr<IRealValuedExampleWeights> createRealValuedExampleWeights(uint32 numExamples)

Creates and returns a new object of type IRealValuedExampleWeights in cases where the examples have real-valued weights.

Parameters:

numExamples – The total number of available examples

Returns:

An unique pointer to an object of type IRealValuedExampleWeights that have been created

class IRealValuedExampleWeights : public IExampleWeights
#include <example_weights_real_valued.hpp>

Defines an interface for all classes that provide access to the weights of individual training examples in cases where the examples have real-valued weights.

Public Functions

inline virtual ~IRealValuedExampleWeights() override
virtual void setWeight(uint32 index, float32 weight) = 0

Sets the weight of the training example at a specific index.

Parameters:
  • index – The index of the training example

  • weight – The weight to be set