DateTimeOriginal not being used by iMatch for DateTime after import?

Started by sgr, June 28, 2021, 01:02:53 PM

Previous topic - Next topic

sgr

I have written an application to assist with the import of images from a variety of sources we have (action/wildlife cameras, phones, CCTV snapshots etc) whereby it adds various hierarchical keywords, fills in missing metadata and places the files in applicable folders for easy import into my IMatch structure.

This works fine except for one aspect which is I am ensuring Exif DateTimeOriginal is set as I read in the online help for IMatch "How IMatch fills DateTime" that is uses DateTimeOriginal first then CreateDate, ModifyDate and others.

However if I only have DateTimeOriginal set then it doesn't pick up this value.  However if I set CreateDate then it works as expected.

I am using ExifTool inside my application and ExifTool confirms the DateTimeOriginal value was set, for example using two of its output options:

[EXIF]          DateTimeOriginal                : 2021:05:27 12:00:00

36867 Date/Time Original              : 2021:05:27 12:00:00


I can easily set both but is this an issue or have I inadvertently changed an IMatch setting somewhere given the online help article?   Using IMatch 2020.14.2

Mario

IMatch uses

[ExifIFD] Date/Time Original
[ExifIFD] Create Date

and

[IPTC] Date Created
[IPTC] Digital Creation Date

and

[XMP-exif] Date/Time Original
* [XMP-photoshop] Date Created

depending on what exists in the file. During import, EXIF data is mapped to XMP by ExifTool and/or IMatch, if a file is re-read (but already in the database), it depends on under which conditions the re-read is triggered (forced, post write-back, file modified on disk).

DateTimeDigitized is prefferred (XMP::photoshop\DateCreated\DateCreated) with a fall back to (XMP::xmp\CreateDate\CreateDate) and a ton of other tags.

There is also metadata protection to keep in mind, and settings you may have set under Edit > Preferences > Metadata 2

I don't know what your application does or which tags and digests (!) it updates. And if everything is correct.
You must update all existing legacy IPTC, EXIF and XMP timestamps in your files to match. Not just pick one field and leave the others dangling.
Run the MDA (The Metadata Analyst) on one of the files your application has manipulated and show us the results (GREEN BUTTON).
-- Mario
IMatch Developer
Forum Administrator
http://www.photools.com  -  Contact & Support - Follow me on 𝕏 - Like photools.com on Facebook

sgr

Thanks for the quick reply.   Taking one of the simpler input files as created by BlueIris CCTV software, it starts with the following using ExifTool (I've removed some basic NTFS file details to keep it short):

[ExifTool]      ExifToolVersion                 : 12.21
[File]          MIMEType                        : image/jpeg
[File]          ExifByteOrder                   : Big-endian (Motorola, MM)
[File]          ImageWidth                      : 2304
[File]          ImageHeight                     : 1296
[File]          EncodingProcess                 : Baseline DCT, Huffman coding
[File]          BitsPerSample                   : 8
[File]          ColorComponents                 : 3
[File]          YCbCrSubSampling                : YCbCr4:2:0 (2 2)
[JFIF]          JFIFVersion                     : 1.01
[JFIF]          ResolutionUnit                  : inches
[JFIF]          XResolution                     : 96
[JFIF]          YResolution                     : 96
[EXIF]          Software                        : Blue Iris
[EXIF]          DateTimeOriginal                : 2021:05:27 12:00:00
[Composite]     ImageSize                       : 2304x1296
[Composite]     Megapixels                      : 3.0


I add the DateTimeOriginal and hierarchical keywords (which adds an XMP section) and then using your validation I get this for the file that didn't work with timeline:

Metadata Analyst Results. Version 2020.14.2. 6/28/2021 1:13:53 PM
File analyzed: \\SERVER03\CCTV\20210527_120000_issue.jpg
Errors: 0
Warnings: 13

Warning: [EXIF] CreateDate missing.
Warning: [XMP] [ExifIFD]:DateTimeOriginal not mapped to [XMP-exif]:DateTimeOriginal (embedded).
Warning: [XMP] [ExifIFD]:DateTimeOriginal not mapped to [XMP-photoshop]:DateCreated (embedded).
Warning: [Detailed Validation] Missing required JPEG ExifIFD tag 0x9000 ExifVersion
Warning: [Detailed Validation] Missing required JPEG ExifIFD tag 0x9101 ComponentsConfiguration
Warning: [Detailed Validation] Missing required JPEG ExifIFD tag 0xa000 FlashpixVersion
Warning: [Detailed Validation] Missing required JPEG ExifIFD tag 0xa001 ColorSpace
Warning: [Detailed Validation] Missing required JPEG ExifIFD tag 0xa002 ExifImageWidth
Warning: [Detailed Validation] Missing required JPEG ExifIFD tag 0xa003 ExifImageHeight
Warning: [Detailed Validation] Missing required JPEG IFD0 tag 0x011a XResolution
Warning: [Detailed Validation] Missing required JPEG IFD0 tag 0x011b YResolution
Warning: [Detailed Validation] Missing required JPEG IFD0 tag 0x0128 ResolutionUnit
Warning: [Detailed Validation] Missing required JPEG IFD0 tag 0x0213 YCbCrPositioning


If I add the CreateDate then it works, but validation still shows:
Metadata Analyst Results. Version 2020.14.2. 6/28/2021 1:15:00 PM
File analyzed: \\SERVER03\Photos\CCTV\20210527_120000_works.jpg
Errors: 0
Warnings: 13

Warning: [XMP] [ExifIFD]:DateTimeOriginal not mapped to [XMP-exif]:DateTimeOriginal (embedded).
Warning: [XMP] [ExifIFD]:CreateDate not mapped to [XMP-xmp]:CreateDate (embedded).
Warning: [XMP] [ExifIFD]:DateTimeOriginal not mapped to [XMP-photoshop]:DateCreated (embedded).
Warning: [Detailed Validation] Missing required JPEG ExifIFD tag 0x9000 ExifVersion
Warning: [Detailed Validation] Missing required JPEG ExifIFD tag 0x9101 ComponentsConfiguration
Warning: [Detailed Validation] Missing required JPEG ExifIFD tag 0xa000 FlashpixVersion
Warning: [Detailed Validation] Missing required JPEG ExifIFD tag 0xa001 ColorSpace
Warning: [Detailed Validation] Missing required JPEG ExifIFD tag 0xa002 ExifImageWidth
Warning: [Detailed Validation] Missing required JPEG ExifIFD tag 0xa003 ExifImageHeight
Warning: [Detailed Validation] Missing required JPEG IFD0 tag 0x011a XResolution
Warning: [Detailed Validation] Missing required JPEG IFD0 tag 0x011b YResolution
Warning: [Detailed Validation] Missing required JPEG IFD0 tag 0x0128 ResolutionUnit
Warning: [Detailed Validation] Missing required JPEG IFD0 tag 0x0213 YCbCrPositioning


I can easily add any required fields and their XMP equivalents as my import application is basically a configurable rule based engine to extract specific data for different source devices and modify the file accordingly.   I just wasn't aware after reading the  IMatch help article I mentioned that CreateDate was essential, or I should create XMP values to match.

If that's as expected for IMatch then that's fine, I'll configure accordingly.   Some of the other jpeg files from action/wildlife cameras are even worse with only a very metadata fields populated compared to phone and camera sources despite often having proprietary sidecar files with the required details.

Mario

Please just send the file which exhibits the problem, a link back to this thread, and details about what exactly your application is doing to support email address.
My "Please check the metadata in my file because it does not work the way I thing it should work" queue is already full, and I have a backlog of maybe a week or two.

By a first look your application is ignoring the existing XMP, updating only EXIF without proper mapping. This will end in problems.
-- Mario
IMatch Developer
Forum Administrator
http://www.photools.com  -  Contact & Support - Follow me on 𝕏 - Like photools.com on Facebook

sgr

No problem, and there's no rush as I can just add the extra values.