diff --git a/images/.DS_Store b/images/.DS_Store deleted file mode 100644 index ec6b1b4665541d893fedc2b6446d96a9e17bd793..0000000000000000000000000000000000000000 Binary files a/images/.DS_Store and /dev/null differ diff --git a/images/img_5.jpg b/images/img_5.jpg deleted file mode 100755 index 63808bd80095c6199b8d923f63150f3a3463d599..0000000000000000000000000000000000000000 Binary files a/images/img_5.jpg and /dev/null differ diff --git a/images/img_6.jpg b/images/img_6.jpg deleted file mode 100755 index c23c15e16067e45722f4c04bc245693e7dd7542b..0000000000000000000000000000000000000000 Binary files a/images/img_6.jpg and /dev/null differ diff --git a/src/.DS_Store b/src/.DS_Store deleted file mode 100644 index 2db64a934c0a822e722e06c687b67433760180a2..0000000000000000000000000000000000000000 Binary files a/src/.DS_Store and /dev/null differ diff --git a/src/methods/.DS_Store b/src/methods/.DS_Store deleted file mode 100644 index f627673be4596f7376d005fb081b76950c670f41..0000000000000000000000000000000000000000 Binary files a/src/methods/.DS_Store and /dev/null differ diff --git a/src/methods/template/reconstruct.py b/src/methods/template/reconstruct.py new file mode 100644 index 0000000000000000000000000000000000000000..a97bd3f6e3c68df763b36c46b2727461af078bd2 --- /dev/null +++ b/src/methods/template/reconstruct.py @@ -0,0 +1,53 @@ +"""The main file for the reconstruction. +This file should NOT be modified except the body of the 'run_reconstruction' function. +Students can call their functions (declared in others files of src/methods/your_name). +""" + + +import numpy as np + +from src.forward_model import CFA + + +def run_reconstruction(y: np.ndarray, cfa: str) -> np.ndarray: + """Performs demosaicking on y. + + Args: + y (np.ndarray): Mosaicked image to be reconstructed. + cfa (str): Name of the CFA. Can be bayer or quad_bayer. + + Returns: + np.ndarray: Demosaicked image. + """ + # Performing the reconstruction. + # TODO + input_shape = (y.shape[0], y.shape[1], 3) + op = CFA(cfa, input_shape) + + return np.zeros(op.input_shape) + + +#### +#### +#### + +#### #### #### ############# +#### ###### #### ################## +#### ######## #### #################### +#### ########## #### #### ######## +#### ############ #### #### #### +#### #### ######## #### #### #### +#### #### ######## #### #### #### +#### #### ######## #### #### #### +#### #### ## ###### #### #### ###### +#### #### #### ## #### #### ############ +#### #### ###### #### #### ########## +#### #### ########## #### #### ######## +#### #### ######## #### #### +#### #### ############ #### +#### #### ########## #### +#### #### ######## #### +#### #### ###### #### + +# 2023 +# Authors: Mauro Dalla Mura and Matthieu Muller