Getting Started#

What is Ewoks?#

Ewoks is an ecosystem of Python packages designed to execute computational graphs, also known as workflows. In these workflows:

  • Nodes represent processing steps

  • Links represent data flowing between steps

https://gitlab.esrf.fr/workflow/ewokstutorials/ewoksfordevs/-/raw/main/images/workflow1.excalidraw.svg?ref_type=heads

Workflows can be defined using JSON, YAML, or created programmatically in Python following the Ewoks specification.

Ewoks acts as a bridge between workflow systems, enabling the same workflow to be executed across different systems. Any workflow system can be integrated into Ewoks as an execution engine, allowing interoperability without changing the workflow definition or implementation.


Quick Start#

Install the full Ewoks suite using pip:

pip install ewoks

This will include all core tools and example workflows.

Run an Example Workflow#

The ewoks package includes several demo workflows. To run the demo workflow from the command line:

ewoks execute demo -p a=10 -p b=3 --test --outputs=all
  • -p a=10 -p b=3: Set input parameters

  • --test: Load the demo workflow from Ewoks test suite

  • --outputs=all: Print outputs of all workflow nodes

For full CLI options, run:

ewoks execute -h

Or refer to the Command-line reference.

Inspect Workflow Parameters#

Before executing a workflow, you can inspect its parameters using:

ewoks show demo -p a=10 -p b=3 --test

Example output:

Workflow: demo
Id: demo
Description: demo
╒════════╤════════════════╤═══════════════════╤═══════╕
│ Name   │ Value          │ Task identifier   │ Id    │
╞════════╪════════════════╪═══════════════════╪═══════╡
│ list   │ [0, 1, 2]      │ SumList           │ task0 │
├────────┼────────────────┼───────────────────┼───────┤
│ delay  │ 0              │ SumList           │ task0 │
├────────┼────────────────┼───────────────────┼───────┤
│ b      │ <MISSING_DATA> │ SumTask           │ task1 │
├────────┼────────────────┼───────────────────┼───────┤
│ delay  │ 0              │ SumTask           │ task1 │
├────────┼────────────────┼───────────────────┼───────┤
│ a      │ 10             │ SumTask           │ task2 │
├────────┼────────────────┼───────────────────┼───────┤
│ b      │ 3              │ SumTask           │ task2 │
├────────┼────────────────┼───────────────────┼───────┤
│ delay  │ 0              │ SumTask           │ task2 │
├────────┼────────────────┼───────────────────┼───────┤
│ b      │ 3              │ SumTask           │ task3 │
├────────┼────────────────┼───────────────────┼───────┤
│ delay  │ 0              │ SumTask           │ task3 │
├────────┼────────────────┼───────────────────┼───────┤
│ b      │ 4              │ SumTask           │ task4 │
├────────┼────────────────┼───────────────────┼───────┤
│ delay  │ 0              │ SumTask           │ task4 │
├────────┼────────────────┼───────────────────┼───────┤
│ delay  │ 0              │ SumTask           │ task5 │
├────────┼────────────────┼───────────────────┼───────┤
│ b      │ 6              │ SumTask           │ task6 │
├────────┼────────────────┼───────────────────┼───────┤
│ delay  │ 0              │ SumTask           │ task6 │
╘════════╧════════════════╧═══════════════════╧═══════╛

Convert Workflow Format#

To inspect or modify a workflow, convert it to a JSON file:

ewoks convert demo demo.json --test

Learn More#

To go further