Skip to content

How to run a workflow created in .ymal #80

Closed Answered by rafaspadilha
mursaleen-bkk asked this question in Q&A
Discussion options

You must be logged in to vote

Hi, @mursaleen-bkk.

You can run this workflow by loading the yaml file and passing it directly as input to client.run.
You can find an example of this in the crop segmentation's visualization notebook.

client = get_default_vibe_client()

input_geometry_path = "./input_region.wkt"
time_range = (datetime(2020, 1, 1), datetime(2020, 12, 31))

# Reading the geometry file 
with open(input_geometry_path) as f:
    geometry = wkt.load(f)

# Reading the workflow
with open("wf_viz_crop_seg.yaml") as f:
    wf_dict = yaml.safe_load(f)

wf_run = client.run(wf_dict, "Crop Segmentation Workflow Visualization", geometry=geometry, time_range=time_range)
wf_run.monitor()

In this case, wf_viz_crop_seg.yaml

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by rafaspadilha
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants