1 write to _parent
Microsoft.ML.OnnxTransformer (1)
OnnxTransform.cs (1)
510
_parent
= parent;
29 references to _parent
Microsoft.ML.OnnxTransformer (29)
OnnxTransform.cs (29)
511
_inputColIndices = new int[
_parent
.Inputs.Length];
512
_inputTensorShapes = new OnnxShape[
_parent
.Inputs.Length];
513
_inputOnnxTypes = new Type[
_parent
.Inputs.Length];
515
var model =
_parent
.Model;
516
for (int i = 0; i <
_parent
.Inputs.Length; i++)
518
var inputNodeInfo = model.ModelInfo.GetInput(
_parent
.Inputs[i]);
526
throw new ArgumentOutOfRangeException(
_parent
.Inputs[i], "Only 1 unknown dimension is allowed");
531
var col = inputSchema.GetColumnOrNull(
_parent
.Inputs[i]);
533
throw Host.ExceptSchemaMismatch(nameof(inputSchema), "input",
_parent
.Inputs[i]);
550
throw Host.ExceptSchemaMismatch(nameof(inputSchema), "input",
_parent
.Inputs[i], inputNodeInfo.DataViewType.GetItemType().ToString(), type.ToString());
561
throw Contracts.Except($"Input shape mismatch: Input '{
_parent
.Inputs[i]}' has shape {String.Join(",", inputShape)}, but input data is of length {typeValueCount}.");
569
var info = new DataViewSchema.DetachedColumn[
_parent
.Outputs.Length];
570
for (int i = 0; i <
_parent
.Outputs.Length; i++)
572
var onnxOutputName =
_parent
.Outputs[i];
578
info[i] = new DataViewSchema.DetachedColumn(columnName,
_parent
.OutputTypes[i], builder.ToAnnotations());
585
var graph =
_parent
.Model.Graph;
610
return col => Enumerable.Range(0,
_parent
.Outputs.Length).Any(i => activeOutput(i)) && _inputColIndices.Any(i => i == col);
613
private protected override void SaveModel(ModelSaveContext ctx) =>
_parent
.SaveModel(ctx);
622
var activeOutputColNames =
_parent
.Outputs.Where((x, i) => activeOutput(i)).ToArray();
624
if (
_parent
.Model.ModelInfo.OutputsInfo[
_parent
.MapDataViewColumnToOnnxOutputTensor(iinfo)].DataViewType is VectorDataViewType vectorType)
635
var type =
_parent
.Model.ModelInfo.OutputsInfo[
_parent
.MapDataViewColumnToOnnxOutputTensor(iinfo)].DataViewType.RawType;
697
outputCache.OutputOnnxValues =
_parent
.Model.Run(inputNameOnnxValues, activeOutputColNames);
716
var namedOnnxValue = outputCacher.Outputs[
_parent
.Outputs[iinfo]];
736
var namedOnnxValue = outputCacher.Outputs[
_parent
.Outputs[iinfo]];
760
var namedOnnxValue = outputCacher.Outputs[
_parent
.Outputs[iinfo]];
762
var caster =
_parent
.Model.ModelInfo.OutputsInfo[
_parent
.MapDataViewColumnToOnnxOutputTensor(iinfo)].Caster;