Skip to content
Commit ba796dd7 authored by Bruno Abinader's avatar Bruno Abinader Committed by Maik Qualmann
Browse files

Run HaarIface::findDuplicates lock-free in parallel

This works by splitting the duplicates finding logic in 4 major steps:

1. Resolve all image ids before starting the searches jobs during DuplicatesFinder::slotStart().
2. Create a shared HaarIface with signature cache in SearchesDBJobsThread to be used by all SearchesJob in parallel.
3. Break down the whole "images to scan" set into iterator ranges, and run these in parallel (lock-free).
4. Rebuild (or update) the search albums in the database.

Step 3) can be run lock-free in parallel with some adjustments e.g. because we're using constant iterator ranges, it is
not possible to remove unused images from the cache when running multithread. Also because we use ranges in step 3),
sometimes the same search album is generated multiple times in separate threads using different reference images; in
step 4) we ensure the aggregated results are filtered so there's only one search album with similar images per
duplicates found.

BUG:372435
parent f8167e2f
Loading
Loading
Loading
Pipeline #55983 canceled with stage
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment