Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

python & imshow with pyplot

Hello all,

I'm trying to get running this example

import numpy as np
import cv2
from matplotlib import pyplot as plt

img = cv2.imread('messi5.jpg',0)
plt.imshow(img, cmap = 'gray', interpolation = 'bicubic')
plt.xticks([]), plt.yticks([])  # to hide tick values on X and Y axis
plt.show()

Examples shows image but the code at plt.show() get stopped and now further command promt avialable from python. I'm running it within

Python 2.7.10 (default, May 23 2015, 09:40:32) [MSC v.1500 32 bit (Intel)] on win32

Thank you for your advice.

Regards,Peter