Property PinnedSequenceLength
- Namespace
- Qavren.Edge.Embeddings.Onnx
- Assembly
- Qavren.Edge.Embeddings.Onnx.dll
PinnedSequenceLength
Null (the default) uses SequenceBuckets: the graph keeps its
declared symbolic sequence_length, CoreML partitions normally, and each batch is
padded to the smallest bucket that fits it.
Set to one of the buckets to pin the shape instead. That emits
AddFreeDimensionOverrideByName("sequence_length", N) and
("batch_size", MaxBatchSize) into
FreeDimensionOverrides and turns
CoreMlProviderOptions.RequireStaticInputShapes on. One pinned shape means one
session and one CoreML compile, and every batch - including a batch of one short string -
pays a full N-token run. It is a measured trade, not a default.
public int? PinnedSequenceLength { get; set; }
Property Value
- int?