Vowpal Wabbit
|
Contains the VW::LEARNER::learner object and utilities for interacting with it. More...
Classes | |
struct | finish_example_data |
struct | func_data |
struct | learn_data |
struct | learner |
Defines the interface for a learning algorithm. More... | |
struct | save_load_data |
struct | sensitivity_data |
Typedefs | |
using | base_learner = learner< char, char > |
Used to type erase the object and pass around common type. More... | |
using | single_learner = learner< char, example > |
Used for reductions that process single example objects at at time. It type erases the specific reduction object type. More... | |
using | multi_learner = learner< char, multi_ex > |
Used for multiline examples where there are several example objects required to describe the overall example. It type erases the specific reduction object type. More... | |
Functions | |
func_data | tuple_dbf (void *data, base_learner *base, void(*func)(void *)) |
void | generic_driver (vw &all) |
void | generic_driver (const std::vector< vw * > &alls) |
void | generic_driver_onethread (vw &all) |
void | noop_sl (void *, io_buf &, bool, bool) |
void | noop (void *) |
float | noop_sensitivity (void *, base_learner &, example &) |
float | recur_sensitivity (void *, base_learner &, example &) |
void | increment_offset (example &ex, const size_t increment, const size_t i) |
void | increment_offset (multi_ex &ec_seq, const size_t increment, const size_t i) |
void | decrement_offset (example &ex, const size_t increment, const size_t i) |
void | decrement_offset (multi_ex &ec_seq, const size_t increment, const size_t i) |
template<class T , class E , class L > | |
learner< T, E > & | init_learner (free_ptr< T > &dat, L *base, void(*learn)(T &, L &, E &), void(*predict)(T &, L &, E &), size_t ws, prediction_type_t pred_type) |
template<class T , class E , class L > | |
learner< T, E > & | init_learner (free_ptr< T > &dat, void(*learn)(T &, L &, E &), void(*predict)(T &, L &, E &), size_t params_per_weight) |
template<class T , class E , class L > | |
learner< T, E > & | init_learner (void(*predict)(T &, L &, E &), size_t params_per_weight) |
template<class T , class E , class L > | |
learner< T, E > & | init_learner (free_ptr< T > &dat, void(*learn)(T &, L &, E &), void(*predict)(T &, L &, E &), size_t params_per_weight, prediction_type_t pred_type) |
template<class T , class E , class L > | |
learner< T, E > & | init_learner (free_ptr< T > &dat, L *base, void(*learn)(T &, L &, E &), void(*predict)(T &, L &, E &), size_t ws) |
template<class T , class E , class L > | |
learner< T, E > & | init_learner (free_ptr< T > &dat, L *base, void(*learn)(T &, L &, E &), void(*predict)(T &, L &, E &)) |
template<class T , class E , class L > | |
learner< T, E > & | init_learner (L *base, void(*learn)(T &, L &, E &), void(*predict)(T &, L &, E &)) |
template<class T , class E , class L > | |
learner< T, E > & | init_multiclass_learner (free_ptr< T > &dat, L *base, void(*learn)(T &, L &, E &), void(*predict)(T &, L &, E &), parser *p, size_t ws, prediction_type_t pred_type=prediction_type_t::multiclass) |
template<class T , class E , class L > | |
learner< T, E > & | init_cost_sensitive_learner (free_ptr< T > &dat, L *base, void(*learn)(T &, L &, E &), void(*predict)(T &, L &, E &), parser *p, size_t ws, prediction_type_t pred_type=prediction_type_t::multiclass) |
template<class T , class E > | |
base_learner * | make_base (learner< T, E > &base) |
template<class T , class E > | |
multi_learner * | as_multiline (learner< T, E > *l) |
template<class T , class E > | |
single_learner * | as_singleline (learner< T, E > *l) |
template<bool is_learn> | |
void | multiline_learn_or_predict (multi_learner &base, multi_ex &examples, const uint64_t offset, const uint32_t id=0) |
Contains the VW::LEARNER::learner object and utilities for interacting with it.
typedef learner< char, char > VW::LEARNER::base_learner |
Used to type erase the object and pass around common type.
typedef learner< char, multi_ex > VW::LEARNER::multi_learner |
Used for multiline examples where there are several example objects required to describe the overall example. It type erases the specific reduction object type.
typedef learner< char, example > VW::LEARNER::single_learner |
Used for reductions that process single example objects at at time. It type erases the specific reduction object type.
multi_learner* VW::LEARNER::as_multiline | ( | learner< T, E > * | l | ) |
single_learner* VW::LEARNER::as_singleline | ( | learner< T, E > * | l | ) |
|
inline |
|
inline |
void VW::LEARNER::generic_driver | ( | vw & | all | ) |
void VW::LEARNER::generic_driver | ( | const std::vector< vw * > & | alls | ) |
void VW::LEARNER::generic_driver_onethread | ( | vw & | all | ) |
|
inline |
|
inline |
learner<T, E>& VW::LEARNER::init_cost_sensitive_learner | ( | free_ptr< T > & | dat, |
L * | base, | ||
void(*)(T &, L &, E &) | learn, | ||
void(*)(T &, L &, E &) | predict, | ||
parser * | p, | ||
size_t | ws, | ||
prediction_type_t | pred_type = prediction_type_t::multiclass |
||
) |
learner<T, E>& VW::LEARNER::init_learner | ( | free_ptr< T > & | dat, |
L * | base, | ||
void(*)(T &, L &, E &) | learn, | ||
void(*)(T &, L &, E &) | predict, | ||
size_t | ws, | ||
prediction_type_t | pred_type | ||
) |
learner<T, E>& VW::LEARNER::init_learner | ( | free_ptr< T > & | dat, |
void(*)(T &, L &, E &) | learn, | ||
void(*)(T &, L &, E &) | predict, | ||
size_t | params_per_weight | ||
) |
learner<T, E>& VW::LEARNER::init_learner | ( | void(*)(T &, L &, E &) | predict, |
size_t | params_per_weight | ||
) |
learner<T, E>& VW::LEARNER::init_learner | ( | free_ptr< T > & | dat, |
void(*)(T &, L &, E &) | learn, | ||
void(*)(T &, L &, E &) | predict, | ||
size_t | params_per_weight, | ||
prediction_type_t | pred_type | ||
) |
learner<T, E>& VW::LEARNER::init_learner | ( | free_ptr< T > & | dat, |
L * | base, | ||
void(*)(T &, L &, E &) | learn, | ||
void(*)(T &, L &, E &) | predict, | ||
size_t | ws | ||
) |
learner<T, E>& VW::LEARNER::init_learner | ( | free_ptr< T > & | dat, |
L * | base, | ||
void(*)(T &, L &, E &) | learn, | ||
void(*)(T &, L &, E &) | predict | ||
) |
learner<T, E>& VW::LEARNER::init_learner | ( | L * | base, |
void(*)(T &, L &, E &) | learn, | ||
void(*)(T &, L &, E &) | predict | ||
) |
learner<T, E>& VW::LEARNER::init_multiclass_learner | ( | free_ptr< T > & | dat, |
L * | base, | ||
void(*)(T &, L &, E &) | learn, | ||
void(*)(T &, L &, E &) | predict, | ||
parser * | p, | ||
size_t | ws, | ||
prediction_type_t | pred_type = prediction_type_t::multiclass |
||
) |
base_learner* VW::LEARNER::make_base | ( | learner< T, E > & | base | ) |
void VW::LEARNER::multiline_learn_or_predict | ( | multi_learner & | base, |
multi_ex & | examples, | ||
const uint64_t | offset, | ||
const uint32_t | id = 0 |
||
) |
|
inline |
|
inline |
|
inline |
float VW::LEARNER::recur_sensitivity | ( | void * | , |
base_learner & | , | ||
example & | |||
) |
|
inline |