Photoshot Retouch Part 5 — Heal red blemishes and dark spots
Checkpoint ID: photoshot-retouch-05-heal-2026-11-30

Unzip the lab. Use Windows x64 and Python 3.10. Open PowerShell in lab.
  py -3.10 -m venv .venv
  .\.venv\Scripts\python.exe -m pip install -r requirements-lock.txt
  .\.venv\Scripts\python.exe finished\reproduce_heal.py

The starting source is start/heal_20261108.py. Its functions come from the 8
November archived development patch. It imports the same blur, ellipse and
ramp helpers as the current checkpoint. start/settings.json defines the two
strength arrays and the known test positions. First predict the differences:
which strength can affect the dark spot, and where should the masks be zero?
The finished checkpoint runs the actual service engine and archived/current
Heal. Only the synthetic skin and landmark-derived masks are controlled.

Expect a regenerated set of input PNGs and ROI masks in input/, then 12
normal-layer runs, a flat-color no-change case, a larger red miss case
and one 16-bit separate-versus-merged test. The 8-bit assets are packed RGB
and one byte per mask pixel. The 16-bit assets use little-endian RGB.
results/heal-checks.json contains the complete measured matrix.

Optional CPU run with actual face landmarks and skin segmentation:
  $env:RETOUCH_MODELS = Join-Path $PWD.Path '.models'
  Push-Location finished
  ..\.venv\Scripts\python.exe -m service.models
  Pop-Location
  .\.venv\Scripts\python.exe finished\reproduce_portrait.py

The model installer checks SHA-256. The portrait runner uses a Windows
TEMP folder with an ASCII path, matching the MediaPipe runtime behavior
confirmed in Part 4. It writes results/portrait-checks.json. The NASA
astronaut image is from scikit-image and was described there as public
domain. This bundle carries no model weights and no reference video frame.
Historic frame summaries in results/additional-evidence.json are local
observations that require the separately archived image files to reproduce.
See results/sha256.json for the frozen code, fixture and output hashes.

Image credit and docs:
https://scikit-image.org/docs/stable/api/skimage.data.html#skimage.data.astronaut
https://ai.google.dev/edge/mediapipe/solutions/vision/face_landmarker
https://ai.google.dev/edge/mediapipe/solutions/vision/image_segmenter

