Update ccnews_split.py
Browse files- ccnews_split.py +2 -1
ccnews_split.py
CHANGED
@@ -18,6 +18,7 @@
|
|
18 |
|
19 |
import json
|
20 |
import os
|
|
|
21 |
from fnmatch import fnmatch
|
22 |
|
23 |
import datasets
|
@@ -119,7 +120,7 @@ class CCNews(datasets.GeneratorBasedBuilder):
|
|
119 |
archive = dl_manager.download(_DOWNLOAD_URL)
|
120 |
|
121 |
return [
|
122 |
-
datasets.SplitGenerator(name=datasets.Split.TRAIN, gen_kwargs={"files":
|
123 |
]
|
124 |
|
125 |
def _generate_examples(self, files):
|
|
|
18 |
|
19 |
import json
|
20 |
import os
|
21 |
+
import tarfile
|
22 |
from fnmatch import fnmatch
|
23 |
|
24 |
import datasets
|
|
|
120 |
archive = dl_manager.download(_DOWNLOAD_URL)
|
121 |
|
122 |
return [
|
123 |
+
datasets.SplitGenerator(name=datasets.Split.TRAIN, gen_kwargs={"files": custom_iter_archive(archive)}),
|
124 |
]
|
125 |
|
126 |
def _generate_examples(self, files):
|