- Enhance low resolution image to high resolution image
Click image to see Youtube video!
- Python 3+
- Keras
- numpy
- OpenCV
- scikit-image
- matplotlib (for visualization)
Super resolution with Subpixel CNN using Keras
Click image to see Youtube video!
train 파일에서
아래와 같은 오류가 계속 발생해야 하는데 어떻게 수정 할 수 있을 까요?
19962 19962
/home/ubuntu/SuperResolution/super_resolution-master/processed/x_test/182638.npy
Traceback (most recent call last):
File "train.py", line 99, in
y_pred = model.predict(x1_test.reshape((1, 44, 44, 3)))
ValueError: cannot reshape array of size 1936 into shape (1,44,44,3)
y_train 용량이 얼마나 만들어지나요? 88G 까지 만들다가 용량 없어서 에러 나네요 ㅜㅜ
history = model.fit_generator(train_gen, validation_data=val_gen, epochs=10, verbose=1, callbacks=[
ModelCheckpoint(r'models\model.h5', monitor='val_loss', verbose=1, save_best_only=True)
])
IndexError Traceback (most recent call last)
in
----> 1 history = model.fit_generator(train_gen, validation_data=val_gen, epochs=10, verbose=1, callbacks=[
2 ModelCheckpoint(r'models\model.h5', monitor='val_loss', verbose=1, save_best_only=True)
3 ])
~\anaconda3\lib\site-packages\tensorflow\python\util\deprecation.py in new_func(*args, **kwargs)
322 'in a future version' if date is None else ('after %s' % date),
323 instructions)
--> 324 return func(*args, **kwargs)
325 return tf_decorator.make_decorator(
326 func, new_func, 'deprecated',
~\anaconda3\lib\site-packages\tensorflow\python\keras\engine\training.py in fit_generator(self, generator, steps_per_epoch, epochs, verbose, callbacks, validation_data, validation_steps, validation_freq, class_weight, max_queue_size, workers, use_multiprocessing, shuffle, initial_epoch)
1813 """
1814 _keras_api_gauge.get_cell('fit_generator').set(True)
-> 1815 return self.fit(
1816 generator,
1817 steps_per_epoch=steps_per_epoch,
~\anaconda3\lib\site-packages\tensorflow\python\keras\engine\training.py in _method_wrapper(self, *args, **kwargs)
106 def _method_wrapper(self, *args, **kwargs):
107 if not self._in_multi_worker_mode(): # pylint: disable=protected-access
--> 108 return method(self, *args, **kwargs)
109
110 # Running inside run_distribute_coordinator
already.
~\anaconda3\lib\site-packages\tensorflow\python\keras\engine\training.py in fit(self, x, y, batch_size, epochs, verbose, callbacks, validation_split, validation_data, shuffle, class_weight, sample_weight, initial_epoch, steps_per_epoch, validation_steps, validation_batch_size, validation_freq, max_queue_size, workers, use_multiprocessing)
1047 training_utils.RespectCompiledTrainableState(self):
1048 # Creates a tf.data.Dataset
and handles batch and epoch iteration.
-> 1049 data_handler = data_adapter.DataHandler(
1050 x=x,
1051 y=y,
~\anaconda3\lib\site-packages\tensorflow\python\keras\engine\data_adapter.py in init(self, x, y, sample_weight, batch_size, steps_per_epoch, initial_epoch, epochs, shuffle, class_weight, max_queue_size, workers, use_multiprocessing, model, steps_per_execution)
1103
1104 adapter_cls = select_data_adapter(x, y)
-> 1105 self._adapter = adapter_cls(
1106 x,
1107 y,
~\anaconda3\lib\site-packages\tensorflow\python\keras\engine\data_adapter.py in init(self, x, y, sample_weights, shuffle, workers, use_multiprocessing, max_queue_size, model, **kwargs)
907 self._keras_sequence = x
908 self._enqueuer = None
--> 909 super(KerasSequenceAdapter, self).init(
910 x,
911 shuffle=False, # Shuffle is handed in the _make_callable override.
~\anaconda3\lib\site-packages\tensorflow\python\keras\engine\data_adapter.py in init(self, x, y, sample_weights, workers, use_multiprocessing, max_queue_size, model, **kwargs)
784 # Since we have to know the dtype of the python generator when we build the
785 # dataset, we have to look at a batch to infer the structure.
--> 786 peek, x = self._peek_and_restore(x)
787 peek = self._standardize_batch(peek)
788 peek = _process_tensorlike(peek)
~\anaconda3\lib\site-packages\tensorflow\python\keras\engine\data_adapter.py in _peek_and_restore(x)
918 @staticmethod
919 def _peek_and_restore(x):
--> 920 return x[0], x
921
922 def _handle_multiprocessing(self, x, workers, use_multiprocessing,
~\Desktop...\DataGenerator.py in getitem(self, index)
30
31 # Generate data
---> 32 X, y = self.__data_generation(list_IDs_temp)
33
34 return X, y
~\Desktop,..SuperResolution\DataGenerator.py in __data_generation(self, list_IDs_temp)
52
53 splited = ID.split('/')
---> 54 splited[-2] = 'y' + splited[-2][1:] # x_train -> y_train
55 y_path = os.path.join(os.sep, *splited)
56
IndexError: list index out of range
그리고 그래픽 카드 메모리를 확 차지하네요 90% 이상 fit_generator 실행하면 에러나면서
UnknownError Traceback (most recent call last)
...
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.