shogun matrix
default constructor constructor for setting params constructor to create new vector in memory free vector destroy vector idx cache
Definition at line 300 of file DataType.h.
Public Member Functions | |
SGMatrix () | |
SGMatrix (T *m, index_t nrows, index_t ncols, bool free_mat=false) | |
SGMatrix (index_t nrows, index_t ncols, bool free_mat=false) | |
SGMatrix (const SGMatrix &orig) | |
virtual | ~SGMatrix () |
virtual void | free_matrix () |
virtual void | destroy_matrix () |
const T & | operator[] (index_t index) const |
T & | operator[] (index_t index) |
Public Attributes | |
T * | matrix |
index_t | num_rows |
index_t | num_cols |
bool | do_free |
SGMatrix | ( | ) |
default constructor
Definition at line 304 of file DataType.h.
constructor for setting params
Definition at line 307 of file DataType.h.
constructor to create new matrix in memory
Definition at line 311 of file DataType.h.
copy constructor
Definition at line 318 of file DataType.h.
virtual ~SGMatrix | ( | ) | [virtual] |
empty destructor
Definition at line 323 of file DataType.h.
virtual void destroy_matrix | ( | ) | [virtual] |
destroy matrix
Definition at line 340 of file DataType.h.
virtual void free_matrix | ( | ) | [virtual] |
free matrix
Definition at line 328 of file DataType.h.
const T& operator[] | ( | index_t | index | ) | const |
operator overload for matrix read only access
index | to access |
Definition at line 349 of file DataType.h.
T& operator[] | ( | index_t | index | ) |
operator overload for matrix r/w access
index | to access |
Definition at line 357 of file DataType.h.
bool do_free |
whether matrix needs to be freed
Definition at line 370 of file DataType.h.
T* matrix |
matrix
Definition at line 364 of file DataType.h.
number of columns of matrix
Definition at line 368 of file DataType.h.
number of rows of matrix
Definition at line 366 of file DataType.h.