Gaëtan Caillaut
commited on
Commit
·
b9e027e
1
Parent(s):
33b386f
Store labels in ClassLabel class
Browse files
cora.py
CHANGED
@@ -52,7 +52,7 @@ class CoraDataset(datasets.GeneratorBasedBuilder):
|
|
52 |
"""
|
53 |
This dataset is the MNIST equivalent in graph learning and we explore it somewhat explicitly here in function of other articles using again and again this dataset as a testbed."""
|
54 |
|
55 |
-
VERSION = datasets.Version("1.0.
|
56 |
|
57 |
# This is an example of a dataset with multiple configurations.
|
58 |
# If you don't want/need to define several sub-sets in your dataset,
|
@@ -84,7 +84,15 @@ class CoraDataset(datasets.GeneratorBasedBuilder):
|
|
84 |
for i in range(1433)
|
85 |
}
|
86 |
features_dict["node"] = datasets.Value("string")
|
87 |
-
features_dict["label"] = datasets.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
88 |
features_dict["neighbors"] = datasets.Sequence(
|
89 |
datasets.Value("string")
|
90 |
)
|
|
|
52 |
"""
|
53 |
This dataset is the MNIST equivalent in graph learning and we explore it somewhat explicitly here in function of other articles using again and again this dataset as a testbed."""
|
54 |
|
55 |
+
VERSION = datasets.Version("1.0.1")
|
56 |
|
57 |
# This is an example of a dataset with multiple configurations.
|
58 |
# If you don't want/need to define several sub-sets in your dataset,
|
|
|
84 |
for i in range(1433)
|
85 |
}
|
86 |
features_dict["node"] = datasets.Value("string")
|
87 |
+
features_dict["label"] = datasets.ClassLabel(names=[
|
88 |
+
"Case_Based",
|
89 |
+
"Genetic_Algorithms",
|
90 |
+
"Neural_Networks",
|
91 |
+
"Probabilistic_Methods",
|
92 |
+
"Reinforcement_Learning",
|
93 |
+
"Rule_Learning",
|
94 |
+
"Theory"
|
95 |
+
])
|
96 |
features_dict["neighbors"] = datasets.Sequence(
|
97 |
datasets.Value("string")
|
98 |
)
|