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

SystemError in tf.raw_ops.ParallelConcat when dtype of shape is tf.qint16 or tf.quint16. #64928

Open
xl1043237213 opened this issue Apr 2, 2024 · 5 comments
Assignees
Labels
comp:ops OPs related issues stat:awaiting tensorflower Status - Awaiting response from tensorflower TF 2.16 type:bug Bug

Comments

@xl1043237213
Copy link

xl1043237213 commented Apr 2, 2024

Issue type

Bug

Have you reproduced the bug with TensorFlow Nightly?

Yes

Source

binary

TensorFlow version

tf 2.15

Custom code

No

OS platform and distribution

Linux Ubuntu 20.04

Mobile device

No response

Python version

3.10

Bazel version

No response

GCC/compiler version

No response

CUDA/cuDNN version

No response

GPU model and memory

No response

Current behavior?

The parameter shape of API tf.raw_ops.ParallelConcat cannot correctly filter tensor input with dtype as qint16 or quint16, which will trigger a SystemError.

Standalone code to reproduce the issue

https://colab.research.google.com/drive/160dforWR2pxr4xlpDnfl-aZzyNnCYTkF?usp=sharing

Relevant log output

SystemError: _PyEval_EvalFrameDefault returned a result with an exception set
@SuryanarayanaY
Copy link
Collaborator

Hi @xl1043237213 ,

As per documentation the shape of this Op should be :

shape: A tf.TensorShape or list of ints. the final shape of the result; should be equal to the shapes of any input but with the number of input values in the first dimension.

It works for list or tf.TensorShape . You are trying to pass a Tensor instead of TensorShape. Hence the error.

@SuryanarayanaY SuryanarayanaY added the stat:awaiting response Status - Awaiting response from author label Apr 3, 2024
@xl1043237213
Copy link
Author

xl1043237213 commented Apr 3, 2024

Thanks for your response.🙂
It is an exception input, but when the dtype of shape is tf.int32 or other types, the code throws the error TypeError. I think TypeError is a correct error, but SystemError is an abnormal error.

@google-ml-butler google-ml-butler bot removed the stat:awaiting response Status - Awaiting response from author label Apr 3, 2024
@SuryanarayanaY
Copy link
Collaborator

Hi @xl1043237213 ,

I tested the code snippet with tf-nightly and it is raising InvalidArgumentError . Attached gist for reference. Could you please test and confirm the behaviour with nightly?

@SuryanarayanaY SuryanarayanaY added the stat:awaiting response Status - Awaiting response from author label Apr 4, 2024
@xl1043237213
Copy link
Author

xl1043237213 commented Apr 5, 2024

Hi @SuryanarayanaY.
I found that the triggering of SystemError may be related to the execution environment. In the original environment, I updated the tf-nightly version and found that I could re-trigger SystemError in CPU execution environment. However, when I restarted the new colab environment,SystemError disappeared. Then, in the new environment, I tried to repeat the code execution 10 times and found that 7 times I could trigger SystemError and 3 times I could trigger InvalidArgumentError.

Below is the relevant colab link:
SystemError : https://colab.research.google.com/drive/160dforWR2pxr4xlpDnfl-aZzyNnCYTkF?usp=sharing
InvalidArgumentError : https://colab.research.google.com/drive/1dxxe2hLpYWYYDC8zNDpH1Q2uCybX9tMv?usp=sharing

@google-ml-butler google-ml-butler bot removed the stat:awaiting response Status - Awaiting response from author label Apr 5, 2024
@SuryanarayanaY
Copy link
Collaborator

SuryanarayanaY commented Apr 17, 2024

Hi @xl1043237213 ,

This seems inconsistent behaviour though this Op raising intended exception sometimes and other times exception followed by system error which is confusing.This is not a service denial or vulnerability issue though.

Escalating to SME for their comments. Thanks!

@SuryanarayanaY SuryanarayanaY added the stat:awaiting tensorflower Status - Awaiting response from tensorflower label Apr 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
comp:ops OPs related issues stat:awaiting tensorflower Status - Awaiting response from tensorflower TF 2.16 type:bug Bug
Projects
None yet
Development

No branches or pull requests

2 participants