Uplift modeling and causal inference with machine learning algorithms
This report presents the forensic synthetic code analysis of uber/causalml, a Python project with 5,976 GitHub stars. SynthScan v2.0 examined 35,117 lines of code across 135 source files, recording 718 pattern matches distributed across 14 syntactic categories. The overall adjusted score of 26.1 places this repository in the Moderate AI signal band.
The scanner applied 160+ deterministic lexical heuristics, multi-line block detectors, abstract syntax tree depth profilers, and a cross-file Jaccard similarity matrix to construct a statistically normalised synthetic code estimate. All matches are individually weighted by severity coefficient and contextual multiplier before summation, and the resulting headline score is temporally discounted to account for the repository's development history relative to the commercial emergence of large language model coding tooling (November 2022 onward).
This chart maps the temporal evolution of the adjusted synthetic code score across successive scan runs. An upward trajectory indicates ongoing incorporation of AI-generated code or expanding LLM-assisted scaffolding; a stable or declining trajectory may reflect active human refactoring, code removal, or the adoption of stricter authorship policies. The dashed secondary line (right axis) independently tracks total raw pattern hit count, which can diverge from the normalised score when codebase size changes significantly between scans.
Classifies detected patterns by their diagnostic confidence and structural impact. CRITICAL patterns (coefficient 10) represent definitive synthetic signatures — hallucinated imports, explicit LLM attribution metadata — virtually never produced by human authors. HIGH (5) indicates strong structural tells such as cross-file repetition or cross-linguistic idioms. MEDIUM (2) covers recognisable conversational padding and AI-specific vocabulary. LOW (1) captures subtle indicators like tautological comments and generic boilerplate that require density to carry independent signal.
This horizontal bar chart decomposes the repository's raw synthetic code score by top-level directory, allowing you to pinpoint precisely which modules or components carry the highest AI authorship density. Directories with disproportionately high scores relative to their size warrant targeted manual review: concentrated AI signatures often trace back to mass-generated configuration layers, auto-ported test suites, LLM-scaffolded boilerplate classes, or entire subsystems authored under heavy copilot assistance. Use this view to prioritise your human code-review effort.
The scanner identified 718 distinct pattern matches across 14 syntactic categories. Each entry below represents a discrete location in the source code where the engine recorded a statistically significant AI authorship indicator. 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 diagnostic confidence level (CRITICAL / HIGH / MEDIUM / LOW). The Context column identifies whether the match occurred inside executable code, an inline comment, or a string literal — comment-context matches receive a ×1.5 weight because LLMs systematically over-annotate. The ⚡ bolt icon marks clustered matches: three or more patterns within a 10-line window, each receiving an additional ×1.5 density multiplier as dense clusters constitute far stronger evidence of synthetic authorship than isolated hits.
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | tests/test_benchmark_loaders.py | 31 | def test_fetch_lalonde_reproduces_the_experimental_estimate(): | CODE |
| LOW | tests/test_benchmark_loaders.py | 44 | def test_fetch_ihdp_replications_differ_and_carry_ground_truth(): | CODE |
| LOW | tests/test_benchmark_loaders.py | 79 | def test_fetch_ihdp_validates_its_arguments(): | CODE |
| LOW | tests/test_benchmark_loaders.py | 87 | def test_fetch_twins_mortality_matches_the_published_rate(): | CODE |
| LOW | tests/test_benchmark_loaders.py | 102 | def test_fetch_twins_reveals_the_twin_the_assignment_picks(): | CODE |
| LOW | tests/test_benchmark_loaders.py | 113 | def test_fetch_twins_assignment_is_seeded(): | CODE |
| LOW | tests/test_benchmark_loaders.py | 139 | def test_ground_truth_metrics_run_on_the_datasets_that_have_it(): | CODE |
| LOW | tests/test_cate_scoring.py | 48 | def test_compute_dr_pseudo_outcomes_shape(synthetic_data): | CODE |
| LOW | tests/test_cate_scoring.py | 62 | def test_compute_dr_pseudo_outcomes_recovers_ate(synthetic_data): | CODE |
| LOW | tests/test_cate_scoring.py | 80 | def test_dr_score_returns_series(synthetic_data): | CODE |
| LOW | tests/test_cate_scoring.py | 94 | def test_dr_score_ranks_perfect_model_lowest(synthetic_data): | CODE |
| LOW | tests/test_cate_scoring.py | 107 | def test_dr_score_with_precomputed_pseudo_outcomes(synthetic_data): | CODE |
| LOW | tests/test_cate_scoring.py | 124 | def test_dr_score_shares_pseudo_outcomes_with_rate_score(synthetic_data): | CODE |
| LOW | tests/test_cate_scoring.py | 152 | def test_dr_score_return_ci_returns_dataframe(synthetic_data): | CODE |
| LOW | tests/test_cate_scoring.py | 168 | def test_dr_score_ci_bounds_ordered(synthetic_data): | CODE |
| LOW | tests/test_cate_scoring.py | 184 | def test_plug_in_t_score_returns_series(synthetic_data): | CODE |
| LOW | tests/test_cate_scoring.py | 198 | def test_plug_in_t_score_ranks_perfect_model_lowest(synthetic_data): | CODE |
| LOW | tests/test_cate_scoring.py | 211 | def test_plug_in_t_score_return_ci_returns_dataframe(synthetic_data): | CODE |
| LOW | tests/test_cate_scoring.py | 232 | def test_plug_in_t_score_missing_columns_raises(synthetic_data): | CODE |
| LOW | tests/test_cate_scoring.py | 238 | def test_compute_dr_pseudo_outcomes_handles_imbalanced_treatment(): | CODE |
| LOW | tests/test_cate_scoring.py | 262 | def test_plug_in_t_score_handles_imbalanced_treatment(): | CODE |
| LOW | tests/test_cate_scoring.py | 296 | def test_dr_score_and_plug_in_t_score_all_finite(synthetic_data): | CODE |
| LOW | tests/test_cate_scoring.py | 318 | def test_compute_r_residuals_shape(synthetic_data): | CODE |
| LOW | tests/test_cate_scoring.py | 334 | def test_rlearner_score_returns_series(synthetic_data): | CODE |
| LOW | tests/test_cate_scoring.py | 348 | def test_rlearner_score_ranks_perfect_model_lowest(synthetic_data): | CODE |
| LOW | tests/test_cate_scoring.py | 361 | def test_rlearner_score_with_precomputed_residuals(synthetic_data): | CODE |
| LOW | tests/test_cate_scoring.py | 387 | def test_rlearner_score_return_ci_returns_dataframe(synthetic_data): | CODE |
| LOW | tests/test_cate_scoring.py | 403 | def test_rlearner_score_ci_bounds_ordered(synthetic_data): | CODE |
| LOW | tests/test_cate_scoring.py | 419 | def test_compute_r_residuals_handles_imbalanced_treatment(): | CODE |
| LOW | tests/test_cate_scoring.py | 445 | def test_rlearner_score_handles_imbalanced_treatment(): | CODE |
| LOW | tests/test_cate_scoring.py | 479 | def test_dr_plug_in_t_and_rlearner_score_all_finite(synthetic_data): | CODE |
| LOW | tests/test_cate_scoring.py | 510 | def test_compute_r_residuals_skips_propensity_when_w_residual_not_needed( | CODE |
| LOW | tests/test_cate_scoring.py | 528 | def test_dr_score_without_learner(synthetic_data): | CODE |
| LOW | tests/test_cate_scoring.py | 540 | def test_plug_in_t_score_without_learner(synthetic_data): | CODE |
| LOW | tests/test_cate_scoring.py | 552 | def test_dr_score_missing_one_learner(synthetic_data): | CODE |
| LOW | tests/test_jax_dragonnet.py | 14 | def test_dragonnet_jax_fit_predict(): | CODE |
| LOW | tests/test_jax_dragonnet.py | 36 | def test_dragonnet_jax_predict_propensity(): | CODE |
| LOW | tests/test_jax_dragonnet.py | 54 | def test_dragonnet_jax_save_load(tmp_path): | CODE |
| LOW⚡ | tests/test_meta_learners.py | 2031 | def test_fit_returns_self_regressor(Cls, kwargs): | CODE |
| LOW⚡ | tests/test_meta_learners.py | 2038 | def test_fit_returns_self_classifier(Cls, kwargs): | CODE |
| LOW⚡ | tests/test_meta_learners.py | 2044 | def test_xgb_rregressor_clone_no_kwargs(): | CODE |
| LOW⚡ | tests/test_meta_learners.py | 2054 | def test_xgb_rregressor_clone_with_kwargs(): | CODE |
| LOW⚡ | tests/test_meta_learners.py | 2295 | def test_t_classifier_fail_fast_return_ci_and_components(): | CODE |
| LOW⚡ | tests/test_meta_learners.py | 2303 | def test_x_learner_pretrain_before_fit_raises(): | CODE |
| LOW⚡ | tests/test_meta_learners.py | 2311 | def test_dr_learner_pretrain_before_fit_raises(): | CODE |
| LOW | tests/test_meta_learners.py | 682 | def test_explainer_auto_importance_catboost(generate_regression_data): | CODE |
| LOW | tests/test_meta_learners.py | 1463 | def test_multi_treatment_learners(): | CODE |
| LOW | tests/test_meta_learners.py | 1566 | def _assert_plain_fit_predict(result, name): | CODE |
| LOW | tests/test_meta_learners.py | 2005 | def test_clone_get_params_regressor(Cls, kwargs): | CODE |
| LOW | tests/test_meta_learners.py | 2019 | def test_clone_get_params_classifier(Cls, kwargs): | CODE |
| LOW | tests/test_meta_learners.py | 2161 | def test_xgbt_classifier_clone(): | CODE |
| LOW | tests/test_meta_learners.py | 2172 | def test_xgbr_classifier_clone(): | CODE |
| LOW | tests/test_meta_learners.py | 2189 | def test_xgb_rregressor_fit_predict_return_ci(): | CODE |
| LOW | tests/test_meta_learners.py | 2216 | def test_bit_identical_predict(Cls, kwargs): | CODE |
| LOW | tests/test_meta_learners.py | 2235 | def test_finite_predict_stochastic(Cls, kwargs): | CODE |
| LOW | tests/test_meta_learners.py | 2247 | def test_bit_identical_estimate_ate_s(): | CODE |
| LOW | tests/test_meta_learners.py | 2258 | def test_t_regressor_return_ci_bit_identical(): | CODE |
| LOW | tests/test_meta_learners.py | 2272 | def test_t_classifier_clone_fit_predict(): | CODE |
| LOW | tests/test_meta_learners.py | 2281 | def test_x_classifier_verbatim_store_clone(): | CODE |
| LOW | tests/test_meta_learners.py | 2323 | def test_base_rlearner_bootstrap_reproducibility(generate_regression_data): | CODE |
| 310 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | tests/test_meta_learners.py | 1497 | # ── Shared assertion helpers ─────────────────────────────────────────────── | COMMENT |
| MEDIUM | tests/test_meta_learners.py | 1572 | # ── T-Learner ───────────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | tests/test_meta_learners.py | 1620 | # ── X-Learner ───────────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | tests/test_meta_learners.py | 1682 | # ── S-Learner ───────────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | tests/test_meta_learners.py | 1729 | # ── DR-Learner ──────────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | tests/test_meta_learners.py | 1783 | # ── R-Learner ───────────────────────────────────────────────────────────── | COMMENT |
| MEDIUM | tests/test_meta_learners.py | 1949 | # ============================================================================= | COMMENT |
| MEDIUM | tests/test_meta_learners.py | 1951 | # ============================================================================= | COMMENT |
| MEDIUM⚡ | tests/test_causal_trees.py | 342 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM⚡ | tests/test_causal_trees.py | 348 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM⚡ | tests/test_causal_trees.py | 891 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM⚡ | tests/test_causal_trees.py | 895 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM | tests/test_causal_trees.py | 687 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM | tests/test_causal_trees.py | 692 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM⚡ | tests/test_serialization_extended.py | 91 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM⚡ | tests/test_serialization_extended.py | 93 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM⚡ | tests/test_serialization_extended.py | 387 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM⚡ | tests/test_serialization_extended.py | 389 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM | tests/test_serialization_extended.py | 33 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM | tests/test_serialization_extended.py | 35 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM | tests/test_serialization_extended.py | 297 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM | tests/test_serialization_extended.py | 299 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM⚡ | tests/test_uplift_trees_kernel.py | 460 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM⚡ | tests/test_uplift_trees_kernel.py | 463 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM⚡ | tests/test_uplift_trees_kernel.py | 627 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM⚡ | tests/test_uplift_trees_kernel.py | 629 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM | tests/test_uplift_trees_kernel.py | 234 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM | tests/test_uplift_trees_kernel.py | 237 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM | tests/test_uplift_trees_kernel.py | 724 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM | tests/test_uplift_trees_kernel.py | 732 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM | tests/test_uplift_trees_kernel.py | 898 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM | tests/test_uplift_trees_kernel.py | 901 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM⚡ | tests/test_serialization.py | 62 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM⚡ | tests/test_serialization.py | 64 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM⚡ | tests/test_serialization.py | 157 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM⚡ | tests/test_serialization.py | 159 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM⚡ | tests/test_serialization.py | 227 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM⚡ | tests/test_serialization.py | 229 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM⚡ | tests/test_serialization.py | 277 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM⚡ | tests/test_serialization.py | 279 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM | causalml/inference/tree/_tree/_classes.py | 57 | # ============================================================================= | COMMENT |
| MEDIUM | causalml/inference/tree/_tree/_classes.py | 59 | # ============================================================================= | COMMENT |
| MEDIUM | causalml/inference/tree/_tree/_classes.py | 84 | # ============================================================================= | COMMENT |
| MEDIUM | causalml/inference/tree/_tree/_classes.py | 86 | # ============================================================================= | COMMENT |
| MEDIUM⚡ | causalml/inference/meta/utils.py | 13 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM⚡ | causalml/inference/meta/utils.py | 15 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM⚡ | causalml/inference/meta/utils.py | 25 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM | causalml/inference/meta/utils.py | 38 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM | causalml/inference/meta/utils.py | 237 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM | causalml/inference/meta/utils.py | 239 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM | causalml/inference/meta/utils.py | 321 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM | causalml/inference/meta/utils.py | 323 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM | causalml/inference/meta/utils.py | 403 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM | causalml/inference/meta/utils.py | 405 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM | causalml/inference/jax/cevae/cevae.py | 134 | # ------------------------------------------------------------------ | COMMENT |
| MEDIUM | causalml/inference/jax/cevae/cevae.py | 136 | # ------------------------------------------------------------------ | COMMENT |
| MEDIUM | causalml/inference/jax/cevae/cevae.py | 149 | # ------------------------------------------------------------------ | COMMENT |
| MEDIUM | causalml/inference/jax/cevae/cevae.py | 151 | # ------------------------------------------------------------------ | COMMENT |
| MEDIUM | causalml/inference/jax/cevae/cevae.py | 317 | # ------------------------------------------------------------------ | COMMENT |
| MEDIUM | causalml/inference/jax/cevae/cevae.py | 319 | # ------------------------------------------------------------------ | COMMENT |
| 8 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | tests/test_fit_arg_order.py | 55 | CODE | |
| LOW | tests/test_counterfactual_unit_selection.py | 2 | CODE | |
| LOW | tests/test_serialization_extended.py | 10 | CODE | |
| LOW | tests/test_serialization_extended.py | 12 | CODE | |
| LOW | tests/test_serialization_extended.py | 13 | CODE | |
| LOW | tests/test_serialization.py | 10 | CODE | |
| LOW | tests/test_serialization.py | 13 | CODE | |
| LOW | tests/test_serialization.py | 13 | CODE | |
| LOW | causalml/propensity.py | 5 | CODE | |
| LOW | causalml/metrics/regression.py | 4 | CODE | |
| LOW | causalml/metrics/regression.py | 5 | CODE | |
| LOW | causalml/metrics/__init__.py | 1 | CODE | |
| LOW | causalml/metrics/__init__.py | 1 | CODE | |
| LOW | causalml/metrics/__init__.py | 1 | CODE | |
| LOW | causalml/metrics/__init__.py | 2 | CODE | |
| LOW | causalml/metrics/__init__.py | 2 | CODE | |
| LOW | causalml/metrics/__init__.py | 2 | CODE | |
| LOW | causalml/metrics/__init__.py | 3 | CODE | |
| LOW | causalml/metrics/__init__.py | 3 | CODE | |
| LOW | causalml/metrics/__init__.py | 3 | CODE | |
| LOW | causalml/metrics/__init__.py | 3 | CODE | |
| LOW | causalml/metrics/__init__.py | 3 | CODE | |
| LOW | causalml/metrics/__init__.py | 3 | CODE | |
| LOW | causalml/metrics/__init__.py | 3 | CODE | |
| LOW | causalml/metrics/__init__.py | 3 | CODE | |
| LOW | causalml/metrics/__init__.py | 13 | CODE | |
| LOW | causalml/metrics/__init__.py | 13 | CODE | |
| LOW | causalml/metrics/__init__.py | 13 | CODE | |
| LOW | causalml/metrics/__init__.py | 13 | CODE | |
| LOW | causalml/metrics/__init__.py | 13 | CODE | |
| LOW | causalml/metrics/__init__.py | 13 | CODE | |
| LOW | causalml/metrics/__init__.py | 21 | CODE | |
| LOW | causalml/metrics/__init__.py | 21 | CODE | |
| LOW | causalml/metrics/__init__.py | 21 | CODE | |
| LOW | causalml/metrics/__init__.py | 21 | CODE | |
| LOW | causalml/metrics/__init__.py | 21 | CODE | |
| LOW | causalml/metrics/__init__.py | 28 | CODE | |
| LOW | causalml/metrics/__init__.py | 28 | CODE | |
| LOW | causalml/metrics/__init__.py | 29 | CODE | |
| LOW | causalml/metrics/__init__.py | 29 | CODE | |
| LOW | causalml/metrics/__init__.py | 29 | CODE | |
| LOW | causalml/metrics/__init__.py | 30 | CODE | |
| LOW | causalml/metrics/__init__.py | 30 | CODE | |
| LOW | causalml/metrics/__init__.py | 30 | CODE | |
| LOW | causalml/metrics/__init__.py | 30 | CODE | |
| LOW | causalml/metrics/__init__.py | 36 | CODE | |
| LOW | causalml/metrics/__init__.py | 36 | CODE | |
| LOW | causalml/metrics/__init__.py | 37 | CODE | |
| LOW | causalml/metrics/__init__.py | 37 | CODE | |
| LOW | causalml/metrics/__init__.py | 37 | CODE | |
| LOW | causalml/metrics/__init__.py | 37 | CODE | |
| LOW | causalml/optimize/__init__.py | 1 | CODE | |
| LOW | causalml/optimize/__init__.py | 2 | CODE | |
| LOW | causalml/optimize/__init__.py | 3 | CODE | |
| LOW | causalml/optimize/__init__.py | 3 | CODE | |
| LOW | causalml/optimize/__init__.py | 3 | CODE | |
| LOW | causalml/optimize/__init__.py | 4 | CODE | |
| LOW | causalml/optimize/__init__.py | 5 | CODE | |
| LOW | causalml/dataset/__init__.py | 1 | CODE | |
| LOW | causalml/dataset/__init__.py | 1 | CODE | |
| 87 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| HIGH | causalml/metrics/ground_truth.py | 75 | Expected loss of the treat-if-``tau_hat``-is-positive policy. Following Shalit, Johansson and Sontag (2017):: | STRING |
| HIGH | causalml/metrics/sensitivity.py | 266 | Return separate potential-outcome predictions mu1_hat, mu0_hat. Only supported for S/T/DR-learner-style objects | STRING |
| HIGH | causalml/dataset/_base.py | 68 | Return the local path to a cached dataset file, downloading it if needed. The digest is verified on download and on | STRING |
| HIGH | causalml/dataset/_benchmarks.py | 111 | Load one replication of the IHDP benchmark. Covariates from the Infant Health and Development Program randomized tr | STRING |
| HIGH | causalml/dataset/semiSynthetic.py | 279 | Build the m-th iteration of the MIU (Model-based Imputation with Uncertainty) ensemble. This function implemen | STRING |
| HIGH | causalml/dataset/semiSynthetic.py | 579 | Train an ensemble of M MIU models and return the best one. This function implements the complete MIU (Model-ba | STRING |
| HIGH | causalml/dataset/semiSynthetic.py | 742 | Perform cross-validation to find optimal hyperparameters for the MIU model. This function performs bootstrap-b | STRING |
| HIGH | causalml/dataset/semiSynthetic.py | 911 | Train a single MIU model for a specific parameter combination and bootstrap iteration. This function is design | STRING |
| HIGH | causalml/inference/serialization.py | 121 | Load a previously saved learner from disk. Checks the saved metadata against the current environment and warns | STRING |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | tests/test_serialization.py | 49 | CODE | |
| LOW | causalml/match.py | 295 | CODE | |
| LOW | causalml/metrics/rate.py | 265 | CODE | |
| LOW | causalml/metrics/visualize.py | 18 | CODE | |
| LOW | causalml/metrics/visualize.py | 450 | CODE | |
| LOW | causalml/metrics/visualize.py | 555 | CODE | |
| LOW | causalml/metrics/visualize.py | 644 | CODE | |
| LOW | causalml/metrics/visualize.py | 693 | CODE | |
| LOW | causalml/metrics/visualize.py | 737 | CODE | |
| LOW | causalml/metrics/visualize.py | 779 | CODE | |
| LOW | causalml/metrics/visualize.py | 873 | CODE | |
| LOW | causalml/metrics/cate_scoring.py | 268 | CODE | |
| LOW | causalml/metrics/cate_scoring.py | 394 | CODE | |
| LOW | causalml/metrics/cate_scoring.py | 499 | CODE | |
| LOW | causalml/dataset/classification.py | 55 | CODE | |
| LOW | causalml/dataset/classification.py | 167 | CODE | |
| LOW | causalml/dataset/classification.py | 171 | CODE | |
| LOW | causalml/dataset/classification.py | 454 | CODE | |
| LOW | causalml/dataset/semiSynthetic.py | 564 | CODE | |
| LOW | causalml/dataset/semiSynthetic.py | 724 | CODE | |
| LOW | causalml/dataset/semiSynthetic.py | 19 | CODE | |
| LOW | causalml/inference/tree/plot.py | 591 | CODE | |
| LOW | causalml/inference/tree/causal/causaltree.py | 64 | CODE | |
| LOW | causalml/inference/tree/causal/causalforest.py | 168 | CODE | |
| LOW | causalml/inference/tree/_uplift/uplifttree.py | 73 | CODE | |
| LOW | causalml/inference/tree/_uplift/uplifttree.py | 661 | CODE | |
| LOW | causalml/inference/tree/_uplift/upliftforest.py | 101 | CODE | |
| LOW | causalml/inference/tree/_uplift/upliftforest.py | 280 | CODE | |
| LOW | causalml/inference/meta/rlearner.py | 39 | CODE | |
| LOW | causalml/inference/meta/rlearner.py | 339 | CODE | |
| LOW | causalml/inference/meta/rlearner.py | 449 | CODE | |
| LOW | causalml/inference/meta/rlearner.py | 654 | CODE | |
| LOW | causalml/inference/meta/xlearner.py | 468 | CODE | |
| LOW | causalml/inference/meta/base.py | 255 | CODE | |
| LOW | causalml/inference/meta/base.py | 328 | CODE | |
| LOW | causalml/inference/torch/cevae.py | 40 | CODE | |
| LOW | causalml/inference/iv/drivlearner.py | 332 | CODE | |
| LOW | causalml/inference/iv/drivlearner.py | 443 | CODE | |
| LOW | causalml/inference/iv/drivlearner.py | 657 | CODE | |
| LOW | causalml/inference/iv/drivlearner.py | 730 | CODE | |
| LOW | causalml/inference/jax/dragonnet.py | 312 | CODE | |
| LOW | causalml/inference/jax/cevae/cevae.py | 106 | CODE | |
| LOW | causalml/inference/tf/dragonnet.py | 41 | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | tests/test_meta_learners.py | 168 | # Check if the normalized AUUC score of model's prediction is higher than random (0.5). | COMMENT |
| LOW | tests/test_meta_learners.py | 240 | # Check if the normalized AUUC score of model's prediction is higher than random (0.5). | COMMENT |
| LOW | tests/test_meta_learners.py | 292 | # Check if the normalized AUUC score of model's prediction is higher than random (0.5). | COMMENT |
| LOW | tests/test_meta_learners.py | 333 | # Check if the normalized AUUC score of model's prediction is higher than random (0.5). | COMMENT |
| LOW | tests/test_meta_learners.py | 374 | # Check if the normalized AUUC score of model's prediction is higher than random (0.5). | COMMENT |
| LOW | tests/test_meta_learners.py | 415 | # Check if the normalized AUUC score of model's prediction is higher than random (0.5). | COMMENT |
| LOW | tests/test_meta_learners.py | 469 | # Check if the normalized AUUC score of model's prediction is higher than random (0.5). | COMMENT |
| LOW | tests/test_meta_learners.py | 512 | # Check if the normalized AUUC score of model's prediction is higher than random (0.5). | COMMENT |
| LOW | tests/test_meta_learners.py | 553 | # Check if the normalized AUUC score of model's prediction is higher than random (0.5). | COMMENT |
| LOW | tests/test_meta_learners.py | 594 | # Check if the normalized AUUC score of model's prediction is higher than random (0.5). | COMMENT |
| LOW | tests/test_meta_learners.py | 671 | # Check if the normalized AUUC score of model's prediction is higher than random (0.5). | COMMENT |
| LOW | tests/test_meta_learners.py | 740 | # Check if the normalized AUUC score of model's prediction is higher than random (0.5). | COMMENT |
| LOW | tests/test_meta_learners.py | 829 | # Check if the normalized AUUC score of model's prediction is higher than random (0.5). | COMMENT |
| LOW | tests/test_meta_learners.py | 883 | # Check if the normalized AUUC score of model's prediction is higher than random (0.5). | COMMENT |
| LOW | tests/test_meta_learners.py | 926 | # Check if the normalized AUUC score of model's prediction is higher than random (0.5). | COMMENT |
| LOW | tests/test_meta_learners.py | 995 | # Check if the normalized AUUC score of model's prediction is higher than random (0.5). | COMMENT |
| LOW | tests/test_meta_learners.py | 1061 | # Check if the normalized AUUC score of model's prediction is higher than random (0.5). | COMMENT |
| LOW | tests/test_meta_learners.py | 1114 | # Check if the normalized AUUC score of model's prediction is higher than random (0.5). | COMMENT |
| LOW | tests/test_meta_learners.py | 1130 | # Check if XGBRRegressor successfully produces treatment effect estimation | COMMENT |
| LOW | tests/test_meta_learners.py | 1221 | # Check if the normalized AUUC score of model's prediction is higher than random (0.5). | COMMENT |
| LOW | tests/test_uplift_trees.py | 111 | # Check if the normalized AUUC score of model's prediction is higher than random (0.5). | COMMENT |
| LOW | tests/test_uplift_trees.py | 189 | # Check if the normalized AUUC score of model's prediction is higher than random (0.5). | COMMENT |
| LOW | tests/test_uplift_trees.py | 199 | # Check if the total count is split correctly, at least for control group in the first level | COMMENT |
| LOW | tests/test_uplift_trees.py | 217 | # Check if it works as expected after filling with validation data | COMMENT |
| LOW | tests/test_uplift_trees.py | 256 | # Check if the features with positive importance is not more than number of nodes | COMMENT |
| LOW | tests/test_ivlearner.py | 75 | # Check if the normalized AUUC score of model's prediction is higher than random (0.5). | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | tests/test_fit_arg_order.py | 212 | CODE | |
| LOW | tests/test_fit_arg_order.py | 436 | CODE | |
| LOW | causalml/match.py | 146 | CODE | |
| LOW | causalml/metrics/sensitivity.py | 583 | CODE | |
| LOW | causalml/dataset/synthetic.py | 39 | CODE | |
| LOW | causalml/dataset/synthetic.py | 211 | CODE | |
| LOW | causalml/dataset/synthetic.py | 320 | CODE | |
| LOW | causalml/dataset/classification.py | 171 | CODE | |
| LOW | causalml/dataset/classification.py | 454 | CODE | |
| LOW | causalml/dataset/semiSynthetic.py | 266 | CODE | |
| LOW | causalml/dataset/semiSynthetic.py | 564 | CODE | |
| LOW | causalml/inference/tree/plot.py | 69 | CODE | |
| LOW | causalml/inference/tree/_tree/_classes.py | 225 | CODE | |
| LOW | causalml/inference/tree/causal/causaltree.py | 894 | CODE | |
| LOW | causalml/inference/tree/causal/_tree.py | 93 | CODE | |
| LOW | causalml/inference/tree/_uplift/_tree.py | 89 | CODE | |
| LOW | causalml/inference/iv/drivlearner.py | 105 | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| HIGH | causalml/inference/meta/tlearner.py | 0 | predict treatment effects. args: x (np.matrix, np.array, pd.dataframe, pl.dataframe, or pl.lazyframe): a feature matrix. | STRING |
| HIGH | causalml/inference/meta/slearner.py | 0 | predict treatment effects. args: x (np.matrix, np.array, pd.dataframe, pl.dataframe, or pl.lazyframe): a feature matrix. | STRING |
| HIGH | causalml/inference/meta/drlearner.py | 0 | predict treatment effects. args: x (np.matrix, np.array, pd.dataframe, pl.dataframe, or pl.lazyframe): a feature matrix. | STRING |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | .readthedocs.yml | 21 | # Read the Docs already builds on every pull request and reports a status | COMMENT |
| LOW | setup.cfg | 1 | [metadata] | COMMENT |
| LOW | docs/conf.py | 1 | #!/usr/bin/env python | COMMENT |
| LOW | docs/conf.py | 21 | # directory, add these directories to sys.path here. If the directory is | COMMENT |
| LOW | docs/conf.py | 141 | # for |version| and |release|, also used in various other places throughout | COMMENT |
| LOW | docs/conf.py | 161 | # directories to ignore when looking for source files. | COMMENT |
| LOW | docs/conf.py | 181 | # color-mode toggle. Pinning a single style here breaks the dark one. | COMMENT |
| LOW | docs/conf.py | 221 | COMMENT | |
| LOW | docs/conf.py | 241 | # which it looks for at the root of the static output, resolve there too. | COMMENT |
| LOW | docs/conf.py | 261 | # to template names. | COMMENT |
| LOW | docs/conf.py | 281 | # Default is True. | COMMENT |
| LOW | docs/conf.py | 301 | COMMENT | |
| LOW | docs/conf.py | 321 | COMMENT | |
| LOW | causalml/inference/meta/utils.py | 21 | pl = None | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | tests/test_jax_cevae.py | 112 | # Loose bound so this stays robust to seeds / mini-batch shuffle order. | COMMENT |
| MEDIUM | causalml/metrics/cate_scoring.py | 72 | """Construct cross-fitted doubly-robust (AIPW) pseudo-outcomes for CATE evaluation. | STRING |
| MEDIUM | causalml/metrics/cate_scoring.py | 287 | """Score fitted CATE models via the doubly-robust (DR) pseudo-outcome loss. | STRING |
| MEDIUM | causalml/inference/meta/drlearner.py | 128 | # the outcome regression, and the treatment regression on the doubly robust estimates. The use of | COMMENT |
| MEDIUM | causalml/inference/iv/drivlearner.py | 133 | # the outcome regression, and the treatment regression on the doubly robust estimates. The use of | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | tests/test_uplift_trees.py | 90 | # Create a synthetic population: | COMMENT |
| MEDIUM | tests/test_uplift_trees.py | 172 | # Create a synthetic population: | COMMENT |
| MEDIUM | docs/conf.py | 6 | # This file is execfile()d with the current directory set to its | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | causalml/__init__.py | 1 | __all__ = [ | CODE |
| LOW | causalml/metrics/ground_truth.py | 17 | __all__ = ["pehe", "ate_error", "policy_risk"] | CODE |
| LOW | causalml/inference/tree/_tree/__init__.py | 12 | __all__ = [ | CODE |
| LOW | causalml/inference/jax/__init__.py | 4 | __all__ = ["DragonNet", "CEVAE"] | CODE |
| LOW | causalml/inference/jax/cevae/__init__.py | 5 | __all__ = ["CEVAE"] | CODE |
| LOW | causalml/inference/jax/cevae/cevae.py | 31 | logger = logging.getLogger(__name__) | CODE |
| LOW | causalml/inference/jax/cevae/losses.py | 59 | __all__ = ["cevae_loss", "trace_causal_effect_elbo"] | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | tests/test_fit_arg_order.py | 230 | except Exception: # optional backend absent, or an import-time failure | CODE |
| LOW | causalml/dataset/_base.py | 111 | except Exception as exc: | CODE |
| LOW | causalml/inference/serialization.py | 34 | except Exception: | CODE |
| LOW | causalml/inference/serialization.py | 74 | except Exception: | CODE |
| LOW | causalml/inference/tree/plot.py | 200 | except Exception as e: | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM⚡ | tests/test_uplift_trees_kernel.py | 462 | # on sklearn's ForestRegressor scaffolding, replacing the legacy joblib forest. | COMMENT |