matplotlib画矩形框

更全面的在Draw rectangles with matplotlib

import matplotlib.patches as patches
import matplotlib.pyplot as plt
import cv2

img=cv2.imread("images/1.jpg")
plt.figure(8)
plt.imshow(imgSrc)
currentAxis=plt.gca()
rect=patches.Rectangle((200, 600),550,650,linewidth=1,edgecolor='r',facecolor='none')
currentAxis.add_patch(rect)


matplotlib画矩形框_第1张图片

你可能感兴趣的:(opencv,Python)