| 602 | class SortedCSCPageSource : public PageSourceIncMixIn<SortedCSCPage> { |
| 603 | protected: |
| 604 | void Fetch() final { |
| 605 | if (!this->ReadCache()) { |
| 606 | auto const& csr = this->source_->Page(); |
| 607 | this->page_.reset(new SortedCSCPage{}); |
| 608 | // we might be able to optimize this by merging transpose and pushcsc |
| 609 | this->page_->PushCSC(csr->GetTranspose(n_features_, nthreads_)); |
| 610 | CHECK_EQ(this->page_->Size(), n_features_); |
| 611 | CHECK_EQ(this->page_->data.Size(), csr->data.Size()); |
| 612 | this->page_->SortRows(this->nthreads_); |
| 613 | page_->SetBaseRowId(csr->base_rowid); |
| 614 | this->WriteCache(); |
| 615 | } |
| 616 | } |
| 617 | |
| 618 | public: |
| 619 | SortedCSCPageSource(float missing, int nthreads, bst_feature_t n_features, uint32_t n_batches, |
no test coverage detected