This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import cv2 as cv | |
import numpy as np | |
def build_gauss_pyr(img, n_layers): | |
pyr = [img] | |
for _ in range(n_layers): | |
pyr.append(cv.pyrDown(pyr[-1])) | |
return pyr | |
def build_lap_pyr(gauss_pyr): |