How to display a picture with python

First enter in the command box: nano 2.py


import numpy as np

import cv2
ing=cv2.imread("imagine.jpg")
cv2.imshow("imagine",ing)

cv2.waitKey(0)


Then go back to the command box,

Enter python 2.py. This picture can be displayed


Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=325384582&siteId=291194637