pfnet / PaintsChainer

line drawing colorization using chainer
https://paintschainer.preferred.tech/
MIT License
3.77k stars 557 forks source link

I failed when I run train_128.py #104

Closed huangheL closed 7 years ago

huangheL commented 7 years ago

the error is img = cv2.cvtColor( img, cv2.COLOR_RGB2YUV ) cv2.error: D:\Build\OpenCV\opencv-3.2.0\modules\imgproc\src\color.cpp:9781: error: (-215) scn == 3 || scn == 4 in function cv::cvtColor

when I tracking the wrong, I find that the reason is no files in ./images/line and ./images/color. your code is

path2 = os.path.join(self._root2 + "_b2r/", self._paths[i])

but there is not anything in path2.

what should i do?

taizan commented 7 years ago

Its line file data augmentation, so put line image file extracted with another param into line_b2r folder also.

huangheL commented 7 years ago

you mean that I need put my own pictures with colorful and lineful pair to ./images/color and ./images/line, then write their names in .\cgi-bin\paint_x2_unet\dat\images_color_train.dat?

taizan commented 7 years ago

yes see also https://github.com/pfnet/PaintsChainer/issues/13

huangheL commented 7 years ago

thanks