1

众所周知,可以通过 gcloud 中的 other files 标志上传其他文件。我正在尝试使用 firebase 测试实验室性能应用程序来检查网络的性能。

我运行的命令是:

gcloud firebase test android run --type=game-loop --app=bazel-bin/tensorflow/lite/tools/benchmark/experimental/firebase/android/benchmark_model_firebase.apk --device model=flame,version=29 --other -files=/data/local/tmp/graph=network1.tflite

该命令因错误而崩溃:

错误:gcloud 崩溃(InvalidUserInputError):无法猜测 network1.tflite 的 mime 类型

有没有办法绕过这个问题或以某种方式将 mime 类型传递给命令行?

4

1 回答 1

1

我找到了一个疯狂的解决方法。我将 tflite 文件重命名为 so 所以 mimetypes 库给了它一个八位字节流 mime 类型并且一切正常。

gcloud firebase test android run --type=game-loop --app=bazel-bin/tensorflow/lite/tools/benchmark/experimental/firebase/android/benchmark_model_firebase.apk --device model=flame,version=29 --other -files=/data/local/tmp/graph=network1.so

在 google 中打开了一个问题:https ://issuetracker.google.com/issues/196230363

于 2021-08-12T07:22:20.663 回答