Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Train with own dataset #22

Open
RaminAbbaszadi opened this issue Feb 15, 2018 · 0 comments
Open

Train with own dataset #22

RaminAbbaszadi opened this issue Feb 15, 2018 · 0 comments

Comments

@RaminAbbaszadi
Copy link

Dear Titu,
Thank you for sharing your source code. I try to train your code with my own dataset which include images with size 128*64. But I get a same error in most of train model in test.py.
error:
ValueError:
Using TensorFlow backend.
Training model : ImageSuperResolutionModel
2018-02-15 09:17:35.000003: W tensorflow/core/platform/cpu_feature_guard.cc:45] The TensorFlow library wasn't compiled to use SSE4.1 instructions, but these are available on your machine and could speed up CPU computations.
2018-02-15 09:17:35.000047: W tensorflow/core/platform/cpu_feature_guard.cc:45] The TensorFlow library wasn't compiled to use SSE4.2 instructions, but these are available on your machine and could speed up CPU computations.
2018-02-15 09:17:35.000061: W tensorflow/core/platform/cpu_feature_guard.cc:45] The TensorFlow library wasn't compiled to use AVX instructions, but these are available on your machine and could speed up CPU computations.
2018-02-15 09:17:35.214561: I tensorflow/core/common_runtime/gpu/gpu_device.cc:887] Found device 0 with properties:
name: GeForce GTX TITAN X
major: 5 minor: 2 memoryClockRate (GHz) 1.076
pciBusID 0000:19:00.0
Total memory: 11.92GiB
Free memory: 3.33GiB
2018-02-15 09:17:35.214608: I tensorflow/core/common_runtime/gpu/gpu_device.cc:908] DMA: 0
2018-02-15 09:17:35.214622: I tensorflow/core/common_runtime/gpu/gpu_device.cc:918] 0: Y
2018-02-15 09:17:35.214644: I tensorflow/core/common_runtime/gpu/gpu_device.cc:977] Creating TensorFlow device (/gpu:0) -> (device: 0, name: GeForce GTX TITAN X, pci bus id: 0000:19:00.0)
Epoch 1/250
Found 51744 images.
Traceback (most recent call last):
File "tests.py", line 47, in
sr.fit(nb_epochs=250)
File "/mnt/home/ramin/srcnn-org-codes/org/Image-Super-Resolution/models.py", line 516, in fit
return super(ImageSuperResolutionModel, self).fit(batch_size, nb_epochs, save_history, history_fn)
File "/mnt/home/ramin/srcnn-org-codes/org/Image-Super-Resolution/models.py", line 122, in fit
validation_steps=val_count // batch_size + 1)
File "/mnt/home/ramin/Image-Super-Resolution/superRe/lib/python3.4/site-packages/keras/legacy/interfaces.py", line 87, in wrapper
return func(*args, **kwargs)
File "/mnt/home/ramin/Image-Super-Resolution/superRe/lib/python3.4/site-packages/keras/engine/training.py", line 2115, in fit_generator
generator_output = next(output_generator)
File "/mnt/home/ramin/Image-Super-Resolution/superRe/lib/python3.4/site-packages/keras/utils/data_utils.py", line 735, in get
six.reraise(value.class, value, value.traceback)
File "/mnt/home/ramin/Image-Super-Resolution/superRe/lib/python3.4/site-packages/six.py", line 693, in reraise
raise value
File "/mnt/home/ramin/Image-Super-Resolution/superRe/lib/python3.4/site-packages/keras/utils/data_utils.py", line 635, in data_generator_task
generator_output = next(self._generator)
File "/mnt/home/ramin/srcnn-org-codes/org/Image-Super-Resolution/img_utils.py", line 303, in image_generator
batch_x[i] = img
ValueError: could not broadcast input array from shape (16,16,3) into shape (64,64,3)
Exception ignored in: <bound method Session.del of <tensorflow.python.client.session.Session object at 0x7fe3e2aa9d68>>
Traceback (most recent call last):
File "/mnt/home/ramin/Image-Super-Resolution/superRe/lib/python3.4/site-packages/tensorflow/python/client/session.py", line 587, in del
TypeError: 'NoneType' object is not callable

I am very appreciate from you, if you help me about it.
Thank you,
Ramin

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant