shark::CVFolds< DatasetTypeT > Class Template Reference

#include <shark/Data/CVDatasetTools.h>

Public Types

typedef DatasetTypeT DatasetType
 
typedef DatasetType::IndexSet IndexSet
 

Public Member Functions

 CVFolds ()
 Creates an empty set of folds. More...
 
 CVFolds (DatasetType const &set, std::vector< IndexSet > const &validationIndizes)
 partitions set in validation folds indicated by the second argument. More...
 
 CVFolds (DatasetType const &set, std::vector< std::size_t > const &foldStart)
 
DatasetType training (std::size_t i) const
 
DatasetType validation (std::size_t i) const
 
IndexSet const & validationFoldIndices (std::size_t i) const
 returns the indices that make up the i-th validation fold More...
 
IndexSet trainingFoldIndices (std::size_t i) const
 
std::size_t size () const
 Returns the number of folds of the dataset. More...
 
DatasetType const & dataset () const
 Returns the dataset underying the folds. More...
 
DatasetTypedataset ()
 Returns the dataset underying the folds. More...
 

Detailed Description

template<class DatasetTypeT>
class shark::CVFolds< DatasetTypeT >

Definition at line 49 of file CVDatasetTools.h.

Member Typedef Documentation

◆ DatasetType

template<class DatasetTypeT>
typedef DatasetTypeT shark::CVFolds< DatasetTypeT >::DatasetType

Definition at line 51 of file CVDatasetTools.h.

◆ IndexSet

template<class DatasetTypeT>
typedef DatasetType::IndexSet shark::CVFolds< DatasetTypeT >::IndexSet

Definition at line 52 of file CVDatasetTools.h.

Constructor & Destructor Documentation

◆ CVFolds() [1/3]

template<class DatasetTypeT>
shark::CVFolds< DatasetTypeT >::CVFolds ( )
inline

Creates an empty set of folds.

Definition at line 55 of file CVDatasetTools.h.

◆ CVFolds() [2/3]

template<class DatasetTypeT>
shark::CVFolds< DatasetTypeT >::CVFolds ( DatasetType const &  set,
std::vector< IndexSet > const &  validationIndizes 
)
inline

partitions set in validation folds indicated by the second argument.

The folds are given as the batch indices of the validation sets

Definition at line 59 of file CVDatasetTools.h.

◆ CVFolds() [3/3]

template<class DatasetTypeT>
shark::CVFolds< DatasetTypeT >::CVFolds ( DatasetType const &  set,
std::vector< std::size_t > const &  foldStart 
)
inline

Definition at line 64 of file CVDatasetTools.h.

Member Function Documentation

◆ dataset() [1/2]

template<class DatasetTypeT>
DatasetType const& shark::CVFolds< DatasetTypeT >::dataset ( ) const
inline

Returns the dataset underying the folds.

Definition at line 109 of file CVDatasetTools.h.

◆ dataset() [2/2]

template<class DatasetTypeT>
DatasetType& shark::CVFolds< DatasetTypeT >::dataset ( )
inline

Returns the dataset underying the folds.

Definition at line 114 of file CVDatasetTools.h.

◆ size()

◆ training()

template<class DatasetTypeT>
DatasetType shark::CVFolds< DatasetTypeT >::training ( std::size_t  i) const
inline

◆ trainingFoldIndices()

template<class DatasetTypeT>
IndexSet shark::CVFolds< DatasetTypeT >::trainingFoldIndices ( std::size_t  i) const
inline

Definition at line 96 of file CVDatasetTools.h.

Referenced by shark::CVFolds< DatasetType >::training().

◆ validation()

template<class DatasetTypeT>
DatasetType shark::CVFolds< DatasetTypeT >::validation ( std::size_t  i) const
inline

◆ validationFoldIndices()

template<class DatasetTypeT>
IndexSet const& shark::CVFolds< DatasetTypeT >::validationFoldIndices ( std::size_t  i) const
inline

returns the indices that make up the i-th validation fold

Definition at line 91 of file CVDatasetTools.h.

Referenced by shark::CVFolds< DatasetType >::validation().


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