mlpack
Classes | Macros | Functions
nca_test.cpp File Reference
#include <string>
#include <mlpack/core.hpp>
#include <mlpack/core/util/mlpack_main.hpp>
#include <mlpack/core/metrics/lmetric.hpp>
#include <mlpack/methods/nca/nca_main.cpp>
#include <ensmallen.hpp>
#include "test_helper.hpp"
#include "../test_catch_tools.hpp"
#include "../catch.hpp"
Include dependency graph for nca_test.cpp:

Classes

struct  NCATestFixture
 

Macros

#define BINDING_TYPE   BINDING_TYPE_TEST
 

Functions

 TEST_CASE_METHOD (NCATestFixture, "NCAExplicitImplicitLabelsTest", "[NCAMainTest][BindingTests]")
 Ensure that, when labels are implicitily given with input, the last column is treated as labels and that we get the desired shape of output.
 
 TEST_CASE_METHOD (NCATestFixture, "NCALBFGSTest", "[NCAMainTest][BindingTests]")
 Ensure that when we pass optimizer of type lbfgs, we also get the desired shape of output.
 
 TEST_CASE_METHOD (NCATestFixture, "NCALabelSizeTest", "[NCAMainTest][BindingTests]")
 Ensure that if labels are of a different size than required by the input, an error occurs.
 
 TEST_CASE_METHOD (NCATestFixture, "NCANormalizationTest", "[NCAMainTest][BindingTests]")
 Ensure that setting normalize as true results in a different output matrix then when set to false.
 
 TEST_CASE_METHOD (NCATestFixture, "NCADifferentStepSizeTest", "[NCAMainTest][BindingTests]")
 Ensure that output is different when step_size is different.
 
 TEST_CASE_METHOD (NCATestFixture, "NCADifferentToleranceTest", "[NCAMainTest][BindingTests]")
 Ensure that output is different when the tolerance is different.
 
 TEST_CASE_METHOD (NCATestFixture, "NCADifferentBatchSizeTest", "[NCAMainTest][BindingTests]")
 Ensure that output is different when batch_size is different.
 
 TEST_CASE_METHOD (NCATestFixture, "NCALinearScanTest", "[NCAMainTest][BindingTests]")
 Ensure that output is different when setting linear_scan to false.
 
 TEST_CASE_METHOD (NCATestFixture, "NCALinearScanTest2", "[NCAMainTest][BindingTests]")
 Ensure that output is the same when same data is used with linear_scan set.
 
 TEST_CASE_METHOD (NCATestFixture, "NCADifferentNumBasisTest", "[NCAMainTest][BindingTests]")
 Ensure that different value of NumBasis results in a different output matrix.
 
 TEST_CASE_METHOD (NCATestFixture, "NCADifferentMaxIterationTest", "[NCAMainTest][BindingTests]")
 Ensure that using a different value of max_iteration results in a different output matrix.
 

Detailed Description

Author
Yasmine Dumouchel

Test mlpackMain() of nca_main.cpp.

mlpack is free software; you may redistribute it and/or modify it under the terms of the 3-clause BSD license. You should have received a copy of the 3-clause BSD license along with mlpack. If not, see http://www.opensource.org/licenses/BSD-3-Clause for more information.