PacktPublishing / Python-Deep-Learning-Cookbook

Python Deep Learning Cookbook, published by Packt
MIT License
138 stars 118 forks source link

TypeError: Invalid dimensions for image data #3

Closed mattdajacob closed 4 years ago

mattdajacob commented 6 years ago

I get the following error when executing the 4th cell in the Chapter 11 - Learning to play game with deep reinforcement learning:

TypeError: Invalid dimensions for image data

The code in cell 4 is: obs_preprocessed = preprocess_frame(observation) plt.imshow(obs_preprocessed, cmap='gray') plt.show()

The results of print(obs_preprocessed.shape) are: (5600,)