Commit ·
ebc4cd2
1
Parent(s): 631f2a3
Upload buster.py (#8)
Browse files- Upload buster.py (6d81f96bc4b0422f7f016a718645c1b8528092c5)
Co-authored-by: Andrea Zugarini <azugarini@users.noreply.huggingface.co>
buster.py
CHANGED
|
@@ -108,6 +108,7 @@ class Buster(datasets.GeneratorBasedBuilder):
|
|
| 108 |
|
| 109 |
def _generate_examples(self, file_path):
|
| 110 |
dataset = load_dataset("json", data_files=file_path)
|
|
|
|
| 111 |
logger.info(f"Generating examples from: {file_path}")
|
| 112 |
for idx, example in enumerate(dataset["train"]):
|
| 113 |
# example features: document_id, tokens, labels
|
|
|
|
| 108 |
|
| 109 |
def _generate_examples(self, file_path):
|
| 110 |
dataset = load_dataset("json", data_files=file_path)
|
| 111 |
+
dataset = dataset.remove_columns(["positions"])
|
| 112 |
logger.info(f"Generating examples from: {file_path}")
|
| 113 |
for idx, example in enumerate(dataset["train"]):
|
| 114 |
# example features: document_id, tokens, labels
|