Bong hits 4 Jesus!

Cleaning Up Noise in Long-Exposure Photographs

Fig. 1 The photo has a purplish cast overall, and is speckled with dots (see detail).
The photo in Fig. 1 is a picture that I took at night, with a 10-minute exposure, to capture the stars wheeling around Polaris. Unfortunately, it was covered with speckles. I knew they couldn't be stars, since stars would have streaked like the ones visible in the inset.

At first I thought this was random noise of some kind; perhaps cosmic rays, perhaps thermal noise, or something that causes a pixel to become "on" randomly. But as I looked at other long-exposure photos I took that night, I found that the noise was the same in every picture. So I began to suspect the camera.

(At this point, I didn't think anything of the purple color. I thought it was some weird effect of the moonlight or of the long exposure time, or something.)

Fig. 2 A photo taken with a 10-minute exposure with the lens cap on also shows a purple haze, and the same pattern of dots (see detail).
To test the hypothesis that the noise came from the camera, I took a few long-exposure pictures with the lens cap on (see Fig. 2). Not only did I find a consistent pattern of speckles at exposure times above 3 minutes, I also found where the purple haze came from (no, not Jimi Hendrix).

Fig. 3 Subtracting Fig. 2 from Fig. 1 cleans the image up considerably.
Since the noise came from the camera in a fairly consistent pattern, and since I had a picture of this noise, it should be possible to know what to remove from the original photo.

I edited the original photo (Fig. 1) with the Gimp, and added the "noise" photo (Fig. 2) as a second layer, using "Difference" mode in the "Layers, Channels & Paths" dialog box ("Subtract" also seems to work, in this case).

The result is in Fig. 3. As you can see in the detail view, the speckles are almost gone, as is the purple haze.

You may notice "haloes" around the remaining speckles. I'm not sure, but these might be compression artifacts: the original photo is a JPEG file, whereas the "noise" image is a full-size TIFF image. Since JPEG uses lossy compression, the haloes may have been introduced when the image was compressed.

The colors still seem a bit wrong, but it's hard to tell how, exactly.