/GHOST

Primary LanguageJupyter NotebookMIT LicenseMIT

GHOST

This repository is part of the Supporting Information to

GHOST: Adjusting the Decision Threshold to Handle Imbalanced Data in Machine Learning

Carmen Esposito,1 Gregory A. Landrum,1,2 Nadine Schneider,3 Nikolaus Stiefl,3 and Sereina Riniker1

1 Laboratory of Physical Chemistry, ETH Zurich, Vladimir-Prelog-Weg 2, 8093 Zurich,Switzerland
2 T5 Informatics GmbH, Spalenring 11, 4055 Basel, Switzerland
3 Novartis Institutes for BioMedical Research, Novartis Pharma AG, Novartis Campus,4002 Basel, Switzerland

Content

Notebooks:

  • example_oob_threshold_optimization.ipynb
    Eexample of how to use the oob-based thresholding method to optimize the decision threshold of a random forest classifier.

  • example_GHOST.ipynb
    Example of how to use GHOST (Generalized tHreshOld ShifTing) to optimize the decision threshold of classification models.

  • Tutorial_Threshold_Optimization_RF.ipynb
    Notebook explaining step by step how to reproduce the results reported in our work. Here, the code is only executed for 6 public datasets and the random forest model.

  • Reproduce_Results_Public_Datasets.ipynb
    Notebook to reproduce the results reported in our work. Here, results are produced for all 138 public datasets. The user can choose between four different machine learning methods, namely random forest (RF), gradient boosting (GB), XGBoost (XGB), and logistic regression (LR). The user can also choose between two different molecular descriptors, ECFP4 and RDKit2D.

  • DeepChem_PubChem.ipynb
    Notebook to reproduce the results of the multi-task classification models for the PubChem datasets.

  • DeepChem_MoleculeNet.ipynb
    Notebook to reproduce the results of the multi-task classification models for the MoleculeNet datasets.

Data:

The threshold optimization methods have been validated agaist 138 public datasets and these are all provided here in the folder data.

Dependencies:

A list of dependencies is available in the file ghost_env.yml. This conda environmet was used to obtain the results reported in our work.

Authors

Carmen Esposito (GHOST procedure) and Greg Landrum (oob-based threshold optimization approach, data collection, initial code).

Acknowledgements

Conformal prediction (CP) experiments were adapted from the CP functions provided by the Volkamer Lab.

License

Citation