Advertisement
shalivitalya

Untitled

Apr 9th, 2020
204
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.46 KB | None | 0 0
  1. import numpy as np
  2. import cv2
  3. import math
  4. import matplotlib.pyplot as plt
  5.  
  6. img = np.load("file.npz")
  7. print(img.files)
  8. # rows,cols,ch = img.shape
  9. #
  10. # pts1 = np.float32([[50,50],[200,50],[50,200]])
  11. # pts2 = np.float32([[10,100],[200,50],[100,250]])
  12. #
  13. # M = cv2.getAffineTransform(pts1,pts2)
  14. #
  15. # dst = cv2.warpAffine(img,M,(cols,rows))
  16.  
  17. plt.subplot(121),plt.imshow(img),plt.title('Input')
  18. plt.subplot(122),plt.imshow(dst),plt.title('Output')
  19. plt.show()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement