From 91c4c97ed25dc2ffc886f50fee2b6fe0c0b25544 Mon Sep 17 00:00:00 2001 From: Jean-Yves Tinevez Date: Wed, 24 May 2023 13:35:44 +0200 Subject: [PATCH] Fix OverlapTracker not working if the first frame was devoid of visible spots. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Noticed by Laura XĂ©nard @Mini-Miette Fix #260 --- .../plugin/trackmate/tracking/overlap/OverlapTracker.java | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/main/java/fiji/plugin/trackmate/tracking/overlap/OverlapTracker.java b/src/main/java/fiji/plugin/trackmate/tracking/overlap/OverlapTracker.java index 3279e80da..6feca9b02 100644 --- a/src/main/java/fiji/plugin/trackmate/tracking/overlap/OverlapTracker.java +++ b/src/main/java/fiji/plugin/trackmate/tracking/overlap/OverlapTracker.java @@ -203,7 +203,11 @@ public boolean process() final Map< Spot, Polygon2D > targetGeometries = createGeometry( spots.iterable( targetFrame, true ), method, enlargeFactor ); if ( sourceGeometries.isEmpty() || targetGeometries.isEmpty() ) + { + sourceGeometries = targetGeometries; + logger.setProgress( ( double ) progress++ / spots.keySet().size() ); continue; + } final ExecutorService executors = Threads.newFixedThreadPool( numThreads ); final List< Future< IoULink > > futures = new ArrayList<>();