Browse Source

Profiling AR version 7

tags/v1.2.0
taoxiangdong 3 years ago
parent
commit
b6ee361521
2 changed files with 9 additions and 2 deletions
  1. +2
    -0
      ge/common/profiling/profiling_manager.cc
  2. +7
    -2
      ge/graph/load/new_model_manager/davinci_model.cc

+ 2
- 0
ge/common/profiling/profiling_manager.cc View File

@@ -588,6 +588,7 @@ Status ProfilingManager::ProfParseDeviceId(const std::map<std::string, std::stri
return FAILED;
} catch (std::out_of_range &) {
GELOGE(FAILED, "Device id: %s is out of range.", decvice_id[i].c_str());
return FAILED;
} catch (...) {
GELOGE(FAILED, "Device id: %s cannot change to int.", decvice_id[i].c_str());
return FAILED;
@@ -614,6 +615,7 @@ Status ProfilingManager::ProfParseParam(const std::map<std::string, std::string>
return FAILED;
} catch (std::out_of_range &) {
GELOGE(FAILED, "Device num: %s is out of range.", iter->second.c_str());
return FAILED;
} catch (...) {
GELOGE(FAILED, "Device num: %s cannot change to int.", iter->second.c_str());
return FAILED;


+ 7
- 2
ge/graph/load/new_model_manager/davinci_model.cc View File

@@ -2819,15 +2819,20 @@ void *DavinciModel::Run(DavinciModel *model) {
GE_TIMESTAMP_START(rtStreamSynchronize);
GELOGI("rtStreamSynchronize start.");
rt_ret = rtStreamSynchronize(model->rt_model_stream_);
if (rt_ret == RT_ERROR_END_OF_SEQUENCE) {
if (rt_ret == kEndOfSequence || rt_ret == kEndOfSequenceNew) {
seq_end_flag = true;
}
GE_IF_BOOL_EXEC(
if (rt_ret == kModelAbortNormal || rt_ret == kModelAbortNormalNew) {
GELOGI("The model with multiple datasets aborts normally.");
} else {
GE_IF_BOOL_EXEC(
rt_ret != RT_ERROR_NONE, rslt_flg = false; GELOGI("seq_end_flg: %d", seq_end_flag);
(void)model->ReturnResult(current_data.index, false, seq_end_flag,
data_wrapper->GetOutput()); // [No need to check value]
CsaInteract::GetInstance().StoreInternalErrorCode(rt_ret, ERROR_MODULE_RUNTIME, JOBSUBSTATE_GRAPH_EXEC);
continue);
}

GELOGI("rtStreamSynchronize end.");
GE_IF_BOOL_EXEC(model->is_first_execute_,
GE_TIMESTAMP_EVENT_END(rtStreamSynchronize, "GraphExcute::Wait for rtStreamSynchronize"));


Loading…
Cancel
Save