tensorflow / tensorflow/models

CenterNet MobileNetV2 FPN 512x512 TFLite from Model Zoo doesn't work on Mobile GPU correctly

Open
#10,056 0 comments 0 reactions 3 assignees View on GitHub

@pkulzc is already working on this.

Since Jun 10, 2021.

models:research:odapi type:bug
Dominant language
Python
Stars
77.7k
Forks
44.8k
PR merge metrics
No merged PRs in 30d

Description

Prerequisites

Please answer the following questions for yourself before submitting an issue.

  • I am using the latest TensorFlow Model Garden release and TensorFlow 2.
  • I am reporting the issue to the correct repository. (Model Garden official or research directory)
  • I checked to make sure that this issue has not already been filed.

1. The entire URL of the file you are using

http://download.tensorflow.org/models/object_detection/tf2/20210210/centernet_mobilenetv2fpn_512x512_coco17_od.tar.gz

2. Describe the bug

A pre-trained TFLite model (model.tflite) from CenterNet MobileNetV2 FPN 512x512 (object detection) Model Zoo doesn't work correctly on Mobile GPU, although it's stated in Centernet_on_device.ipynb that it should work there.

Tried with various versions of org.tensorflow:tensorflow-lite-gpu including 0.0.0-nightly, 2.5.0, 2.4.0, 2.3.0, 2.2.0. Neither of them works correctly.

Tried various options for GPU delegate without any success. In particular, tried to set setPrecisionLossAllowed to false.

3. Steps to reproduce

4. Expected behavior

  • The results on CPU and GPU should be the same
  • The output scores are in [0,1] interval.

5. Additional context

The TFLite model works well and correctly on desktop (Ubuntu 20.04) in Python on both CPU and GPU.

6. System information

  • OS Platform and Distribution: Android 27
  • Mobile device name if the issue happens on a mobile device: AI Camera
  • TensorFlow installed from (source or binary): binary
  • TensorFlow version - tried multiple versions of org.tensorflow:tensorflow-lite-gpu including 0.0.0-nightly, 2.5.0, 2.4.0, 2.3.0, 2.2.0. Neither of them works correctly.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.