scipp / essreduce

Common functionality for ESS data reduction
https://scipp.github.io/essreduce/
BSD 3-Clause "New" or "Revised" License
1 stars 1 forks source link

Workflow building helper. #70

Closed YooSunYoung closed 3 months ago

YooSunYoung commented 3 months ago

Fixes #68

and partially related to #61

I avoided spending too much time to make it prettier for now.

Try Out

Now it's building new object everytime you call the helper function.

from ess import loki
from ess.reduce.ui import workflow_widget

workflow_widget()

https://github.com/user-attachments/assets/fced63b7-14f9-456c-9d89-44570c578875

There is a smaller helper that create a widget for a certain pipeline constructor.

from ess.reduce.ui import workflow_widget_from_constructor
from ess.loki.general import LokiAtLarmorTutorialWorkflow

workflow_widget_from_constructor(LokiAtLarmorTutorialWorkflow)
YooSunYoung commented 3 months ago

@MridulS I'm gonna add tests and documentation as well but can you please have a look in the meantime?

YooSunYoung commented 3 months ago

@jokasimr I either left comments or fixed the code. Can you please have another look?

YooSunYoung commented 3 months ago

I think I fixed everything...! I'll just merge it : D