Datasets:

Modalities:
Text
ArXiv:
Libraries:
Datasets
License:
sumanthd commited on
Commit
4a60b51
1 Parent(s): 6966028

push updated test sets

Browse files
.gitattributes CHANGED
@@ -52,3 +52,14 @@ saved_model/**/* filter=lfs diff=lfs merge=lfs -text
52
  *.jpg filter=lfs diff=lfs merge=lfs -text
53
  *.jpeg filter=lfs diff=lfs merge=lfs -text
54
  *.webp filter=lfs diff=lfs merge=lfs -text
 
 
 
 
 
 
 
 
 
 
 
 
52
  *.jpg filter=lfs diff=lfs merge=lfs -text
53
  *.jpeg filter=lfs diff=lfs merge=lfs -text
54
  *.webp filter=lfs diff=lfs merge=lfs -text
55
+ data/ta_IndicNER_v1.0.zip filter=lfs diff=lfs merge=lfs -text
56
+ data/te_IndicNER_v1.0.zip filter=lfs diff=lfs merge=lfs -text
57
+ data/bn_IndicNER_v1.0.zip filter=lfs diff=lfs merge=lfs -text
58
+ data/gu_IndicNER_v1.0.zip filter=lfs diff=lfs merge=lfs -text
59
+ data/hi_IndicNER_v1.0.zip filter=lfs diff=lfs merge=lfs -text
60
+ data/or_IndicNER_v1.0.zip filter=lfs diff=lfs merge=lfs -text
61
+ data/pa_IndicNER_v1.0.zip filter=lfs diff=lfs merge=lfs -text
62
+ data/as_IndicNER_v1.0.zip filter=lfs diff=lfs merge=lfs -text
63
+ data/kn_IndicNER_v1.0.zip filter=lfs diff=lfs merge=lfs -text
64
+ data/ml_IndicNER_v1.0.zip filter=lfs diff=lfs merge=lfs -text
65
+ data/mr_IndicNER_v1.0.zip filter=lfs diff=lfs merge=lfs -text
data/.DS_Store ADDED
Binary file (6.15 kB). View file
 
data/as_IndicNER_v1.0.zip ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:98d11a58acf977fcfd514868d6252da185d945842e9da5568c6c5735f5f5efbd
3
+ size 459923
data/bn_IndicNER_v1.0.zip ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:3c09e575448e5273dd7b30e743b0be39e635b73654913b6c54717eae77192aaa
3
+ size 65825444
data/gu_IndicNER_v1.0.zip ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:fb823b9f6cc1ca1863b1e8020a072efbaac0d102bf4901cb8e9a5110cd95a6ee
3
+ size 26560187
data/hi_IndicNER_v1.0.zip ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:051cd8313d55204a84c2e5535147438a8314867c6a772cb45d9f64cb5768fe32
3
+ size 82327771
data/kn_IndicNER_v1.0.zip ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:4348fea022961f3655d3b348be4d4e2cae636068875abb749be04ffd49a0d659
3
+ size 23489518
data/ml_IndicNER_v1.0.zip ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:1f1867602bf9206cb18e4eb6da87933a80428972fdc28ae343e1d2921e409992
3
+ size 36275708
data/mr_IndicNER_v1.0.zip ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:3de32e2fbeda3db78025f419ec132035d32b1d4389265944b7a47855daf810fc
3
+ size 25196650
data/or_IndicNER_v1.0.zip ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:9e9661bc59f3ca4515f24f5103e27d64894c39925f063f41d26df83b07db0b1e
3
+ size 11435526
data/pa_IndicNER_v1.0.zip ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:e54511434ca0e2d5b14bfac1eb30d5cc269a4e82baa3dc66b98a508eacb4496e
3
+ size 33407897
data/ta_IndicNER_v1.0.zip ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:bb7e3d023462a4a61c5823581247f91e9706aada8149048ffac9b7829a8ff867
3
+ size 29707348
data/te_IndicNER_v1.0.zip ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:a9701708b237c0f00f99caa3c1f777f6db20c8e05238e1fa5d1823696a759fc2
3
+ size 25703832
naamapadam-pr.py ADDED
@@ -0,0 +1,93 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import json
2
+ import os
3
+
4
+ import datasets
5
+
6
+ _CITATION = """\
7
+
8
+ """
9
+
10
+ _DESCRIPTION = """\
11
+
12
+ """
13
+ _HOMEPAGE = "https://indicnlp.ai4bharat.org/"
14
+
15
+ _LICENSE = "Creative Commons Attribution-NonCommercial 4.0 International Public License"
16
+
17
+ _URL = "https://huggingface.co/datasets/ai4bharat/naamapadam-pr/resolve/main/data/{}_IndicNER_v{}.zip"
18
+
19
+ _LANGUAGES = ["as", "bn", "gu", "hi", "kn", "ml", "mr", "or", "pa", "ta", "te"]
20
+
21
+
22
+ class NaamapadamPR(datasets.GeneratorBasedBuilder):
23
+ VERSION = datasets.Version("1.0.0")
24
+
25
+ BUILDER_CONFIGS = [
26
+ datasets.BuilderConfig(
27
+ name="{}".format(lang), version=datasets.Version("1.0.0")
28
+ )
29
+ for lang in _LANGUAGES
30
+ ]
31
+
32
+ def _info(self):
33
+ return datasets.DatasetInfo(
34
+ description=_DESCRIPTION,
35
+ features=datasets.Features(
36
+ {
37
+ "tokens": datasets.Sequence(datasets.Value("string")),
38
+ "ner_tags": datasets.Sequence(
39
+ datasets.features.ClassLabel(
40
+ names=[
41
+ "O",
42
+ "B-PER",
43
+ "I-PER",
44
+ "B-ORG",
45
+ "I-ORG",
46
+ "B-LOC",
47
+ "I-LOC",
48
+ ]
49
+ )
50
+ ),
51
+ }
52
+ ),
53
+ supervised_keys=None,
54
+ homepage=_HOMEPAGE,
55
+ citation=_CITATION,
56
+ license=_LICENSE,
57
+ version=self.VERSION,
58
+ )
59
+
60
+ def _split_generators(self, dl_manager):
61
+ """Returns SplitGenerators."""
62
+ lang = str(self.config.name)
63
+ url = _URL.format(lang, self.VERSION.version_str[:-2])
64
+
65
+ data_dir = dl_manager.download_and_extract(url)
66
+
67
+ return [
68
+ datasets.SplitGenerator(
69
+ name=datasets.Split.TRAIN,
70
+ gen_kwargs={
71
+ "filepath": os.path.join(data_dir, lang + "_train.json"),
72
+ },
73
+ ),
74
+ datasets.SplitGenerator(
75
+ name=datasets.Split.TEST,
76
+ gen_kwargs={
77
+ "filepath": os.path.join(data_dir, lang + "_test.json"),
78
+ },
79
+ ),
80
+ datasets.SplitGenerator(
81
+ name=datasets.Split.VALIDATION,
82
+ gen_kwargs={
83
+ "filepath": os.path.join(data_dir, lang + "_val.json"),
84
+ },
85
+ ),
86
+ ]
87
+
88
+ def _generate_examples(self, filepath):
89
+ """Yields examples as (key, example) tuples."""
90
+ with open(filepath, encoding="utf-8") as f:
91
+ for idx_, row in enumerate(f):
92
+ data = json.loads(row)
93
+ yield idx_, {"tokens": data["words"], "ner_tags": data["ner"]}