From e9a9b8085b6efee1f26fe777be38211d4f95866b Mon Sep 17 00:00:00 2001
From: schlda00 <kai.schleicher@unibas.ch>
Date: Fri, 25 Apr 2025 13:40:53 +0200
Subject: [PATCH] Update function for newest version of TrackMate

---
 2d_spots_in_fibers.py | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/2d_spots_in_fibers.py b/2d_spots_in_fibers.py
index 78054ef..2d76305 100644
--- a/2d_spots_in_fibers.py
+++ b/2d_spots_in_fibers.py
@@ -198,8 +198,8 @@ def run_trackmate_dog_spot_detector(imp, spot_diameter, quality_threshold):
 
     exportSpotsAsDots = True
     exportTracksOnly = False
-    # labelIdPainting = LabelImgExporter.LabelIdPainting.LABEL_IS_INDEX_MOVIE_UNIQUE
-    label_imp = LabelImgExporter.createLabelImagePlus(trackmate, exportSpotsAsDots, exportTracksOnly, False) # labelIdPainting (needed in a future verion of TM)
+    labelIdPainting = LabelImgExporter.LabelIdPainting.LABEL_IS_INDEX_MOVIE_UNIQUE
+    label_imp = LabelImgExporter.createLabelImagePlus(trackmate, exportSpotsAsDots, exportTracksOnly, labelIdPainting)
     label_imp.setCalibration(cal)
     imp.close() 
 
-- 
GitLab