Temperature, Humidity, & Pressure.
For some time I have wondered it would be neat to capture ambient weather information when a photo was taken. Why? you may be wondering. Well, along with the image itself the accompanying metadata captures a lot of the moment. Basic information contained within a modern digital image file of course is the date and the time when a photo was taken. Smartphones and certain cameras can also capture the location geo coordinates using GPS or other geolocation methods. Cameras can even detect faces and even perform facial recognition identifying people in the photos. Already smartphones have pressure and temperature sensors so if the information is available why not record that information to the image metadata as well?
This information can be used to aid photo organization and searching in various ways. AI image analysis could also use this information in identifying and classifying images. For example, if an AI engine is almost certain that the image contains snow or rain, would not humidity and temperature values be helpful to increase its certainty? Classification of images as taken indoors or outdoors could also be aided using these values.
Already some Sony cameras capture and record (within its model specific makernotes) ambient temperature as well as internal camera temperature and battery temperature when an image is taken. The Exif 2.31 standard included new fields for storing some of these values:
0x9400 | Ambient Temperature | Ambient temperature in degrees C, called Temperature by the EXIF spec. |
0x9401 | Humidity | Ambient relative humidity in percent |
0x9402 | Pressure | Air pressure in hPa or mbar |
0x9403 | Water Depth | Depth under water in metres, negative for above water. |
Source: https://www.sno.phy.queensu.ca/~phil/exiftool/TagNames/EXIF.html
For cameras which lack capability, this information could also be added during post-processing. An image file with the date and time information along with geo coordinates it would be possible for a web service with historical weather station information to return this values so that they can be added back to the file. Apps such as Snapchat already do this as “stickers”. Services which contain historical weather information are: NOAA Centers for Environmental Information, Weather Underground and Open Weather Map.
Weather Tag
Update 10/2018 – I wrote a simple Windows command line application for adding weather information to a set of images. Using the date and time a photo was taken, the app matches the weather reading from a file containing periodic weather readings. The project is hosted in https://github.com/josemoliver/WeatherTag
You can download the compiled Weather Tag console app as well as example files you can use to test it out from the https://github.com/josemoliver/WeatherTag/releases page.
Update 4/2019 – Flickr now displays this information for recently uploaded files – here is an example. On the photo page if you click on the Show Exif link it will include Ambient Temperature, Humidity and Pressure readings, if available.
I followed your article on converting WLPG People tags to Lightroom. I got the following CMD lines to work fine for a single folder:
D:\Dropbox\Name Test>exiftool -config convert_regions.config “-regioninfoexiftool *.jpg -“xmp-dc:Subject+<RegionPersonDisplayName"
2 image files updated
I have over a 100K photos in a large multi-folder organization. Is there a way to automate the above CMD lines to automatically go thru all of the folders in my Win10 organization scheme?
Hello Joe, Yes. If you add -r to the command line it will “recursively” go through all the subfolders. 100K is quite a lot of photos, so I would recommend to try to break the task among a subgroup of folders, say in batches of 20K. The command will generate also backup files with the .jpg_original extension, you could also add the -overwrite_original flag so that it does not create the backup files. Ensure you have a backup of the files before proceeding.
Hey this is awesome!
I’ve a tangentially related question for you, does any of this show up for you when viewing the pictures normally? Recently got a camera enclosure and dive watch and thought it would be cool to take the watch data to tag all the photos with Temperature and WaterDepth from my dive watch and while I think I got it added correctly with a python script, I cannot actually see it anywhere when trying to view the Exif data with default viewers (on Windows). Trying to figure out if this is me doing something wrong or if they just don’t show up in most things.
Thanks!
Well, it depends on the software you use to view the images. The data is saved to the file, but not all applications may display them. In windows the ones I know of like Geosetter and Digikam do. You could also use exiftool to export the data from the image file to say a csv file for opening in Excel, for example.