GPU package receipts#
Windows GPU checks can use shared/python/windows_installer_payload.py to inspect a
trusted MSIX or administratively extract a trusted MSI into a temporary directory.
The caller profiles the extracted executable and owns artifact identity checks. The
helper estimates disk use before extraction; it is not an enforced quota. MSI
administrative extraction can execute custom actions, so use a trusted runner and
trusted same-run packages. Extraction does not install the app or test installed
behavior. windows_gpu_process.py terminates a timed-out Windows process tree.
The Windows CI fixture checks a real MSI File table and synthetic MSIX archives;
pwsh -File windows/scripts/tests/Test-WindowsInstallerPayloadFixture.ps1 -IncludeRoundtrip also
builds and extracts a text-only MSI with WiX when that tool is available. Neither
fixture installs an application or exercises a GPU.
The windows-clean-gpu-check action accepts the Windows package identity from the
trusted producer resolver, downloads the current-run archive by ID, and runs a
caller-owned PowerShell CPU inference check on a fresh GitHub-hosted Windows x64
runner. It first compares the downloaded files to the current-attempt producer
receipt, then writes a clean-host receipt only if the check succeeds, package bytes
remain unchanged, and scratch cleanup succeeds. The caller owns installation and removal, and must upload
the resulting receipt and pair it with a separate hardware GPU profile receipt.
Before download it reserves 4 GiB after the reported compressed archive size; before
extraction it reserves 2 GiB for the hosted runner and 2 GiB for installer work
after the measured expanded package size. This estimate is not an extraction quota
and does not guarantee an installer will fit. Local and self-hosted GPU checks retain
their separate disk floor.
The same windows_clean_gpu_receipt.py driver supports a trusted self-hosted GPU
check with --check gpu-model-inference --evidence-dir <absolute-empty-directory>.
That directory must be outside --work; the PowerShell callback receives it as
GPU_EVIDENCE_DIR, with GPU_PACKAGE_DIR and GPU_VENDOR. It must write at least
one regular evidence file. The driver verifies the producer receipt before the
callback, rechecks package bytes afterward, rejects linked evidence, and publishes
the GPU receipt only after package scratch cleanup. The caller owns and removes
the evidence directory, including on failure; upload it only after the driver
succeeds. This records the caller’s check, not independent proof of GPU execution.
shared/python/gpu_artifact_receipt.py binds a flat set of named package files to
a caller-supplied CI identity and a named passed check. It uses only the Python
standard library and runs on Windows and Linux. It is a building block; it is not
yet connected to any release workflow.
Both create and verify require the same arguments: --directory, --receipt,
one --file per expected package, --repository, --revision (a full 40-digit
lowercase commit SHA), --run-id, --run-attempt, --artifact-id,
--artifact-digest (the upload action’s bare SHA-256 archive digest), --platform,
--arch, --vendor and --check (a stable check name). IDs and attempts are
positive decimal integers. The supported tuples are Linux x64 NVIDIA/AMD, Linux
arm64 NVIDIA, and Windows x64 NVIDIA/AMD. The receipt must be outside the package
directory; create refuses to overwrite an existing file.
An optional sha256: prefix is accepted and normalized to the same bare digest.
The directory must contain exactly the named regular files: extras, subdirectories,
links, duplicate names and path components fail. The receipt records each file’s
SHA-256 separately from the Actions archive digest. verify compares the caller’s
expected identity and filenames against the receipt and rehashes the packages.
Malformed or duplicate JSON fields and a status other than passed fail.
For a trusted Linux x64 NVIDIA job, for example, assemble the arguments from the workflow’s own context and the upload action’s outputs, then use them after the checks described below:
receipt_args=(--directory "$PACKAGES" --receipt "$RECEIPT"
--file app.deb --file app.AppImage --repository "$GITHUB_REPOSITORY"
--revision "$GITHUB_SHA" --run-id "$GITHUB_RUN_ID" --run-attempt "$GITHUB_RUN_ATTEMPT"
--artifact-id "$ARTIFACT_ID" --artifact-digest "$ARTIFACT_DIGEST"
--platform linux --arch x64 --vendor nvidia --check gpu-model-inference)
python3 shared/python/gpu_artifact_receipt.py create "${receipt_args[@]}"
python3 shared/python/gpu_artifact_receipt.py verify "${receipt_args[@]}"
A receipt does not prove a GPU check happened or authenticate its author. A trusted workflow must download an immutable artifact ID with digest verification, hash the packages before the hardware test, run the real named check against those same bytes, and confirm their hashes did not change before creating a passed receipt. This tool compares the supplied artifact ID and archive digest as identity strings; it does not fetch GitHub metadata or independently verify the downloaded archive. The workflow must obtain those values from trusted upload metadata and validate the archive using a digest-verifying download action before invoking the tool. Promotion must independently obtain the expected repository, commit, run, attempt, artifact ID and digest from trusted workflow context, download that same ID, verify the passed receipt and hashes, and enforce the required check for every tuple. Do not read the expected values solely from the receipt being checked. Checks on an untrusted runner cannot be made trustworthy by this file. Coordinate access to the directory so other processes cannot replace files while they are being hashed.
An overwritten Actions artifact is a new artifact: bind to its ID, not only its name. On a rerun, require matching run attempt and recreate all dependent receipts; do not promote a stale receipt or a different matrix entry. GPU releases also need explicit expected asset names and their existing clean-host and license checks.
The resolve-gpu-producer action runs on Linux and accepts a trusted producer-verified receipt and
an exact attempt-scoped artifact name. It independently queries the current workflow
run’s artifact metadata, requires one non-expired matching artifact, and compares
its ID and digest with the receipt before returning them and the package filenames.
The calling job needs actions: read. The caller must form the name from the current
run, attempt and validated GPU tuple, and must verify that its upload contains the
producer-hashed package bytes before publishing the receipt. This resolver does not
run a GPU check or authenticate a receipt from an untrusted producer.
Linux artifacts retain the existing DEB, tarball and AppImage contract. Windows x64 GPU
callers must set package-layout explicitly to zip (one ZIP), installers (MSI,
MSIX and test certificate) or zip-installers (all four); the installer files and
certificate must share a stem. Both -testcert.cer and -test-signing.cer match the
existing installer producers. For AccelerANTgine, accelerantgine expects the actual
CPack ZIP/MSI stem and its four-component, underscore-named MSIX; it permits one
matching .cer, -testcert.cer or -test-signing.cer, but the current producer does
not guarantee a certificate. Windows ARM GPU tuples are rejected. This check does
not run Windows installers or verify GPU inference: separate trusted clean-host and
hardware receipts are still required before staging.
For Windows GPU artifacts, Assert-PackageOrtFamily in
WindowsPackageBinary.Common requires exactly the named ORT-family DLLs in a
declared bundle or ZIP, MSI, MSIX or NSIS setup directory. Unexpected, duplicate, nested or
linked ORT-family files fail, including files outside that directory. MSI checks
the installed file table and root-relative paths; an NSIS setup its $INSTDIR-relative listing. This census does not verify
the files’ bytes: use Assert-PackageBinary against wheel-proven inputs and
verify their notices separately.
Assert-PackageOrtProviderSet -Path <package> -Directory <dir> -Expected <names> -Label <name>
compares one package directory’s ORT provider DLLs with a proven list. It reads the package
through Get-PackageOrtProviderNames, with the same MSI root parameters. -Expected may hold the
whole proven family: only onnxruntime_providers_*.dll names count, and order does not. A missing
or an extra provider fails, and the message names both sets after the label. A proven list
without a provider, a duplicate or a miscased provider name fails too. It does not verify the
providers’ bytes.
Stage checked bytes for a release#
shared/python/stage_gpu_artifact.py accepts the raw, flat ZIP of a single
Actions artifact, two receipts and independently supplied CI identity fields.
Download the artifact by its immutable ID with actions/download-artifact@v8,
skip-decompress: true and digest-mismatch: error; derive the expected ID and
SHA-256 digest from the trusted upload step. Pass the current repository, commit,
run and attempt from the trusted workflow context. The script hashes the raw ZIP
and requires it to match that digest, then checks the two distinct receipts for
clean-host-inference and gpu-model-inference, the same identity, exact filenames
and the hashes of the ZIP’s actual package bytes.
Pass --file once per explicitly expected package, and set positive
--max-uncompressed-bytes and --max-compression-ratio limits for the intended
packages. Extra, duplicate, nested, linked and encrypted entries fail. The output
must be a nonexistent path under an existing real directory. Files are written in
a temporary sibling and published atomically without replacing an existing path;
Linux requires renameat2 with RENAME_NOREPLACE support from the output
filesystem; Windows requires its no-replace rename. Some filesystems, including
WSL DrvFs mounts such as /mnt/c, can reject this operation. Use a filesystem
that supports it, such as a suitable native Linux filesystem; the script reports
the error and fails closed instead of falling back to a replacing rename. A failed
run must never be followed by upload, and callers must guard against other processes
changing inputs or the output during and after the operation.
This staging step does not fetch the artifact or authenticate either receipt. Only trusted jobs that verified and tested the exact artifact may produce those receipts, and the caller must obtain the expected identity independently. It does not run GPU inference, create a release, or establish that a physical GPU was used. Each caller must explicitly wire successful check jobs and upload only the staged output.
Linux check actions#
clean-host-package-check retains its existing name-based download by default.
For a GPU receipt, a trusted caller supplies artifact-id, artifact-digest,
the three exact artifact-files, vendor, architecture, output receipt path and
expansion limits. It downloads the raw archive by ID, checks the trusted digest,
extracts the packages, and records their hashes before running its usual clean-host
commands. Only after those commands succeed and the same files still match does it
write a clean-host-inference receipt. All three DEB, tarball and AppImage checks
and their commands are required in this mode; partial inputs fail before download.
gpu-package-check applies the same pre/post protocol around a trusted Linux GPU
profiling command, with the extracted packages in GPU_PACKAGE_DIR. The command
must actually profile each expected package on the requested physical GPU; its
exit status and the receipt alone cannot prove that it did. A caller must upload
both receipts only after their corresponding checks succeed, and use the current
run’s immutable artifact ID and upload digest for the staging step.
For default MIGraphX verification, source linux/scripts/lib/gpu-profile-env.sh
and call gpu_without_migraphx_overrides COMMAND [ARG...]. It removes inherited
MIGRAPHX_* and ORT_MIGRAPHX_* variables from that command’s environment while
preserving the caller’s environment and GPU visibility. Apply any intentional
diagnostic setting inside the command; a diagnostic run does not establish default
runtime behavior. Callers still select and verify the physical GPU independently.
Comparing a Windows AMD display with WSL HIP#
For a local WSL check, first enumerate Windows display devices with
Get-PnpDevice -Class Display. Pass the exact AMD PCI device InstanceId to
windows/scripts/diagnostics/Get-AmdDisplayPciAddress.ps1. The read-only helper
requires that device to be healthy and its bus/device/function to be unique among
Windows PCI display devices. It prints an address such as 18:00.0.
In the same Linux or container environment that will run the application, with the
same runtime library and visibility settings, call
python3 -I shared/python/verify_hip_adapter.py --pci-address 18:00.0 using the
Windows result. It loads libamdhip64.so.7, requires exactly one HIP-visible GPU
and matches the HIP-reported PCI address in domain zero. The command never changes
which devices are visible. A missing device, multiple visible GPUs, a nonzero domain,
an inaccessible runtime or an address mismatch fails the check.
This comparison does not prove PCI-address equivalence on every WSL configuration,
that the application loaded the same HIP library, or that ORT ran on the device;
retain separately verified provider profiles and output-parity checks. It also does
not establish a stable GPU UUID: the WSL iGPU inspected on 2026-10-31 returned a HIP
UUID with bytes 5858 followed by zeros. Recheck both sides after hardware or driver
changes, and do not assign that value to another adapter.
Detector parity#
shared/python/compare_detector_parity.py CPU.json GPU.json compares detections
from the two-cats fixture. Both inputs use schema version 1 with image dimensions
and detection classes, scores and pixel boxes. It requires a credible CPU baseline
and a one-to-one class, score and box match. Empty, malformed and non-finite results
fail. Callers must run the actual packaged detector twice, independently verify the
CPU and GPU operator profiles, and pass results from those same runs. A match alone
does not establish GPU execution or prove parity on other images.
After validating a CPU baseline against every result, use --pairwise to compare
repeated results to each other. It retains the schema, bounds and one-to-one tolerance
checks without reapplying the CPU-only two-cats score oracle to a GPU reference.
Pairwise checks must not replace the default CPU-baseline checks.
The three-process run. shared/python/check_detector_parity.py is the run a consumer’s Windows GPU
lane makes around the comparator: the packaged detector in three processes (CPU, the GPU, the GPU again),
each writing an output, a repeat and one provider profile; verify_ort_profile.py --min-runs 2 on each
profile; and the comparator over every pair of the six outputs, --pairwise unless the CPU output is
one side. Each child gets a clean environment (no inherited KATAGLYPHIS_, ORT_, MIGRAPHX_ or
GST_ variable), the package’s own onnxruntime.dll, which must be a regular file in the stage, and
on DirectML the adapter index that verify-dxgi-adapter.py checked. The photo must match its SHA-256.
A consumer’s scripts/windows/check_gpu_detector_parity.py keeps only the launcher command and its
model check, and calls check_parity(hub, stage, device, index, work, launch, run).
linux/scripts/tests/test-detector-parity.sh runs both with a fake detector as a real subprocess.
Tensor diagnosis#
shared/python/summarize_detector_tensors.py CPU_DIRECTORY GPU_DIRECTORY --runs 2 --output NEW_JSON summarizes raw model tensors when investigating detector
differences. Carry compare_detector_parity.py beside it for the canonical
duplicate-key JSON reader; the command supports isolated Python execution.
Each directory contains exactly run-N.json, run-N-input.f32le and
run-N-output.f32le for every requested run. Schema1 metadata names each fixed
payload, its positive integer shape, float32 type and little-endian byte order.
Files must be regular and nonempty, byte counts must match, and values must be finite.
Every CPU/GPU input shape and exact byte hash must match before output comparison.
The report retains repeat identities, every cross-pair’s error statistics, raw
array coordinates and per-axis maxima for small axes. Different outputs can
produce a successful diagnostic report with acceptance: false; there is no raw
tensor tolerance or implicit GPU verdict. Existing summaries are never overwritten.
These files trust the recording application and do not authenticate model/binary
identity, prove GPU execution or replace the ordinary photograph comparator,
per-run operator profiles, exact package binding and hardware checks above.
The prepared OxidANT onnx-detect --tensor-snapshots NEW_DIRECTORY captures the
real preprocessed input and first output before postprocessing on each model run.
To replay a captured input without the consumer binding or postprocessing, use the family image’s SDK and a new output directory:
bash linux/scripts/build-native-tensor-replay.sh NEW_BUILD ORT_SDK_PREFIX
bash linux/scripts/check-native-tensor-replay.sh NEW_BUILD CORE RELU_MODEL
NEW_BUILD/ort-tensor-replay CORE MODEL 1,3,640,640 INPUT.f32le cpu NEW_CPU
ORT_AMDGPU_EP_ROOT=PLUGIN_PREFIX NEW_BUILD/ort-tensor-replay CORE MODEL 1,3,640,640 INPUT.f32le migraphx NEW_GPU
The Linux replay opens the explicit core, uses ort_plugin_eps.hpp registration,
selects GPU device zero, and runs twice in one session with default intra-op
threads and spinning enabled. It records the first model output as host float32,
plus raw inputs and an ORT profile. Check each profile with
verify_ort_profile.py --min-runs 2 and summarize both tensors/ directories;
raw exit zero does not apply the detector’s score tolerance or prove acceptance.
For repeated host probes, keep that sequence in the reusable pair transport:
bash linux/scripts/replay-native-tensor-pair.sh HOST_PYTHON NEW_PAIR MODEL 1,3,640,640 INPUT.f32le -- \
env ORT_AMDGPU_EP_ROOT=PLUGIN_PREFIX LD_LIBRARY_PATH=EXPLICIT_LIBS \
LOADER --library-path EXPLICIT_RUNTIME_LIBS NEW_BUILD/ort-tensor-replay CORE
The prefix ends at CORE; the driver appends model, shape, input, device and a
new device-specific output path without reparsing arguments. It runs CPU then
MIGraphX, removes inherited MIGraphX tuning overrides, requires exactly one profile
for each, invokes the isolated Python profile probe with two required runs and
only then summarizes all raw cross-pairs. It preserves failing native, profile
and summary statuses and refuses an existing pair directory. Use an explicit
host interpreter; the command does not provision an image interpreter. Keep
cli-value-options.sh, gpu-profile-env.sh and their logging companion in lib/,
and both Python probes plus compare_detector_parity.py in the shared layout.
Protocol-double tests do not establish actual model/provider execution.
Preserve the exact executable, core, plugin, input/model hashes, environment, loader search order and runtime library closure for each comparison. Swapping a core/plugin pair under a fixed closure does not replay its entire original image.
Both native SDK probes carry ort_probe_session.hpp and ort_plugin_eps.hpp.
Options and input memory-info remain owned until after their dependent objects.
The builder uses the shared compiler-cache launcher, records cold/warm object
hashes/statistics and resolves the source-built GCC prefix before Clang links.
The ownership probe retains its original sanitizer policy with that same GCC
selection. SDK-free transport tests check independent little-endian bytes,
shape/count/finite-input and no-overwrite refusals with assertion controls;
they do not execute ORT. The SDK command proves tiny CPU inference and precise
refusals, including a missing plugin; it does not prove GPU execution, sanitizer
cleanliness or consumer parity. Those require their separate actual runs.
For an intermediate tensor, use shared/python/prepare_onnx_tensor_replay.py
with an existing ONNX-enabled tooling interpreter, separate from the consumer:
python prepare_onnx_tensor_replay.py inventory ORIGINAL.onnx --model-sha256 SHA256 --output NEW_INVENTORY.json
python prepare_onnx_tensor_replay.py expose ORIGINAL.onnx --model-sha256 SHA256 --tensor EXACT_NAME --output NEW_MODEL_DIRECTORY
The inventory records topological node/output positions, names, operators and inferred types/shapes. Only known top-level float32 outputs with rank one through eight and no known nonpositive dimension can be exposed. Unknown dimensions remain unknown; the native replay validates their actual runtime shape. The tool requires the original hash, strict shape inference and the ONNX checker. It refuses external tensor data, nested graphs, local functions and sparse payloads. The diagnostic retains all original outputs, puts the selected tensor first and checks that node and initializer bytes did not change. Its manifest records both model hashes and the actual ONNX version; outputs require new files/directories. It does not install or update dependencies, and the media image need not contain the ONNX preparation module. Reuse a recorded tooling environment and preserve its interpreter/module identity with the invocation.
Run NEW_MODEL_DIRECTORY/model.onnx through the native replay with the same
captured input and fixed runtime closure. Verify every repeated provider profile
and summarize the raw tensors as above. Adding outputs can alter optimization
and fusion even when nodes and weights match. A divergence in this instrumented
model is not by itself the first failing operator of the original model. Preserve
the original-model photograph parity result separately. Source regressions use
schema doubles and omission mutations; real ONNX preparation and actual device
execution need their own evidence.
Zero-pad/MaxPool regression fixture#
linux/scripts/prepare-migraphx-padding-reproducer.py NEW_DIRECTORY uses an
existing ONNX tooling interpreter to preserve an independent negative-input
fixture, original expected bytes and hashes. Its 2x2 input is [-1,-2;-3,-4];
explicit zero padding on the bottom/right followed by a 2x2 stride-one MaxPool
must yield [-1,0;0,0]. The padded tensor remains a second graph output so the
native CPU baseline stays independently checkable. Without that output, the
first attempted fixture already produced unexpected CPU values and cannot
isolate the GPU compiler. Validate the CPU result before any negative control.
Use the pair driver for this fixture in separate default and explicit control
processes. MIGRAPHX_DISABLE_PASSES=eliminate_pad in the command prefix is a
semantic diagnostic control, not an accepted shipping policy. Preserve both
raw outputs and every repeated provider profile. A narrow source guard is
prepared at linux/scripts/patches/migraphx/001-preserve-zero-pad-maxpool.patch;
the real original and patched passes compile against the image SDK with the
same updated upstream test object. The original negative case fails with the
wrong boundary values; all six patched upstream tests pass, including the
existing convolution/im2col cases. Linux currently installs MIGraphX through
AMD apt, so producer wiring and actual corrected-byte/default-policy acceptance
remain required. This standalone pass proof does not replace the backend. The independent fixture does not replace the original photograph or
any finished-consumer/image receipt.
The reusable source check is:
bash linux/scripts/probe-migraphx-padding.sh NEW_OUTPUT VERIFIED_UPSTREAM_SOURCE MIGRAPHX_SDK
It applies the canonical patch, compiles one updated test object and both real
pass variants, requires the original numerical assertion to fail, and runs the
complete patched upstream test file. Every object has a cold/warm cache receipt
and byte comparison. Both executables define the pass symbol themselves. Compiler selection is shared
with the native tensor replay builder through lib/native-cxx-probe.sh; copied
standalone probes must retain that helper, cli-value-options.sh, its logging
companion and the canonical core companions. The
generated libmigraphx-padding-probe.so is a selective source-interposition
diagnostic only; loading it does not establish a shipped compiler fix. The actual selective probe restores both the independent boundary case and the
unchanged original detector tensor: the previously failing class-15 score differs
from CPU by about 0.00003955, CPU bytes match the original baseline, and both
GPU runs contain provider operators. Loader bindings prove use of the corrected
pass. Preserve this as a preload diagnostic; ordinary package defaults and
shipped-backend acceptance remain open. The
auto-discovered policy suite compiles the actual patched function with typed
graph doubles and checks MaxPool, average and the existing LP fold; it does not
prove SDK numerics or GPU inference. Fixture-preparation tests use schema doubles.
A package on your own GPU#
No hosted runner has a GPU, so a package has run on one only where someone ran it. On Windows, unpack
the package and run its detector on ModelANT’s contracts/fixtures/two_cats.jpg, on the CPU and then
on the GPU:
Repository |
Command |
|---|---|
OxidANT |
|
AccelerANTgine |
|
OmniAccelerANT |
|
OrchestrANT |
|
Compare with compare_detector_parity.py cpu.json gpu.json, then check the GPU run’s profile with
verify_ort_profile.py PROFILE.json --device directml. Take both. On 2026-11-02 an RX 9070 XT ran
deim_dfine_n_coco-v1 with every profiled operator on DmlExecutionProvider and returned no
detection, because DirectML computes MatMul by a 1-D vector wrongly; v2 returns the CPU’s detections.
To build a GPU package yourself, run the repository’s Windows build inside :winamd64-nvidia or
:winamd64-rocm: AccelerANTgine’s Invoke-ContainerBuild.ps1 -OrtVariant nvidia|amd -Image IMAGE
or OmniAccelerANT’s Build-Windows.ps1 -OrtProvider cuda|directml.
On Linux#
Run natively, not under WSL, where an RX 9070 XT hangs at its first HIP copy (BACKLOG CON202). These scripts run the finished packages on the CPU and the GPU; only self-hosted jobs call them, and no such runner exists yet, so a first run may find faults in the scripts themselves.
The machine needs the vendor’s driver and the user-space runtime the packages load from the host
(on AMD: TheRock’s HIP and MIGraphX at the image’s pins, set up in
linux-host-setup.md § A4b),
gh, python3, dpkg-deb and xvfb-run, and your user in the render and video groups. With a
second GPU, keep the card you mean to test selected: an enabled gfx1036 iGPU has no MIGraphX
kernels, so disable it in the firmware or set HIP_VISIBLE_DEVICES.
Clone each repository with git clone --branch develop, then git submodule update --init without
--recursive, which fails on the depth of the nested submodules. Take the newest green run:
id=$(gh run list -R Kataglyphis/REPO --workflow WORKFLOW --branch develop --status success --limit 1 \
--json databaseId --jq '.[0].databaseId')
gh run download "$id" -R Kataglyphis/REPO -n ARTIFACT -D ~/gpu/REPO
REPO |
WORKFLOW |
ARTIFACT |
Command, with |
|---|---|---|---|
OxidANT |
|
|
|
AccelerANTgine |
|
|
|
OrchestrANT |
|
|
|
OmniAccelerANT |
|
|
|
The NVIDIA artifacts swap amd for nvidia. two_cats.jpg is ModelANT’s contracts/fixtures/two_cats.jpg.
A GPU run that compiles the detector’s kernels from a cold comgr cache takes about six minutes on a gfx1201;
OmniAccelerANT’s launch budget is 900 s (PROFILE_GPU_TIMEOUT), and its AppImage lane is cold on every run
(failure-modes). On 2026-11-07 all
four AMD packages passed on an RX 9070 XT.
Repeated ORT profile runs#
python3 shared/python/verify_ort_profile.py PROFILE.json --device migraphx --min-runs 2
requires at least two complete, non-overlapping model_run intervals in one
process, and a non-copy model operator on the requested provider fully inside
every complete run. Qualifying intervals need valid timing; a run without a
matching provider event fails. Omitting --min-runs retains the single-profile check.
The trace identifies a process, not an ORT session; callers must independently
ensure repeated runs use the same session and compare their outputs. A provider
event alone does not establish correct results or physical GPU execution.
--device xnnpack and --device dnnl apply the same operator rule to ORT’s CPU
accelerator providers, so a session that fell back to CPUExecutionProvider fails.
Reusable workflow invocation scopes#
For each callable GPU workflow, pass the caller’s optional scope through the environment
as GPU_INVOCATION_SCOPE to python3 -I shared/python/gpu_invocation_scope.py before
using it. The helper writes suffix to GITHUB_OUTPUT: the default scope produces an
empty suffix, and another valid scope produces -scope-<scope>. Scopes must match
[a-z][a-z0-9-]{0,31}; invalid values fail before the output file is opened. Callers
of the same reusable workflow in one parent run must use distinct scopes, including
when their selected GPU targets overlap. The caller remains responsible for uniqueness.
Use the validated output consistently in attempt-scoped artifact names, receipts and scratch paths, and in job concurrency groups after the validation job succeeds. Do not use raw scope input in a cancellation-sensitive group before validation. A scope separates evidence; it does not authenticate an artifact or verify GPU execution.
GPU workflow invariants#
Rules for the reusable GPU workflows, their artifacts and the GPU diagnostics. Each item is one rule.
The reusable Python Linux GPU lane checks the consumer pin before pulling, forwards the default-off host-runtime input only to packaging, and isolates unverified outputs.
Its optional nondefault invocation scope requires attempt-scoped GPU uploads, uses a case-sensitive plan and the pinned validator before the build, and scopes both package and always-uploaded test-report names. CPU/default plans remain checkout-free.
Its optional attempt-scoped GPU artifacts use the current run attempt and never overwrite. CPU and default GPU names remain unchanged.
Release collection always skips upload names containing
candidate,unverifiedorinventory-only, regardless of case. User skip globs stay case-sensitive. A promoted GPU upload needs separate checks and expected asset names.GPU package receipts bind exact filenames and hashes to a caller-supplied check and CI identity. They do not authenticate or run that check. Preserve the trust and pre/post-test requirements in
docs/gpu-artifact-receipts.md.The GPU producer resolver independently matches the current run’s artifact ID and digest against its receipt. Preserve attempt-scoped names and trusted producer checks.
Windows GPU producer resolution requires an explicit package layout and checks matching versions and vendor across package names. Windows ARM GPU tuples remain unsupported.
Reusable GPU workflow invocation scopes use the shared validated suffix for artifact names and job concurrency. Raw caller input must not cancel a valid invocation before validation.
GPU artifact staging checks the raw archive digest, both required check receipts and exact expanded files before atomic no-replace publication. Trusted callers remain responsible for receipt provenance and hardware checks.
GPU detector parity uses the shared two-cats comparator. Validate the CPU baseline before using
--pairwisefor repeats, and require real provider profiles and matched results. For repeated inference,verify_ort_profile.py --min-runsrequires provider operators in every complete sequential run. Process identity alone does not prove one session.GPU loader-origin checks use
shared/python/verify_ort_loader_trace.py. Profile-bound checks select the matching PID trace and retain the canonical provider/run verdict. Every selected ORT/plugin record must match that PID, including duplicate records. Unrelated fork-child libraries may share the trace. Paths and process identity do not prove bytes or one ORT session.Loader trace parent segments require explicit live root resolution, normalized package-directory agreement and actual containment. CLI roots remain canonical, and raw trace paths stay in the receipt.
Tensor diagnostics compare every repeated input before describing model-output differences. A successful diagnostic never grants numerical/provider/package acceptance. Copy
compare_detector_parity.pybesidesummarize_detector_tensors.pyfor its canonical JSON reader.Native tensor replay and the tiny SDK probe carry
ort_probe_session.hppbesideort_plugin_eps.hpp. Preserve caller-owned options/input memory and use the canonical GCC toolchain for Clang SDK links. Raw replay success never grants parity.Intermediate-tensor diagnostics bind the original and instrumented model hashes and preserve node/initializer bytes. Exposed outputs can change fusion, so they cannot replace original-model or finished-consumer acceptance.
Native C++ diagnostic builders carry
lib/native-cxx-probe.sh. Preserve its caller-visible launcher, GCC root, single-argument toolchain flag and raw failures.The opt-in Linux clean-host and GPU profile actions download by immutable ID, check the upload digest and compare the same packages before and after the actual check. Keep the default CPU name-based path.