File tree Expand file tree Collapse file tree 2 files changed +2
-12
lines changed Expand file tree Collapse file tree 2 files changed +2
-12
lines changed Original file line number Diff line number Diff line change @@ -118,7 +118,7 @@ TEST(GBTree, ChoosePredictor) {
118
118
119
119
auto p_dmat = RandomDataGenerator (kRows , kCols , 0 ).GenerateDMatrix ();
120
120
121
- auto & data = (*(p_dmat->GetBatches <SparsePage>().begin ())).data ;
121
+ auto const & data = (*(p_dmat->GetBatches <SparsePage>().begin ())).data ;
122
122
p_dmat->Info ().labels .Reshape (kRows );
123
123
124
124
auto learner = std::unique_ptr<Learner>(Learner::Create ({p_dmat}));
@@ -145,7 +145,7 @@ TEST(GBTree, ChoosePredictor) {
145
145
for (size_t i = 0 ; i < 4 ; ++i) {
146
146
learner->UpdateOneIter (i, p_dmat);
147
147
}
148
- ASSERT_TRUE (data.HostCanWrite ());
148
+ ASSERT_TRUE (data.HostCanRead ());
149
149
150
150
// pull data into device.
151
151
data.HostVector ();
Original file line number Diff line number Diff line change @@ -342,16 +342,6 @@ TEST(Learner, GPUConfiguration) {
342
342
learner->UpdateOneIter (0 , p_dmat);
343
343
ASSERT_EQ (learner->Ctx ()->gpu_id , 0 );
344
344
}
345
- {
346
- // With CPU algorithm but GPU Predictor, this is to simulate when
347
- // XGBoost is only used for prediction, so tree method is not
348
- // specified.
349
- std::unique_ptr<Learner> learner {Learner::Create (mat)};
350
- learner->SetParams ({Arg{" tree_method" , " hist" },
351
- Arg{" predictor" , " gpu_predictor" }});
352
- learner->UpdateOneIter (0 , p_dmat);
353
- ASSERT_EQ (learner->Ctx ()->gpu_id , 0 );
354
- }
355
345
}
356
346
#endif // defined(XGBOOST_USE_CUDA)
357
347
You can’t perform that action at this time.
0 commit comments