-
Notifications
You must be signed in to change notification settings - Fork 909
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Vizro Discussion #2898
Comments
Moved to 30/8 |
For more information on the VizX integration with Kedro-viz, please refer to this issue: kedro-viz issue #1457. First Part of Technical Design: Learning and Introduction
Second Part of Technical Design: Integration DiscussionWe aim to explore the methods for integrating VizX with Kedro. There are two primary user journeys to consider:
To address these user journeys, we're evaluating the following options:
|
Integration Methods for VizX and Kedro/Kedro-Viz1. Seamless Integration with VizXOverview:
Pros:
Cons:
2. Independent VizX IntegrationOverview:
Pros:
Cons:
3. Kedro-Viz Support for Generic Applications(Technical feasibility still under investigation) Overview:
Pros:
Cons:
|
3! 3! 3! I can't find the issue, but I've wanted it for ages - especially if you can expose the session and catalog programmatically to any generic application |
Could you elaborate? |
Keep it separate. There are already calls to further componentize Kedro core (e.g. separate Kedro data catalog so it can be used independently); this would do the opposite, for something that's not core to every Kedro workflow (a lot of data pipelines may not require visualization, especially in production).
Strong preference for #2. If you want the most flexible way to build and serve plots, and have a way to do so linked with your Kedro pipeline, it would make sense to not be forced to do it via Kedro-Viz. I would imagine there are a lot of use cases where people want a hosted dashboard (e.g. maybe as part of a website) powered by some data coming from Kedro, but it's very unlikely IMO they would want to see all of Kedro-Viz there. A more "cohesive" experience for showing plots via Kedro-Viz could, at some later point, leverage the above integration/plugin, but I don't see this as a priority. |
If tools can access the catalog data and session metadata via an API then they can do lots of things without creating their own session. |
True, so that part is already available. VizX has already built it's own Kedro intergration which allows it to access the Kedro catalog and run the dashboard which can be hosted or integrated elsewhere. the above is specifically for running VizX inside Kedro-viz. |
Oh, that's good to know. In that case, I don't have a particularly strong opinion; I don't particularly have anything against #1 even, as long as the additional config handling is in Kedro-Viz (i.e. Kedro core should not explicitly load I also personally don't see this as a high priority, since I am not aware of users asking to see dashboards in Kedro-Viz, UNLESS it's clear to the Kedro-Viz team that doing so would increase adoption of Kedro-Viz. There seems to be some "evidence markers" in kedro-org/kedro-viz#1457 to support that, but they're all around translators? From the same issue:
I may be missing some context, but why should translators show Kedro-Viz in stakeholder conversations? It seems perfectly reasonable to me that they should show the dashboard. I've only really seen Kedro-Viz used with clients to show progress ("look at how our baby pipeline has grown up over the past few months", "see how we connect to your various data sources") and highlight the work of data scientists and engineers; I have not personally seen it used in conversations to showcase insights, because a dashboard is the better choice there, and it doesn't necessarily need to live in Kedro-Viz. |
Both 1 & 2 seems like a tight couple with kedro to me. (1) requires dumping stuff in
Kedro-viz already integrated with Kedro so |
* |
I want to understand this more. What would the user journey look like? where would they define the path to vizro_app? |
Summary from the last tech discussion
@idanov mentioned building this using plugins (kedro/ vizro/ kedro-viz plugins?) which we are currently investigating.
|
The three approaches have some overlap with each other and the final solution is likely a mix of them (i.e. for example we could take approach 1 but still enable integration with streamlit or vizro). It would help us to understand better by looking at the following dimension and see what is possible or not possible with each approach.
|
Thanks @noklam for this - above questions are exactly what we need to discuss in our next technical design session. |
A user was asking today whether there's a way to "automate the dashboard creation using VizX". This is an interesting use case we could look into. For example, something like # catalog.yaml
input_data:
type: polars.GenericDataset
format: parquet
filepath: data/03_primary/data.pq
dashboard:
type: vizro.VizroDataset
filepath: data/08_reporting/dashboard.yaml # nodes.py
import vizro.models as vm
import polars as pl
def create_dashboard(input_data: pl.DataFrame) -> pl.Dashboard:
page = ...
dashboard = vm.Dashboard(pages=[page])
return dashboard But this assumes a dashboard built from Vizro pydantic models can be serialized to YAML or JSON (couldn't verify that from the docs) and also the resulting YAML needs a Python script to load it and run it: https://vizro.readthedocs.io/en/latest/pages/user_guides/dashboard/ # app.py
from pathlib import Path
import yaml
import vizro.plotly.express as px
from vizro import Vizro
from vizro.managers import data_manager
from vizro.models import Dashboard
data_manager["iris"] = px.data.iris
dashboard = yaml.safe_load(Path("dashboard.yaml").read_text(encoding="utf-8"))
dashboard = Dashboard(**dashboard)
if __name__ == "__main__":
Vizro().build(dashboard).run() |
Hi all! @noklam pointed me this way and asked me to share some messages I wrote in the slack relating to kedro/vizro integration Some months back I experimented with using the kedro datacatalog as a dataloader for streamlit dashboards. It worked very well by allowing me to build a dropdown which would return the selected dataset to then be visualized in different ways. It was useful for building reusable mini-dashboards and my idea was to try to include an app/ in every kedro project which would automatically provide some basic visualizations out of the box. I didn't get to that stage, but I am convinced a clean datacatalog integration, including some prebuilt components like the one I mentioned for the dropdown would be a highly valuable tool. I also briefly considered using kedro pipelines as the source of transformation steps for the actual running dashboard but 1. it was too complex, 2. it introduced too much overhead for streamlit's constant recalculation of stuff and 3. it simply did not add that much functionality beyond just using the datacatalog and doing the final filtering on the streamlit side. I'm sure y'all will come up with a much cleaner integration than that. |
@inigohidalgo that is awesome, I had a similar idea of providing some out-of-the-box visualisations using vizro in kedro-viz. Could i reach out to you to understand more when we start research on this? 😊 |
EDA would be a very good out-of-box-visualisation. |
Sure :) |
Summary of what was discussed in technical design today: -
|
Closing this, because the initial discussions are completed. A new issue should be opened when more decisions need to be made. |
Description
Placeholder ticket to be filled in by @rashidakanchwala for the VizX Tech Discussion on 23/8
Aim of the discussion
Context
Pre-reading
Other useful links
The text was updated successfully, but these errors were encountered: