Vowpal Wabbit
|
#include "io_buf.h"
#include "parse_primitives.h"
#include "example.h"
#include "future_compat.h"
#include <mutex>
#include <condition_variable>
#include <memory>
#include "queue.h"
#include "object_pool.h"
Go to the source code of this file.
Classes | |
struct | example_initializer |
struct | parser |
Functions | |
void | enable_sources (vw &all, bool quiet, size_t passes, input_options &input_options) |
void | adjust_used_index (vw &all) |
void | lock_done (parser &p) |
void | set_done (vw &all) |
void | reset_source (vw &all, size_t numbits) |
void | finalize_source (parser *source) |
void | set_compressed (parser *par) |
void | free_parser (vw &all) |
void adjust_used_index | ( | vw & | all | ) |
Definition at line 968 of file parser.cc.
Referenced by VW_Finish_Passes().
void enable_sources | ( | vw & | all, |
bool | quiet, | ||
size_t | passes, | ||
input_options & | input_options | ||
) |
Definition at line 312 of file parser.cc.
References vw::active, parser::audit, vw::audit, binary_print_result(), parser::bound_sock, input_options::cache_files, children(), io_buf::count, io_buf::current, vw::daemon, vw::data_filename, parser::decision_service_json, input_options::dsjson, v_array< T >::empty(), f, io_buf::files, vw::final_prediction_sink, VW::finish(), input_options::foreground, handle_sigterm(), vw::hash_inv, parser::input, isbinary(), input_options::json, input_options::kill_cache, parser::label_sock, vw::length(), MAP_ANONYMOUS, parser::max_fd, vw::num_children, io_buf::open_file(), vw::options, vw::p, parse_cache(), input_options::pid_file, input_options::port, input_options::port_file, vw::print, print_result(), v_array< T >::push_back(), vw::quiet, io_buf::READ, read_cached_features(), read_features_string(), VW::read_lines(), parser::reader, parser::resettable, v_array< T >::resize(), vw::sd, parameters::share(), v_array< T >::size(), parser::sorted_cache, vw::stdin_off, parser::text_reader, THROW, THROWERRNO, vw::trace_message, VW::config::options_i::was_supplied(), vw::weights, and parser::write_cache.
Referenced by parse_sources().
void finalize_source | ( | parser * | source | ) |
Definition at line 206 of file parser.cc.
References io_buf::close_files(), v_array< T >::empty(), f, io_buf::files, parser::input, v_array< T >::last(), parser::output, and v_array< T >::pop().
Referenced by VW::finish(), and set_compressed().
void free_parser | ( | vw & | all | ) |
Definition at line 976 of file parser.cc.
References parser::counts, io_buf::currentname, VW::dealloc_example(), label_parser::delete_label, vw::delete_prediction, v_array< T >::delete_v(), VW::object_pool< T, TInitializer, TCleanup >::empty(), parser::example_pool, io_buf::finalname, VW::object_pool< T, TInitializer, TCleanup >::get_object(), parser::gram_mask, parser::lp, parser::name, vw::ngram_strings, parser::output, vw::p, VW::ptr_queue< T >::pop(), parser::ready_parsed_examples, VW::ptr_queue< T >::size(), and parser::words.
Referenced by VW::finish().
void lock_done | ( | parser & | p | ) |
Definition at line 571 of file parser.cc.
References parser::done, parser::ready_parsed_examples, and VW::ptr_queue< T >::set_done().
Referenced by parse_dispatch(), and set_done().
void reset_source | ( | vw & | all, |
size_t | numbits | ||
) |
Definition at line 126 of file parser.cc.
References v_array< T >::begin(), binary_print_result(), parser::bound_sock, cache_numbits(), v_array< T >::clear(), io_buf::close_file(), io_buf::close_file_or_socket(), io_buf::compressed(), io_buf::current, io_buf::currentname, vw::daemon, f, io_buf::files, vw::final_prediction_sink, io_buf::finalname, recall_tree_ns::find(), io_buf::flush(), parser::input, isbinary(), io_buf::num_files(), io_buf::open_file(), parser::output, parser::output_done, parser::output_lock, vw::p, v_array< T >::pop(), vw::print, print_result(), v_array< T >::push_back(), io_buf::READ, read_cached_features(), read_features_string(), parser::reader, parser::ready_parsed_examples, io_buf::reset_file(), parser::resettable, v_array< T >::size(), VW::ptr_queue< T >::size(), vw::stdin_off, THROW, and parser::write_cache.
Referenced by parse_dispatch().
void set_compressed | ( | parser * | par | ) |
Definition at line 82 of file parser.cc.
References finalize_source(), parser::input, and parser::output.
Referenced by parse_source().
void set_done | ( | vw & | all | ) |
Definition at line 578 of file parser.cc.
References vw::early_terminate, lock_done(), and vw::p.
Referenced by GD::end_pass(), end_pass(), and finish_example().