diff --git a/src/checks.py b/src/checks.py index 1201813380aaeb95759a31418e9d82d067341b84..4201a01b1f38af4aa0916048b028d48ee7b296e1 100644 --- a/src/checks.py +++ b/src/checks.py @@ -71,20 +71,6 @@ def check_data_range(img: np.ndarray) -> None: raise Exception(f'Pixel\'s values must be in range [0, 1]. Got range [{np.min(img)}, {np.max(img)}].') -def check_len(img1_list: list | np.ndarray, img2_list: list | np.ndarray) -> None: - """Checks if two lists have the same length. - - Args: - img1_list (list | np.ndarray): First list. - img2_list (list | np.ndarray): Secind list. - - Raises: - Exception: Exception if the two list do not have the same length. - """ - if len(img1_list) != len(img2_list): - raise Exception(f'The two lists must have the same length. Got {len(img1_list)} and {len(img2_list)}.') - - def check_cfa(cfa: str) -> None: """Checks if the CFA's name is correct. diff --git a/src/utils.py b/src/utils.py index 7a5340f25852726d240a7b261d4b48ca17419c64..e7213270b860c2aed3d61361e1aa637f6d620d7e 100755 --- a/src/utils.py +++ b/src/utils.py @@ -7,7 +7,7 @@ from skimage.metrics import peak_signal_noise_ratio, structural_similarity from skimage.io import imread, imsave import numpy as np -from src.checks import check_len, check_data_range, check_rgb, check_shape, check_path, check_png +from src.checks import check_data_range, check_rgb, check_shape, check_path, check_png def normalise_image(img: np.ndarray) -> np.ndarray: