class_docstr: Test case that needs a Tensorflow Session and default Graph.
class_docstr_tok: ["Test","case","that","needs","a","Tensorflow","Session","and","default","Graph","."]
docstr: Teardown the Session and default Graph.
docstr_tok: ["Teardown","the","Session","and","default","Graph","."]
code: def teardown_method(self):
      """Teardown the Session and default Graph."""
      logger.remove_all()
      self.sess.__exit__(None, None, None)
      self.sess_manager.__exit__(None, None, None)
      self.graph_manager.__exit__(None, None, None)
      self.sess.close()
  
      # These del are crucial to prevent ENOMEM in the CI
      # b/c TensorFlow does not release memory explicitly
      del self.graph
      del self.sess
      gc.collect()
  
file_path: garage/tests/fixtures/fixtures.py
imports: import gc
  import os
  from dowel import logger
  import tensorflow
  from garage.experiment import deterministic
  from garage.experiment.snapshotter import SnapshotConfig
  from tests.fixtures.logger import NullOutput
label_desc: Use image node_id 2 for calling the TfGraphTestCase obj's underlying member method code with example usage: obj.teardown_method() without return types