class_docstr: Groups wrapped layer call functions.
  
  This is used to ensure that all layer call functions are traced with the same
  inputs-
    - call
    - call_and_return_conditional_losses
    - call_and_return_all_conditional_losses
class_docstr_tok: ["Groups","wrapped","layer","call","functions",".","This","is","used","to","ensure","that","all","layer","call","functions","are","traced","with","the","same","inputs-","-","call","-","call_and_return_conditional_losses","-","call_and_return_all_conditional_losses"]
docstr: Adds a layer call function to the collection.
  
  Args:
    call_fn: a python function
    name: Name of call function
    match_layer_training_arg: If True, removes the `training` from the
      function arguments when calling `call_fn`.
  
  Returns:
    LayerCall (tf.function)
docstr_tok: ["Adds","a","layer","call","function","to","the","collection",".","Args",":","call_fn",":","a","python","function","name",":","Name","of","call","function","match_layer_training_arg",":","If","True",",","removes","the","`","training","`","from","the","function","arguments","when","calling","`","call_fn","`",".","Returns",":","LayerCall","(","tf.function",")"]
code: def add_function(self, call_fn, name, match_layer_training_arg):
      """Adds a layer call function to the collection.
  
      Args:
        call_fn: a python function
        name: Name of call function
        match_layer_training_arg: If True, removes the `training` from the
          function arguments when calling `call_fn`.
  
      Returns:
        LayerCall (tf.function)
      """
      fn = LayerCall(
          self,
          self._maybe_wrap_with_training_arg(
              call_fn, match_layer_training_arg
          ),
          name,
          input_signature=self.fn_input_signature,
      )
      self._functions[name] = fn.wrapped_call
      return fn
  
imports: import functools
  import threading
  import weakref
  from tensorflow.python.eager import def_function
  from tensorflow.python.framework import tensor_shape
  from tensorflow.python.framework import tensor_spec
  from tensorflow.python.keras import backend
  from tensorflow.python.keras.engine import base_layer_utils
  from tensorflow.python.keras.engine import input_spec
  from tensorflow.python.keras.mixed_precision import autocast_variable
  from tensorflow.python.keras.saving import saving_utils
  from tensorflow.python.keras.saving.saved_model import constants
  from tensorflow.python.keras.saving.saved_model import load
  from tensorflow.python.keras.saving.saved_model import serialized_attributes
  from tensorflow.python.keras.saving.saved_model import utils
  from tensorflow.python.keras.utils import tf_contextlib
  from tensorflow.python.keras.utils import tf_inspect
  from tensorflow.python.keras.utils import tf_utils
  from tensorflow.python.keras.utils import version_utils
  from tensorflow.python.keras.utils.generic_utils import LazyLoader
  from tensorflow.python.platform import tf_logging
  from tensorflow.python.trackable import data_structures
  from tensorflow.python.util import nest
  from tensorflow.python.util import tf_decorator
label_desc: Use image node_id 9 for calling the LayerCallCollection obj's underlying member method code with example usage: obj.add_function(call_fn, name, match_layer_training_arg) and returns: fn