Skip to content
Closed
Show file tree
Hide file tree
Changes from 3 commits
Commits
Show all changes
34 commits
Select commit Hold shift + click to select a range
aea97b6
Add vision evaluation CI for VLM recipes with PyTorch comparison and …
apsonawane Jun 4, 2026
a269849
Update requirements
apsonawane Jun 4, 2026
11110cf
Add trigger
apsonawane Jun 4, 2026
238acf6
Add dependencies
apsonawane Jun 4, 2026
64afa0d
Add new models
apsonawane Jun 4, 2026
e827242
pin ort and genai versions
apsonawane Jun 4, 2026
94b8117
Fix precommit
apsonawane Jun 4, 2026
ed34c75
update python version
apsonawane Jun 4, 2026
753037b
Add subprocess
apsonawane Jun 4, 2026
5593f5b
Update requirements and path
apsonawane Jun 4, 2026
41ac0a5
Update
apsonawane Jun 4, 2026
43864a9
Cleanup
apsonawane Jun 4, 2026
e710839
Add datasets
apsonawane Jun 4, 2026
fb23ab0
Run only mmmu test
apsonawane Jun 4, 2026
e7d0710
remove submetric
apsonawane Jun 4, 2026
5f6aafc
Fix
apsonawane Jun 5, 2026
b888148
Run only one model
apsonawane Jun 5, 2026
189528e
Fix eval
apsonawane Jun 5, 2026
0551947
Merge branch 'main' into asonawane/e2e
hanbitmyths Jun 5, 2026
c234fc3
Update models
apsonawane Jun 5, 2026
90b9567
Merge branch 'asonawane/e2e' of https://github.com/microsoft/olive-re…
apsonawane Jun 5, 2026
ee1e833
Add all subjects
apsonawane Jun 5, 2026
c617b41
Update model
apsonawane Jun 5, 2026
64b2e2f
Update tests
apsonawane Jun 5, 2026
7133176
Enable cuda model
apsonawane Jun 5, 2026
995515f
Enable cuda model
apsonawane Jun 5, 2026
c0ba214
Enable cuda model
apsonawane Jun 5, 2026
a8cf28a
Enable cuda model
apsonawane Jun 5, 2026
a31a0f1
remove cuda models and add few cpu models
apsonawane Jun 5, 2026
de1f008
Update Olive branch
apsonawane Jun 5, 2026
db70ffe
Run sequential
apsonawane Jun 8, 2026
1760c10
Update Olive branch
apsonawane Jun 8, 2026
d92e44d
use self-hosted pool and run AI2D test
apsonawane Jun 9, 2026
977a1c4
Merge branch 'main' into asonawane/e2e
apsonawane Jun 9, 2026
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
55 changes: 51 additions & 4 deletions .github/scripts/generate_matrix.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,15 @@
Script to scan the input directory for files with name "olive_ci.json"
and generate output that can be set as strategy matrix for github job.

When --changed-files is provided (one file path per line), only recipes
whose directory contains at least one changed file are included.
This avoids running all recipes when a PR only touches one recipe folder.

Example:
python generate_matrix.py <input directory> <ubuntu|windows> <cpu|cuda>
python generate_matrix.py <input directory> <ubuntu|windows> <cpu|cuda> --changed-files changed.txt
"""
import argparse
import json
import sys
from pathlib import Path
Expand All @@ -18,18 +24,59 @@
"requirements_file": "",
}

dirpath = Path(sys.argv[1])
os = sys.argv[2]
device = sys.argv[3]
parser = argparse.ArgumentParser()
parser.add_argument("dirpath", type=Path)
parser.add_argument("os", choices=["ubuntu", "windows"])
parser.add_argument("device", choices=["cpu", "cuda"])
parser.add_argument("--changed-files", type=Path, default=None,
help="File containing list of changed file paths (one per line)")
args = parser.parse_args()

dirpath = args.dirpath
os = args.os
device = args.device

# If changed-files is provided, compute the set of recipe directories that
# contain at least one changed file. Shared files (e.g. .github/scripts/*)
# trigger all recipes.
changed_recipe_dirs = None
if args.changed_files and args.changed_files.exists():
changed_paths = [Path(line.strip()) for line in args.changed_files.read_text().splitlines() if line.strip()]
changed_recipe_dirs = set()
run_all = False
for p in changed_paths:
# Changes to shared CI scripts or workflows trigger all recipes
if str(p).startswith(".github/"):
run_all = True
break
if run_all:
changed_recipe_dirs = None # None means "run all"
else:
for filepath in dirpath.rglob("olive_ci.json"):
recipe_dir = filepath.parent.relative_to(dirpath)
for p in changed_paths:
try:
# Check if the changed file is inside this recipe's directory
Path(p).relative_to(recipe_dir)
changed_recipe_dirs.add(str(recipe_dir))
break
except ValueError:
continue

recipes = []
for filepath in dirpath.rglob("olive_ci.json"):
recipe_dir = str(filepath.parent.relative_to(dirpath))

# Skip recipes that weren't touched in this PR
if changed_recipe_dirs is not None and recipe_dir not in changed_recipe_dirs:
continue

with filepath.open() as strm:
for config in json.load(strm):
if config["os"] == os and config["device"] == device:
config["name"] = f"{filepath.parent.name} | {config['name']} | {os} | {device}"
config["path"] = str(filepath)
config["cwd"] = str(filepath.parent.relative_to(dirpath))
config["cwd"] = recipe_dir

for key, value in _defaults.items():
if key not in config:
Expand Down
Loading
Loading