On 11/10/2012 12:05, Bas Jansen wrote:
Dear Alan,

Hello

PeptMoiety expects two files passed to it (when running it on the
command line), I would like to try the file option but will need the way
to go around this issue with input being a list of files so if you would
be willing to share that, that would be greatly appreciated.

Here is one possibility:

There is the option to pass a list of data. Each item in the list is written into a temporary file and then another "index" file is created that contains the paths to the temporary file. So, if you can pass the contents of those files rather than the paths to them, then you can use this mechanism.

I'm attaching a very simple example. The file list is available under the Advanced tab of the tool service.

[snip]

Bas

Alan


<workflow xmlns="http://taverna.sf.net/2008/xml/t2flow"; version="1" 
producedBy="taverna-2.4.0"><dataflow id="6c71b9b7-8607-4170-8e40-e38580024964" 
role="top"><name>Simple_data_list_exa</name><inputPorts><port><name>Tool_in1</name><depth>1</depth><granularDepth>1</granularDepth><annotations
 /></port></inputPorts><outputPorts><port><name>Tool_STDOUT</name><annotations 
/></port></outputPorts><processors><processor><name>Tool</name><inputPorts><port><name>in1</name><depth>1</depth></port></inputPorts><outputPorts><port><name>STDOUT</name><depth>0</depth><granularDepth>0</granularDepth></port></outputPorts><annotations
 
/><activities><activity><raven><group>net.sf.taverna.t2.activities</group><artifact>external-tool-activity</artifact><version>1.4</version></raven><class>net.sf.taverna.t2.activities.externaltool.ExternalToolActivity</class><inputMap><map
 from="in1" to="in1" /></inputMap><outputMap><map from="STDOUT" to="STDOUT" 
/></outputMap><configBean 
encoding="xstream"><net.sf.taverna.t2.activities.externaltool.ExternalToolActivityConfigurationBean
 xmlns="">
  <mechanismType>789663B8-DA91-428A-9F7D-B3F3DA185FD4</mechanismType>
  <mechanismName>default local</mechanismName>
  <mechanismXML>&lt;?xml version="1.0" encoding="UTF-8"?&gt;&#xD;
&lt;localInvocation&gt;&lt;shellPrefix&gt;/bin/sh 
-c&lt;/shellPrefix&gt;&lt;linkCommand&gt;/bin/ln -s %%PATH_TO_ORIGINAL%% 
%%TARGET_NAME%%&lt;/linkCommand&gt;&lt;/localInvocation&gt;&#xD;
</mechanismXML>
  <externaltoolid>f0e740ae-e60b-421b-9cab-287988d1dbca</externaltoolid>
  <useCaseDescription>
    <usecaseid />
    <description />
    <command>cat in1</command>
    <preparingTimeoutInSeconds>1200</preparingTimeoutInSeconds>
    <executionTimeoutInSeconds>1800</executionTimeoutInSeconds>
    <tags />
    <REs />
    <queue__preferred />
    <queue__deny />
    <static__inputs />
    <inputs>
      <entry>
        <string>in1</string>
        <de.uni__luebeck.inb.knowarc.usecases.ScriptInputUser>
          <tag>in1</tag>
          <file>true</file>
          <tempFile>false</tempFile>
          <binary>false</binary>
          <charsetName>MacRoman</charsetName>
          <forceCopy>false</forceCopy>
          <list>true</list>
          <concatenate>false</concatenate>
          <mime />
        </de.uni__luebeck.inb.knowarc.usecases.ScriptInputUser>
      </entry>
    </inputs>
    <outputs />
    <includeStdIn>false</includeStdIn>
    <includeStdOut>true</includeStdOut>
    <includeStdErr>true</includeStdErr>
    <validReturnCodes>
      <int>0</int>
    </validReturnCodes>
  </useCaseDescription>
  <edited>false</edited>
</net.sf.taverna.t2.activities.externaltool.ExternalToolActivityConfigurationBean></configBean><annotations
 
/></activity></activities><dispatchStack><dispatchLayer><raven><group>net.sf.taverna.t2.core</group><artifact>workflowmodel-impl</artifact><version>1.4</version></raven><class>net.sf.taverna.t2.workflowmodel.processor.dispatch.layers.Parallelize</class><configBean
 
encoding="xstream"><net.sf.taverna.t2.workflowmodel.processor.dispatch.layers.ParallelizeConfig
 xmlns="">
  <maxJobs>1</maxJobs>
</net.sf.taverna.t2.workflowmodel.processor.dispatch.layers.ParallelizeConfig></configBean></dispatchLayer><dispatchLayer><raven><group>net.sf.taverna.t2.core</group><artifact>workflowmodel-impl</artifact><version>1.4</version></raven><class>net.sf.taverna.t2.workflowmodel.processor.dispatch.layers.ErrorBounce</class><configBean
 encoding="xstream"><null xmlns="" 
/></configBean></dispatchLayer><dispatchLayer><raven><group>net.sf.taverna.t2.core</group><artifact>workflowmodel-impl</artifact><version>1.4</version></raven><class>net.sf.taverna.t2.workflowmodel.processor.dispatch.layers.Failover</class><configBean
 encoding="xstream"><null xmlns="" 
/></configBean></dispatchLayer><dispatchLayer><raven><group>net.sf.taverna.t2.core</group><artifact>workflowmodel-impl</artifact><version>1.4</version></raven><class>net.sf.taverna.t2.workflowmodel.processor.dispatch.layers.Retry</class><configBean
 
encoding="xstream"><net.sf.taverna.t2.workflowmodel.processor.dispatch.layers.RetryConfig
 xmlns="">
  <backoffFactor>1.0</backoffFactor>
  <initialDelay>1000</initialDelay>
  <maxDelay>5000</maxDelay>
  <maxRetries>0</maxRetries>
</net.sf.taverna.t2.workflowmodel.processor.dispatch.layers.RetryConfig></configBean></dispatchLayer><dispatchLayer><raven><group>net.sf.taverna.t2.core</group><artifact>workflowmodel-impl</artifact><version>1.4</version></raven><class>net.sf.taverna.t2.workflowmodel.processor.dispatch.layers.Invoke</class><configBean
 encoding="xstream"><null xmlns="" 
/></configBean></dispatchLayer></dispatchStack><iterationStrategyStack><iteration><strategy><cross><port
 name="in1" depth="1" 
/></cross></strategy></iteration></iterationStrategyStack></processor></processors><conditions
 /><datalinks><datalink><sink 
type="processor"><processor>Tool</processor><port>in1</port></sink><source 
type="dataflow"><port>Tool_in1</port></source></datalink><datalink><sink 
type="dataflow"><port>Tool_STDOUT</port></sink><source 
type="processor"><processor>Tool</processor><port>STDOUT</port></source></datalink></datalinks><annotations><annotation_chain
 encoding="xstream"><net.sf.taverna.t2.annotation.AnnotationChainImpl xmlns="">
  <annotationAssertions>
    <net.sf.taverna.t2.annotation.AnnotationAssertionImpl>
      <annotationBean 
class="net.sf.taverna.t2.annotation.annotationbeans.FreeTextDescription">
        <text>This example workflow shows how a list of data items can be 
written to temporary files and an index file created.</text>
      </annotationBean>
      <date>2012-10-11 11:48:09.862 UTC</date>
      <creators />
      <curationEventList />
    </net.sf.taverna.t2.annotation.AnnotationAssertionImpl>
  </annotationAssertions>
</net.sf.taverna.t2.annotation.AnnotationChainImpl></annotation_chain><annotation_chain_2_2
 encoding="xstream"><net.sf.taverna.t2.annotation.AnnotationChainImpl xmlns="">
  <annotationAssertions>
    <net.sf.taverna.t2.annotation.AnnotationAssertionImpl>
      <annotationBean 
class="net.sf.taverna.t2.annotation.annotationbeans.IdentificationAssertion">
        <identification>f41b5e1c-218a-4773-ab84-6f2e5d948cde</identification>
      </annotationBean>
      <date>2012-10-11 11:41:28.922 UTC</date>
      <creators />
      <curationEventList />
    </net.sf.taverna.t2.annotation.AnnotationAssertionImpl>
  </annotationAssertions>
</net.sf.taverna.t2.annotation.AnnotationChainImpl></annotation_chain_2_2><annotation_chain_2_2
 encoding="xstream"><net.sf.taverna.t2.annotation.AnnotationChainImpl xmlns="">
  <annotationAssertions>
    <net.sf.taverna.t2.annotation.AnnotationAssertionImpl>
      <annotationBean 
class="net.sf.taverna.t2.annotation.annotationbeans.IdentificationAssertion">
        <identification>6c71b9b7-8607-4170-8e40-e38580024964</identification>
      </annotationBean>
      <date>2012-10-11 11:48:18.656 UTC</date>
      <creators />
      <curationEventList />
    </net.sf.taverna.t2.annotation.AnnotationAssertionImpl>
  </annotationAssertions>
</net.sf.taverna.t2.annotation.AnnotationChainImpl></annotation_chain_2_2><annotation_chain
 encoding="xstream"><net.sf.taverna.t2.annotation.AnnotationChainImpl xmlns="">
  <annotationAssertions>
    <net.sf.taverna.t2.annotation.AnnotationAssertionImpl>
      <annotationBean 
class="net.sf.taverna.t2.annotation.annotationbeans.Author">
        <text>Alan R Williams</text>
      </annotationBean>
      <date>2012-10-11 11:47:06.838 UTC</date>
      <creators />
      <curationEventList />
    </net.sf.taverna.t2.annotation.AnnotationAssertionImpl>
  </annotationAssertions>
</net.sf.taverna.t2.annotation.AnnotationChainImpl></annotation_chain><annotation_chain
 encoding="xstream"><net.sf.taverna.t2.annotation.AnnotationChainImpl xmlns="">
  <annotationAssertions>
    <net.sf.taverna.t2.annotation.AnnotationAssertionImpl>
      <annotationBean 
class="net.sf.taverna.t2.annotation.annotationbeans.DescriptiveTitle">
        <text>Simple data list example</text>
      </annotationBean>
      <date>2012-10-11 11:47:14.438 UTC</date>
      <creators />
      <curationEventList />
    </net.sf.taverna.t2.annotation.AnnotationAssertionImpl>
  </annotationAssertions>
</net.sf.taverna.t2.annotation.AnnotationChainImpl></annotation_chain></annotations></dataflow></workflow>
------------------------------------------------------------------------------
Don't let slow site performance ruin your business. Deploy New Relic APM
Deploy New Relic app performance management and know exactly
what is happening inside your Ruby, Python, PHP, Java, and .NET app
Try New Relic at no cost today and get our sweet Data Nerd shirt too!
http://p.sf.net/sfu/newrelic-dev2dev
_______________________________________________
taverna-users mailing list
[email protected]
[email protected]
Web site: http://www.taverna.org.uk
Mailing lists: http://www.taverna.org.uk/about/contact-us/

Reply via email to