Let us if this resolves the binding issues
Signed-off-by: Omar Shrit <omar@shrit.me>
This commit is contained in:
@@ -14,6 +14,7 @@
|
||||
|
||||
#include <mlpack/prereqs.hpp>
|
||||
#include "ccov.hpp"
|
||||
#include "random.hpp"
|
||||
|
||||
/**
|
||||
* Linear algebra utility functions, generally performed on matrices or vectors.
|
||||
|
||||
@@ -91,8 +91,8 @@ inline void RandVector(arma::vec& v)
|
||||
|
||||
for (size_t i = 0; i + 1 < v.n_elem; i += 2)
|
||||
{
|
||||
double a = Random();
|
||||
double b = Random();
|
||||
double a = math::Random();
|
||||
double b = math::Random();
|
||||
double first_term = sqrt(-2 * log(a));
|
||||
double second_term = 2 * M_PI * b;
|
||||
v[i] = first_term * cos(second_term);
|
||||
|
||||
@@ -40,6 +40,7 @@
|
||||
#include <mlpack/methods/cf/neighbor_search_policies/pearson_search.hpp>
|
||||
|
||||
using namespace mlpack;
|
||||
using namespace mlpack::math;
|
||||
using namespace mlpack::cf;
|
||||
using namespace mlpack::amf;
|
||||
using namespace mlpack::svd;
|
||||
@@ -202,9 +203,9 @@ PARAM_STRING_IN("neighbor_search", "Algorithm used for neighbor search.",
|
||||
void BINDING_FUNCTION(util::Params& params, util::Timers& timers)
|
||||
{
|
||||
if (params.Get<int>("seed") == 0)
|
||||
math::RandomSeed(std::time(NULL));
|
||||
RandomSeed(std::time(NULL));
|
||||
else
|
||||
math::RandomSeed(params.Get<int>("seed"));
|
||||
RandomSeed(params.Get<int>("seed"));
|
||||
|
||||
// Validate parameters.
|
||||
RequireOnlyOnePassed(params, { "training", "input_model" }, true);
|
||||
|
||||
Reference in New Issue
Block a user