MCPcopy Index your code
hub / github.com/tensorpack/tensorpack / f

Function f

tensorpack/tfutils/common.py:132–136  ·  view source on GitHub ↗
(n)

Source from the content-addressed store, hash-verified

130 G = tfv1.get_default_graph()
131
132 def f(n):
133 if len(n) >= 3 and n[-2] == ':':
134 return G.get_tensor_by_name(n)
135 else:
136 return G.get_operation_by_name(n)
137
138 if not isinstance(name, list):
139 return f(name)

Callers 1

get_op_or_tensor_by_nameFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected