yolact
yolact copied to clipboard
Training on custom data doesn't seem to load segmentations labels
File "C:\Users\marrabld\Documents\GitHub\yolact\data\coco.py", line 280, in detection_collate
targets.append(torch.FloatTensor(sample[1][0]))
TypeError: new(): data must be a sequence (got NoneType)
Each sample in the batch in detection_collate is None
![image](https://user-images.githubusercontent.com/2086569/193405296-6e269b18-49b9-457a-ae78-9e24206a6fa5.png)
As you can see in the right hand side of the screenshot, the labels.json can be read and rendered correctly with fiftyone
I get the following errors
C:\Users\marrabld\anaconda3\envs\yolact\python.exe "C:/Program Files/JetBrains/PyCharm Community Edition 2022.2.2/plugins/python-ce/helpers/pydev/pydevd.py" --multiprocess --qt-support=auto --client 127.0.0.1 --port 49341 --file C:\Users\marrabld\Documents\GitHub\yolact\train.py --config=yolact_resnet50_raiid_config
Connected to pydev debugger (build 222.4167.33)
loading annotations into memory...
Done (t=0.12s)
creating index...
index created!
loading annotations into memory...
Done (t=0.12s)
creating index...
index created!
C:\Users\marrabld\anaconda3\envs\yolact\lib\site-packages\torch\jit\_recursive.py:235: UserWarning: 'lat_layers' was found in ScriptModule constants, but it is a non-constant submodule. Consider removing it.
" but it is a non-constant {}. Consider removing it.".format(name, hint))
C:\Users\marrabld\anaconda3\envs\yolact\lib\site-packages\torch\jit\_recursive.py:235: UserWarning: 'pred_layers' was found in ScriptModule constants, but it is a non-constant submodule. Consider removing it.
" but it is a non-constant {}. Consider removing it.".format(name, hint))
C:\Users\marrabld\anaconda3\envs\yolact\lib\site-packages\torch\jit\_recursive.py:235: UserWarning: 'downsample_layers' was found in ScriptModule constants, but it is a non-constant submodule. Consider removing it.
" but it is a non-constant {}. Consider removing it.".format(name, hint))
Initializing weights...
Begin training!
C:\Users\marrabld\Documents\GitHub\yolact\utils\augmentations.py:315: VisibleDeprecationWarning: Creating an ndarray from ragged nested sequences (which is a list-or-tuple of lists-or-tuples-or ndarrays with different lengths or shapes) is deprecated. If you meant to do this, you must specify 'dtype=object' when creating the ndarray.
mode = random.choice(self.sample_options)
C:\Users\marrabld\Documents\GitHub\yolact\utils\augmentations.py:315: VisibleDeprecationWarning: Creating an ndarray from ragged nested sequences (which is a list-or-tuple of lists-or-tuples-or ndarrays with different lengths or shapes) is deprecated. If you meant to do this, you must specify 'dtype=object' when creating the ndarray.
mode = random.choice(self.sample_options)
C:\Users\marrabld\Documents\GitHub\yolact\utils\augmentations.py:315: VisibleDeprecationWarning: Creating an ndarray from ragged nested sequences (which is a list-or-tuple of lists-or-tuples-or ndarrays with different lengths or shapes) is deprecated. If you meant to do this, you must specify 'dtype=object' when creating the ndarray.
mode = random.choice(self.sample_options)
C:\Users\marrabld\Documents\GitHub\yolact\utils\augmentations.py:315: VisibleDeprecationWarning: Creating an ndarray from ragged nested sequences (which is a list-or-tuple of lists-or-tuples-or ndarrays with different lengths or shapes) is deprecated. If you meant to do this, you must specify 'dtype=object' when creating the ndarray.
mode = random.choice(self.sample_options)
Traceback (most recent call last):
File "C:\Users\marrabld\Documents\GitHub\yolact\train.py", line 270, in train
for datum in data_loader:
File "C:\Users\marrabld\anaconda3\envs\yolact\lib\site-packages\torch\utils\data\dataloader.py", line 530, in __next__
data = self._next_data()
File "C:\Users\marrabld\anaconda3\envs\yolact\lib\site-packages\torch\utils\data\dataloader.py", line 1224, in _next_data
return self._process_data(data)
File "C:\Users\marrabld\anaconda3\envs\yolact\lib\site-packages\torch\utils\data\dataloader.py", line 1250, in _process_data
data.reraise()
File "C:\Users\marrabld\anaconda3\envs\yolact\lib\site-packages\torch\_utils.py", line 457, in reraise
raise exception
TypeError: Caught TypeError in DataLoader worker process 0.
Original Traceback (most recent call last):
File "C:\Users\marrabld\anaconda3\envs\yolact\lib\site-packages\torch\utils\data\_utils\worker.py", line 287, in _worker_loop
data = fetcher.fetch(index)
File "C:\Users\marrabld\anaconda3\envs\yolact\lib\site-packages\torch\utils\data\_utils\fetch.py", line 52, in fetch
return self.collate_fn(data)
File "C:\Users\marrabld\Documents\GitHub\yolact\data\coco.py", line 280, in detection_collate
targets.append(torch.FloatTensor(sample[1][0]))
TypeError: new(): data must be a sequence (got NoneType)
python-BaseException
C:\Users\marrabld\Documents\GitHub\yolact\utils\augmentations.py:315: VisibleDeprecationWarning: Creating an ndarray from ragged nested sequences (which is a list-or-tuple of lists-or-tuples-or ndarrays with different lengths or shapes) is deprecated. If you meant to do this, you must specify 'dtype=object' when creating the ndarray.
mode = random.choice(self.sample_options)