diff --git a/src/mlpack/tests/ann_layer_test.cpp b/src/mlpack/tests/ann_layer_test.cpp index 9c803a3416..247e17e338 100644 --- a/src/mlpack/tests/ann_layer_test.cpp +++ b/src/mlpack/tests/ann_layer_test.cpp @@ -355,7 +355,7 @@ BOOST_AUTO_TEST_CASE(SimpleDropoutLayerTest) /** * Perform dropout x times using ones as input, sum the number of ones and - * validate that the layer is is producing approximately the right number of + * validate that the layer is producing approximately the correct number of * ones. */ BOOST_AUTO_TEST_CASE(DropoutProbabilityTest) diff --git a/src/mlpack/tests/main_tests/decision_tree_test.cpp b/src/mlpack/tests/main_tests/decision_tree_test.cpp index 716adba394..2ff723de0d 100644 --- a/src/mlpack/tests/main_tests/decision_tree_test.cpp +++ b/src/mlpack/tests/main_tests/decision_tree_test.cpp @@ -77,14 +77,14 @@ BOOST_AUTO_TEST_CASE(DecisionTreeOutputDimensionTest) // Check that number of output points are equal to number of input points. BOOST_REQUIRE_EQUAL(CLI::GetParam>("predictions").n_cols, - testSize); + testSize); BOOST_REQUIRE_EQUAL(CLI::GetParam("probabilities").n_cols, - testSize); + testSize); // Check number of output rows equals number of classes in case of // probabilities and 1 for predictions. - BOOST_REQUIRE_EQUAL(CLI::GetParam>("predictions").n_rows, - 1); + BOOST_REQUIRE_EQUAL( + CLI::GetParam>("predictions").n_rows, 1); BOOST_REQUIRE_EQUAL(CLI::GetParam("probabilities").n_rows, 3); } @@ -160,20 +160,20 @@ BOOST_AUTO_TEST_CASE(DecisionModelReuseTest) // Input trained model. SetInputParam("test", std::move(testData)); SetInputParam("input_model", - std::move(CLI::GetParam("output_model"))); + std::move(CLI::GetParam("output_model"))); mlpackMain(); // Check that number of output points are equal to number of input points. BOOST_REQUIRE_EQUAL(CLI::GetParam>("predictions").n_cols, - testSize); + testSize); BOOST_REQUIRE_EQUAL(CLI::GetParam("probabilities").n_cols, - testSize); + testSize); // Check number of output rows equals number of classes in case of // probabilities and 1 for predicitions. - BOOST_REQUIRE_EQUAL(CLI::GetParam>("predictions").n_rows, - 1); + BOOST_REQUIRE_EQUAL( + CLI::GetParam>("predictions").n_rows, 1); BOOST_REQUIRE_EQUAL(CLI::GetParam("probabilities").n_rows, 3); // Check that initial predictions and predictions using saved model are same. diff --git a/src/mlpack/tests/main_tests/emst_test.cpp b/src/mlpack/tests/main_tests/emst_test.cpp index 65e400ce01..f49d934a88 100644 --- a/src/mlpack/tests/main_tests/emst_test.cpp +++ b/src/mlpack/tests/main_tests/emst_test.cpp @@ -122,11 +122,9 @@ BOOST_AUTO_TEST_CASE(EMSTFirstTwoOutputRowsIntegerTest) for (size_t i = 0; i < CLI::GetParam("output").n_cols; i++) { BOOST_REQUIRE_CLOSE(CLI::GetParam("output")(0, i), - boost::math::iround( - CLI::GetParam("output")(0, i)), 1e-5); + boost::math::iround(CLI::GetParam("output")(0, i)), 1e-5); BOOST_REQUIRE_CLOSE(CLI::GetParam("output")(1, i), - boost::math::iround( - CLI::GetParam("output")(1, i)), 1e-5); + boost::math::iround(CLI::GetParam("output")(1, i)), 1e-5); } } diff --git a/src/mlpack/tests/main_tests/linear_regression_test.cpp b/src/mlpack/tests/main_tests/linear_regression_test.cpp index 0507eb43ab..e3d0d7993d 100644 --- a/src/mlpack/tests/main_tests/linear_regression_test.cpp +++ b/src/mlpack/tests/main_tests/linear_regression_test.cpp @@ -171,7 +171,7 @@ BOOST_AUTO_TEST_CASE(LRWrongResponseSizeTest) } /** - * Ensuring that test data dimensionality is is checked. + * Ensuring that test data dimensionality is checked. */ BOOST_AUTO_TEST_CASE(LRWrongDimOfDataTest1) { @@ -193,7 +193,7 @@ BOOST_AUTO_TEST_CASE(LRWrongDimOfDataTest1) } /** - * Ensuring that test data dimensionality is is checked when model is loaded. + * Ensuring that test data dimensionality is checked when model is loaded. */ BOOST_AUTO_TEST_CASE(LRWrongDimOfDataTest2) { diff --git a/src/mlpack/tests/main_tests/preprocess_imputer_test.cpp b/src/mlpack/tests/main_tests/preprocess_imputer_test.cpp index d7e16ee795..bf30f102eb 100644 --- a/src/mlpack/tests/main_tests/preprocess_imputer_test.cpp +++ b/src/mlpack/tests/main_tests/preprocess_imputer_test.cpp @@ -122,9 +122,9 @@ BOOST_AUTO_TEST_CASE(PreprocessImputerListwiseDimensionTest) if (std::to_string(inputData(0, i)) == "nan" || std::to_string(inputData(1, i)) == "nan" || std::to_string(inputData(2, i)) == "nan") - { - countNaN++; - } + { + countNaN++; + } } // Input custom data points and labels. diff --git a/src/mlpack/tests/main_tests/preprocess_split_test.cpp b/src/mlpack/tests/main_tests/preprocess_split_test.cpp index 44ca6ebcdd..5911e92b8c 100644 --- a/src/mlpack/tests/main_tests/preprocess_split_test.cpp +++ b/src/mlpack/tests/main_tests/preprocess_split_test.cpp @@ -105,9 +105,9 @@ BOOST_AUTO_TEST_CASE(PreprocessSplitLabelLessDimensionTest) // Now check that the output has desired dimensions. BOOST_REQUIRE_EQUAL(CLI::GetParam("training").n_cols, - std::ceil(0.9 * inputSize)); + std::ceil(0.9 * inputSize)); BOOST_REQUIRE_EQUAL(CLI::GetParam("test").n_cols, - std::floor(0.1 * inputSize)); + std::floor(0.1 * inputSize)); } /** @@ -161,8 +161,8 @@ BOOST_AUTO_TEST_CASE(PreprocessSplitZeroTestRatioTest) BOOST_REQUIRE_EQUAL( CLI::GetParam>("training_labels").n_cols, labelSize); - BOOST_REQUIRE_EQUAL(CLI::GetParam>("test_labels").n_cols, - 0); + BOOST_REQUIRE_EQUAL( + CLI::GetParam>("test_labels").n_cols, 0); } /** diff --git a/src/mlpack/tests/nystroem_method_test.cpp b/src/mlpack/tests/nystroem_method_test.cpp index e0f1f75840..c29f78f101 100644 --- a/src/mlpack/tests/nystroem_method_test.cpp +++ b/src/mlpack/tests/nystroem_method_test.cpp @@ -157,7 +157,7 @@ BOOST_AUTO_TEST_CASE(GermanTest) // The bandwidth of the kernel is selected to be the half the average // distance between each point and the mean of the dataset. This isn't // _exactly_ what the paper says, but I've modified what it said because our - // formulation of what the Gaussian kernel is is different. + // formulation of what the Gaussian kernel is different. GaussianKernel gk(16.461); // Calculate the true kernel matrix.