fix extraction target
Browse files
spanish_passage_retrieval.py
CHANGED
@@ -80,8 +80,8 @@ class PRES(datasets.GeneratorBasedBuilder):
|
|
80 |
|
81 |
if not self._data:
|
82 |
with tempfile.TemporaryDirectory() as tmpdir:
|
83 |
-
|
84 |
-
|
85 |
|
86 |
with open(os.path.join(extracted_path, 'docs.json')) as f:
|
87 |
docs = json.load(f)
|
|
|
80 |
|
81 |
if not self._data:
|
82 |
with tempfile.TemporaryDirectory() as tmpdir:
|
83 |
+
patoolib.extract_archive(archive, outdir=tmpdir)
|
84 |
+
extracted_path = os.path.join(tmpdir, 'PRES Dataset')
|
85 |
|
86 |
with open(os.path.join(extracted_path, 'docs.json')) as f:
|
87 |
docs = json.load(f)
|