Vowpal Wabbit
|
#include <iostream>
#include <algorithm>
#include <cstdlib>
#include <cstring>
#include <cassert>
#include <cstdint>
#include "vw_exception.h"
#include "memory.h"
Go to the source code of this file.
Classes | |
struct | v_array< T > |
Macros | |
#define | NOMINMAX |
#define | __INLINE inline |
Typedefs | |
typedef v_array< unsigned char > | v_string |
Functions | |
template<class T > | |
v_array< T > | v_init () |
template<class T > | |
void | copy_array (v_array< T > &dst, const v_array< T > &src) |
template<class T > | |
void | copy_array_no_memcpy (v_array< T > &dst, const v_array< T > &src) |
template<class T > | |
void | copy_array (v_array< T > &dst, const v_array< T > &src, T(*copy_item)(T &)) |
template<class T > | |
void | push_many (v_array< T > &v, const T *_begin, size_t num) |
template<class T > | |
void | calloc_reserve (v_array< T > &v, size_t length) |
template<class T > | |
v_array< T > | pop (v_array< v_array< T > > &stack) |
template<class T > | |
bool | v_array_contains (v_array< T > &A, T x) |
template<class T > | |
std::ostream & | operator<< (std::ostream &os, const v_array< T > &v) |
template<class T , class U > | |
std::ostream & | operator<< (std::ostream &os, const v_array< std::pair< T, U > > &v) |
v_string | string2v_string (const std::string &s) |
std::string | v_string2string (const v_string &v_s) |
Variables | |
const size_t | erase_point = ~((1u << 10u) - 1u) |
void calloc_reserve | ( | v_array< T > & | v, |
size_t | length | ||
) |
Definition at line 220 of file v_array.h.
References v_array< T >::_begin, v_array< T >::_end, and v_array< T >::end_array.
Referenced by mwt_setup().
Definition at line 185 of file v_array.h.
References v_array< T >::_begin, v_array< T >::clear(), push_many(), and v_array< T >::size().
Referenced by memory_tree_ns::copy_example_data(), VW::copy_example_data(), VW::copy_example_metadata(), MULTILABEL::copy_label(), CB::copy_label(), COST_SENSITIVE::copy_label(), CCB::copy_label(), features::deep_copy_from(), learn(), predict(), and SelectiveBranchingMT::run().
void copy_array | ( | v_array< T > & | dst, |
const v_array< T > & | src, | ||
T(*)(T &) | copy_item | ||
) |
Definition at line 200 of file v_array.h.
References v_array< T >::_begin, v_array< T >::_end, v_array< T >::clear(), and v_array< T >::push_back().
Definition at line 193 of file v_array.h.
References v_array< T >::_begin, v_array< T >::_end, v_array< T >::clear(), and v_array< T >::push_back().
Referenced by features::deep_copy_from().
std::ostream& operator<< | ( | std::ostream & | os, |
const v_array< T > & | v | ||
) |
std::ostream& operator<< | ( | std::ostream & | os, |
const v_array< std::pair< T, U > > & | v | ||
) |
Definition at line 228 of file v_array.h.
void push_many | ( | v_array< T > & | v, |
const T * | _begin, | ||
size_t | num | ||
) |
Definition at line 207 of file v_array.h.
References v_array< T >::_begin, v_array< T >::_end, v_array< T >::end_array, v_array< T >::resize(), and v_array< T >::size().
Referenced by copy_array(), make_write_cache(), TC_parser< audit >::maybeFeature(), TC_parser< audit >::nameSpaceInfo(), TagState< audit >::String(), string2v_string(), and substring_to_example().
|
inline |
bool v_array_contains | ( | v_array< T > & | A, |
T | x | ||
) |
Definition at line 237 of file v_array.h.
References v_array< T >::_begin, and v_array< T >::_end.
Referenced by memory_tree_ns::collect_labels_from_leaf(), Search::get_training_timesteps(), Search::single_prediction_notLDF(), and memory_tree_ns::train_one_against_some_at_leaf().
|
inline |
|
inline |
const size_t erase_point = ~((1u << 10u) - 1u) |
Definition at line 28 of file v_array.h.
Referenced by v_array< uint64_t >::clear().