code: def get_activation(activation_string):
      """
      Maps a string to a Python function, e.g., "relu" => `tf.nn.relu`.
  
      Args:
          activation_string: String name of the activation function.
  
      Returns:
          A Python function corresponding to the activation function. If
          `activation_string` is None, empty, or "linear", this will return None.
          If `activation_string` is not a string, it will return `activation_string`.
  
      Raises:
          ValueError: The `activation_string` does not correspond to a known
          activation.
      """
  
      # We assume that anything that"s not a string is already an activation
      # function, so we just return it.
      if not isinstance(activation_string, str):
          return activation_string
  
      if not activation_string:
          return None
  
      act = activation_string.lower()
      if act == "linear":
          return None
      elif act == "relu":
          return tf.nn.relu
      elif act == "gelu":
          return gelu
      elif act == "tanh":
          return tf.tanh
      elif act == "hf_gelu":
          return hf_gelu
      else:
          raise ValueError("Unsupported activation: %s" % act)
  
imports: import copy
  import json
  import math
  import numpy
  import tensorflow
  import functools
  from transformers.activations_tf import gelu
  from finetune.optimizers.recompute_grads import recompute_grad
  from finetune.nn.auxiliary import embed_position
label_desc: Use image node_id 2 for calling a global function with example usage: get_activation(activation_string) and returns: activation_string, None, None, tf, gelu, tf, hf_gelu