1

I have transferred photos from my camera SD card to my computer (using a card/ram reader) and deleted the original photos. Now I have just realized there are color bars overlaid in photos. Here is an example:

enter image description here

You can download the original image (which includes metadata) here. Note that the colorbars are not present in the thumbnail!:

https://drive.google.com/file/d/0B0xoao6g6xzoLUxkcnpuTkNjMkk/view?usp=sharing

The blame seems to be on the transfer. Do you agree? Why transferring a photo can potentially corrupt it? I haven't seen this problem with other file types.

As I don't have the original photos, there any way to fix/reduce this corruption?

  • Just because the corruption is not evident in the thumbnail image does not mean the entire file was not already corrupt when written to the card in the camera. – Michael C Feb 7 '16 at 15:05
  • @MichaelClark: Yeah. Does that mean the camera itself generated the thumbnail and embedded it into jpeg file? My PC couldn't have done it since the uncorrupted image is not available. – Isaac Feb 7 '16 at 15:22
  • Yes, cameras usually generate a thumbnail preview and embed it into the file before loading it in the buffer to be written to the memory card. – Michael C Feb 7 '16 at 16:13
6

Short Answer : you may be lucky !

As you supposed, it seems that you have indeed experienced some corruption(s) during the transfer. Technically speaking, a JPG is made of tiny blocks of pixels called "MCU block" (Minimum Coded Unit). In the case of your image, the MCU has the size of 16*8 pixels (regular sizes are 8*8, 8*16 and 16*8). As one can see in your image, corruption appears indeed as blocks.

zoom on the first corrupted block

Generally, if a block gets corrupted during the transfer, all the following blocks are "corrupted". If you are lucky, the information is still there on your hard drive, but misaligned somehow. So when an image viewer try to read your image, it shows weird colors and misaligned lignes (basically, if your image viewer displays something, you can probably recover the displayed part of your image... but probably not the whole image).

If only such a corruption occurs, you can try to correct it manually. You will lose the data from the corrupted blocks but might be able to recover the others.

WARNING : as most "repair" procedures will alter your image, make a copy of it before trying to repair it.

I managed to recover this image using a free tool called "JPEG Repair Shop" (JRS) from Anders Pedersen (http://anderspedersen.net/jpegrepair) :

Repaired image (blocks are still corrupted)

Basically, all you have to do is load an image, find the first corrupted block and click on "Fix Colors". Sometimes, the "Fix Colors" options will still give strange colors. In this case, you can also add/remove MCU blocks and then try to fix the colors again.

You can see that almost all the image is now OK. Some blocks are still corrupted. You can see them in red in the following image :

Repaired image (corrupted blocks in red)

Finally, using Photoshop and the clone stamp or the content-aware filling tools, you can obtain this :

Repaired image

Some other tools may be able to get better result, maybe you can use PhotoShop to do everything, but I don't know how.

  • Wow thanks! What approach did you take to correct the image? There are more corrupted photos that need to be fixed. – Isaac Feb 7 '16 at 12:49
  • 1
    I added more details, I hope you will ba able to save your images :) – Olivier Feb 7 '16 at 13:10
  • 3
    Handy tool - also worth pointing out that throwing some recovery software at the SD card might be able to recover the files too. – James Snell Feb 7 '16 at 13:31
  • @JamesSnell: Good point! – Isaac Feb 7 '16 at 13:32

Not the answer you're looking for? Browse other questions tagged or ask your own question.