Skip to content

feat: baker pipeline — all 4 sources, integration tested - #14

Merged
gerchowl merged 9 commits into
mainfrom
dev
Apr 17, 2026
Merged

gerchowl merged 9 commits into
mainfrom
dev

Conversation

@gerchowl

Copy link
Copy Markdown
Contributor

Summary

Full baker pipeline implementation:

  • 4 source fetchers (ambientcg, polyhaven, gpuopen, physicallybased)
  • Bake engine (PNG validation, mtlx stub for gpuopen)
  • Parquet writer (UNCOMPRESSED binary, ZSTD scalars, rowmap via bounded PNG magic scan)
  • Index builder + CLI with 95% success threshold
  • 22 unit tests + integration test (real upstream data, range-read verified)
  • Dagger bake-source function for CI-driven builds

Test plan

  • 22 unit tests pass (normalization, parquet schema, rowmap offsets)
  • Integration test passes (2 real ambientcg materials → parquet → rowmap → range-read)
  • All 4 API probes pass
  • CI green (both jobs)

vig-os-release-app Bot and others added 9 commits April 16, 2026 23:21
Syncs `dev` with `main` (sync-main-to-dev workflow).
Implements the full pipeline for ambientcg (simplest source):
- common.py: MaterialRecord, retry with backoff, category/channel normalization
- sources/ambientcg.py: paginated API discovery, ZIP download, PNG extraction
- bake.py: PNG validation passthrough (mtlx baking stub for gpuopen)
- parquet_writer.py: UNCOMPRESSED binary cols, ZSTD scalars, rowmap via PNG magic scan
- index_builder.py: index JSON from records
- __main__.py: CLI with fetch/all subcommands, 95% success threshold
- 22 unit tests (normalization, parquet schema, rowmap range-read verification)
- Dagger integration-test: fetch 2 real materials → pack → verify range reads
Fetches 2 real ambientcg materials, bakes, packs parquet, verifies
range-read via rowmap. Blocks PRs if the pipeline is broken.
Discovery still paginates fully (needed for production builds), but
materials without download URLs for the requested tier are filtered
out before the limit is applied. Fixes integration test failing on
brand-new materials that haven't been processed yet.
- Add include=downloadData to discovery URL (downloadFolders is null without it)
- Downloads are under default/zip/downloads[] with attribute "1K-PNG" etc.
  not separate folders per tier
- polyhaven: individual PNG downloads, per-slug detail endpoint
- gpuopen: ZIP with mtlx, flat texture extraction, layered flagging
- physicallybased: scalar only (IOR, color, roughness), no textures
- CLI: wire up all 4 fetchers
- rowmap: limit PNG magic scan to 100-byte window after page offset
  to prevent false positives from PNG data in neighboring columns
- Dagger bake-source: runs full baker for one source+tier, returns artifacts dir
- CLI: physicallybased skips bake/pack (scalar only, index JSON only)
@gerchowl
gerchowl merged commit b2459fb into main Apr 17, 2026
10 checks passed
gerchowl added a commit that referenced this pull request May 15, 2026
Baker pipeline — all 4 sources, integration tested.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant