# Write metadata from recovered images?



## squidman (Nov 23, 2018)

I managed to lose about 80 images from SDHC cards that I did not save in Lightroom Classic.   Using the Adobe script to recover images from previews I sucessfully recovered the lost images as jpegs. I would like to recover the metadata for each preview , specifically the location and GPS data, that are shown in the metadata column of the Library window. I welcome all and any suggestions. The “write to file” instruction does. Not work in my case since the preview data can not be refreshed since the originals are absent.  ThanksCLassic


----------



## Philippe Coudé du Foresto (Nov 24, 2018)

What do you mean by "I did not save In Lightroom Classic" ?  If by this this you mean "import in LR", they should still be referenced in the catalog with their metadata. You could then copy these info back to image recovered from the preview.
If they were not impirted in LR, you couldn't have a previexw of these images.


----------



## squidman (Nov 25, 2018)

Thank you  so much for your suggestion Phillipe.
Sadly, things are not so simple. The images were  erased  from the SDHC cards, but do still appear in my catalog as the second of two folders:labelled Internal SSD and Sony, the name of my data card. Under "Sony" there are 2 entries under the folder labelled SONY:100MSDCF and 101MSDCF. In the former are 62 images, in the latter: 18. Previews for all 62 deleted images are present under LIBRARY and the corresponding metadata are given in the usual Metadata section at the right of the previews display.  As I mentioned earlier, I successfully used the Adobe supplied script to generate JPEG images for all 62 Previews saved in a Desktop file. I used data recovery software in unsuccessful attempts to recover  the images from both my SSD and the SDHC card labelled "SONY" on my MacBook Air where the images were written originally. These images are important to me because they are of sundry things I observed on my trip to the Antartica Peninsula this past January and February. I was using a new Sony DSC-RX 10 M4 camera which has the equivalent of a max 600mm zoom! In additional to the GPS data for images taken with my iPhone X,  the Sony camera allowed me to connect to my iPhone and obtain the GPS data from it ,  which were written into the appropriate image metadata. Sorry to be so long winded, but as best as I can determine the orinal images no longer exist. I hope the attached screenshot gives a clear picture of the situation.  Bill


----------



## Philippe Coudé du Foresto (Nov 25, 2018)

I'm surprised that folders/images on the SD card are referenced in the catalog. When I import from memory card, my LR never allows me to reference the files on the card by using  ADD. Instead, I have to COPY the file somewhere on a HD where they are referenced in my catalog. Strange but this will be useful in your case.
The important consequence is that these lost images are still referenced in your catalog which therefore still contains all their metadata like GPS coordinates.
So, if I understand correctly, you have jpeg files of your images (created from the previews) and lost images referenced in the catalog but with no originals.
The only thing you have to do is make these recovered jpeg your new originals. 
The simplest way to this is, pictures by pictures, click on the "!", then click on "Find" in the dialog box to locate the corresponding recovered jpeg.  This will link the record in the catalog (which has all the metadata including the GPS coordinates) to the jpeg file.
Ok course, if you did some develop edit on your original raws, you will have to reset them. This is done in the develop module by clicking "Reset" in the bottom right.


----------



## Jim Wilde (Nov 25, 2018)

Philippe Coudé du Foresto said:


> I'm surprised that folders/images on the SD card are referenced in the catalog. When I import from memory card, my LR never allows me to reference the files on the card by using  ADD. Instead, I have to COPY the file somewhere on a HD where they are referenced in my catalog. Strange but this will be useful in your case.



We sometimes come across this situation, and it's usually caused by the user inadvertently having the same SD card folder specified as the *Destination *folder on the Import dialog. So basically LR reads from the SD card and writes back to the same card, that adds the card and folder to the catalog, then when the card is removed they are all "missing".

I always use the "Make second copy" option during import, which would give protection against loss of the originals.


----------



## squidman (Nov 25, 2018)

Philippe Coudé du Foresto said:


> I'm surprised that folders/images on the SD card are referenced in the catalog. When I import from memory card, my LR never allows me to reference the files on the card by using  ADD. Instead, I have to COPY the file somewhere on a HD where they are referenced in my catalog. Strange but this will be useful in your case.
> The important consequence is that these lost images are still referenced in your catalog which therefore still contains all their metadata like GPS coordinates.
> So, if I understand correctly, you have jpeg files of your images (created from the previews) and lost images referenced in the catalog but with no originals.
> The only thing you have to do is make these recovered jpeg your new originals.
> ...





Jim Wilde said:


> We sometimes come across this situation, and it's usually caused by the user inadvertently having the same SD card folder specified as the *Destination *folder on the Import dialog. So basically LR reads from the SD card and writes back to the same card, that adds the card and folder to the catalog, then when the card is removed they are all "missing".
> 
> I always use the "Make second copy" option during import, which would give protection against loss of the originals.





Jim Wilde said:


> We sometimes come across this situation, and it's usually caused by the user inadvertently having the same SD card folder specified as the *Destination *folder on the Import dialog. So basically LR reads from the SD card and writes back to the same card, that adds the card and folder to the catalog, then when the card is removed they are all "missing".
> 
> I always use the "Make second copy" option during import, which would give protection against loss of the originals.




Thanks Jim- I think that is exactly what happened because the the original preview names in the metadata column were all "name-2.xxx".  After recovering the images as jpegs I subsequently removed the "-2 f"rom the names of the recovered files.

Thanks Phillippe for your advice. I was thinking that the metadata had to be associated with the reviews but couldn't figure out how to reattach them to the images.  I will give your plan of attack a try when I have a chance and reply with the results . Bill


----------



## squidman (Nov 25, 2018)

Thank you so much for your suggestions Philippe and Jim- Bingo, all is well now. Bill


----------

