Closed smellyspice closed 2 years ago
This is expected. Mapillary Tools consider images both at the same point (<= distance_duplicated) and at the same angle (<= angle_duplicated) as duplicated. Because photos taken at the same point but in different directions could be still useful ;)
To solve this problem (or any other 360 camera), you can try specify --distance_duplicated 5 --angle_duplicated 360
to disable the angle duplication check.
@ptpt - Thanks for the quick reply and workaround.
No doubt being able to process images at the same location in different directions is useful. However, --duplicate_angle
is an optional filter and by not using it, I would expect the application not to perform any angle dup checks!
Perhaps the fix here is to either change the default value to 360 so it acts disabled
by default (as you suggest) or to update the documentation to make it clear that this option goes active with a default value of 5 whenever --duplicate_distance
is used. This might clear up future confusion. I honestly prefer the former over the latter, since if angle calcs were important to me, I'd have used that filter in the first place! :)
Thanks to you both for raising this issue and providing a workaround.
I agree with everything in @smellyspice's last comment, following his suggestion would surely help many users (otherwise we have to rely on users finding this thread here for the workaround).
Thanks for the input and sorry for the confustion here. Hard to change the defaults because it has been there for a while. We can definitely clarify it in the manual or docs. Will fix it in the next release.
And it seems that interpolate will run after the duplication check, means there is no way to remove duplication if there is no direction in the source EXIF.
I hope it should be somehow clarify or fixed too? (I switched to GoPro Hero 10 and went into this issue processing timelapse JPGs)
Let me know if it makes sense to you
--duplicate_distance DUPLICATE_DISTANCE
The maximum distance that can be considered "too
close" between two images. If both images also point
in the same direction (see --duplicate_angle), the
later image will be marked as duplicate and will not
be upload. [default: 0.1]
--duplicate_angle DUPLICATE_ANGLE
The maximum camera angle difference between two images
to be considered as heading in the same direction. If
both images are also close to each other (see
--duplicate_distance), the later image will be marked
as duplicate and will not be upload. [default: 5.0]
Basic information
mapillary_tools version 0.8.2
Linux
GoPro MAX
Steps to reproduce behavior
Expected behavior
expected
images skipped due to MapillaryDuplicationError
Actual behavior
Images not skipped
Corresponding data
Images imported into EasyGPS to view relative position of images: https://screencast-o-matic.com/i/c3fZrKVYZrE
Additional information
I think the problem is in the logic here: https://github.com/mapillary/mapillary_tools/blob/4bfebf8705d06d8568619cc0c6b83fd3d4fad95e/mapillary_tools/process_sequence_properties.py#L97 A true in
distance_duplicated
will never get appended ifangle_duplicated
doesn't also evalute to trueWhen I change line 97 to:
if distance_duplicated: # and angle_duplicated:
I correctly get the clustered images at the stop light removed as duplicates. See: https://screencast-o-matic.com/i/c3fZrLVYZ33Thanks, Rob