QuickRank  v2.0
QuickRank: A C++ suite of Learning to Rank algorithms
Public Member Functions | Static Public Member Functions | Public Attributes | Private Attributes | List of all members
RTNode Class Reference

#include <rtnode.h>

Public Member Functions

 RTNode (double prediction)
 
 RTNode (size_t *new_sampleids, size_t new_nsampleids, double prediction)
 
 RTNode (float new_threshold, size_t new_featureidx, size_t new_featureid, RTNode *new_left, RTNode *new_right)
 
 RTNode (size_t *new_sampleids, RTNodeHistogram *new_hist)
 
 ~RTNode ()
 
void set_feature (size_t fidx, size_t fid)
 
size_t get_feature_id ()
 
size_t get_feature_idx ()
 
void save_leaves (RTNode **&leaves, size_t &nleaves, size_t &capacity)
 
bool is_leaf () const
 
quickrank::Score score_instance (const quickrank::Feature *d, const size_t next_fx_offset) const
 
pugi::xml_node append_xml_model (pugi::xml_node parent, const std::string &pos="") const
 

Static Public Member Functions

static RTNodeparse_xml (const pugi::xml_node &split_xml)
 

Public Attributes

size_t * sampleids = NULL
 
size_t nsampleids = 0
 
float threshold = 0.0f
 
double deviance = 0.0
 
double avglabel = 0.0
 
RTNodeleft = NULL
 
RTNoderight = NULL
 
RTNodeHistogramhist = NULL
 

Private Attributes

size_t featureidx = uint_max
 
size_t featureid = uint_max
 

Constructor & Destructor Documentation

RTNode::RTNode ( double  prediction)
inline
RTNode::RTNode ( size_t *  new_sampleids,
size_t  new_nsampleids,
double  prediction 
)
inline
RTNode::RTNode ( float  new_threshold,
size_t  new_featureidx,
size_t  new_featureid,
RTNode new_left,
RTNode new_right 
)
inline
RTNode::RTNode ( size_t *  new_sampleids,
RTNodeHistogram new_hist 
)
inline
RTNode::~RTNode ( )
inline

Member Function Documentation

pugi::xml_node RTNode::append_xml_model ( pugi::xml_node  parent,
const std::string &  pos = "" 
) const
size_t RTNode::get_feature_id ( )
inline
size_t RTNode::get_feature_idx ( )
inline
bool RTNode::is_leaf ( ) const
inline
RTNode * RTNode::parse_xml ( const pugi::xml_node &  split_xml)
static
Todo:
TODO: this should be changed with item mapping
void RTNode::save_leaves ( RTNode **&  leaves,
size_t &  nleaves,
size_t &  capacity 
)
quickrank::Score RTNode::score_instance ( const quickrank::Feature d,
const size_t  next_fx_offset 
) const
inline
void RTNode::set_feature ( size_t  fidx,
size_t  fid 
)
inline

Member Data Documentation

double RTNode::avglabel = 0.0
double RTNode::deviance = 0.0
size_t RTNode::featureid = uint_max
private
size_t RTNode::featureidx = uint_max
private
RTNodeHistogram* RTNode::hist = NULL
RTNode* RTNode::left = NULL
size_t RTNode::nsampleids = 0
RTNode* RTNode::right = NULL
size_t* RTNode::sampleids = NULL
float RTNode::threshold = 0.0f

The documentation for this class was generated from the following files: