File: test_prediction_cache.cc

package info (click to toggle)
xgboost 3.0.0-1
  • links: PTS, VCS
  • area: main
  • in suites: trixie
  • size: 13,796 kB
  • sloc: cpp: 67,502; python: 35,503; java: 4,676; ansic: 1,426; sh: 1,320; xml: 1,197; makefile: 204; javascript: 19
file content (35 lines) | stat: -rw-r--r-- 875 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
/**
 * Copyright 2021-2023 by XGBoost contributors
 */
#include <gtest/gtest.h>

#include "test_prediction_cache.h"

namespace xgboost {
TEST_F(TestPredictionCache, Approx) {
  Context ctx;
  this->RunTest(&ctx, "grow_histmaker", "one_output_per_tree");
}

TEST_F(TestPredictionCache, Hist) {
  Context ctx;
  this->RunTest(&ctx, "grow_quantile_histmaker", "one_output_per_tree");
}

TEST_F(TestPredictionCache, HistMulti) {
  Context ctx;
  this->RunTest(&ctx, "grow_quantile_histmaker", "multi_output_tree");
}

#if defined(XGBOOST_USE_CUDA)
TEST_F(TestPredictionCache, GpuHist) {
  auto ctx = MakeCUDACtx(0);
  this->RunTest(&ctx, "grow_gpu_hist", "one_output_per_tree");
}

TEST_F(TestPredictionCache, GpuApprox) {
  auto ctx = MakeCUDACtx(0);
  this->RunTest(&ctx, "grow_gpu_approx", "one_output_per_tree");
}
#endif  // defined(XGBOOST_USE_CUDA)
}  // namespace xgboost