Loading page...Загружаем страницу...正在加载页面...
AtlasRepo

Contrek: Vectorizing 10 Billion Pixels on a Raspberry Pi 5 with Just 4 GB RAM

说明与用途

Contrek 通过流式处理水平条带并将多边形写入磁盘,使得在 4 GB RAM 的 Raspberry Pi 5 上处理 10 十亿像素的栅格图像时,峰值内存仅为 2.42 GB。

问题

Processing extremely large raster images without loading the entire image into memory.

结果

On a Raspberry Pi 5 with 4 GB RAM, Contrek processed a 10 billion‑pixel image in 13 min 52 s, peaking at 2.42 GiB memory, producing a 21.03 GB SVG without any swap.

工作流

  • 1. Install Contrek on a Raspberry Pi 5 with 4 GB RAM, 250 GB NVMe SSD, Ubuntu 24.04 ARM64 Docker container.
  • 2. Prepare a 100,000 × 100,000 pixel PNG image (~900 MB compressed).
  • 3. Run Contrek with horizontal stripe width of 1,000 rows.
  • 4. Contrek extracts contours, reconnects across stripes, and writes polygons to disk progressively.
  • 5. Monitor execution time, peak memory, and CPU usage.
  • 6. Verify output SVG (~21 GB) and confirm no swap usage.

证据

Contrek can process an image in horizontal stripes, reconnecting contours across stripe boundaries and progressively writing completed polygons to disk.

来源

The input was a 100,000 × 100,000 pixel PNG image, containing 10 billion pixels. The compressed PNG file is about 900 MB.

来源

Peak process memory 2.42 GiB

来源

Output SVG 21.03 GB

来源

The process completed successfully, with zero swaps reported by GNU time.

来源

  • 记录日期: 2026-10-23T10:11:32.525Z