Update files from the datasets library (from 1.4.0)
Browse filesRelease notes: https://github.com/huggingface/datasets/releases/tag/1.4.0
amttl.py
CHANGED
|
@@ -16,11 +16,12 @@
|
|
| 16 |
# Lint as: python3
|
| 17 |
"""Introduction to AMTTL CWS Dataset"""
|
| 18 |
|
| 19 |
-
import logging
|
| 20 |
-
|
| 21 |
import datasets
|
| 22 |
|
| 23 |
|
|
|
|
|
|
|
|
|
|
| 24 |
_CITATION = """\
|
| 25 |
@inproceedings{xing2018adaptive,
|
| 26 |
title={Adaptive multi-task transfer learning for Chinese word segmentation in medical text},
|
|
@@ -115,7 +116,7 @@ class Amttl(datasets.GeneratorBasedBuilder):
|
|
| 115 |
]
|
| 116 |
|
| 117 |
def _generate_examples(self, filepath):
|
| 118 |
-
|
| 119 |
with open(filepath, encoding="utf-8") as f:
|
| 120 |
guid = 0
|
| 121 |
tokens = []
|
|
|
|
| 16 |
# Lint as: python3
|
| 17 |
"""Introduction to AMTTL CWS Dataset"""
|
| 18 |
|
|
|
|
|
|
|
| 19 |
import datasets
|
| 20 |
|
| 21 |
|
| 22 |
+
logger = datasets.logging.get_logger(__name__)
|
| 23 |
+
|
| 24 |
+
|
| 25 |
_CITATION = """\
|
| 26 |
@inproceedings{xing2018adaptive,
|
| 27 |
title={Adaptive multi-task transfer learning for Chinese word segmentation in medical text},
|
|
|
|
| 116 |
]
|
| 117 |
|
| 118 |
def _generate_examples(self, filepath):
|
| 119 |
+
logger.info("⏳ Generating examples from = %s", filepath)
|
| 120 |
with open(filepath, encoding="utf-8") as f:
|
| 121 |
guid = 0
|
| 122 |
tokens = []
|