You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When I use my own data set, the loss appears nan, and it reports WARNING:root:NaN or Inf found in input tensor. What is the reason?
**Traceback (most recent call last):
File "train.py", line 114, in
main()
File "train.py", line 105, in main
model = train(cfg, args)
File "train.py", line 44, in train
model = do_train(cfg, model, train_loader, optimizer, scheduler, checkpointer, device, arguments, args)
File "D:\Document\PersonalDocuments\FileCollection\All_Programs\Python\MyPaperExperiment\lufficc\original\SSD-master\ssd\engine\trainer.py", line
76, in do_train
for iteration, (images, targets, _) in enumerate(data_loader, start_iter):
File "D:\Software\ProgrammingTools\Anaconda\envs\torch1.6\lib\site-packages\torch\utils\data\dataloader.py", line 363, in next
data = self._next_data()
File "D:\Software\ProgrammingTools\Anaconda\envs\torch1.6\lib\site-packages\torch\utils\data\dataloader.py", line 989, in _next_data
return self._process_data(data)
File "D:\Software\ProgrammingTools\Anaconda\envs\torch1.6\lib\site-packages\torch\utils\data\dataloader.py", line 1014, in _process_data
data.reraise()
File "D:\Software\ProgrammingTools\Anaconda\envs\torch1.6\lib\site-packages\torch_utils.py", line 395, in reraise
raise self.exc_type(msg)
cv2.error: Caught error in DataLoader worker process 1.
Original Traceback (most recent call last):
File "D:\Software\ProgrammingTools\Anaconda\envs\torch1.6\lib\site-packages\torch\utils\data_utils\worker.py", line 185, in _worker_loop
data = fetcher.fetch(index)
File "D:\Software\ProgrammingTools\Anaconda\envs\torch1.6\lib\site-packages\torch\utils\data_utils\fetch.py", line 44, in fetch
data = [self.dataset[idx] for idx in possibly_batched_index]
File "D:\Software\ProgrammingTools\Anaconda\envs\torch1.6\lib\site-packages\torch\utils\data_utils\fetch.py", line 44, in
data = [self.dataset[idx] for idx in possibly_batched_index]
File "D:\Document\PersonalDocuments\FileCollection\All_Programs\Python\MyPaperExperiment\lufficc\original\SSD-master\ssd\data\datasets\voc.py", l
ine 44, in getitem
image, boxes, labels = self.transform(image, boxes, labels)
File "D:\Document\PersonalDocuments\FileCollection\All_Programs\Python\MyPaperExperiment\lufficc\original\SSD-master\ssd\data\transforms\transfor
ms.py", line 75, in call
img, boxes, labels = t(img, boxes, labels)
File "D:\Document\PersonalDocuments\FileCollection\All_Programs\Python\MyPaperExperiment\lufficc\original\SSD-master\ssd\data\transforms\transfor
ms.py", line 135, in call
self.size))
cv2.error: OpenCV(4.5.4) 👎 error: (-5:Bad argument) in function 'resize'
Overload resolution failed:
Conversion error: src
Expected Ptrcv::UMat for argument 'src'**
The text was updated successfully, but these errors were encountered:
When I use my own data set, the loss appears nan, and it reports WARNING:root:NaN or Inf found in input tensor. What is the reason?
**Traceback (most recent call last):
File "train.py", line 114, in
main()
File "train.py", line 105, in main
model = train(cfg, args)
File "train.py", line 44, in train
model = do_train(cfg, model, train_loader, optimizer, scheduler, checkpointer, device, arguments, args)
File "D:\Document\PersonalDocuments\FileCollection\All_Programs\Python\MyPaperExperiment\lufficc\original\SSD-master\ssd\engine\trainer.py", line
76, in do_train
for iteration, (images, targets, _) in enumerate(data_loader, start_iter):
File "D:\Software\ProgrammingTools\Anaconda\envs\torch1.6\lib\site-packages\torch\utils\data\dataloader.py", line 363, in next
data = self._next_data()
File "D:\Software\ProgrammingTools\Anaconda\envs\torch1.6\lib\site-packages\torch\utils\data\dataloader.py", line 989, in _next_data
return self._process_data(data)
File "D:\Software\ProgrammingTools\Anaconda\envs\torch1.6\lib\site-packages\torch\utils\data\dataloader.py", line 1014, in _process_data
data.reraise()
File "D:\Software\ProgrammingTools\Anaconda\envs\torch1.6\lib\site-packages\torch_utils.py", line 395, in reraise
raise self.exc_type(msg)
cv2.error: Caught error in DataLoader worker process 1.
Original Traceback (most recent call last):
File "D:\Software\ProgrammingTools\Anaconda\envs\torch1.6\lib\site-packages\torch\utils\data_utils\worker.py", line 185, in _worker_loop
data = fetcher.fetch(index)
File "D:\Software\ProgrammingTools\Anaconda\envs\torch1.6\lib\site-packages\torch\utils\data_utils\fetch.py", line 44, in fetch
data = [self.dataset[idx] for idx in possibly_batched_index]
File "D:\Software\ProgrammingTools\Anaconda\envs\torch1.6\lib\site-packages\torch\utils\data_utils\fetch.py", line 44, in
data = [self.dataset[idx] for idx in possibly_batched_index]
File "D:\Document\PersonalDocuments\FileCollection\All_Programs\Python\MyPaperExperiment\lufficc\original\SSD-master\ssd\data\datasets\voc.py", l
ine 44, in getitem
image, boxes, labels = self.transform(image, boxes, labels)
File "D:\Document\PersonalDocuments\FileCollection\All_Programs\Python\MyPaperExperiment\lufficc\original\SSD-master\ssd\data\transforms\transfor
ms.py", line 75, in call
img, boxes, labels = t(img, boxes, labels)
File "D:\Document\PersonalDocuments\FileCollection\All_Programs\Python\MyPaperExperiment\lufficc\original\SSD-master\ssd\data\transforms\transfor
ms.py", line 135, in call
self.size))
cv2.error: OpenCV(4.5.4) 👎 error: (-5:Bad argument) in function 'resize'
The text was updated successfully, but these errors were encountered: