Add a function definition to the context. Once added, the function (identified by its name) can be executed like any other operation. Args: fdef: A FunctionDef protocol buffer message.
(self, fdef)
| 978 | pywrap_tensorflow.TFE_ContextAddFunction(self._handle, fn) |
| 979 | |
| 980 | def add_function_def(self, fdef): |
| 981 | """Add a function definition to the context. |
| 982 | |
| 983 | Once added, the function (identified by its name) can be executed like any |
| 984 | other operation. |
| 985 | |
| 986 | Args: |
| 987 | fdef: A FunctionDef protocol buffer message. |
| 988 | """ |
| 989 | self.ensure_initialized() |
| 990 | fdef_string = fdef.SerializeToString() |
| 991 | pywrap_tensorflow.TFE_ContextAddFunctionDef( |
| 992 | self._handle, fdef_string, len(fdef_string)) |
| 993 | |
| 994 | def remove_function(self, name): |
| 995 | """Remove a function from the context. |
no test coverage detected