qjadud1994 / CRNN-Keras

CRNN (CNN+RNN) for OCR using Keras / License Plate Recognition
MIT License
521 stars 191 forks source link

image resize issue in training.py #27

Open tykell opened 5 years ago

tykell commented 5 years ago

img = cv2.resize(img,(self.img_w, self.img_h),None) cv2.error: OpenCV(3.4.4) /io/opencv/modules/imgproc/src/resize.cpp:3784: error: (-215:Assertion failed) !ssize.empty() in function 'resize'

I keep getting the above error inspite of resizing my images to 128x64 and I am not able to train the model because of this.

quan7794 commented 5 years ago

You get this error because image have problem. Please check a path to your image. In Windows,character like "/" must be convert to "//". Ex: "./DB/train/" => ".//DB//train//".