Unverified Commit 96ecab6f authored by Nikita Titov's avatar Nikita Titov Committed by GitHub
Browse files

Remove checks for label when loading dataset from binary file because label is...

Remove checks for label when loading dataset from binary file because label is ignored in that case (#4737)
parent 798dc1d4
......@@ -834,16 +834,6 @@ void DatasetLoader::CheckDataset(const Dataset* dataset, bool is_load_from_binar
Log::Fatal("Parameter max_bin_by_feature cannot be changed when loading from binary file.");
}
int label_idx = -1;
if (Common::AtoiAndCheck(config_.label_column.c_str(), &label_idx)) {
if (dataset->label_idx_ != label_idx) {
Log::Fatal("Dataset was constructed with label index %d. It cannot be changed to %d when loading from binary file.",
dataset->label_idx_, label_idx);
}
} else {
Log::Info("It is recommended to use integer for label index when loading from binary file for sanity check.");
}
if (config_.label_column != "") {
Log::Warning("Parameter label_column works only in case of loading data directly from text file. It will be ignored when loading from binary file.");
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment