File size: 1,885 Bytes
3f16c86
f12df27
 
 
 
 
 
 
 
 
 
 
 
 
 
 
3f16c86
f12df27
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
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
77
78
79
80
81
82
83
---
language: en
license: mit
task_categories:
- image-to-text
- text-recognition
- self-supervised-learning
tags:
- scene-text-recognition
- str
- ocr
- computer-vision
- multimodal
- self-supervised
size_categories:
- 10M<n<100M
---

# Union14M-STR: Combined Scene Text Recognition Dataset

## Dataset Description

Union14M-STR is a combined dataset containing both labeled and unlabeled images for comprehensive Scene Text Recognition (STR) training. It combines Union14M-L (4M labeled) and Union14M-U (10M unlabeled) datasets.

### Key Features

- **4M labeled images** from 14 public datasets
- **10M unlabeled images** for self-supervised learning
- **Combined training** supporting both supervised and self-supervised approaches
- **5 difficulty levels** for labeled data
- **Multiple data sources** for comprehensive coverage

### Dataset Structure

```
{
    "image": PIL.Image,
    "text": str or null,
    "source": str,
    "subset": str,
    "has_label": bool
}
```

### Splits

- **train**: Combined labeled and unlabeled training data
- **valid**: Labeled validation data only

### Usage

```python
from datasets import load_dataset

# Load the dataset
dataset = load_dataset("Bekhouche/Union14M-STR")

# Access different splits
train_data = dataset["train"]
valid_data = dataset["valid"]

# Filter by label availability
labeled_data = train_data.filter(lambda x: x["has_label"] == True)
unlabeled_data = train_data.filter(lambda x: x["has_label"] == False)

# Example usage
for sample in train_data:
    image = sample["image"]
    text = sample["text"]  # May be None for unlabeled data
    has_label = sample["has_label"]
    
    if has_label:
        # Supervised training
        pass
    else:
        # Self-supervised training
        pass
```

### Citation

If you use this dataset, please cite the original Union14M paper and acknowledge the source datasets.