Fix cpplint. (#4157)

* Add comment after #endif.
* Add missing headers.
This commit is contained in:
Jiaming Yuan
2019-02-18 00:16:29 +08:00
committed by GitHub
parent 71a604fae3
commit 2e618af743
46 changed files with 97 additions and 72 deletions

View File

@@ -10,6 +10,7 @@
#include <unordered_set>
#include <vector>
#include <limits>
#include <memory>
#include <string>
#include <sstream>
#include <utility>

View File

@@ -11,6 +11,7 @@
#include <dmlc/registry.h>
#include <xgboost/base.h>
#include <functional>
#include <memory>
#include <string>
#include <utility>
#include <vector>

View File

@@ -37,6 +37,6 @@ DMLC_REGISTRY_LINK_TAG(updater_sync);
#ifdef XGBOOST_USE_CUDA
DMLC_REGISTRY_LINK_TAG(updater_gpu);
DMLC_REGISTRY_LINK_TAG(updater_gpu_hist);
#endif
#endif // XGBOOST_USE_CUDA
} // namespace tree
} // namespace xgboost

View File

@@ -597,7 +597,7 @@ class ColMaker: public TreeUpdater {
const auto num_features = static_cast<bst_omp_uint>(feat_set.size());
#if defined(_OPENMP)
const int batch_size = std::max(static_cast<int>(num_features / this->nthread_ / 32), 1);
#endif
#endif // defined(_OPENMP)
int poption = param_.parallel_option;
if (poption == 2) {
poption = static_cast<int>(num_features) * 2 < this->nthread_ ? 1 : 0;

View File

@@ -16,6 +16,7 @@
#include <string>
#include <queue>
#include <iomanip>
#include <unordered_map>
#include <utility>
#include "./param.h"