Set up the data, parsing and quality-control layer for a public benchmark on the Volve daily drilling reports (DDR) and WITSML real-time data. - Data manifest with SHA-256 hashes of the three Volve subtrees in use. - DDR XML parser into DuckDB (1,759 reports, 26 wellbores, 23,447 activities, 17 tables) with locked expected counts. - Render QC of the publisher HTML against the XML (272,544 items). - OCR client for the shared chandra vLLM service, with a page cache keyed on model, prompt hash, dpi, max_tokens and temperature, and OCR QC against the HTML on a 26-report pilot. - Run logging (scripts/runlog.sh, logs/index.csv), the P0 runner and 40 tests. - Research plan, technical overview and progress page (in Vietnamese). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
21 lines
1.1 KiB
Bash
Executable File
21 lines
1.1 KiB
Bash
Executable File
#!/usr/bin/env bash
|
|
# Run the full P0 pipeline: data hash check → inventory → DDR XML parse → render QC → OCR pilot → OCR QC → unit tests.
|
|
# The OCR pilot sends nothing once its 47 pages are in the page cache (outputs/ocr/pages/); the full OCR run
|
|
# (scripts/04_ocr.py --all, ~5.3 h) is not part of P0: run it detached, see README.
|
|
set -euo pipefail
|
|
cd "$(dirname "$0")/.."
|
|
PY="${PY:-.venv/bin/python}"
|
|
# Unconditional: the machine default is OMP/MKL/OPENBLAS_NUM_THREADS=40, and "${VAR:-4}" would keep that 40.
|
|
export OMP_NUM_THREADS=4 MKL_NUM_THREADS=4 OPENBLAS_NUM_THREADS=4
|
|
# Log + runtime: the whole pipeline goes to logs/runs/<timestamp>_p0/, one subdirectory per step, one row per step in
|
|
# logs/index.csv (volve_dia/runlog.py).
|
|
[[ -n "${RUNLOG_DIR:-}" ]] || exec "$PY" -m volve_dia.runlog -n p0 -- bash "scripts/$(basename "$0")" "$@"
|
|
step() { "$PY" -m volve_dia.runlog -- "$@"; }
|
|
step "$PY" scripts/00_data_manifest.py --check
|
|
step "$PY" scripts/01_inventory.py
|
|
step "$PY" scripts/02_parse_ddr.py
|
|
step "$PY" scripts/03_render_qc.py
|
|
step "$PY" scripts/04_ocr.py --pilot
|
|
step "$PY" scripts/05_ocr_qc.py
|
|
step "$PY" -m pytest -q
|