2016年12月18日 星期日

Python - matplotlib畫圖表

import pyplot、image
from matplotlib import pyplot as plt
from matplotlib import image as img
Display a Matplotlib RGB Image
image = img.imread(ImageFilePath)
plt.imshow(image)
plt.show()
Add a arbitrary line
plt.plot([x0,x1],[y0,y1],"r")
Invert axis
plt.gca().invert_xaxis()
plt.gca().invert_yaxis()

沒有留言:

張貼留言