diff --git a/official/recommend/naml/ascend310_infer/src/sample_process.cpp b/official/recommend/naml/ascend310_infer/src/sample_process.cpp index e0772ca09b2068fa0d747852f0cd3a720b1fb61e..d8871a40b7c51342ee3c9c0f9ab79aabad854803 100644 --- a/official/recommend/naml/ascend310_infer/src/sample_process.cpp +++ b/official/recommend/naml/ascend310_infer/src/sample_process.cpp @@ -318,17 +318,17 @@ void SampleProcess::DestroyResource() { } INFO_LOG("end to destroy context"); - ret = aclrtResetDevice(deviceId_); - if (ret != ACL_ERROR_NONE) { - ERROR_LOG("reset device failed"); - } - INFO_LOG("end to reset device is %d", deviceId_); - ret = aclFinalize(); if (ret != ACL_ERROR_NONE) { ERROR_LOG("finalize acl failed"); } INFO_LOG("end to finalize acl"); + + ret = aclrtResetDevice(deviceId_); + if (ret != ACL_ERROR_NONE) { + ERROR_LOG("reset device failed"); + } + INFO_LOG("end to reset device is %d", deviceId_); } std::vector<std::string> SampleProcess::GetModelExecCostTimeInfo() {