Sigurdur commited on
Commit
d4cffaf
·
verified ·
1 Parent(s): 47f78b9

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +184 -0
README.md CHANGED
@@ -24,4 +24,188 @@ configs:
24
  data_files:
25
  - split: train
26
  path: data/train-*
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
27
  ---
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
24
  data_files:
25
  - split: train
26
  path: data/train-*
27
+ license: apache-2.0
28
+ task_categories:
29
+ - image-to-text
30
+ language:
31
+ - is
32
+ tags:
33
+ - ocr
34
+ - icelandic
35
+ - historical-documents
36
+ - newspapers
37
+ - document-layout
38
+ - timarit
39
+ - research
40
+ size_categories:
41
+ - n<1K
42
+ pretty_name: Timarit OCR
43
  ---
44
+
45
+ # Timarit OCR
46
+
47
+ ## Dataset Description
48
+
49
+ This dataset contains page-level images extracted from historical Icelandic newspapers and periodicals sourced from [timarit.is](https://timarit.is), Iceland's national digital archive of newspapers and magazines. Each sample pairs a page image with structured OCR output, providing ground-truth data for Icelandic historical documents.
50
+
51
+ OCR transcriptions were generated using [rednote-hilab/dots.ocr](https://huggingface.co/rednote-hilab/dots.ocr), a state-of-the-art document OCR model.
52
+
53
+ ### Dataset Summary
54
+
55
+ - **Language:** Icelandic (`is`)
56
+ - **Source:** [timarit.is](https://timarit.is) — Iceland's National and University Library digital archive
57
+ - **OCR Model:** [rednote-hilab/dots.ocr](https://huggingface.co/rednote-hilab/dots.ocr)
58
+ - **Format:** Images (PNG) with structured JSON OCR output
59
+ - **Primary Use Case:** OCR training and evaluation for historical Icelandic text
60
+
61
+ ### Supported Tasks
62
+
63
+ - **OCR / Image-to-Text:** Pairs of document images and their transcribed text for training or evaluating OCR models on historical Icelandic typography.
64
+ - **Document Layout Analysis:** Page-level images suitable for detecting text regions, columns, and other layout elements typical of historical Nordic newspaper printing.
65
+
66
+ ---
67
+
68
+ ## Dataset Structure
69
+
70
+ ### Data Fields
71
+
72
+ | Field | Type | Description |
73
+ |---|---|---|
74
+ | `image` | `Image` | Page-level scan of the source document (505px–3370px wide) |
75
+ | `imagewidth` | `int` | Width of the image in pixels |
76
+ | `issue_id` | `string` | Identifier for the specific issue (1–6 chars) |
77
+ | `page_name` | `string` | Name of the page within the issue (178 unique values) |
78
+ | `publication_id` | `string` | Identifier for the publication (1–4 chars) |
79
+ | `year` | `int32` | Publication year |
80
+ | `ocr` | `string` | Structured JSON OCR output from dots.ocr, containing detected text regions |
81
+
82
+ The `ocr` column contains a JSON-serialized list of detected text blocks. Each block has the following structure:
83
+
84
+ | Key | Type | Description |
85
+ |---|---|---|
86
+ | `box` | `list[int]` | Bounding box of the text region as `[x1, y1, x2, y2]` |
87
+ | `text` | `string` | Transcribed text content of the region |
88
+ | `category` | `string` | Layout category (e.g. `"Title"`, `"Text"`) |
89
+ | `confidence` | `float` | Model confidence score for the detection (0.0–1.0) |
90
+
91
+ Example `ocr` entry:
92
+ ```json
93
+ [
94
+ {"box": [366, 136, 1060, 502], "text": "FJÁRMÁLA FTIRLITIÐ", "category": "Title", "confidence": 1.0},
95
+ {"box": [496, 721, 868, 760], "text": "Leiðbeinandi tilmæli", "category": "Text", "confidence": 1.0}
96
+ ]
97
+ ```
98
+
99
+ To parse the `ocr` column in Python:
100
+ ```python
101
+ import json
102
+ from datasets import load_dataset
103
+
104
+ ds = load_dataset("Sigurdur/timarit-ocr")
105
+ ocr_blocks = json.loads(ds["train"][0]["ocr"])
106
+ for block in ocr_blocks:
107
+ print(block["category"], block["text"])
108
+ ```
109
+
110
+ ### Data Splits
111
+
112
+ | Split | Size |
113
+ |---|---|
114
+ | `train` | 1000 |
115
+
116
+ ---
117
+
118
+ ## Source Data
119
+
120
+ ### About timarit.is
121
+
122
+ [timarit.is](https://timarit.is) is the digital newspaper and periodical archive maintained by the National and University Library of Iceland (Landsbókasafn Íslands – Háskólabókasafn). It contains digitized issues of Icelandic newspapers and magazines spanning from the 19th century to the present, making it the primary resource for historical Icelandic printed text.
123
+
124
+ ### Collection Process
125
+
126
+ Pages were sourced from publicly available scans on timarit.is. Images were extracted at the page level and OCR transcriptions were generated using [rednote-hilab/dots.ocr](https://huggingface.co/rednote-hilab/dots.ocr).
127
+
128
+ ---
129
+
130
+ ## Copyright & Licensing
131
+
132
+ This dataset is released under the [Apache 2.0 License](https://www.apache.org/licenses/LICENSE-2.0). **Attribution is required** — if you use this dataset, you must cite the author (see citation below).
133
+
134
+ ### Source Material Copyright
135
+
136
+ The source material in this dataset is drawn from [timarit.is](https://timarit.is), the digital archive of the National and University Library of Iceland. Under Icelandic copyright law, a work enters the public domain **70 years after the death of the author**. Not all documents in this dataset can be guaranteed to meet this threshold.
137
+
138
+ **This dataset is intended solely for research purposes.** Users must not use this dataset or its contents for commercial purposes. It is the responsibility of the user to verify the copyright status of any specific document before use beyond non-commercial academic research. The dataset author assumes no liability for copyright infringement arising from downstream use.
139
+
140
+ ---
141
+
142
+ ## Usage
143
+
144
+ ```python
145
+ import json
146
+ from datasets import load_dataset
147
+
148
+ ds = load_dataset("Sigurdur/timarit-ocr")
149
+ sample = ds["train"][0]
150
+
151
+ # View image metadata
152
+ print(sample["publication_id"], sample["issue_id"], sample["year"])
153
+
154
+ # Parse OCR blocks
155
+ ocr_blocks = json.loads(sample["ocr"])
156
+ for block in ocr_blocks:
157
+ print(block["category"], block["text"])
158
+ ```
159
+
160
+ ---
161
+
162
+ ## Intended Use
163
+
164
+ This dataset is intended for:
165
+
166
+ - Training and fine-tuning OCR models on historical Icelandic text
167
+ - Evaluating OCR performance on low-resource Nordic language documents
168
+ - Research into historical document understanding and layout analysis for Icelandic
169
+
170
+ ---
171
+
172
+ ## Limitations & Biases
173
+
174
+ - Coverage is limited to publications available on timarit.is and may not represent all historical Icelandic print media.
175
+ - Historical documents may contain archaic spelling, ligatures, and fonts that differ significantly from modern Icelandic text.
176
+ - Scan quality varies across publications and time periods, which may affect model performance.
177
+ - OCR transcriptions were generated automatically by `dots.ocr` and may contain errors, particularly on degraded or low-resolution scans.
178
+
179
+ ---
180
+
181
+ ## Citation
182
+
183
+ If you use this dataset, please cite:
184
+
185
+ ```bibtex
186
+ @dataset{sigurdur2025timaritocr,
187
+ author = {Sigurdur Sigurdarson},
188
+ title = {Timarit OCR: Historical Icelandic Newspaper OCR Dataset},
189
+ year = {2025},
190
+ publisher = {Hugging Face},
191
+ url = {https://huggingface.co/datasets/Sigurdur/timarit-ocr}
192
+ }
193
+ ```
194
+
195
+ You may also want to cite the OCR model used to generate transcriptions:
196
+
197
+ ```bibtex
198
+ @misc{rednote2025dotsocr,
199
+ author = {rednote-hilab},
200
+ title = {dots.ocr},
201
+ year = {2025},
202
+ publisher = {Hugging Face},
203
+ url = {https://huggingface.co/rednote-hilab/dots.ocr}
204
+ }
205
+ ```
206
+
207
+ ---
208
+
209
+ ## Related Datasets
210
+
211
+ - [Sigurdur/isl-finepdfs-images](https://huggingface.co/datasets/Sigurdur/isl-finepdfs-images) — Icelandic PDF page images from the HuggingFaceFW/finepdfs collection