From 8112fe88ef856344d9cb02306c92e59ba25965e7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ram=C3=B3n=20Rivera-Vic=C3=A9ns?= Date: Wed, 15 Sep 2021 10:30:43 +0200 Subject: [PATCH 01/12] Remove old conda parameters --- template.nextflow.config | 6 ------ 1 file changed, 6 deletions(-) diff --git a/template.nextflow.config b/template.nextflow.config index 3dde1e1..886aa6b 100644 --- a/template.nextflow.config +++ b/template.nextflow.config @@ -75,12 +75,6 @@ params { // PATH to TransPi DBs installation pipeInstall - // PATH to conda installation from precheck. Leave blank is precheck was not used or you will use containers - myCondaInstall="" - - //busco4 conda env - cenv="" - // Uniprot database PATH uniprot uniname From 8cb9fdaecc9efab17f25d6623052654420fba56d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ram=C3=B3n=20Rivera-Vic=C3=A9ns?= Date: Wed, 15 Sep 2021 10:32:06 +0200 Subject: [PATCH 02/12] Remove conda function and variables for busco4 --- precheck_TransPi.sh | 38 ++++++++++++-------------------------- 1 file changed, 12 insertions(+), 26 deletions(-) diff --git a/precheck_TransPi.sh b/precheck_TransPi.sh index 50b6cc9..8bfedbd 100755 --- a/precheck_TransPi.sh +++ b/precheck_TransPi.sh @@ -15,6 +15,12 @@ source_c() { source ~/.bashrc fi } +cleanConda () { + cd $mypwd + echo -e "\n\t -- Cleaning conda environment -- \n" + conda clean -a -y + echo -e "\n\t -- Done cleaning conda environment -- \n" +} conda_only() { source_c #Check conda and environment @@ -24,7 +30,8 @@ conda_only() { ver=$( conda -V | awk '{print $2}' | cut -f 1,2 -d "." ) vern=4.8 if [ $( echo "$ver >= $vern" | bc -l ) -eq 1 ];then - echo -e "\n\t -- Conda is installed (v4.8 or higher). Checking environment... --\n" + echo -e "\n\t -- Conda is installed (v4.8 or higher) --\n" + cleanConda fi else echo -e "\n\t -- Conda is not intalled --\n" @@ -602,24 +609,6 @@ pfam_c() { fi fi } -#temporary for buscoV4 -bus_env4 () { - echo -e "\n\t -- Creating BUSCO V4 environment --\n" - conda create -n busco4 -c conda-forge -c bioconda busco=4.1.4=py_0 -y - conda clean -a -y -} -bus4 () { - cd $mypwd - cpath=$( conda info --json | sed -n '/\"envs\":/,/\],/p' | grep "busco4" | tr -d "," | tr -d " " | tr -d "\"" ) - if [ "$cpath" == "" ];then - echo -e "\n\t -- Cannot find the BUSCO V4 environment -- \n" - echo -e "\n\t -- Cleaning conda before installing BUSCO V4 environment -- \n" - conda clean -a -y - bus_env4 - else - echo -e "\n\t -- BUSCO V4 environment found --\n" - fi -} pfam_u() { cd $installDir if [ ! -d DBs/hmmerdb/ ];then @@ -787,8 +776,8 @@ get_var () { echo "unpdate=\"$( if [ -f ${mypwd}/DBs/uniprot_db/.lastrun.txt ];then cat ${mypwd}/DBs/uniprot_db/.lastrun.txt;else echo "N/A";fi )\"" >>${mypwd}/.varfile.sh echo "pfdate=\"$( if [ -f ${mypwd}/DBs/hmmerdb/.lastrun.txt ];then cat ${mypwd}/DBs/hmmerdb/.lastrun.txt;else echo "N/A";fi )\"" >>${mypwd}/.varfile.sh echo "dbdate=\"$( if [ -f ${mypwd}/DBs/sqlite_db/.lastrun.txt ];then cat ${mypwd}/DBs/sqlite_db/.lastrun.txt;else echo "N/A";fi )\"" >>${mypwd}/.varfile.sh - echo "tenv=$( conda info --json | sed -n '/\"envs\":/,/\],/p' | grep -w "TransPi\"" | tr -d "," | tr -d " " )" >>${mypwd}/.varfile.sh - echo "cenv=$( conda info --json | sed -n '/\"envs\":/,/\],/p' | grep "busco4" | tr -d "," | tr -d " " )" >>${mypwd}/.varfile.sh + #echo "tenv=$( conda info --json | sed -n '/\"envs\":/,/\],/p' | grep -w "TransPi\"" | tr -d "," | tr -d " " )" >>${mypwd}/.varfile.sh + #echo "cenv=$( conda info --json | sed -n '/\"envs\":/,/\],/p' | grep "busco4" | tr -d "," | tr -d " " )" >>${mypwd}/.varfile.sh vpwd=$mypwd echo "mypwd=$mypwd" >>${vpwd}/.varfile.sh source .varfile.sh @@ -802,8 +791,7 @@ get_var () { echo -e "\t SQL DB last update: \t $dbdate" echo -e "\t NEXTFLOW:\t\t $nextflow \n\n" cat ${confDir}/template.nextflow.config | sed -e "s|pipeInstall|pipeInstall=\"${mypwd}\"|" -e "s|busco4db|busco4db=\"${busco4db}\"|" -e "s|uniprot|uniprot=\"${uniprot}\"|" \ - -e "s|uniname|uniname=\"${uniname}\"|" -e "s|pfloc|pfloc=\"${pfloc}\"|" -e "s|pfname|pfname=\"${pfname}\"|" -e "s|Tsql|Tsql=\"${Tsql}\"|" \ - -e "s|myCondaInstall=\"\"|myCondaInstall=\"${tenv}\"|" -e "s|cenv=\"\"|cenv=\"${cenv}\"|" >nextflow.config + -e "s|uniname|uniname=\"${uniname}\"|" -e "s|pfloc|pfloc=\"${pfloc}\"|" -e "s|pfname|pfname=\"${pfname}\"|" -e "s|Tsql|Tsql=\"${Tsql}\"|" >nextflow.config rm .varfile.sh } get_var_user() { @@ -826,8 +814,7 @@ get_var_user() { echo -e "\t PFAM files:\t\t $pfloc" echo -e "\t NEXTFLOW:\t\t $nextflow \n\n" cat ${confDir}/template.nextflow.config | sed -e "s|pipeInstall|pipeInstall=\"${mypwd}\"|" -e "s|busco4db|busco4db=\"${busco4db}\"|" -e "s|uniprot|uniprot=\"${uniprot}\"|" \ - -e "s|uniname|uniname=\"${uniname}\"|" -e "s|pfloc|pfloc=\"${pfloc}\"|" -e "s|pfname|pfname=\"${pfname}\"|" -e "s|Tsql|Tsql=\"${Tsql}\"|" \ - -e "s|myCondaInstall=\"\"|myCondaInstall=\"${tenv}\"|" -e "s|cenv=\"\"|cenv=\"${cenv}\"|" >nextflow.config + -e "s|uniname|uniname=\"${uniname}\"|" -e "s|pfloc|pfloc=\"${pfloc}\"|" -e "s|pfname|pfname=\"${pfname}\"|" -e "s|Tsql|Tsql=\"${Tsql}\"|" >nextflow.config rm .varfile.sh } container_pipeline_setup() { @@ -869,7 +856,6 @@ conda_pipeline_setup() { buildsql_c trisql_c pfam_c - bus4 echo -e "\n\t -- If no \"ERROR\" was found and all the neccesary databases are installed proceed to run TransPi -- \n" get_var fi From e1a82e51abd84ab20b42a25960187622df40c332 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ram=C3=B3n=20Rivera-Vic=C3=A9ns?= Date: Wed, 15 Sep 2021 10:49:23 +0200 Subject: [PATCH 03/12] Add trinotate env. Move funtions. --- precheck_TransPi.sh | 29 +++++++++++++++++++---------- 1 file changed, 19 insertions(+), 10 deletions(-) diff --git a/precheck_TransPi.sh b/precheck_TransPi.sh index 8bfedbd..3db93b3 100755 --- a/precheck_TransPi.sh +++ b/precheck_TransPi.sh @@ -524,6 +524,23 @@ evi_c () { echo -e "\n\t -- EvidentialGene is already installed and in the PATH -- \n" fi } +buildsql_c () { + cd ${mypwd} + if [ -d DBs/sqlite_db/ ];then + cd DBs/sqlite_db/ + else + mkdir -p DBs/sqlite_db/ + cd DBs/sqlite_db/ + fi +} +condaTrinotate () { + echo -e "\n\t -- Creating Trinotate conda environment -- \n" + conda create --mkdir --yes --quiet -n TPtrinotate -c conda-forge bioconda::trinotate=3.2.1=pl526_0 + echo -e "\n\t -- Done with Trinotate conda environment -- \n" +} +condaTrinotateEnd () { + conda remove -n TPtrinotate --all -y +} trisql_container () { if [ ! -e *.sqlite ];then echo -e "\n\n\t -- Custom sqlite database for Trinotate is not installed -- \n" @@ -554,7 +571,7 @@ trisql_c () { condaRoot=$( conda info --json | grep "CONDA_ROOT" | cut -f 2 -d ":" | tr -d "," | tr -d " " | tr -d "\"" ) if [ -f ${condaRoot}/etc/profile.d/conda.sh ];then source ${condaRoot}/etc/profile.d/conda.sh - conda activate TransPi + condaTrinotate check_sql=$( command -v Build_Trinotate_Boilerplate_SQLite_db.pl | wc -l ) if [ $check_sql -eq 0 ];then echo -e "\n\t -- Script \"Build_Trinotate_Boilerplate_SQLite_db.pl\" from Trinotate cannot be found -- \n" @@ -564,6 +581,7 @@ trisql_c () { Build_Trinotate_Boilerplate_SQLite_db.pl Trinotate rm uniprot_sprot.dat.gz Pfam-A.hmm.gz date -u >.lastrun.txt + condaTrinotateEnd fi fi elif [ -e *.sqlite ];then @@ -572,15 +590,6 @@ trisql_c () { echo -e "\n\t -- Databases (PFAM,SwissProt,EggNOG,GO) last update: ${DB} --\n " fi } -buildsql_c () { - cd ${mypwd} - if [ -d DBs/sqlite_db/ ];then - cd DBs/sqlite_db/ - else - mkdir -p DBs/sqlite_db/ - cd DBs/sqlite_db/ - fi -} pfam_c() { #Check PFAM files cd $mypwd From 5aa5e81e7afbc1e80dcea19dba4cb32bba424cfe Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ram=C3=B3n=20Rivera-Vic=C3=A9ns?= Date: Wed, 15 Sep 2021 10:59:18 +0200 Subject: [PATCH 04/12] Add note and missing parameter --- template.nextflow.config | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/template.nextflow.config b/template.nextflow.config index 886aa6b..99d37e1 100644 --- a/template.nextflow.config +++ b/template.nextflow.config @@ -182,7 +182,10 @@ params { // These options will change how the profiles work. // Run with conda installed by the precheck - myConda = false + //next 2 parameters are outdated + myConda = false + myCondaInstall="" + condaActivate = false // TransPi container with all programs @@ -255,9 +258,6 @@ process { // env Evidential Gene variable (only for nextflow) env.evi="${projectDir}/scripts/evigene" -// Temp BUSCO V4 container for oneContainer option. -params.v4container="ezlabgva/busco:v4.0.5_cv1" - // Get PATH for cache environments params.localCacheDir = (params.envCacheDir ? "${params.envCacheDir}" : "${launchDir}") From 81f91dc66f5f131294a1c582fefaf5138ffcc2e9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ram=C3=B3n=20Rivera-Vic=C3=A9ns?= Date: Wed, 15 Sep 2021 10:59:38 +0200 Subject: [PATCH 05/12] Comment cleanConda func fro test --- precheck_TransPi.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/precheck_TransPi.sh b/precheck_TransPi.sh index 3db93b3..4bc0892 100755 --- a/precheck_TransPi.sh +++ b/precheck_TransPi.sh @@ -31,7 +31,7 @@ conda_only() { vern=4.8 if [ $( echo "$ver >= $vern" | bc -l ) -eq 1 ];then echo -e "\n\t -- Conda is installed (v4.8 or higher) --\n" - cleanConda + #cleanConda fi else echo -e "\n\t -- Conda is not intalled --\n" From 2e94dab05f8376385ddaac545504da066fcd5248 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ram=C3=B3n=20Rivera-Vic=C3=A9ns?= Date: Wed, 15 Sep 2021 11:15:33 +0200 Subject: [PATCH 06/12] Update README --- README.md | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index 217d8ea..fb6b2d1 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,4 @@ -# TransPi - TRanscriptome ANalysiS PIpeline +M# TransPi - TRanscriptome ANalysiS PIpeline ```text _______ _____ _ @@ -44,9 +44,12 @@ TransPi documentation and examples can be found [here](https://palmuc.github.io/ Preprint of TransPi including kmer, reads length, and reads quantities tests can be found [here](https://doi.org/10.1101/2021.02.18.431773). Also we tested the pipeline with over 45 samples from different phyla. -## Cite +TransPi has been peer-reviewed and recommended by Peer Community In Genomics +(https://doi.org/10.24072/pci.genomics.100009) -If you use TransPi please cite the preprint: +## Citation + +If you use TransPi please cite the peer-reviewed publication: Rivera-Vicéns, R.E., García-Escudero, CA., Conci, N., Eitel, M., and Wörheide, G. (2021). TransPi – a comprehensive TRanscriptome ANalysiS PIpeline for de novo transcriptome assembly. bioRxiv 2021.02.18.431773; doi: https://doi.org/10.1101/2021.02.18.431773 From 9e7a3ee400b36ab159c21328643b213de28719d2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ram=C3=B3n=20Rivera-Vic=C3=A9ns?= Date: Wed, 15 Sep 2021 11:17:15 +0200 Subject: [PATCH 07/12] Fix name --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index fb6b2d1..184f65e 100644 --- a/README.md +++ b/README.md @@ -18,7 +18,7 @@ M# TransPi - TRanscriptome ANalysiS PIpeline * [Pipeline processes](#Pipelie-processes) * [Manual](#Manual) * [Publication](#Publication) - * [Cite](#Cite) + * [Citation](#Citation) * [Funding](#Funding) * [Future work](#Future-work) * [Issues](#Issues) From c044322bf0b3c06b07e05d431080fc9bbf31cd40 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ram=C3=B3n=20Rivera-Vic=C3=A9ns?= Date: Wed, 15 Sep 2021 11:36:54 +0200 Subject: [PATCH 08/12] Fix busco4 env --- TransPi.nf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/TransPi.nf b/TransPi.nf index 066e81e..b38dc3c 100644 --- a/TransPi.nf +++ b/TransPi.nf @@ -1300,7 +1300,7 @@ if (params.onlyAsm || params.onlyAnn || params.onlyEvi || params.all) { publishDir "${workDir}/.versions", mode: "copy", overwrite: true, pattern: "*.version.txt" // change container in oneContainer option - conda (params.condaActivate && params.myConda ? params.cenv : params.condaActivate ? "-c conda-forge bioconda::busco==4.1.4--py_2" : null) + conda (params.condaActivate && params.myConda ? params.cenv : params.condaActivate ? "-c conda-forge bioconda::busco=4.1.4=py_2" : null) if (params.oneContainer){ container "${params.v4container}" } else { container (workflow.containerEngine == 'singularity' && !params.singularity_pull_docker_container ? "https://depot.galaxyproject.org/singularity/busco:4.1.4--py_2" : "quay.io/biocontainers/busco:4.1.4--py_2") } From 452b1f4ac68f8590d9ab7b56b63b75a9a04ce844 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ram=C3=B3n=20Rivera-Vic=C3=A9ns?= Date: Thu, 16 Sep 2021 10:28:50 +0200 Subject: [PATCH 09/12] Add missing tuple. WIP --- TransPi.nf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/TransPi.nf b/TransPi.nf index b38dc3c..a953862 100644 --- a/TransPi.nf +++ b/TransPi.nf @@ -2873,7 +2873,7 @@ if (params.onlyAsm || params.onlyAnn || params.onlyEvi || params.all) { publishDir "${workDir}/.versions", mode: "copy", overwrite: true, pattern: "*.version.txt" input: - file(assembly), file(annotation) from + tuple file(assembly), file(annotation) from output: file("*.fasta") into From 2580e18177a46545c7b1f6a2dc371fbbc2a69678 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ram=C3=B3n=20Rivera-Vic=C3=A9ns?= Date: Mon, 25 Oct 2021 14:25:56 -0400 Subject: [PATCH 10/12] Change default value (MacManes 2014) --- template.nextflow.config | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/template.nextflow.config b/template.nextflow.config index 99d37e1..3f2b68b 100644 --- a/template.nextflow.config +++ b/template.nextflow.config @@ -116,7 +116,7 @@ params { // Skip fastp quality filter step skipFilter = false // Minimum reads quality for filtering in fastp - minQual="25" + minQual="5" // Filter rRNA rRNAfilter = false @@ -185,7 +185,7 @@ params { //next 2 parameters are outdated myConda = false myCondaInstall="" - + condaActivate = false // TransPi container with all programs From 90de76f9ef173108c925cbfa0c4bec2351832f3b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ram=C3=B3n=20Rivera-Vic=C3=A9ns?= Date: Wed, 27 Oct 2021 07:57:15 -0400 Subject: [PATCH 11/12] Fix #28 --- precheck_TransPi.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/precheck_TransPi.sh b/precheck_TransPi.sh index 4bc0892..bffdc76 100755 --- a/precheck_TransPi.sh +++ b/precheck_TransPi.sh @@ -27,8 +27,8 @@ conda_only() { check_conda=$( command -v conda ) if [ "$check_conda" != "" ];then #&& [ "$ver" -gt "45" ];then echo -e "\n\t -- Conda seems to be installed in your system --\n" - ver=$( conda -V | awk '{print $2}' | cut -f 1,2 -d "." ) - vern=4.8 + ver=$( conda -V | awk '{print $2}' | cut -f 1,2 -d "." | tr -d "." ) + vern=48 if [ $( echo "$ver >= $vern" | bc -l ) -eq 1 ];then echo -e "\n\t -- Conda is installed (v4.8 or higher) --\n" #cleanConda From 386209ea043ece14a8099fd040983ff7b5acf80b Mon Sep 17 00:00:00 2001 From: Ramon Rivera Date: Wed, 27 Oct 2021 10:49:28 -0400 Subject: [PATCH 12/12] Update README.md --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 184f65e..35ba547 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,4 @@ -M# TransPi - TRanscriptome ANalysiS PIpeline +# TransPi - TRanscriptome ANalysiS PIpeline ```text _______ _____ _