Skip to content

Commit 0180ff6

Browse files
Test build failure
1 parent 7de47ee commit 0180ff6

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/Microsoft.ML.OnnxConverter/OnnxExportExtensions.cs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ internal static ModelProto ConvertToOnnxProtobuf(this ModelOperationsCatalog cat
7979
/// <param name="stream">The stream to write the protobuf model to.</param>
8080
/// <returns>An ONNX model equivalent to the converted ML.NET model.</returns>
8181
public static void ConvertToOnnx(this ModelOperationsCatalog catalog, ITransformer transform, IDataView inputData, Stream stream) =>
82-
ConvertToOnnxProtobuf(catalog, transform, new EmptyDataView(catalog.GetEnvironment(), inputData.Schema)).WriteTo(stream);
82+
ConvertToOnnxProtobuf(catalog, transform, inputData).WriteTo(stream);
8383

8484
/// <summary>
8585
/// Convert the specified <see cref="ITransformer"/> to ONNX format and writes to a stream.
@@ -91,7 +91,7 @@ public static void ConvertToOnnx(this ModelOperationsCatalog catalog, ITransform
9191
/// <param name="stream">The stream to write the protobuf model to.</param>
9292
/// <returns>An ONNX model equivalent to the converted ML.NET model.</returns>
9393
public static void ConvertToOnnx(this ModelOperationsCatalog catalog, ITransformer transform, IDataView inputData, int opSetVersion, Stream stream) =>
94-
ConvertToOnnxProtobuf(catalog, transform, new EmptyDataView(catalog.GetEnvironment(), inputData.Schema), opSetVersion).WriteTo(stream);
94+
ConvertToOnnxProtobuf(catalog, transform, inputData, opSetVersion).WriteTo(stream);
9595

9696
/// <summary>
9797
/// Convert the specified <see cref="ITransformer"/> to ONNX format and writes to a stream.
@@ -103,7 +103,7 @@ public static void ConvertToOnnx(this ModelOperationsCatalog catalog, ITransform
103103
/// <param name="outputColumns">List of output columns we want to keep.</param>
104104
/// <returns>An ONNX model equivalent to the converted ML.NET model.</returns>
105105
public static void ConvertToOnnx(this ModelOperationsCatalog catalog, ITransformer transform, IDataView inputData, Stream stream, params string[] outputColumns) =>
106-
ConvertToOnnxProtobuf(catalog, transform, new EmptyDataView(catalog.GetEnvironment(), inputData.Schema), outputColumns).WriteTo(stream);
106+
ConvertToOnnxProtobuf(catalog, transform, inputData, outputColumns).WriteTo(stream);
107107

108108
/// <summary>
109109
/// Convert the specified <see cref="ITransformer"/> to ONNX format and writes to a stream.

0 commit comments

Comments
 (0)