Scalable, Portable and Distributed Gradient Boosting (GBDT, GBRT or GBM) Library, for Python, R, Java, Scala, C and more. Runs on single machine, Hadoop, Spark, Dask, Flink and DataFlow
This report summarizes scanner evidence for dmlc/xgboost, a C++ project with 28,847 GitHub stars. SynthScan examined 144,722 lines of code across 757 source files, recording 862 pattern matches distributed across 19 syntactic categories. The legacy adjusted pattern signal is 7.1 (Moderate pattern signal); it is not an authorship estimate.
Use the findings to ask whether maintainers can explain intent, verify dependencies, simplify unnecessary scaffolding, and focus review effort. Risk Payload v1 adds ownership, supply-chain, over-engineering, and review-effort vectors when available. These are prompts for human verification, not probabilities, security findings, or measured maintenance costs.
Use each vector to guide manual verification of the underlying findings.
Can maintainers explain intent, assumptions, and trade-offs? 734 finding(s).
Are imports declared and package/API names verified? 75 finding(s).
Are wrappers, guards, and repeated structures necessary? 394 finding(s).
Which changes need focused human review? 862 finding(s).
This chart tracks the legacy adjusted pattern score across scan runs. Changes can reflect source changes, scan coverage, or detector/scoring versions; they do not measure AI adoption or prove that a team refactored code. Compare runs only when their scoring versions are compatible. The dashed line tracks the raw pattern-hit count.
Groups findings by configured severity weight. Severity is not a confidence estimate, security rating, or proof that a package is missing. Verify imports against the project's manifests and inspect each finding in its local design context.
This horizontal bar chart shows where configured pattern scores accumulate across directories. Treat the bars as locations to inspect, not as evidence of authorship or code quality. Use the file-level findings to decide whether a directory needs a focused ownership, dependency, complexity, or review check.
The scanner identified 862 distinct pattern matches across 19 syntactic categories. Each entry below represents a discrete location in the source code where the engine recorded a detector match to inspect in context. Expand any category row to inspect the individual file paths, line numbers, code snippets, and the lexical context (CODE, COMMENT, or STRING) in which each match was detected.
Reading the findings table: The Severity column indicates the configured finding weight (CRITICAL / HIGH / MEDIUM / LOW). The Context column identifies whether the match occurred inside executable code, an inline comment, or a string literal — legacy comment-context matches receive a ×1.5 score weight. The ⚡ bolt icon marks clustered matches: three or more patterns within a 10-line window, each receiving an additional ×1.5 density multiplier under the legacy scoring model.
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | demo/dask/gpu_training.py | 42 | def using_quantile_device_dmatrix(client: Client, X: da.Array, y: da.Array) -> da.Array: | CODE |
| LOW | demo/dask/dask_callbacks.py | 18 | def probability_for_going_backward(epoch: int) -> float: | CODE |
| LOW | demo/guide-python/continuation.py | 50 | def training_continuation_early_stop(tmpdir: str, use_pickle: bool) -> None: | CODE |
| LOW | demo/guide-python/prediction_intervals.py | 139 | def plot_prediction_intervals( | CODE |
| LOW | tests/python/test_ordinal.py | 34 | def test_cat_container_model_slice() -> None: | CODE |
| LOW | tests/python/test_ordinal.py | 57 | def test_pd_cat_nullable_integer( | CODE |
| LOW | tests/python/test_ordinal.py | 78 | def test_pd_cat_nullable_float() -> None: | CODE |
| LOW | tests/python/test_ordinal.py | 131 | def test_training_continuation() -> None: | CODE |
| LOW | tests/python/test_ordinal.py | 139 | def test_recode_dmatrix_predict() -> None: | CODE |
| LOW | tests/python/test_training_continuation.py | 38 | def run_training_continuation( | CODE |
| LOW | tests/python/test_training_continuation.py | 135 | def test_training_continuation_json(self, tmp_path: Path) -> None: | CODE |
| LOW | tests/python/test_training_continuation.py | 140 | def test_training_continuation_updaters_json(self, tmp_path: Path) -> None: | CODE |
| LOW | tests/python/test_training_continuation.py | 175 | def test_continuation_determinism(kwargs: Any) -> None: | CODE |
| LOW | tests/python/test_basic.py | 201 | def test_dmatrix_numpy_init_omp(self): | CODE |
| LOW | tests/python/test_basic.py | 237 | def test_cv_explicit_fold_indices(self): | CODE |
| LOW | tests/python/test_basic.py | 251 | def test_cv_explicit_fold_indices_labels(self): | CODE |
| LOW | tests/python/test_basic.py | 333 | def test_parse_eval_str_nonfinite() -> None: | CODE |
| LOW | tests/python/test_early_stopping.py | 15 | def test_early_stopping_nonparallel(self): | CODE |
| LOW | tests/python/test_early_stopping.py | 122 | def test_cv_early_stopping_with_multiple_eval_sets_and_metrics(self): | CODE |
| LOW | tests/python/test_with_arrow.py | 39 | def test_arrow_table_with_custom_feature_names(self, DMatrixT): | CODE |
| LOW | tests/python/test_with_arrow.py | 48 | def test_arrow_table_with_label(self): | CODE |
| LOW | tests/python/test_with_arrow.py | 100 | def test_arrow_unsupported_dtype(self, DMatrixT): | CODE |
| LOW | tests/python/test_plotting.py | 105 | def test_importance_plot_show_values(self) -> None: | CODE |
| LOW | tests/python/test_data_iterator.py | 338 | def test_categorical_extmem_qdm( | CODE |
| LOW⚡ | tests/python/test_interaction_constraints.py | 11 | def test_exact_interaction_constraints(self) -> None: | CODE |
| LOW⚡ | tests/python/test_interaction_constraints.py | 14 | def test_hist_interaction_constraints(self) -> None: | CODE |
| LOW⚡ | tests/python/test_interaction_constraints.py | 17 | def test_approx_interaction_constraints(self) -> None: | CODE |
| LOW⚡ | tests/python/test_interaction_constraints.py | 20 | def test_hist_multi_interaction_constraints(self) -> None: | CODE |
| LOW⚡ | tests/python/test_interaction_constraints.py | 23 | def test_interaction_constraints_feature_names(self) -> None: | CODE |
| LOW | tests/python/test_interaction_constraints.py | 60 | def test_hist_training_accuracy(self, tree_method: str) -> None: | CODE |
| LOW | tests/python/test_model_io.py | 105 | def test_categorical_model_io(self, tmp_path: Path) -> None: | CODE |
| LOW | tests/python/test_model_io.py | 342 | def test_with_sklearn_obj_metric(tmp_path: Path) -> None: | CODE |
| LOW | tests/python/test_tree_regularization.py | 70 | def test_absolute_error_lambda(self): | CODE |
| LOW | tests/python/test_tree_regularization.py | 94 | def test_quantile_error_lambda(self): | CODE |
| LOW | tests/python/generate_models.py | 38 | def generate_regression_model() -> None: | CODE |
| LOW | tests/python/generate_models.py | 108 | def generate_classification_model() -> None: | CODE |
| LOW | tests/python/generate_models.py | 179 | def generate_aft_survival_models() -> None: | CODE |
| LOW | tests/python/test_callback.py | 127 | def test_early_stopping_custom_eval(self, breast_cancer: BreastCancer) -> None: | CODE |
| LOW | tests/python/test_callback.py | 147 | def test_early_stopping_customize(self, breast_cancer: BreastCancer) -> None: | CODE |
| LOW | tests/python/test_callback.py | 209 | def test_early_stopping_custom_eval_skl(self, breast_cancer: BreastCancer) -> None: | CODE |
| LOW | tests/python/test_callback.py | 221 | def test_early_stopping_save_best_model(self, breast_cancer: BreastCancer) -> None: | CODE |
| LOW | tests/python/test_callback.py | 261 | def test_early_stopping_continuation( | CODE |
| LOW | tests/python/test_callback.py | 295 | def test_early_stopping_multiple_metrics(self): | CODE |
| LOW | tests/python/test_callback.py | 317 | def test_eta_decay_leaf_output(self, tree_method: str, objective: str) -> None: | CODE |
| LOW | tests/python/test_basic_models.py | 105 | def test_boost_from_prediction(self): | CODE |
| LOW | tests/python/test_basic_models.py | 120 | def test_boost_from_existing_model(self) -> None: | CODE |
| LOW | tests/python/test_basic_models.py | 239 | def test_feature_names_validation(self): | CODE |
| LOW | tests/python/test_basic_models.py | 255 | def test_special_model_dump_characters(self) -> None: | CODE |
| LOW | tests/python/test_survival.py | 58 | def test_aft_survival_toy_data( | CODE |
| LOW | tests/python/test_survival.py | 137 | def test_aft_survival_demo_data(): | CODE |
| LOW | tests/python/test_dmatrix.py | 67 | def test_dmatrix_numpy_masked_array(self, dtype): | CODE |
| LOW | tests/python/test_dmatrix.py | 86 | def test_dmatrix_numpy_non_native_byte_order(self): | CODE |
| LOW | tests/python/test_predict.py | 17 | def test_inplace_predict_masked_array() -> None: | CODE |
| LOW | tests/python/test_predict.py | 90 | def test_base_margin_vs_base_score() -> None: | CODE |
| LOW | tests/python/test_ranking.py | 94 | def test_ranking_with_unweighted_data(): | CODE |
| LOW | tests/python/test_ranking.py | 128 | def test_ranking_with_weighted_data(): | CODE |
| LOW | tests/python/test_ranking.py | 185 | def test_lambdarank_parameters(params): | CODE |
| LOW | tests/python/test_multi_target.py | 54 | def test_shap_multi_output_tree() -> None: | CODE |
| LOW | tests/python/test_multi_target.py | 140 | def test_normal_distribution_constant_label(multi_strategy: str) -> None: | CODE |
| LOW | tests/python/test_multi_target.py | 175 | def test_normal_extreme_initial_variance( | CODE |
| 248 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | demo/kaggle-higgs/speedtest.R | 41 | nrounds <- 120 | COMMENT |
| LOW | demo/kaggle-higgs/speedtest.R | 61 | # 111.682 0.777 35.963 | COMMENT |
| LOW | demo/guide-python/generalized_linear_model.py | 21 | # change booster to gblinear, so that we are fitting a linear model | COMMENT |
| LOW | R-package/R/xgb.DMatrix.save.R | 1 | #' Save xgb.DMatrix object to binary file | COMMENT |
| LOW | R-package/R/xgb.plot.multi.trees.R | 1 | #' Project all trees on one tree | COMMENT |
| LOW | R-package/R/xgb.plot.multi.trees.R | 21 | #' | COMMENT |
| LOW | R-package/R/xgb.plot.multi.trees.R | 41 | #' nrounds = 30, | COMMENT |
| LOW | R-package/R/xgb.plot.deepness.R | 1 | #' Plot model tree depth | COMMENT |
| LOW | R-package/R/xgb.plot.deepness.R | 21 | #' Those could be helpful in determining sensible ranges of the `max_depth` | COMMENT |
| LOW | R-package/R/xgb.plot.deepness.R | 41 | #' | COMMENT |
| LOW | R-package/R/xgb.plot.deepness.R | 61 | #' xgb.plot.deepness(model) | COMMENT |
| LOW | R-package/R/utils.R | 381 | COMMENT | |
| LOW | R-package/R/utils.R | 421 | #' for objects produced by [xgboost()]), outside of its core components, might also keep: | COMMENT |
| LOW | R-package/R/utils.R | 441 | #' not used for prediction / importance / plotting / etc. | COMMENT |
| LOW | R-package/R/utils.R | 461 | #' preferred for long-term storage. | COMMENT |
| LOW | R-package/R/utils.R | 481 | #' | COMMENT |
| LOW | R-package/R/utils.R | 501 | #' xgb.save(bst, fname) | COMMENT |
| LOW | R-package/R/utils.R | 521 | #' obj2 <- readRDS(fname) | COMMENT |
| LOW | R-package/R/utils.R | 541 | #' that code calling xgboost will still work once those are removed in future releases. | COMMENT |
| LOW | R-package/R/xgb.plot.importance.R | 1 | #' Plot feature importance | COMMENT |
| LOW | R-package/R/xgb.plot.importance.R | 21 | #' | COMMENT |
| LOW | R-package/R/xgb.plot.importance.R | 41 | #' - `xgb.ggplot.importance()`: A customizable "ggplot" object. | COMMENT |
| LOW | R-package/R/xgb.plot.importance.R | 61 | #' xgb.plot.importance( | COMMENT |
| LOW | R-package/R/xgb.plot.importance.R | 141 | # Avoid error messages during CRAN check. | COMMENT |
| LOW | R-package/R/xgb.save.raw.R | 1 | #' Save XGBoost model to R's raw vector | COMMENT |
| LOW | R-package/R/xgb.save.raw.R | 21 | #' train <- agaricus.train | COMMENT |
| LOW | R-package/R/xgb.plot.shap.R | 1 | #' SHAP dependence plots | COMMENT |
| LOW | R-package/R/xgb.plot.shap.R | 21 | #' The default (`NULL`) will use up to 100k data points. | COMMENT |
| LOW | R-package/R/xgb.plot.shap.R | 41 | #' If `FALSE`, only a list of matrices is returned. | COMMENT |
| LOW | R-package/R/xgb.plot.shap.R | 61 | #' a meaningful thing to do. | COMMENT |
| LOW | R-package/R/xgb.plot.shap.R | 81 | #' data.table::setDTthreads(nthread) | COMMENT |
| LOW | R-package/R/xgb.plot.shap.R | 101 | #' | COMMENT |
| LOW | R-package/R/xgb.plot.shap.R | 121 | #' model = model_multiclass, | COMMENT |
| LOW | R-package/R/xgb.plot.shap.R | 141 | #' ) | COMMENT |
| LOW | R-package/R/xgb.plot.shap.R | 241 | #' Visualizes SHAP contributions of different features. | COMMENT |
| LOW | R-package/R/xgb.plot.shap.R | 261 | #' and the Python library <https://github.com/shap/shap>. | COMMENT |
| LOW | R-package/R/xgboost.R | 821 | if (is.na(early_stopping_rounds) || early_stopping_rounds <= 0L) { | COMMENT |
| LOW | R-package/R/xgboost.R | 841 | #' | COMMENT |
| LOW | R-package/R/xgboost.R | 861 | #' For package authors using 'xgboost' as a dependency, it is highly recommended to use | COMMENT |
| LOW | R-package/R/xgboost.R | 881 | #' Note that categorical features are only supported for `data.frame` inputs, and are automatically | COMMENT |
| LOW | R-package/R/xgboost.R | 901 | #' set as the last level. | COMMENT |
| LOW | R-package/R/xgboost.R | 921 | #' prediction type (e.g. `multi:softmax` vs. `multi:softprob`) are not allowed, and neither are | COMMENT |
| LOW | R-package/R/xgboost.R | 941 | #' - `"reg:tweedie"`: Tweedie regression with log-link. It might be useful, e.g., for modeling total loss in insurance, | COMMENT |
| LOW | R-package/R/xgboost.R | 961 | #' @param monitor_training Whether to monitor objective optimization progress on the input data. | COMMENT |
| LOW | R-package/R/xgboost.R | 981 | #' if there is no improvement in performance (as measured by the last metric passed under | COMMENT |
| LOW | R-package/R/xgboost.R | 1001 | #' a monotonically increasing function of that feature (that is, as the value of the feature | COMMENT |
| LOW | R-package/R/xgboost.R | 1021 | #' @param feature_weights Feature weights for column sampling. | COMMENT |
| LOW | R-package/R/xgboost.R | 1041 | #' the corresponding `y` - `base_margin` should have the same column order that the model will use | COMMENT |
| LOW | R-package/R/xgboost.R | 1061 | #' - L2 regularization term on weights. Increasing this value will make model more conservative. Normalised to number | COMMENT |
| LOW | R-package/R/xgboost.R | 1081 | #' data(mtcars) | COMMENT |
| LOW | R-package/R/xgboost.R | 1101 | #' # Can calculate evaluation metrics during boosting rounds | COMMENT |
| LOW | R-package/R/xgboost.R | 1241 | #' @title Compute predictions from XGBoost model on new data | COMMENT |
| LOW | R-package/R/xgboost.R | 1261 | #' matched by name by default (see `validate_features`). | COMMENT |
| LOW | R-package/R/xgboost.R | 1281 | #' untransformed margin (e.g., for binary classification, the values are log-odds deviations from | COMMENT |
| LOW | R-package/R/xgboost.R | 1301 | #' (for objectives which produces a single score per observation), or a matrix with number of | COMMENT |
| LOW | R-package/R/xgboost.R | 1321 | #' and come in the same order as in the training data. | COMMENT |
| LOW | R-package/R/xgboost.R | 1541 | "\n", | COMMENT |
| LOW | R-package/R/xgboost.R | 1561 | #' | COMMENT |
| LOW | R-package/R/xgboost.R | 1581 | #' - `data`: A sparse Matrix of 'dgCMatrix' class with 126 columns. | COMMENT |
| LOW | R-package/R/xgboost.R | 1601 | #' @importFrom data.table data.table | COMMENT |
| 267 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| HIGH | tests/python/test_plotting.py | 14 | except ImportError: | CODE |
| HIGH | tests/python/test_with_pandas.py | 14 | except ImportError: | CODE |
| HIGH | tests/python/test_with_modin.py | 12 | except ImportError: | CODE |
| HIGH | tests/test_distributed/test_with_dask/test_with_dask.py | 1275 | except (ValueError, KilledWorker): | CODE |
| HIGH | python-package/xgboost/collective.py | 254 | except TypeError: # float128 doesn't exist on the system | CODE |
| HIGH | python-package/xgboost/collective.py | 368 | except ImportError: | CODE |
| HIGH | python-package/xgboost/__init__.py | 34 | except ImportError: | CODE |
| HIGH | python-package/xgboost/sklearn.py | 1301 | except TypeError: # `QuantileDMatrix` supports lesser types than DMatrix | CODE |
| HIGH | python-package/xgboost/sklearn.py | 1491 | except TypeError: | CODE |
| HIGH | python-package/xgboost/training.py | 618 | except ImportError: | CODE |
| HIGH | python-package/xgboost/data.py | 121 | except ImportError: | CODE |
| HIGH | python-package/xgboost/data.py | 127 | except ImportError: | CODE |
| HIGH | python-package/xgboost/data.py | 193 | except ImportError: | CODE |
| HIGH | python-package/xgboost/data.py | 199 | except ImportError: | CODE |
| HIGH | python-package/xgboost/data.py | 239 | except ImportError: | CODE |
| HIGH | python-package/xgboost/data.py | 245 | except ImportError: | CODE |
| HIGH | python-package/xgboost/testing/__init__.py | 90 | except OSError: | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | demo/multiclass_classification/train.py | 3 | CODE | |
| LOW | demo/dask/dask_learning_to_rank.py | 16 | CODE | |
| LOW | demo/guide-python/cat_in_the_dat.py | 24 | CODE | |
| LOW | demo/guide-python/learning_to_rank.py | 19 | CODE | |
| LOW | tests/test_distributed/test_with_spark/test_spark.py | 6 | CODE | |
| LOW | tests/test_distributed/test_gpu_with_dask/conftest.py | 21 | CODE | |
| LOW | tests/test_distributed/test_with_dask/conftest.py | 3 | CODE | |
| LOW | tests/test_distributed/test_with_dask/test_with_dask.py | 2048 | CODE | |
| LOW | tests/test_distributed/test_with_dask/test_with_dask.py | 2139 | CODE | |
| LOW | tests/python-gpu/test_gpu_multi_target.py | 4 | CODE | |
| LOW | tests/python-sycl/test_sycl_with_sklearn.py | 1 | CODE | |
| LOW | tests/python-sycl/test_sycl_prediction.py | 1 | CODE | |
| LOW | tests/python-sycl/test_sycl_prediction.py | 6 | CODE | |
| LOW | tests/python-sycl/test_sycl_updaters.py | 1 | CODE | |
| LOW | tests/python-sycl/test_sycl_updaters.py | 3 | CODE | |
| LOW | tests/python-sycl/test_sycl_updaters.py | 5 | CODE | |
| LOW | tests/python-sycl/test_sycl_updaters.py | 6 | CODE | |
| LOW | tests/python-sycl/test_sycl_updaters.py | 7 | CODE | |
| LOW | python-package/xgboost/objective.py | 28 | CODE | |
| LOW | python-package/xgboost/compat.py | 4 | CODE | |
| LOW | python-package/xgboost/compat.py | 41 | CODE | |
| LOW | python-package/xgboost/compat.py | 42 | CODE | |
| LOW | python-package/xgboost/compat.py | 43 | CODE | |
| LOW | python-package/xgboost/_typing.py | 33 | CODE | |
| LOW | python-package/xgboost/__init__.py | 6 | CODE | |
| LOW | python-package/xgboost/__init__.py | 6 | CODE | |
| LOW | python-package/xgboost/__init__.py | 6 | CODE | |
| LOW | python-package/xgboost/__init__.py | 12 | CODE | |
| LOW | python-package/xgboost/__init__.py | 12 | CODE | |
| LOW | python-package/xgboost/__init__.py | 12 | CODE | |
| LOW | python-package/xgboost/__init__.py | 12 | CODE | |
| LOW | python-package/xgboost/__init__.py | 12 | CODE | |
| LOW | python-package/xgboost/__init__.py | 12 | CODE | |
| LOW | python-package/xgboost/__init__.py | 20 | CODE | |
| LOW | python-package/xgboost/__init__.py | 21 | CODE | |
| LOW | python-package/xgboost/__init__.py | 21 | CODE | |
| LOW | python-package/xgboost/__init__.py | 24 | CODE | |
| LOW | python-package/xgboost/__init__.py | 24 | CODE | |
| LOW | python-package/xgboost/__init__.py | 24 | CODE | |
| LOW | python-package/xgboost/__init__.py | 25 | CODE | |
| LOW | python-package/xgboost/__init__.py | 25 | CODE | |
| LOW | python-package/xgboost/__init__.py | 25 | CODE | |
| LOW | python-package/xgboost/__init__.py | 26 | CODE | |
| LOW | python-package/xgboost/__init__.py | 26 | CODE | |
| LOW | python-package/xgboost/__init__.py | 26 | CODE | |
| LOW | python-package/xgboost/__init__.py | 26 | CODE | |
| LOW | python-package/xgboost/__init__.py | 26 | CODE | |
| LOW | python-package/xgboost/__init__.py | 26 | CODE | |
| LOW | python-package/xgboost/core.py | 5 | CODE | |
| LOW | python-package/xgboost/training.py | 42 | CODE | |
| LOW | python-package/xgboost/data.py | 83 | CODE | |
| LOW | python-package/xgboost/data.py | 84 | CODE | |
| LOW | python-package/xgboost/data.py | 85 | CODE | |
| LOW | python-package/xgboost/data.py | 87 | CODE | |
| LOW | python-package/xgboost/data.py | 87 | CODE | |
| LOW | python-package/xgboost/_data_utils.py | 41 | CODE | |
| LOW | python-package/xgboost/dask/utils.py | 8 | CODE | |
| LOW | python-package/xgboost/testing/__init__.py | 52 | CODE | |
| LOW | python-package/xgboost/testing/__init__.py | 52 | CODE | |
| LOW | python-package/xgboost/testing/dask.py | 3 | CODE | |
| 9 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| CRITICAL | R-package/tests/testthat/test_dmatrix.R | 674 | expect_equal(xgb.get.DMatrix.num.non.missing(dm1), 10) | CODE |
| CRITICAL | R-package/tests/testthat/test_dmatrix.R | 679 | expect_equal(xgb.get.DMatrix.num.non.missing(dm2), 8) | CODE |
| CRITICAL | python-package/xgboost/data.py | 497 | # pandas.core.internals.managers.SingleBlockManager.array_values() | COMMENT |
| CRITICAL | …rc/main/java/ml/dmlc/xgboost4j/java/flink/XGBoost.java | 170 | return new XGBoostModel(ml.dmlc.xgboost4j.java.XGBoost.loadModel(opened)); | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | demo/guide-python/model_parser.py | 146 | CODE | |
| LOW | tests/python/test_model_compatibility.py | 30 | CODE | |
| LOW | tests/python/test_model_compatibility.py | 77 | CODE | |
| LOW | tests/python/test_shap.py | 12 | CODE | |
| LOW | tests/python/test_shap.py | 81 | CODE | |
| LOW | tests/python/test_tracker.py | 224 | CODE | |
| LOW | tests/python/test_tracker.py | 258 | CODE | |
| LOW | tests/python/test_tracker.py | 229 | CODE | |
| LOW | tests/python/test_tracker.py | 270 | CODE | |
| LOW | tests/test_distributed/test_with_dask/test_with_dask.py | 1810 | CODE | |
| LOW | tests/python-sycl/test_sycl_updaters.py | 64 | CODE | |
| LOW | tests/python-sycl/test_sycl_training_continuation.py | 11 | CODE | |
| LOW | tests/python-sycl/test_sycl_training_continuation.py | 31 | CODE | |
| LOW | python-package/xgboost/callback.py | 558 | CODE | |
| LOW | python-package/xgboost/callback.py | 637 | CODE | |
| LOW | python-package/xgboost/core.py | 2371 | CODE | |
| LOW | python-package/xgboost/core.py | 3134 | CODE | |
| LOW | python-package/xgboost/libpath.py | 19 | CODE | |
| LOW | python-package/xgboost/sklearn.py | 1238 | CODE | |
| LOW | python-package/xgboost/sklearn.py | 1434 | CODE | |
| LOW | python-package/xgboost/sklearn.py | 1856 | CODE | |
| LOW | python-package/xgboost/data.py | 366 | CODE | |
| LOW | python-package/xgboost/data.py | 530 | CODE | |
| LOW | python-package/xgboost/data.py | 1058 | CODE | |
| LOW | python-package/xgboost/dask/__init__.py | 1008 | CODE | |
| LOW | python-package/xgboost/dask/__init__.py | 1536 | CODE | |
| LOW | python-package/xgboost/dask/__init__.py | 1966 | CODE | |
| LOW | python-package/xgboost/testing/ordinal.py | 125 | CODE | |
| LOW | python-package/xgboost/testing/ordinal.py | 136 | CODE | |
| LOW | python-package/xgboost/testing/continuation.py | 17 | CODE | |
| LOW | python-package/xgboost/testing/continuation.py | 41 | CODE | |
| LOW | python-package/xgboost/testing/shared.py | 55 | CODE | |
| LOW | python-package/xgboost/spark/core.py | 1393 | CODE | |
| LOW | python-package/xgboost/spark/core.py | 1419 | CODE | |
| LOW | python-package/xgboost/spark/data.py | 190 | CODE | |
| LOW | python-package/xgboost/spark/data.py | 229 | CODE | |
| LOW | doc/conf.py | 65 | CODE | |
| LOW | ops/script/lint_cpp.py | 13 | CODE | |
| LOW | ops/script/lint_cpp.py | 135 | CODE | |
| LOW | ops/script/change_scala_version.py | 7 | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | tests/python/test_parse_tree.py | 35 | CODE | |
| LOW | tests/python-sycl/test_sycl_simple_dask.py | 17 | CODE | |
| LOW | python-package/xgboost/callback.py | 270 | CODE | |
| LOW | python-package/xgboost/collective.py | 135 | CODE | |
| LOW | python-package/xgboost/collective.py | 147 | CODE | |
| LOW | python-package/xgboost/plotting.py | 21 | CODE | |
| LOW | python-package/xgboost/plotting.py | 154 | CODE | |
| LOW | python-package/xgboost/core.py | 691 | CODE | |
| LOW | python-package/xgboost/core.py | 897 | CODE | |
| LOW | python-package/xgboost/core.py | 946 | CODE | |
| LOW | python-package/xgboost/core.py | 1139 | CODE | |
| LOW | python-package/xgboost/core.py | 1511 | CODE | |
| LOW | python-package/xgboost/core.py | 2022 | CODE | |
| LOW | python-package/xgboost/core.py | 2456 | CODE | |
| LOW | python-package/xgboost/core.py | 3049 | CODE | |
| LOW | python-package/xgboost/sklearn.py | 871 | CODE | |
| LOW | python-package/xgboost/sklearn.py | 2193 | CODE | |
| LOW | python-package/xgboost/training.py | 53 | CODE | |
| LOW | python-package/xgboost/training.py | 435 | CODE | |
| LOW | python-package/xgboost/training.py | 253 | CODE | |
| LOW | python-package/xgboost/data.py | 1214 | CODE | |
| LOW | python-package/xgboost/dask/__init__.py | 245 | CODE | |
| LOW | python-package/xgboost/dask/__init__.py | 570 | CODE | |
| LOW | python-package/xgboost/dask/__init__.py | 810 | CODE | |
| LOW | python-package/xgboost/dask/__init__.py | 1187 | CODE | |
| LOW | python-package/xgboost/dask/__init__.py | 285 | CODE | |
| LOW | python-package/xgboost/dask/__init__.py | 580 | CODE | |
| LOW | python-package/xgboost/dask/__init__.py | 1966 | CODE | |
| LOW | python-package/xgboost/dask/data.py | 206 | CODE | |
| LOW | python-package/xgboost/testing/data.py | 884 | CODE | |
| LOW | python-package/xgboost/spark/estimator.py | 195 | CODE | |
| LOW | python-package/xgboost/spark/estimator.py | 372 | CODE | |
| LOW | python-package/xgboost/spark/estimator.py | 561 | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | demo/rmm_plugin/rmm_mgpu_with_dask.py | 44 | # To use RMM pool allocator with a GPU Dask cluster, just add rmm_pool_size option | COMMENT |
| MEDIUM | demo/guide-python/custom_softmax.py | 72 | # suitable for demo. Also the one in native XGBoost core is more robust to | COMMENT |
| MEDIUM | python-package/xgboost/config.py | 58 | # Show all messages, including ones pertaining to debugging | COMMENT |
| LOW | python-package/xgboost/sklearn.py | 1874 | # If output_margin is active, simply return the scores | STRING |
| MEDIUM | python-package/xgboost/dask/__init__.py | 672 | # dask paradigm. But as a side effect, the `evals_result` in single-node API | COMMENT |
| MEDIUM | python-package/xgboost/testing/__init__.py | 646 | """Reassign stdout temporarily in order to test printed statements | STRING |
| MEDIUM | python-package/xgboost/spark/core.py | 962 | # Spark-rapids is a project to leverage GPUs to accelerate spark SQL. | COMMENT |
| LOW | python-package/xgboost/spark/core.py | 696 | # For now, since we cannot call rdd.getNumPartitions(), we just return | COMMENT |
| LOW | python-package/xgboost/spark/core.py | 1382 | # User don't set gpu configurations, just use cpu | COMMENT |
| MEDIUM | …main/scala/ml/dmlc/xgboost4j/scala/spark/XGBoost.scala | 144 | // that utilize GPUs alongside training tasks in order to avoid GPU out-of-memory errors. | COMMENT |
| MEDIUM | src/common/cuda_pinned_allocator.h | 72 | // This is actually a pinned memory allocator in disguise. We utilize HMM or ATS for | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | python-package/xgboost/callback.py | 37 | __all__ = [ | CODE |
| LOW | python-package/xgboost/interpret.py | 127 | __all__ = ["shap_values"] | CODE |
| LOW | python-package/xgboost/config.py | 127 | def set_config(**new_config: Any) -> None: | STRING |
| LOW | python-package/xgboost/__init__.py | 41 | __all__ = [ | CODE |
| LOW | python-package/xgboost/core.py | 970 | def set_float_info(self, field: str, data: ArrayLike) -> None: | CODE |
| LOW | python-package/xgboost/core.py | 985 | def set_float_info_npy2d(self, field: str, data: ArrayLike) -> None: | CODE |
| LOW | python-package/xgboost/core.py | 1001 | def set_uint_info(self, field: str, data: ArrayLike) -> None: | CODE |
| LOW | python-package/xgboost/core.py | 1032 | def set_label(self, label: ArrayLike) -> None: | CODE |
| LOW | python-package/xgboost/core.py | 1044 | def set_weight(self, weight: ArrayLike) -> None: | CODE |
| LOW | python-package/xgboost/core.py | 1064 | def set_base_margin(self, margin: ArrayLike) -> None: | CODE |
| LOW | python-package/xgboost/core.py | 1082 | def set_group(self, group: ArrayLike) -> None: | CODE |
| LOW | python-package/xgboost/core.py | 1850 | def _set_params(self, params: List[Tuple[str, str]]) -> None: | CODE |
| LOW | python-package/xgboost/core.py | 2102 | def set_attr(self, **kwargs: Optional[Any]) -> None: | CODE |
| LOW | python-package/xgboost/core.py | 2132 | def _set_feature_info(self, features: Optional[FeatureInfo], field: str) -> None: | CODE |
| LOW | python-package/xgboost/sklearn.py | 1305 | def _set_evaluation_result(self, evals_result: EvalsLog) -> None: | CODE |
| LOW | python-package/xgboost/dask/__init__.py | 127 | __all__ = [ | CODE |
| LOW | python-package/xgboost/spark/__init__.py | 17 | __all__ = [ | CODE |
| LOW⚡ | python-package/xgboost/spark/core.py | 372 | def _set_predict_params_default(self) -> None: | CODE |
| LOW | python-package/xgboost/spark/core.py | 312 | def _set_xgb_params_default(self) -> None: | CODE |
| LOW | python-package/xgboost/spark/core.py | 348 | def _set_fit_params_default(self) -> None: | CODE |
| LOW | python-package/xgboost/spark/estimator.py | 41 | def set_param_attrs(attr_name: str, param: Param) -> None: | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | demo/guide-python/cat_pipeline.py | 66 | # Create an encoder based on training data. | COMMENT |
| MEDIUM | R-package/R/utils.R | 2 | # This file is for the low level reusable utility functions | COMMENT |
| MEDIUM | tests/python-gpu/test_gpu_prediction.py | 267 | # Create a wide dataset | COMMENT |
| MEDIUM | python-package/xgboost/dask/data.py | 434 | # Create the training DMatrix | COMMENT |
| MEDIUM | python-package/xgboost/testing/data.py | 180 | # Create a dictionary-backed dataframe, enable this when the roundtrip is | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| HIGH | demo/guide-python/quantile_data_iterator.py | 0 | utility function for obtaining current batch of data. | STRING |
| HIGH | tests/python-gpu/test_from_cudf.py | 0 | utility function for obtaining current batch of data. | STRING |
| HIGH | python-package/xgboost/dask/data.py | 0 | utility function for obtaining current batch of data. | STRING |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| HIGH | tests/python/test_with_pandas.py | 400 | assert df.equals(copy) | CODE |
| HIGH | python-package/xgboost/testing/data.py | 200 | # assert pd_catcodes.equals(pa_catcodes) | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | demo/guide-python/distributed_extmem_basic.py | 188 | except Exception as e: | CODE |
| LOW | tests/python/test_with_shap.py | 9 | except Exception: | CODE |
| LOW | tests/python/test_openmp.py | 48 | except Exception as e: | CODE |
| LOW | python-package/xgboost/core.py | 409 | except Exception as e: # pylint: disable=broad-except | CODE |
| LOW | python-package/xgboost/data.py | 1306 | except Exception: # pylint: disable=broad-except | CODE |
| LOW | python-package/xgboost/dask/__init__.py | 659 | except Exception: # pylint: disable=broad-except | CODE |
| LOW | python-package/xgboost/testing/__init__.py | 186 | except Exception: # pylint: disable=broad-except | CODE |
| LOW | python-package/xgboost/testing/__init__.py | 741 | except Exception as e: # pylint: disable=broad-except | CODE |
| LOW | python-package/xgboost/spark/core.py | 1695 | except Exception as e: # pylint: disable=W0703 | CODE |
| LOW | ops/script/change_version.py | 146 | except Exception as e: | STRING |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| HIGH | R-package/R/xgb.DMatrix.R | 666 | #' # In this example, batches are obtained by subsetting the 'x' variable. | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | python-package/CMakeLists.txt | 21 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM | python-package/CMakeLists.txt | 23 | # --------------------------------------------------------------------------- | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | R-package/tests/testthat/test_ranking.R | 25 | # Check if the metric is monotone increasing | COMMENT |
| LOW | R-package/tests/testthat/test_ranking.R | 53 | # Check if the metric is monotone increasing | COMMENT |
| LOW | R-package/tests/testthat/test_ranking.R | 63 | all(diff(z) <= 0) # Check if z is monotone decreasing | CODE |
| LOW | jvm-packages/create_jni.py | 80 | # Set GPU_ARCH_FLAG to override the CUDA architectures. | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | demo/guide-python/sklearn_evals_result.py | 25 | # Or you can use: clf = xgb.XGBClassifier(**param_dist) | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | R-package/R/xgb.train.R | 420 | #' The purpose of this function is to enable IDE autocompletions and to provide in-package | COMMENT |
| LOW | python-package/xgboost/spark/core.py | 1283 | # all the columns specified by features_cols, so we need to check if | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | ops/pipeline/build-cuda.sh | 5 | ## Usage: | COMMENT |
| LOW | ops/pipeline/test-python-wheel.sh | 4 | ## Usage: | COMMENT |