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

Method _ctx

tensorflow/python/ops/script_ops.py:160–164  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

158
159 @property
160 def _ctx(self):
161 # N.B. This is needed to support calling py_func with GPU tensors,
162 # which must be transferred to CPU if used in any of the NumPy APIs.
163 context.ensure_initialized()
164 return context.context()._handle # pylint: disable=protected-access
165
166 def insert(self, func):
167 """Registers `func` and returns a unique token for this entry."""

Callers

nothing calls this directly

Calls 2

ensure_initializedMethod · 0.80
contextMethod · 0.45

Tested by

no test coverage detected