scTranslation
收藏资源简介:
scTranslation是一个专为单细胞多组学模态转换任务设计的综合性基准数据集,由西湖大学等机构联合构建,旨在系统评估跨模态预测模型的性能。该基准整合了八项高质量数据集,涵盖SNARE-seq、10x Multiome、CITE-seq等多种技术,涉及人类与小鼠的多个器官及发育阶段,数据规模从数百至数万细胞不等,特征维度高达数十万。数据集的创建过程严格遵循6M标准(多技术、多物种、多器官、多组学、多规模、多阶段),通过公开数据库收集并预处理了匹配的RNA、ATAC及蛋白质表达矩阵。该数据集主要应用于计算生物学领域,致力于解决单细胞多组学实验成本高昂、数据稀疏及模态缺失等问题,为跨模态预测模型提供标准化评估框架,推动精准医学与发育生物学研究。
scTranslation is a comprehensive benchmark dataset specifically developed for single-cell multi-omics modal translation tasks, jointly constructed by Westlake University and other research institutions, with the goal of systematically evaluating the performance of cross-modal prediction models. This benchmark integrates eight high-quality datasets, covering multiple technologies including SNARE-seq, 10x Multiome, and CITE-seq, and involves multiple organs and developmental stages of humans and mice. The dataset comprises samples ranging from hundreds to tens of thousands of cells, with feature dimensions reaching up to hundreds of thousands. The construction of this dataset strictly adheres to the 6M criteria (multiple technologies, multiple species, multiple organs, multi-omics, multiple scales, multiple stages), where matched RNA, ATAC and protein expression matrices were collected and preprocessed from public databases. This dataset is primarily applied in the field of computational biology, aiming to address challenges such as high experimental costs, data sparsity and modality deficiency in single-cell multi-omics experiments, providing a standardized evaluation framework for cross-modal prediction models, and advancing research in precision medicine and developmental biology.
ScTranslation 单细胞跨模态翻译基准
项目概述
ScTranslation 是一个用于单细胞数据跨模态翻译的基准测试平台,支持 RNA、ATAC 和 ADT/Protein 三种模态之间的相互转换(RNA ⇄ ATAC 和 RNA ⇄ ADT),集成了六种代表性方法,并通过统一的 Runner 接口封装。
集成方法与模态支持
| 模型 | 实现路径 | 支持模态 |
|---|---|---|
| BABEL | sctranslation/models/babel |
RNA, ATAC, ADT |
| scButterfly | sctranslation/models/scbutterfly |
RNA, ATAC, ADT |
| JAMIE | sctranslation/models/jamie |
RNA, ATAC, ADT |
| multiDGD | sctranslation/models/multidgd |
RNA, ATAC, ADT |
| scPair | sctranslation/models/scpair |
RNA, ATAC, ADT |
| scDiffusionX | sctranslation/models/scdiffusionx |
RNA, ATAC, ADT |
每种方法通过统一的 Runner 接口(train, test, preprocessing_pipeline_{r,a,p})驱动,共享相同的预处理、数据集和评估代码。
安装要求
- 推荐使用 Python 3.10 的 conda 环境
- 需安装 PyTorch(CUDA 版本匹配)
- 通过
pip install -r requirements.txt安装依赖 - 部分方法需额外安装
episcanpy、scib、blobfile等原生依赖
数据集布局
数据集存储在统一根目录下,每个数据集一个子目录,每种模态对应一个 AnnData(.h5ad)文件:
$SCT_ROOT/ └── <dataset_name>/ ├── RNA_data.h5ad # 必需:RNA-seq 计数 ├── ATAC_data.h5ad # 可选:ATAC 峰矩阵 ├── ADT_data.h5ad # 可选:ADT 计数 └── split_<seed>.pkl # 首次运行自动生成
所有 AnnData 文件须共享相同的细胞索引(obs_names),且 obs 中包含 cell_type 列用于聚类评估。数据集根目录可通过环境变量 SCT_ROOT 或命令行参数 --root_path 设置,默认值为 ./datasets。
运行单个模型
每个方法提供独立的 CLI 入口(位于 tests/ 目录),支持训练和测试两种模式。常用参数包括:
| 参数 | 说明 | 默认值 |
|---|---|---|
--mode |
训练或测试模式 | 各模型不同 |
--data_name |
数据集子文件夹名称 | 示例数据集名 |
--root_path |
数据集根目录 | $SCT_ROOT 或 ./datasets |
--config_path |
YAML 配置文件路径 | configs/default.yaml |
--random_seed |
数据划分和初始化种子 | 0 |
--modal1/--modal2 |
模态标识(r/a/p) | r / a |
--model_file |
模型检查点读写路径 | ./output/<模型名>/ |
--saved_path |
预测结果和评估指标输出路径 | ./output/statistics/<模型名> |
--data_path |
预处理后输入数据缓存路径 | ./data/<模型名> |
以 BABEL 为例,RNA→ATAC 翻译的训练命令: bash python tests/BABEL.py --mode train --data_name Chen_2019 --modal2 a --random_seed 0
scDiffusionX 训练需使用 torchrun 多 GPU 启动。
批量运行
scripts/ 目录下的 shell 脚本可复现论文实验:
run_baselines.sh:训练并测试除 scDiffusionX 外的所有模型run_scdiffusionx.sh:单独运行 scDiffusionX
支持通过环境变量 CUDA_VISIBLE_DEVICES、SCT_ROOT、CONFIG 等控制运行配置。
评估指标
模型测试阶段生成 test_<任务>_pred.h5ad 和 test_<任务>_truth.h5ad 文件(任务包括 a2r、r2a、r2p),使用 tests/evaluation.py 计算以下指标:
- 聚类评估(Leiden 聚类 vs 真实
cell_type):ARI, AMI, NMI, HOM - 表达水平评估:PCC, Spearman, MSE, MAE
- 生成质量评估:MMD, iLISI
- 分类评估:AUROC, 特征级相关性
每个输出 AnnData 的 var 中还存储了单细胞的 PCC 值。
可重复性说明
- 数据集划分完全由
--random_seed参数决定,并缓存为split_<seed>.pkl文件 - 每次运行前调用
seed_everything确保随机性可复现 - 在相同输入条件下,所有评估输出具有确定性




