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

Support TensorFlow 2 #471

Open
brimoor opened this issue Jul 9, 2020 · 0 comments
Open

Support TensorFlow 2 #471

brimoor opened this issue Jul 9, 2020 · 0 comments
Labels
enhancement Code enhancement

Comments

@brimoor
Copy link
Contributor

brimoor commented Jul 9, 2020

We should be able to support running ETA as-is under TensorFlow 2 by replacing tensorflow imports in any TF 1.X specific modules as follows:

try:
   # TF 2
    import tensorflow.compat.v1 as tf
    tf.disable_v2_behavior()
except:
    # TF 1.X
    import tensorflow as tf
@brimoor brimoor added the enhancement Code enhancement label Jul 9, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement Code enhancement
Projects
None yet
Development

No branches or pull requests

1 participant