3

I am following this tutorial, but with my own data: https://www.youtube.com/watch?v=yqkISICHH-U

I ran into this error, I trained my data successfully but when trying to evaluate my data I am running into this error: tensorflow.python.framework.errors_impl.InvalidArgumentError: Expected 'tf.Tensor(False, shape=(), dtype=bool)' to be true. Summarized data: b'maximum box coordinate value is larger than 1.100000: '1.2443783

It was actually successful before, as I trained a model last night and could evaluate it, but I wanted to retrain it from scratch because it wasn't detecting very well. I recompressed my images into JPG and relabelled them(used LabelImg), deleted previous checkpoints, then tried again and this is what I'm getting. So I don't think there are compatibility issues. The model I am using is SSD MobileNet V2 FPNLite 320x320. Python version 3.6 and Tensorflow 2.4.1

I checked out the other questions related to this error, but the solutions have either not worked or I lack the understanding to follow the directions, which I am open to trying if I can get better steps on how to do them.

I tried changing the box_list_ops.py as detailed here: https://github.com/tensorflow/models/issues/1754 but that has not fixed it.

I also tried running scripts to make sure my images were the correct size, and it seemed like there were no issues, but I would definitely like to double check if anyone knows what script I should use and how to use it.

Thank you, this is my first time posting on Stack Overflow so I apologize if I'm not providing enough details or information, I am willing to share more as necessary.

Apuroop_M
  • 31
  • 2

1 Answers1

1

I had the same problem, in my case what solved it was cropping the images that were in portrait format (height>width) to "become" landscape.

According to my research, it seems that TensorFlow object detection does not allow the bounding boxes to be too small (smaller than 32x32) or larger than the aspect ratio of the original image.

Another suggestion is to run or adapt this code by mgh3326 and also adjust your images that have small boxes.

Mathews Edwirds
  • 65
  • 1
  • 1
  • 9