Skip to content

Surv-TCAV-PBC is a fully reproducible pipeline for concept-based interpretability in survival analysis using the PBC-276 dataset and XGBoost-AFT models. It implements Surv-TCAV (Survival Testing with Concept Activation Vectors) to quantify the directional impact of clinically meaningful concepts on the model’s time-to-event predictions.

License

Notifications You must be signed in to change notification settings

emmanuel6474/surv-tcav-pbc

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Surv-TCAV on PBC-276

End-to-end pipeline for XGBoost AFT on PBC-276 with TreeSHAP and concept-based Surv-TCAV.
Figures are written to figures/, metrics to results/.

Environment

python -m venv .venv
. .venv/bin/activate      # Windows: .venv\Scripts\activate
pip install -r requirements.txt

Run

python pbc_surv_tcav.py

Command-line options:

python pbc_surv_tcav.py --help

Faster run (for CI/CODECHECK)

python pbc_surv_tcav.py --repeats 5 --no_shap

Outputs

  • Console: 25× 80/20 validation, C-index and IBS summary, Surv-TCAV effects
  • Results (CSV):
    • results/split_metrics.csv
    • results/summary_metrics.csv
  • Figures:
    • figures/validation_metrics.png
    • figures/treeshap_summary.png (optional; disable with --no_shap)
    • figures/tcav_bar.png
    • figures/calibration_tstar.png

Data

PBC dataset mirrored via Rdatasets (Therneau, survival package):
https://vincentarelbundock.github.io/Rdatasets/csv/survival/pbc.csv

License

MIT

About

Surv-TCAV-PBC is a fully reproducible pipeline for concept-based interpretability in survival analysis using the PBC-276 dataset and XGBoost-AFT models. It implements Surv-TCAV (Survival Testing with Concept Activation Vectors) to quantify the directional impact of clinically meaningful concepts on the model’s time-to-event predictions.

Resources

License

Stars

Watchers

Forks

Packages

No packages published