Datasets:
pain
/

Languages:
Arabic
ArXiv:
License:
File size: 2,945 Bytes
b7af895
 
769d07b
b7af895
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
769d07b
b7af895
 
 
 
e6b9ea6
b7af895
 
 
 
 
 
 
 
 
 
769d07b
b7af895
 
 
 
 
 
 
 
 
 
 
 
 
 
 
769d07b
 
 
ae6de76
769d07b
b7af895
769d07b
 
 
 
 
 
 
 
fd41fe2
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
import datasets
from datasets.tasks import ImageClassification
import os

_CITATION = """\
@misc{https://doi.org/10.48550/arxiv.2301.11932,
  doi = {10.48550/ARXIV.2301.11932},
  
  url = {https://arxiv.org/abs/2301.11932},
  
  author = {Al-Barham, Muhammad and Alsharkawi, Adham and Al-Yaman, Musa and Al-Fetyani, Mohammad and Elnagar, Ashraf and SaAleek, Ahmad Abu and Al-Odat, Mohammad},
  
  keywords = {Computer Vision and Pattern Recognition (cs.CV), FOS: Computer and information sciences, FOS: Computer and information sciences},
  
  title = {RGB Arabic Alphabets Sign Language Dataset},
  
  publisher = {arXiv},
  
  year = {2023},
  
  copyright = {Creative Commons Attribution 4.0 International}
}
"""

_DESCRIPTION = "RGB Arabic Alphabet Sign Language (AASL) dataset comprises 7,857 raw and fully labelled RGB images of the Arabic sign language alphabets, which to our best knowledge is the first publicly available RGB dataset. The dataset is aimed to help those interested in developing real-life Arabic sign language classification models. AASL was collected from more than 200 participants and with different settings such as lighting, background, image orientation, image size, and image resolution. Experts in the field supervised, validated and filtered the collected images to ensure a high-quality dataset." 
_URL = "https://huggingface.co/datasets/pain/AASL/blob/main/images.zip"
_HOMEPAGE = "https://www.kaggle.com/datasets/muhammadalbrham/rgb-arabic-alphabets-sign-language-dataset"
_LICENSE = "CC BY-SA 4.0"


class AASL(datasets.GeneratorBasedBuilder):
  
  def _info(self):
    
    return datasets.DatasetInfo(

        description=_DESCRIPTION,
        features=datasets.Features(

            {
                "image": datasets.Image(),
                "label": datasets.features.ClassLabel(names=['Ain','Al','Alef','Beh','Dad','Dal','Feh','Ghain','Hah','Heh','Jeem','Kaf','Khah','Laa','Lam','Meem','Noon','Qaf','Reh','Sad','Seen','Sheen','Tah','Teh','Teh_Marbuta','Theh','Waw','Yeh','Zah','Zain'])
            }
        ),
        supervised_keys=("image", "label"),
        homepage=_HOMEPAGE,
        citation=_CITATION,
        task_templates=[
            ImageClassification(
                image_column="image",
                label_column="label"
            )
        ],
        license=_LICENSE
    )
  
  def _split_generators(self, dl_manager):
    archive_path = dl_manager.download(_URL)

    return [datasets.SplitGenerator(
                name=datasets.Split.TRAIN, gen_kwargs={"images":dl_manager.iter_archive(archive_path)}
            )]
  
  def _generate_examples(self, images):

    x = len(list(images))
    print("Length")
    print(x)
    print(images)

    for file_path, file_obj in images:
        if file_path.startswith("images/"):
            yield file_path, {
                "image": {"path": file_path, "bytes": file_obj.read()},
                "label": 'x',
            }