init
Browse files
tweet_topic_multilingual.py
CHANGED
@@ -4,7 +4,7 @@ import datasets
|
|
4 |
|
5 |
logger = datasets.logging.get_logger(__name__)
|
6 |
_DESCRIPTION = """[TweetTopicMultilingual](TBA)"""
|
7 |
-
_VERSION = "0.0.
|
8 |
_CITATION = """TBA"""
|
9 |
_HOME_PAGE = "https://cardiffnlp.github.io"
|
10 |
_NAME = "tweet_topic_multilingual"
|
@@ -54,7 +54,7 @@ class TweetTopicMultilingual(datasets.GeneratorBasedBuilder):
|
|
54 |
_key = 0
|
55 |
logger.info("generating examples from = %s", filepath)
|
56 |
with open(filepath, encoding="utf-8") as f:
|
57 |
-
_list = [json.loads(i) for i in f.read().split('\n') if i]
|
58 |
for i in _list:
|
59 |
yield _key, i
|
60 |
_key += 1
|
|
|
4 |
|
5 |
logger = datasets.logging.get_logger(__name__)
|
6 |
_DESCRIPTION = """[TweetTopicMultilingual](TBA)"""
|
7 |
+
_VERSION = "0.0.3"
|
8 |
_CITATION = """TBA"""
|
9 |
_HOME_PAGE = "https://cardiffnlp.github.io"
|
10 |
_NAME = "tweet_topic_multilingual"
|
|
|
54 |
_key = 0
|
55 |
logger.info("generating examples from = %s", filepath)
|
56 |
with open(filepath, encoding="utf-8") as f:
|
57 |
+
_list = [json.loads(i) for i in f.read().split('\n') if len(i) > 0]
|
58 |
for i in _list:
|
59 |
yield _key, i
|
60 |
_key += 1
|