Thread: Problems with timestamp metadata on JPEG file (due to daylight saving hour?)
i'm having trouble understanding how ubuntu deals timestamps in metadata. example i've taken photo camera @ 18:05 (utc+1). on camera itself, shows correct time when view picture on screen.
when copy picture computer, ubuntu adds 1 hour timestamp, thus:
why this? ubuntu trying clever, noting picture taken during british summer time , assuming metadata refers utc? that's source of one-hour time difference can think of. or there other reason?code:$ ls -l p4280277.jpg -rwxr-xr-x 1 user group 451097 2012-04-28 19:05 p4280277.jpg
confirm metadata has not somehow been changed when copying image onto computer, used following python code:
this gives timestamp = '2012:04:28 18:05:01', metadata on actual file still correct.code:import pil.image, pil.exiftags # open file f = pil.image.open('p4280277.jpg') # metadata dictionary info_raw = f._getexif() # find 'datetime' tag tag in info_raw.keys(): tag_decoded = pil.exiftags.tags.get(tag, tag) if tag_decoded == 'datetime': timestamp = info_raw[tag] break
interestingly, if run
then ubuntu no longer adds 1 hour onto timestamp!code:$ touch -t 201204281805.01 p4280277.jpg
can explain what's happening here?code:$ ls -l p4280277.jpg -rwxr-xr-x 1 user group 451097 2012-04-28 18:05 p4280277.jpg
just out of curiosity...check selected time "system settings"
manual...or automatic?
-t option touch sets time file
man touch quantum leap??![]()
Forum The Ubuntu Forum Community Ubuntu Official Flavours Support New to Ubuntu [all variants] Problems with timestamp metadata on JPEG file (due to daylight saving hour?)
Ubuntu
Comments
Post a Comment