I trained my model in R using XGBoost and now need to do predictions in C++. I am trying to load the model file in C++ using XGBoosterLoadModel function.
My code compiles fine but it fails at discovering my unit-test functions. When I remove the call to function XGBoosterLoadModel, everything works fine and I can see my unit tests.
Here's what I have in my unit test file. Any clue on what I'm missing would be really appreciated:
#include <xgboost/c_api.h>
#include "stdafx.h"
#include <google/gtest/gtest.h>
namespace UnitTests
{
TEST(XGBoost, HysteresisPeakDetection_WithEmptyInput_ReturnsFalse)
{
const char *fname;
BoosterHandle handle;
int a = XGBoosterLoadModel(handle, fname);
}
}
Aucun commentaire:
Enregistrer un commentaire