【问题标题】:TensorFlow Android API - A way to increase log level without changing code?TensorFlow Android API - 一种在不更改代码的情况下提高日志级别的方法?
【发布时间】:2017-10-05 13:44:05
【问题描述】:

我为 Android 编译了 TensorFlow,我可以看到默认情况下 VLOG 级别为 0。

这会导致很多这样的日志行:

tensorflow_inference_jni.cc:237 End computing. Ran in XXX ms (YYY ms avg over ZZZ runs)

我知道这在理论上可以通过设置TF_CPP_MIN_VLOG_LEVEL环境变量来解决。

我想知道是否有办法告诉我的 android 应用设置此环境变量(可能为调试/发布设置不同的级别),或者我必须更改 JNI 代码并重新编译以消除此日志消息.

【问题讨论】:

    标签: java android logging tensorflow environment-variables


    【解决方案1】:

    我认为您使用的是过时版本的 Tensorflow。

    打印该日志消息的代码在此提交中被删除: https://github.com/tensorflow/tensorflow/commit/1a9769dc79fdd27c347633df210ff64f48de8d07

    我建议更新到 Tensorflow v1.1。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2015-02-02
      • 1970-01-01
      • 2019-05-18
      • 2011-08-22
      • 1970-01-01
      • 2011-01-28
      相关资源
      最近更新 更多