Image reconstruction using low-light components
Let's say we have a regular photo and three low-light photos illuminated in different colors. Each pixel is a three-component vector $q=(R,G,B)$. Then $q_k^{A}$ is the $k$-th pixel of the regular photo and $q_k^{B}$ $q_k^{C}$ $q_k^{D}$ be the $k$-th pixel of the three low-light versions.
The task is to reconstruct the regular photo from the three low-light photos where:
$q_k^{A} = F^{A}q_k^{B} + F^{C}q_k^{C} + F^{D}q_k^{D} + q_{const}$. Clearly, $F^A, F^{B}, F^{C}$ are $3 \times 3$ matrices and $q_{const}$ is a vector.
The task is to perform least-squares fit for the 30 components (three matrices and the vector). Specifically, we should minimize:
$S = \frac{1}{MN}\sum\limits_{k=0}^{MN-1}{||-q_k^{A} + F^{A}q_k^{B} + F^{C}q_k^{C} + F^{D}q_k^{D} + q_{const}||^2}$
What is the proper way to approach this problem? I have implemented linear regression of different types before, but in this case I am not sure how to proceed.
Topic objective-function computer-vision regression
Category Data Science