Skip to content

About

Hybrid ML + Marcus theory model to predict and rationalize triplet energy transfer (EnT) reactivity.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Latest commit

 

History

1 Commit

Folders and files

Repository files navigation

MarcusEnTdecker

Python Paper Zenodo ioChem-BD Web app

This repository accompanies our manuscript:

Hölter, N.; Schlosser, L.; Hümpel, C.; Spierling, L.; Glorius, F.
A Hybrid Machine Learning and Marcus Theory Approach for Rationalizing and Predicting Triplet Energy Transfer.
Manuscript in preparation; publication link to follow.

It builds on the original EnTdecker platform:

Schlosser, L.; Rana, D.; Pflüger, P.; Katzenburg, F.; Glorius, F.
EnTdecker—A Machine Learning-Based Platform for Guiding Substrate Discovery in Energy Transfer Catalysis.
J. Am. Chem. Soc. 2024, 146 (19), 13266–13275. DOI: 10.1021/jacs.4c01352.

The ML framework in this repository predicts, from a SMILES string, the adiabatic triplet energy ET, the reorganization energies λS0-T1 and λT1-S0, and the triplet spin populations of a molecule. Each prediction comes with an uncertainty. Combined with Marcus theory, these predictions give the driving force and the barrier of triplet energy transfer from a photocatalyst.

Installation

Requires Python ≥ 3.12.

git clone https://github.com/GloriusGroup/MarcusEnTdecker.git
cd MarcusEnTdecker

With uv (recommended):

uv sync --extra ml          # ML models, Python API and the ent-ml command line
uv sync --extra webapp      # the same, plus the web application

With pip:

python -m venv .venv
source .venv/bin/activate   # Windows: .venv\Scripts\activate
pip install -e ".[ml]"      # or ".[webapp]"

The trained model (ml/data/model_final.pt) is part of the repository.

Usage

Command line:

uv run ent-ml predict "C=Cc1ccccc1"                  # triplet and reorganization energies, uncertainties
uv run ent-ml predict --file smiles.txt --format csv --out predictions.csv
uv run ent-ml rate --quencher "C=Cc1ccccc1" \
    --photocatalysts data/computational_data_processed/photocatalyst_properties_calc.xlsx \
    --photocatalyst 1                                # driving force, barrier, rate constant
uv run ent-ml --help

Python:

from ml.prediction import predict
from ml.predict import RatePredictor, photocatalyst_properties

predict(["C=Cc1ccccc1"])        # DataFrame: triplet and reorganization energies, uncertainties, spin populations

pc = photocatalyst_properties(
    "data/computational_data_processed/photocatalyst_properties_calc.xlsx", 1)   # PC1
result = RatePredictor().predict(pc, quencher="C=Cc1ccccc1")
result.dG_kcal, result.dG_barrier_kcal, result.k_ent

The photocatalyst properties (ET, λ) come from DFT. ml/README.md describes the model, its training and the full API.

Web application

EnTdecker serves the model in the browser and computes the EnT barrier for any molecule against the 35 photocatalysts of our library. It is hosted at https://entdecker.uni-muenster.de. To run it locally:

uv sync --extra webapp
uv run uvicorn webapp.app:app --port 5000           # then open http://127.0.0.1:5000

Reproducing the paper

The data-processing pipeline and benchmark analyses are in data/ and benchmark/; data/README.md and benchmark/README.md describe them.

The Zenodo archive includes the code, models, processed data and both raw-data folders: data/experimental_data_raw/ and data/computational_data_raw/. The GitHub checkout excludes these raw folders; download them from the Zenodo deposit to run the full pipeline.

uv run reproduce.py              # all stages: data, benchmark, further_analysis, webapp
uv run reproduce.py benchmark    # one stage

After extracting the Zenodo archive, run the commands above from its repository folder. The raw inputs are already in data/. In a GitHub checkout without the raw inputs, reproduce.py skips extraction and rebuilds the remaining stages from the supplied tables.

Tests: uv run --extra webapp --group dev pytest.

Publication

  • Current manuscript: publication link to follow
  • Data and archived code: Zenodo
  • DFT calculations: ioChem-BD
  • Web application: EnTdecker

If you use this code or data, please cite our manuscript and the original EnTdecker publication listed above.

Credits

The model code is pyrates by Leon Schlosser, carried here as the ml package; ml/README.md records its origin.

About

Hybrid ML + Marcus theory model to predict and rationalize triplet energy transfer (EnT) reactivity.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages