Tensorflow Lite 基准测试应用说明 [英] Tensorflow Lite benchmark app explanation

查看:37
本文介绍了Tensorflow Lite 基准测试应用说明的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用 Tensorflow Lite Benchmark Android应用程序 在 Android 设备上测试我的模型.输出示例如下:

I'm using the Tensorflow Lite Benchmark Android application to test my model on Android devices. An example of the output is the following:

我们的平均推理时间:预热:83235,初始化:38467,推理:79760.9

Average inference timings in us: Warmup: 83235, Init: 38467, Inference: 79760.9

虽然 Inference 的含义对我来说很清楚(即平均推理时间以微秒为单位),但我不知道什么是 WarmupInit 指的是?不幸的是,文档 没有解释这一点.

While the meaning Inference is quite clear to me (i.e., the average inference time in microseconds), I've no idea about what Warmup and Init refer to? Unfortunately, the documentation does not explain this point.

推荐答案

Init:加载模型和构建解释器对象所需的时间,这是初始化步骤,需要发生在开始(即一次性成本)

Init: The time it takes to load the model and build the interpreter object, which is the initialization step that needs to happen at the beginning (i.e., one-time cost)

Warmup:根据 warmup_runs 配置,开始时预热运行所需的平均推理时间.换句话说,将第一个warmup_runs个推理结果平均到输出中的Warmup结果中,并且只将后面的num_runs个推理结果被平均到 Inference 输出中.

Warmup: The average inference time it took for the warmup runs at the beginning, according to the warmup_runs configuration. In other words, the first warmup_runs number of inference results are averaged into the Warmup result in the output, and only the subsequent num_runs number of inferences are averaged into Inference output.

查看基准工具自述文件了解更多详情.https://github.com/tensorflow/tensorflow/blob/master/tensorflow/lite/tools/benchmark/README.md#parameters

Take a look at the benchmark tool README for more details. https://github.com/tensorflow/tensorflow/blob/master/tensorflow/lite/tools/benchmark/README.md#parameters

这篇关于Tensorflow Lite 基准测试应用说明的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆