MCPcopy Create free account
hub / github.com/LBANN/lbann / _get_work_dir

Function _get_work_dir

ci_test/common_python/test_util.py:327–334  ·  view source on GitHub ↗
(test_file: str)

Source from the content-addressed store, hash-verified

325
326# Mimics the other tester's determination of working directory
327def _get_work_dir(test_file: str) -> str:
328 test_fname = os.path.realpath(test_file)
329 # Create test name by removing '.py' from file name
330 test_fname = os.path.splitext(os.path.basename(test_fname))[0]
331 if not re.match('^test_.', test_fname):
332 # Make sure test name is prefixed with 'test_'
333 test_fname = 'test_' + test_fname
334 return os.path.join(os.path.dirname(test_file), 'experiments', test_fname)
335
336
337# Ensures that backpropagation would be run through the entire model

Callers 1

setup_funcFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected