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

Function f

tensorflow/python/ops/parallel_for/pfor.py:3153–3161  ·  view source on GitHub ↗
(*args)

Source from the content-addressed store, hash-verified

3151 # TODO(agarwal): consider caching this function definition.
3152 @def_function.function
3153 def f(*args):
3154 assert all(isinstance(arg, WrappedTensor) for arg in args), args
3155 assert len(args) == len(func.graph.inputs), (args, func.graph.inputs)
3156 # Map inputs to function arguments.
3157 for inp, arg in zip(func.graph.inputs, args):
3158 converter._add_conversion(inp, arg)
3159 # Convert output tensors.
3160 return tuple([converter._convert_helper(x).t
3161 for x in func._func_graph_outputs])
3162
3163 call_outputs = f(*pfor_input.inputs)
3164 assert len(call_outputs) == len(func._func_graph_outputs)

Callers 3

pfor_map_fnMethod · 0.70
loop_fnMethod · 0.70

Calls 4

allFunction · 0.85
tupleFunction · 0.85
_add_conversionMethod · 0.80
_convert_helperMethod · 0.80

Tested by 2

pfor_map_fnMethod · 0.56
loop_fnMethod · 0.56