Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- ValueError Traceback (most recent call last)
- <ipython-input-9-3b925296aca6> in <module>()
- 49
- 50 # Train the model, iterating on the data in batches of 32 samples
- ---> 51 model.fit(training_data, one_hot_labels, epochs=10, batch_size=32)
- 52
- 53 #model.fit(x_train, y_train, epochs=5, batch_size=32)
- C:\ProgramData\Anaconda3\envs\tensorflow\lib\site-packages\keras\models.py in fit(self, x, y, batch_size, epochs, verbose, callbacks, validation_split, validation_data, shuffle, class_weight, sample_weight, initial_epoch, **kwargs)
- 865 class_weight=class_weight,
- 866 sample_weight=sample_weight,
- --> 867 initial_epoch=initial_epoch)
- 868
- 869 def evaluate(self, x, y, batch_size=32, verbose=1,
- C:\ProgramData\Anaconda3\envs\tensorflow\lib\site-packages\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, **kwargs)
- 1520 class_weight=class_weight,
- 1521 check_batch_axis=False,
- -> 1522 batch_size=batch_size)
- 1523 # Prepare validation data.
- 1524 do_validation = False
- C:\ProgramData\Anaconda3\envs\tensorflow\lib\site-packages\keras\engine\training.py in _standardize_user_data(self, x, y, sample_weight, class_weight, check_batch_axis, batch_size)
- 1376 self._feed_input_shapes,
- 1377 check_batch_axis=False,
- -> 1378 exception_prefix='input')
- 1379 y = _standardize_input_data(y, self._feed_output_names,
- 1380 output_shapes,
- C:\ProgramData\Anaconda3\envs\tensorflow\lib\site-packages\keras\engine\training.py in _standardize_input_data(data, names, shapes, check_batch_axis, exception_prefix)
- 130 ' to have ' + str(len(shapes[i])) +
- 131 ' dimensions, but got array with shape ' +
- --> 132 str(array.shape))
- 133 for j, (dim, ref_dim) in enumerate(zip(array.shape, shapes[i])):
- 134 if not j and not check_batch_axis:
- ValueError: Error when checking input: expected dense_5_input to have 2 dimensions, but got array with shape (300, 20, 20, 3)
-
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement