| --- |
| language: |
| - zgh |
| - tzm |
| - shi |
| - gha |
| - shy |
| - mzb |
| task_categories: |
| - image-to-text |
| tags: |
| - ocr |
| - tifinagh |
| - tamazight |
| - document-understanding |
| - vision-language |
| pretty_name: Tifinagh OCR 39k |
| size_categories: |
| - 10K<n<100K |
| license: apache-2.0 |
| --- |
| |
| # Tifinagh OCR Dataset (39k Synthetic Samples) |
|
|
| ## ๐ Description |
| This dataset is a comprehensive collection of **39,104 synthetic images** designed for training and evaluating OCR and vision-language models for the **Tifinagh script**. It features a wide variety of fonts, background colors, and text styles in a rectangular format. |
|
|
| ## ๐ Dataset Composition |
| - **39,1K images** in PNG format. |
| - **Diversity:** Includes multiple background/text color combinations and various font styles (from: IRCAM, Tawalt, Madghis Madi). |
| - **Format:** Optimized rectangular images (Dynamic scaling with centered text). |
|
|
| ## ๐งฉ Features |
| Each sample in the `metadata.jsonl` contains: |
| - `file_name`: Path to the image file. |
| - `text`: Ground-truth Tifinagh transcription. |
| - `background_color`: Color of the image background. |
| - `text_color`: Color of the rendered text. |
| - `pic_ID`: Unique image identifier. |
|
|
| > [!NOTE] |
| > The metadata has been **shuffled randomly** to allow a diverse preview of different fonts and styles in the Hugging Face dataset explorer. |
|
|
| ## ๐ฏ Use Cases |
| - Tifinagh OCR training and evaluation. |
| - Document understanding for Amazigh languages. |
| - Vision-language model validation. |
| - Robustness testing across different typographic styles. |
|
|
| ## ๐ Usage |
| ```python |
| from datasets import load_dataset |
| |
| dataset = load_dataset("Tamazight/Tifinagh-OCR-39K") |
| |
| sample = dataset["train"][0] |
| print(sample["text"]) |
| sample["image"].show() |
| ``` |
|
|
| ## ๐ Metadata & Credits |
| - **Creation Year:** 2024 |
| - **License:** [apache-2.0](https://choosealicense.com/licenses/apache-2.0/) |
| - **Creator:** Aksel Tinfat for [@Tamazight](https://huggingface.co/Tamazight) project on Hugging Face. |