jflow_core_workflow.html 36 KB
Newer Older
1
2
<!DOCTYPE html>
<html lang="en">
Jerome Mariette's avatar
Jerome Mariette committed
3
4
5
  <head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1">
6

Jerome Mariette's avatar
Jerome Mariette committed
7
8
9
10
11
12
13
14
15
    <title>Jflow</title>

    <!-- Bootstrap core CSS -->
    <link href="css/bootstrap.min.css" rel="stylesheet">
    <!-- Bootstrap theme -->
    <link href="css/bootstrap-theme.min.css" rel="stylesheet">

    <!-- Custom styles for this template -->
    <link href="css/theme.css" rel="stylesheet">
16

Philippe Bardou's avatar
Philippe Bardou committed
17
18
19
	<!--  Highlight code -->
	<link href="css/tomorrow-night-eighties.css" rel="stylesheet">

Jerome Mariette's avatar
Jerome Mariette committed
20
21
22
23
24
25
    <!-- HTML5 shim and Respond.js IE8 support of HTML5 elements and media queries -->
    <!--[if lt IE 9]>
      <script src="https://oss.maxcdn.com/html5shiv/3.7.2/html5shiv.min.js"></script>
      <script src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js"></script>
    <![endif]-->
  </head>
26

Jerome Mariette's avatar
Jerome Mariette committed
27
28
29
30
31
32
33
34
35
36
37
38
  <body role="document">
  
    <!-- Fixed navbar -->
    <div class="navbar navbar-inverse navbar-fixed-top" role="navigation">
      <div class="container">
        <div class="navbar-header">
          <button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target=".navbar-collapse">
            <span class="sr-only">Toggle navigation</span>
            <span class="icon-bar"></span>
            <span class="icon-bar"></span>
            <span class="icon-bar"></span>
          </button>
39
          <a class="navbar-brand" href="./index">Jflow</a>
Jerome Mariette's avatar
Jerome Mariette committed
40
41
42
        </div>
        <div class="navbar-collapse collapse">
          <ul class="nav navbar-nav">
43
44
45
            <li><a href="./index">About</a></li>
            <li><a href="./jflow_install">Install</a></li>
            <li><a href="./jflow_quickstart">Quick start</a></li>
Philippe Bardou's avatar
Philippe Bardou committed
46
47
            <li class="dropdown active">
              <a href="#" class="dropdown-toggle" data-toggle="dropdown">Documentation<span class="caret"></span></a>
Jerome Mariette's avatar
Jerome Mariette committed
48
              <ul class="dropdown-menu" role="menu">
49
50
51
52
53
54
                <li class="active"><a href="./jflow_core_workflow">Add a workflow</a></li>
                <li><a href="./jflow_core_component">Add a component</a></li>
                <li><a href="./jflow_plugin">Plugin insertion</a></li>
                <li><a href="./jflow_type">Add a data type</a></li>
                <li><a href="./jflow_format">Add a file format</a></li>
                <li><a href="./jflow_advanced_configuration">Advanced configuration</a></li>
Jerome Mariette's avatar
Jerome Mariette committed
55
56
              </ul>
            </li>
57
			<li><a href="./example1">Example</a></li>
Jerome Mariette's avatar
Jerome Mariette committed
58
59
60
61
62
			<li><a href="mailto:support.genopole@toulouse.inra.fr">Contact</a></li>
          </ul>
        </div><!--/.nav-collapse -->
      </div>
    </div>
63

Jerome Mariette's avatar
Jerome Mariette committed
64
    <div class="container">
Philippe Bardou's avatar
Philippe Bardou committed
65
      <div class="row">
Philippe Bardou's avatar
Philippe Bardou committed
66
67
68
        <!--Nav Bar -->
	    <nav class="col-xs-3 bs-docs-sidebar">
	        <ul id="sidebar" class="nav nav-stacked fixed">
Jerome Mariette's avatar
Jerome Mariette committed
69
70
		        <li><a href="#what" class="active">What is a workflow</a></li>
		        <li><a href="#workflow-architecture">Where to add a new workflow</a></li>
71
		        <li><a href="#workflow" >The Workflow class</a></li>
Philippe Bardou's avatar
Philippe Bardou committed
72
73
		       	<li><a href="#define_parameters">Define parameters</a>
			       	<ul class="nav nav-stacked">
74
			       		<li><a href="#parameters">Parameters</a></li>
Jerome Mariette's avatar
Jerome Mariette committed
75
			       		<li><a href="#input_parameters">Inputs</a></li>
Ibouniyamine Nabihoudine's avatar
wf doc    
Ibouniyamine Nabihoudine committed
76
			       		<li><a href="#multiple_parameters">Multiple parameters</a></li>
Ibouniyamine Nabihoudine's avatar
Ibouniyamine Nabihoudine committed
77
			       		<li><a href="#exclusion_rules">Exclusion rules</a></li>
Philippe Bardou's avatar
Philippe Bardou committed
78
79
80
	                </ul>
                </li>
				<li><a href="#process">Process</a></li>
Jerome Mariette's avatar
Jerome Mariette committed
81
82
83
84
				<li><a href="#other_methods">Other methods</a>
				  	<ul class="nav nav-stacked">
				        <li><a href="#pre_process">Pre process</a></li>
						<li><a href="#post_process">Post process</a></li>
Jerome Mariette's avatar
Jerome Mariette committed
85
86
87
						<li><a href="#set_to_address">Set to address</a></li>
						<li><a href="#set_subject">Set subject</a></li>
						<li><a href="#set_message">Set message</a></li>
Jerome Mariette's avatar
Jerome Mariette committed
88
						<li><a href="#get_resource">Get resource</a></li>
Jerome Mariette's avatar
Jerome Mariette committed
89
90
					</ul>
				</li>
Philippe Bardou's avatar
Philippe Bardou committed
91
92
93
	        </ul>
   	    </nav>
   	 
Jerome Mariette's avatar
Jerome Mariette committed
94
        <div class="col-xs-12 col-sm-9">
Jerome Mariette's avatar
Jerome Mariette committed
95
96
97
98
99
100
101
102
        
           	<section id="what" class="group">
		    	<h1 class="page-header">What is a workflow</h1>
	    		<p>A workflow is a collection of <a href="./jflow-core-component.html">components</a>. In jflow, it is represented by a Python class
	    			inerhiting from <code>jflow.workflow.Workflow</code>. It lists all the inputs and parameters that should be requested to 
	    			the final user and build the execution process by adding components and linking them to each others.</p>
	    	</section>
        
Ibouniyamine Nabihoudine's avatar
wf doc    
Ibouniyamine Nabihoudine committed
103
        	<section id="workflow-architecture" class="group">
Philippe Bardou's avatar
Philippe Bardou committed
104
		    	<h1 class="page-header">Where to add a new workflow</h1>
105
106
		    	<p>New wokflow must be added as a new python package in the <code>workflows</code> package. The implementation of
		    	a workflows must be written in the package <code>__init__.py</code> file. The developper can also create: </p>
Ibouniyamine Nabihoudine's avatar
wf doc    
Ibouniyamine Nabihoudine committed
107
		    	<ul>
108
109
110
		    		<li>a <code>components</code> package, where all the workflow specific components can be stored,</li>
		    		<li>a <code>lib</code> package to import specific libraries within its workflow,</li>
		    		<li>a <code>bin</code> folder with the binaries used in the workflow.</li>
Ibouniyamine Nabihoudine's avatar
wf doc    
Ibouniyamine Nabihoudine committed
111
112
		    	</ul>
		    	
Philippe Bardou's avatar
Philippe Bardou committed
113
		    	<pre class="pre-hl "><code class="ini">jflow/
Philippe Bardou's avatar
Philippe Bardou committed
114
115
116
117
├── bin/
├── docs/
├── src/
├── workflows/
Philippe Bardou's avatar
Philippe Bardou committed
118
119
120
121
122
│   ├── myworkflow/       [ the new workflow package ]
│   │   ├── components/   [ specific components ]
│   │   ├── lib/          [ specific libraries ]
│   │   ├── bin/          [ specific binairies ]
│   │   └── __init__.py   [ the workflow implementation ]
Philippe Bardou's avatar
Philippe Bardou committed
123
124
125
126
127
128
129
│   ├── components/
│   ├── extparsers/
│   ├── __init__.py
│   ├── formats.py
│   └── types.py
├── applications.properties
└── README</code></pre>
Ibouniyamine Nabihoudine's avatar
wf doc    
Ibouniyamine Nabihoudine committed
130
131
		    </section>   
     
Philippe Bardou's avatar
Philippe Bardou committed
132
        	<section id="workflow" class="group">
133
134
		    	<h1 class="page-header">The Workflow class</h1>
		    	<p>In jflow, a workflow is a class defined in the <code>__init__.py</code> file. In order to add a new workflow, the developper has to: </p>
Ibouniyamine Nabihoudine's avatar
wf doc    
Ibouniyamine Nabihoudine committed
135
		    	
Philippe Bardou's avatar
Philippe Bardou committed
136
		    	<ul>
Jerome Mariette's avatar
Jerome Mariette committed
137
			    	<li>implement a class inheriting from the <code>jflow.workflow.Workflow</code> class,</li>
Ibouniyamine Nabihoudine's avatar
Ibouniyamine Nabihoudine committed
138
					<li>overload the <code>get_description()</code> method to provide to the final user a description of the workflow,</li>
139
140
141
					<li>overload the <code>define_parameters()</code> method to add the workflow inputs and parameters,</li>
					<li>overload the <code>process()</code> method by adding components and setting their arguments,</li>
					<li>link the components inputs and outputs.</li>
Philippe Bardou's avatar
Philippe Bardou committed
142
				</ul>
143
				<p>The class skeleton is given by</p>
Philippe Bardou's avatar
Philippe Bardou committed
144
			    <div>
Ibouniyamine Nabihoudine's avatar
wf doc    
Ibouniyamine Nabihoudine committed
145
			    	<pre class="pre-hl "><code class="python">from jflow.workflow import Workflow
Jerome Mariette's avatar
Jerome Mariette committed
146

147
class MyWorkflow (Workflow):
Philippe Bardou's avatar
Philippe Bardou committed
148
149

    def get_description(self):
150
        return "a description"
Philippe Bardou's avatar
Philippe Bardou committed
151
152

    def define_parameters(self, function="process"):
153
        # define the parameters
Philippe Bardou's avatar
Philippe Bardou committed
154
155

    def process(self):
156
        # add and link the components</code></pre>
Philippe Bardou's avatar
Philippe Bardou committed
157
			    </div>
Ibouniyamine Nabihoudine's avatar
wf doc    
Ibouniyamine Nabihoudine committed
158
			    
Jerome Mariette's avatar
Jerome Mariette committed
159
160
			</section>

Philippe Bardou's avatar
Philippe Bardou committed
161
			<section id="define_parameters" class="group">
Philippe Bardou's avatar
Philippe Bardou committed
162
		    	<h1 class="page-header">Define parameters</h1>
Ibouniyamine Nabihoudine's avatar
wf doc    
Ibouniyamine Nabihoudine committed
163
				<p>
Jerome Mariette's avatar
Jerome Mariette committed
164
					The <code>define_parameters()</code> method is used to add workflow parameters and inputs. To do so, several methods are available. 
Ibouniyamine Nabihoudine's avatar
Ibouniyamine Nabihoudine committed
165
					Once defined, the new parameters are available as object attibuts, thus they are accessible through <code>self.parameter_name</code>.
Ibouniyamine Nabihoudine's avatar
wf doc    
Ibouniyamine Nabihoudine committed
166
				</p>
Ibouniyamine Nabihoudine's avatar
wf doc    
Ibouniyamine Nabihoudine committed
167
				<p>
168
					Several types of parameters can be added, all described in the following sections. All have two required positional 
Jerome Mariette's avatar
Jerome Mariette committed
169
170
					arguments: <code>name</code> and <code>help</code>. The other arguments are optional and can be given to the method by using their 
					keywords.
Ibouniyamine Nabihoudine's avatar
wf doc    
Ibouniyamine Nabihoudine committed
171
				</p>
Philippe Bardou's avatar
Philippe Bardou committed
172
173
174
175
				<div class="alert alert-info" role="alert">
					<span class="glyphicon glyphicon-exclamation-sign" aria-hidden="true"></span>
					The operator <code>is</code> is not supported to evaluate a parameter, the operator <code>==</code> must be prefered.
				</div>
Ibouniyamine Nabihoudine's avatar
wf doc    
Ibouniyamine Nabihoudine committed
176
				
177
178
				<div id="parameters" class="subgroup">
					<h2>Parameters</h2>
Ibouniyamine Nabihoudine's avatar
wf doc    
Ibouniyamine Nabihoudine committed
179
					
Jerome Mariette's avatar
Jerome Mariette committed
180
					<p>Parameters can be added to handle a single element or a list of elements. Thus, the <code>add_parameter()</code> method can be used to force 
Jerome Mariette's avatar
Jerome Mariette committed
181
182
					the final user to provide one and only one value, where the <code>add_parameter_list()</code> method allows the final user to give as many values he 
					wants.</p>
183
184
					
					<h3>add_parameter()</h3>
Jerome Mariette's avatar
Jerome Mariette committed
185
						<h4>Example</h4>
186
						<p>
Jerome Mariette's avatar
Jerome Mariette committed
187
							In the following example, a parameter named <code>sequencer</code> 
188
189
190
							is added to the workflow. It has a list of choices and the default value is "HiSeq2000".
						</p>
				    	<div>
Jerome Mariette's avatar
Jerome Mariette committed
191
192
193
194
				    		<pre class="pre-hl "><code class="python">self.add_parameter("sequencer",
    		   "The sequencer type.", 
    		   choices = ["HiSeq2000", "ILLUMINA","SLX","SOLEXA","454","UNKNOWN"], 
    		   default="HiSeq2000")</code></pre>
195
196
197
				    	</div>
						
						<h4>Options</h4>					
Ibouniyamine Nabihoudine's avatar
wf doc    
Ibouniyamine Nabihoudine committed
198
			    	
Jerome Mariette's avatar
Jerome Mariette committed
199
			    			<p>There are two positional arguments: <code>name</code> and <code>help</code>. All other options are keyword options</p>
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
					    	
							<div class="table-responsive">
								<table class="table table-bordered table-striped">
									<thead>
										<tr>
											<th>Name</th>
											<th>Type</th>
											<th>Required</th>
											<th>Default value</th>
											<th>Description</th>
										</tr>
									</thead>
									<tbody>
										<tr>
											<td>name</td>
Ibouniyamine Nabihoudine's avatar
Ibouniyamine Nabihoudine committed
215
											<td>string</td>
216
217
											<td>true</td>
											<td>None</td>
Jerome Mariette's avatar
Jerome Mariette committed
218
219
											<td>The name of the parameter. The parameter value is accessible 
												within the workflow object through the attribute named <code>self.parameter_name</code>.</td>
220
221
222
223
										</tr>
										
										<tr>
											<td>help</td>
Ibouniyamine Nabihoudine's avatar
Ibouniyamine Nabihoudine committed
224
											<td>string</td>
225
226
											<td>true</td>
											<td>None</td>
Jerome Mariette's avatar
Jerome Mariette committed
227
											<td>The parameter help message.</td>
228
										</tr>
Ibouniyamine Nabihoudine's avatar
wf doc    
Ibouniyamine Nabihoudine committed
229
									
230
231
232
233
234
										<tr>
											<td>default</td>
											<td>-</td>
											<td>false</td>
											<td>None</td>
Ibouniyamine Nabihoudine's avatar
Ibouniyamine Nabihoudine committed
235
											<td>The default parameter value. It's type depends on the parameter type.</td>
236
237
238
239
										</tr>
										
										<tr>
											<td>type</td>
Ibouniyamine Nabihoudine's avatar
Ibouniyamine Nabihoudine committed
240
											<td>string</td>
241
242
											<td>false</td>
											<td>"str"</td>
Jerome Mariette's avatar
Jerome Mariette committed
243
244
245
											<td>The parameter type. The value provided by the final user will be casted and checked against this type. 
											All built-in Python types are available "int", "str", "float", "bool", "date", ... To create customized types, 
											refere to the <a href="./jflow-type.html">Add a data type</a> documentation.</td>
246
247
248
249
250
251
										</tr>
										
										<tr>
											<td>choices</td>
											<td>list</td>
											<td>false</td>
Jerome Mariette's avatar
Jerome Mariette committed
252
253
											<td>[]</td>
											<td>A list of the allowed values.</td>
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
										</tr>
										
										<tr>
											<td>required</td>
											<td>boolean</td>
											<td>false</td>
											<td>false</td>
											<td>Wether or not the parameter can be ommitted.</td>
										</tr>
										
										<tr>
											<td>flag</td>
											<td>string</td>
											<td>false</td>
											<td>None</td>
Jerome Mariette's avatar
Jerome Mariette committed
269
											<td>The command line flag (if the value is None, the flag will be <code>--name</code>).</td>
270
271
272
273
274
275
276
										</tr>
										
										<tr>
											<td>group</td>
											<td>string</td>
											<td>false</td>
											<td>"default"</td>
Jerome Mariette's avatar
Jerome Mariette committed
277
											<td>The value is used to group a list of parameters in sections. The group is used in both command line and GUI.</td>
278
279
280
281
282
283
284
										</tr>
										
										<tr>
											<td>display_name</td>
											<td>string</td>
											<td>false</td>
											<td>None</td>
Jerome Mariette's avatar
Jerome Mariette committed
285
											<td>The parameter name that should be displayed on the final form.</td>
286
287
288
289
290
291
292
										</tr>
										
										<tr>
											<td>add_to</td>
											<td>string</td>
											<td>false</td>
											<td>None</td>
Jerome Mariette's avatar
Jerome Mariette committed
293
294
											<td>If this parameter is part of a multiple parameter, <code>add_to</code> allows to define to which "parent" parameter it should be
											linked to.</td>
295
296
297
298
299
										</tr>
		
									</tbody>
								</table>
							</div>
Ibouniyamine Nabihoudine's avatar
wf doc    
Ibouniyamine Nabihoudine committed
300
					
301
					<h3>add_parameter_list()</h3>
Ibouniyamine Nabihoudine's avatar
wf doc    
Ibouniyamine Nabihoudine committed
302
					
Jerome Mariette's avatar
Jerome Mariette committed
303
304
305
						<p>The <code>add_parameter_list()</code> method takes the same arguments as <code>add_parameter()</code>. However, adding this parameter,
						the final user will be allowed to enter multiple values for this parameter and the object attribut <code>self.parameter_name</code> will be
						settled as a Python list.</p>
Ibouniyamine Nabihoudine's avatar
wf doc    
Ibouniyamine Nabihoudine committed
306
					
307
308
309
310
				</div>
				
	       		
	       		<div id="input_parameters" class="subgroup">
Jerome Mariette's avatar
Jerome Mariette committed
311
	       			<h2>Inputs</h2>
312
	       			
Ibouniyamine Nabihoudine's avatar
Ibouniyamine Nabihoudine committed
313
					<p>Just like parameters, inputs can be added to handle a single file or a list of files. Thus, the <code>add__input_file()</code> method can be used to force 
Ibouniyamine Nabihoudine's avatar
Ibouniyamine Nabihoudine committed
314
					the final user to provide one and only one file, where the <code>add__input_file_list()</code> method allows the final user to give as many files as he 
Jerome Mariette's avatar
Jerome Mariette committed
315
316
					wants.</p>
	       			
Jerome Mariette's avatar
Jerome Mariette committed
317
	       				<h3>add_input_file()</h3>
Jerome Mariette's avatar
Jerome Mariette committed
318
319
320
321
322
323
							<h4>Example</h4>
	       				<p>
							In the following example, an input named <code>reads</code> 
							is added to the workflow. The provided file is required and should be in fastq format. No file size limitation is specified. 
						</p>
				    	<div>
Jerome Mariette's avatar
Jerome Mariette committed
324
325
326
327
				    		<pre class="pre-hl "><code class="python">self.add_input_file_list("reads", 
                         "Which read files should be used", 
                         file_format="fastq", 
                         required=True)</code></pre>
Jerome Mariette's avatar
Jerome Mariette committed
328
329
				    	</div>
				    		
330
331
							<h4>Options</h4>
								
Jerome Mariette's avatar
Jerome Mariette committed
332
								<p>There are two positional argument : <code>name</code> and <code>help</code>. All other options are keyword options. </p>
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
                      
								<div class="table-responsive">
									<table class="table table-bordered table-striped">
										<thead>
											<tr>
												<th>Name</th>
												<th>Type</th>
												<th>Required</th>
												<th>Default value</th>
												<th>Description</th>
											</tr>
										</thead>
										<tbody>
											<tr>
												<td>name</td>
Ibouniyamine Nabihoudine's avatar
Ibouniyamine Nabihoudine committed
348
												<td>string</td>
349
350
												<td>true</td>
												<td>None</td>
Jerome Mariette's avatar
Jerome Mariette committed
351
352
												<td>The name of the parameter. The parameter value is accessible 
													within the workflow object through the attribute named <code>self.parameter_name</code>.</td>
353
354
355
356
											</tr>
											
											<tr>
												<td>help</td>
Ibouniyamine Nabihoudine's avatar
Ibouniyamine Nabihoudine committed
357
												<td>string</td>
358
359
												<td>true</td>
												<td>None</td>
Jerome Mariette's avatar
Jerome Mariette committed
360
												<td>The parameter help message.</td>
361
362
363
364
365
366
367
											</tr>
											
											<tr>
												<td>default</td>
												<td>string</td>
												<td>false</td>
												<td>None</td>
Jerome Mariette's avatar
Jerome Mariette committed
368
												<td>The default path value.</td>
369
370
371
372
373
374
375
											</tr>
										
											<tr>
												<td>file_format</td>
												<td>string</td>
												<td>false</td>
												<td>"any"</td>
Jerome Mariette's avatar
Jerome Mariette committed
376
377
												<td>The file format is checked before running the workflow. To create customized format, 
													refere to the <a href="./jflow-format.html">Add a file format</a> documentation.</td>
378
379
380
381
382
383
384
											</tr>
											
											<tr>
												<td>type</td>
												<td>string</td>
												<td>false</td>
												<td>"inputfile"</td>
Jerome Mariette's avatar
Jerome Mariette committed
385
386
387
388
389
390
												<td>The type can be "inputfile", "localfile", "urlfile" or "browsefile". An "inputfile" allows the 
												final user to provide a "localfile" or an "urlfile" or a "browsefile". A "localfile" restricts the final
												user to provide a path to a file visible by jflow. An "urlfile" only permits the final user to give an 
												URL as input, where a "browsefile" force the final user to upload a file from its own computer. This last
												option is only available from the GUI and is considered as a "localfile" from the command line. All the 
												uploading process is handled by jflow.</td>
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
											</tr>
											
											<tr>
												<td>required</td>
												<td>boolean</td>
												<td>false</td>
												<td>false</td>
												<td>Wether or not the parameter can be ommitted.</td>
											</tr>
											
											<tr>
												<td>flag</td>
												<td>string</td>
												<td>false</td>
												<td>None</td>
Jerome Mariette's avatar
Jerome Mariette committed
406
												<td>The command line flag (if the value is None, the flag will be <code>--name</code>).</td>
407
408
409
410
411
412
413
											</tr>
											
											<tr>
												<td>group</td>
												<td>string</td>
												<td>false</td>
												<td>"default"</td>
Jerome Mariette's avatar
Jerome Mariette committed
414
												<td>The value is used to group a list of parameters in sections. The group is used in both command line and GUI.</td>
415
416
417
418
419
420
421
											</tr>
											
											<tr>
												<td>display_name</td>
												<td>string</td>
												<td>false</td>
												<td>None</td>
Jerome Mariette's avatar
Jerome Mariette committed
422
												<td>The parameter name that should be displayed on the final form.</td>
423
424
425
426
427
428
429
											</tr>
											
											<tr>
												<td>add_to</td>
												<td>string</td>
												<td>false</td>
												<td>None</td>
Jerome Mariette's avatar
Jerome Mariette committed
430
431
												<td>If this parameter is part of a multiple parameter, <code>add_to</code> allows to define to which "parent" parameter it should be
												linked to.</td>
432
433
434
435
436
437
438
											</tr>
											
											<tr>
												<td>size_limit</td>
												<td>string</td>
												<td>false</td>
												<td>"0"</td>
Jerome Mariette's avatar
Jerome Mariette committed
439
440
441
												<td>Which maximum file size is allowed. If the value is "0", the file size allowed is unlimited. The given value should
												also provides the file size units between "bytes", "Kb", "Mb", "Gb", "Tb", "Pb", "Eb" and "Zb". A value of 10Mb will 
												restrict the user to upload a file of 10 Mega Bytes.</td>
442
443
444
445
446
447
											</tr>
										</tbody>
									</table>
								</div>
								
					    <h3>add_input_file_list()</h3>
Jerome Mariette's avatar
Jerome Mariette committed
448
449
450
451
					    
						<p>This method takes the same arguments as <code>add_input_file()</code>. However, adding this parameter,
						the final user will be allowed to provide multiple files and the object attribut <code>self.parameter_name</code> will be
						settled as a Python list.</p>
Jerome Mariette's avatar
Jerome Mariette committed
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
						
						<h3>add_input_directory()</h3>
						<p>
							The <code>add_input_directory()</code> method allows the user to select files from a specific directory. This 
							kind of input can be useful for tools outputing not only files but an organized directory.
							The parameter <code>get_files_fn</code> specify the function that will be used to retrieve the files. This method can 
							take as many arguments as required, but the first argument has to be a string representing the folder path.
							By default all files will be selected. From the workflow <code>process()</code> function, the files can be retrieved
							by using the <code>get_files()</code> method.
						</p>
						
						<h4>Example</h4>
	       				<p>
	       					In the following example, the <code>add_input_directory()</code> method is used to parse a directory and retrieve only fasta files
	       					inside this directory. <code>get_files()</code> will browse the directory and get all fasta files.
						</p>
			    		<div>
			    		<pre class="pre-hl "><code class="python">import os
from jflow.Workflow import Workflow

def fasta_files(folder):
    res = []
    for file in os.listdir(folder):
        if file.endswith(".fasta"):
            res.append(file)
    return res

class MyWorkflow(Workflow):
    def define_parameters(self, function="process"):
        self.add_input_directory("fastadir", "Path to folder with fasta files", 
            get_files_fn=fasta_files)

    def process(self):
        # to retrieve the files
        for fastafile in self.fastadir.get_files():
            # do something</code></pre>
				    	</div>
				    		
			    		<h4>Options</h4>
						<p>There are two positional argument : <code>name</code> and <code>help</code>. All other options are keyword options. </p>
						<div class="table-responsive">
							<table class="table table-bordered table-striped">
								<thead>
									<tr>
										<th>Name</th>
										<th>Type</th>
										<th>Required</th>
										<th>Default value</th>
										<th>Description</th>
									</tr>
								</thead>
								<tbody>
									<tr>
										<td>name</td>
										<td>string</td>
										<td>true</td>
										<td>None</td>
										<td>The name of the parameter. The parameter value is accessible 
											within the workflow object through the attribute named <code>self.parameter_name</code>.</td>
									</tr>
									
									<tr>
										<td>help</td>
										<td>string</td>
										<td>true</td>
										<td>None</td>
										<td>The parameter help message.</td>
									</tr>
									
									<tr>
										<td>default</td>
										<td>string</td>
										<td>false</td>
										<td>None</td>
										<td>The default path value.</td>
									</tr>
								
									<tr>
										<td>get_files_fn</td>
										<td>function</td>
										<td>false</td>
										<td>-</td>
										<td>
											get_files_fn will be the method called when executing <code>param.get_files()</code>. All argument from get_files()
											will be used as arguments in get_files_fn
										</td>								
									</tr>
									
									<tr>
										<td>required</td>
										<td>boolean</td>
										<td>false</td>
										<td>false</td>
										<td>Wether or not the parameter can be ommitted.</td>
									</tr>
									
									<tr>
										<td>flag</td>
										<td>string</td>
										<td>false</td>
										<td>None</td>
										<td>The command line flag (if the value is None, the flag will be <code>--name</code>).</td>
									</tr>
									
									<tr>
										<td>group</td>
										<td>string</td>
										<td>false</td>
										<td>"default"</td>
										<td>The value is used to group a list of parameters in sections. The group is used in both command line and GUI.</td>
									</tr>
									
									<tr>
										<td>display_name</td>
										<td>string</td>
										<td>false</td>
										<td>None</td>
										<td>The parameter name that should be displayed on the final form.</td>
									</tr>
								</tbody>
							</table>
						</div>
574
575
	       		</div>

Ibouniyamine Nabihoudine's avatar
wf doc    
Ibouniyamine Nabihoudine committed
576
577
578
579
				
				<div id="multiple_parameters" class="subgroup">
					<h2>Multiple parameters</h2>
					
Jerome Mariette's avatar
Jerome Mariette committed
580
581
582
583
584
585
586
587
588
589
590
591
592
						<p>Jflow offers, to the developper, the possibility to structure the input data by using the notion of multiple parameters. A multi 
						parameter is a collection of parameters linked together. Just like for parameters and inputs, it can be added to handle a single collection or a 
						list of collections. Thus, the <code>add_multiple_parameter()</code> method can be used to force the final user to provide one and only one 
						collection, where the <code>add_multiple_parameter_list()</code> method allows the final user to give as many collection he wants. To add a 
						parameter within the multiple parameter, it only requires to set the option <code>add_to</code> of any methods previously described. 
						The accessible object attribut <code>self.multi_parameter_name</code> is then a Python dictionary gathering all the values of the different 
						parameters under the format <code>{"sub_parameter1":value}</code></p>
						
						<h3>add_multiple_parameter()</h3>
						
						<h4>Example</h4>
						The following example creates a multiple parameter named <code>library</code> which contains two input files <code>R1</code> and <code>R2</code> 
						and a <code>sequencer</code> parameter. </p>
Ibouniyamine Nabihoudine's avatar
wf doc    
Ibouniyamine Nabihoudine committed
593
594
595
596
597
598
				    	
				    	<div>
				    		<pre class="pre-hl "><code class="python">self.add_multiple_parameter("library", "Library.", required=True)
self.add_input_file("R1", "Path to R1 file.", required=True, add_to="library")
self.add_input_file("R2", "Path to R2 file.", add_to="library")
self.add_parameter("sequencer", "The sequencer type.", choices=["HiSeq2000", 
Philippe Bardou's avatar
Philippe Bardou committed
599
    "ILLUMINA", "UNKNOWN"], default="HiSeq2000", add_to="library")</code></pre>
Ibouniyamine Nabihoudine's avatar
wf doc    
Ibouniyamine Nabihoudine committed
600
				    	</div>
Jerome Mariette's avatar
Jerome Mariette committed
601
602

						<h4>Options</h4>
Ibouniyamine Nabihoudine's avatar
Ibouniyamine Nabihoudine committed
603
						<p>There are two positional arguments : name and help. All other options are keyword options.</p>
Ibouniyamine Nabihoudine's avatar
wf doc    
Ibouniyamine Nabihoudine committed
604
								
Ibouniyamine Nabihoudine's avatar
wf doc    
Ibouniyamine Nabihoudine committed
605
606
607
608
609
610
611
612
613
614
615
616
617
618
								<div class="table-responsive">
										<table class="table table-bordered table-striped">
											<thead>
												<tr>
													<th>Name</th>
													<th>Type</th>
													<th>Required</th>
													<th>Default value</th>
													<th>Description</th>
												</tr>
											</thead>
											<tbody>
												<tr>
													<td>name</td>
Ibouniyamine Nabihoudine's avatar
Ibouniyamine Nabihoudine committed
619
													<td>string</td>
Ibouniyamine Nabihoudine's avatar
wf doc    
Ibouniyamine Nabihoudine committed
620
621
													<td>true</td>
													<td>None</td>
Jerome Mariette's avatar
Jerome Mariette committed
622
623
624
													<td>The name of the multi parameter. The parameter value is accessible 
														within the workflow object through the attribute named <code>self.multi_parameter_name</code>. And its sub parameters
														using <code>self.multi_parameter_name["sub_parameter_name"]</code>.</td>
Ibouniyamine Nabihoudine's avatar
wf doc    
Ibouniyamine Nabihoudine committed
625
626
627
628
												</tr>
												
												<tr>
													<td>help</td>
Ibouniyamine Nabihoudine's avatar
Ibouniyamine Nabihoudine committed
629
													<td>string</td>
Ibouniyamine Nabihoudine's avatar
wf doc    
Ibouniyamine Nabihoudine committed
630
631
													<td>true</td>
													<td>None</td>
Jerome Mariette's avatar
Jerome Mariette committed
632
													<td>The parameter help message.</td>
Ibouniyamine Nabihoudine's avatar
wf doc    
Ibouniyamine Nabihoudine committed
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
												</tr>

												<tr>
													<td>required</td>
													<td>boolean</td>
													<td>false</td>
													<td>false</td>
													<td>Wether or not the parameter can be ommitted.</td>
												</tr>
												
												<tr>
													<td>flag</td>
													<td>string</td>
													<td>false</td>
													<td>None</td>
Jerome Mariette's avatar
Jerome Mariette committed
648
649
													<td>The command line flag (if the value is None, the flag will be <code>--name</code>). The sub parameters can be set as following
													<code>--name sub1=... sub2=...</code></td>
Ibouniyamine Nabihoudine's avatar
wf doc    
Ibouniyamine Nabihoudine committed
650
651
652
653
654
655
656
												</tr>
												
												<tr>
													<td>group</td>
													<td>string</td>
													<td>false</td>
													<td>"default"</td>
Jerome Mariette's avatar
Jerome Mariette committed
657
													<td>The value is used to group a list of parameters in sections. The group is used in both command line and GUI.</td>
Ibouniyamine Nabihoudine's avatar
wf doc    
Ibouniyamine Nabihoudine committed
658
659
660
661
662
663
664
												</tr>
												
												<tr>
													<td>display_name</td>
													<td>string</td>
													<td>false</td>
													<td>None</td>
Jerome Mariette's avatar
Jerome Mariette committed
665
													<td>The parameter name that should be displayed on the final form.</td>
Ibouniyamine Nabihoudine's avatar
wf doc    
Ibouniyamine Nabihoudine committed
666
												</tr>
Jerome Mariette's avatar
Jerome Mariette committed
667
												
Ibouniyamine Nabihoudine's avatar
wf doc    
Ibouniyamine Nabihoudine committed
668
669
670
671
672
											</tbody>
										</table>
									</div>
						
						<h3>add_multiple_parameter_list()</h3>
Jerome Mariette's avatar
Jerome Mariette committed
673
674
675
						<p>This method takes the same arguments as <code>add_multiple_parameter()</code>. However, adding this parameter,
						the final user will be allowed to provide multiple collection and the object attribut <code>self.multi_parameter_name</code> will be
						settled as a Python list of Python dictionary.</p>
Ibouniyamine Nabihoudine's avatar
wf doc    
Ibouniyamine Nabihoudine committed
676
677
678
679
						
				</div>
				
				<div id="exclusion_rules" class="subgroup">
Ibouniyamine Nabihoudine's avatar
Ibouniyamine Nabihoudine committed
680
					<h2>Exclusion rules</h2>
Ibouniyamine Nabihoudine's avatar
wf doc    
Ibouniyamine Nabihoudine committed
681
				
Jerome Mariette's avatar
Jerome Mariette committed
682
						<p>Jflow offers the possibility to exclude some rules from each otehrs. To do so, the method <code>add_exclusion_rule()</code> is available. </p>
Ibouniyamine Nabihoudine's avatar
wf doc    
Ibouniyamine Nabihoudine committed
683
684
					
						<h3>add_exclution_rule()</h3>
Jerome Mariette's avatar
Jerome Mariette committed
685
686
687
688
689
690
691
692
693
							<h4>Example</h4>
							<p>In the following example, the final user will not be allowed to provide both <code>fasta_file</code> and <code>fastq_file</code> parameters.</p>
						   	<div>
				    		<pre class="pre-hl "><code class="python">self.add_input_file("fasta_file", "Path to the fasta file.", format="fasta")
self.add_input_file("fastq_file", "Path to the fastq file.", format="fastq")
self.add_exclution_rule("fasta_file", "fastq")</code></pre>
				    	</div>
				    	
							<h4>Options</h4>
Ibouniyamine Nabihoudine's avatar
wf doc    
Ibouniyamine Nabihoudine committed
694
							<p>The method accept the following options</p>
Ibouniyamine Nabihoudine's avatar
wf doc    
Ibouniyamine Nabihoudine committed
695
						
Ibouniyamine Nabihoudine's avatar
wf doc    
Ibouniyamine Nabihoudine committed
696
697
698
699
700
701
702
703
704
705
706
707
708
709
							<div class="table-responsive">
								<table class="table table-bordered table-striped">
									<thead>
										<tr>
											<th>Name</th>
											<th>Type</th>
											<th>Required</th>
											<th>Default value</th>
											<th>Description</th>
										</tr>
									</thead>
									<tbody>
										<tr>
											<td>*args2exclude</td>
Ibouniyamine Nabihoudine's avatar
Ibouniyamine Nabihoudine committed
710
											<td>string</td>
Ibouniyamine Nabihoudine's avatar
wf doc    
Ibouniyamine Nabihoudine committed
711
712
713
714
715
716
717
											<td>true</td>
											<td>None</td>
											<td>The name of the parameter to exclude.</td>
										</tr>
									</tbody>
								</table>
							</div>
Ibouniyamine Nabihoudine's avatar
wf doc    
Ibouniyamine Nabihoudine committed
718
				</div>
Ibouniyamine Nabihoudine's avatar
wf doc    
Ibouniyamine Nabihoudine committed
719

Jerome Mariette's avatar
Jerome Mariette committed
720
			</section>
Philippe Bardou's avatar
Philippe Bardou committed
721
722
			
	  		<section id="process" class="group">
Jerome Mariette's avatar
Jerome Mariette committed
723
		    	<h1 class="page-header">Process</h1>
Ibouniyamine Nabihoudine's avatar
Ibouniyamine Nabihoudine committed
724
		    	<p>The <code>process()</code> method is in charge of building the workflow by adding components (using the method <code>add_component()</code>) and 
Jerome Mariette's avatar
Jerome Mariette committed
725
		    	linking their inputs and their outputs. A component is a class representing a workflow step. See the 
Jerome Mariette's avatar
Jerome Mariette committed
726
		    	<a href="./jflow-core-component.html">component</a> documentation for more information.</p>
Jerome Mariette's avatar
Jerome Mariette committed
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743

   				<h2>add_component()</h2>
   				<p>The <code>add_component()</code> method add a component to the workflow by building a <code>jflow.component.Component</code>
   				object and returning it. All attributs defined within this object, such as the outputs, are then available from the workflow and 
   				can be used as inputs of other components.</p>
   				<h3>Example</h3>
   				<p>In the following example, the first component <code>BWAIndex</code> is built and returned in the <code>bwaindex</code> object.
   				The output <code>bwaindex.databank</code> is accessible as an object attribut and can be used as input of the <code>BWAmem</code>
   				component. This example is extracted from the <a href="./jflow-quickstart.html">Quick start</a>.</p>
					<div>
				    <pre class="pre-hl "><code class="python"># index the reference genome
bwaindex = self.add_component("BWAIndex", [self.reference_genome])
# align reads against the indexed genome
bwamem = self.add_component("BWAmem", [bwaindex.databank, self.reads])</code></pre>
				    	</div>
   				<h3>Options</h3>
   				<p>There is one positional argument : component_name. All other options are keyword options.</p>
Frédéric Escudié's avatar
Frédéric Escudié committed
744
745
746
747
748
749
750
751
752
753
754
755
756
757
   				<div class="table-responsive">
					<table class="table table-bordered table-striped">
						<thead>
							<tr>
								<th>Name</th>
								<th>Type</th>
								<th>Required</th>
								<th>Default value</th>
								<th>Description</th>
							</tr>
						</thead>
						<tbody>
							<tr>
								<td>component_name</td>
Jerome Mariette's avatar
Jerome Mariette committed
758
								<td>string</td>
Frédéric Escudié's avatar
Frédéric Escudié committed
759
								<td>true</td>
Jerome Mariette's avatar
Jerome Mariette committed
760
761
								<td>None</td>
								<td>The component class name to add to the workflow.</td>
Frédéric Escudié's avatar
Frédéric Escudié committed
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
							</tr>
							<tr>
								<td>args</td>
								<td>list</td>
								<td>false</td>
								<td>[]</td>
								<td>The component's arguments (see <a href="./jflow-core-component.html#define_parameters">here</a> for more details).</td>
							</tr>
							<tr>
								<td>kwargs</td>
								<td>dict</td>
								<td>false</td>
								<td>{}</td>
								<td>The component's keyword arguments (see <a href="./jflow-core-component.html#define_parameters">here</a> for more details).</td>
							</tr>
							<tr>
								<td>component_prefix</td>
Jerome Mariette's avatar
Jerome Mariette committed
779
								<td>string</td>
Frédéric Escudié's avatar
Frédéric Escudié committed
780
781
								<td>false</td>
								<td>"default"</td>
Jerome Mariette's avatar
Jerome Mariette committed
782
783
								<td>The prefix is used to name the component at the execution. The prefix allows to add multiple components of the same class within
								the same workflow.</td>
Frédéric Escudié's avatar
Frédéric Escudié committed
784
785
786
							</tr>
						</tbody>
					</table>
Jerome Mariette's avatar
Jerome Mariette committed
787
788
				</div>
			</section>
Philippe Bardou's avatar
Philippe Bardou committed
789
790
			
	  		<section id="other_methods" class="group">
Jerome Mariette's avatar
Jerome Mariette committed
791
		    	<h1 class="page-header">Other methods</h1>
Frédéric Escudié's avatar
Frédéric Escudié committed
792
				<div id="pre_process" class="subgroup">
Jerome Mariette's avatar
Jerome Mariette committed
793
					<h2>Pre process</h2>
Ibouniyamine Nabihoudine's avatar
Ibouniyamine Nabihoudine committed
794
					<p><code>pre_process()</code> is executed before running the <code>process</code> method. Unlike <code>process</code>, this method does not allow
Jerome Mariette's avatar
Jerome Mariette committed
795
796
					to add components, but can be useful when implementing an application requiring to prepare some data before running the workflow (insert / recover
					information from a database, add metadata to the workflow, ...).</p>
Frédéric Escudié's avatar
Frédéric Escudié committed
797
798
				</div>
				<div id="post_process" class="subgroup">
Jerome Mariette's avatar
Jerome Mariette committed
799
800
801
					<h2>Post process</h2>
					<p><code>post_process()</code> is executed right after the <code>process</code> method and cannot be used to add components. This method can
					be useful to perform some database transactions and to synchronize data.</p>
Frédéric Escudié's avatar
Frédéric Escudié committed
802
				</div>
Jerome Mariette's avatar
Jerome Mariette committed
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
				<div id="set_to_address" class="subgroup">
					<h2>Set to address</h2>
					<p><code>set_to_address()</code> overwrite the value <code>to_address</code> defined in the jflow configuration file.</p>
	   				<h3>Options</h3>
	   				<p>There is one required argument : to_address.</p>
	   				<div class="table-responsive">
						<table class="table table-bordered table-striped">
							<thead>
								<tr>
									<th>Name</th>
									<th>Type</th>
									<th>Required</th>
									<th>Default value</th>
									<th>Description</th>
								</tr>
							</thead>
							<tbody>
								<tr>
									<td>to_address</td>
									<td>string</td>
									<td>true</td>
									<td>None</td>
									<td>The email address to use to send an email to the user once the workflow is completed.</td>
								</tr>
							</tbody>
						</table>
					</div>
					
				</div>
				<div id="set_subject" class="subgroup">
					<h2>Set email subject</h2>
					<p><code>set_subject()</code> </code> overwrite the value <code>subject</code> defined in the jflow configuration file.</p>
	   				<h3>Options</h3>
	   				<p>There is one required argument : subject.</p>
	   				<div class="table-responsive">
						<table class="table table-bordered table-striped">
							<thead>
								<tr>
									<th>Name</th>
									<th>Type</th>
									<th>Required</th>
									<th>Default value</th>
									<th>Description</th>
								</tr>
							</thead>
							<tbody>
								<tr>
									<td>subject</td>
									<td>string</td>
									<td>true</td>
									<td>None</td>
									<td>The email subject to use for the email sent to the user once the workflow is completed.</td>
								</tr>
							</tbody>
						</table>
					</div>
				</div>
				<div id="set_message" class="subgroup">
					<h2>Set email message</h2>
					<p><code>set_message()</code> overwrite the value <code>message</code> defined in the jflow configuration file.</p>
	   				<h3>Options</h3>
	   				<p>There is one required argument : message.</p>
	   				<div class="table-responsive">
						<table class="table table-bordered table-striped">
							<thead>
								<tr>
									<th>Name</th>
									<th>Type</th>
									<th>Required</th>
									<th>Default value</th>
									<th>Description</th>
								</tr>
							</thead>
							<tbody>
								<tr>
									<td>message</td>
									<td>string</td>
									<td>true</td>
									<td>None</td>
									<td>The email message to use for the email sent to the user once the workflow is completed.</td>
								</tr>
							</tbody>
						</table>
					</div>
				</div>
Jerome Mariette's avatar
Jerome Mariette committed
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
				<div id="get_resource" class="subgroup">
					<h2>Get shared resources</h2>
					<p>The method <code>get_resource()</code>, giving a specific resource, returns the defined value within the <code>resource</code> 
					section of the jflow configuration file.</p>
	   				<h3>Options</h3>
	   				<p>There is one required argument : resource.</p>
	   				<div class="table-responsive">
						<table class="table table-bordered table-striped">
							<thead>
								<tr>
									<th>Name</th>
									<th>Type</th>
									<th>Required</th>
									<th>Default value</th>
									<th>Description</th>
								</tr>
							</thead>
							<tbody>
								<tr>
									<td>resource</td>
									<td>string</td>
									<td>true</td>
									<td>None</td>
									<td>The resource name for which is requested the configured value.</td>
								</tr>
							</tbody>
						</table>
					</div>
				</div>
Jerome Mariette's avatar
Jerome Mariette committed
917
			</section>
Philippe Bardou's avatar
Philippe Bardou committed
918
		  </div>
919
920
		</div>
		
Jerome Mariette's avatar
Jerome Mariette committed
921
922
923
      <hr>
      <footer>
      	<div class="container" style="text-align: center;">
Philippe Bardou's avatar
Philippe Bardou committed
924
		  <p>Copyright © 2015, INRA | Designed by <a target="_blank" href="http://bioinfo.genotoul.fr/">GenoToul Bioinfo platform</a> and <a target="_blank" href="http://www.sigenae.org/">Sigenae platform</a>.</p>
Jerome Mariette's avatar
Jerome Mariette committed
925
926
927
		</div>
      </footer>
	
928
	</div>
Jerome Mariette's avatar
Jerome Mariette committed
929
930
931
932
933
934
935
936
937
938
	
    <!-- Bootstrap core JavaScript
    ================================================== -->
    <!-- Placed at the end of the document so the pages load faster -->
    <script src="js/jquery.min.js"></script>
    <script src="js/bootstrap.min.js"></script>
    <!-- <script src="../../assets/js/docs.min.js"></script> -->
    <!-- IE10 viewport hack for Surface/desktop Windows 8 bug -->
    <!-- <script src="../../assets/js/ie10-viewport-bug-workaround.js"></script> -->
	
Philippe Bardou's avatar
Philippe Bardou committed
939
940
941
942
	<!--  Highlight code -->
	<script src="js/highlight.pack.js"></script>
	<script>hljs.initHighlightingOnLoad();</script>
	
Ibouniyamine Nabihoudine's avatar
wf doc    
Ibouniyamine Nabihoudine committed
943
	<script type='text/javascript'>
Philippe Bardou's avatar
Philippe Bardou committed
944
945
946
947
948
		$('body').scrollspy({
    		target: '.bs-docs-sidebar',
    		offset: 150
		});
	</script>
949
950
</body>
</html>