Advertisement
Guest User

Error Mlpack

a guest
Apr 11th, 2015
262
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 6.12 KB | None | 0 0
  1. Command: g++ -lmlpack test.cpp -I /usr/include/libxml2
  2.  
  3. Error
  4. In file included from /usr/include/c++/4.9/random:35:0,
  5. from /usr/local/include/mlpack/core/math/random.hpp:10,
  6. from /usr/local/include/mlpack/core.hpp:161,
  7. from test.cpp:1:
  8. /usr/include/c++/4.9/bits/c++0x_warning.h:32:2: error: #error This file requires compiler and library support for the ISO C++ 2011 standard. This support is currently experimental, and must be enabled with the -std=c++11 or -std=gnu++11 compiler options.
  9. #error This file requires compiler and library support for the \
  10. ^
  11. In file included from /usr/local/include/mlpack/core.hpp:156:0,
  12. from test.cpp:1:
  13. /usr/local/include/mlpack/core/util/ostream_extra.hpp:31:58: error: default template arguments may not be used in function templates without -std=c++11 or -std=gnu++11
  14. std::ostream& operator<<(std::ostream& stream, const T& t)
  15. ^
  16. In file included from /usr/local/include/mlpack/core.hpp:161:0,
  17. from test.cpp:1:
  18. /usr/local/include/mlpack/core/math/random.hpp:16:13: error: ‘mt19937’ in namespace ‘std’ does not name a type
  19. extern std::mt19937 randGen;
  20. ^
  21. /usr/local/include/mlpack/core/math/random.hpp:18:13: error: ‘uniform_real_distribution’ in namespace ‘std’ does not name a template type
  22. extern std::uniform_real_distribution<> randUniformDist;
  23. ^
  24. /usr/local/include/mlpack/core/math/random.hpp:20:13: error: ‘normal_distribution’ in namespace ‘std’ does not name a template type
  25. extern std::normal_distribution<> randNormalDist;
  26. ^
  27. /usr/local/include/mlpack/core/math/random.hpp: In function ‘void mlpack::math::RandomSeed(size_t)’:
  28. /usr/local/include/mlpack/core/math/random.hpp:31:3: error: ‘randGen’ was not declared in this scope
  29. randGen.seed((uint32_t) seed);
  30. ^
  31. /usr/local/include/mlpack/core/math/random.hpp: In function ‘double mlpack::math::Random()’:
  32. /usr/local/include/mlpack/core/math/random.hpp:46:26: error: ‘randGen’ was not declared in this scope
  33. return randUniformDist(randGen);
  34. ^
  35. /usr/local/include/mlpack/core/math/random.hpp:46:33: error: ‘randUniformDist’ was not declared in this scope
  36. return randUniformDist(randGen);
  37. ^
  38. /usr/local/include/mlpack/core/math/random.hpp: In function ‘double mlpack::math::Random(double, double)’:
  39. /usr/local/include/mlpack/core/math/random.hpp:54:43: error: ‘randGen’ was not declared in this scope
  40. return lo + (hi - lo) * randUniformDist(randGen);
  41. ^
  42. /usr/local/include/mlpack/core/math/random.hpp:54:50: error: ‘randUniformDist’ was not declared in this scope
  43. return lo + (hi - lo) * randUniformDist(randGen);
  44. ^
  45. /usr/local/include/mlpack/core/math/random.hpp: In function ‘int mlpack::math::RandInt(int)’:
  46. /usr/local/include/mlpack/core/math/random.hpp:62:66: error: ‘randGen’ was not declared in this scope
  47. return (int) std::floor((double) hiExclusive * randUniformDist(randGen));
  48. ^
  49. /usr/local/include/mlpack/core/math/random.hpp:62:73: error: ‘randUniformDist’ was not declared in this scope
  50. return (int) std::floor((double) hiExclusive * randUniformDist(randGen));
  51. ^
  52. /usr/local/include/mlpack/core/math/random.hpp: In function ‘int mlpack::math::RandInt(int, int)’:
  53. /usr/local/include/mlpack/core/math/random.hpp:71:50: error: ‘randGen’ was not declared in this scope
  54. * randUniformDist(randGen));
  55. ^
  56. /usr/local/include/mlpack/core/math/random.hpp:71:57: error: ‘randUniformDist’ was not declared in this scope
  57. * randUniformDist(randGen));
  58. ^
  59. /usr/local/include/mlpack/core/math/random.hpp: In function ‘double mlpack::math::RandNormal()’:
  60. /usr/local/include/mlpack/core/math/random.hpp:79:25: error: ‘randGen’ was not declared in this scope
  61. return randNormalDist(randGen);
  62. ^
  63. /usr/local/include/mlpack/core/math/random.hpp:79:32: error: ‘randNormalDist’ was not declared in this scope
  64. return randNormalDist(randGen);
  65. ^
  66. /usr/local/include/mlpack/core/math/random.hpp: In function ‘double mlpack::math::RandNormal(double, double)’:
  67. /usr/local/include/mlpack/core/math/random.hpp:91:36: error: ‘randGen’ was not declared in this scope
  68. return variance * randNormalDist(randGen) + mean;
  69. ^
  70. /usr/local/include/mlpack/core/math/random.hpp:91:43: error: ‘randNormalDist’ was not declared in this scope
  71. return variance * randNormalDist(randGen) + mean;
  72. ^
  73. In file included from /usr/local/include/mlpack/core.hpp:167:0,
  74. from test.cpp:1:
  75. /usr/local/include/mlpack/core/dists/gaussian_distribution.hpp: At global scope:
  76. /usr/local/include/mlpack/core/dists/gaussian_distribution.hpp:34:16: error: ‘constexpr’ does not name a type
  77. static const constexpr double log2pi = 1.83787706640934533908193770912475883;
  78. ^
  79. /usr/local/include/mlpack/core/dists/gaussian_distribution.hpp:34:16: note: C++11 ‘constexpr’ only available with -std=c++11 or -std=gnu++11
  80. /usr/local/include/mlpack/core/dists/gaussian_distribution.hpp:138:28: error: expected ‘,’ or ‘...’ before ‘&&’ token
  81. void Covariance(arma::mat&& covariance);
  82. ^
  83. /usr/local/include/mlpack/core/dists/gaussian_distribution.hpp: In member function ‘void mlpack::distribution::GaussianDistribution::LogProbability(const mat&, arma::vec&) const’:
  84. /usr/local/include/mlpack/core/dists/gaussian_distribution.hpp:181:33: error: ‘log2pi’ was not declared in this scope
  85. logProbabilities = -0.5 * k * log2pi - 0.5 * logDetCov + logExponents;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement