davanstrien HF Staff commited on
Commit
2c440d7
·
verified ·
1 Parent(s): 30f8440

Upload README.md with huggingface_hub

Browse files
Files changed (1) hide show
  1. README.md +86 -35
README.md CHANGED
@@ -1,37 +1,88 @@
1
  ---
2
- dataset_info:
3
- features:
4
- - name: image
5
- dtype: image
6
- - name: raw_queries
7
- list: string
8
- - name: broad_topical_query
9
- dtype: string
10
- - name: broad_topical_explanation
11
- dtype: string
12
- - name: specific_detail_query
13
- dtype: string
14
- - name: specific_detail_explanation
15
- dtype: string
16
- - name: visual_element_query
17
- dtype: string
18
- - name: visual_element_explanation
19
- dtype: string
20
- - name: parsed_into_json
21
- dtype: bool
22
- - name: markdown
23
- dtype: string
24
- - name: inference_info
25
- dtype: string
26
- splits:
27
- - name: train
28
- num_bytes: 312424
29
- num_examples: 3
30
- download_size: 330840
31
- dataset_size: 312424
32
- configs:
33
- - config_name: default
34
- data_files:
35
- - split: train
36
- path: data/train-*
37
  ---
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
  ---
2
+ tags:
3
+ - ocr
4
+ - document-processing
5
+ - dots-mocr
6
+ - multilingual
7
+ - markdown
8
+ - uv-script
9
+ - generated
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
10
  ---
11
+
12
+ # Document OCR using dots.mocr
13
+
14
+ This dataset contains OCR results from images in [davanstrien/ufo-ColPali](https://huggingface.co/datasets/davanstrien/ufo-ColPali) using dots.mocr, a 3B multilingual model with SOTA document parsing and SVG generation.
15
+
16
+ ## Processing Details
17
+
18
+ - **Source Dataset**: [davanstrien/ufo-ColPali](https://huggingface.co/datasets/davanstrien/ufo-ColPali)
19
+ - **Model**: [rednote-hilab/dots.mocr](https://huggingface.co/rednote-hilab/dots.mocr)
20
+ - **Number of Samples**: 3
21
+ - **Processing Time**: 2.0 min
22
+ - **Processing Date**: 2026-03-19 17:38 UTC
23
+
24
+ ### Configuration
25
+
26
+ - **Image Column**: `image`
27
+ - **Output Column**: `markdown`
28
+ - **Dataset Split**: `train`
29
+ - **Batch Size**: 16
30
+ - **Prompt Mode**: ocr
31
+ - **Max Model Length**: 24,000 tokens
32
+ - **Max Output Tokens**: 24,000
33
+ - **GPU Memory Utilization**: 90.0%
34
+
35
+ ## Model Information
36
+
37
+ dots.mocr is a 3B multilingual document parsing model that excels at:
38
+ - 100+ Languages — Multilingual document support
39
+ - Table extraction — Structured data recognition
40
+ - Formulas — Mathematical notation preservation
41
+ - Layout-aware — Reading order and structure preservation
42
+ - Web screen parsing — Webpage layout analysis
43
+ - Scene text spotting — Text detection in natural scenes
44
+ - SVG code generation — Charts, UI layouts, scientific figures to SVG
45
+
46
+ ## Dataset Structure
47
+
48
+ The dataset contains all original columns plus:
49
+ - `markdown`: The extracted text in markdown format
50
+ - `inference_info`: JSON list tracking all OCR models applied to this dataset
51
+
52
+ ## Usage
53
+
54
+ ```python
55
+ from datasets import load_dataset
56
+ import json
57
+
58
+ # Load the dataset
59
+ dataset = load_dataset("{output_dataset_id}", split="train")
60
+
61
+ # Access the markdown text
62
+ for example in dataset:
63
+ print(example["markdown"])
64
+ break
65
+
66
+ # View all OCR models applied to this dataset
67
+ inference_info = json.loads(dataset[0]["inference_info"])
68
+ for info in inference_info:
69
+ print(f"Column: {info['column_name']} - Model: {info['model_id']}")
70
+ ```
71
+
72
+ ## Reproduction
73
+
74
+ This dataset was generated using the [uv-scripts/ocr](https://huggingface.co/datasets/uv-scripts/ocr) dots.mocr script:
75
+
76
+ ```bash
77
+ uv run https://huggingface.co/datasets/uv-scripts/ocr/raw/main/dots-mocr.py \
78
+ davanstrien/ufo-ColPali \
79
+ <output-dataset> \
80
+ --image-column image \
81
+ --batch-size 16 \
82
+ --prompt-mode ocr \
83
+ --max-model-len 24000 \
84
+ --max-tokens 24000 \
85
+ --gpu-memory-utilization 0.9
86
+ ```
87
+
88
+ Generated with [UV Scripts](https://huggingface.co/uv-scripts)