提交 b154e0b4 编写于 作者: D dzhwinter

clean demo_ci

上级 abe8e207
...@@ -424,8 +424,12 @@ void Executor::RunPreparedContext(ExecutorPrepareContext* ctx, Scope* scope, ...@@ -424,8 +424,12 @@ void Executor::RunPreparedContext(ExecutorPrepareContext* ctx, Scope* scope,
VLOG(3) << "after tensor copy"; VLOG(3) << "after tensor copy";
float sum = .0; float sum = .0;
for(size_t i=0; i < check.numel(); ++i) { for(size_t i=0; i < check.numel(); ++i) {
if(std::type_index(check.type()) == std::type_index(typeid(int64_t))) {
sum += static_cast<float>(check.data<int64_t>()[i]);
} else {
sum += check.data<float>()[i]; sum += check.data<float>()[i];
} }
}
VLOG(3) << "op " << op->Type() << " input var " << var_name << " sum " << sum; VLOG(3) << "op " << op->Type() << " input var " << var_name << " sum " << sum;
} }
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册