| --- |
| license: mit |
| tags: |
| - biology |
| - genomics |
| - gene-expression |
| - enhancer |
| - regulatory-genomics |
| - dna |
| library_name: pytorch |
| --- |
| |
| # EPInformer β pipeline (pretrained checkpoints) |
|
|
| Pretrained checkpoints for the **[EPInformer pipeline](https://github.com/pinellolab/EPInformer/tree/pipeline)** β a from-raw-ENCODE pipeline for [EPInformer](https://github.com/pinellolab/EPInformer) across 6 cell lines (K562, GM12878, H1, HepG2, HUVEC, NHEK). |
|
|
| Two models (defined in `EPInformer/models.py` on the `pipeline` branch): |
|
|
| - **`enhancer_predictor_256bp`** β 256 bp enhancer-activity encoder; predicts `log2(0.1 + sqrt(H3K27acΒ·DNase))` activity from sequence. |
| - **`EPInformer_v2`** β gene-expression model (RNA / CAGE) that reuses the frozen encoder as its sequence backbone. |
| |
| ## Results (12-fold leave-chromosome-out, pooled Pearson R) |
| |
| **Enhancer encoder** (log2 activity): |
| |
| | | H1 | HepG2 | K562 | HUVEC | NHEK | GM12878 | |
| |---|---|---|---|---|---|---| |
| | **R** | 0.820 | 0.743 | 0.740 | 0.742 | 0.677 | 0.617 | |
| |
| **Gene expression** (shipped `f3` = frozen encoder + 3 enhancer features + promoter signal): |
| |
| | | K562 | GM12878 | HepG2 | HUVEC | NHEK | H1 | |
| |---|---|---|---|---|---|---| |
| | **RNA** | 0.856 | 0.860 | 0.845 | 0.839 | 0.828 | 0.781 | |
| | **CAGE** | 0.867 | 0.890 | β | β | β | β | |
| |
| CAGE labels exist only for K562/GM12878 (the other four are RNA-only). |
| |
| ## Files |
| |
| ``` |
| enhancer_encoders/{CELL}/fold_{i}.pt # CELL β {K562, GM12878, H1, HepG2, HUVEC, NHEK}, i β 1..12 |
| expression_models/{CELL}/{ASSAY}/{FEATURE}/fold_*.pt |
| # ASSAY β {RNA, CAGE}; FEATURE β {f1, f2, f3} |
| ``` |
| |
| These are the pipeline's **256 bp enhancer-activity encoders** β the best checkpoint for each of |
| the 12 leave-chromosome-out folds, for all 6 cell lines (72 checkpoints). Any fold works for |
| inference; the R values in the table above are pooled across all 12 held-out folds. |
| |
| The gene-expression checkpoint directories contain 12 folds for each supported cell/assay/feature |
| configuration. Use the matching HDF5 input, expression labels, fold split, and pretrained enhancer |
| encoder described in the pipeline README. |
| |
| > The KLF1 demo in the notebooks uses the original published EPInformer encoder shipped in the repo's |
| > `trained_models/pretrained_enhancer_encoder/` β a separate checkpoint from these folds. |
| |
| ## Usage |
| |
| ```python |
| import torch |
| from huggingface_hub import hf_hub_download |
| # the model class lives on the pipeline branch: |
| # git clone -b pipeline https://github.com/pinellolab/EPInformer |
| from EPInformer.models import enhancer_predictor_256bp |
| |
| ckpt = hf_hub_download("JiecongLin/EPInformer-pipeline", "enhancer_encoders/K562/fold_8.pt") |
| net = enhancer_predictor_256bp() |
| net.load_state_dict(torch.load(ckpt, map_location="cpu", weights_only=False)["model_state_dict"]) |
| net.eval() |
| ``` |
| |
| See the **[project wiki](https://github.com/pinellolab/EPInformer/wiki)** for the full training and evaluation guide, and the **[`pipeline`](https://github.com/pinellolab/EPInformer/tree/pipeline)** branch for code. |
| |