Update mc4_validation.py
Browse files- mc4_validation.py +2 -4
mc4_validation.py
CHANGED
@@ -9,7 +9,7 @@ import datasets
|
|
9 |
|
10 |
logger = datasets.logging.get_logger(__name__)
|
11 |
|
12 |
-
|
13 |
_DESCRIPTION = """\
|
14 |
A colossal, cleaned version of Common Crawl's web crawl corpus.
|
15 |
|
@@ -276,7 +276,7 @@ class Mc4ValidationConfig(datasets.BuilderConfig):
|
|
276 |
class Mc4Validation(datasets.GeneratorBasedBuilder):
|
277 |
"""mC4, a colossal, cleaned version of Common Crawl's web crawl corpus."""
|
278 |
|
279 |
-
BUILDER_CONFIGS = [Mc4ValidationConfig(languages=[lang]) for lang in _LANGUAGES]
|
280 |
BUILDER_CONFIG_CLASS = Mc4ValidationConfig
|
281 |
|
282 |
def _info(self):
|
@@ -307,10 +307,8 @@ class Mc4Validation(datasets.GeneratorBasedBuilder):
|
|
307 |
for lang in self.config.languages
|
308 |
for index in range(_N_SHARDS_PER_SPLIT[lang][split])
|
309 |
]
|
310 |
-
train_downloaded_files = dl_manager.download(data_urls["train"])
|
311 |
validation_downloaded_files = dl_manager.download(data_urls["validation"])
|
312 |
return [
|
313 |
-
datasets.SplitGenerator(name=datasets.Split.TRAIN, gen_kwargs={"filepaths": train_downloaded_files}),
|
314 |
datasets.SplitGenerator(
|
315 |
name=datasets.Split.VALIDATION, gen_kwargs={"filepaths": validation_downloaded_files}
|
316 |
),
|
|
|
9 |
|
10 |
logger = datasets.logging.get_logger(__name__)
|
11 |
|
12 |
+
_VERSION = "0.0.1"
|
13 |
_DESCRIPTION = """\
|
14 |
A colossal, cleaned version of Common Crawl's web crawl corpus.
|
15 |
|
|
|
276 |
class Mc4Validation(datasets.GeneratorBasedBuilder):
|
277 |
"""mC4, a colossal, cleaned version of Common Crawl's web crawl corpus."""
|
278 |
|
279 |
+
BUILDER_CONFIGS = [Mc4ValidationConfig(languages=[lang], datasets.Version(_VERSION)) for lang in _LANGUAGES]
|
280 |
BUILDER_CONFIG_CLASS = Mc4ValidationConfig
|
281 |
|
282 |
def _info(self):
|
|
|
307 |
for lang in self.config.languages
|
308 |
for index in range(_N_SHARDS_PER_SPLIT[lang][split])
|
309 |
]
|
|
|
310 |
validation_downloaded_files = dl_manager.download(data_urls["validation"])
|
311 |
return [
|
|
|
312 |
datasets.SplitGenerator(
|
313 |
name=datasets.Split.VALIDATION, gen_kwargs={"filepaths": validation_downloaded_files}
|
314 |
),
|