Menu

#33 linear interpolate doesn't care about maxtimediff

v1.0 (example)
open
None
5
2014-01-11
2014-01-07
comp3v
No

I noticed that in case of running with "--interpolate=linear" option, the gpsPhoto.pl doesn't consider maxtimediff option and never gives "Could not find a coordinate" even for totally remote points. Isn't it a bug?
Thanks

Discussion

  • Uwe Girlich

    Uwe Girlich - 2014-01-11

    I don't think so.
    Please have a look at the code lines 1292 to 1309. The interpolation is done between the 2 track points directly before and after the time of the image in two cases: either the timestamp of the image is "near" (in the sense of maxtimediff) to any of the 2 track points OR the two track points are very near together spatially (option maxdistance, default is 20 metres). This feature was added to support geocoding of images in a house without GPS access, when you have track points from arrival and departure: the last arrival track point and the first departure track point are near together and so we just assume, that all images taken between arrival and departure are made at the same spot. If you don't like this behaviour just use a much smaller maxdistance (like 0).

     
  • comp3v

    comp3v - 2014-01-11

    now I see, thanks for explaining!
    (I still think it would be nice to give an option to disable such behavior without changing maxdistance, but at least now I see how to do that).

     
  • Uwe Girlich

    Uwe Girlich - 2014-01-11

    No problem, I could add such an option. Any ideas about a good name and exact behaviour? I think such an option should cover all possible combinations of the timely and spatial nearness. My proposal:
    --nearness=space
    --nearness=time
    --nearness=space-or-time (current behaviour, the default)
    --nearness=time-or-space (same like space-or-time)
    --nearness=space-and-time (interpolation happens only, when time and space of consecutive track points are near to each other)
    --nearness=time-and-space (same like space-and-time)

    And I just re-checked the documentation. It explains the logical OR and even lists another reason for this I completely forgot already: there are track recorders recording only, if the coordinates change considerably. But when you just stay in one spot and take pictures you may not get any future track points.

     
  • comp3v

    comp3v - 2014-01-11

    well, in my case just adding the option of -and- instead of -or- would already solve the problem :) Thanks a lot!

     

Log in to post a comment.