GW-HIVE / biomuta-old

Documentation: https://biomuta.readthedocs.io/en/latest/
0 stars 0 forks source link

BioMuta pipeline

Overview

The BioMuta pipeline gathers mutation data from various sources and combines them into a single dataset under common field structure.

The sources included in BioMuta are:

BioMuta gathers mutation data for the following cancers:

Features

BioMuta pipeline comprises two steps:

  1. Download Downloads mutation lists from each source. TBA: cBioPortal fields, cBioPortal studies
  2. Convert Formats all resources to the BioMuta standard for both data and field structure.

Usage

(This is a draft.) Script execution order (some scripts will be moved into appropriate directories later) 1 - fetch_mutations.sh 2 - cancer_types.py | integrate_cancer_types.sh

UniProt Accession Numbers

  1. Extract GRCh37 chromosomic positions and write out in BED format.
    • script: /pipeline/convert_step2/liftover/1_chr_pos_to_bed_ver2.py
    • output: /biomuta/generated/datasets/2024_10_22/hg19positions.bed
  2. Use UCSC LiftOver to convert to GRCh38 chromosomic positions. 2.1 Run 2_liftover.sh on hg19positions.bed with the chain file ucscHg19ToHg38.over.chain. You will get successfully mapped positions in hg38positions.bed and unmapped positions in unmapped.bed. 2.2 grep -v '^#' unmapped.bed > unmapped_ucsc.bed to delete comments generated by liftOver 2.3 Run the same script but use unmapped.bed as the input and ensembl_GRCh37_to_GRCh38.chain as the chain file. You will get successfully mapped positions in hg38positions_unmapped_by_uscs.bed and unmapped positions in unmapped_ensembl.bed.
  3. Grab the corresponding ENSEMBL transcript ID.
  4. Map to ENSEMBL protein ID.
  5. Map to UniProt Canonical Accession Numbers.

Project Structure

License

Acknowledgements

The liftover from GRCh37 to GRCh38 was performed with the LiftOver command line tool developed by UCSC (insert link).

Setting config parameters

After cloning this repo, you will need to set the parameters given in pipeline/config.json.

Deprecated documentation

Requirements

The following must be available on your server:

Setting config parameters

After cloning this repo, you will need to set the parameters given in cof/config.json. The "server" paramater can be "tst" or "prd" for test or production server respectively. The "app_port" is the port in the host that should map to docker container for the app.

Creating and starting docker container for the APP

From the "app" subdirectory, run the python script given to build and start container:

  python3 create_app_container.py -s {DEP}
  docker ps --all

The last command should list docker all containers and you should see the container you created "running_hivelabapp{DEP}". To start this container, the best way is to create a service file (/usr/lib/systemd/system/docker-hivelab-app-{DEP}.service), and place the following content in it.

  [Unit]
  Description=Glyds APP Container
  Requires=docker.service
  After=docker.service

  [Service]
  Restart=always
  ExecStart=/usr/bin/docker start -a running_hivelab_app_{DEP}
  ExecStop=/usr/bin/docker stop -t 2 running_hivelab_app_{DEP}

  [Install]
  WantedBy=default.target

This will allow you to start/stop the container with the following commands, and ensure that the container will start on server reboot.

  $ sudo systemctl daemon-reload 
  $ sudo systemctl enable docker-hivelab-app-{DEP}.service
  $ sudo systemctl start docker-hivelab-app-{DEP}.service
  $ sudo systemctl stop docker-hivelab-app-{DEP}.service

Mapping APP and API containers to public domains

To map the APP and API containers to public domains (e.g. www.hivelab.org and api.hivelab.org), add apache VirtualHost directives. This VirtualHost directive can be in a new f ile (e.g. /etc/httpd/conf.d/hivelab.conf).

  <VirtualHost *:443>
    ServerName www.hivelab.org
    ProxyPass / http://127.0.0.1:{APP_PORT}/
    ProxyPassReverse / http://127.0.0.1:{APP_PORT}/
  </VirtualHost>

where {APP_PORT} and {API_PORT} are your port for the APP and API ports in conf/config.json file. You need to restart apache after this changes using the following command:

   $ sudo apachectl restart