Skip to content

Add Zarr archive and specification for ViT-MNIST inference traces (issue 39)#52

Open
Rosette2237 wants to merge 2 commits into
AI2Science:mainfrom
Rosette2237:archive/zarr-on-transformers
Open

Add Zarr archive and specification for ViT-MNIST inference traces (issue 39)#52
Rosette2237 wants to merge 2 commits into
AI2Science:mainfrom
Rosette2237:archive/zarr-on-transformers

Conversation

@Rosette2237

@Rosette2237 Rosette2237 commented Mar 9, 2026

Copy link
Copy Markdown

Summary

This PR adds the Zarr archive design and implementation for storing ViT inference traces, including inputs, predictions, metadata, and per-layer attention outputs. The goal is to support efficient partial reads for downstream visualization and analysis, instead of relying on a simple .pt archive.

For the full archive specification, please refer to Zarr archive specification.

Included in this PR

  • Zarr archive design for ViT attention data
  • Archive structure for metadata, inputs, and per-layer attention outputs
  • Storage choices for chunking and compression
  • Supporting specification documentation in ARCHIVE_SPEC.md

Why

This design makes it easier to:

  • read specific samples, layers, or heads without loading the full archive
  • support attention visualization workflows
  • extend the archive format for larger future models and datasets

Future Work

Design the similar Zarr archive for VizFold and fix issue #39.

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