Epoch: [0][59460/102488] Time 0.087s (0.087s) Speed 366.4 samples/s Data 0.002s (0.009s) Loss 0.01915 (0.49964)
torch.Size([32, 512, 1, 41])
torch.Size([32, 512, 1, 41])
torch.Size([32, 512, 1, 41])
torch.Size([32, 512, 1, 41])
torch.Size([32, 512, 1, 41])
torch.Size([32, 512, 1, 41])
torch.Size([32, 512, 1, 41])
torch.Size([32, 512, 1, 41])
Traceback (most recent call last):
File "train.py", line 160, in
main()
File "train.py", line 135, in main
function.train(config, train_loader, train_dataset, converter, model, criterion, optimizer, device, epoch, writer_dict, output_dict)
File "/data/OCR/CRNN_Chinese_Characters_Rec-stable/CRNN_Chinese_Characters_Rec-stable/lib/core/function.py", line 36, in train
for i, (inp, idx) in enumerate(train_loader):
File "/home/topmoo/anaconda3/lib/python3.6/site-packages/torch/utils/data/dataloader.py", line 819, in next
return self._process_data(data)
File "/home/topmoo/anaconda3/lib/python3.6/site-packages/torch/utils/data/dataloader.py", line 846, in _process_data
data.reraise()
File "/home/topmoo/anaconda3/lib/python3.6/site-packages/torch/_utils.py", line 369, in reraise
raise self.exc_type(msg)
cv2.error: Caught error in DataLoader worker process 0.
Original Traceback (most recent call last):
File "/home/anaconda3/lib/python3.6/site-packages/torch/utils/data/_utils/worker.py", line 178, in _worker_loop
data = fetcher.fetch(index)
File "/home/anaconda3/lib/python3.6/site-packages/torch/utils/data/_utils/fetch.py", line 44, in fetch
data = [self.dataset[idx] for idx in possibly_batched_index]
File "/home/anaconda3/lib/python3.6/site-packages/torch/utils/data/_utils/fetch.py", line 44, in
data = [self.dataset[idx] for idx in possibly_batched_index]
File "/data/OCR/CRNN_Chinese_Characters_Rec-stable/CRNN_Chinese_Characters_Rec-stable/lib/dataset/_360cc.py", line 45, in getitem
img = cv2.cvtColor(img, cv2.COLOR_BGR2GRAY)
cv2.error: OpenCV(3.4.10) /opencv-3.4.10/modules/imgproc/src/color.cpp:182: error: (-215:Assertion failed) !_src.empty() in function 'cvtColor'
Epoch: [0][59460/102488] Time 0.087s (0.087s) Speed 366.4 samples/s Data 0.002s (0.009s) Loss 0.01915 (0.49964) torch.Size([32, 512, 1, 41]) torch.Size([32, 512, 1, 41]) torch.Size([32, 512, 1, 41]) torch.Size([32, 512, 1, 41]) torch.Size([32, 512, 1, 41]) torch.Size([32, 512, 1, 41]) torch.Size([32, 512, 1, 41]) torch.Size([32, 512, 1, 41]) Traceback (most recent call last): File "train.py", line 160, in
main()
File "train.py", line 135, in main
function.train(config, train_loader, train_dataset, converter, model, criterion, optimizer, device, epoch, writer_dict, output_dict)
File "/data/OCR/CRNN_Chinese_Characters_Rec-stable/CRNN_Chinese_Characters_Rec-stable/lib/core/function.py", line 36, in train
for i, (inp, idx) in enumerate(train_loader):
File "/home/topmoo/anaconda3/lib/python3.6/site-packages/torch/utils/data/dataloader.py", line 819, in next
return self._process_data(data)
File "/home/topmoo/anaconda3/lib/python3.6/site-packages/torch/utils/data/dataloader.py", line 846, in _process_data
data.reraise()
File "/home/topmoo/anaconda3/lib/python3.6/site-packages/torch/_utils.py", line 369, in reraise
raise self.exc_type(msg)
cv2.error: Caught error in DataLoader worker process 0.
Original Traceback (most recent call last):
File "/home/anaconda3/lib/python3.6/site-packages/torch/utils/data/_utils/worker.py", line 178, in _worker_loop
data = fetcher.fetch(index)
File "/home/anaconda3/lib/python3.6/site-packages/torch/utils/data/_utils/fetch.py", line 44, in fetch
data = [self.dataset[idx] for idx in possibly_batched_index]
File "/home/anaconda3/lib/python3.6/site-packages/torch/utils/data/_utils/fetch.py", line 44, in
data = [self.dataset[idx] for idx in possibly_batched_index]
File "/data/OCR/CRNN_Chinese_Characters_Rec-stable/CRNN_Chinese_Characters_Rec-stable/lib/dataset/_360cc.py", line 45, in getitem
img = cv2.cvtColor(img, cv2.COLOR_BGR2GRAY)
cv2.error: OpenCV(3.4.10) /opencv-3.4.10/modules/imgproc/src/color.cpp:182: error: (-215:Assertion failed) !_src.empty() in function 'cvtColor'