1#!/usr/local/bin/bash
2
3# These are example SCRIPTs to run PFAM with MPI ON PBS. Minor changes would be needed for LSF etc
4# executable for mpirun, e.g. from OpenMPI
5MPIRUN_EXEC=`which mpirun`
6# these arguments are valid for OpenMPI, change them for Intel's
7MPIRUN_ARGS="-gmca mpi_warn_on_fork 0 -cpus-per-proc 1 -np $2 -machinefile workers.$PBS_JOBID.mpi"
8
9#executable of hhmscan
10HMMSCAN_EXEC=`which hmmscan`
11
12#your PFAM database
13PFAMDB=/home/pap056/30day/databases/pfam/Pfam-AB.hmm.bin
14
15# no need to change the following
16
17export OMP_NUM_THREADS=1
18# the PBS_O_WORKDIR is where you launched the script from. Feel free to change this if you need
19# to launch it from a difference directory
20cd $PBS_O_WORKDIR
21cat ${PBS_NODEFILE} > workers.$PBS_JOBID.mpi
22$MPIRUN_EXEC $MPIRUN_ARGS ffindex_apply_mpi \
23 -d "$1"_out2.db \
24 -i "$1"_out2.db.idx \
25 $1 \
26 $1.idx \
27 -- $HMMSCAN_EXEC -o /dev/null --cpu 1 --noali --cut_nc --acc --notextw --domtblout /dev/stdout $PFAMDB -
28