We have introduced custom dataset preview for our users allowing them to implement preview method. However, the documentation needs to be updated with some details regarding the expected dict schema and also add some validation for the NewTypes (eg., TablePreview).
index - An array of 0 indexed integers representing nrows
columns - An array of strings representing names of ncolumns
data - A 2D array representing data for the TablePreview
Description
We have introduced custom dataset preview for our users allowing them to implement
preview
method. However, the documentation needs to be updated with some details regarding the expected dict schema and also add some validation for the NewTypes (eg., TablePreview).Context
https://github.com/kedro-org/kedro-viz/issues/1847#issuecomment-2086213105
Possible Implementation
preview
function should match one of the following typesKedro-Viz expects the dict should contain the below schema -
TablePreview :
index - An array of 0 indexed integers representing nrows columns - An array of strings representing names of ncolumns data - A 2D array representing data for the TablePreview
Example -
Catalog -
TablePreview value returned from
preview()
function -NOTE: This ticket needs to be updated with schema details of other return types (ImagePreview, PlotlyPreview, JSONPreview) for reference
Possible Alternatives
Checklist