Template Struct DatasetDetails

Struct Documentation

template<typename DatasetX = arma::mat, typename DatasetY = arma::mat>
struct mlpack::models::DatasetDetails

Structure used to provide details about the dataset.

tparam DatasetX

Datatype for loading input features for the dataset.

tparam DatasetY

Datatype for prediction features for the dataset.

Public Functions

inline DatasetDetails()
inline DatasetDetails(const std::string &datasetName, const std::string &trainDownloadURL, const std::string &testDownloadURL, const std::string &trainHash, const std::string &testHash, const std::string &datasetType, const std::string &trainPath, const std::string &testPath)

Constructor for initializing object for seperate train and test download URL.

Parameters
  • datasetName – Name of dataset used for identification during dataloader call.

  • trainDownloadURL – URL for downloading training data.

  • testDownloadURL – URL for downloading testing data.

  • trainHash – CRC-32 checksum for training data.

  • testHash – CRC-32 checksum for testing data.

  • datasetType – Determines if the format of dataset is similar to CSV.

  • trainPath – Path for training dataset.

  • testPath – Path for testing dataset.

inline DatasetDetails(const std::string &datasetName, const bool zipFile, const std::string &datasetURL, const std::string &datasetPath, const std::string &datasetHash, const std::string &datasetType, const std::string &trainPath = "", const std::string &testPath = "")

Constructor for initializing paths for zip files.

Parameters
  • datasetName – Name of dataset used for identification during dataloader call.

  • zipFile – Boolean to determine if dataset is stored in zip format. NOTE: For large dataset type such as images always set to true.

  • datasetURL – URL for downloading dataset.

  • datasetPath – Path where the dataset will be downloaded.

  • datasetHash – CRC-32 checksum for dataset.

  • datasetType – Determines the format of dataset.

  • trainPath – Path for training dataset.

  • testPath – Path for testing dataset.

Public Members

std::string datasetName

Locally stored name of dataset used for identification during dataloader call.

std::string trainDownloadURL

Locally stored URL for downloading training data.

std::string testDownloadURL

Locally stored URL for downloading testing data.

std::string trainHash

CRC-32 checksum for training data file.

std::string testHash

CRC-32 checksum for testing data file.

std::string datasetType

Locally stored stored to determine type of dataset.

std::string trainPath

Locally stored path to file / directory for training data.

std::string testPath

Locally stored path to file / directory for testing data.

bool zipFile

Locally held boolean to determine whether dataset will be in zip format.

std::string datasetURL

Locally stored URL for downloading dataset.

std::string datasetPath

Locally stored path for saving the archived / zip dataset.

std::string datasetHash

Locally stored CRC-32 checksum for the dataset.

std::string serverName

Locally stored server name for download file.

std::function<void(DatasetX&, DatasetY&, DatasetX&, DatasetY&, DatasetX&)> PreProcess
size_t startTrainingInputFeatures

First Index which will be fed into the model as input.

size_t endTrainingInputFeatures

Last Index which will be fed into the model as input.

size_t startTrainingPredictionFeatures

First Index which be predicted by the model as output.

size_t endTrainingPredictionFeatures

Last Index which be predicted by the model as output.

size_t startTestingInputFeatures

First Index which will be fed into the model as input for testing.

size_t endTestingInputFeatures

Last Index which will be fed into the model as input for testing.

bool dropHeader

Whether or not to drop the first row from CSV.

std::string trainingImagesPath

Locally stored path to images.

std::string testingImagesPath

Locally stored path to testing images.

std::string trainingAnnotationPath

Locally stored path to training annotations in xml format.

std::vector<std::string> classes

Locally stored classes of image classification /detection.

size_t imageWidth

Locally stored width of images.

size_t imageHeight

Locally stored heightof images.

size_t imageDepth

Locally stored depth of images.