1. An image processor for processing an input image to an output image, comprising: (a) an image input device for reading an input image, wherein said input image has a color filter array (CFA) mosaic structure; (b) a storage device for containing a set of learned regression coefficients for a predefined estimation function for estimating output colorbands at image pixels, wherein each of said set of said learned regression coefficients is defined for a collection of nearby pixels for each of said image pixels; and (c) a pixel processing module for processing each of the pixels of said input image, wherein said pixel processor: (i) obtains said collection of nearby pixels for each of said pixels in said input image, (ii) selects learned regression coefficients from said stored learned regression coefficients based on the position of said pixel in said color filter array mosaic structure and a calculation using said collection of nearby pixels in said input image, and (iii) applies said learned regression coefficients and said predefined estimation function to said pixels in said input image, thereby processing said input image to an output image, wherein said output image contains for each pixel values for a specified number of colorbands, which are different or the same in number or spectral sensitivity from said colorbands of said input image.