#!/bin/bash set -e set -o pipefail umask 0002 #### SET THE STAGE SCRATCH_DIR=/scratch/test_masa1_2024-11-13--15-48-43_temp$$ GSTORE_DIR=/srv/GT/analysis/course_sushi/public/gstore/projects INPUT_DATASET=/srv/GT/analysis/course_sushi/public/gstore/projects/p1000/test_masa1_2024-11-13--15-48-43/input_dataset.tsv LAST_JOB=TRUE echo "Job runs on `hostname`" echo "at $SCRATCH_DIR" mkdir $SCRATCH_DIR || exit 1 cd $SCRATCH_DIR || exit 1 source /usr/local/ngseq/etc/lmod_profile module add QC/FastQC/0.12.1 Dev/R/4.4.0 Tools/Picard/3.2.0 Tools/samtools/1.20 Dev/Python/3.11.5 QC/fastp/0.23.4 #### NOW THE ACTUAL JOBS STARTS R --vanilla --slave<< EOT EZ_GLOBAL_VARIABLES <<- '/usr/local/ngseq/opt/EZ_GLOBAL_VARIABLES.txt' if (!library(ezRun, logical.return = TRUE)){ message('retry loading ezRun') Sys.sleep(120) library(ezRun) } param = list() param[['cores']] = '1' param[['ram']] = '15' param[['scratch']] = '10' param[['partition']] = 'course' param[['process_mode']] = 'DATASET' param[['samples']] = 'mut11,mut22' param[['paired']] = 'true' param[['showNativeReports']] = 'false' param[['specialOptions']] = '' param[['cmdOptions']] = '' param[['mail']] = 'masaomi.hatakeyama@uzh.ch' param[['sushi_app']] = 'FastqcApp' param[['name']] = 'FastQC' param[['dataRoot']] = '/srv/GT/analysis/course_sushi/public/gstore/projects' param[['resultDir']] = 'p1000/test_masa1_2024-11-13--15-48-43' param[['isLastJob']] = TRUE output = list() output[['Name']] = 'FastQC' output[['MultiQC Report [Link]']] = 'p1000/test_masa1_2024-11-13--15-48-43/multi_FastQC/multiqc_report.html' output[['MultiQC [File]']] = 'p1000/test_masa1_2024-11-13--15-48-43/multi_FastQC' output[['FastQC [File]']] = 'p1000/test_masa1_2024-11-13--15-48-43/FastQC' output[['Order Id [B-Fabric]']] = '35755' input = '/srv/GT/analysis/course_sushi/public/gstore/projects/p1000/test_masa1_2024-11-13--15-48-43/input_dataset.tsv' EzAppFastqc\$new()\$run(input=input, output=output, param=param) EOT #### JOB IS DONE WE PUT THINGS IN PLACE AND CLEAN AUP rsync -r multi_FastQC /srv/GT/analysis/course_sushi/public/gstore/projects/p1000/test_masa1_2024-11-13--15-48-43/ rsync -r FastQC /srv/GT/analysis/course_sushi/public/gstore/projects/p1000/test_masa1_2024-11-13--15-48-43/ cd /scratch rm -rf /scratch/test_masa1_2024-11-13--15-48-43_temp$$ || exit 1 echo __SCRIPT END__