Corrupted Nikon D700 NEF files

Started by josephskaff, January 17, 2014, 01:42:49 PM

Previous topic - Next topic

josephskaff

Hi,

I found an applicaion that you did which fixes corrupted NEF images, but it worked for sveral Nikon cameras except the D700.
Is there a new updated application that would take images from that specific camera?
Thank you in advance for helping.

Phil Harvey

This is my first request for D700 support.  To add support for the D700 I will need a set of 12 test images comprised of the following 6 images a) copied directly from the camera's memory card, and b) corrupted by the Nikon software:

1) 12-bit compressed
2) 12-bit lossless compressed
3) 12-bit uncompressed
4) 14-bit compressed
5) 14-bit lossless compressed
6) 14-bit uncompressed

If you can provide these, mail them to philharvey66 at gmail.com.  If your mail can't handle the large files, then you can upload them to a file hosting service, and I will download them from there.

Note that this utility only fixes NEF files that were corrupted by Nikon software.  It does not fix NEF files corrupted due to memory card problems. (https://exiftool.org/fix_corrupted_nef.html)

- Phil
...where DIR is the name of a directory/folder containing the images.  On Mac/Linux/PowerShell, use single quotes (') instead of double quotes (") around arguments containing a dollar sign ($).

josephskaff

Great ! Thanks for that quick reply !
I noticed that my files were corrupted during transfer from the camera onto PC.
It is definitly not due to memory card.
I will upload whatever files I can as requested during the weekend.

Thank you again.

josephskaff

Hi Phil,

I just sent you files on Dropbox. Please let me know if and when you will access them cause I am not very sure if I did the right things.

Regards.

josephskaff

BTW,

The email address you mentionned did not work, so I guess it is rather owl.phy@queensu.ca instead of owl.phy.queensu.ca.

I hope to be right.

Phil Harvey

I can check the dropbox on monday when I'm back on a fast internet connection.

My mail is "philharvey66 at gmail.com" (change the " at " to "@" -- I do this to keep email-mining robots grabbing my address).

- Phil
...where DIR is the name of a directory/folder containing the images.  On Mac/Linux/PowerShell, use single quotes (') instead of double quotes (") around arguments containing a dollar sign ($).


Phil Harvey

Hi Joseph,

I got the files, thanks.

From the comments in your email it is apparent that this is a different problem than the one fix_corrupted_nef was designed for.  Your NEF image was corrupted by transfer with Windows 7 downloader, while fix_corrupted_nef fixes different problems created when NEF files are downloaded with older Nikon software.

The good news is that your corrupted NEF displays fine in Apple Preview, so it can't be too messed up.  I don't have Capture NX 2, so I can't test with this.

Looking at the file, there are a few tags that Windows has added.  I suggest using exiftool to remove these, then try loading again with Capture NX 2.  The command to remove the extra tags is:

exiftool -xmp:all= -offsetschema= FILE.NEF

Let me know how it goes.

- Phil

P.S. It is absolutely astounding to me that the Microsoft software modifies NEF images when downloading.  Their software has a really bad track record for corrupting metadata in JPEG images (where the metadata isn't crucial for the display of the image).  I can't believe that they would be stupid enough to try to modify a proprietary file like NEF (where the metadata is vital for proper display of the image).  What complete idiots.  I can't find the words to express to you how stupid they are to do this.  They should be held accountable for their incompetence/negligence.
...where DIR is the name of a directory/folder containing the images.  On Mac/Linux/PowerShell, use single quotes (') instead of double quotes (") around arguments containing a dollar sign ($).

josephskaff

Thank Phil, I will try your recepee :).

I totally agree with what you say about the Microsoft thing. I can't wait for the magical moment that I will cross the border and buy me a real Apple machine. Especially for working with images and photography. It's in my plans, have enough with Microsoft thing, always troubles opening files!!!!!!

Cheers

josephskaff

Hi again Phil,

Unfortunately, I did not understand the procedure.
Where and how can I execute the line that you are suggesting?
There must be something that I am missing. I tried to go through the instructions, but did not succeed.

Regards.

Phil Harvey

Hi Joseph,

There are a number of posts like this one which give basic instructions on how to run exiftool.

- Phil
...where DIR is the name of a directory/folder containing the images.  On Mac/Linux/PowerShell, use single quotes (') instead of double quotes (") around arguments containing a dollar sign ($).

josephskaff

Thanks Phil, I am actually following the instructions. I already installed PERL, and EXIF for windows. Trying to make it work now. think that it will be OK.

Joseph

josephskaff

So hi again PHIL,

I followed your instructions.
After many unsuccessful attempts, I noticed that I had to add the .pl extension to "exiftool" in your command syntax:  exiftool.pl -xmp:all= -offsetschema= FILE.NEF, to make it work.
So I executed this commad line, followed by the path to my corrupted image, and I obtained a message saying that the file was updated.
I tryed to open the updated image with CNX2, but it still doesn't open.

I guess that Exif operates directly on the image itself and does not store a new copy anywhere else.

So this is the state of the situation.

Regards.

Phil Harvey

Hi Joseph,

Oh, you're using the Perl version.  This is the hard way to go.  My instructions were for the stand-alone Windows .exe version.  It is more complicated to install the Perl version, but you have it working now, so good.

When you run the command, ExifTool will save the original file name by adding "_original" to the name.  You should see this file beside the modified image.  For example, if you modify a file called "example.cr2", the original will be preserved as "example.cr2_original" in the same directory.  If you get the updated message but don't see the "_original" file, then you are looking in the wrong place.

But if you do see the "_original" file, and the modified image still doesn't open with CNX2, then I guess we are out of luck. :(

- Phil
...where DIR is the name of a directory/folder containing the images.  On Mac/Linux/PowerShell, use single quotes (') instead of double quotes (") around arguments containing a dollar sign ($).

josephskaff

Hi Phil,

I checked and I have the two files with one indexed _original. So I was opening the right file, and yes, we are out of luck :) and/or :(.
Fortunately that I always shoot in RAW + JPEG high (fine).
I learned my lesson now, thanks to you: always download using Nikon View NX 2 in my case, and never trust third party downloader, especialy Windows !

I will contact Nikon people and see if there still be anything to salage those NEF files.

BTW: you mentioned that you could open the file on Apple, but I think what you see is the JPG preview, cause here also I can open the file in JPEG viewer, inside Nikon Capture NX2, but the time I click on RAW, the file shows with those pinky lines.

Cheers !

I will let you know if any positive outcome with Nikon people.