Skip to content

Commit

Permalink
Specify executive memory/threads so we can run more things in one mac…
Browse files Browse the repository at this point in the history
…hine and to explicitly get the right resources
  • Loading branch information
skoren committed May 21, 2018
1 parent 9e8cfa4 commit 0dc79d7
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/dx-canu/dxapp.json
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@
"file": "src/canu.sh",
"systemRequirements": {
"*": {
"instanceType": "mem1_ssd1_x2"
"instanceType": "mem2_hdd2_x2"
}
},
"distribution": "Ubuntu",
Expand Down
4 changes: 2 additions & 2 deletions src/dx-canu/src/canu.sh
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ main() {

if [ ! -s ${output_prefix}.contigs.fasta ]; then
# save the command without the inputs
echo "canu objectStore=DNANEXUS objectStoreClient=dx objectStoreNameSpace=$output_path objectStoreProject=$DX_PROJECT_CONTEXT_ID -d . -p ${output_prefix} genomeSize=${genome_size} $parameters" > canu.sh
echo "canu executiveMemory=8 executiveThreads=2 objectStore=DNANEXUS objectStoreClient=dx objectStoreNameSpace=$output_path objectStoreProject=$DX_PROJECT_CONTEXT_ID -d . -p ${output_prefix} genomeSize=${genome_size} $parameters" > canu.sh
# bash is set to quit in the app on any error (including file doesn't exist) so we only run rm on success of describe, otherwise nothing
exists=`dx describe --name $DX_PROJECT_CONTEXT_ID:$output_path/canu.sh || true`
if [[ -e canu.sh && x$exists != x ]] ; then
Expand All @@ -103,6 +103,6 @@ main() {
dx upload --wait --parents --path $DX_PROJECT_CONTEXT_ID:$output_path/canu.sh canu.sh

# run the canu command
canu objectStore=DNANEXUS objectStoreClient=dx objectStoreNameSpace=$output_path objectStoreProject=$DX_PROJECT_CONTEXT_ID -d . -p ${output_prefix} genomeSize=${genome_size} $parameters ${input_type} ${input_files_name[@]}
canu executiveMemory=8 executiveThreads=2 objectStore=DNANEXUS objectStoreClient=dx objectStoreNameSpace=$output_path objectStoreProject=$DX_PROJECT_CONTEXT_ID -d . -p ${output_prefix} genomeSize=${genome_size} $parameters ${input_type} ${input_files_name[@]}
fi
}

0 comments on commit 0dc79d7

Please sign in to comment.