Provides an interface to manipulate all kind of data.
Inheritance:
Public Fields
-
int* selected_examples
- The indices of all selected examples.
-
int current_example
- Index of the current example.
-
int n_targets
- Targets size, for all examples
-
void* targets
- Pointer to the targets of the current example
-
int n_inputs
- Input size, for all examples
-
List* inputs
- Pointer on the inputs of the current example
-
int n_examples
- Number of examples in the dataset.
-
int n_real_examples
- Real number of examples in the dataset.
Public Methods
-
DataSet()
-
void setExample(int t)
- Set targets and inputs to the targets and inputs of the example with the index selected_examples[t]
-
virtual void setRealExample(int t) = 0
- Set targets and inputs to the targets and inputs of the example with the index t
-
void pushSubset(int* subset_, int n_examples_)
- Set a new subset.
-
void popSubset()
- Remove the last subset.
Inherited from Object:
Public Methods
-
virtual void init()
-
void addOption(const char* name, int size, void* ptr, const char* help="", bool is_allowed_after_init=false)
-
void addIOption(const char* name, int* ptr, int init_value, const char* help="", bool is_allowed_after_init=false)
-
void addROption(const char* name, real* ptr, real init_value, const char* help="", bool is_allowed_after_init=false)
-
void addBOption(const char* name, bool* ptr, bool init_value, const char* help="", bool is_allowed_after_init=false)
-
void setOption(const char* name, void* ptr)
-
void setIOption(const char* name, int option)
-
void setROption(const char* name, real option)
-
void setBOption(const char* name, bool option)
-
virtual void loadFILE(FILE* file)
-
virtual void saveFILE(FILE* file)
-
void load(const char* filename)
-
void save(const char* filename)
Documentation
Provides an interface to manipulate all kind of data.
int* selected_examples
- The indices of all selected examples.
When select_examples is false, it contains
the indices of all examples.
int current_example
- Index of the current example.
Warning:
- don't forget to set it in setRealExample() !
- it's the real index and not the index
in the selected_examples table.
int n_targets
- Targets size, for all examples
void* targets
- Pointer to the targets of the current example
int n_inputs
- Input size, for all examples
List* inputs
- Pointer on the inputs of the current example
int n_examples
- Number of examples in the dataset.
If you're using select_examples, it's
the number of selected examples.
int n_real_examples
- Real number of examples in the dataset.
It's the number of examples in memory.
(= n_examples if select_examples is false)
DataSet()
void setExample(int t)
- Set targets and inputs to the targets and inputs
of the example with the index selected_examples[t]
virtual void setRealExample(int t) = 0
- Set targets and inputs to the targets and inputs
of the example with the index t
void pushSubset(int* subset_, int n_examples_)
- Set a new subset.
- subset_ (of size n_examples_) is a set
of indices which define a subset of data.
- if a pushSubset() has been already called,
the next pushSubset() defines a subset of the
previous subset, and so on...
- this function set select_examples to true
and set the read indices of the examples in
selected_examples.
void popSubset()
- Remove the last subset.
- recomputes "selected_examples".
- if it was the last subset, set select_examples
to false.
- Direct child classes:
- SeqDataSet
EuclideanDataSet
- Author:
- Ronan Collobert (collober@iro.umontreal.ca)
Alphabetic index HTML hierarchy of classes or Java
This page was generated with the help of DOC++.