[Feature]: Estimate Location from other photos #1675
Replies: 23 comments 26 replies
-
Hmm, since most of the picture uploaded from the phone already has geolocation in the image's EXIF. I am not sure if we need this info at all |
Beta Was this translation helpful? Give feedback.
-
Yes but even with mobile not all photos may have geotags. I explain why I thought about this: I went on vacation. I made some exterior photos to my family, but then we went to visit a cave where there was no GPS signal, the photos I took in there have no geotags. Also, later that same day we went to eat to a restaurant where there wasn't GPS signal too. This is not a rare situation. In my case, I don't have any GPS signal on almost any interior spaces... |
Beta Was this translation helpful? Give feedback.
-
To add, Google photos have this feature, though it also uses location history data. It would be helpful for phone + camera setups where a traveller would use phones to take snapshots while dedicated cameras with no GPS for more artistic/composed landscapes. |
Beta Was this translation helpful? Give feedback.
-
I know this feature request is quite old, but it would be very useful to import the takeout location data from Google Timeline, or otherwise to be able to import gpx or geoJSON. It's possible to write to the files before adding to Immich, but considering this application is pitched as a fairly direct competitor to Google Photos, it might be useful to be able to pull from Google's own collection of our data. |
Beta Was this translation helpful? Give feedback.
-
I would like to mention a situation where, let's say, you were to save images from the web or take a couple screenshots at around the same time as shooting some photos with geolocation information. This would add the location data to the saved web images and screenshots as well, and I have had this happen during the time I used PhotoPrism. Side note, PhotoPrism would also stack such screenshots and saved images due to them being around the same time and location, making the problem further annoying. I have had to turn off Location Estimates and Stack by location and time behaviors to make this aspect of my library usable. I think this would be a significant issue considering Immich is also meant to back up your phone's photo library, which will invariably have such saved images and screenshots. |
Beta Was this translation helpful? Give feedback.
-
@r3nor I am very interested in a feature like this, but I can't see how this would effectively work from a technical standpoint. |
Beta Was this translation helpful? Give feedback.
-
There’s a good example of an implementation of this type of function in the OSX Photos CLI software found here on GitHub. Would be useful when importing a mix of DSLR photos and phone photos for sure. very niche cases (taking a photo from a moving vehicle where GPS data is enabled for one photo but not the next photo 2 minutes later) can be addressed/caught with some of the settings. |
Beta Was this translation helpful? Give feedback.
-
I would like this feature, as well. I take lots of photos with my non-phone camera (and no GPS), and my wife is generally taking a few snaps with her phone. Being able to co-locate (based on time) un-tagged photos with the geo-tagged images would be fantastic. Set a time resolution for the association, and suddenly un-tagged images get located (with some uncertainty). |
Beta Was this translation helpful? Give feedback.
-
Also very interested in this feature. |
Beta Was this translation helpful? Give feedback.
-
I am asking for this feature. I usually take pictures with my cell phone, but when I travel I use my still camera (Olympus E-PL5). Of course, I can create albums based on date, but the ability to automatically geo-tag would be more useful. |
Beta Was this translation helpful? Give feedback.
-
Would also really like this feature. Trying Immich, but currently a PhotoPrism user, and when comparing both service's map/location features it really stands out on my library. I have tens of thousands of photos from "normal" cameras (DSLR etc) which don't have any exif GPS data. However in PhotoPrism's map I see almost all of these in approximately the right location. Of course they are not exact, but they are in the right region, usually within a few km, and that's essentially what the map view is for - to be able to browse from the world view down, and see/remember what you did in various places. The location not being precise is, to me, far more preferable than missing out on seeing all those photos at all! Regarding comment about screenshots getting geo-tagged in PhotoPrism due to this method, in my setup screenshots get categorised as "low quality" and don't get shown on the map or timeline views, which seems like a good way to do it. Having a toggle for "show/hide screenshots" would be another good option if Immich wanted to think about that. Or just, don't estimate geo location for screenshots. This was/is probably the one biggest feature that might make PhotoPrism my preferred tool. Thanks! |
Beta Was this translation helpful? Give feedback.
-
The big concern I see with this is that photos from multiple different people could get garbled really easily here. For instance, I was part of a shared (non-Immich) photo album with some friends a while back. I then downloaded these files and loaded them into Immich. Friend A might be at place X, Friend B at place Y taking photos at the same time. Suppose A used geotagging, and B didn't. How do we make sure that B's photos don't show up at X? |
Beta Was this translation helpful? Give feedback.
-
Yeah that’s valid and something I did think about, and would need to be addressed somehow.
I guess firstly, it’s probably an opt in feature. If you don’t think it will work for your setup you could not enable the ‘estimate locations’ feature and there will certainly be some people that this will be better for. But perhaps you want it for some folders/events/scenarios but not others due to the cameras physically being in different locations at the same / similar time.
Photoprism manages it somehow; whether it causes strange effects/impact on a user’s library would of course be specific to each user. For my library/ies it works very well in practice. But I don’t have whole albums/folders of other people’s photos. Maybe a few photos every now and again.
Do you have the opportunity to run photoprism on the library which you have this concern to see what happens in practice?
One way would perhaps be to expose the ‘link’ that is used to make the estimate as a metadata field/property of the photo. And then allow via the UI to ‘unlink’ from an incorrect estimate or even ‘relink’ to a note appropriate estimate.
For example:
Photo 1 is taken by an iPhone with accurate GPS at 09:05:00
Photo 2 is taken with a normal camera with no location data at 09:15:00, the photo is taken by the owner of the iPhone a few hundred meters away from Photo 1.
Photo 3 is taken by another iPhone but by different person at 09:10:00 in another city, with geolocation enabled.
To be accurate, you want Photo 2’s location to be estimated by using Photo 1’s location. However, since the timestamps are closer to Photo 3 it will probably get linked to that one, leading to an inaccurate map display.
If you open Photo 2 and go to meta data > estimated location > there could be a list of photos that were used. You could deselect one; ‘don’t use this photo to estimate location’, or even ‘don’t use photos taken by this camera to estimate the location’ or even further ‘don’t use this camera to estimate locations for ANY photos in this Immich instance’.
Lots of options to think about! Not trivial understand…
----- Original message -----
From: "blublub - notifications at github.com" ***@***.***>
To: "immich-app/immich - immich at noreply.github.com" ***@***.***>
Cc: semiligneous ***@***.***>, "Comment - comment at noreply.github.com" ***@***.***>
Subject: Re: [immich-app/immich] [Feature]: Estimate Location from other photos (Discussion #1675)
Date: Friday, 12 July 2024 05:36
The big concern I see with this is that photos from multiple different people could get garbled really easily here. For instance, I was part of a shared (non-Immich) photo album with some friends a while back. I then downloaded these files and loaded them into Immich. Friend A might be at place X, Friend B at place Y taking photos at the same time.
Suppose A used geotagging, and B didn't. How do we make sure that B's photos don't show up at X?
Valid concern.
This could be prevented with that not being an automated feature, more a guided one:
1. specify time / range
2. Immich lists cameras without and with GPS
3. User selects from which camera a GPS location should be transferred and ho close the timestamp has to be
—
Reply to this email directly, view it on GitHub <#1675 (reply in thread)>, or unsubscribe <https://github.com/notifications/unsubscribe-auth/AOYQN4JSSZASWIPGHIM74TLZL3NDVAVCNFSM6AAAAAAYQ62BHKVHI2DSMVQWIX3LMV43URDJONRXK43TNFXW4Q3PNVWWK3TUHMYTAMBSGQ3TCNI>.
You are receiving this because you commented.Message ID: ***@***.***>
|
Beta Was this translation helpful? Give feedback.
-
Sure! I have a Photoprism instance I was playing around with not to long ago. Hopefully this weekend I'll have some time to spin it back up, get those photos imported, and see what it does. Will report back with my findings. |
Beta Was this translation helpful? Give feedback.
-
Any estimated locations should certainly only be stored as part of the separate metadata/index - not by editing the exif info on the files themselves. This is how Photoprism does it - all my libraries are mounted read/only to ensure this doesn't happen, and the features all work.
…----- Original message -----
From: "Justin Forseth - notifications at github.com" ***@***.***>
To: "immich-app/immich - immich at noreply.github.com" ***@***.***>
Cc: semiligneous ***@***.***>, "Comment - comment at noreply.github.com" ***@***.***>
Subject: Re: [immich-app/immich] [Feature]: Estimate Location from other photos (Discussion #1675)
Date: Tuesday, 16 July 2024 05:10
Tested Photoprism's implementation. Found a few false results, but was overall impressed with how well it worked and can see the appeal of the feature a lot more now.
Still, I don't like the idea of Immich changing the metadata of my pics based on a guess. I think this would be a good feature to add the utilities section, with duplicate detect. Have it ask, "Was this photo taken here?" and give you a little pin you can drag around.
—
Reply to this email directly, view it on GitHub <#1675 (reply in thread)>, or unsubscribe <https://github.com/notifications/unsubscribe-auth/AOYQN4M7MPVRW2NBOYWIV3DZMQNBRAVCNFSM6AAAAAAYQ62BHKVHI2DSMVQWIX3LMV43URDJONRXK43TNFXW4Q3PNVWWK3TUHMYTAMBVGQ3TCNI>.
You are receiving this because you commented.Message ID: ***@***.***>
|
Beta Was this translation helpful? Give feedback.
-
Surely no more or less than any of the other features of either solution - such as face-detection or tags/labels? Those, and estimated locations, are all properties that are created and stored independent of the actual images. Moving to/from either platform inherently requires such information to be lost and then re-created in the new platform. Both can also be used side-by-side indefinitely if required.
…----- Original message -----
From: "Justin Forseth - notifications at github.com" ***@***.***>
To: "immich-app/immich - immich at noreply.github.com" ***@***.***>
Cc: semiligneous ***@***.***>, "Comment - comment at noreply.github.com" ***@***.***>
Subject: Re: [immich-app/immich] [Feature]: Estimate Location from other photos (Discussion #1675)
Date: Tuesday, 16 July 2024 08:17
This is probably out of the scope of this discussion, but does this make migrating away from Immich/Photoprism harder?
—
Reply to this email directly, view it on GitHub <#1675 (reply in thread)>, or unsubscribe <https://github.com/notifications/unsubscribe-auth/AOYQN4OZCGIQ76ELMXXEX33ZMRC63AVCNFSM6AAAAAAYQ62BHKVHI2DSMVQWIX3LMV43URDJONRXK43TNFXW4Q3PNVWWK3TUHMYTAMBVGU4TMNA>.
You are receiving this because you commented.Message ID: ***@***.***>
|
Beta Was this translation helpful? Give feedback.
-
Interesting concept - I was not aware that storing face data info to the images was a ‘thing’ but it makes sense and I can see how some people would want that. Personally if writing the face (or any other) metadata to the files got implemented in Immich I would probably choose to not use it for my use case, at least not yet.
I think it would be something to enable/disable by each user, and also choose which type of data is OK to be written back to the images (facial, geo, geo-estimates etc), but I would still keep my "proper camera" images as external libraries mounted read only anyway so no estimated locations would be written. I upload those to storage location from SD card in other ways.
I don't think this is directly impacting the "can Immich do location estimates" feature request though - but certainly something to take into account alongside other feature requests.
…----- Original message -----
From: "scblakely - notifications at github.com" ***@***.***>
To: "immich-app/immich - immich at noreply.github.com" ***@***.***>
Cc: semiligneous ***@***.***>, "Comment - comment at noreply.github.com" ***@***.***>
Subject: Re: [immich-app/immich] [Feature]: Estimate Location from other photos (Discussion #1675)
Date: Wednesday, 17 July 2024 07:15
Certainly it should not be written to the Geolocation tag unless specifically requested, but it could (via Reverse Geocoding) fill in the IPTC location tags:
90: City
92: Sub-location
95: Province-State
100: Country-PrimaryLocationCode
101: Country-PrimaryLocationName
—
Reply to this email directly, view it on GitHub <#1675 (reply in thread)>, or unsubscribe <https://github.com/notifications/unsubscribe-auth/AOYQN4NP6QDYX63TLTUWPQ3ZMWEQ5AVCNFSM6AAAAAAYQ62BHKVHI2DSMVQWIX3LMV43URDJONRXK43TNFXW4Q3PNVWWK3TUHMYTAMBWGY4DMMQ>.
You are receiving this because you commented.Message ID: ***@***.***>
|
Beta Was this translation helpful? Give feedback.
-
Photoprism's implementation uses the most recent photo with a location taken before + after the one you're trying to estimate location on Does a calculation how much you moved over how much time (velocity vector) Looks at the timestamp of your photo, plops on a location estimate based on your velocity between the taking two photos Oversimplified example: user took photo 1 and photo 3, moved 10 m/s between the two geolocations, photo 2 was taken 10 seconds after photo 1, photo 2 must be 10 meters away from photo 1 source: |
Beta Was this translation helpful? Give feedback.
-
If that’s relatively simple to implement, it would be great to see in Immich. I agree it won’t be perfect, but in my opinion I’d prefer to see all my photos on a map even in a slightly incorrect position than not on the map at all (which is how it is today).
Some type of filter or icon or visual cue to show it’s an ‘estimated location’ rather than ‘gps location’ would be additionally useful/helpful.
Ability to switch the feature on or off, (maybe even per external library? In order to assist those who maybe have mixed sources, some of which may be more or less suited to this type of estimation) would be good.
…----- Original message -----
From: "matcpn - notifications at github.com" ***@***.***>
To: "immich-app/immich - immich at noreply.github.com" ***@***.***>
Cc: semiligneous ***@***.***>, "Comment - comment at noreply.github.com" ***@***.***>
Subject: Re: [immich-app/immich] [Feature]: Estimate Location from other photos (Discussion #1675)
Date: Tuesday, 3 September 2024 11:33
Photoprism's implementation uses the most recent photo with a location taken before + after the one you're trying to estimate location on
Does a calculation how much you moved over how much time (velocity vector)
Looks at the timestamp of your photo, plops on a location estimate based on your velocity between the taking two photos
Oversimplified example: user took photo 1 and photo 3, moved 10 m/s between the two geolocations, photo 2 was taken 10 seconds after photo 1, photo 2 must be 10 meters away from photo 1
source:
https://github.com/photoprism/photoprism/blob/develop/internal/entity/photo_estimate.go
—
Reply to this email directly, view it on GitHub <#1675 (comment)>, or unsubscribe <https://github.com/notifications/unsubscribe-auth/AOYQN4OCKTNL2XWJVNK5CLLZUUGVTAVCNFSM6AAAAAAYQ62BHKVHI2DSMVQWIX3LMV43URDJONRXK43TNFXW4Q3PNVWWK3TUHMYTANJSGYYDSMY>.
You are receiving this because you commented.Message ID: ***@***.***>
|
Beta Was this translation helpful? Give feedback.
-
I have been working on a standalone script to do this for my own photos collection, although it does it by re-writing the EXIF data directly on the photos. My use case is my phone has GPS and my DSLR does not, and I want to use the GPS data from my phone's photos to populate the location tags for my DSLR photos. An approximation is often good enough and much better than nothing. For this to work well, it requires that the time on the phone and DSLR are well synced, which I always make sure of. My algorithm is to take the time and GPS location from the the four closest-in-time (2 before and 2 after) photos with GPS data, select which two to use, and do a linear interpolation/extrapolation of the location and tag it with those results. I artificially change the GDOP values to reduce the precision of the location fix for these interpolated values based on the time difference between the two photos. The reference photo selection process is a little complicated in an attempt to try to make the calculation more accurate. I tend to prefer using the closest photos on either side (in time), but when one side has two much closer timestamps, it will extrapolate using the location and time of those instead of interpolating using the ones on either side. There are some special circumstances:
I also add another custom EXIF tag so that I can easily tell if the photo has real or interpolated GPS data, so that if I come up with better heuristics, I can go back and re-tag the photos. Obviously these heuristics won't work on a whole-library basis, but they should work quite well within appropriately organized albums. |
Beta Was this translation helpful? Give feedback.
-
This feature goes by the name of "geotagging" photos. And tools have been around for a long time that have done this. Search keywords: geotagging and interpolation. Even exiftool has a way to do this from gps track files: https://www.exiftool.org/geotag.html That said, it would be nice to have this option in Immich. No other comments other than +1, this has my vote. |
Beta Was this translation helpful? Give feedback.
-
The most common case I see is pictures shared by groups through messaging apps that strip the exif data. This cases is also quite easy |
Beta Was this translation helpful? Give feedback.
-
There's already a PR #20758 to implement this. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Feature detail
So Photoprism has a feature that given a 24h time span, it sets the geotag of the images from that span with the geolocation of other images that were taken the same day.
I think this is a very useful feature, but 24h I think is too much and can be innacurate.
It would be a good feature if Immich could get Geolocation estimations from close-taken pictures for those that do not have Geolocation metadata in short timespans.
Platform
Server
Beta Was this translation helpful? Give feedback.
All reactions