Hi there,
I am creating a custom Android App for object detection. Therefore, I use the Tensorflow Object Detection Android App from here: examples/lite/examples/object_detection/android at master · tensorflow/examples · GitHub 11
I am training my models with TFlite model maker with the following code:

!pip install -q tflite-model-maker
!pip install -q pycocotools
#----------------Python code--------------------------
import numpy as np
import os
from tflite_model_maker.config import ExportFormat
from tflite_model_maker import model_spec
from tflite_model_maker import object_detector
import tensorflow as tf
assert tf.version.startswith(‘2’)
tf.get_logger().setLevel(‘ERROR’)
from absl import logging
logging.set_verbosity(logging.ERROR)
spec = model_spec.get(‘efficientdet_lite0’)
test_data = object_detector.DataLoader.from_pascal_voc(’./test’, ‘./test’, label_map={1: “Ball”, 2: “Spieler Rot”, 3: “Spieler Gelb”})
train_data = object_detector.DataLoader.from_pascal_voc(’./train’, ‘./train’, label_map={1: “Ball”, 2: “Spieler Rot”, 3: “Spieler Gelb”})
validation_data = object_detector.DataLoader.from_pascal_voc(’./valid’, ‘./valid’, label_map={1: “Ball”, 2: “Spieler Rot”, 3: “Spieler Gelb”})
model = object_detector.create(train_data, model_spec=spec, batch_size=16, train_whole_model=True, validation_data=validation_data, epochs=1)
model.evaluate(test_data)
model.export(export_dir=’.’)

This worked without any errors for many weeks. Now I get the following error in Android Studio:
Output tensor at index 0 is expected to have 3 dimensions, found 2.
My dataset is exactly the same and I train on Google Colab. I am sure that I didn’t change anything on the Android App.
I look forward for your answers 
Have an nice day.
Greetings,
Daniel Hauser