deliberable_04_01_2026
All checks were successful
build_docker / essential (push) Successful in 1s
build_docker / build_paddle_ocr (push) Successful in 5m12s
build_docker / build_paddle_ocr_gpu (push) Successful in 20m54s
build_docker / build_easyocr (push) Successful in 18m19s
build_docker / build_doctr (push) Successful in 19m49s
build_docker / build_easyocr_gpu (push) Successful in 24m6s
build_docker / build_raytune (push) Successful in 4m10s
build_docker / build_doctr_gpu (push) Successful in 16m26s
All checks were successful
build_docker / essential (push) Successful in 1s
build_docker / build_paddle_ocr (push) Successful in 5m12s
build_docker / build_paddle_ocr_gpu (push) Successful in 20m54s
build_docker / build_easyocr (push) Successful in 18m19s
build_docker / build_doctr (push) Successful in 19m49s
build_docker / build_easyocr_gpu (push) Successful in 24m6s
build_docker / build_raytune (push) Successful in 4m10s
build_docker / build_doctr_gpu (push) Successful in 16m26s
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
@@ -95,6 +95,25 @@ Results are saved to `src/results/` as CSV files:
|
||||
- `raytune_doctr_results_<timestamp>.csv`
|
||||
- `raytune_easyocr_results_<timestamp>.csv`
|
||||
|
||||
### Correlation Analysis
|
||||
|
||||
Correlation tables used in the thesis are derived from the CSV results with a local script:
|
||||
|
||||
```bash
|
||||
source .venv/bin/activate
|
||||
python tem/scripts/compute_correlations_all.py
|
||||
```
|
||||
|
||||
Outputs are written to `src/results/correlations/`:
|
||||
- `paddle_correlations.csv`
|
||||
- `doctr_correlations.csv`
|
||||
- `easyocr_correlations.csv`
|
||||
|
||||
These files are computed from the corresponding inputs:
|
||||
- `src/results/raytune_paddle_results_20260119_122609.csv`
|
||||
- `src/results/raytune_doctr_results_20260119_121445.csv`
|
||||
- `src/results/raytune_easyocr_results_20260119_120204.csv`
|
||||
|
||||
## Directory Structure
|
||||
|
||||
```
|
||||
|
||||
1129
src/archived/ocr_benchmark_notebook.ipynb
Normal file
1129
src/archived/ocr_benchmark_notebook.ipynb
Normal file
File diff suppressed because one or more lines are too long
1285
src/archived/paddle_ocr_fine_tune_unir.ipynb
Normal file
1285
src/archived/paddle_ocr_fine_tune_unir.ipynb
Normal file
File diff suppressed because one or more lines are too long
@@ -1,82 +0,0 @@
|
||||
# docker-compose.tuning.yml - Ray Tune with all OCR services (PaddleOCR + DocTR)
|
||||
# Usage:
|
||||
# docker compose -f docker-compose.tuning.yml up -d paddle-ocr-gpu doctr-gpu
|
||||
# docker compose -f docker-compose.tuning.yml run raytune --service paddle --samples 64
|
||||
# docker compose -f docker-compose.tuning.yml run raytune --service doctr --samples 64
|
||||
# docker compose -f docker-compose.tuning.yml down
|
||||
#
|
||||
# Note: EasyOCR uses port 8002 (same as PaddleOCR). Use docker-compose.tuning.easyocr.yml separately.
|
||||
|
||||
services:
|
||||
raytune:
|
||||
image: seryus.ddns.net/unir/raytune:latest
|
||||
network_mode: host
|
||||
shm_size: '5gb'
|
||||
volumes:
|
||||
- ./results:/app/results:rw
|
||||
environment:
|
||||
- PYTHONUNBUFFERED=1
|
||||
|
||||
paddle-ocr-gpu:
|
||||
image: seryus.ddns.net/unir/paddle-ocr-gpu:latest
|
||||
container_name: paddle-ocr-gpu-tuning
|
||||
ports:
|
||||
- "8002:8000"
|
||||
volumes:
|
||||
- ./dataset:/app/dataset:ro
|
||||
- ./debugset:/app/debugset:rw
|
||||
- paddlex-cache:/root/.paddlex
|
||||
environment:
|
||||
- PYTHONUNBUFFERED=1
|
||||
- CUDA_VISIBLE_DEVICES=0
|
||||
- PADDLE_DET_MODEL=PP-OCRv5_mobile_det
|
||||
- PADDLE_REC_MODEL=PP-OCRv5_mobile_rec
|
||||
deploy:
|
||||
resources:
|
||||
reservations:
|
||||
devices:
|
||||
- driver: nvidia
|
||||
count: 1
|
||||
capabilities: [gpu]
|
||||
restart: unless-stopped
|
||||
healthcheck:
|
||||
test: ["CMD", "python", "-c", "import urllib.request; urllib.request.urlopen('http://localhost:8000/health')"]
|
||||
interval: 30s
|
||||
timeout: 10s
|
||||
retries: 3
|
||||
start_period: 60s
|
||||
|
||||
doctr-gpu:
|
||||
image: seryus.ddns.net/unir/doctr-gpu:latest
|
||||
container_name: doctr-gpu-tuning
|
||||
ports:
|
||||
- "8003:8000"
|
||||
volumes:
|
||||
- ./dataset:/app/dataset:ro
|
||||
- ./debugset:/app/debugset:rw
|
||||
- doctr-cache:/root/.cache/doctr
|
||||
environment:
|
||||
- PYTHONUNBUFFERED=1
|
||||
- CUDA_VISIBLE_DEVICES=0
|
||||
- DOCTR_DET_ARCH=db_resnet50
|
||||
- DOCTR_RECO_ARCH=crnn_vgg16_bn
|
||||
deploy:
|
||||
resources:
|
||||
reservations:
|
||||
devices:
|
||||
- driver: nvidia
|
||||
count: 1
|
||||
capabilities: [gpu]
|
||||
restart: unless-stopped
|
||||
healthcheck:
|
||||
test: ["CMD", "python", "-c", "import urllib.request; urllib.request.urlopen('http://localhost:8000/health')"]
|
||||
interval: 30s
|
||||
timeout: 10s
|
||||
retries: 3
|
||||
start_period: 180s
|
||||
|
||||
volumes:
|
||||
paddlex-cache:
|
||||
name: paddlex-model-cache
|
||||
doctr-cache:
|
||||
name: doctr-model-cache
|
||||
19
src/results/correlations/doctr_correlations.csv
Normal file
19
src/results/correlations/doctr_correlations.csv
Normal file
@@ -0,0 +1,19 @@
|
||||
parameter,metric,pearson
|
||||
straighten_pages,CER,0.9998131749398365
|
||||
symmetric_pad,CER,0.5261495908818205
|
||||
disable_page_orientation,CER,-0.49338806188002227
|
||||
disable_crop_orientation,CER,0.3470400052300961
|
||||
paragraph_break,CER,-0.28710190683729514
|
||||
resolve_blocks,CER,-0.2307325611083525
|
||||
preserve_aspect_ratio,CER,0.12408787013954682
|
||||
assume_straight_pages,CER,-0.11904725618816066
|
||||
resolve_lines,CER,0.060358529330885535
|
||||
straighten_pages,WER,0.9997423603542454
|
||||
symmetric_pad,WER,0.5288569133407047
|
||||
disable_page_orientation,WER,-0.49788185337361895
|
||||
disable_crop_orientation,WER,0.35150041517456027
|
||||
paragraph_break,WER,-0.2867204522845194
|
||||
resolve_blocks,WER,-0.23363320696739256
|
||||
assume_straight_pages,WER,-0.12980061688173894
|
||||
preserve_aspect_ratio,WER,0.1289984520450311
|
||||
resolve_lines,WER,0.06486504638919248
|
||||
|
92
src/results/correlations/doctr_correlations.json
Normal file
92
src/results/correlations/doctr_correlations.json
Normal file
@@ -0,0 +1,92 @@
|
||||
[
|
||||
{
|
||||
"parameter": "straighten_pages",
|
||||
"metric": "CER",
|
||||
"pearson": 0.9998131749398365
|
||||
},
|
||||
{
|
||||
"parameter": "symmetric_pad",
|
||||
"metric": "CER",
|
||||
"pearson": 0.5261495908818205
|
||||
},
|
||||
{
|
||||
"parameter": "disable_page_orientation",
|
||||
"metric": "CER",
|
||||
"pearson": -0.49338806188002227
|
||||
},
|
||||
{
|
||||
"parameter": "disable_crop_orientation",
|
||||
"metric": "CER",
|
||||
"pearson": 0.3470400052300961
|
||||
},
|
||||
{
|
||||
"parameter": "paragraph_break",
|
||||
"metric": "CER",
|
||||
"pearson": -0.28710190683729514
|
||||
},
|
||||
{
|
||||
"parameter": "resolve_blocks",
|
||||
"metric": "CER",
|
||||
"pearson": -0.2307325611083525
|
||||
},
|
||||
{
|
||||
"parameter": "preserve_aspect_ratio",
|
||||
"metric": "CER",
|
||||
"pearson": 0.12408787013954682
|
||||
},
|
||||
{
|
||||
"parameter": "assume_straight_pages",
|
||||
"metric": "CER",
|
||||
"pearson": -0.11904725618816066
|
||||
},
|
||||
{
|
||||
"parameter": "resolve_lines",
|
||||
"metric": "CER",
|
||||
"pearson": 0.060358529330885535
|
||||
},
|
||||
{
|
||||
"parameter": "straighten_pages",
|
||||
"metric": "WER",
|
||||
"pearson": 0.9997423603542454
|
||||
},
|
||||
{
|
||||
"parameter": "symmetric_pad",
|
||||
"metric": "WER",
|
||||
"pearson": 0.5288569133407047
|
||||
},
|
||||
{
|
||||
"parameter": "disable_page_orientation",
|
||||
"metric": "WER",
|
||||
"pearson": -0.49788185337361895
|
||||
},
|
||||
{
|
||||
"parameter": "disable_crop_orientation",
|
||||
"metric": "WER",
|
||||
"pearson": 0.35150041517456027
|
||||
},
|
||||
{
|
||||
"parameter": "paragraph_break",
|
||||
"metric": "WER",
|
||||
"pearson": -0.2867204522845194
|
||||
},
|
||||
{
|
||||
"parameter": "resolve_blocks",
|
||||
"metric": "WER",
|
||||
"pearson": -0.23363320696739256
|
||||
},
|
||||
{
|
||||
"parameter": "assume_straight_pages",
|
||||
"metric": "WER",
|
||||
"pearson": -0.12980061688173894
|
||||
},
|
||||
{
|
||||
"parameter": "preserve_aspect_ratio",
|
||||
"metric": "WER",
|
||||
"pearson": 0.1289984520450311
|
||||
},
|
||||
{
|
||||
"parameter": "resolve_lines",
|
||||
"metric": "WER",
|
||||
"pearson": 0.06486504638919248
|
||||
}
|
||||
]
|
||||
25
src/results/correlations/easyocr_correlations.csv
Normal file
25
src/results/correlations/easyocr_correlations.csv
Normal file
@@ -0,0 +1,25 @@
|
||||
parameter,metric,pearson
|
||||
contrast_ths,CER,0.40885606429688176
|
||||
ycenter_ths,CER,0.3052506223332593
|
||||
slope_ths,CER,-0.3007836023513022
|
||||
width_ths,CER,0.2820622927402215
|
||||
beamWidth,CER,0.24551397803020547
|
||||
add_margin,CER,0.23419721611930053
|
||||
height_ths,CER,-0.22762064209067434
|
||||
low_text,CER,-0.2127914870290739
|
||||
adjust_contrast,CER,-0.14938336246670267
|
||||
text_threshold,CER,-0.12089385052834749
|
||||
link_threshold,CER,-0.09553910777087017
|
||||
min_size,CER,0.04597421017746789
|
||||
contrast_ths,WER,0.38684315732406244
|
||||
slope_ths,WER,-0.32504213142289984
|
||||
ycenter_ths,WER,0.28738383141120705
|
||||
add_margin,WER,0.24148232685944232
|
||||
width_ths,WER,0.23869424685132606
|
||||
height_ths,WER,-0.23743923240967893
|
||||
beamWidth,WER,0.2286079838179018
|
||||
adjust_contrast,WER,-0.17842640649533945
|
||||
low_text,WER,-0.1772397092408802
|
||||
text_threshold,WER,-0.12733512825321042
|
||||
min_size,WER,0.10070615378426818
|
||||
link_threshold,WER,-0.04425190559911718
|
||||
|
122
src/results/correlations/easyocr_correlations.json
Normal file
122
src/results/correlations/easyocr_correlations.json
Normal file
@@ -0,0 +1,122 @@
|
||||
[
|
||||
{
|
||||
"parameter": "contrast_ths",
|
||||
"metric": "CER",
|
||||
"pearson": 0.40885606429688176
|
||||
},
|
||||
{
|
||||
"parameter": "ycenter_ths",
|
||||
"metric": "CER",
|
||||
"pearson": 0.3052506223332593
|
||||
},
|
||||
{
|
||||
"parameter": "slope_ths",
|
||||
"metric": "CER",
|
||||
"pearson": -0.3007836023513022
|
||||
},
|
||||
{
|
||||
"parameter": "width_ths",
|
||||
"metric": "CER",
|
||||
"pearson": 0.2820622927402215
|
||||
},
|
||||
{
|
||||
"parameter": "beamWidth",
|
||||
"metric": "CER",
|
||||
"pearson": 0.24551397803020547
|
||||
},
|
||||
{
|
||||
"parameter": "add_margin",
|
||||
"metric": "CER",
|
||||
"pearson": 0.23419721611930053
|
||||
},
|
||||
{
|
||||
"parameter": "height_ths",
|
||||
"metric": "CER",
|
||||
"pearson": -0.22762064209067434
|
||||
},
|
||||
{
|
||||
"parameter": "low_text",
|
||||
"metric": "CER",
|
||||
"pearson": -0.2127914870290739
|
||||
},
|
||||
{
|
||||
"parameter": "adjust_contrast",
|
||||
"metric": "CER",
|
||||
"pearson": -0.14938336246670267
|
||||
},
|
||||
{
|
||||
"parameter": "text_threshold",
|
||||
"metric": "CER",
|
||||
"pearson": -0.12089385052834749
|
||||
},
|
||||
{
|
||||
"parameter": "link_threshold",
|
||||
"metric": "CER",
|
||||
"pearson": -0.09553910777087017
|
||||
},
|
||||
{
|
||||
"parameter": "min_size",
|
||||
"metric": "CER",
|
||||
"pearson": 0.04597421017746789
|
||||
},
|
||||
{
|
||||
"parameter": "contrast_ths",
|
||||
"metric": "WER",
|
||||
"pearson": 0.38684315732406244
|
||||
},
|
||||
{
|
||||
"parameter": "slope_ths",
|
||||
"metric": "WER",
|
||||
"pearson": -0.32504213142289984
|
||||
},
|
||||
{
|
||||
"parameter": "ycenter_ths",
|
||||
"metric": "WER",
|
||||
"pearson": 0.28738383141120705
|
||||
},
|
||||
{
|
||||
"parameter": "add_margin",
|
||||
"metric": "WER",
|
||||
"pearson": 0.24148232685944232
|
||||
},
|
||||
{
|
||||
"parameter": "width_ths",
|
||||
"metric": "WER",
|
||||
"pearson": 0.23869424685132606
|
||||
},
|
||||
{
|
||||
"parameter": "height_ths",
|
||||
"metric": "WER",
|
||||
"pearson": -0.23743923240967893
|
||||
},
|
||||
{
|
||||
"parameter": "beamWidth",
|
||||
"metric": "WER",
|
||||
"pearson": 0.2286079838179018
|
||||
},
|
||||
{
|
||||
"parameter": "adjust_contrast",
|
||||
"metric": "WER",
|
||||
"pearson": -0.17842640649533945
|
||||
},
|
||||
{
|
||||
"parameter": "low_text",
|
||||
"metric": "WER",
|
||||
"pearson": -0.1772397092408802
|
||||
},
|
||||
{
|
||||
"parameter": "text_threshold",
|
||||
"metric": "WER",
|
||||
"pearson": -0.12733512825321042
|
||||
},
|
||||
{
|
||||
"parameter": "min_size",
|
||||
"metric": "WER",
|
||||
"pearson": 0.10070615378426818
|
||||
},
|
||||
{
|
||||
"parameter": "link_threshold",
|
||||
"metric": "WER",
|
||||
"pearson": -0.04425190559911718
|
||||
}
|
||||
]
|
||||
15
src/results/correlations/paddle_correlations.csv
Normal file
15
src/results/correlations/paddle_correlations.csv
Normal file
@@ -0,0 +1,15 @@
|
||||
parameter,metric,pearson
|
||||
use_doc_unwarping,CER,0.8791236551817551
|
||||
use_doc_orientation_classify,CER,-0.7119850615039771
|
||||
textline_orientation,CER,-0.5347452891182014
|
||||
text_det_thresh,CER,0.4280438958428758
|
||||
text_det_box_thresh,CER,0.3113152196833144
|
||||
text_rec_score_thresh,CER,-0.2681957118190106
|
||||
text_det_unclip_ratio,CER,
|
||||
use_doc_unwarping,WER,0.743651897463081
|
||||
use_doc_orientation_classify,WER,-0.6018981292243886
|
||||
textline_orientation,WER,-0.5906753653336065
|
||||
text_det_thresh,WER,0.39917807081409956
|
||||
text_det_box_thresh,WER,0.2555315418488065
|
||||
text_rec_score_thresh,WER,-0.08030912963602418
|
||||
text_det_unclip_ratio,WER,
|
||||
|
72
src/results/correlations/paddle_correlations.json
Normal file
72
src/results/correlations/paddle_correlations.json
Normal file
@@ -0,0 +1,72 @@
|
||||
[
|
||||
{
|
||||
"parameter": "use_doc_unwarping",
|
||||
"metric": "CER",
|
||||
"pearson": 0.8791236551817551
|
||||
},
|
||||
{
|
||||
"parameter": "use_doc_orientation_classify",
|
||||
"metric": "CER",
|
||||
"pearson": -0.7119850615039771
|
||||
},
|
||||
{
|
||||
"parameter": "textline_orientation",
|
||||
"metric": "CER",
|
||||
"pearson": -0.5347452891182014
|
||||
},
|
||||
{
|
||||
"parameter": "text_det_thresh",
|
||||
"metric": "CER",
|
||||
"pearson": 0.4280438958428758
|
||||
},
|
||||
{
|
||||
"parameter": "text_det_box_thresh",
|
||||
"metric": "CER",
|
||||
"pearson": 0.3113152196833144
|
||||
},
|
||||
{
|
||||
"parameter": "text_rec_score_thresh",
|
||||
"metric": "CER",
|
||||
"pearson": -0.2681957118190106
|
||||
},
|
||||
{
|
||||
"parameter": "text_det_unclip_ratio",
|
||||
"metric": "CER",
|
||||
"pearson": NaN
|
||||
},
|
||||
{
|
||||
"parameter": "use_doc_unwarping",
|
||||
"metric": "WER",
|
||||
"pearson": 0.743651897463081
|
||||
},
|
||||
{
|
||||
"parameter": "use_doc_orientation_classify",
|
||||
"metric": "WER",
|
||||
"pearson": -0.6018981292243886
|
||||
},
|
||||
{
|
||||
"parameter": "textline_orientation",
|
||||
"metric": "WER",
|
||||
"pearson": -0.5906753653336065
|
||||
},
|
||||
{
|
||||
"parameter": "text_det_thresh",
|
||||
"metric": "WER",
|
||||
"pearson": 0.39917807081409956
|
||||
},
|
||||
{
|
||||
"parameter": "text_det_box_thresh",
|
||||
"metric": "WER",
|
||||
"pearson": 0.2555315418488065
|
||||
},
|
||||
{
|
||||
"parameter": "text_rec_score_thresh",
|
||||
"metric": "WER",
|
||||
"pearson": -0.08030912963602418
|
||||
},
|
||||
{
|
||||
"parameter": "text_det_unclip_ratio",
|
||||
"metric": "WER",
|
||||
"pearson": NaN
|
||||
}
|
||||
]
|
||||
Reference in New Issue
Block a user