MCPcopy Create free account
hub / github.com/OpenPPL/ppl.nn / FindDataTypeByStr

Function FindDataTypeByStr

tools/pplnn.cc:663–670  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

661};
662
663static datatype_t FindDataTypeByStr(const string& str) {
664 for (int i = 0; !g_str2datatype[i].first.empty(); ++i) {
665 if (str == g_str2datatype[i].first) {
666 return g_str2datatype[i].second;
667 }
668 }
669 return DATATYPE_UNKNOWN;
670}
671
672static const char* FindDataTypeStr(datatype_t dt) {
673 for (int i = 0; !g_str2datatype[i].first.empty(); ++i) {

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected