14 #ifndef MLPACK_CORE_DATA_LOAD_HPP
15 #define MLPACK_CORE_DATA_LOAD_HPP
64 arma::Mat<eT>& matrix,
65 const bool fatal =
false,
66 const bool transpose =
true);
81 extern template bool Load<unsigned int>(
const std::string&,
82 arma::Mat<unsigned int>&,
86 extern template bool Load<unsigned long>(
const std::string&,
87 arma::Mat<unsigned long>&,
91 extern template bool Load<unsigned long long>(
const std::string&,
92 arma::Mat<unsigned long long>&,
96 extern template bool Load<float>(
const std::string&,
101 extern template bool Load<double>(
const std::string&,
137 template<
typename eT>
140 const bool fatal =
false);
169 template<
typename eT>
171 arma::Row<eT>& rowvec,
172 const bool fatal =
false);
206 template<
typename eT,
typename PolicyType>
208 arma::Mat<eT>& matrix,
209 DatasetMapper<PolicyType>& info,
210 const bool fatal =
false,
211 const bool transpose =
true);
220 extern template bool Load<int, IncrementPolicy>(
223 DatasetMapper<IncrementPolicy>&,
227 extern template bool Load<arma::u32, IncrementPolicy>(
229 arma::Mat<arma::u32>&,
230 DatasetMapper<IncrementPolicy>&,
234 extern template bool Load<arma::u64, IncrementPolicy>(
236 arma::Mat<arma::u64>&,
237 DatasetMapper<IncrementPolicy>&,
241 extern template bool Load<float, IncrementPolicy>(
244 DatasetMapper<IncrementPolicy>&,
248 extern template bool Load<double, IncrementPolicy>(
251 DatasetMapper<IncrementPolicy>&,
288 const bool fatal =
false,
304 template<
typename eT>
306 arma::Mat<eT>& matrix,
308 const bool fatal =
false);
320 template<
typename eT>
321 bool Load(
const std::vector<std::string>& files,
322 arma::Mat<eT>& matrix,
324 const bool fatal =
false);
328 arma::Mat<unsigned char>& matrix,
330 const bool fatal =
false);
336 #include "load_model_impl.hpp"
338 #include "load_vec_impl.hpp"
340 #include "load_image_impl.hpp"
format
Define the formats we can read through boost::serialization.
The core includes that mlpack expects; standard C++ includes and Armadillo.
bool LoadImage(const std::string &filename, arma::Mat< unsigned char > &matrix, ImageInfo &info, const bool fatal=false)
bool Load(const std::string &filename, arma::Mat< eT > &matrix, const bool fatal=false, const bool transpose=true)
Loads a matrix from file, guessing the filetype from the extension.
string(REGEX REPLACE".*#define MLPACK_VERSION_MINOR ([0-9]+).*""\\1"MLPACK_VERSION_MINOR"${VERSION_HPP_CONTENTS}") string(REGEX REPLACE".* "\\1" MLPACK_VERSION_PATCH "$