Run the receipt experiment¶
Kind: how-to.
This procedure installs and runs Nemotron-3.5-Parse on a fixed receipt corpus. It needs no judge model or existing model server. For a GPU-free start, inspect the saved results.
Install the prerequisites¶
Use Linux x86-64 and an NVIDIA GPU. The recorded experiment used one RTX 4090 with 24 GiB of memory. The current profile requires at least 11000 MiB free on GPU 0. This is a reservation policy, not a measured minimum for every input. Other GPU architectures are not verified by this pilot. Allow tens of GB for container layers and model weights.
- Install uv and Git.
- Install Podman with rootless support.
- Install the NVIDIA driver for your system.
- Install NVIDIA Container Toolkit.
- Follow NVIDIA's CDI setup guide.
- Check the host and GPU device.
uv --version
podman info
nvidia-smi --id=0
nvidia-ctk cdi list
The CDI list must include nvidia.com/gpu=0.
The serving profile selects that device and checks its free memory.
It refuses insufficient memory and does not stop other workloads.
Install the experiment¶
- Clone the repository.
git clone https://github.com/Alberto-Codes/inference-lab.git
cd inference-lab
- Install Python and the locked preparation dependencies.
uv python install 3.12
uv sync --locked --group data
- Download the fixed inputs into a new directory.
uv run --group data python scripts/prepare_receipts.py --output corpus/receipts-01
Preparation reads the pinned CORD test source and verifies all 24 image hashes and annotations. It reproduces the JPEG encoding used by the recorded pilot. See input identity for details.
- Build the pinned parser container.
uv run inference-axi build
- Check available GPU memory.
uv run inference-axi status
Run and save outputs¶
- Start the parser.
uv run inference-axi start
If startup fails, save uv run inference-axi logs --full before running uv run inference-axi stop.
The stop command removes only this checkout's owned parser container.
Resolve the reported failure before starting again.
- Submit the receipt corpus with cleanup on exit.
(
trap 'uv run inference-axi stop' EXIT
uv run python scripts/receipt_experiment.py \
--input corpus/receipts-01 --output runs/receipts-01
)
The run warms each image, then measures concurrency levels one and four.
It saves terminal records in requests.jsonl and a summary in results.json.
A failed warmup prevents measured work.
An interrupted run retains its completed request records.
Inspect results¶
- Score the selected run into a new file.
uv run python scripts/score_receipts.py \
--input runs/receipts-01 --output runs/receipts-01/scores.json
- Read the summaries and individual missing-number lists in
scores.json. - Compare suspicious outputs with the corresponding receipt images.
The scorer refuses incomplete or duplicate sample sets. It does not modify the raw requests or replace an existing output file. Use a new directory or filename for another attempt.
These scores check extracted text and numbers, not layout or table-structure accuracy. Model-assisted review is a separate optional step. Use troubleshooting for startup, memory or scoring errors.