-
Notifications
You must be signed in to change notification settings - Fork 0
/
component.yaml
139 lines (136 loc) · 3.61 KB
/
component.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
name: kubeflow-vega
description: Kubeflow visualization component backed by Vega and Vega-Lite
metadata:
annotations:
kfx.e2.fyi: kubeflow-vega
inputs:
- {
name: data,
type: String,
description: "artifact with the data to visualize (e.g. output file from another kfp op)",
}
- {
name: data_type,
type: String,
description: 'format of the data file: must be one of "json", "csv", "tsv" or "topojson"',
}
- {
name: json_key,
type: String,
default: "",
optional: true,
description: key to extract the data when the data input is a JSON object. The value of the key must be an array of objects.,
}
- {
name: x,
type: String,
default: "",
optional: true,
description: data column (or key) to use to plot the x-axis,
}
- {
name: xtype,
type: String,
default: quantitative,
description: 'data type for the x-axis: must be one of "quantitative", "temporal", "ordinal", or "nominal"',
}
- {
name: xagg,
type: String,
default: "",
optional: true,
description: 'how the data in the x-axis will be aggregated: "count", "mean", "median", "min", "max", or "sum"',
}
- {
name: y,
type: String,
default: "",
optional: true,
description: data column (or key) to use to plot the y-axis,
}
- {
name: ytype,
type: String,
default: quantitative,
description: 'data type for the y-axis: must be one of "quantitative", "temporal", "ordinal", or "nominal"',
}
- {
name: yagg,
type: String,
default: "",
optional: true,
description: 'how the data in the y-axis will be aggregated: "count", "mean", "median", "min", "max", or "sum"',
}
- {
name: spec,
type: String,
default: "",
optional: true,
description: artifact with a Vega or Vega-Lite spec to render.,
}
- {
name: mark,
type: String,
default: "point",
optional: true,
description: 'visual encoding to use to render the data: must be one of "area", "bar", "circle", "line", "point", "rect", "rule", "square", "text", "tick", or "geoshape"',
}
- {
name: height,
type: String,
default: container,
optional: true,
description: Height of the visualization - defaults to container height,
}
- {
name: width,
type: String,
default: container,
optional: true,
description: Width of the visualization - defaults to container width,
}
- { name: interactive, type: Bool, default: true, optional: true }
outputs:
- {
name: mlpipeline_ui_metadata,
type: JsonObject,
description: ui metadata artifact for rendering in kfp ui,
}
implementation:
container:
image: e2fyi/kubeflow-vega:latest
command:
[
node,
/home/kf/dist/index.js,
--dpath,
{ inputPath: data },
--dtype,
{ inputValue: data_type },
--dkey,
{ inputValue: json_key },
--x,
{ inputValue: x },
--xtype,
{ inputValue: xtype },
--xagg,
{ inputValue: xagg },
--y,
{ inputValue: y },
--ytype,
{ inputValue: ytype },
--yagg,
{ inputValue: yagg },
--mark,
{ inputValue: mark },
--width,
{ inputValue: width },
--height,
{ inputValue: height },
--interactive,
{ inputValue: interactive },
--spec,
{ inputPath: spec },
--ui-metadata-path,
{ outputPath: mlpipeline_ui_metadata },
]