作者小头像 Lv.1
15 成长值

个人介绍

这个人很懒,什么都没有留下

感兴趣或擅长的领域

暂无数据
个人勋章
TA还没获得勋章~
成长雷达
15
0
0
0
0

个人资料

个人介绍

这个人很懒,什么都没有留下

感兴趣或擅长的领域

暂无数据

达成规则

发布时间 2019/09/19 14:54:43 最后回复 LeonX86 2021/08/27 17:22:57 版块 昇腾
4792 9 0
发布时间 2021/02/06 18:04:47 最后回复 z00245565 2021/02/07 14:44:03 版块 鲲鹏DevKit
4759 8 0
发布时间 2021/02/05 15:58:23 最后回复 z00245565 2021/02/05 16:12:19 版块 昇腾
1727 4 0
他的回复:
代码如下:int main(int argc, char **argv){    AtlasAscendLog::Log::LogInfoOn();    // Parse the configuration file    ConfigParser config;    APP_ERROR ret = config.ParseConfig("./data/config/setup.config");    if (ret != APP_ERR_OK) {        LogError "Failed to parse the configuration file, ret = " ret;        return ret;    }    // Get the device ID from the configuration parsing    int32_t deviceId = 0;    ret = GetDeviceID(config, deviceId);    if (ret != APP_ERR_OK) {        LogError "Failed to Get the device ID. , ret = " ret;        return ret;    }    // Initial the Ascend, context, stream    aclrtContext context = nullptr;    aclrtStream stream = nullptr;    ret = InitAscend(deviceId, context, stream);    if (ret != APP_ERR_OK) {        LogError "Failed to initialize the Ascend, ret = " ret;        return APP_ERR_COMM_INIT_FAIL;    }    auto startTime = std::chrono::high_resolution_clock::now();    ret = DataInteraction();    if (ret != APP_ERR_OK) {        LogError "Failed to perform data interaction, ret = " ret;    }    // Destroy the Ascend, context, stream    ret = DestroyAscend(deviceId, context, stream);    if (ret != APP_ERR_OK) {        LogError "Failed to destroy the Ascend, ret = " ret;        return ret;    }    auto endTime = std::chrono::high_resolution_clock::now();    double costTime = std::chrono::duration(endTime - startTime).count();    LogInfo "TotalRuntime: " costTime "ms";    return APP_ERR_OK;}
发布时间 2018/12/11 19:48:51 最后回复 z00245565 2020/02/19 09:39:14 版块 微服务引擎
6298 1 0