Conversation
Score column being named "Score0". The ONNX model will rename the output columns by design, therefore a different class with the ColumnName of "Score0" is needed. This fixes the test pipeline to address this issue. Fixes dotnet#2981
Codecov Report
@@ Coverage Diff @@
## master #3253 +/- ##
==========================================
+ Coverage 72.69% 72.69% +<.01%
==========================================
Files 807 807
Lines 145172 145171 -1
Branches 16225 16225
==========================================
Hits 105537 105537
+ Misses 35220 35219 -1
Partials 4415 4415
|
rogancarr
left a comment
There was a problem hiding this comment.
Approved with comments.
occur if the input type was not a variable vector or vector type. This is not needed as we do support converting basic types to equivalent ONNX tensor type. Therefore removing the check in GetOutputSchema fixes this problem.
| throw Host.ExceptSchemaMismatch(nameof(inputSchema), "input", input); | ||
| if (!(col.Kind == SchemaShape.Column.VectorKind.VariableVector || col.Kind == SchemaShape.Column.VectorKind.Vector)) | ||
| throw Host.ExceptSchemaMismatch(nameof(inputSchema), "input", input, "vector", col.GetTypeString()); | ||
|
|
There was a problem hiding this comment.
if input col.Kind == VariableVector, how is that case handled? If not handled, should throw exception.
There was a problem hiding this comment.
so prior to this change, we allowed VariableVector in that it would not throw -- this change now allows for vector and simple types. I would prefer to have a test that uses VariableVector, but I have yet to find something that provides a VariableVector output AND can be saved to ONNX.
There was a problem hiding this comment.
@jignparm from our conversation, you mentioned that we should not have allowed VariableVector to begin with and should fix as part of this change. I have updated the code to reflect that, but we should have a test that confirms if this works correctly. I have created the following issue for tracking #3375
|
LGTM @singlis |
The test pipeline for consuming an ONNX model would fail due to the Score column being named "Score0". The ONNX model will rename the output columns by design, therefore a different class with the ColumnName of "Score0" is needed. This fixes the test pipeline to address this issue.
Fixes #2981