Home
last modified time | relevance | path

Searched refs:arg_spec (Results 1 – 17 of 17) sorted by relevance

/external/tensorflow/tensorflow/python/keras/saving/saved_model/
Dutils.py64 fn, arg_spec = maybe_add_training_arg(
92 decorator_argspec=arg_spec)
175 arg_spec = tf_inspect.getfullargspec(original_call)
176 defaults = list(arg_spec.defaults) if arg_spec.defaults is not None else []
178 kwonlyargs = arg_spec.kwonlyargs
179 kwonlydefaults = arg_spec.kwonlydefaults or {}
181 if 'training' not in arg_spec.args:
185 index = arg_spec.args.index('training')
186 training_default_index = len(arg_spec.args) - index
187 if (arg_spec.defaults and
[all …]
Dsave_impl.py348 arg_spec = tf_inspect.getfullargspec(self.layer_call_method)
350 arg_spec.defaults or
351 arg_spec.kwonlyargs or
352 arg_spec.varkw)
361 args = arg_spec.args
460 arg_spec = tf_inspect.getfullargspec(call_fn)
461 args = arg_spec.args + ['training']
462 defaults = list(arg_spec.defaults or [])
466 varargs=arg_spec.varargs,
467 varkw=arg_spec.varkw,
[all …]
Dsaved_model_test.py535 arg_spec = tf_inspect.getfullargspec(fn)
536 index = len(arg_spec.args) - arg_spec.args.index('training')
537 self.assertEqual(arg_spec.defaults[-index], default_value)
582 arg_spec = tf_inspect.getfullargspec(
584 self.assertFalse(arg_spec.defaults) # defaults is None or empty
/external/chromium-trace/catapult/common/py_trace_event/py_trace_event/trace_event_impl/
Ddecorators.py32 arg_spec = inspect.getargspec(func)
33 is_method = arg_spec.args and arg_spec.args[0] == "self"
36 arg_index = arg_spec.args.index(name)
37 defaults_length = len(arg_spec.defaults) if arg_spec.defaults else 0
38 default_index = arg_index + defaults_length - len(arg_spec.args)
40 default = arg_spec.defaults[default_index]
/external/tensorflow/tensorflow/python/util/
Ddeprecation.py423 def _get_deprecated_positional_arguments(names_to_ok_vals, arg_spec): argument
443 name: pos for pos, name in enumerate(arg_spec.args)}
458 arg_spec = tf_inspect.getfullargspec(func)
460 deprecated_arg_names, arg_spec)
462 is_varargs_deprecated = arg_spec.varargs in deprecated_arg_names
463 is_kwargs_deprecated = arg_spec.varkw in deprecated_arg_names
467 known_args = arg_spec.args + [arg_spec.varargs, arg_spec.varkw]
514 if is_varargs_deprecated and len(args) > len(arg_spec.args):
515 invalid_args.append(arg_spec.varargs)
517 invalid_args.append(arg_spec.varkw)
/external/tensorflow/tensorflow/core/grappler/optimizers/
Dfunction_api_info_test.cc41 for (const auto& arg_spec : input_args_spec) in SetArgs() local
42 SetArg(arg_spec.first, arg_spec.second, sig->add_input_arg()); in SetArgs()
43 for (const auto& arg_spec : output_args_spec) in SetArgs() local
44 SetArg(arg_spec.first, arg_spec.second, sig->add_output_arg()); in SetArgs()
/external/toolchain-utils/crosperf/
Dbenchmark_unittest.py65 arg_spec = inspect.getfullargspec(Benchmark.__init__)
66 self.assertEqual(len(arg_spec.args), len(args_list))
68 self.assertIn(arg, arg_spec.args)
Dbenchmark_run_unittest.py123 arg_spec = inspect.getfullargspec(benchmark_run.BenchmarkRun.__init__)
124 self.assertEqual(len(arg_spec.args), len(args_list))
125 self.assertEqual(arg_spec.args, args_list)
/external/tensorflow/tensorflow/python/autograph/pyct/
Dparser.py215 arg_spec = tf_inspect.getfullargspec(func)
218 if node_args != tuple(arg_spec.args):
221 if arg_spec.varargs != _arg_name(node.args.vararg):
224 if arg_spec.varkw != _arg_name(node.args.kwarg):
228 if node_kwonlyargs != tuple(arg_spec.kwonlyargs):
/external/tensorflow/tensorflow/python/compiler/xla/
Dxla.py617 arg_spec = tf_inspect.getargspec(func)
618 num_func_args = len(arg_spec.args)
619 if arg_spec.defaults is None:
622 num_func_defaults = len(arg_spec.defaults)
626 if num_func_defaults == 0 and arg_spec.varargs is None:
630 if arg_spec.varargs is None and num_args_supplied > num_func_args:
/external/tensorflow/tensorflow/python/distribute/
Dparameter_server_strategy_v2.py631 arg_spec = tf_inspect.getfullargspec(initial_value)
632 if ("shard_info" not in arg_spec.args and
633 "shard_info" not in arg_spec.kwonlyargs):
Dstrategy_test_lib.py138 arg_spec = tf_inspect.getfullargspec(optimizer_obj.minimize)
139 return "var_list" in arg_spec.args[:-len(arg_spec.defaults)]
/external/tensorflow/tensorflow/python/keras/utils/
Dgeneric_utils.py621 arg_spec = tf_inspect.getfullargspec(cls.from_config)
624 if 'custom_objects' in arg_spec.args:
759 arg_spec = tf_inspect.getfullargspec(fn)
760 if accept_all and arg_spec.varkw is not None:
762 return name in arg_spec.args or name in arg_spec.kwonlyargs
/external/tensorflow/tensorflow/python/feature_column/
Dserialization.py253 arg_spec = tf_inspect.getfullargspec(cls.from_config)
256 if 'custom_objects' in arg_spec.args:
/external/llvm-project/lldb/source/Host/common/
DProcessLaunchInfo.cpp269 FileSpec arg_spec(argv0); in ConvertArgumentsForLaunchingInShell() local
270 if (arg_spec.IsRelative()) { in ConvertArgumentsForLaunchingInShell()
/external/tensorflow/tensorflow/python/ops/ragged/
Dragged_dispatch.py77 arg_spec = tf_inspect.getargspec(func)
83 if argname not in arg_spec.args:
85 (argname, func, arg_spec.args))
86 arg_infos.append(_ArgInfo(argname, arg_spec.args.index(argname), is_list))
/external/tensorflow/tensorflow/tools/compatibility/
Dtf_upgrade_v2_test.py363 arg_spec = tf_inspect.getfullargspec(method)
368 self.assertEqual(arg_spec[0][pos], arg)