I used tf.reset_default_graph() in tensorflow 1.x to repeat run a cell and it worked well (to generate many trianed model in one run). However, in tensorflow 2.0, tf.compat.v1.reset_default_graph() is not working and if I repeat run the cell a vaule error will happen: name x has been used.
I have noticed that tensorlayer.layers.clear_layers_name() can remove the layer space. However, seem like that tl.layers.clear_layers_name() was not available in tensorlayer 2.X.
The code is composed with tensorlayer 2.x and tensorflow 2.0. The question is how to reset the entire graph to repeat run my code in a 'for' circulation with tensorflow 2.0, or any other options for using tl.layers.clear_layers_name() like function?
I used tf.reset_default_graph() in tensorflow 1.x to repeat run a cell and it worked well (to generate many trianed model in one run). However, in tensorflow 2.0, tf.compat.v1.reset_default_graph() is not working and if I repeat run the cell a vaule error will happen: name x has been used.
I have noticed that tensorlayer.layers.clear_layers_name() can remove the layer space. However, seem like that tl.layers.clear_layers_name() was not available in tensorlayer 2.X.
The code is composed with tensorlayer 2.x and tensorflow 2.0. The question is how to reset the entire graph to repeat run my code in a 'for' circulation with tensorflow 2.0, or any other options for using tl.layers.clear_layers_name() like function?