| 574 | } |
| 575 | |
| 576 | XGB_DLL int XGDMatrixCreateFromMat(const bst_float *data, xgboost::bst_ulong nrow, |
| 577 | xgboost::bst_ulong ncol, bst_float missing, DMatrixHandle *out) { |
| 578 | API_BEGIN(); |
| 579 | data::DenseAdapter adapter(data, nrow, ncol); |
| 580 | xgboost_CHECK_C_ARG_PTR(out); |
| 581 | *out = new std::shared_ptr<DMatrix>(DMatrix::Create(&adapter, missing, 1)); |
| 582 | API_END(); |
| 583 | } |
| 584 | |
| 585 | XGB_DLL int XGDMatrixCreateFromMat_omp(const bst_float *data, // NOLINT |
| 586 | xgboost::bst_ulong nrow, xgboost::bst_ulong ncol, |