Skip to content

Optional data converters for connection with native orange widgets #61

Description

@poautran

In GitLab by @woutdenolf on Oct 14, 2025, 16:51 GMT+2:

Proposal: implement data converters when pass data to and from native Orange widgets

def my_input_converter(Dict[Union[str,int], Any]) -> Dict[Union[str,int], Any]:
    ...


def my_output_converter(Dict[Union[str,int], Any]) -> Dict[Union[str,int], Any]:
    ...


class OWSumTask(
    OWEwoksWidgetOneThread,
    ewokstaskclass=SumTask, 
    native_input_converter=my_input_converter,
    native_output_converter=my_output_converter
):
    ...

Use-case (@Retegan , @Thomas18 ): ewoksxas has Ewoks widgets using Larch. These widgets need to be use-able in native Orange workflows (e.g. what ID21 is doing).

For this we need to pass the data as orange data frames: https://redirect.github.com/biolab/orange3/blob/872e4aed3164d88c6ac21e8633290d2a63664868/Orange/data/pandas_compat.py#L40.

However for the Ewoks tasks we want to pass the data as dictionaries of numpy arrays so we are not coupled to Orange3 and this data structure is more easily accessible for any other Ewoks task we want to add.

Assignees: @woutdenolf

Migrated from GitLab: https://gitlab.esrf.fr/workflow/ewoks/ewoksorange/-/issues/61

Metadata

Metadata

Assignees

Type

No type

Fields

No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions