1. An apparatus comprising: a processor; and memory coupled to the processor, the memory comprising executable instructions that, when executed by the processor, cause the processor to effectuate operations comprising: generating a masked reference image by applying a mask to a reference image, the masked reference image comprising a plurality of pixels that represent a part of a scene, wherein the mask indicates which pixels of the reference image are likely to break an assumption of a compensation estimation process; generating an estimate of compensation for compensating a particular pixel value of pixels contained in the masked reference image by aggregating differences between the particular pixel value and values of pixels in a second image that correspond to pixels in the masked reference image with the particular pixel value, wherein a pixel in the reference image corresponds to a pixel in the second image when pixels represent the same part of the scene; and generating a compensated image portion of the reference image by adding the estimate to the value of pixels that are both in a compensation portion of the reference image and also have pixel values equal to the particular pixel value.