From d3806a66f002b93f6dc03447b6628f943a3ba90c Mon Sep 17 00:00:00 2001 From: pvtroshin Date: Tue, 8 Feb 2011 17:21:44 +0000 Subject: [PATCH] Further work on GlobPlot git-svn-id: link to svn.lifesci.dundee.ac.uk/svn/barton/ptroshin/JABA2@3718 e3abac25-378b-4346-85de-24260fe3988d --- binaries/src/compilebin.sh | 7 +++- binaries/src/globplot/{GlobPipe.py => GlobPlot.py} | 0 binaries/src/setexecflag.sh | 2 + conf/Executable.properties | 11 +++++- conf/settings/GlobPlotLimits.xml | 13 +++++++ how_to_add_new_webservice.txt | 41 ++++++++++++++++++++ .../compbio/data/sequence/SequenceUtilTester.java | 5 ++- 7 files changed, 75 insertions(+), 4 deletions(-) rename binaries/src/globplot/{GlobPipe.py => GlobPlot.py} (100%) create mode 100644 conf/settings/GlobPlotLimits.xml create mode 100644 how_to_add_new_webservice.txt diff --git a/binaries/src/compilebin.sh b/binaries/src/compilebin.sh index 3cc20b2..8a0ecd2 100644 --- a/binaries/src/compilebin.sh +++ b/binaries/src/compilebin.sh @@ -67,5 +67,10 @@ echo "DONE" chmod +x sav_gol cd .. - +echo "Compiling GlobPlot..." +cd globplot +echo "DONE" +# TODO deal with the links +chmod +x GlobPlot.py +cd .. diff --git a/binaries/src/globplot/GlobPipe.py b/binaries/src/globplot/GlobPlot.py similarity index 100% rename from binaries/src/globplot/GlobPipe.py rename to binaries/src/globplot/GlobPlot.py diff --git a/binaries/src/setexecflag.sh b/binaries/src/setexecflag.sh index d125079..33d1b65 100644 --- a/binaries/src/setexecflag.sh +++ b/binaries/src/setexecflag.sh @@ -22,3 +22,5 @@ chmod +x tcoffee/t_coffee_source/t_coffee echo "Setting executable flag for DisEMBL..." chmod +x disembl/disembl disembl/sav_gol disembl/DisEMBL.py +echo "Setting executable flag for GlobPlot..." +chmod +x globplot/GlobPlot.py diff --git a/conf/Executable.properties b/conf/Executable.properties index 548507c..1562c56 100644 --- a/conf/Executable.properties +++ b/conf/Executable.properties @@ -72,7 +72,7 @@ jronn.cluster.cpunum=4 jronn.cluster.settings=-q 64bit-pri.q -pe smp 4 -l h_vmem=1700M -l ram=1700M -l h_cpu=24:00:00 -### Disembl configuration Tisean - Disembl dependancy cannot be redistributed (!) ### +### Disembl configuration Tisean - Disembl dependancy ### #local.disembl.bin.windows= local.disembl.bin=binaries/src/disembl/DisEMBL.py cluster.disembl.bin=/homes/pvtroshin/workspace/jaba2/binaries/src/disembl/DisEMBL.py @@ -80,6 +80,15 @@ disembl.parameters.file=conf/settings/DisemblParameters.xml disembl.limits.file=conf/settings/DisemblLimits.xml disembl.cluster.settings=-l h_cpu=24:00:00 -l h_vmem=6000M -l ram=6000M +### GlobPlot configuration Tisean - GlobPlot and Disembl dependancy ### +#local.disembl.bin.windows= +local.globplot.bin=binaries/src/globplot/GlobPlot.py +cluster.globplot.bin=/homes/pvtroshin/workspace/jaba2/binaries/src/globplot/GlobPlot.py +globplot.parameters.file=conf/settings/GlobPlotParameters.xml +globplot.limits.file=conf/settings/GlobPlotLimits.xml +globplot.cluster.settings=-l h_cpu=24:00:00 -l h_vmem=6000M -l ram=6000M + + ### AACon configuration ### local.aacon.bin.windows=D:\\Java\\jdk1.6.0_14\\bin\\java.exe local.aacon.bin=/sw/java/latest/bin/java diff --git a/conf/settings/GlobPlotLimits.xml b/conf/settings/GlobPlotLimits.xml new file mode 100644 index 0000000..7621169 --- /dev/null +++ b/conf/settings/GlobPlotLimits.xml @@ -0,0 +1,13 @@ + + + compbio.runner.disorder.GlobPlot + + 5000 + 1000 + + + # LocalEngineExecutionLimit # + 200 + 400 + + diff --git a/how_to_add_new_webservice.txt b/how_to_add_new_webservice.txt new file mode 100644 index 0000000..d795d35 --- /dev/null +++ b/how_to_add_new_webservice.txt @@ -0,0 +1,41 @@ +How To add a new executable + +1) Add executable to the binaries folder. If it has source code and can be recompiled for different platforms include it under binaries/src +Edit binaries/src setexecutableflag.sh and compilebin.sh scripts accordingly. + +2) Make sure all the dependencies of the software being installed are satisfied. If there are other binaries they should be included as well. Keep the dependant binaries in subfolder for the main executable. Update compily and setexecflag scripts accordigly. + +3) Make sure executable + - Does not have any hard links to its dependencies, e.g. is able to run from any installation folder and does not contain any hardcoded paths. (TODO examples...) + +4) Describe executable in conf/Exectuable.properties. + +5) Add Limit.xml, Parameters.xml and Presets.xml. All but Limits are optional. + +6) Create a Java wrapper class for your executable. Create it within runner source directory. + +7) Create a testcase suit for your wrapper and run the test cases. + +8) Create parser for the output files of your executable. Suggested location compbio.data.sequence.SequenceUtil + +9) Test the parser + +10) Decide which interface your executable is going to match. + For example it what the executable produces can be represented as Annotations + to the sequence file or alignment, then SequenceAnnotation interface might be appropriate. + For multiple sequence alignment an Msa interface should be used. + +11) If matching interface is found, then implement a web service confirming to it within + a webservices source folder + +12) Register web service in WEB-INF/ web.xml and sun-jaxws.xml + +13) Modify the client to work with your web service. + +14) Test. + +15) Testing on the cluster... + + + + diff --git a/testsrc/compbio/data/sequence/SequenceUtilTester.java b/testsrc/compbio/data/sequence/SequenceUtilTester.java index 9a8c5a0..7f45855 100644 --- a/testsrc/compbio/data/sequence/SequenceUtilTester.java +++ b/testsrc/compbio/data/sequence/SequenceUtilTester.java @@ -232,11 +232,12 @@ public class SequenceUtilTester { assertEquals(scores.size(), 5); } for (Score score : scores) { - if (score.getMethod() == GlobProtResult.Disorder) { + + if (score.getMethod() == (Enum) GlobProtResult.Disorder) { assertEquals(score.getRanges().size(), 7); assertTrue(score.getScores().isEmpty()); } - if (score.getMethod() == GlobProtResult.Dydx) { + if (score.getMethod() == (Enum)GlobProtResult.Dydx) { assertFalse(score.getScores().isEmpty()); assertTrue(score.getRanges().isEmpty()); } -- 1.7.10.2