transformers
Exporters: run exported models on their backend's runtime (`ModelRunner`)
#50032
Merged

Exporters: run exported models on their backend's runtime (`ModelRunner`) #50032

IlyasMoutawwakil merged 74 commits into main from exporters-forward-runtime
IlyasMoutawwakil
IlyasMoutawwakil Exporters: return ExportArtifacts, split backends into export_artifac…
e9b4b630
IlyasMoutawwakil Exporters: load and push ExportArtifacts, record the saved graphs' ow…
710d30fc
IlyasMoutawwakil Exporters: prefix OpenVINO's saved files with `openvino_`
f50273fd
IlyasMoutawwakil Exporters: simplify the artifacts API after review
10050aaf
IlyasMoutawwakil Exporters: name a single graph a program, load ONNX lazily, test agai…
22ad2de0
IlyasMoutawwakil Exporters: load saved ONNX lazily, record positional metadata for Exe…
b339c72c
IlyasMoutawwakil IlyasMoutawwakil requested a review from echarlaix echarlaix 36 days ago
HuggingFaceDocBuilderDev
IlyasMoutawwakil IlyasMoutawwakil marked this pull request as ready for review 36 days ago
echarlaix
echarlaix approved these changes on 2026-10-28
ArthurZucker
ArthurZucker approved these changes on 2026-11-02
IlyasMoutawwakil Exporters: load through cached_files, plain ExportMetadata fields, re…
b14325a4
IlyasMoutawwakil Exporters: register a backend by its exporter, export every component…
2fcae0d9
IlyasMoutawwakil Exporters: run single-graph exports (ExportedModel, AutoExportedModel)
54eb6f1d
IlyasMoutawwakil Exporters: sort the runtimes import, return only tensors from the Exe…
942a0a73
IlyasMoutawwakil Exporters: rebuild the model's outputs from the traced specs, drop Au…
7de7cb11
IlyasMoutawwakil IlyasMoutawwakil changed the title Exporters: run exported models (`ExportedModel`, `AutoExportedModel`) Exporters: run exported models (`ExportedModel`) 30 days ago
IlyasMoutawwakil IlyasMoutawwakil force pushed from 75f27de6 to 7de7cb11 30 days ago
IlyasMoutawwakil Exporters: register the cache classes a saved export's specs name bef…
4f164d4e
IlyasMoutawwakil Exporters: keep ONNX Runtime CUDA inputs and outputs on the GPU (IO b…
c8818751
IlyasMoutawwakil Exporters: run ONNX through IO binding on every device, save a runtim…
fa127e11
IlyasMoutawwakil Exporters: bind only tensor inputs on ONNX, copy OpenVINO outputs once
6b9fba9b
IlyasMoutawwakil Exporters: feed ExecuTorch string constants as None, keep non-string …
69c33a98
IlyasMoutawwakil Exporters: let runtime() pass runner options, ONNX Runtime providers …
b7a1d1b4
IlyasMoutawwakil Exporters: compile OpenVINO in the export's precision on CPU, take co…
c4f40cf5
IlyasMoutawwakil Exporters: choose per call whether a runner shares its inputs and out…
ef7dacfa
IlyasMoutawwakil Exporters: give a torch program the scalars it was traced with, in it…
3b861dd7
IlyasMoutawwakil Exporters: record a None kwarg as a constant too
62191414
IlyasMoutawwakil Exporters: bind ONNX inputs by name, run bf16 convolutions in fp32 on…
6d80fa4b
IlyasMoutawwakil Exporters: feed SDPA's boolean mask to ONNX as an additive one
fc78285f
IlyasMoutawwakil Merge branch 'exporters-artifacts' into exporters-forward-runtime
fc65352a
IlyasMoutawwakil Exporters: feed bf16 inputs to OpenVINO as bf16 tensors
b6f63b47
IlyasMoutawwakil Exporters: read bf16 OpenVINO outputs as bf16
41c68b16
IlyasMoutawwakil Exporters: split the CPU between torch and OpenVINO (`torch_threads`)
90024083
IlyasMoutawwakil Exporters: import torch in the quantizers' utils only when it's avail…
e6472aa3
IlyasMoutawwakil Merge branch 'main' into exporters-artifacts
e207dc34
IlyasMoutawwakil Merge branch 'exporters-artifacts' into exporters-forward-runtime
e1afad0a
IlyasMoutawwakil Exporters: an export returns an ExportedModel, not ExportArtifacts
ad541c1d
IlyasMoutawwakil Exporters: simplify the export plumbing
5a191224
IlyasMoutawwakil Tests: expect the single unknown-format error for a missing format
d1b5bb87
IlyasMoutawwakil Merge branch 'exporters-artifacts' into exporters-forward-runtime
54836cf6
IlyasMoutawwakil Exporters: an ONNX export's program is its onnx_ir.Model, not an ONNX…
677743b7
IlyasMoutawwakil Exporters: an ONNX export loaded from the Hub cache saves again; save…
3b09dad8
IlyasMoutawwakil Merge branch 'exporters-artifacts' into exporters-forward-runtime
ef9a7eb0
IlyasMoutawwakil Exporters: load a .pte from its file, record the output spec with the…
680b63a8
IlyasMoutawwakil Exporters: save loaded exports again safely; load remote-code configs…
b480efae
IlyasMoutawwakil Merge branch 'exporters-artifacts' into exporters-forward-runtime
dde03d49
IlyasMoutawwakil Exporters: runtimes/ is runners/; size an ONNX graph's weights by `is…
e38b917b
IlyasMoutawwakil Exporters: convert the export config where it is used
42138b79
IlyasMoutawwakil Merge branch 'exporters-artifacts' into exporters-forward-runtime
c68ed315
IlyasMoutawwakil Exporters: one single-component check, one import-on-use step; drop u…
8fe966d4
IlyasMoutawwakil Exporters: clearer names; the export config serializes itself
edb1ec98
IlyasMoutawwakil Merge branch 'exporters-artifacts' into exporters-forward-runtime
33c1afef
IlyasMoutawwakil Exporters: runner_<backend> modules; from_pretrained takes hub option…
02e37d17
IlyasMoutawwakil Exporters: to_json_string without a trailing newline
53e45bba
IlyasMoutawwakil Merge branch 'exporters-artifacts' into exporters-forward-runtime
c43b13d6
IlyasMoutawwakil Exporters: examples and decode tests run through ExportedModel
e0e27289
IlyasMoutawwakil Exporters: a runnable ONNX quantization example; inline the one-use c…
96584b3c
IlyasMoutawwakil Merge branch 'exporters-artifacts' into exporters-forward-runtime
ed010764
IlyasMoutawwakil Exporters: the ONNX runner defaults to CUDA only when a GPU is there
8a9be2ac
IlyasMoutawwakil Tests: configs are serialized now, just never read back from a dict
c3bc94e3
IlyasMoutawwakil Merge branch 'exporters-artifacts' into exporters-forward-runtime
77ba571b
IlyasMoutawwakil IlyasMoutawwakil changed the title Exporters: run exported models (`ExportedModel`) Exporters: run exported models on their backend's runtime (`ModelRunner`) 21 days ago
IlyasMoutawwakil Exporters: leave the SDPA mask change to #50309; dtype from the metad…
a5f786cd
IlyasMoutawwakil Exporters: import repeat_kv only with torch, so the OpenVINO exporter…
13f4ebbb
IlyasMoutawwakil Merge branch 'exporters-artifacts' into exporters-forward-runtime
ab8a94a6
Base automatically changed from exporters-artifacts to main 21 days ago
IlyasMoutawwakil Exporters: upcast a 16-bit model's small tensors by swapping in f32 c…
4f4c1984
IlyasMoutawwakil Exporters: ONNX Runtime CUDA graphs in the runner; GatherND at consta…
8ec04c1b
IlyasMoutawwakil Merge remote-tracking branch 'origin/main' into exporters-forward-run…
a88c206c
IlyasMoutawwakil Exporters: load the ONNX Runtime quantizer's tensor attributes before…
c9273d8a
IlyasMoutawwakil Exporters: regression tests for the quantizer's tensor attributes and…
78999a16
IlyasMoutawwakil Exporters: the ONNX runner keeps one CUDA graph
a6260a4b
IlyasMoutawwakil IlyasMoutawwakil enabled auto-merge 21 days ago
disabled auto-merge 21 days ago
Manually disabled by user
IlyasMoutawwakil
IlyasMoutawwakil Exporters: record a 16-bit OpenVINO export's own precision, which the…
e84ff1b3
IlyasMoutawwakil Exporters: record a 16-bit OpenVINO export's precision on the model, …
e0d10561
IlyasMoutawwakil Exporters: broadcast in numpy mode in OpenVINO graphs, which the CPU …
7b408b9c
IlyasMoutawwakil Tests: bf16 export tolerances at 1e-2; the bf16 ONNX test needs CUDA
5f0d8448
IlyasMoutawwakil Exporters: keep a rank-adding expand's broadcast bidirectional in Ope…
17845075
IlyasMoutawwakil Exporters: refuse a CUDA graph replay at another shape; stale runner …
0e10ad26
IlyasMoutawwakil Tests: run the Dynamo generate export through its runner; eager outpu…
b0554924
IlyasMoutawwakil Exporters: share the ONNX/OpenVINO graph I/O plumbing; fix the runner…
0a0fa0a3
IlyasMoutawwakil Exporters: size `beam_idx` from the cache's batch; bicubic antialias …
e7aa62df
IlyasMoutawwakil Merge remote-tracking branch 'origin/main' into exporters-forward-run…
4c9dc079
IlyasMoutawwakil IlyasMoutawwakil merged 57583c28 into main 20 days ago
IlyasMoutawwakil IlyasMoutawwakil deleted the exporters-forward-runtime branch 20 days ago

Login to write a write a comment.

Login via GitHub

Assignees
No one assigned
Labels
Milestone