Exiftool 9.06 on Mac OSX Maverick via MacPorts 2.2.1.
I'm using Python 2.7 and exiftool to get json formated metadata of images.
To increase processing speed I use the -stay_open feature to keep executable running between the commands.
For a given test image I get different results ( see attachment *.txt ) for the same image when querying it within the same -stay_open session !?
Comparing 2nd attempt to 1st attempt :
- 22 "new" tags added
- one tag "FileAccessDate" changed ( this is expected )
I attached a Python script to trigger the problem.
Strangely the problem disappears when I initially call command "-ver" before doing any other stuff in the stay_open session !?
I tried to reproduce the problem by excuting exiftool on the commandline and feeding it via stdin - but there the results are always the same.
Maybe a Python expert give some insides ?
Sorry for the delay in responding. I'm currently on vacation.
The difference in output between your two runs looks mainly like Composite tags. This could be caused by an extra -e option in one command to suppress the composite tags. I don't have time to study your PHP closely to see how this could possibly happen, but if possible it could explain the output files you posted.
Try printing your exiftool commands to see exactly what you are trying to execute.
- Phil
Thanks for you reply Phil.
I took a deeper look at my commands supplied to exiftool and found the issue !
The reason seems to be my initial command to start exiftool, using the following arguments:
"-e", "-lang", "en", "-stay_open", "True", "-@", "-"
-e is telling exiftool to discard composite tags.
Thus the first invocation after starting exiftool using arguments "-J PATH_TO_IMAGE" is performed while -e feature is effective whereas any following invocation does include composite tags !?
When I omit the initial -e then the output is equal for any number of consecutive invocations except FileAccessDate ( which is expected ).
I don't know if this behaviour is consider a bug or a feature ?
Quote from: mako on August 19, 2014, 02:45:27 PM
Thus the first invocation after starting exiftool using arguments "-J PATH_TO_IMAGE" is performed while -e feature is effective whereas any following invocation does include composite tags !?
Yes. It is a separate command after any
-execute option. If you want arguments common to all commands, you need to use the
-common_args feature.
QuoteI don't know if this behaviour is consider a bug or a feature ?
This is by design.
- Phil
Hello,
please allow an additional question:
QuoteIt is a separate command after any -execute option.
That this is valid for -e option is clear to me.
But is the same also valid for -use MWG ?
Best regards
Herb
-use MODULE
Add features from specified plug-in MODULE. Currently, the MWG
module is the only plug-in module distributed with exiftool. This
module adds read/write support for tags as recommended by the
Metadata Working Group. To save typing, "-use MWG" is assumed if
the "MWG" group is specified for any tag on the command line. See
the MWG Tags documentation for more details. Note that this
option is not reversible, and remains in effect until the
application terminates, even across the "-execute" option.