From 54cd804811c7727597ae70a90eaeaddc6711e7a0 Mon Sep 17 00:00:00 2001 From: Yiming Yang Date: Tue, 22 Sep 2020 23:48:06 -0400 Subject: [PATCH 1/2] Allow string type for calc_signature_scores --- workflows/cumulus/cumulus.wdl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/workflows/cumulus/cumulus.wdl b/workflows/cumulus/cumulus.wdl index 074dda8d..79a863bd 100644 --- a/workflows/cumulus/cumulus.wdl +++ b/workflows/cumulus/cumulus.wdl @@ -100,7 +100,7 @@ workflow cumulus { # Random number generator seed. [default: 0] Int? random_state # Calculate signature scores for gene sets in . - File? calc_signature_scores + String? calc_signature_scores # Number of PCs. [default: 50] Int? nPC # Number of neighbors used for constructing affinity matrix. [default: 100] From d34ae03f7dbcd1cd377dabc225377223e9cec524 Mon Sep 17 00:00:00 2001 From: Yiming Yang Date: Wed, 23 Sep 2020 15:40:22 -0400 Subject: [PATCH 2/2] update calc_signature_scores input --- workflows/cumulus/cumulus.wdl | 4 ++-- workflows/cumulus/cumulus_tasks.wdl | 15 ++++++++++++--- 2 files changed, 14 insertions(+), 5 deletions(-) diff --git a/workflows/cumulus/cumulus.wdl b/workflows/cumulus/cumulus.wdl index 79a863bd..11f1371b 100644 --- a/workflows/cumulus/cumulus.wdl +++ b/workflows/cumulus/cumulus.wdl @@ -1,6 +1,6 @@ version 1.0 -import "https://api.firecloud.org/ga4gh/v1/tools/cumulus:cumulus_tasks/versions/22/plain-WDL/descriptor" as tasks +import "https://api.firecloud.org/ga4gh/v1/tools/cumulus:cumulus_tasks/versions/23/plain-WDL/descriptor" as tasks # import "cumulus_tasks.wdl" as tasks workflow cumulus { @@ -302,7 +302,7 @@ workflow cumulus { correction_method = correction_method, batch_group_by = batch_group_by, random_state = random_state, - gene_signature_file = calc_signature_scores, + gene_signature_set = calc_signature_scores, nPC = nPC, knn_K = knn_K, knn_full_speed = knn_full_speed, diff --git a/workflows/cumulus/cumulus_tasks.wdl b/workflows/cumulus/cumulus_tasks.wdl index 47329909..87795156 100644 --- a/workflows/cumulus/cumulus_tasks.wdl +++ b/workflows/cumulus/cumulus_tasks.wdl @@ -108,7 +108,7 @@ task run_cumulus_cluster { String? correction_method String? batch_group_by Int? random_state - File? gene_signature_file + String? gene_signature_set Int? nPC Int? knn_K Boolean? knn_full_speed @@ -151,11 +151,17 @@ task run_cumulus_cluster { String docker_registry } + Boolean is_url = defined(gene_signature_set) && sub(select_first([gene_signature_set]), "^gs://.+", "URL") == "URL" + command { set -e export TMPDIR=/tmp monitor_script.sh > monitoring.log & + if [ ~{is_url} == true ]; then + gsutil -q cp ~{gene_signature_set} gene_signature.gmt + fi + python <