Skip to content

Commit

Permalink
Deploying to gh-pages from @ 6b81799 🚀
Browse files Browse the repository at this point in the history
  • Loading branch information
Freymaurer committed Feb 21, 2024
1 parent 4b64908 commit 579f1c4
Show file tree
Hide file tree
Showing 39 changed files with 65 additions and 10 deletions.
60 changes: 52 additions & 8 deletions docs/WorkflowsManual/cwl_examples.html
Original file line number Diff line number Diff line change
Expand Up @@ -674,10 +674,51 @@ <h1 class="front-header">
glob: $(runtime.outdir)
</nfdi-code>
<p><a href="https://git.nfdi4plants.org/muehlhaus/ArcPrototype/-/tree/CWLExamples/workflows/FixedScript">Example</a></p>
<nfdi-h3 id="with-a-fixed-script-in-a-mounted-arc">With a fixed script in a mounted arc</nfdi-h3>
<p>When scripting, it is convenient to work within the environment of the ARC (e.g. location of files, writing results in the runs
folder and so on). When the ARC is mounted within the CWL process, the script can be ran in that environment and the corresponding runs folder
is then returned as an output.</p>
<nfdi-code class="language-yaml">cwlVersion: v1.2
class: CommandLineTool
hints:
DockerRequirement:
dockerPull: address/to/my/docker
requirements:
- class: InitialWorkDirRequirement
listing:
# this specifies the name of the root folder
- entryname: arc
entry: $(inputs.arcDirectory)
writable: true
- class: NetworkAccess
networkAccess: true
baseCommand: [run, ./arc/workflows/myWorkflow/myAnalysis.script]
inputs:
# the arc root directory is given as an input, but not called by the process
arcDirectory:
type: Directory
input1:
type: File
inputBinding:
position: 1
input2:
type: Directory
inputBinding:
position: 2
# prefix is optional
prefix: -i
outputs:
myOutput:
type: Directory
outputBinding:
glob: "./arc/runs/myRun"
</nfdi-code>
<p><a href="https://git.nfdi4plants.org/muehlhaus/ArcPrototype/-/tree/CWLExamples/workflows/ARCMount">Example</a></p>
<nfdi-h3 id="within-an-arc-with-a-devcontainer">Within an ARC with a devcontainer</nfdi-h3>
<p>Within the context of an ARC, researches often work within devcontainers or the ARC environment. CWL is able to replicate
this workflow under the premise, that in the end everything can be executed in one go. The entire arc directory can be mounted
into the working directory of the CWL process.</p>
this workflow under the premise, that in the end everything can be executed in one go by including the Dockerfile of the devcontainer.
The entire arc directory can be mounted into the working directory of the CWL process as well, making the script for the devcontainer
and CWL process identical. This enables explorative work in scripts which can then be executed with CWL after completion without much overhead.</p>
<nfdi-code class="language-yaml">cwlVersion: v1.2
class: CommandLineTool
hints:
Expand All @@ -686,13 +727,17 @@ <h1 class="front-header">
requirements:
- class: InitialWorkDirRequirement
listing:
- entryname: myAnalysis.script
entry:
$include: myAnalysis.script
# this specifies the name of the root folder
- entryname: arc
entry: $(inputs.arcDirectory)
writable: true
- class: NetworkAccess
networkAccess: true
baseCommand: [run, myAnalysis.script]
baseCommand: [run, ./arc/workflows/myWorkflow/myAnalysis.script]
inputs:
# the arc root directory is given as an input, but not called by the process
arcDirectory:
type: Directory
input1:
type: File
inputBinding:
Expand All @@ -707,8 +752,7 @@ <h1 class="front-header">
myOutput:
type: Directory
outputBinding:
# this returns the whole working directory
glob: $(runtime.outdir)
glob: "./arc/runs/myRun"
</nfdi-code>
<p>The Dockerfile should only include operations that reference resources that are available online or within the baseimage. COPY operations that point to local files for
example won't work in the context of CWL. If they are necessary for the execution in the devcontainer context (e.g. configuration for editors), but not the execution of the script, they
Expand Down
13 changes: 12 additions & 1 deletion docs/WorkflowsManual/cwl_runner_installation.html
Original file line number Diff line number Diff line change
Expand Up @@ -604,10 +604,21 @@ <h1 class="front-header">
<ul>
<li>Run <code>sudo apt-get update</code></li>
<li>Install Python 3 if it is not already preinstalled <code>sudo apt install python3</code></li>
<li>Install python virtual environment <code>sudo apt install python3.8-venv</code></li>
<li>Install python virtual environment <code>sudo apt install python3.[your version here]-venv</code></li>
<li>Create a virtual environment <code>python3 -m venv env</code> (named env here, name can vary)</li>
<li>Activate the virtual environment <code>source env/bin/activate</code></li>
<li>Install the cwltool with pip <code>pip install cwltool</code></li>
</ul>
<nfdi-h2 id="cwltool-usage">cwltool usage</nfdi-h2>
<ul>
<li>If you are on Windows, start the WSL</li>
<li>Activate the virtual environment <code>source env/bin/activate</code></li>
<li>Navigate to the results destination directory</li>
<li>Run the cwltool with the cwl file and the job file <code>cwltool uri/to/cwlfile.cwl uri/to/jobfile.yml</code>
<ul>
<li>Important: cwltool requires <a href="https://en.wikipedia.org/wiki/Uniform_Resource_Identifier">URIs</a> for the input files</li>
</ul>
</li>
</ul>

<div style="display: flex; align-items: flex-end; justify-content: space-between; margin: 1rem 0 1rem 0;">
Expand Down
Binary file removed pagefind/fragment/en-us_425fd9d.pf_fragment
Binary file not shown.
Binary file added pagefind/fragment/en-us_848b438.pf_fragment
Binary file not shown.
Binary file added pagefind/fragment/en-us_a97cdf6.pf_fragment
Binary file not shown.
Binary file removed pagefind/fragment/en-us_dc28959.pf_fragment
Binary file not shown.
Binary file removed pagefind/index/en-us_0282012.pf_index
Binary file not shown.
Binary file added pagefind/index/en-us_141f61e.pf_index
Binary file not shown.
Binary file removed pagefind/index/en-us_1674831.pf_index
Binary file not shown.
Binary file removed pagefind/index/en-us_17c2941.pf_index
Binary file not shown.
Binary file added pagefind/index/en-us_1cbdec5.pf_index
Binary file not shown.
Binary file removed pagefind/index/en-us_2368d10.pf_index
Binary file not shown.
Binary file removed pagefind/index/en-us_29b982d.pf_index
Binary file not shown.
Binary file removed pagefind/index/en-us_2dfdd41.pf_index
Binary file not shown.
Binary file added pagefind/index/en-us_32444c7.pf_index
Binary file not shown.
Binary file added pagefind/index/en-us_34a7ce5.pf_index
Binary file not shown.
Binary file removed pagefind/index/en-us_5367a29.pf_index
Binary file not shown.
Binary file added pagefind/index/en-us_7357bac.pf_index
Binary file not shown.
Binary file removed pagefind/index/en-us_856edf1.pf_index
Binary file not shown.
Binary file removed pagefind/index/en-us_8d11626.pf_index
Binary file not shown.
Binary file removed pagefind/index/en-us_9a4b304.pf_index
Binary file not shown.
Binary file added pagefind/index/en-us_9d6464f.pf_index
Binary file not shown.
Binary file added pagefind/index/en-us_a43c983.pf_index
Binary file not shown.
Binary file added pagefind/index/en-us_a67729e.pf_index
Binary file not shown.
Binary file added pagefind/index/en-us_a67d9ab.pf_index
Binary file not shown.
Binary file removed pagefind/index/en-us_b7f26a6.pf_index
Binary file not shown.
Binary file added pagefind/index/en-us_b9f3463.pf_index
Binary file not shown.
Binary file added pagefind/index/en-us_c2f9ec4.pf_index
Binary file not shown.
Binary file added pagefind/index/en-us_c48f614.pf_index
Binary file not shown.
Binary file removed pagefind/index/en-us_d117725.pf_index
Binary file not shown.
Binary file added pagefind/index/en-us_d3c38da.pf_index
Binary file not shown.
Binary file removed pagefind/index/en-us_f8a8f49.pf_index
Binary file not shown.
Binary file removed pagefind/index/en-us_fb4a16c.pf_index
Binary file not shown.
Binary file added pagefind/index/en-us_fc1af41.pf_index
Binary file not shown.
Binary file added pagefind/index/en-us_fddcfa4.pf_index
Binary file not shown.
Binary file removed pagefind/index/en-us_ff11d8e.pf_index
Binary file not shown.
2 changes: 1 addition & 1 deletion pagefind/pagefind-entry.json
Original file line number Diff line number Diff line change
@@ -1 +1 @@
{"version":"1.0.4","languages":{"de-de":{"hash":"de-de_8e81e7fc77bd9","wasm":"de-de","page_count":1},"en-us":{"hash":"en-us_ed234c3adb0d8","wasm":"en-us","page_count":436}}}
{"version":"1.0.4","languages":{"de-de":{"hash":"de-de_8e81e7fc77bd9","wasm":"de-de","page_count":1},"en-us":{"hash":"en-us_243869e8ad9fc","wasm":"en-us","page_count":436}}}
Binary file added pagefind/pagefind.en-us_243869e8ad9fc.pf_meta
Binary file not shown.
Binary file removed pagefind/pagefind.en-us_ed234c3adb0d8.pf_meta
Binary file not shown.

0 comments on commit 579f1c4

Please sign in to comment.