Skip to content

Run code TF-GPU erroring #43

Description

@Eslam2011

I run python code using TF-GPU on this image tensorflow/tensorflow:latest-gpu, and they alot of errors in code such as:

x_idxs = tf.placeholder(tf.int64, shape=[None,2])
AttributeError: module 'tensorflow' has no attribute 'placeholder'

I solved it by using
import tensorflow.compat.v1 as tf
tf.disable_v2_behavior()

### But why this error, I think the code must run without any error?

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions