Skip to content

Commit

Permalink
Modified pipelines paths where necessary
Browse files Browse the repository at this point in the history
  • Loading branch information
victor5lm committed Jun 18, 2024
1 parent 9eb9f21 commit 97c08fe
Show file tree
Hide file tree
Showing 13 changed files with 17 additions and 17 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ mkdir logs

scratch_dir=$(echo $PWD | sed "s/\/data\/bi\/scratch_tmp/\/scratch/g")

cat ../samples_id.txt | while read in; do echo "srun --partition short_idx --cpus-per-task 32 --mem 35000M --chdir $scratch_dir --time 01:00:00 --output logs/IRMA.${in}.%j.log /data/bi/pipelines/flu-amd-202402/IRMA FLU_AD ../02-preprocessing/${in}/${in}_R1_filtered.fastq.gz ../02-preprocessing/${in}/${in}_R2_filtered.fastq.gz ${in} --external-config ../../../DOC/irma_config.sh &"; done > _01_irma.sh
cat ../samples_id.txt | while read in; do echo "srun --partition short_idx --cpus-per-task 32 --mem 35000M --chdir $scratch_dir --time 01:00:00 --output logs/IRMA.${in}.%j.log /data/bi/pipelines/flu-amd/flu-amd-1.1.4/IRMA FLU_AD ../02-preprocessing/${in}/${in}_R1_filtered.fastq.gz ../02-preprocessing/${in}/${in}_R2_filtered.fastq.gz ${in} --external-config ../../../DOC/irma_config.sh &"; done > _01_irma.sh

echo 'bash create_irma_stats.sh' > _02_create_stats.sh

Expand All @@ -32,4 +32,4 @@ echo 'grep -w 'C__' irma_stats.txt | cut -f1 | while read sample; do cat C_fragm
echo 'cat ../samples_id.txt | while read in; do cat ${in}/*.fasta | sed "s/^>/\>${in}_/g" | sed 's/_H1//g' | sed 's/_H3//g' | sed 's/_N1//g' | sed 's/_N2//g' | sed 's@-@/@g' | sed 's/_A_/_/g' | sed 's/_B_/_/g' | sed 's/_C_/_/g' >> all_samples_completo.txt; done' >> _03_post_processing.sh

echo 'sed "s/__//g" irma_stats.txt > clean_irma_stats.txt' >> _03_post_processing.sh
echo 'sed "s/_\t/\t/g" irma_stats.txt > clean_irma_stats.txt' >> _03_post_processing.sh
echo 'sed "s/_\t/\t/g" irma_stats.txt > clean_irma_stats.txt' >> _03_post_processing.sh
2 changes: 1 addition & 1 deletion bu_isciii/templates/IRMA/ANALYSIS/ANALYSIS02_MET/lablog
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ cat <<EOF > mag.sbatch

export NXF_OPTS="-Xms500M -Xmx4G"

nextflow run /scratch/bi/pipelines/nf-core-mag-2.1.1/workflow/main.nf \\
nextflow run /data/bi/pipelines/nf-core-mag/nf-core-mag-2.1.1/workflow/main.nf \\
-c ../../DOC/mag.config \\
--input '00-reads/*_R{1,2}.fastq.gz' \\
--outdir $(date '+%Y%m%d')_mag \\
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ cat <<EOF > assembly.sbatch
# module load Nextflow/23.10.0 singularity
export NXF_OPTS="-Xms500M -Xmx8G"

nextflow run /data/bi/pipelines/nf-core-bacass/main.nf \\
nextflow run /data/bi/pipelines/nf-core-bacass/nf-core-bacass-2.2.0dev/main.nf \\
-c ../../DOC/hpc_slurm_assembly.config \\
-profile singularity \\
--input samplesheet.csv \\
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ cat <<EOF > mag.sbatch

export NXF_OPTS="-Xms500M -Xmx4G"

nextflow run /scratch/bi/pipelines/nf-core-mag-2.1.1/workflow/main.nf \\
nextflow run /data/bi/pipelines/nf-core-mag/nf-core-mag-2.1.1/workflow/main.nf \\
-c ../../DOC/mag.config \\
--input '00-reads/*_R{1,2}.fastq.gz' \\
--outdir $(date '+%Y%m%d')_mag \\
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ echo "sbatch bcftools_query.sbatch" > _01_bcftools_query.sh


# module load Java/1.8.0_281 R/4.1.0-foss-2021a
cat ../samples_id.txt | xargs -I @@ echo "mkdir @@;srun --chdir ${scratch_dir} --output logs/KGGSEQ.@@.%j.log --job-name KGGSEQ --cpus-per-task 1 --mem 8192 --partition short_idx --time 02:00:00 java -jar -Xmx8g /data/bi/pipelines/kggseqhg19/kggseq.jar --no-web --buildver hg19 --vcf-file ../06-VarScan/@@/@@.vcf.gz --db-gene refgene --db-score dbnsfp --genome-annot --db-filter ESP5400,dbsnp141,1kg201305 --rare-allele-freq 1 --mendel-causing-predict best --omim-annot --out @@/@@_annot.txt --no-qc &" > _02_kggseq.sh
cat ../samples_id.txt | xargs -I @@ echo "mkdir @@;srun --chdir ${scratch_dir} --output logs/KGGSEQ.@@.%j.log --job-name KGGSEQ --cpus-per-task 1 --mem 8192 --partition short_idx --time 02:00:00 java -jar -Xmx8g /data/bi/pipelines/kggseq/kggseqhg19/kggseq.jar --no-web --buildver hg19 --vcf-file ../06-VarScan/@@/@@.vcf.gz --db-gene refgene --db-score dbnsfp --genome-annot --db-filter ESP5400,dbsnp141,1kg201305 --rare-allele-freq 1 --mendel-causing-predict best --omim-annot --out @@/@@_annot.txt --no-qc &" > _02_kggseq.sh
cat ../samples_id.txt | xargs -I % echo "gunzip %/%_annot.txt.flt.txt.gz" > _03_final_table.sh
cat ../samples_id.txt | xargs -I % echo 'cp header %/%_header.table && tail -n +2 %/%.table >> %/%_header.table' >> _03_final_table.sh
cat ../samples_id.txt | xargs -I % echo "Rscript merge_parse.R %" >> _03_final_table.sh
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ scratch_dir=$(echo $PWD | sed "s/\/data\/bi\/scratch_tmp/\/scratch/g")

mkdir logs

cat ../samples_id.txt | while read in; do echo "srun --partition short_idx --chdir ${scratch_dir} --mem 50G --output logs/KMERFINDER.${in}.%j.log singularity run -B /scratch/bi/ -B /data/bi/references/kmerfinder/20190108_stable_dirs/bacteria /scratch/bi/pipelines/kmerfinder_v3.0.simg -i ../01-preprocessing/${in}/${in}_R1_filtered.fastq.gz ../01-preprocessing/${in}/${in}_R2_filtered.fastq.gz -o ${scratch_dir}/${in} -db /data/bi/references/kmerfinder/20190108_stable_dirs/bacteria/bacteria.ATG -tax /data/bi/references/kmerfinder/20190108_stable_dirs/bacteria/bacteria.name -x &";done > _01_kmerfinder.sh
cat ../samples_id.txt | while read in; do echo "srun --partition short_idx --chdir ${scratch_dir} --mem 50G --output logs/KMERFINDER.${in}.%j.log singularity run -B /scratch/bi/ -B /data/bi/references/kmerfinder/20190108_stable_dirs/bacteria /data/bi/pipelines/singularity-images/kmerfinder_v3.0.simg -i ../01-preprocessing/${in}/${in}_R1_filtered.fastq.gz ../01-preprocessing/${in}/${in}_R2_filtered.fastq.gz -o ${scratch_dir}/${in} -db /data/bi/references/kmerfinder/20190108_stable_dirs/bacteria/bacteria.ATG -tax /data/bi/references/kmerfinder/20190108_stable_dirs/bacteria/bacteria.name -x &";done > _01_kmerfinder.sh

echo "cat ../samples_id.txt | xargs -I % awk '{FS=\"\t\"} NR==2 {print \$1}' %/results.txt | awk '{count[\$0]++} END{for (i in count) {print count[i], i}}' | sort -nr" > _02_find_common_reference.sh

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ cat <<EOF > pikavirus.sbatch

export NXF_OPTS="-Xms500M -Xmx4G"

nextflow run /scratch/bi/pipelines/PikaVirus/main.nf \\
nextflow run /data/bi/pipelines/pikavirus/PikaVirus/main.nf \\
-c ../../DOC/hpc_slurm_pikavirus.config \\
--input samplesheet.csv \\
--kraken_scouting false \\
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ cat <<EOF > rnaseq.sbatch

export NXF_OPTS="-Xms500M -Xmx4G"

/data/bi/pipelines/nf-core-rnaseq-3.10.1/workflow/main.nf \\
/data/bi/pipelines/nf-core-rnaseq/nf-core-rnaseq-3.10.1/workflow/main.nf \\
-c ../../DOC/hpc_slurm_rnaseq.config \\
-params-file ../../DOC/hg38_ensmbl_rnaseq.yml \\
--input samplesheet.csv \\
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ cat <<EOF > seek_destroy.sbatch

export NXF_OPTS="-Xms500M -Xmx4G"

nextflow run /scratch/bi/pipelines/Seek-Destroy/main.nf \\
nextflow run /data/bi/pipelines/seek-destroy-nf/main.nf \\
-c ../../DOC/seek_destroy.config \\
--input samplesheet.csv \\
--scout_database /data/bi/references/kraken/minikraken_8GB_20200312.tgz \\
Expand Down
4 changes: 2 additions & 2 deletions bu_isciii/templates/viralrecon/ANALYSIS/lablog_viralrecon
Original file line number Diff line number Diff line change
Expand Up @@ -363,7 +363,7 @@ do
echo "#SBATCH --output ${ref}_$(date '+%Y%m%d')_viralrecon.log" >> ${FOLDER_NAME}/lablog
printf "#SBATCH --chdir \$scratch_dir\n\n" >> ${FOLDER_NAME}/lablog
printf 'export NXF_OPTS="-Xms500M -Xmx4G"\n\n' >> ${FOLDER_NAME}/lablog
echo "nextflow run /data/bi/pipelines/nf-core-viralrecon-2.6.0/workflow/main.nf \\\\" >> ${FOLDER_NAME}/lablog
echo "nextflow run /data/bi/pipelines/nf-core-viralrecon/nf-core-viralrecon-2.6.0/workflow/main.nf \\\\" >> ${FOLDER_NAME}/lablog
echo " -c ../${CONFIG_FILE} \\\\" >> ${FOLDER_NAME}/lablog
echo " -params-file ../${PARAMS_FILE} \\\\" >> ${FOLDER_NAME}/lablog
echo " --input samplesheet_${ref}.csv \\\\" >> ${FOLDER_NAME}/lablog
Expand Down Expand Up @@ -404,4 +404,4 @@ rm _02_create_run_percentage_Ns.sh
mv DATE_ANALYSIS0X_MAG $(date '+%Y%m%d')_ANALYSIS0X_MAG
cd 00-reads; cat ../samples_id.txt | xargs -I % echo "ln -s ../../RAW/%_*R1*.fastq.gz %_R1.fastq.gz" | bash; cat ../samples_id.txt | xargs -I % echo "ln -s ../../RAW/%_*R2*.fastq.gz %_R2.fastq.gz" | bash; cd ..

echo_green "\nLablog_viralrecon execution has been completed successfully!"
echo_green "\nLablog_viralrecon execution has been completed successfully!"
2 changes: 1 addition & 1 deletion bu_isciii/templates/viralrecon/DOC/viralrecon.config
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
singularity {
enabled = true
autoMounts = true
runOptions = '-B /data/bi/references/ -B /data/bi/pipelines/artic-ncov2019/ -B "$HOME"'
runOptions = '-B /data/bi/references/ -B /data/bi/pipelines/artic-ncov2019/artic-ncov2019/ -B "$HOME"'
}

process {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
singularity {
enabled = true
autoMounts = true
runOptions = '-B /data/bi/references/ -B /data/bi/pipelines/artic-ncov2019/'
runOptions = '-B /data/bi/references/ -B /data/bi/pipelines/artic-ncov2019/artic-ncov2019/'
}

process {
Expand All @@ -10,7 +10,7 @@ process {
withName: 'ARTIC_MINION' {
ext.args = [
'--normalise 500',
'--scheme-directory /data/bi/pipelines/artic-ncov2019/primer_schemes/',
'--scheme-directory /data/bi/pipelines/artic-ncov2019/artic-ncov2019/primer_schemes/',
'--medaka'
].join(' ').trim()
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@ platform: 'nanopore'
protocol: 'amplicon'
artic_scheme: 'nCoV-2019'
primer_set_version: 5
fasta: '/data/bi/pipelines/artic-ncov2019/primer_schemes/nCoV-2019/V5/ESIB-EQA.reference.fasta'
primer_bed: '/data/bi/pipelines/artic-ncov2019/primer_schemes/nCoV-2019/V5/ESIB-EQA.primer.bed'
fasta: '/data/bi/pipelines/artic-ncov2019/artic-ncov2019/primer_schemes/nCoV-2019/V5/ESIB-EQA.reference.fasta'
primer_bed: '/data/bi/pipelines/artic-ncov2019/artic-ncov2019/primer_schemes/nCoV-2019/V5/ESIB-EQA.primer.bed'
primer_fasta: '../../RAW/ESIB_EQA_2023.SARS1/ESIB_EQA_2023.SARS1.primers.fasta'
kraken2_db: '/data/bi/references/eukaria/homo_sapiens/hg38/UCSC/kraken2/kraken2_human.tar.gz'
nextclade_dataset_name: 'sars-cov-2'
Expand Down

0 comments on commit 97c08fe

Please sign in to comment.