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

Method get_multi_trainer_path

src/callbacks/callback.cpp:37–49  ·  view source on GitHub ↗

@brief Build a standard directory hierarchy including trainer ID. */

Source from the content-addressed store, hash-verified

35/** @brief Build a standard directory hierarchy including trainer ID.
36 */
37std::string callback_base::get_multi_trainer_path(const model& m,
38 const std::string& root_dir)
39{
40 std::string dir = root_dir;
41 if (dir.empty()) {
42 dir = "./";
43 }
44 if (dir.back() != '/') {
45 dir += "/";
46 }
47
48 return build_string(dir, get_const_trainer().get_name(), '/');
49}
50
51/** @brief Build a standard directory hierachy including trainer,
52 * execution context, and model information (in that order).

Callers

nothing calls this directly

Calls 3

build_stringFunction · 0.85
emptyMethod · 0.45
get_nameMethod · 0.45

Tested by

no test coverage detected