﻿# ONNX Runtime Split 18: an empty optional input slot is not a supplied split tensor

Split in the 1.32 notes distinguishes an omitted optional value from a second slot; validate exporter placeholders and actual split semantics separately.

Author: Retrivium team
Updated: 2026-11-15
Canonical URL: https://retrivium.ai/journal/week46-engine-ort-split-empty-optional-edge/
Language: en

ONNX Runtime 1.32.0 includes Split handling for num_outputs with an empty optional split edge. The linked PR distinguishes the number of input slots from whether the second value exists. A positional placeholder can therefore be valid even though a check based only on list length would reject the model.

## A slot is part of a positional interface

Optional ONNX inputs preserve positional meaning even when a value is omitted. The PR repairs a constructor check that treated a two-slot list as if the second tensor were necessarily present. A proposed regression serializes the empty placeholder explicitly and checks successful model loading. Also keep a genuinely supplied split tensor as a separate case, so the fix does not accidentally erase the distinction it is intended to restore.

## Loading is only the structural check

After initialization, verify the output partitions against the operator’s num_outputs behaviour. Include even and uneven division where the chosen opset allows it. A graph that now loads but selects the wrong splitting rule would still be incorrect. Use distinguishable sequential values so an omitted, repeated or shifted section is obvious, and verify output order as well as total element count.

## Preserve exporter representation in the reproducer

A test harness that rebuilds the node and drops empty strings may avoid the exact serialized form that triggered the issue. Keep the original model bytes or inspect the input list after serialization. This is especially important when two exporters express the same omitted input differently. Compare the actual installed runtime with the intended model artifact rather than assuming that a hand-built equivalent reaches the same validation branch.

## Do not generalize an omission fix into schema freedom

The change concerns an allowed absent optional input with the relevant attribute. It does not permit arbitrary missing required tensors or incompatible combinations of split controls. Keep invalid controls in coverage and check the declared opset. This article reports the release correction and proposed artifact test, without claiming new cross-provider results or suggesting that deleting model inputs is a general workaround for initialization errors.

## Sources

- [ONNX Runtime v1.32.0 release](https://github.com/microsoft/onnxruntime/releases/tag/v1.32.0)
- [ONNX Runtime pull request #32972](https://github.com/microsoft/onnxruntime/pull/32972)

## Related reading

- [ONNX optional inputs: preserve positions when a middle argument is absent](/journal/fg2-onnx-optional-input-empty-placeholder-position/)
- [ONNX compatibility: distinguish IR version, domain opsets and model revision](/journal/fg2-onnx-ir-version-opset-domain-separation/)
