Cloud-Pipelines / pipeline-editor

Cloud Pipelines Editor is a web app that allows the users to build and run Machine Learning pipelines without having to set up development environment.
https://cloud-pipelines.net/pipeline-editor/
Apache License 2.0
55 stars 7 forks source link

Visualizations and Metrics not showing #2

Open MatthiasCarnein opened 1 year ago

MatthiasCarnein commented 1 year ago

When using components that generate metrics or visualizations, they are not picked up and shown in the Kubeflow Pipelines UI ( https://www.kubeflow.org/docs/components/pipelines/v1/sdk/output-viewer/#v1-sdk-writing-out-metadata-for-the-output-viewers ).

Expected Result: taxi-tip-confusion-matrix-step-output

The issue seems to be that Kubeflow Pipelines expects the name of the artifact to be mlpipeline-ui-metadata or mlpipeline-metrics whereas Cloud Pipelines Editor names the artifact mlpipeline_ui_metadata or mlpipeline_metrics (underscore instead of hyphen). After renaming the artifact, the visualizations and metrics are successfully displayed in the UI.


Thank you for all your work on Cloud Pipelines Editor! It's a great addition to the Kubeflow ecosystem.

Ark-kun commented 1 year ago

Thank you for the bug report.

Interesting. Those visualizations and their artifacts were so hacky in KFP... Hacks in the SDK, hacks in the backend...

I guess I'll have to add a hack in the Pipeline Editor to rename them. Alternatively we could fix the components themselves to have the expected output artifact names.

BTW, how do you prefer adding your components to the Pipeline Editor? "User components"? Overriding the main component library?

MatthiasCarnein commented 1 year ago

I agree, KFP is definitely doing some magic with the artifact names. It seems that the KFP SDK translates the artifact name mlpipeline_ui_metadata to mlpipeline-ui-metadata when compiling a pipeline.

Unfortunately, fixing the component definitions themselves is probably difficult. In my case, many components are generated by create_component_from_func() / func_to_container_op() which only generate the underscore names (mlpipeline_ui_metadata).

BTW, how do you prefer adding your components to the Pipeline Editor? "User components"? Overriding the main component library?

We have built up an internal repository of KFP components which we used to override the main component library.