Biowulf High Performance Computing at the NIH
Basset on Biowulf

Deep convolutional neural networks for DNA sequence analysis. Basset provides researchers with tools to:

References:

Documentation
Important Notes

Interactive job
Interactive jobs should be used for debugging, graphics, or applications that cannot be run as batch jobs.

Allocate an interactive session and run the program. Sample session:

[user@biowulf]$ sinteractive --gres=gpu:k80:1,lscratch:10 --mem=20g -c14
salloc.exe: Pending job allocation 46116226
salloc.exe: job 46116226 queued and waiting for resources
salloc.exe: job 46116226 has been allocated resources
salloc.exe: Granted job allocation 46116226
salloc.exe: Waiting for resource configuration
salloc.exe: Nodes cn3144 are ready for job

[user@cn3144 ~]$ module load basset
[+] Loading basset 0.1.0 on cn3586
[+] Loading singularity 2.4 on cn3586

[user@cn3144 ~]$ cp /usr/local/apps/basset/Basset/data/models/pretrained_model.* .

[user@cn3144 ~]$ cp /usr/local/apps/basset/Basset/tutorials/sad_eg/* .

[user@cn3144 ~]$ basset basset_sad.py -l 600 -i -o sad -s -f /fdb/genome/hg19/hg19.fa -t sample_beds.txt pretrained_model.th rs13336428.vcf
WARNING: Skipping user bind, non existent bind point (file) in container: '/usr/bin/nvidia-smi'
WARNING: Bind file source does not exist on host: /etc/resolv.conf
/Basset/src/basset_predict.lua -rc  pretrained_model.th sad/model_in.h5 sad/model_out.txt

[user@cn3144 ~]$ exit
salloc.exe: Relinquishing job allocation 46116226
[user@biowulf ~]$

Batch job
Most jobs should be run as batch jobs.

Create a batch input file (e.g. basset.sh). For example:

#!/bin/bash
#SBATCH --partition=gpu
#SBATCH --gres=gpu:k80:1,lscratch:10
module load basset
basset basset_sad.py -l 600 -i -o sad -s -f /fdb/genome/hg19/hg19.fa -t sample_beds.txt pretrained_model.th rs13336428.vcf

Submit this job using the Slurm sbatch command.

sbatch --cpus-per-task=14 --mem=20g basset.sh
Swarm of Jobs
A swarm of jobs is an easy way to submit a set of independent commands requiring identical resources.

Create a swarmfile (e.g. basset.swarm). For example:

basset basset_sad.py -o sad1 -t sample_beds1.txt ... s1.vcf
basset basset_sad.py -o sad2 -t sample_beds2.txt ... s2.vcf
basset basset_sad.py -o sad3 -t sample_beds3.txt ... s3.vcf
[... rest of options]

Submit this job using the swarm command.

swarm -f basset.swarm -g 20 -t 14 --module basset
where
-g # Number of Gigabytes of memory required for each process (1 line in the swarm command file)
-t # Number of threads/CPUs required for each process (1 line in the swarm command file).
--module basset Loads the basset module for each subjob in the swarm