tf.compat.v1.reset_default_graph  |  TensorFlow v2.16.1 (original) (raw)

tf.compat.v1.reset_default_graph

Stay organized with collections Save and categorize content based on your preferences.

Clears the default graph stack and resets the global default graph.

tf.compat.v1.reset_default_graph() -> None

Migrate to TF2

reset_default_graph does not work with either eager execution ortf.function, and you should not invoke it directly. To migrate code that uses Graph-related functions to TF2, rewrite the code without them. See themigration guide for more description about the behavior and semantic changes between Tensorflow 1 and Tensorflow 2.

Description

Used in the notebooks

Used in the tutorials
Generating Images with BigGAN Classify Flowers with Transfer Learning Generating Images with Little Data Using S3GAN Fitting Dirichlet Process Mixture Model Using Preconditioned Stochastic Gradient Langevin Dynamics Linear Mixed-Effect Regression in {TF Probability, R, Stan}
Raises
AssertionError If this function is called within a nested graph.

Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates. Some content is licensed under the numpy license.

Last updated 2024-04-26 UTC.