Mercurial > repos > peterjc > tmhmm_and_signalp
changeset 3:f3b373a41f81
Migrated tool version 0.0.6 from old tool shed archive to new tool shed repository
author | peterjc |
---|---|
date | Tue, 07 Jun 2011 18:05:13 -0400 |
parents | 6901298ac16c |
children | 81caef04ce8b |
files | tools/protein_analysis/README tools/protein_analysis/seq_analysis_utils.py tools/protein_analysis/signalp3.xml tools/protein_analysis/suite_config.xml tools/protein_analysis/tmhmm2.xml |
diffstat | 5 files changed, 20 insertions(+), 12 deletions(-) [+] |
line wrap: on
line diff
--- a/tools/protein_analysis/README Tue Jun 07 18:04:39 2011 -0400 +++ b/tools/protein_analysis/README Tue Jun 07 18:05:13 2011 -0400 @@ -72,11 +72,15 @@ - Additional unit tests v0.0.4 - Ignore comment lines in tmhmm2 output. v0.0.5 - Explicitly request tmhmm short output (may not be the default) +v0.0.6 - Improvement to how sub-jobs are run (should be faster) Developers ========== -These wrappers are currently being developed on the following hg branch: +This script and other tools are being developed on the following hg branch: +http://bitbucket.org/peterjc/galaxy-central/src/tools + +This incorporates the previously used hg branch: http://bitbucket.org/peterjc/galaxy-central/src/seq_analysis For making the "Galaxy Tool Shed" http://community.g2.bx.psu.edu/ tarball use
--- a/tools/protein_analysis/seq_analysis_utils.py Tue Jun 07 18:04:39 2011 -0400 +++ b/tools/protein_analysis/seq_analysis_utils.py Tue Jun 07 18:05:13 2011 -0400 @@ -102,28 +102,32 @@ raise err return files -def run_jobs(jobs, threads): +def run_jobs(jobs, threads, verbose=False): """Takes list of cmd strings, returns dict with error levels.""" pending = jobs[:] running = [] results = {} while pending or running: - #print "%i jobs pending, %i running, %i completed" \ - # % (len(jobs), len(running), len(results)) #See if any have finished for (cmd, process) in running: - return_code = process.wait() + return_code = process.poll() #non-blocking if return_code is not None: results[cmd] = return_code running = [(cmd, process) for (cmd, process) in running \ if cmd not in results] + if verbose: + print "%i jobs pending, %i running, %i completed" \ + % (len(pending), len(running), len(results)) #See if we can start any new threads while pending and len(running) < threads: cmd = pending.pop(0) + if verbose: + print cmd process = subprocess.Popen(cmd, shell=True) running.append((cmd, process)) #Loop... - sleep(1) - #print "%i jobs completed" % len(results) + sleep(10) + if verbose: + print "%i jobs completed" % len(results) assert set(jobs) == set(results) return results
--- a/tools/protein_analysis/signalp3.xml Tue Jun 07 18:04:39 2011 -0400 +++ b/tools/protein_analysis/signalp3.xml Tue Jun 07 18:05:13 2011 -0400 @@ -1,4 +1,4 @@ -<tool id="signalp3" name="SignalP 3.0" version="0.0.3"> +<tool id="signalp3" name="SignalP 3.0" version="0.0.6"> <description>Find signal peptides in protein sequences</description> <command interpreter="python"> signalp3.py $organism $truncate 8 $fasta_file $tabular_file
--- a/tools/protein_analysis/suite_config.xml Tue Jun 07 18:04:39 2011 -0400 +++ b/tools/protein_analysis/suite_config.xml Tue Jun 07 18:05:13 2011 -0400 @@ -1,9 +1,9 @@ - <suite id="tmhmm_and_signalp" name="TMHMM and SignalP" version="0.0.5"> + <suite id="tmhmm_and_signalp" name="TMHMM and SignalP" version="0.0.6"> <description>Wrappers for TMHMM and SignalP</description> - <tool id="tmhmm2" name="TMHMM 2.0" version="0.0.5"> + <tool id="tmhmm2" name="TMHMM 2.0" version="0.0.6"> <description>Find transmembrane domains in protein sequences</description> </tool> - <tool id="signalp3" name="SignalP 3.0" version="0.0.3"> + <tool id="signalp3" name="SignalP 3.0" version="0.0.6"> <description>Find signal peptides in protein sequences</description> </tool> </suite>
--- a/tools/protein_analysis/tmhmm2.xml Tue Jun 07 18:04:39 2011 -0400 +++ b/tools/protein_analysis/tmhmm2.xml Tue Jun 07 18:05:13 2011 -0400 @@ -1,4 +1,4 @@ -<tool id="tmhmm2" name="TMHMM 2.0" version="0.0.5"> +<tool id="tmhmm2" name="TMHMM 2.0" version="0.0.6"> <description>Find transmembrane domains in protein sequences</description> <command interpreter="python"> tmhmm2.py 8 $fasta_file $tabular_file