fix DMatrix load_row_split bug (#3431)
This commit is contained in:
parent
8973f2cb0e
commit
5850a2558a
@ -213,11 +213,13 @@ int XGDMatrixCreateFromFile(const char *fname,
|
||||
int silent,
|
||||
DMatrixHandle *out) {
|
||||
API_BEGIN();
|
||||
bool load_row_split = false;
|
||||
if (rabit::IsDistributed()) {
|
||||
LOG(CONSOLE) << "XGBoost distributed mode detected, "
|
||||
<< "will split data among workers";
|
||||
load_row_split = true;
|
||||
}
|
||||
*out = new std::shared_ptr<DMatrix>(DMatrix::Load(fname, silent != 0, true));
|
||||
*out = new std::shared_ptr<DMatrix>(DMatrix::Load(fname, silent != 0, load_row_split));
|
||||
API_END();
|
||||
}
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user