[dask] Allow empty data matrix in AFT survival (#6379)

* [dask] Allow empty data matrix in AFT survival

* Add unit test
This commit is contained in:
Philip Hyunsu Cho
2020-11-12 17:49:58 -08:00
committed by GitHub
parent 5a33c2f3a0
commit e5193c21a1
3 changed files with 11 additions and 6 deletions

View File

@@ -206,10 +206,6 @@ struct EvalEWiseSurvivalBase : public Metric {
bst_float Eval(const HostDeviceVector<bst_float>& preds,
const MetaInfo& info,
bool distributed) override {
CHECK_NE(info.labels_lower_bound_.Size(), 0U)
<< "labels_lower_bound cannot be empty";
CHECK_NE(info.labels_upper_bound_.Size(), 0U)
<< "labels_upper_bound cannot be empty";
CHECK_EQ(preds.Size(), info.labels_lower_bound_.Size());
CHECK_EQ(preds.Size(), info.labels_upper_bound_.Size());