MCPcopy Create free account
hub / github.com/cyrusbehr/tensorrt-cpp-api / checkCudaErrorCode

Function checkCudaErrorCode

src/engine.h:22–29  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

20}
21
22inline void checkCudaErrorCode(cudaError_t code) {
23 if (code != 0) {
24 std::string errMsg = "CUDA operation failed with code: " + std::to_string(code) + "(" + cudaGetErrorName(code) +
25 "), with message: " + cudaGetErrorString(code);
26 std::cout << errMsg << std::endl;
27 throw std::runtime_error(errMsg);
28 }
29}
30
31std::vector<std::string> getFilesInDirectory(const std::string &dirPath);
32} // namespace Util

Callers 7

clearGpuBuffersMethod · 0.85
loadNetworkMethod · 0.85
buildMethod · 0.85
runInferenceMethod · 0.85
getBatchMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected