Datasets:
Upload README.md with huggingface_hub
Browse files
README.md
CHANGED
|
@@ -10,6 +10,35 @@ language:
|
|
| 10 |
pretty_name: olmOCR-bench Pre-Rendered
|
| 11 |
size_categories:
|
| 12 |
- 1K<n<10K
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 13 |
---
|
| 14 |
|
| 15 |
# olmOCR-bench Pre-Rendered
|
|
@@ -24,13 +53,36 @@ This dataset eliminates that setup entirely by hosting the pre-rendered images d
|
|
| 24 |
|
| 25 |
All files are accessible via direct URL, so you can evaluate any model by just pointing at these URLs — no local downloads, no PDF rendering tools, no dataset cloning.
|
| 26 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 27 |
## Contents
|
| 28 |
|
| 29 |
-
| Directory | Contents | Count |
|
| 30 |
-
|-----------|----------|-------|
|
| 31 |
-
| `
|
| 32 |
-
| `
|
| 33 |
-
| `predictions/` | Published model prediction caches | 1,403 .md files |
|
| 34 |
|
| 35 |
## Rendering Details
|
| 36 |
|
|
@@ -39,7 +91,7 @@ Each PDF page is rendered to PNG matching the official olmOCR benchmark process:
|
|
| 39 |
- **Resolution**: `target_longest_image_dim = 2048` (longest side scaled to 2048px, aspect ratio preserved)
|
| 40 |
- **Renderer**: PyMuPDF (same pixel output as pdftoppm used in the official repo)
|
| 41 |
- **Pages**: Page 1 only (the benchmark tests only page 1 of each PDF)
|
| 42 |
-
- **Naming**: `{pdf_stem}_pg1.png`
|
| 43 |
|
| 44 |
This matches what the official benchmark runners do internally:
|
| 45 |
- `run_chatgpt.py`: `render_pdf_to_base64png(pdf_path, target_longest_image_dim=2048)`
|
|
@@ -75,18 +127,6 @@ https://huggingface.co/datasets/shhdwi/olmocr-pre-rendered/resolve/main/images/a
|
|
| 75 |
https://huggingface.co/datasets/shhdwi/olmocr-pre-rendered/resolve/main/ground_truth/arxiv_math.jsonl
|
| 76 |
```
|
| 77 |
|
| 78 |
-
## Categories
|
| 79 |
-
|
| 80 |
-
| Category | PDFs | Tests | Test Types |
|
| 81 |
-
|----------|------|-------|------------|
|
| 82 |
-
| arxiv_math | 522 | 2,927 | math |
|
| 83 |
-
| headers_footers | 266 | 753 | absent |
|
| 84 |
-
| long_tiny_text | 62 | 442 | present |
|
| 85 |
-
| multi_column | 231 | 884 | order |
|
| 86 |
-
| old_scans | 98 | 526 | present, absent, order |
|
| 87 |
-
| old_scans_math | 36 | 458 | math |
|
| 88 |
-
| table_tests | 188 | 1,020 | table |
|
| 89 |
-
|
| 90 |
## Attribution
|
| 91 |
|
| 92 |
Based on [olmOCR-bench](https://huggingface.co/datasets/allenai/olmOCR-bench) by Allen AI ([paper](https://huggingface.co/papers/2502.18443)). Licensed ODC-BY-1.0.
|
|
|
|
| 10 |
pretty_name: olmOCR-bench Pre-Rendered
|
| 11 |
size_categories:
|
| 12 |
- 1K<n<10K
|
| 13 |
+
configs:
|
| 14 |
+
- config_name: arxiv_math
|
| 15 |
+
data_files:
|
| 16 |
+
- split: test
|
| 17 |
+
path: images/arxiv_math/**
|
| 18 |
+
- config_name: headers_footers
|
| 19 |
+
data_files:
|
| 20 |
+
- split: test
|
| 21 |
+
path: images/headers_footers/**
|
| 22 |
+
- config_name: long_tiny_text
|
| 23 |
+
data_files:
|
| 24 |
+
- split: test
|
| 25 |
+
path: images/long_tiny_text/**
|
| 26 |
+
- config_name: multi_column
|
| 27 |
+
data_files:
|
| 28 |
+
- split: test
|
| 29 |
+
path: images/multi_column/**
|
| 30 |
+
- config_name: old_scans
|
| 31 |
+
data_files:
|
| 32 |
+
- split: test
|
| 33 |
+
path: images/old_scans/**
|
| 34 |
+
- config_name: old_scans_math
|
| 35 |
+
data_files:
|
| 36 |
+
- split: test
|
| 37 |
+
path: images/old_scans_math/**
|
| 38 |
+
- config_name: tables
|
| 39 |
+
data_files:
|
| 40 |
+
- split: test
|
| 41 |
+
path: images/tables/**
|
| 42 |
---
|
| 43 |
|
| 44 |
# olmOCR-bench Pre-Rendered
|
|
|
|
| 53 |
|
| 54 |
All files are accessible via direct URL, so you can evaluate any model by just pointing at these URLs — no local downloads, no PDF rendering tools, no dataset cloning.
|
| 55 |
|
| 56 |
+
## Dataset Structure
|
| 57 |
+
|
| 58 |
+
The dataset has **7 subsets** (one per benchmark category), each with a **test** split:
|
| 59 |
+
|
| 60 |
+
| Subset | PDFs | Tests | Test Types |
|
| 61 |
+
|--------|------|-------|------------|
|
| 62 |
+
| `arxiv_math` | 522 | 2,927 | math |
|
| 63 |
+
| `headers_footers` | 266 | 753 | absent |
|
| 64 |
+
| `long_tiny_text` | 62 | 442 | present |
|
| 65 |
+
| `multi_column` | 231 | 884 | order |
|
| 66 |
+
| `old_scans` | 98 | 526 | present, absent, order |
|
| 67 |
+
| `old_scans_math` | 36 | 458 | math |
|
| 68 |
+
| `tables` | 188 | 1,020 | table |
|
| 69 |
+
|
| 70 |
+
### Loading with `datasets`
|
| 71 |
+
|
| 72 |
+
```python
|
| 73 |
+
from datasets import load_dataset
|
| 74 |
+
|
| 75 |
+
ds = load_dataset("shhdwi/olmocr-pre-rendered", "arxiv_math", split="test")
|
| 76 |
+
print(ds[0]) # {'image': <PIL.Image>, 'pdf_stem': '...', 'category': '...', ...}
|
| 77 |
+
```
|
| 78 |
+
|
| 79 |
## Contents
|
| 80 |
|
| 81 |
+
| Directory | Contents | Count |
|
| 82 |
+
|-----------|----------|-------|
|
| 83 |
+
| `images/` | Pre-rendered PNG images (page 1, 2048px longest dim) with `metadata.jsonl` per category | 1,403 images |
|
| 84 |
+
| `ground_truth/` | JSONL test case files (from allenai/olmOCR-bench) | 7,010 tests |
|
| 85 |
+
| `predictions/` | Published model prediction caches | 1,403 .md files |
|
| 86 |
|
| 87 |
## Rendering Details
|
| 88 |
|
|
|
|
| 91 |
- **Resolution**: `target_longest_image_dim = 2048` (longest side scaled to 2048px, aspect ratio preserved)
|
| 92 |
- **Renderer**: PyMuPDF (same pixel output as pdftoppm used in the official repo)
|
| 93 |
- **Pages**: Page 1 only (the benchmark tests only page 1 of each PDF)
|
| 94 |
+
- **Naming**: `{pdf_stem}_pg1.png`
|
| 95 |
|
| 96 |
This matches what the official benchmark runners do internally:
|
| 97 |
- `run_chatgpt.py`: `render_pdf_to_base64png(pdf_path, target_longest_image_dim=2048)`
|
|
|
|
| 127 |
https://huggingface.co/datasets/shhdwi/olmocr-pre-rendered/resolve/main/ground_truth/arxiv_math.jsonl
|
| 128 |
```
|
| 129 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 130 |
## Attribution
|
| 131 |
|
| 132 |
Based on [olmOCR-bench](https://huggingface.co/datasets/allenai/olmOCR-bench) by Allen AI ([paper](https://huggingface.co/papers/2502.18443)). Licensed ODC-BY-1.0.
|