MCPcopy Index your code
hub / github.com/tensorflow/models / parse_configuration

Function parse_configuration

official/core/train_utils.py:377–391  ·  view source on GitHub ↗

Parses ExperimentConfig from flags.

(flags_obj, lock_return=True, print_return=True)

Source from the content-addressed store, hash-verified

375
376
377def parse_configuration(flags_obj, lock_return=True, print_return=True):
378 """Parses ExperimentConfig from flags."""
379
380 params = ExperimentParser(flags_obj).parse()
381
382 params.validate()
383 if lock_return:
384 params.lock()
385
386 if print_return:
387 pp = pprint.PrettyPrinter()
388 logging.info('Final experiment parameters:\n%s',
389 pp.pformat(params.as_dict()))
390
391 return params
392
393
394def serialize_config(params: config_definitions.ExperimentConfig,

Callers

nothing calls this directly

Calls 6

ExperimentParserClass · 0.85
lockMethod · 0.80
infoMethod · 0.80
parseMethod · 0.45
validateMethod · 0.45
as_dictMethod · 0.45

Tested by

no test coverage detected