Successful resolution AttributeError: module 'tensorflow.compat' has no attribute 'v1'
table of Contents
Solve the problem
AttributeError: module 'tensorflow.compat' has no attribute 'v1'
Solution
Because in tf2 version, using tf1 the API.
# with tf.compat.v1.Session(graph=graph) as sess:
with tf.Session(graph=graph) as sess: