Datasets:
Tasks:
Question Answering
Languages:
English
Size:
10K<n<100K
ArXiv:
Tags:
multihop-tabular-text-qa
License:
Commit
•
2962e06
1
Parent(s):
ad22bfa
Skip missing JSON files (#6)
Browse files- Skip missing JSON files (d1ca539b4851b068c0e38d0f6b7b4a93434cad1c)
- hybrid_qa.py +7 -4
hybrid_qa.py
CHANGED
@@ -139,10 +139,13 @@ class HybridQa(datasets.GeneratorBasedBuilder):
|
|
139 |
table_file_path = os.path.join(tables_path, f"{table_id}.json")
|
140 |
url_data_path = os.path.join(requests_path, f"{table_id}.json")
|
141 |
|
142 |
-
|
143 |
-
|
144 |
-
|
145 |
-
|
|
|
|
|
|
|
146 |
|
147 |
table["header"] = [header[0] for header in table["header"]]
|
148 |
|
|
|
139 |
table_file_path = os.path.join(tables_path, f"{table_id}.json")
|
140 |
url_data_path = os.path.join(requests_path, f"{table_id}.json")
|
141 |
|
142 |
+
try:
|
143 |
+
with open(table_file_path, encoding="utf-8") as f:
|
144 |
+
table = json.load(f)
|
145 |
+
with open(url_data_path, encoding="utf-8") as f:
|
146 |
+
url_data = json.load(f)
|
147 |
+
except KeyError: # Some JSON files were not properly added to the GitHub repo: filenames with ':', '"'
|
148 |
+
continue
|
149 |
|
150 |
table["header"] = [header[0] for header in table["header"]]
|
151 |
|