Skip to main content

Posts

Showing posts from December, 2021

Take 2 images, crop some part of both the images and swap them

  Libraries Required for this  1.numpy 2.Matplotlib 3.opencv Taking input from the user using img1 = cv2.imread("imageone.jpg") img2 = cv2.imread("imagetwo.png") Converting both the images into RGB format from BGR img1 = cv2.cvtColor(img1,cv2.COLOR_BGR2RGB) Showing image using Matplotlib plt.imshow(imagename)

Take 2 images and combine it to form a single image using opencv

  Libraries Required for this  1.numpy 2.Matplotlib 3.opencv Taking input from the user using img1 = cv2.imread("imageone.jpg") img2 = cv2.imread("imagetwo.png") Converting both the images into RGB format from BGR img1 = cv2.cvtColor(img1,cv2.COLOR_BGR2RGB) Showing image using Matplotlib plt.imshow(imagename)