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

Function GetGradDefs

tensorflow/c/c_test_util.cc:434–442  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

432}
433
434std::vector<std::pair<string, string>> GetGradDefs(
435 const tensorflow::GraphDef& graph_def) {
436 std::vector<std::pair<string, string>> grads;
437 for (const tensorflow::GradientDef& grad : graph_def.library().gradient()) {
438 grads.emplace_back(grad.function_name(), grad.gradient_func());
439 }
440 std::sort(grads.begin(), grads.end());
441 return grads;
442}
443
444std::vector<string> GetFuncNames(const tensorflow::GraphDef& graph_def) {
445 std::vector<string> names;

Callers 1

TEST_FFunction · 0.85

Calls 7

sortFunction · 0.85
gradientMethod · 0.80
function_nameMethod · 0.80
libraryMethod · 0.45
emplace_backMethod · 0.45
beginMethod · 0.45
endMethod · 0.45

Tested by

no test coverage detected