jmiller656 / EDSR-Tensorflow

Tensorflow implementation of Enhanced Deep Residual Networks for Single Image Super-Resolution
MIT License
330 stars 107 forks source link

Issue about training my own dataset #10

Open kennylovesfree opened 6 years ago

kennylovesfree commented 6 years ago

Thanks for your sharing, it helps a lot. But when I use my own images to train, it always show like below:

Traceback (most recent call last): File "train.py", line 20, in network.train(args.iterations,args.savedir) File "/home/zhangyao/kenny/SR/EDSR-Tensorflow/model.py", line 206, in train test_x,test_y = self.test_data(*self.test_args) File "/home/zhangyao/kenny/SR/EDSR-Tensorflow/data.py", line 41, in get_test_set img = crop_center(img,original_size,original_size) File "/home/zhangyao/kenny/SR/EDSR-Tensorflow/data.py", line 81, in cropcenter y,x, = img.shape ValueError: need more than 2 values to unpack

I was wondering whether it happens because about too small image size. Look forward for your help~

jmiller656 commented 6 years ago

Seen some confusion with this before. It looks like this is happening because you're using black and white images. I'll make a fix for this, because it seems to be counter-intuitive to people.

Hoping to fix this tonight, actually. I'll keep you posted

kennylovesfree commented 6 years ago

Thanks for your help! I have not checked whether I use black and white images. But when I use larger(>500*500)jpg images, it works. So maybe it caused by too small iamge?