l have a set of images of different sizes (45,50,3), (69,34,3), (34,98,3). l want to add padding to these images as follows:
Take the max width and leng
You can use:
image = cv2.copyMakeBorder( src, top, bottom, left, right, borderType)
where src is your source image and top, botto, left, right are paddings around the image.
You can use max(sizes) - size value of the image in a while loop to add the padding to each image. the bordertype can be one of these:
copyMakeBorder tutorial