This would be a feature to automatically match individual local photos to individual remote photos. If you already have a bunch of observations uploaded but not tagged, this would be a massive timesaver.
A basic implementation using an existing SSIM library would be manageable. Possible libraries:
Download medium-sized versions of all observation photos
Get all specified local photos
Narrow down matches by comparing EXIF date taken with observation date/time, += some time window
iNat strips photo metadata, so we don't have date taken info for remote images
Generally assume that remote images are a subset of local images
For each observation photo:
Get SSIM score against each candidate local photo (within possible time window)
Pick highest-ranked image, with some score threshhold (in case no local match exists)
Notes:
This could be quite computationally intensive for a large photo collection/observation history, so performance optimization may end up being the most difficult part.
Some of the above libraries have fairly heavy dependencies, and I don't want to bloat the size of the naturtag installer too much
The best performance is going to be with GPU acceleration, but that requires platform-specific binaries that I don't think I could package with naturtag
Possibly include both a CPU-only version and a GPU-optimized version?
This would be a feature to automatically match individual local photos to individual remote photos. If you already have a bunch of observations uploaded but not tagged, this would be a massive timesaver.
A basic implementation using an existing SSIM library would be manageable. Possible libraries:
Some preliminary tests are here: https://github.com/pyinat/naturtag/blob/ssim/test_ssim.py
Basic steps might look something like:
Notes: