gabrielaltay
commited on
Commit
•
8895663
1
Parent(s):
9ff4a0e
use all files
Browse files- hacdc-wikipedia.py +1 -4
hacdc-wikipedia.py
CHANGED
@@ -139,10 +139,8 @@ class HacdcWikimedia20220901(datasets.GeneratorBasedBuilder):
|
|
139 |
|
140 |
def _split_generators(self, dl_manager):
|
141 |
|
142 |
-
paths = [os.path.join("data", _FILES
|
143 |
downloaded_files = dl_manager.download_and_extract(paths)
|
144 |
-
print("PATHS", paths)
|
145 |
-
print("DLFILES", downloaded_files)
|
146 |
return [
|
147 |
datasets.SplitGenerator(name="every", gen_kwargs={"filepaths": downloaded_files}),
|
148 |
]
|
@@ -158,7 +156,6 @@ class HacdcWikimedia20220901(datasets.GeneratorBasedBuilder):
|
|
158 |
_id = 0
|
159 |
for filepath in filepaths:
|
160 |
logger.info("generating examples from = %s", filepath)
|
161 |
-
print("FP", filepath)
|
162 |
with open(filepath, "r") as fp:
|
163 |
for line in fp:
|
164 |
data = json.loads(line)
|
|
|
139 |
|
140 |
def _split_generators(self, dl_manager):
|
141 |
|
142 |
+
paths = [os.path.join("data", filename) for filename in _FILES]
|
143 |
downloaded_files = dl_manager.download_and_extract(paths)
|
|
|
|
|
144 |
return [
|
145 |
datasets.SplitGenerator(name="every", gen_kwargs={"filepaths": downloaded_files}),
|
146 |
]
|
|
|
156 |
_id = 0
|
157 |
for filepath in filepaths:
|
158 |
logger.info("generating examples from = %s", filepath)
|
|
|
159 |
with open(filepath, "r") as fp:
|
160 |
for line in fp:
|
161 |
data = json.loads(line)
|