Multiprocessing not available, fall back to single threaded encoding imread read blank (None) image for file: /home/opencv/–center-crop/Downloads/img/h_101.jpg

gluon-cv
code-error
unix-based

#1

When i try create .rec files using im2rec.py

i get these errors,what does it mean and how to fix
machine:~$ python Downloads/im2rec.py Downloads/train –center-crop --resize 224 --pack-label
Creating .rec file from /home/opencv/Downloads/train/dog.lst in /home/opencv/Downloads/train
multiprocessing not available, fall back to single threaded encoding
imread read blank (None) image for file: /home/opencv/–center-crop/Downloads/img/h_101.jpg
Traceback (most recent call last):
File “Downloads/im2rec.py”, line 386, in
record.write_idx(item[0], s)
File “/home/opencv/.local/lib/python2.7/site-packages/mxnet/recordio.py”, line 285, in write_idx
self.write(buf)
File “/home/opencv/.local/lib/python2.7/site-packages/mxnet/recordio.py”, line 135, in write
ctypes.c_size_t(len(buf))))
TypeError: object of type ‘NoneType’ has no len()


#2

Hi @Data_Miner, I spot a typo! Check just before center-crop.

You’ve got –center-crop when it needs to be --center-crop, so the script is looking for a file at /home/opencv/–center-crop/Downloads/img/h_101.jpg which doesn’t exist.


#3

Thank you, it is works:)