【发布时间】:2021-04-09 19:18:56
【问题描述】:
我正在将 Google 的 MLKit 用于 Android 应用程序来进行对象检测。 我知道有一些 TFlite 模型与 MLKit 兼容,但是当我大部分时间使用其他模型时,我都会遇到这个错误:
com.google.android.gms.tasks.RuntimeExecutionException: com.google.mlkit.common.MlKitException: Failed to initialize detector. Unexpected number of dimensions for output index 0: got 3D, expected either 2D (BxN with B=1) or 4D (BxHxWxN with B=1, W=1, H=1).
我想知道是否有可能(以及如何)操纵输入/输出(对于某些模型,问题是其他输出的输入)以满足此处对 MLKit 的要求:https://developers.google.com/ml-kit/custom-models#model-compatibility
我正在尝试将方形猪放入圆孔中?
【问题讨论】:
标签: android tensorflow-lite google-mlkit