Datasets:
Update higgs.py
Browse files
higgs.py
CHANGED
@@ -1,4 +1,4 @@
|
|
1 |
-
"""Higgs
|
2 |
|
3 |
from typing import List
|
4 |
|
@@ -111,9 +111,6 @@ class Higgs(datasets.GeneratorBasedBuilder):
|
|
111 |
|
112 |
|
113 |
def _info(self):
|
114 |
-
if self.config.name not in features_per_config:
|
115 |
-
raise ValueError(f"Unknown configuration: {self.config.name}")
|
116 |
-
|
117 |
info = datasets.DatasetInfo(description=DESCRIPTION, citation=_CITATION, homepage=_HOMEPAGE,
|
118 |
features=features_per_config[self.config.name])
|
119 |
|
@@ -137,7 +134,4 @@ class Higgs(datasets.GeneratorBasedBuilder):
|
|
137 |
|
138 |
|
139 |
def preprocess(self, data: pandas.DataFrame, config: str = "higgs") -> pandas.DataFrame:
|
140 |
-
|
141 |
-
return data[list(features_types_per_config[config].keys())]
|
142 |
-
else:
|
143 |
-
raise ValueError(f"Unknown config: {config}")
|
|
|
1 |
+
"""Higgs."""
|
2 |
|
3 |
from typing import List
|
4 |
|
|
|
111 |
|
112 |
|
113 |
def _info(self):
|
|
|
|
|
|
|
114 |
info = datasets.DatasetInfo(description=DESCRIPTION, citation=_CITATION, homepage=_HOMEPAGE,
|
115 |
features=features_per_config[self.config.name])
|
116 |
|
|
|
134 |
|
135 |
|
136 |
def preprocess(self, data: pandas.DataFrame, config: str = "higgs") -> pandas.DataFrame:
|
137 |
+
return data[list(features_types_per_config[config].keys())]
|
|
|
|
|
|