biolab / orange3

🍊 :bar_chart: :bulb: Orange: Interactive data analysis
https://orangedatamining.com
Other
4.85k stars 1.01k forks source link

Widget that can contain subprocesses built up from other widgets #4229

Closed wvdvegte closed 4 years ago

wvdvegte commented 4 years ago

It would be nice to be able to hierarchically subdivide data-processing workflows into sub-processes by having a sub-process widget, and being able to select part of the workflow, right-click, select "create sub-process" so that it will "disappear" into a sub-process widget with as its input the input of the first widget(s) in the selected workflow and as output the output of the last one(s). This makes it easier to maintain overview over complex workflows and to (re)arrange them.

FlyingTonio commented 4 years ago

I strongly support this suggestion. I am experiencing the same difficulty with complex workflows.

irgolic commented 4 years ago

This has been brought up in the past.

You could hide a sub-process/workflow/scheme in a widget-like object.

SUB1

Double-clicking it should open the sub-workflow in the same window, with a source and a sink node. Linking several widgets to the sink could implicitly merge the data (alleviating https://github.com/biolab/orange3/issues/4228). Their signals should connect to the links in the outer workflow.

SUB2

If we decide not to allow nesting of sub-workflows, it could be opened in a panel (like a frameless window) on top of the current workflow, casting a shadow on the canvas behind it. Otherwise, calling setScheme() should be fine. Some meta information may need to be stored when opening a sub-workflow, to restore the previous scheme when exiting the sub-workflow view.

A sub-workflow should be created by highlighting two or more connected widgets and pressing a keyboard shortcut, or right-clicking/selecting an option in the Widget menu.

janezd commented 4 years ago

I strongly support this suggestion.

You volunteer? :)

janezd commented 4 years ago

As @irgolic wrote, this issue has come up before. We (i.e. the core team) refer to it as "megawidgets".

Such functionality is available in software in which elements (like Orange's widges) are too specific and combining many of them is needed to achieve the same effect as that of a single Orange's widget. We believe that Orange strikes a good balance and doesn't require them. We use Orange a lot and never felt any need for them.

If any software that is based on Orange Canvas but uses its own sets of widgets would need this, its developers are on their own. Canvas is open sourced.

There is only one single person on the world who could implement this functionality. It would require months of his work and his time is too precious for a functionality that is in unnecessary.

wvdvegte commented 4 years ago

OK, fair enough! I do realize that I generally need less widgets in Orange than "operators" in RapidMiner ...