Datasets:
Tasks:
Text Classification
Modalities:
Text
Formats:
parquet
Sub-tasks:
topic-classification
Languages:
Burmese
Size:
1K - 10K
License:
Commit
•
88414fe
0
Parent(s):
Update files from the datasets library (from 1.2.0)
Browse filesRelease notes: https://github.com/huggingface/datasets/releases/tag/1.2.0
- .gitattributes +27 -0
- README.md +70 -0
- dataset_infos.json +1 -0
- dummy/1.0.1/dummy_data.zip +3 -0
- myanmar_news.py +82 -0
.gitattributes
ADDED
@@ -0,0 +1,27 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
*.7z filter=lfs diff=lfs merge=lfs -text
|
2 |
+
*.arrow filter=lfs diff=lfs merge=lfs -text
|
3 |
+
*.bin filter=lfs diff=lfs merge=lfs -text
|
4 |
+
*.bin.* filter=lfs diff=lfs merge=lfs -text
|
5 |
+
*.bz2 filter=lfs diff=lfs merge=lfs -text
|
6 |
+
*.ftz filter=lfs diff=lfs merge=lfs -text
|
7 |
+
*.gz filter=lfs diff=lfs merge=lfs -text
|
8 |
+
*.h5 filter=lfs diff=lfs merge=lfs -text
|
9 |
+
*.joblib filter=lfs diff=lfs merge=lfs -text
|
10 |
+
*.lfs.* filter=lfs diff=lfs merge=lfs -text
|
11 |
+
*.model filter=lfs diff=lfs merge=lfs -text
|
12 |
+
*.msgpack filter=lfs diff=lfs merge=lfs -text
|
13 |
+
*.onnx filter=lfs diff=lfs merge=lfs -text
|
14 |
+
*.ot filter=lfs diff=lfs merge=lfs -text
|
15 |
+
*.parquet filter=lfs diff=lfs merge=lfs -text
|
16 |
+
*.pb filter=lfs diff=lfs merge=lfs -text
|
17 |
+
*.pt filter=lfs diff=lfs merge=lfs -text
|
18 |
+
*.pth filter=lfs diff=lfs merge=lfs -text
|
19 |
+
*.rar filter=lfs diff=lfs merge=lfs -text
|
20 |
+
saved_model/**/* filter=lfs diff=lfs merge=lfs -text
|
21 |
+
*.tar.* filter=lfs diff=lfs merge=lfs -text
|
22 |
+
*.tflite filter=lfs diff=lfs merge=lfs -text
|
23 |
+
*.tgz filter=lfs diff=lfs merge=lfs -text
|
24 |
+
*.xz filter=lfs diff=lfs merge=lfs -text
|
25 |
+
*.zip filter=lfs diff=lfs merge=lfs -text
|
26 |
+
*.zstandard filter=lfs diff=lfs merge=lfs -text
|
27 |
+
*tfevents* filter=lfs diff=lfs merge=lfs -text
|
README.md
ADDED
@@ -0,0 +1,70 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
---
|
2 |
+
annotations_creators: []
|
3 |
+
language_creators: []
|
4 |
+
languages:
|
5 |
+
- my
|
6 |
+
licenses:
|
7 |
+
- gpl-3-0
|
8 |
+
multilinguality:
|
9 |
+
- monolingual
|
10 |
+
size_categories:
|
11 |
+
- 1K<n<10K
|
12 |
+
source_datasets:
|
13 |
+
- original
|
14 |
+
task_categories:
|
15 |
+
- text-classification
|
16 |
+
task_ids:
|
17 |
+
- topic-classification
|
18 |
+
---
|
19 |
+
|
20 |
+
# Dataset Card for Myanmar_News
|
21 |
+
|
22 |
+
## Dataset Description
|
23 |
+
|
24 |
+
- **Repository: ** https://github.com/ayehninnkhine/MyanmarNewsClassificationSystem
|
25 |
+
|
26 |
+
### Dataset Summary
|
27 |
+
|
28 |
+
The Myanmar news dataset contains article snippets in four categories:
|
29 |
+
Business, Entertainment, Politics, and Sport.
|
30 |
+
|
31 |
+
These were collected in October 2017 by Aye Hninn Khine
|
32 |
+
|
33 |
+
### Languages
|
34 |
+
|
35 |
+
Myanmar/Burmese language
|
36 |
+
|
37 |
+
## Dataset Structure
|
38 |
+
|
39 |
+
### Data Fields
|
40 |
+
|
41 |
+
- text - text from article
|
42 |
+
- category - a topic: Business, Entertainment, **Politic**, or **Sport** (note spellings)
|
43 |
+
|
44 |
+
### Data Splits
|
45 |
+
|
46 |
+
One training set (8,116 total rows)
|
47 |
+
|
48 |
+
### Source Data
|
49 |
+
|
50 |
+
#### Initial Data Collection and Normalization
|
51 |
+
|
52 |
+
Data was collected by Aye Hninn Khine
|
53 |
+
and shared on GitHub with a GPL-3.0 license.
|
54 |
+
|
55 |
+
Multiple text files were consolidated into one labeled CSV file by Nick Doiron.
|
56 |
+
|
57 |
+
## Additional Information
|
58 |
+
|
59 |
+
### Dataset Curators
|
60 |
+
|
61 |
+
Contributors to original GitHub repo:
|
62 |
+
- https://github.com/ayehninnkhine
|
63 |
+
|
64 |
+
### Licensing Information
|
65 |
+
|
66 |
+
GPL-3.0
|
67 |
+
|
68 |
+
### Citation Information
|
69 |
+
|
70 |
+
See https://github.com/ayehninnkhine/MyanmarNewsClassificationSystem
|
dataset_infos.json
ADDED
@@ -0,0 +1 @@
|
|
|
|
|
1 |
+
{"default": {"description": "The Myanmar news dataset contains article snippets in four categories:\nBusiness, Entertainment, Politics, and Sport.\n\nThese were collected in October 2017 by Aye Hninn Khine\n", "citation": "", "homepage": "https://github.com/ayehninnkhine/MyanmarNewsClassificationSystem", "license": "GPL-3.0", "features": {"text": {"dtype": "string", "id": null, "_type": "Value"}, "category": {"num_classes": 4, "names": ["Sport", "Politic", "Business", "Entertainment"], "names_file": null, "id": null, "_type": "ClassLabel"}}, "post_processed": null, "supervised_keys": null, "builder_name": "myanmar_news", "config_name": "default", "version": {"version_str": "1.0.1", "description": null, "major": 1, "minor": 0, "patch": 1}, "splits": {"train": {"name": "train", "num_bytes": 3797368, "num_examples": 8116, "dataset_name": "myanmar_news"}}, "download_checksums": {"https://github.com/Georeactor/MyanmarNewsClassificationSystem/archive/main.zip": {"num_bytes": 610592, "checksum": "e0558e4ea389aee3a31a4b9eb86160ded8c3bde776723177bc08dd4d20c8d980"}}, "download_size": 610592, "post_processing_size": null, "dataset_size": 3797368, "size_in_bytes": 4407960}}
|
dummy/1.0.1/dummy_data.zip
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:2a2e2099e1dd5dc8bdbc59878f9c75934460fa1a82f3c5848a00af5a19886caa
|
3 |
+
size 1307
|
myanmar_news.py
ADDED
@@ -0,0 +1,82 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
# coding=utf-8
|
2 |
+
# Copyright 2020 The HuggingFace Datasets Authors and the current dataset script contributor.
|
3 |
+
#
|
4 |
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
5 |
+
# you may not use this file except in compliance with the License.
|
6 |
+
# You may obtain a copy of the License at
|
7 |
+
#
|
8 |
+
# http://www.apache.org/licenses/LICENSE-2.0
|
9 |
+
#
|
10 |
+
# Unless required by applicable law or agreed to in writing, software
|
11 |
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
12 |
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
13 |
+
# See the License for the specific language governing permissions and
|
14 |
+
# limitations under the License.
|
15 |
+
|
16 |
+
from __future__ import absolute_import, division, print_function
|
17 |
+
|
18 |
+
import csv
|
19 |
+
import os
|
20 |
+
|
21 |
+
import datasets
|
22 |
+
|
23 |
+
|
24 |
+
# no BibTeX citation
|
25 |
+
_CITATION = ""
|
26 |
+
|
27 |
+
_DESCRIPTION = """\
|
28 |
+
The Myanmar news dataset contains article snippets in four categories:
|
29 |
+
Business, Entertainment, Politics, and Sport.
|
30 |
+
|
31 |
+
These were collected in October 2017 by Aye Hninn Khine
|
32 |
+
"""
|
33 |
+
|
34 |
+
_LICENSE = "GPL-3.0"
|
35 |
+
|
36 |
+
_URLs = {"default": "https://github.com/Georeactor/MyanmarNewsClassificationSystem/archive/main.zip"}
|
37 |
+
|
38 |
+
|
39 |
+
class MyanmarNews(datasets.GeneratorBasedBuilder):
|
40 |
+
VERSION = datasets.Version("1.0.1")
|
41 |
+
|
42 |
+
def _info(self):
|
43 |
+
class_names = ["Sport", "Politic", "Business", "Entertainment"]
|
44 |
+
features = datasets.Features(
|
45 |
+
{
|
46 |
+
"text": datasets.Value("string"),
|
47 |
+
"category": datasets.ClassLabel(names=class_names),
|
48 |
+
}
|
49 |
+
)
|
50 |
+
return datasets.DatasetInfo(
|
51 |
+
description=_DESCRIPTION,
|
52 |
+
features=features,
|
53 |
+
supervised_keys=None,
|
54 |
+
homepage="https://github.com/ayehninnkhine/MyanmarNewsClassificationSystem",
|
55 |
+
license=_LICENSE,
|
56 |
+
citation=_CITATION,
|
57 |
+
)
|
58 |
+
|
59 |
+
def _split_generators(self, dl_manager):
|
60 |
+
my_urls = _URLs[self.config.name]
|
61 |
+
data_dir = dl_manager.download_and_extract(my_urls)
|
62 |
+
return [
|
63 |
+
datasets.SplitGenerator(
|
64 |
+
name=datasets.Split.TRAIN,
|
65 |
+
gen_kwargs={
|
66 |
+
"filepath": os.path.join(data_dir, "MyanmarNewsClassificationSystem-main", "topics.csv"),
|
67 |
+
"split": "train",
|
68 |
+
},
|
69 |
+
),
|
70 |
+
]
|
71 |
+
|
72 |
+
def _generate_examples(self, filepath, split):
|
73 |
+
with open(filepath, encoding="utf-8") as f:
|
74 |
+
rdr = csv.reader(f, delimiter="\t")
|
75 |
+
next(rdr)
|
76 |
+
rownum = 0
|
77 |
+
for row in rdr:
|
78 |
+
rownum += 1
|
79 |
+
yield rownum, {
|
80 |
+
"text": row[0],
|
81 |
+
"category": row[1],
|
82 |
+
}
|