Skip to content

Commit

Permalink
Final modifications for SGE cluster - thanks to Nicolas Rodriguez!
Browse files Browse the repository at this point in the history
  • Loading branch information
wikiselev committed Jun 4, 2015
1 parent d164644 commit 1441321
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 7 deletions.
6 changes: 5 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
## Summary

This script is dedicated to allow one to quickly and efficiently run a Copasi parameter estimation task on a computing cluster. Running 1000 parameter estimations in minutes and automatically summarising the results allows you to test a lot of hypothesis in a single day! Please enjoy and fork/pull request if you can see some obvious improvements!

## Prerequisites

1. [LSF](http://www-03.ibm.com/systems/platformcomputing/products/lsf/) or [SGE](http://www.oracle.com/us/products/tools/oracle-grid-engine-075549.html) cluster
Expand Down Expand Up @@ -37,4 +41,4 @@ where **n** is number of parameter estimations and **c** is your cluster queuing

Authors: [Vladimir Kiselev](www.genat.uk), Marija Jankovic

Acknowledgments: Martina Fröhlich
Acknowledgments: Martina Fröhlich, Nicolas Rodriguez
6 changes: 4 additions & 2 deletions coparaest.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,11 @@ mkdir results out err
if [ $2 = "lsf" ]; then
bsub -J "parameter-estimation[1-$1]" -o out/%I -e err/%I sh scripts/parameter-estimation.sh
bsub -w "ended(parameter-estimation*)" -J "get-obj-values" -o out/get-obj-values -e err/get-obj-values perl scripts/get-obj-values.pl
bsub -w "ended(get-obj-values)" -J "analyse-results" -o out/analyse-results -e err/analyse-results /nfs/users/nfs_v/vk6/R-3.2.0/bin/Rscript scripts/analyse-results.R
bsub -w "ended(get-obj-values)" -J "analyse-results" -o out/analyse-results -e err/analyse-results Rscript scripts/analyse-results.R
fi

if [ $2 = "sge" ]; then
echo "sh scripts/job.sh" | qsub -t 1-$1 -cwd -V -o out/%I -e err/%I
echo "sh scripts/parameter-estimation.sh" | qsub -t 1-$1 -N "parameter_estimation" -cwd -V -o "out/parameter-estimation-${SGE_TASK_ID}" -e "err/parameter-estimation-${SGE_TASK_ID}"
echo "perl scripts/get-obj-values.pl" | qsub -hold_jid "parameter_estimation" -N "get_obj_values" -cwd -V -o out/get-obj-values -e err/get-obj-values
echo "Rscript scripts/analyse-results.R" | qsub -hold_jid "get_obj_values" -N "analyse_results" -cwd -V -o out/analyse-results -e err/analyse-results
fi
14 changes: 10 additions & 4 deletions scripts/parameter-estimation.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
mkdir results/$LSB_JOBINDEX
cp model/* results/$LSB_JOBINDEX
cd results/$LSB_JOBINDEX
JOB_INDEX=${LSB_JOBINDEX}

if [ "x${LSB_JOBINDEX}" == "x" ]; then
JOB_INDEX=${SGE_TASK_ID}
fi

mkdir results/$JOB_INDEX
cp model/* results/$JOB_INDEX
cd results/$JOB_INDEX
file=`ls *.cps`
/nfs/users/nfs_v/vk6/COPASI-4.15.95-Linux-64bit/bin/CopasiSE -s $file $file
CopasiSE -s $file $file

0 comments on commit 1441321

Please sign in to comment.