| 598 | #endif // !defined(XGBOOST_USE_CUDA) |
| 599 | |
| 600 | NumpyArrayIterForTest::NumpyArrayIterForTest(float sparsity, bst_idx_t rows, size_t cols, |
| 601 | size_t batches) |
| 602 | : ArrayIterForTest{sparsity, rows, cols, batches} { |
| 603 | rng_->Device(DeviceOrd::CPU()); |
| 604 | std::tie(batches_, interface_) = rng_->GenerateArrayInterfaceBatch(&data_, n_batches_); |
| 605 | this->Reset(); |
| 606 | } |
| 607 | |
| 608 | int NumpyArrayIterForTest::Next() { |
| 609 | if (iter_ == n_batches_) { |
nothing calls this directly
no test coverage detected