Bug 485332 - Some images were not correlated even though GPS coordinates were available for the time they were taken
Summary: Some images were not correlated even though GPS coordinates were available fo...
Status: RESOLVED NOT A BUG
Alias: None
Product: digikam
Classification: Applications
Component: Geolocation-Correlator (show other bugs)
Version: 8.3.0
Platform: Microsoft Windows Microsoft Windows
: NOR normal
Target Milestone: ---
Assignee: Digikam Developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2024-04-10 16:15 UTC by Steve Franks
Modified: 2024-04-14 11:08 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed In: 8.4.0
Sentry Crash Report:


Attachments
GPX Track (266.17 KB, application/octet-stream)
2024-04-10 16:15 UTC, Steve Franks
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Steve Franks 2024-04-10 16:15:07 UTC
Created attachment 168348 [details]
GPX Track

***
If you're not sure this is actually a bug, instead post about it at https://discuss.kde.org

If you're reporting a crash, attach a backtrace with debug symbols; see https://community.kde.org/Guidelines_and_HOWTOs/Debugging/How_to_create_useful_crash_reports
***

SUMMARY
I took some photos today and used digikam geolocation editor to geotag them. This is something that I have done successfully many times.
Two of the 21 images were not located using my default Interpolate setting of 00:05:00. They were correctly located when the time was increased to 00:06:00.

STEPS TO REPRODUCE
1.  Save a GPX file containing a track recorded at the same time as a number of photos were taken.
2.  Use digikam geolocation editor to match the photos to the track to establish their coordinates.
3.  

OBSERVED RESULT
Two images were not matched against the GPX track.

EXPECTED RESULT
All images matched.

SOFTWARE/OS VERSIONS
Windows:  11
macOS: 
Linux/KDE Plasma: 
(available in About System)
KDE Plasma Version: 
KDE Frameworks Version: 
Qt Version: 

ADDITIONAL INFORMATION
I always allow a margin of 5 minutes for interpolating images in case the Garmin eTrex 22x loses signal, as can happen in inclement weather.  digikam shows the time that the two photos were taken was 10th Apr 2024 @ 11:45. The track shows 5 points during that minute (11:45).
Comment 1 Steve Franks 2024-04-10 16:20:12 UTC
The photos are too big to upload here.
digikam metadata shows that one was taken at 11:45:29, the other at 11:45:37.
Comment 2 Maik Qualmann 2024-04-10 16:41:30 UTC
The problem is clear and easy to fix.

@Gilles,
Now that we are at Qt-6.7.0 with the Windows MSVC version, do we want to go back to a local date/time in digiKam or do we want to keep UTC as the timespec?
One would probably be the speed of date calculations, we can easily test this with a change in digikam_globals.cpp without patching the entire code.
The question is also, if we were to support time zones in the future, would UTC be better as a timespec?

Maik
Comment 3 caulier.gilles 2024-04-10 17:22:20 UTC
Qt 6.7.0 in VCPKG ? As i can see it's always 6.6.1. There is a PR, but not yet merged :

https://github.com/microsoft/vcpkg/pull/37923

AppImage and MacOS uses 5.15.13.

Gilles
Comment 4 Maik Qualmann 2024-04-10 17:44:59 UTC
Ah yes, I hadn't even thought about this dependency at the moment.

Maik
Comment 5 Maik Qualmann 2024-04-10 17:58:26 UTC
@Steve,
After looking at the code it doesn't seem to have anything to do with the UTC timespec we are currently using. Can you send me the two images by email.
Comment 6 Maik Qualmann 2024-04-10 18:06:39 UTC
I looked at the GPX data, you are in UTC time, +1 hour daylight saving time. I think you didn't set your camera to daylight saving time.

Maik
Comment 7 caulier.gilles 2024-04-11 08:38:43 UTC
>Now that we are at Qt-6.7.0 with the Windows MSVC version, do we want to go back to a local date/time in digiKam or do we want to keep >UTC as the timespec?

yes, when 6.7.0 will be available

>One would probably be the speed of date calculations, we can easily test this with a change in digikam_globals.cpp without patching the >entire code.

yes, a factorized method checking the QT version will help here.

>The question is also, if we were to support time zones in the future, would UTC be better as a timespec?

I think yes. a C++20 response is given here :

https://www.modernescpp.com/index.php/calendar-and-time-zone-in-c-20-time-zones/

Gilles
Comment 8 Maik Qualmann 2024-04-11 19:39:11 UTC
There is no problem in digiKam, I tested it with my test GPX route. For your images with 11:45:29 and 11:45:37, only a GPS time around 12:45:xx comes into question where the images correlated correctly. So you have to set your time zone to -01:00 in the digiKam correlation settings.
We might have to make a checkbox for daylight saving time or calculate it automatically.

Maik
Comment 9 Steve Franks 2024-04-14 10:44:56 UTC
(In reply to Maik Qualmann from comment #6)
> I looked at the GPX data, you are in UTC time, +1 hour daylight saving time.
> I think you didn't set your camera to daylight saving time.
> 
> Maik

That's probably true. Sorry to have bothered you.
Steve