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

Segmentation fault in tf.histogram_fixed_width #45770

Closed
DNXie opened this issue Dec 17, 2020 · 7 comments
Closed

Segmentation fault in tf.histogram_fixed_width #45770

DNXie opened this issue Dec 17, 2020 · 7 comments
Assignees
Labels
comp:ops OPs related issues stat:awaiting tensorflower Status - Awaiting response from tensorflower TF 2.8 type:bug Bug

Comments

@DNXie
Copy link

DNXie commented Dec 17, 2020

Please make sure that this is a bug. As per our
GitHub Policy,
we only address code/doc bugs, performance issues, feature requests and
build/installation issues on GitHub. tag:bug_template

System information

  • Have I written custom code (as opposed to using a stock example script provided in TensorFlow): No
  • OS Platform and Distribution (e.g., Linux Ubuntu 16.04): Linux Ubuntu 18.04
  • Mobile device (e.g. iPhone 8, Pixel 2, Samsung Galaxy) if the issue happens on mobile device: N/A
  • TensorFlow installed from (source or binary): binary
  • TensorFlow version (use command below):2.1.0
  • Python version:3.7.6
  • Bazel version (if compiling from source):N/A
  • GCC/Compiler version (if compiling from source):N/A
  • CUDA/cuDNN version:N/A
  • GPU model and memory:N/A

Describe the current behavior
tf.histogram_fixed_width crashes (segmentation fault) when values contain nan

Describe the expected behavior
Expect no crash

Standalone code to reproduce the issue

import tensorflow as tf
import numpy as np
tf.histogram_fixed_width(values=np.nan, value_range=[1,2])
@ravikyram
Copy link
Contributor

I have tried in colab with TF 2.3, nightly version(2.5.0-dev20201216) and was able to reproduce the issue.Please,find the gist here. Thanks!

@ravikyram ravikyram added comp:ops OPs related issues TF 2.1 for tracking issues in 2.1 release labels Dec 17, 2020
@ravikyram ravikyram assigned ymodak and unassigned ravikyram Dec 17, 2020
@ymodak ymodak added the stat:awaiting tensorflower Status - Awaiting response from tensorflower label Dec 17, 2020
@mihaimaruseac
Copy link
Collaborator

Does this also reproduce with TF 2.4?

@ravikyram
Copy link
Contributor

@mihaimaruseac

I have tried in colab with TF 2.4 and i was able to reproduce the issue. Please, find the gist here. Thanks!

@tensorflowbutler tensorflowbutler removed the stat:awaiting tensorflower Status - Awaiting response from tensorflower label Dec 30, 2020
@rushabh-v
Copy link
Contributor

Looks like values don't expect nan values. Should I open a PR that raises an error if there are nan in values?

@ymodak
Copy link
Contributor

ymodak commented Jan 6, 2021

I see that the example crashes if executed on cpu with TF 2.4 where as on gpu execution with TF 2.4 it passes with following output.

<tf.Tensor: shape=(100,), dtype=int32, numpy=
array([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
       0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
       0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
       0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
       0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], dtype=int32)>

@ymodak ymodak added the stat:awaiting tensorflower Status - Awaiting response from tensorflower label Jan 6, 2021
@mihaimaruseac mihaimaruseac added the TF 2.5 Issues related to TF 2.5 label Jun 8, 2021
@tensorflow tensorflow deleted a comment from saikumarchalla Aug 19, 2021
@ymodak ymodak removed the TF 2.1 for tracking issues in 2.1 release label Aug 19, 2021
@mohantym
Copy link
Contributor

It is still replicating in CPU mode for TF 2.8.

@mohantym mohantym added TF 2.8 and removed TF 2.5 Issues related to TF 2.5 labels Feb 17, 2022
@google-ml-butler
Copy link

Are you satisfied with the resolution of your issue?
Yes
No

tensorflow-jenkins pushed a commit that referenced this issue May 4, 2022
tensorflow-jenkins pushed a commit that referenced this issue May 4, 2022
tensorflow-jenkins pushed a commit that referenced this issue May 4, 2022
tensorflow-jenkins pushed a commit that referenced this issue May 4, 2022
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.8 type:bug Bug
Projects
None yet
Development

No branches or pull requests

8 participants