Hi there,
I need to write a list of metadata tags that I've gathered from a custom raw format photo so that they can be read by Pix4d. The tags I need to write are in the links below, some are "Standard" but I believe some might need to be overwritten in order to work.
Standard tags = https://support.pix4d.com/hc/en-us/articles/205732299#gsc.tab=0
XMP specification = https://support.pix4d.com/hc/en-us/articles/206434245#gsc.tab=0
Thanks for any help you can offer.
Oh and here is the config file I've tried to use with no luck
%Image::ExifTool::UserDefined = {
'Image::ExifTool::XMP::Main' => {
Camera => {
SubDirectory => {
TagTable => 'Image::ExifTool::UserDefined::Camera',
},
},
},
'Image::ExifTool::EXIF::Main' => {
GPSInfo => {
SubDirectory => {
TagTable => 'Image::ExifTool::UserDefined::GPSInfo',
},
},
Photo => {
SubDirectory => {
TagTable => 'Image::ExifTool::UserDefined::Photo',
},
},
},
};
%Image::ExifTool::UserDefined::Camera = {
GROUPS => { 0 => 'XMP', 1 => 'XMP-Camera', 2 => 'Camera' },
NAMESPACE => { 'Camera' => 'http://pix4d.com/camera/1.0/' },
WRITABLE => 'string',
Yaw => { Writable => 'rational', Groups => { 2 => Camera}},
Pitch => { Writable => 'rational', Groups => { 2 => Camera}},
Roll => { Writable => 'rational', Groups => { 2 => Camera}},
CentralWaveLength => { Writable => 'string', Groups => { 2 => Camera}},
BandName => { Writable => 'string', Groups => { 2 => Camera}},
RigName => { Writable => 'string', Groups => { 2 => Camera}},
RigCameraIndex => { Writable => 'string', Groups => { 2 => Camera}},
};
%Image::ExifTool::UserDefined::GPSInfo = {
GROUPS => { 0 => 'EXIF', 1 => 'EXIF-GPSInfo', 2 => 'GPSInfo' },
NAMESPACE => { 'GPSInfo' => 'http://pix4d.com/GPSInfo/1.0/' },
WRITABLE => 'string',
GPSLatitude => { Struct => { Hi => { Writable => 'rational'}, Lo => {Writable => 'rational'}}, Groups => { 2 => GPSInfo}},
GPSLongitudep => { Struct => { Hi => { Writable => 'rational'}, Lo => {Writable => 'rational'}}, Groups => { 2 => GPSInfo}},
GPSTimeStamp => { Struct => { Hour => { Writable => 'rational'}, Minute => {Writable => 'rational'}, Second => {Writable => 'rational'}}, Groups => { 2 => GPSInfo}},
GPSAltitude => { Writable => 'rational', Groups => { 2 => GPSInfo}},
GPSAltituderef => { Writable => 'short', Groups => { 2 => GPSInfo}},
GPSTimeStampS => { Writable => 'rational', Groups => { 2 => GPSInfo}},
GPSLatitudeRef => { Writable => 'string', Groups => { 2 => GPSInfo}},
GPSLongitudeRef => { Writable => 'string', Groups => { 2 => GPSInfo}},
GPSLeapSeconds => { Writable => 'short', Groups => { 2 => GPSInfo}},
GPSTimeFormat => { Writable => 'short', Groups => { 2 => GPSInfo}},
GPSFixStatus => { Writable => 'short', Groups => { 2 => GPSInfo}},
};
%Image::ExifTool::UserDefined::Photo = {
GROUPS => { 0 => 'EXIF', 1 => 'EXIF-Photo', 2 => 'Photo' },
NAMESPACE => { 'Photo' => 'http://pix4d.com/Photo/1.0/' },
WRITABLE => 'string',
DateTimeOriginal => { Writable => 'string', Groups => { 2 => Photo}},
SubSecTimeOriginal => { Writable => 'short', Groups => { 2 => Photo}},
ExposureTime => { Writable => 'rational', Groups => { 2 => Photo}},
ExposureMode => { Writable => 'boolean', Groups => { 2 => Photo}},
ISOSpeedRatings => { Writable => 'short', Groups => { 2 => Photo}},
LensModel => { Writable => 'string', Groups => { 2 => Photo}},
};
Hi Ethan,
These EXIF tags are standard EXIF and as such they don't require user-defined tags. To write these in ExifTool, all you need to do is determine the correct tag name. See the EXIF Tags documentation (https://exiftool.org/TagNames/EXIF.html) for a complete list.
The XMP.Camera tags look to be Pix4d-specific, and as far as I can tell you are defining these correctly (but you can drop the "Groups => { 2 => Camera}" because this is already the default as specified by the GROUPS entry in your table).
- Phil
Hi Phil,
I've had some luck finding the standard tags, but I have found a warning
QuoteWarning: Can't convert ExifIFD:ExposureMode (not in PrintConv)
I am passing it a value of 1 through a subprocess call, but that call can only pass things as string objects from what I can determine, I don't know why it works for all the values except Exposure Mode
Take a look at the EXIF tag page (https://exiftool.org/TagNames/EXIF.html) for the values of ExposureMode. The value of 1 would normally be set as "Manual".
To set the raw value, you can add a hashtag to the end of the tag name:
exiftool -ExposureMode#=1 FileOrDir
Thanks Stargeek.
So, I got all the tags to play nice, except for now the Yaw, Pitch, and Roll are no longer being read by Pix4d. The xmp specification says they need to be in XMP.Camera and that they are rational numbers.
Has anyone gotten these tags to work?
Regards,
The specification you gave is not sufficient to know how these tags should be written. I need either an example XMP containing these tags, or the property name, namespace prefix and namespace URI for the tags. XMP.Camera is their local way of addressing the tags, and is not helpful. If you can use Pix4d to write these tags then you can see how they should be written.
- Phil
Quote from: Phil Harvey on December 05, 2017, 07:06:52 AM
The specification you gave is not sufficient to know how these tags should be written. I need either an example XMP containing these tags, or the property name, namespace prefix and namespace URI for the tags. XMP.Camera is their local way of addressing the tags, and is not helpful. If you can use Pix4d to write these tags then you can see how they should be written.
- Phil
Hi Phil
I found an image that has the data I need.
Below is the data:
[ExifTool] ExifTool Version Number : 10.63
[System] File Name : IMG_160729_071428_0014_RGB.JPG
[System] Directory : D:/Exifphotos
[System] File Size : 2.5 MB
[System] File Modification Date/Time : 2017:12:07 18:59:50-08:00
[System] File Access Date/Time : 2017:12:07 15:34:50-08:00
[System] File Creation Date/Time : 2017:12:07 15:34:50-08:00
[System] File Permissions : rw-rw-rw-
[File] File Type : JPEG
[File] File Type Extension : jpg
[File] MIME Type : image/jpeg
[File] Exif Byte Order : Big-endian (Motorola, MM)
[File] Image Width : 4608
[File] Image Height : 3456
[File] Encoding Process : Baseline DCT, Huffman coding
[File] Bits Per Sample : 8
[File] Color Components : 3
[File] Y Cb Cr Sub Sampling : YCbCr4:2:0 (2 2)
[IFD0] Compression : JPEG
[IFD0] Photometric Interpretation : YCbCr
[IFD0] Make : Parrot
[IFD0] Camera Model Name : Sequoia
[IFD0] Orientation : Horizontal (normal)
[IFD0] X Resolution : 72
[IFD0] Y Resolution : 72
[IFD0] Resolution Unit : inches
[IFD0] Software : v1.1.0-rc1
[IFD0] Modify Date : 2016:07:29 07:14:28
[IFD0] Y Cb Cr Positioning : Centered
[IFD0] Image Number : 14
[IFD0] Camera Serial Number : PI040378AA6C000267
[IFD0] Original Raw File Name : IMG_160729_071428_0014_RGB.JPG
[ExifIFD] Exposure Time : 1/830
[ExifIFD] F Number : 2.3
[ExifIFD] ISO : 100
[ExifIFD] Exif Version : 0210
[ExifIFD] Date/Time Original : 2016:07:29 07:14:28
[ExifIFD] Create Date : 1970:01:01 00:03:49
[ExifIFD] Components Configuration : Y, Cb, Cr, -
[ExifIFD] Shutter Speed Value : 1/830
[ExifIFD] Aperture Value : 2.3
[ExifIFD] Max Aperture Value : 2.3
[ExifIFD] Focal Length : 4.9 mm
[ExifIFD] Image Number : 14
[ExifIFD] Sub Sec Time : 028981
[ExifIFD] Sub Sec Time Original : 028981
[ExifIFD] Sub Sec Time Digitized : 540535
[ExifIFD] Flashpix Version : 0100
[ExifIFD] Color Space : Uncalibrated
[ExifIFD] Exif Image Width : 4608
[ExifIFD] Exif Image Height : 3456
[ExifIFD] Focal Plane X Resolution : 746.2686793
[ExifIFD] Focal Plane Y Resolution : 746.2686793
[ExifIFD] Focal Plane Resolution Unit : mm
[ExifIFD] Exposure Mode : Auto
[ExifIFD] White Balance : Auto
[ExifIFD] Focal Length In 35mm Format : 28 mm
[ExifIFD] Image Unique ID : 76A06F4F3479E4D0651BFC196405B495
[ExifIFD] Serial Number : PI040378AA6C000267
[GPS] GPS Version ID : 2.2.0.0
[GPS] GPS Latitude Ref : North
[GPS] GPS Latitude : 46 deg 31' 24.15"
[GPS] GPS Longitude Ref : East
[GPS] GPS Longitude : 6 deg 33' 4.95"
[GPS] GPS Altitude Ref : Above Sea Level
[GPS] GPS Altitude : 505.0581808 m
[GPS] GPS Time Stamp : 07:14:26.802
[GPS] GPS Status : Measurement Active
[GPS] GPS Speed Ref : km/h
[GPS] GPS Speed : 40.25337621
[GPS] GPS Map Datum : WGS-84
[GPS] GPS Date Stamp : 2016:07:29
[XMP-Camera] Rig Name : Sequoia
[XMP-Camera] Yaw : -69.915070
[XMP-Camera] Pitch : 5.747519
[XMP-Camera] Roll : -6.973208
[XMP-Camera] IMU Sample Size : 185
[XMP-Camera] IMU Time Offset : 10623074
[XMP-Camera] Line Readout Time : 47500
[XMP-Camera] IMU Frequency : 1000
[XMP-Camera] Principal Point : 3.005977,2.245134
[XMP-Camera] Model Type : perspective
[XMP-Camera] Perspective Focal Length : 4.507643
[XMP-Camera] Perspective Distortion : 0.209457683,-0.354049203,0.265381076,-0.004126354,-0.001986669
[XMP-Camera] IMU Linear Velocity : -2.212102,-10.960538,1.196878
[XMP-Camera] GPSXY Accuracy : 3.015103
[XMP-Camera] GPSZ Accuracy : 4.127000
[XMP-Camera] Flight UUID : 26D9D225ABC80F206709E65F2ABCEAFD
[XMP-Camera] Band Name : Red, Green, Blue
[XMP-Camera] IMU Angular Velocity : .nYCrDQAAAAC9kcw8s546vXItxDwBAAAAhYSrDQAAAADm6l291594vXhB/DsBAAAAbYirDQAAAADm6l29CzJ0vQC68TgBAAAAVYyrDQAAAADWO488FiykvWzOlzwBAAAAPZCrDQAAAACp0Ns9xvIYvnItxDwBAAAAJZSrDQAAAAAvuDA+Bb1UvsjDkTsBAAAADZirDQAAAADtMR8+SSFEvgBDtTsBAAAA9ZurDQAAAACYAII9iYjbvZBfMzwBAAAA3Z+rDQAAAAD7I8a774PnvAReejwBAAAAxaOrDQAAAACwZbs7vt78uyCJXDsBAAAA3KerDQAAAADbbH89NRnEvEjd0bsBAAAAxKurDQAAAAB3wwM+937Zu+BtDLwBAAAArK+rDQAAAADvSSw+RvwcPCB1mjoBAAAAlLOrDQAAAABUMRQ+lgpXvAjjzDwBAAAAfLerDQAAAAAJhWk9ujI2vcDKRDwBAAAAZLurDQAAAABUfDu83jN0vRBerrsBAAAATL+rDQAAAAAYVCE7Ug4/vRBerrsBAAAANMOrDQAAAADywqI9tVdMvZjkhTwBAAAAHMerDQAAAABqbiI+ba7xvfhJaDwBAAAABMurDQAAAAAx0D0+4uFLvkjd0bsBA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quatDQAAAADm7CY+hjqZvXLot70BAAAAkuqtDQAAAACE2MM9I3P4vRQRm70BAAAAeu6tDQAAAAC2+Gk9+Z4pvk6Qvr0BAAAAYvKtDQAAAAA2/dA9OCgvvgLgy70BAAAASvatDQAAAAAQZ0M+GEMRvpLX370BAAAAMvqtDQAAAADaM4Q+llUcvnLot70BAAAAGv6tDQAAAACop4M+fM1UvnLot70BAAAAAgKuDQAAAAB0f0Q+ZyB3vrgv2b0BAAAA6gWuDQAAAADGXtU9kLtovmYgur0BAAAA0gmuDQAAAAAG1Fw9Z99Avhxwx70BAAAAug2uDQAAAACy8K09Hl8xvnLot70BAAAAohGuDQAAAAC5oyM+drE0vhCoyb0BAAAAihWuDQAAAAAPmFw+MgwPviLP870BAAAAlRmuDQAAAABiJG4+pSSivSjY370BAAAAfR2uDQAAAABveU8+0o82vawH9r0BAAAAZSGuDQAAAAC1bBU++FqFvbJwx70BAAAATSWuDQAAAAAYIY09RzjrvZKBn70BAAAANSmuDQAAAABaqhM8M68fvowYzr0BAAAAHS2uDQAAAAA2fjU9/hwkvijY370BAAAABTGuDQAAAABFzhk+YQHpvQSA5r0BAAAA7TSuDQAAAACa82s+lZPkveSQvr0BAAAA1TiuDQAAAACa82s+1IEyvsoAw70BAAAAvTyuDQAAAABmkSI+2p1SvqA/+L0BAAAApUCuDQAAAADookI9XItHvqaoyb0BAAAAjUSuDQAAAADpdYi870owvgjpt70BAAAAdUiuDQAAAAA9B9Y8R50zvvwgur0BAAAAXUyuDQAAAAC6Uus9z6ZIvkJo270BAAAARVCuDQAAAADf5jE+OIoJvrGrAb4BAAAA.
[Composite] Aperture : 2.3
[Composite] GPS Altitude : 505 m Above Sea Level
[Composite] GPS Date/Time : 2016:07:29 07:14:26.80199981Z
[Composite] GPS Latitude : 46 deg 31' 24.15" N
[Composite] GPS Longitude : 6 deg 33' 4.95" E
[Composite] GPS Position : 46 deg 31' 24.15" N, 6 deg 33' 4.95" E
[Composite] Image Size : 4608x3456
[Composite] Megapixels : 15.9
[Composite] Scale Factor To 35 mm Equivalent: 5.7
[Composite] Shutter Speed : 1/830
[Composite] Create Date : 1970:01:01 00:03:49.540535
[Composite] Date/Time Original : 2016:07:29 07:14:28.028981
[Composite] Modify Date : 2016:07:29 07:14:28.028981
[Composite] Circle Of Confusion : 0.005 mm
[Composite] Field Of View : 65.5 deg
[Composite] Focal Length : 4.9 mm (35 mm equivalent: 28.0 mm)
[Composite] Hyperfocal Distance : 1.98 m
[Composite] Light Value : 12.1
Attached is a config file that should do what you want. You were very close with your XMP definitions, and according to the pix4d documentation, these should have worked. The only thing I changed with the yaw/pitch/roll is to change them to "real" instead of "rational", but the pix4d doc says that rational should be acceptable.
The IMUAngularVelocity is interesting, and is Base64-encoded binary data which seems to be a repeating list of 24-byte structures. I don't know what the first 8 bytes are, but the next 12 seem to be 4 floating point values:
offset char hex long short1 short2 float double date
----------------- ---- -------- ----------- ------ ------ ---------- ----------- ----------
0 00000000 .... 9d80ab0d 229343389 -32611 3499 1.057e-30 1.133e-315 1977-04-08 (0%)
4 00000004 .... 00000000 0 0 0 0 7.93e-16 1970-01-01 (0%)
8 00000008 ...< bd91cc3c 1020039613 -28227 15564 0.02497 -9.457e-14 2002-04-29 (0%)
12 0000000c ..:. b39e3abd -1120231757 -24909 -17094 -0.04556 5.6e-16 1934-07-03 (0%)
16 00000010 r-.< 722dc43c 1019489650 11634 15556 0.02395 2.626e-314 2002-04-22 (0%)
20 00000014 .... 01000000 1 1 0 1.401e-45 8.06e-243 1970-01-01 (0%)
24 00000018 .... 8584ab0d 229344389 -31611 3499 1.057e-30 1.133e-315 1977-04-08 (1%)
28 0000001c .... 00000000 0 0 0 0 -4.252e-13 1970-01-01 (1%)
32 00000020 ..]. e6ea5dbd -1117918490 -5402 -17059 -0.05418 -1.4e-12 1934-07-30 (1%)
36 00000024 ..x. d79f78bd -1116168233 -24617 -17032 -0.0607 9.573e-20 1934-08-19 (1%)
40 00000028 xA.; 7841fc3b 1006387576 16760 15356 0.007698 2.619e-314 2001-11-22 (1%)
44 0000002c .... 01000000 1 1 0 1.401e-45 8.065e-243 1970-01-01 (1%)
48 00000030 m... 6d88ab0d 229345389 -30611 3499 1.057e-30 1.133e-315 1977-04-08 (1%)
52 00000034 .... 00000000 0 0 0 0 -4.252e-13 1970-01-01 (1%)
56 00000038 ..]. e6ea5dbd -1117918490 -5402 -17059 -0.05418 -1.148e-12 1934-07-30 (1%)
60 0000003c .2t. 0b3274bd -1116458485 12811 -17036 -0.05962 2.134e-34 1934-08-16 (1%)
64 00000040 ...8 00baf138 955365888 -17920 14577 0.0001153 2.594e-314 2000-04-10 (1%)
68 00000044 .... 01000000 1 1 0 1.401e-45 8.069e-243 1970-01-01 (2%)
72 00000048 U... 558cab0d 229346389 -29611 3499 1.057e-30 1.133e-315 1977-04-08 (2%)
76 0000004c .... 00000000 0 0 0 0 5.418e-17 1970-01-01 (2%)
80 00000050 .;.< d63b8f3c 1016019926 15318 15503 0.01748 -9.173e-12 2002-03-13 (2%)
84 00000054 .,.. 162ca4bd -1113314282 11286 -16988 -0.08016 8.259e-17 1934-09-21 (2%)
88 00000058 l..< 6cce973c 1016581740 -12692 15511 0.01853 2.624e-314 2002-03-19 (2%)
92 0000005c .... 01000000 1 1 0 1.401e-45 8.074e-243 1970-01-01 (2%)
- Phil
Just out of interest, I was checking the speed of exif and xmp encoding to use pictures in pix4d:
dos('C:\Temp\exiftool -config "C:\Temp\pix4d.config" -GPSLatitude -GPSLongitude -GPSAltitude -GPSLatitudeRef -GPSLongitudeRef -GPSAltitudeRef -csv="C:\Temp\pics_pos.csv" -overwrite_original C:\Temp\Flight_test_data\20191017_F2v2\pic')
takes 11.6 sec
dos('C:\Temp\exiftool -config "C:\Temp\pix4d.config" -Xmp-Camera:Yaw -Xmp-Camera:Pitch -Xmp-Camera:Roll -csv="C:\Temp\pics_rpy.csv" -overwrite_original C:\Temp\Flight_test_data\20191017_F2v2\pic')
takes 12.04 sec
dos('C:\Temp\exiftool -config "C:\Temp\pix4d.config" -GPSLatitude -GPSLongitude -GPSAltitude -GPSLatitudeRef -GPSLongitudeRef -GPSAltitudeRef -Xmp-Camera:Yaw -Xmp-Camera:Pitch -Xmp-Camera:Roll -csv="C:\Temp\pics_pos_rpy_no2.csv" -overwrite_original -fast C:\Temp\Flight_test_data\20191017_F2v2\pic')
while surprisingly this takes 30.09 sec (having the -fast option) and 23.22 sec without the fast option.
I was just interested about the reason why combined exif+xmp takes the same time or longer than separate exif followed by xmp encoding. Am I missing something obvious?
This command doesn't make a lot of sense:
QuoteC:\Temp\exiftool -config "C:\Temp\pix4d.config" -GPSLatitude -GPSLongitude -GPSAltitude -GPSLatitudeRef -GPSLongitudeRef -GPSAltitudeRef -Xmp-Camera:Yaw -Xmp-Camera:Pitch -Xmp-Camera:Roll -csv="C:\Temp\pics_pos_rpy_no2.csv" -overwrite_original -fast C:\Temp\Flight_test_data\20191017_F2v2\pic
it is equivalent to this:
C:\Temp\exiftool -config "C:\Temp\pix4d.config" -csv="C:\Temp\pics_pos_rpy_no2.csv" -overwrite_original C:\Temp\Flight_test_data\20191017_F2v2\pic(if you run on the command line, you'll see a message: "Ignored superfluous tag names or invalid options: -GPSLatitude ..." indicating that the tag name arguments don't mean anything)
Also note that the
-fast option should have no effect when writing, so I don't understand your observations either.
- Phil
Dear Phil!
Thanks for the quick reply and for correcting my mistake (I used some code snippets from http://help.propelleraero.com/en/articles/880862-batch-geotagging-photos-with-exiftool and assumed this is the right format).
Let me rephrase the question a bit:
I removed the unnecessary part of the code and run the 3 experiments once again:
1: batch exif geotag 161 pictures with the lat,lon,alt, latref.... tags - takes t1 = 10.5170 sec
2: batch embed xmp tags for the same 161 pictures (roll, pitch, yaw) - takes t2 = 11.8422 sec
Now I want to combine the two into one. If I have to guess if I combine the two into one command, exiftool has to open each file only once so I would assume EXIF+XMP tagging would take something like 12.5 sec. On the other hand to my surprise it took t3 = 25.0048 sec, which is larger than t1+t2
I call the batch script from Matlab and I repeated the experiment a few times, but I got the same answer.
There must be something else going on here because the time should be about the same. Are you sure you aren't seeing differences from disk caching or something else? Either that or there is something I'm not seeing in your combined command (what is that now, exactly, btw?).
- Phil