Installation
TiRank supports multiple installation methods. It is recommended to create a dedicated conda environment to ensure compatibility.
Method 1: Bioconda Installation (Recommended)
This is the easiest method. You can install the stable version of TiRank directly from the Bioconda channel.
Clone the TiRank repository (for access to example scripts):
git clone https://github.com/LenisLin/TiRank.git cd TiRank
Create a clean python environment:
conda create -n tirank python=3.9 conda activate tirank
Install TiRank:
conda install -c bioconda -c conda-forge tirank leidenalg python-igraph
Note
The TiRank framework has been tested on Ubuntu 22.04 with Python 3.9, using NVIDIA Driver 12.4 and RTX 3090 GPUs.
Method 2: Docker
Install Docker
Ensure Docker is installed on your system.
Pull the TiRank Docker Image
docker pull lenislin/tirank_v1:latest
Run the Docker Container
docker run -p 8050:8050 lenislin/tirank_v1:latest /bin/bash
Verify Container Execution
After running the above command, you should be inside the container’s terminal. Verify the setup by activating the environment and checking the TiRank version:
conda activate TiRank python -c "import tirank; print(tirank.__version__)"
Persistent Data Storage (Optional)
To mount a local directory to retain data inside the container:
docker run -it -v /path/to/local/data:/container/data lenislin/tirank_v1:latest /bin/bash
Stop and Remove the Docker Container
Use the following commands to manage containers:
docker stop <container_id> docker rm <container_id>
Method 3: Interactive Web Tool (GUI)
This method is for running the TiRank web application locally.
Set Up the Web Server
Navigate to the
Webdirectory and create adatafolder:cd TiRank/Web mkdir data
Download the required datasets and pretrained models into the newly created
datadirectory:Set Up Directory Structure
Ensure the following directory structure is maintained within the
Webfolder:Web/ ├── assets/ ├── components/ ├── img/ ├── layout/ ├── data/ │ ├── pretrainModel/ │ │ └── ctranspath.pth │ ├── ExampleData/ │ │ ├── CRC_ST_Prog/ │ │ └── SKCM_SC_Res/ ├── tiRankWeb/ └── app.py
Run the Web Application
Execute the following command from within the
Webdirectory:python app.pyAccess the Web Interface
Open a web browser and navigate to
http://localhost:8050to access the TiRank GUI.