Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Test case to ensure inference error when element types mismatch #5525

Conversation

ClifHouck
Copy link
Contributor

Description

Created a short proof of concept test case to see what happens when element types mismatch.

Output from the test:
C++ exception with description "[TypeInferenceError] Inferred elem type differs from existing elem type: (FLOAT) vs (UINT8)" thrown in the test body.

Seems to indicate that GetElemTypeString already works as expected.

Motivation and Context

Investigating #5178, but it seems like it may not actually be a problem?

@ClifHouck
Copy link
Contributor Author

@justinchuby Any thoughts?

@justinchuby
Copy link
Contributor

Thanks for the investigation! In that case maybe we just need to use the latest onnx in ONNX Runtime (I believe that's where I found it)

@ClifHouck ClifHouck force-pushed the clif/dtype_name_in_shape_inference_mismatch/5178 branch from 7dacc56 to 6390bc8 Compare August 25, 2023 13:20
@ClifHouck ClifHouck marked this pull request as ready for review August 25, 2023 15:42
@ClifHouck ClifHouck requested a review from a team as a code owner August 25, 2023 15:42
@ClifHouck ClifHouck force-pushed the clif/dtype_name_in_shape_inference_mismatch/5178 branch from 25f80d7 to e8b06a8 Compare August 25, 2023 15:42
Signed-off-by: Clif Houck <me@clifhouck.com>
Signed-off-by: Clif Houck <me@clifhouck.com>
Signed-off-by: Clif Houck <me@clifhouck.com>
@ClifHouck ClifHouck force-pushed the clif/dtype_name_in_shape_inference_mismatch/5178 branch from e8b06a8 to 5ecc080 Compare August 28, 2023 13:01
@justinchuby justinchuby changed the title POC test case to check what happens when element types mismatch. Test case to ensure error messages when element types mismatch Aug 28, 2023
@justinchuby justinchuby changed the title Test case to ensure error messages when element types mismatch Test case to ensure inference error when element types mismatch Aug 28, 2023
@justinchuby justinchuby added this pull request to the merge queue Aug 28, 2023
Merged via the queue into onnx:main with commit 127f03d Aug 28, 2023
35 checks passed
corwinjoy pushed a commit to corwinjoy/onnx that referenced this pull request Sep 5, 2023
…#5525)

### Description
<!-- - Describe your changes. -->
Created a short proof of concept test case to see what happens when
element types mismatch.

Output from the test:
`C++ exception with description "[TypeInferenceError] Inferred elem type
differs from existing elem type: (FLOAT) vs (UINT8)" thrown in the test
body.`

Seems to indicate that `GetElemTypeString` already works as expected.

### Motivation and Context
<!-- - Why is this change required? What problem does it solve? -->
<!-- - If it fixes an open issue, please link to the issue here. -->
Investigating onnx#5178, but it seems like it may not actually be a problem?

---------

Signed-off-by: Clif Houck <me@clifhouck.com>
Signed-off-by: Corwin Joy <corwinjoy@gmail.com>
corwinjoy pushed a commit to corwinjoy/onnx that referenced this pull request Sep 5, 2023
…#5525)

### Description
<!-- - Describe your changes. -->
Created a short proof of concept test case to see what happens when
element types mismatch.

Output from the test:
`C++ exception with description "[TypeInferenceError] Inferred elem type
differs from existing elem type: (FLOAT) vs (UINT8)" thrown in the test
body.`

Seems to indicate that `GetElemTypeString` already works as expected.

### Motivation and Context
<!-- - Why is this change required? What problem does it solve? -->
<!-- - If it fixes an open issue, please link to the issue here. -->
Investigating onnx#5178, but it seems like it may not actually be a problem?

---------

Signed-off-by: Clif Houck <me@clifhouck.com>
Signed-off-by: Corwin Joy <corwinjoy@gmail.com>
corwinjoy pushed a commit to corwinjoy/onnx that referenced this pull request Sep 5, 2023
…#5525)

### Description
<!-- - Describe your changes. -->
Created a short proof of concept test case to see what happens when
element types mismatch.

Output from the test:
`C++ exception with description "[TypeInferenceError] Inferred elem type
differs from existing elem type: (FLOAT) vs (UINT8)" thrown in the test
body.`

Seems to indicate that `GetElemTypeString` already works as expected.

### Motivation and Context
<!-- - Why is this change required? What problem does it solve? -->
<!-- - If it fixes an open issue, please link to the issue here. -->
Investigating onnx#5178, but it seems like it may not actually be a problem?

---------

Signed-off-by: Clif Houck <me@clifhouck.com>
Signed-off-by: Corwin Joy <corwinjoy@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants