import numpy as np import matplotlib.pyplot as plt # Random seed #np.random.seed(123) # Generate random data rand_data = np.random.randint(0,255,(6,6)) # Plot image plt.imshow(rand_data, cmap="OrRd") plt.show()