SUYEgit / Surgery-Robot-Detection-Segmentation

Object detection and segmentation for a surgery robot using Mask-RCNN on Python 3, Keras, and TensorFlow..
Other
181 stars 84 forks source link

IndexError: list index out of range #11

Closed eyildiz-ugoe closed 6 years ago

eyildiz-ugoe commented 6 years ago

If you have 11 classes, you get the following error in your real_time_detection.py.

Traceback (most recent call last):
  File "detection.py", line 49, in <module>
    class_names, p['scores'], colors=colors, real_time=True)
  File "/usr/local/lib/python3.5/dist-packages/mask_rcnn-2.1-py3.5.egg/mrcnn/visualize.py", line 136, in display_instances
IndexError: list index out of range

It works with 2 and 5 classes, but not with 11.

Any thoughts?

monjurulkarim commented 6 years ago

Give mask color using 'Label' name instead of class_id.

monjurulkarim commented 6 years ago

Did it work?

eyildiz-ugoe commented 6 years ago

The issue was about something else, everything is solved now.