Vowpal Wabbit
|
#include <search.h>
Private Member Functions | |
template<class T > | |
void | make_new_pointer (v_array< T > &A, size_t new_size) |
template<class T > | |
predictor & | add_to (v_array< T > &A, bool &A_is_ptr, T a, bool clear_first) |
template<class T > | |
predictor & | add_to (v_array< T > &A, bool &A_is_ptr, T *a, size_t count, bool clear_first) |
void | free_ec () |
Private Attributes | |
bool | is_ldf |
ptag | my_tag |
example * | ec |
size_t | ec_cnt |
bool | ec_alloced |
float | weight |
v_array< action > | oracle_actions |
bool | oracle_is_pointer |
v_array< ptag > | condition_on_tags |
v_array< char > | condition_on_names |
v_array< action > | allowed_actions |
bool | allowed_is_pointer |
v_array< float > | allowed_actions_cost |
bool | allowed_cost_is_pointer |
size_t | learner_id |
search & | sch |
Definition at line 3119 of file search.cc.
References allowed_actions, allowed_actions_cost, condition_on_names, condition_on_tags, and oracle_actions.
Search::predictor::~predictor | ( | ) |
Definition at line 3151 of file search.cc.
References allowed_actions, allowed_actions_cost, allowed_cost_is_pointer, allowed_is_pointer, condition_on_names, condition_on_tags, v_array< T >::delete_v(), free_ec(), oracle_actions, and oracle_is_pointer.
Definition at line 3342 of file search.cc.
References add_to(), allowed_actions, and allowed_is_pointer.
Referenced by add_allowed(), SequenceSpanTask::run(), and set_allowed().
Definition at line 3343 of file search.cc.
References add_to(), allowed_actions, and allowed_is_pointer.
Definition at line 3347 of file search.cc.
References add_to(), allowed_actions, allowed_is_pointer, v_array< T >::begin(), and v_array< T >::size().
Definition at line 3362 of file search.cc.
References add_to(), allowed_actions, allowed_actions_cost, allowed_cost_is_pointer, and allowed_is_pointer.
Definition at line 3368 of file search.cc.
References a, add_allowed(), add_to(), allowed_actions, allowed_actions_cost, allowed_cost_is_pointer, and allowed_is_pointer.
Definition at line 3414 of file search.cc.
References condition_on_names, condition_on_tags, and v_array< T >::push_back().
Referenced by EntityRelationTask::predict_relation(), GraphTask::run(), and set_condition().
Definition at line 3427 of file search.cc.
References condition_on_names, condition_on_tags, and v_array< T >::push_back().
Referenced by SequenceSpanTask::run(), and set_condition_range().
Definition at line 3304 of file search.cc.
References add_to(), oracle_actions, and oracle_is_pointer.
Definition at line 3305 of file search.cc.
References add_to(), oracle_actions, and oracle_is_pointer.
Definition at line 3309 of file search.cc.
References add_to(), v_array< T >::begin(), oracle_actions, oracle_is_pointer, and v_array< T >::size().
|
private |
Definition at line 3233 of file search.cc.
References a, v_array< T >::begin(), v_array< T >::clear(), v_array< T >::end(), v_array< T >::push_back(), and v_array< T >::size().
Referenced by add_allowed(), add_oracle(), set_allowed(), and set_oracle().
|
private |
Definition at line 3254 of file search.cc.
References a, v_array< T >::begin(), v_array< T >::clear(), v_array< T >::delete_v(), v_array< T >::end(), v_array< T >::end_array, and v_array< T >::size().
predictor & Search::predictor::erase_alloweds | ( | ) |
Definition at line 3330 of file search.cc.
References allowed_actions, allowed_actions_cost, allowed_cost_is_pointer, allowed_is_pointer, v_array< T >::begin(), v_array< T >::clear(), and v_array< T >::end().
Referenced by reset(), DepParserTask::run(), and set_allowed().
predictor & Search::predictor::erase_oracles | ( | ) |
Definition at line 3296 of file search.cc.
References v_array< T >::begin(), v_array< T >::clear(), v_array< T >::end(), oracle_actions, and oracle_is_pointer.
Referenced by reset().
|
private |
Definition at line 3139 of file search.cc.
References COST_SENSITIVE::cs_label, VW::dealloc_example(), CB::delete_label(), ec, ec_alloced, ec_cnt, and is_ldf.
Referenced by reset(), set_input(), and ~predictor().
|
private |
Definition at line 3222 of file search.cc.
References v_array< T >::begin(), v_array< T >::end(), v_array< T >::end_array, and v_array< T >::size().
action Search::predictor::predict | ( | ) |
Definition at line 3460 of file search.cc.
References allowed_actions, allowed_actions_cost, v_array< T >::begin(), condition_on_names, condition_on_tags, ec, ec_cnt, is_ldf, learner_id, my_tag, oracle_actions, v_array< T >::pop(), Search::search::predict(), Search::search::predictLDF(), v_array< T >::push_back(), sch, v_array< T >::size(), and weight.
Referenced by EntityRelationTask::predict_entity(), EntityRelationTask::predict_relation(), SequenceSpanTask::run(), GraphTask::run(), and DepParserTask::run().
predictor & Search::predictor::reset | ( | ) |
Definition at line 3163 of file search.cc.
References v_array< T >::clear(), condition_on_names, condition_on_tags, erase_alloweds(), erase_oracles(), and free_ec().
Definition at line 3352 of file search.cc.
References add_to(), allowed_actions, and allowed_is_pointer.
Referenced by EntityRelationTask::predict_entity(), EntityRelationTask::predict_relation(), SequenceSpanTask::run(), DepParserTask::run(), and set_allowed().
Definition at line 3353 of file search.cc.
References add_to(), allowed_actions, and allowed_is_pointer.
Definition at line 3357 of file search.cc.
References add_to(), allowed_actions, allowed_is_pointer, v_array< T >::begin(), and v_array< T >::size().
Definition at line 3392 of file search.cc.
References add_to(), allowed_actions, allowed_actions_cost, allowed_cost_is_pointer, and allowed_is_pointer.
Definition at line 3398 of file search.cc.
References a, add_allowed(), add_to(), allowed_actions, allowed_actions_cost, allowed_cost_is_pointer, allowed_is_pointer, erase_alloweds(), and set_allowed().
Definition at line 3420 of file search.cc.
References add_condition(), v_array< T >::clear(), condition_on_names, and condition_on_tags.
Definition at line 3441 of file search.cc.
References add_condition_range(), v_array< T >::clear(), condition_on_names, and condition_on_tags.
Referenced by SequenceTask::run(), SequenceSpanTask::run(), and DepParserTask::run().
Definition at line 3173 of file search.cc.
References ec, ec_alloced, ec_cnt, free_ec(), and is_ldf.
Referenced by EntityRelationTask::predict_entity(), EntityRelationTask::predict_relation(), SequenceTask::run(), SequenceSpanTask::run(), GraphTask::run(), and DepParserTask::run().
void Search::predictor::set_input_at | ( | size_t | posn, |
example & | input_example | ||
) |
Definition at line 3209 of file search.cc.
References VW::copy_example_data(), CB::copy_label(), COST_SENSITIVE::cs_label, ec, ec_alloced, ec_cnt, and THROW.
void Search::predictor::set_input_length | ( | size_t | input_length | ) |
Definition at line 3193 of file search.cc.
References ec, ec_alloced, ec_cnt, is_ldf, and THROW.
predictor & Search::predictor::set_learner_id | ( | size_t | id | ) |
Definition at line 3448 of file search.cc.
References id(), and learner_id.
Referenced by EntityRelationTask::predict_entity(), EntityRelationTask::predict_relation(), SequenceSpanTask::run(), and GraphTask::run().
Definition at line 3314 of file search.cc.
References add_to(), oracle_actions, and oracle_is_pointer.
Referenced by EntityRelationTask::predict_entity(), EntityRelationTask::predict_relation(), SequenceTask::run(), SequenceSpanTask::run(), GraphTask::run(), and DepParserTask::run().
Definition at line 3315 of file search.cc.
References add_to(), oracle_actions, and oracle_is_pointer.
Definition at line 3319 of file search.cc.
References add_to(), v_array< T >::begin(), oracle_actions, oracle_is_pointer, and v_array< T >::size().
Definition at line 3454 of file search.cc.
References my_tag.
Referenced by SequenceTask::run(), SequenceSpanTask::run(), and DepParserTask::run().
predictor & Search::predictor::set_weight | ( | float | w | ) |
Definition at line 343 of file search.h.
Referenced by add_allowed(), erase_alloweds(), predict(), predictor(), set_allowed(), and ~predictor().
|
private |
Definition at line 345 of file search.h.
Referenced by add_allowed(), erase_alloweds(), predict(), predictor(), set_allowed(), and ~predictor().
|
private |
Definition at line 346 of file search.h.
Referenced by add_allowed(), erase_alloweds(), set_allowed(), and ~predictor().
|
private |
Definition at line 344 of file search.h.
Referenced by add_allowed(), erase_alloweds(), set_allowed(), and ~predictor().
|
private |
Definition at line 342 of file search.h.
Referenced by add_condition(), add_condition_range(), predict(), predictor(), reset(), set_condition(), set_condition_range(), and ~predictor().
Definition at line 341 of file search.h.
Referenced by add_condition(), add_condition_range(), predict(), predictor(), reset(), set_condition(), set_condition_range(), and ~predictor().
|
private |
Definition at line 335 of file search.h.
Referenced by free_ec(), predict(), set_input(), set_input_at(), and set_input_length().
|
private |
Definition at line 337 of file search.h.
Referenced by free_ec(), set_input(), set_input_at(), and set_input_length().
|
private |
Definition at line 336 of file search.h.
Referenced by free_ec(), predict(), set_input(), set_input_at(), and set_input_length().
|
private |
Definition at line 333 of file search.h.
Referenced by free_ec(), predict(), set_input(), and set_input_length().
|
private |
Definition at line 347 of file search.h.
Referenced by predict(), and set_learner_id().
|
private |
Definition at line 339 of file search.h.
Referenced by add_oracle(), erase_oracles(), predict(), predictor(), set_oracle(), and ~predictor().
|
private |
Definition at line 340 of file search.h.
Referenced by add_oracle(), erase_oracles(), set_oracle(), and ~predictor().
|
private |
|
private |