MCPcopy Create free account
hub / github.com/DeepRec-AI/DeepRec / add_function

Method add_function

tensorflow/python/eager/context.py:968–978  ·  view source on GitHub ↗

Add a function definition to the context. Once added, the function (identified by its name) can be executed like any other operation. Args: fn: A wrapped TF_Function (returned from TF_GraphToFunction_wrapper).

(self, fn)

Source from the content-addressed store, hash-verified

966 return self._num_gpus
967
968 def add_function(self, fn):
969 """Add a function definition to the context.
970
971 Once added, the function (identified by its name) can be executed like any
972 other operation.
973
974 Args:
975 fn: A wrapped TF_Function (returned from TF_GraphToFunction_wrapper).
976 """
977 self.ensure_initialized()
978 pywrap_tensorflow.TFE_ContextAddFunction(self._handle, fn)
979
980 def add_function_def(self, fdef):
981 """Add a function definition to the context.

Callers 15

definitionMethod · 0.45
add_functionFunction · 0.45
__init__Method · 0.45
ConvertLibFunctionMethod · 0.45
TESTFunction · 0.45
TESTFunction · 0.45
TESTFunction · 0.45
TEST_FFunction · 0.45
TESTFunction · 0.45
TESTFunction · 0.45

Calls 1

ensure_initializedMethod · 0.95

Tested by 15

TESTFunction · 0.36
TESTFunction · 0.36
TESTFunction · 0.36
TEST_FFunction · 0.36
TESTFunction · 0.36
TESTFunction · 0.36
TESTFunction · 0.36
InitMethod · 0.36
TESTFunction · 0.36