import cv2
font = cv2.FONT_HERSHEY_SIMPLEX
img = cv2.imread('putText_1.jpg')
cv2.putText(img, 'judy', (110, 1590), font, 8, (128, 0, 128), 8)
cv2.namedWindow('putText_1', cv2.WINDOW_KEEPRATIO)
cv2.imshow('putText_1', img)
cv2.waitKey(0)
cv2.destroyAllWindows()
import cv2
font = cv2.FONT_HERSHEY_SIMPLEX
img = cv2.imread('Picture10.jpg')
cv2.putText(img, 'opencv', (20, 59), font, 1, (128, 0, 128), 4)
cv2.namedWindow('putText_2', cv2.WINDOW_KEEPRATIO)
cv2.imshow('putText_1', img)
cv2.waitKey(0)
cv2.destroyAllWindows()