Spaces:
Build error
Build error
Try dynamic typing
Browse files- vendiscore.py +10 -7
vendiscore.py
CHANGED
@@ -86,16 +86,19 @@ def get_features(config_name):
|
|
86 |
if config_name in ("text", "default"):
|
87 |
return datasets.Features({"samples": datasets.Value("string")})
|
88 |
if config_name == "image":
|
89 |
-
datasets.Features({"samples": datasets.Image})
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
90 |
return [
|
91 |
datasets.Features({"samples": datasets.Value("int32")}),
|
92 |
-
datasets.Features(
|
93 |
-
{"samples": datasets.Sequence(datasets.Value("int32"))}
|
94 |
-
),
|
95 |
datasets.Features({"samples": datasets.Value("float")}),
|
96 |
-
datasets.Features(
|
97 |
-
{"samples": datasets.Sequence(datasets.Value("float"))}
|
98 |
-
),
|
99 |
datasets.Features({"samples": datasets.Array2D}),
|
100 |
]
|
101 |
|
|
|
86 |
if config_name in ("text", "default"):
|
87 |
return datasets.Features({"samples": datasets.Value("string")})
|
88 |
if config_name == "image":
|
89 |
+
return datasets.Features({"samples": datasets.Image})
|
90 |
+
if config_name in ("K", "X"):
|
91 |
+
return [
|
92 |
+
datasets.Features(
|
93 |
+
{"samples": datasets.Sequence(datasets.Value("int32"))}
|
94 |
+
),
|
95 |
+
datasets.Features(
|
96 |
+
{"samples": datasets.Sequence(datasets.Value("float"))}
|
97 |
+
),
|
98 |
+
]
|
99 |
return [
|
100 |
datasets.Features({"samples": datasets.Value("int32")}),
|
|
|
|
|
|
|
101 |
datasets.Features({"samples": datasets.Value("float")}),
|
|
|
|
|
|
|
102 |
datasets.Features({"samples": datasets.Array2D}),
|
103 |
]
|
104 |
|