Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 12 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -203,6 +203,7 @@ $RECYCLE.BIN/
# Temporary files
temp/
tmp/
out/
*.tmp
*.temp

Expand All @@ -223,6 +224,17 @@ tmp/
*.graphml
*.onnxdata

# ONNX Runtime external-data sidecars dropped at CWD (UUID-named *.data files)
# from sessions that did not pin the external-data directory
/*.data

# Quark / quantizer side-effect outputs
/quantized_info.csv

# Local debug / scratch scripts (convention: leading underscore = private)
scripts/_*.py
scripts/_*.json

# Logs
*.log
logs/
Expand Down
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ Purpose-built for Windows hardware diversity, the CLI handles conversion, graph
- **All Windows ML EPs supported.** Every [supported execution provider](https://microsoft.github.io/winml-cli/latest/concepts/eps-and-devices/#eps-winml-cli-supports) is available behind the same commands.
- **Curated model catalog.** A [verified set of models](https://microsoft.github.io/winml-cli/latest/reference/supported-models/) that run across all Windows ML EPs - a reliable starting point.
- **Bring your own ONNX.** Not only for converting from PyTorch - bring an [existing ONNX model](https://microsoft.github.io/winml-cli/latest/tutorials/build-from-onnx/) to get operator-compatibility insights and optimize it based on the analysis.
- **Hub-hosted ONNX models.** Reference pre-exported ONNX files on the Hugging Face Hub as `<org>/<repo>/<path/to/file>.onnx` (e.g. `onnx-community/sam3-tracker-ONNX/onnx/vision_encoder_int8.onnx`). Supported by `winml config`, `winml build`, `winml run`, `winml serve`, `winml perf`, and `winml eval`.

---

Expand Down
34 changes: 28 additions & 6 deletions scripts/e2e_eval/build_registry.py
Original file line number Diff line number Diff line change
Expand Up @@ -128,19 +128,35 @@ def load_optimum_types() -> set[str]:


def load_curated_entries(curated_path: Path) -> list[dict]:
"""Load curated entries (hf_id + task + group + priority) from source JSON."""
"""Load curated entries (hf_id + task + group + priority) from source JSON.

Optional fields recognised by downstream consumers but not enforced here:

* ``composite_onnx`` -- ``{role: hub_onnx_ref}`` map for models that
ship as several role-tagged ONNX graphs (e.g. SAM-family mask
generators with ``image-encoder`` + ``prompt-decoder``). Old
consumers ignore this field; new consumers (e.g.
``mask-generation`` evaluator dispatch) read it to discover the
per-role files. ``hf_id`` is still required and should point at
the canonical repo (typically the encoder's repo).
"""
with curated_path.open(encoding="utf-8") as f:
entries = json.load(f)
return [
{
loaded: list[dict] = []
for e in entries:
if "hf_id" not in e:
continue
item = {
"hf_id": e["hf_id"],
"task": e.get("task") or "",
"group": e.get("group", "P0"),
"priority": e.get("priority", "P0"),
}
for e in entries
if "hf_id" in e
]
# Pass-through additive fields so they survive into the built registry.
if "composite_onnx" in e:
item["composite_onnx"] = e["composite_onnx"]
loaded.append(item)
return loaded


def print_stats(registry_path: Path) -> None:
Expand Down Expand Up @@ -380,6 +396,10 @@ def build_registry(
existing["priority"] = priority
existing["group"] = group
safe_print(f" [{priority}] {model_id} / {task} — updated (group={group})")
# Carry curated ``composite_onnx`` onto an existing entry so
# downstream consumers always see the canonical role map.
if "composite_onnx" in c and "composite_onnx" not in existing:
existing["composite_onnx"] = c["composite_onnx"]
continue

# New curated entry — fetch metadata if not already loaded
Expand All @@ -399,6 +419,8 @@ def build_registry(
"last_update_time": metadata["last_modified"],
"optimum_supported": is_optimum,
}
if "composite_onnx" in c:
entry["composite_onnx"] = c["composite_onnx"]

seen.add(key)
entry_lookup[key] = entry
Expand Down
42 changes: 42 additions & 0 deletions scripts/e2e_eval/testsets/models_with_acc.json
Original file line number Diff line number Diff line change
Expand Up @@ -1927,5 +1927,47 @@
"depth_column": "depth_map"
}
}
},
{
"hf_id": "onnx-community/sam3-tracker-ONNX",
"task": "mask-generation",
"model_type": "sam3_tracker",
"group": "Top200",
"priority": "P2",
"composite_onnx": {
"image-encoder": "onnx-community/sam3-tracker-ONNX/onnx/vision_encoder_int8.onnx",
"prompt-decoder": "onnx-community/sam3-tracker-ONNX/onnx/prompt_encoder_mask_decoder_int8.onnx"
},
"dataset_config": {
"path": "mattmdjaga/human_parsing_dataset",
"split": "train",
"metric": "mIoU",
"samples": 10,
"columns_mapping": {
"input_column": "image",
"mask_column": "mask"
}
}
},
{
"hf_id": "onnx-community/sam2.1-hiera-small-ONNX",
"task": "mask-generation",
"model_type": "sam2",
"group": "Top200",
"priority": "P2",
"composite_onnx": {
"image-encoder": "onnx-community/sam2.1-hiera-small-ONNX/onnx/vision_encoder_int8.onnx",
"prompt-decoder": "onnx-community/sam2.1-hiera-small-ONNX/onnx/prompt_encoder_mask_decoder_int8.onnx"
},
"dataset_config": {
"path": "mattmdjaga/human_parsing_dataset",
"split": "train",
"metric": "mIoU",
"samples": 10,
"columns_mapping": {
"input_column": "image",
"mask_column": "mask"
}
}
}
]
Loading
Loading