CWL :Append the ref input used in toolkit
1
0
Entering edit mode
5.5 years ago
lizhichao ▴ 80

I want the input ref used in analysis toolkit, and the toolkit input the ref in config format,not in command-line format.Then,How can I deal with it,when I use CWL . Thank you!

cwl • 2.1k views
ADD COMMENT
1
Entering edit mode

Hi lizhichao

Your question is too vague and badly written. For people here to help you, you need to explain what you are asking in a well structured way

Please read these post and re-frame the question

How To Ask Good Questions On Technical And Scientific Forums

Brief Reminder On How To Ask A Good Question

ADD REPLY
0
Entering edit mode

And I want to know. when cwl running in a docker ,where is the running dir and the input files dir copied to the same dir?

ADD REPLY
1
Entering edit mode

The answer regarding InitialWorkDirRequirement has already been given. But for anybody reading this in the future: The directory in which a CommandLineTool runs will only be determined after starting the job. You can, however, reference the directory in your cwl documents using $(runtime.outdir).

If you do not use InitialWorkDirRequirement, input files will never be copied. Links to the input files are created instead.

ADD REPLY
0
Entering edit mode

My software need the ref directory name,and I need assign the directory name by cwl-yaml's ref params.How can I achieve it?

ADD REPLY
0
Entering edit mode

It is really difficult to understand what the issue is. Maybe try giving us a specific example of what you are working on. What software do you want to run? Can you post the current version of your command line tool, even if it doesn't work? What is the file you have trouble passing to the tool?

If you put a little more effort into elaborating, i am sure we will be able to help.

ADD REPLY
0
Entering edit mode

Sorry for my obscure expression. I have made it.

ADD REPLY
2
Entering edit mode
5.5 years ago

Hello lizhichao,

For creating configuration files at runtime, please consult this part of the CWL User Guide: https://www.commonwl.org/user_guide/14-runtime/index.html

ADD COMMENT
1
Entering edit mode

Yes,I have made it. Another quesiton: How can I write inputs to support the one options or more repeats arguments. For example :"-L chr1" and "-L chr1 -L chr2 -L chr3".

ADD REPLY
1
Entering edit mode

try:

type: string[]
inputBinding:
  prefix: -L
ADD REPLY
0
Entering edit mode

Ok。I will try it and i believe it works. take the previous a example.in gatk anlysis module,Haplotypecaller allows :-L target_string ,as well as -L wes.bed(type:file) . How can i deal with it in cwl? type:string?file?

ADD REPLY
0
Entering edit mode

You could define 2 inputs. One for strings, one for files. Both set as optional using ?.

input_A:
  type: string[]?
  inputBinding:
    prefix: -L
input_B:
  type: file?
  inputBinding:
    prefix: -L
ADD REPLY
0
Entering edit mode

emm. so the cwl will verdict the " -L" input format by string or file format?? hahahaha

ADD REPLY
0
Entering edit mode

If you pass input_A to the tool, it's an array of strings. If you pass input_B to the tool, its a file. CWL will not decide by itself.

ADD REPLY
1
Entering edit mode

oh,i think i understand your idea,Tank you ! You means CWL decide the input format by [id] not [prefix]. Is that so?

ADD REPLY
1
Entering edit mode

Yes!

CWL will check which inputs IDs are an the workflow / job and feed them into the tool.

ADD REPLY
0
Entering edit mode
ADD REPLY
0
Entering edit mode

hoping your reply,not vote... Thanks!

ADD REPLY

Login before adding your answer.

Traffic: 2477 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6