Skip to content

Help training #237

@Ronald-Kray

Description

@Ronald-Kray

Describe the bug
I can't proceed train step. What should I do?

To Reproduce
Steps to reproduce the behavior:
Traceback (most recent call last):
File "C:/Users/ha485/PycharmProjects/toandaominh1997_EfficientDet.Pytorch/train.py", line 334, in
main()
File "C:/Users/ha485/PycharmProjects/toandaominh1997_EfficientDet.Pytorch/train.py", line 330, in main
main_worker(args.gpu, ngpus_per_node, args)
File "C:/Users/ha485/PycharmProjects/toandaominh1997_EfficientDet.Pytorch/train.py", line 275, in main_worker
train(train_loader, model, scheduler, optimizer, epoch, args)
File "C:/Users/ha485/PycharmProjects/toandaominh1997_EfficientDet.Pytorch/train.py", line 105, in train
for idx, (images, annotations) in enumerate(train_loader):
File "C:\Users\ha485.conda\envs'EfficientDet_toandao'\lib\site-packages\torch\utils\data\dataloader.py", line 819, in next
return self._process_data(data)
File "C:\Users\ha485.conda\envs'EfficientDet_toandao'\lib\site-packages\torch\utils\data\dataloader.py", line 846, in _process_data
data.reraise()
File "C:\Users\ha485.conda\envs'EfficientDet_toandao'\lib\site-packages\torch_utils.py", line 369, in reraise
raise self.exc_type(msg)
AttributeError: Caught AttributeError in DataLoader worker process 0.
Original Traceback (most recent call last):
File "C:\Users\ha485.conda\envs'EfficientDet_toandao'\lib\site-packages\torch\utils\data_utils\worker.py", line 178, in _worker_loop
data = fetcher.fetch(index)
File "C:\Users\ha485.conda\envs'EfficientDet_toandao'\lib\site-packages\torch\utils\data_utils\fetch.py", line 44, in fetch
data = [self.dataset[idx] for idx in possibly_batched_index]
File "C:\Users\ha485.conda\envs'EfficientDet_toandao'\lib\site-packages\torch\utils\data_utils\fetch.py", line 44, in
data = [self.dataset[idx] for idx in possibly_batched_index]
File "C:\Users\ha485\PycharmProjects\toandaominh1997_EfficientDet.Pytorch\datasets\coco.py", line 66, in getitem
img = self.load_image(idx)
File "C:\Users\ha485\PycharmProjects\toandaominh1997_EfficientDet.Pytorch\datasets\coco.py", line 79, in load_image
if len(img.shape) == 2:
AttributeError: 'NoneType' object has no attribute 'shape'

Expected behavior
A clear and concise description of what you expected to happen.

Screenshots
If applicable, add screenshots to help explain your problem.

Desktop (please complete the following information):

  • OS: [e.g. Windows, Ubuntu 18.04]
  • This repository version [e.g. pypi 0.3.1 or branch/commit ref]
  • PyTorch version w/ CUDA/cuDNN [e.g. from conda list, 1.7.0 py3.8_cuda11.0.221_cudnn8.0.3_0]

Additional context
Add any other context about the problem here.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions