ExifTool Forum

General => Metadata => Topic started by: itsjustvenky on October 10, 2016, 01:21:46 PM

Title: Custom metadata is ignored by ExifTool
Post by: itsjustvenky on October 10, 2016, 01:21:46 PM
Hi,

I am trying to extract xmp packet from this attached file, but for some reason, some of the custom metadata is missing from output xmp file. I could able to export the correct xmp packet using photoshop but not using exiftool.

Command :exiftool -tagsfromfile test.jpg -all output.xmp
Exiftool Version : 10.25

I am enclosing original image, xmp packet extracted using photoshop and exiftool

Please let know what might be the issue.

I couldn't attach the original file which was 2.8MB. So I am attaching the other one which has similar issue.


Thanks you very much
Venkatesh

Title: Re: Custom metadata is ignored by ExifTool
Post by: Phil Harvey on October 10, 2016, 01:23:50 PM
Yes.  You are copying the tags individually, and ExifTool can only write the ones which have been pre-defined.  I think you should probably be copying the XMP as a block instead:

exiftool -xmp -b test.jpg > output.xmp

or

exiftool -tagsfromfile test.jpg -xmp output.xmp

See examples 6 and 7 here (https://exiftool.org/metafiles.html#xmp) for more information.

- Phil
Title: Re: Custom metadata is ignored by ExifTool
Post by: itsjustvenky on October 10, 2016, 01:28:55 PM
Hi Phil

Thank for you reply. I tried your command and it didn't work. Can you please look at the attached source image file.

Thanks
Venkatesh
Title: Re: Custom metadata is ignored by ExifTool
Post by: StarGeek on October 10, 2016, 05:18:29 PM
What exactly didn't work?  Was there an error message?  If  certain tags weren't in the output.xmp file, which tags were they?

I downloaded your tiff file, extracted the xmp as per Phil's command, then ran exiftool over both the tiff and the xmp file and the xmp results were the same.
Title: Re: Custom metadata is ignored by ExifTool
Post by: itsjustvenky on October 12, 2016, 01:57:09 AM
Hey StarGeek,

I am attaching the image file was well xmp packet extracted using photoshop as well as exiftool. If you open photoshop xmp packet then you can see, this part of metadata is missing from exiftool extracted xmp

<rdf:Description rdf:about=""
            xmlns:xwnv="http://ns.xinet.com/ns/xinetschema#">
         <xwnv:UPC_SVU>64318050000</xwnv:UPC_SVU>
         <xwnv:GTIN>00643180500009</xwnv:GTIN>
         <xwnv:MANUFACTURER>Divaderme Cosmetics</xwnv:MANUFACTURER>
         <xwnv:BRAND_NAME>Divaderme Cosmetics</xwnv:BRAND_NAME>
         <xwnv:DESCRIPTION>Mascara; Natural Fiber; Black Fiber</xwnv:DESCRIPTION>
         <xwnv:SIZE>1</xwnv:SIZE>
         <xwnv:UOM>ea</xwnv:UOM>
         <xwnv:Keywords>64318050000; Divaderme Cosmetics; Mascara; Natural Fiber; Black Fiber; 1 ea</xwnv:Keywords>
         <xwnv:Import_Source>TWIST 2_Process_New_Imagery Wed Oct 05 01:50:00 CST 2016</xwnv:Import_Source>
         <xwnv:Asset_Type>Photographic Image</xwnv:Asset_Type>
         <xwnv:GA_Asset_Type>Product Image</xwnv:GA_Asset_Type>
         <xwnv:ASSET_SOURCE>Gladson</xwnv:ASSET_SOURCE>
         <xwnv:DEPARTMENT>GM HBC</xwnv:DEPARTMENT>
         <xwnv:PRODUCT_CATEGORY>Cosmetic</xwnv:PRODUCT_CATEGORY>
      </rdf:Description>

I couldn't upload file directly to this forum and hence I am enclosing outside link

https://www.filesupload.org/ee7cf6a3985dd1d0b3b7dd402705e66f/Examples.zip

please let me know

Thanks
Venkatesh
Title: Re: Custom metadata is ignored by ExifTool
Post by: itsjustvenky on October 12, 2016, 01:57:48 AM
I have tried
exiftool -tagsfromfile source.jpg output.xmp
exiftool -tagsfromfile source.jpg -xmp output.xmp
Title: Re: Custom metadata is ignored by ExifTool
Post by: StarGeek on October 12, 2016, 03:11:12 AM
I'm not sure why your output doesn't have it. 

I use this command:
exiftool -tagsfromfile X:\!temp\z\Examples\00643180500009.tif -xmp X:\!temp\z\Examples\output.xmp

And when I open up output.xmp in Notepad++, I see this:
  <rdf:Description rdf:about=""
    xmlns:xmp="http://ns.adobe.com/xap/1.0/"
    xmlns:dc="http://purl.org/dc/elements/1.1/"
    xmlns:xmpMM="http://ns.adobe.com/xap/1.0/mm/"
    xmlns:stRef="http://ns.adobe.com/xap/1.0/sType/ResourceRef#"
    xmlns:stEvt="http://ns.adobe.com/xap/1.0/sType/ResourceEvent#"
    xmlns:xmpRights="http://ns.adobe.com/xap/1.0/rights/"
    xmlns:xwnv="http://ns.xinet.com/ns/xinetschema#"
   xmp:CreateDate="2016-10-04T13:43:34-05:00"
   xmp:ModifyDate="2016-10-05T15:22:52-05:00"
   xmp:MetadataDate="2016-10-05T17:33:53-05:00"
   xmp:CreatorTool="Adobe Photoshop CC 2014 (Macintosh)"
   dc:format="image/tiff"
   xmpMM:InstanceID="xmp.iid:1df5cf05-5df3-490a-a51f-203b8b07ec4c"
   xmpMM:DocumentID="adobe:docid:photoshop:4bf16667-cbbf-1179-b843-aa036d9503c7"
   xmpMM:OriginalDocumentID="uuid:1432AE73628AE6119922A9B695C0707D"
   xmpRights:Marked="False"
   xwnv:UPC_SVU="64318050000"
   xwnv:GTIN="00643180500009"
   xwnv:MANUFACTURER="Divaderme Cosmetics"
   xwnv:BRAND_NAME="Divaderme Cosmetics"
   xwnv:DESCRIPTION="Mascara; Natural Fiber; Black Fiber"
   xwnv:SIZE="1"
   xwnv:UOM="ea"
   xwnv:Keywords="64318050000; Divaderme Cosmetics; Mascara; Natural Fiber; Black Fiber; 1 ea"
   xwnv:Import_Source="TWIST 2_Process_New_Imagery Wed Oct 05 01:50:00 CST 2016"
   xwnv:Asset_Type="Photographic Image"
   xwnv:GA_Asset_Type="Product Image"
   xwnv:ASSET_SOURCE="Gladson"
   xwnv:DEPARTMENT="GM HBC"
   xwnv:PRODUCT_CATEGORY="Cosmetic">

Which includes the data you're missing.  Different formatting than the Photoshop output, but (I'm assuming) legit (I know little about XML).  Also, open up the tiff and it's exactly the same as in the tiff.

Your output from exiftool file doesn't appear to use the commands suggested by Phil.  It appears to be output from your first command (-all).  Additionally, it appears to be the output of Exiftool ver 8.5, not 10.25.  You may have an older version of exiftool in your path someplace.

Try using either of the commands from Phil's post and search around to see if you have an older version of exiftool.  Type exiftool -ver to see what version is actually being run.  If you're on Windows, you can type Where Exiftool to check where they might be.
Title: Re: Custom metadata is ignored by ExifTool
Post by: itsjustvenky on October 12, 2016, 10:29:26 AM
@StarGeek... thank you very much for the info. Yeah the "-xmp" option with 10.x version was able to extract missing metadata from image file. This is working fine on windows as well as Linux.