30 "device is busy, retry later" 35 "an unexpected error was encontered during the function call" 40 "the host is out of memory" 44 MVNC_DEVICE_NOT_FOUND,
45 "there is no device at the given index or name" 49 MVNC_INVALID_PARAMETERS,
50 "at least one of the given parameters is invalid in the context of the function call" 55 "timeout in the communication with the device" 60 "the file named MvNCAPI.mvcmd should be installed in the mvnc direcotry" 70 "the graph or device has been closed during the operation" 74 MVNC_UNSUPPORTED_GRAPH_FILE,
75 "the graph file may have been created with an incompatible prior version of the Toolkit" 80 "an error has been reported by Movidius VPU" 86 assert(MVNC_OK >= code && code >= MVNC_MYRIAD_ERROR);
90 const std::string msg = CODE2STR.at(code);
92 if (code == MVNC_BUSY)
97 if (code == MVNC_ERROR)
102 if (code == MVNC_OUT_OF_MEMORY)
107 if (code == MVNC_DEVICE_NOT_FOUND)
112 if (code == MVNC_INVALID_PARAMETERS)
117 if (code == MVNC_TIMEOUT)
122 if (code == MVNC_MVCMD_NOT_FOUND)
127 if (code == MVNC_NO_DATA)
132 if (code == MVNC_GONE)
137 if (code == MVNC_UNSUPPORTED_GRAPH_FILE)
142 if (code == MVNC_MYRIAD_ERROR)
147 catch (std::out_of_range& e)
std::map< int, std::string > CODE2STR
static void tryToThrowMvncException(int code)