Datasets:
Tasks:
Summarization
Sub-tasks:
news-articles-summarization
Languages:
Indonesian
Size:
100K<n<1M
ArXiv:
Tags:
extractive-summarization
License:
Update files from the datasets library (from 1.16.0)
Browse filesRelease notes: https://github.com/huggingface/datasets/releases/tag/1.16.0
- id_liputan6.py +5 -7
id_liputan6.py
CHANGED
|
@@ -109,23 +109,21 @@ class IdLiputan6(datasets.GeneratorBasedBuilder):
|
|
| 109 |
data_dir = os.path.abspath(os.path.expanduser(dl_manager.manual_dir))
|
| 110 |
if not os.path.exists(data_dir):
|
| 111 |
raise FileNotFoundError(
|
| 112 |
-
"{} does not exist. Make sure you insert a manual dir via `datasets.load_dataset('id_liputan6', "
|
| 113 |
-
"'canonical', data_dir=...)`. Manual download instructions:\n{}"
|
| 114 |
-
data_dir, self.manual_download_instructions
|
| 115 |
-
)
|
| 116 |
)
|
| 117 |
split_generators = [
|
| 118 |
datasets.SplitGenerator(
|
| 119 |
name=datasets.Split.VALIDATION,
|
| 120 |
gen_kwargs={
|
| 121 |
-
"article_dir": os.path.join(data_dir, "{
|
| 122 |
"split": "dev",
|
| 123 |
},
|
| 124 |
),
|
| 125 |
datasets.SplitGenerator(
|
| 126 |
name=datasets.Split.TEST,
|
| 127 |
gen_kwargs={
|
| 128 |
-
"article_dir": os.path.join(data_dir, "{
|
| 129 |
"split": "test",
|
| 130 |
},
|
| 131 |
),
|
|
@@ -135,7 +133,7 @@ class IdLiputan6(datasets.GeneratorBasedBuilder):
|
|
| 135 |
datasets.SplitGenerator(
|
| 136 |
name=datasets.Split.TRAIN,
|
| 137 |
gen_kwargs={
|
| 138 |
-
"article_dir": os.path.join(data_dir, "{
|
| 139 |
"split": "train",
|
| 140 |
},
|
| 141 |
)
|
|
|
|
| 109 |
data_dir = os.path.abspath(os.path.expanduser(dl_manager.manual_dir))
|
| 110 |
if not os.path.exists(data_dir):
|
| 111 |
raise FileNotFoundError(
|
| 112 |
+
f"{data_dir} does not exist. Make sure you insert a manual dir via `datasets.load_dataset('id_liputan6', "
|
| 113 |
+
"'canonical', data_dir=...)`. Manual download instructions:\n{self.manual_download_instructions}"
|
|
|
|
|
|
|
| 114 |
)
|
| 115 |
split_generators = [
|
| 116 |
datasets.SplitGenerator(
|
| 117 |
name=datasets.Split.VALIDATION,
|
| 118 |
gen_kwargs={
|
| 119 |
+
"article_dir": os.path.join(data_dir, f"{self.config.name}/dev"),
|
| 120 |
"split": "dev",
|
| 121 |
},
|
| 122 |
),
|
| 123 |
datasets.SplitGenerator(
|
| 124 |
name=datasets.Split.TEST,
|
| 125 |
gen_kwargs={
|
| 126 |
+
"article_dir": os.path.join(data_dir, f"{self.config.name}/test"),
|
| 127 |
"split": "test",
|
| 128 |
},
|
| 129 |
),
|
|
|
|
| 133 |
datasets.SplitGenerator(
|
| 134 |
name=datasets.Split.TRAIN,
|
| 135 |
gen_kwargs={
|
| 136 |
+
"article_dir": os.path.join(data_dir, f"{self.config.name}/train"),
|
| 137 |
"split": "train",
|
| 138 |
},
|
| 139 |
)
|