Returns `True` if and only if `tensor_or_op` is fetchable.
(self, tensor_or_op)
| 4955 | self._unfetchable_ops.add(op) |
| 4956 | |
| 4957 | def is_fetchable(self, tensor_or_op): |
| 4958 | """Returns `True` if and only if `tensor_or_op` is fetchable.""" |
| 4959 | if isinstance(tensor_or_op, Tensor): |
| 4960 | return tensor_or_op.op not in self._unfetchable_ops |
| 4961 | else: |
| 4962 | return tensor_or_op not in self._unfetchable_ops |
| 4963 | |
| 4964 | def switch_to_thread_local(self): |
| 4965 | """Make device, colocation and dependencies stacks thread-local. |
no outgoing calls