Initial support for multioutput regression. (#7514)
* Add num target model parameter, which is configured from input labels. * Change elementwise metric and indexing for weights. * Add demo. * Add tests.
This commit is contained in:
@@ -92,6 +92,7 @@ TEST(CAPI, ConfigIO) {
|
||||
labels[i] = i;
|
||||
}
|
||||
p_dmat->Info().labels.Data()->HostVector() = labels;
|
||||
p_dmat->Info().labels.Reshape(kRows);
|
||||
|
||||
std::shared_ptr<Learner> learner { Learner::Create(mat) };
|
||||
|
||||
@@ -126,6 +127,7 @@ TEST(CAPI, JsonModelIO) {
|
||||
labels[i] = i;
|
||||
}
|
||||
p_dmat->Info().labels.Data()->HostVector() = labels;
|
||||
p_dmat->Info().labels.Reshape(kRows);
|
||||
|
||||
std::shared_ptr<Learner> learner { Learner::Create(mat) };
|
||||
|
||||
|
||||
Reference in New Issue
Block a user