thtrieu / darkflow

Translate darknet to tensorflow. Load trained weights, retrain/fine-tune using tensorflow, export constant graph def to mobile devices
GNU General Public License v3.0
6.13k stars 2.08k forks source link

AttributeError: 'NoneType' object has no attribute 'path' Aborted (core dumped) #1115

Open ankitAMD opened 4 years ago

ankitAMD commented 4 years ago

(abc) assetone04@assetone04-Vostro-3490:~/Music/Darkflow-object-detection-master$ python draw_box.py

     Traceback (most recent call last):
          File "/home/assetone04/anaconda2/envs/abc/lib/python3.6/site-packages/matplotlib/backends/backend_qt5.py", line 335, in keyPressEvent
         FigureCanvasBase.key_press_event(self, key, guiEvent=event)
         File "/home/assetone04/anaconda2/envs/abc/lib/python3.6/site-packages/matplotlib/backend_bases.py", line 1861, in key_press_event
           self.callbacks.process(s, event)
         File "/home/assetone04/anaconda2/envs/abc/lib/python3.6/site-packages/matplotlib/cbook.py", line 554, in process
          proxy(*args, **kwargs)
          File "/home/assetone04/anaconda2/envs/abc/lib/python3.6/site-packages/matplotlib/cbook.py", line 416, in __call__
          return mtd(*args, **kwargs)
          File "draw_box.py", line 35, in onkeypress
         write_xml(image_folder, img, object_list, tl_list, br_list, savedir)
           File "/home/assetone04/Music/Darkflow-object-detection-master/gen_xml.py", line 11, in write_xml
           image = cv2.imread(img.path)
          AttributeError: 'NoneType' object has no attribute 'path'
          Aborted (core dumped)

i given location correct but i don't why it comes when i press two times "q" this happen.

no_path

ankitAMD commented 4 years ago

@thtrieu, @abagshaw please help. Thanks a lot in advance. please help.