Update climate-evaluation.py
Browse files- climate-evaluation.py +4 -3
climate-evaluation.py
CHANGED
@@ -25,7 +25,7 @@ Datasets for Climate Evaluation.
|
|
25 |
|
26 |
_HOMEPAGE = "https://arxiv.org/abs/2401.09646"
|
27 |
|
28 |
-
_URL = "https://huggingface.co/datasets/eci-io/climate-evaluation/blob/main/"
|
29 |
|
30 |
_LICENSE = ""
|
31 |
|
@@ -316,6 +316,7 @@ class ClimateEvaluation(datasets.GeneratorBasedBuilder):
|
|
316 |
features["idx"] = datasets.Value("int32")
|
317 |
else:
|
318 |
if self.config.name == "cdp_qa":
|
|
|
319 |
features = {
|
320 |
text_feature: datasets.Value("string")
|
321 |
for text_feature in self.config.text_features.keys()
|
@@ -527,11 +528,11 @@ class ClimateEvaluation(datasets.GeneratorBasedBuilder):
|
|
527 |
idx = iter(range(100000))
|
528 |
for file in data_file:
|
529 |
yield from self._process_file(file, delimiter="\t", idx=idx)
|
530 |
-
elif self.config.name == "cdp_qa":
|
531 |
# idx = iter(range(10000000))
|
532 |
# print(f"!!!data_file: {data_file}")
|
533 |
# for file in data_file:
|
534 |
-
yield from self._process_file(data_file)
|
535 |
else:
|
536 |
yield from self._process_file(data_file)
|
537 |
|
|
|
25 |
|
26 |
_HOMEPAGE = "https://arxiv.org/abs/2401.09646"
|
27 |
|
28 |
+
# _URL = "https://huggingface.co/datasets/eci-io/climate-evaluation/blob/main/"
|
29 |
|
30 |
_LICENSE = ""
|
31 |
|
|
|
316 |
features["idx"] = datasets.Value("int32")
|
317 |
else:
|
318 |
if self.config.name == "cdp_qa":
|
319 |
+
print(f"self.config.text_features: {self.config.text_features.keys()}")
|
320 |
features = {
|
321 |
text_feature: datasets.Value("string")
|
322 |
for text_feature in self.config.text_features.keys()
|
|
|
528 |
idx = iter(range(100000))
|
529 |
for file in data_file:
|
530 |
yield from self._process_file(file, delimiter="\t", idx=idx)
|
531 |
+
# elif self.config.name == "cdp_qa":
|
532 |
# idx = iter(range(10000000))
|
533 |
# print(f"!!!data_file: {data_file}")
|
534 |
# for file in data_file:
|
535 |
+
# yield from self._process_file(data_file)
|
536 |
else:
|
537 |
yield from self._process_file(data_file)
|
538 |
|