Commit c6386098 authored by wangsen's avatar wangsen
Browse files

add higashi

parent 127b175d
Pipeline #1761 canceled with stages
# 论文
Higashi: Multiscale and integrative scHi-C analysis
https://doi.org/10.1038/s41587-021-01034-y
# 模型结构
Higashi使用超图神经网络来揭示这个构造的超图中的高阶交互模式。Higashi可以为scHi-C制作嵌入物,用于下游分析。Higashi可以输入单细胞Hi-C接触图谱,从而能够以单细胞分辨率详细表征3D基因组特征,如TAD样结构域边界和A/B区分数。
![Alt text](./image/image.png)
# 算法原理
Higashi的关键算法设计是将scHi-C数据转换为超图。这种转化保留了scHi-C接触图谱的单细胞分辨率和3D基因组特征。具体来说,嵌入scHi-C数据的过程现在相当于学习超图的节点嵌入,输入scHi-C接触图就变成了预测超图中缺失的超边。在Higashi,我们使用我们最近开发的Hyper-SAGNN架构22,这是一个通用的超图表示学习框架,专门针对scHi-C分析进行了大量的新开发
![Alt text](./image/image-1.png)
# 环境配置
Docker(方式一)
推荐使用docker方式运行,提供拉取的docker镜像:
```
docker pull image.sourcefind.cn:5000/dcu/admin/base/pytorch:2.1.0-ubuntu20.04-dtk24.04.1-py3.10
docker run -dit --shm-size 80g --network=host --name=geneformer --privileged --device=/dev/kfd --device=/dev/dri --group-add video --cap-add=SYS_PTRACE --security-opt seccomp=unconfined -u root -v /opt/hyhal/:/opt/hyhal/:ro image.sourcefind.cn:5000/dcu/admin/base/pytorch:2.1.0-ubuntu20.04-dtk24.04.1-py3.10 /bin/bash
docker exec -it geneformer /bin/bash
```
安装docker中没有的依赖:
```
pip install -r requirements.txt -i http://mirrors.aliyun.com/pypi/simple/ --trusted-host mirrors.aliyun.com
```
Dockerfile(方式二)
```
docker build -t geneformer:latest .
docker run -dit --shm-size 80g --network=host --name=geneformer --privileged --device=/dev/kfd --device=/dev/dri --group-add video --cap-add=SYS_PTRACE --security-opt seccomp=unconfined -u root -v /opt/hyhal/:/opt/hyhal/:ro geneformer:latest /bin/bash
docker exec -it geneformer /bin/bash
```
Conda(方式三)
1.创建conda虚拟环境:
```
conda create -n geneformer python=3.10
conda activate geneformer
```
2.关于本项目DCU显卡所需的工具包、深度学习库等均可从光合开发者社区下载安装。
- [DTK 24.04.1](https://cancon.hpccube.com:65024/directlink/1/DTK-24.04.1/Ubuntu20.04.1/DTK-24.04.1-Ubuntu20.04.1-x86_64.tar.gz)
- [Pytorch 2.1](https://cancon.hpccube.com:65024/directlink/4/pytorch/DAS1.2/torch-2.1.0+das.opt1.dtk24042-cp310-cp310-manylinux_2_28_x86_64.whl)
Tips:以上dtk驱动、torch等工具版本需要严格一一对应。
3. 其它依赖库参照requirements.txt安装:
```
pip install -r requirements.txt -i http://mirrors.aliyun.com/pypi/simple/ --trusted-host mirrors.aliyun.com
```
# 下载数据
```
......
{% set name = "higashi" %}
{% set version = "0.1.0a0" %}
package:
name: "{{ name|lower }}"
version: "{{ version }}"
source:
# url: "https://test.pypi.io/packages/source/{{ name[0] }}/{{ name }}/{{ name }}-{{ version }}.tar.gz"
git-url:
build:
number: 0
script: "{{ PYTHON }} -m pip install . -vv"
requirements:
host:
- bokeh >=2.1.1
- cooler >=0.8
- cython >=0.29.24
- fbpca
- h5py
- numpy >=1.21.2
- pandas >=1.3.4
- pillow
- pip
- python >=3.9
- pytorch >=1.8
- scikit-learn >=0.23.2
- scipy >=1.7.3
- seaborn >=0.11.2
- tqdm
- umap-learn >=0.5
run:
- bokeh >=2.1.1
- cooler >=0.8
- cython >=0.29.24
- fbpca
- h5py
- numpy >=1.21.2
- pandas >=1.3.4
- pillow
- python >=3.9
- pytorch >=1.8
- scikit-learn >=0.23.2
- scipy >=1.7.3
- seaborn >=0.11.2
- tqdm
- umap-learn >=0.5
test:
imports:
- higashi
- higashi.Higashi_analysis
- higashi.Higashi_backend
about:
home: "https://github.com/ma-compbio/Higashi"
license: MIT
license_family: MIT
license_file:
summary: "Higashi: Multiscale and integrative scHi-C analysis"
doc_url:
dev_url:
extra:
recipe-maintainers:
- your-github-id-here
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment