code: def create_session(timeout=10000, interactive=True):
      """Create a tf session for the model.
      # This function is slight motification of code written by Alex Mordvintsev
  
      Args:
        timeout: tfutil param.
  
      Returns:
        TF session.
      """
      graph = tf.Graph()
      config = tf.compat.v1.ConfigProto()
      config.gpu_options.allow_growth = True
      config.operation_timeout_in_ms = int(timeout * 1000)
      if interactive:
          return tf.compat.v1.InteractiveSession(
              graph=graph, config=config
          )
      else:
          return tf.compat.v1.Session(graph=graph, config=config)
  
file_path: tcav/tcav/utils.py
imports: from scipy.stats import ttest_ind
  import numpy
  import tensorflow
  from tcav.tcav_results.results_pb2 import Result, Results
label_desc: Use image node_id 1 for calling a global function with example usage: create_session(timeout, interactive) and returns: tf, tf