[ImageJ-devel] Exporting trackmate data using ImageJ/Jython script

Jean-Yves Tinevez jeanyves.tinevez at gmail.com
Sat Jun 13 12:04:14 CDT 2015


Hi Roy,

Ok I found the problem.

The tables return their item sorted by time (spot, edges at least). So you
need to make sure that you compute the time feature for edges if you don't
want to to fail.This means in your script add:


# Edge analyzer
settings.addEdgeAnalyzer(EdgeTargetAnalyzer())
settings.addEdgeAnalyzer(EdgeTimeLocationAnalyzer())

(without Target, you cannot save the TrackMate file btw)

and then

ExportStatsToIJAction().execute(trackmate)

will work.

best
jy





On Sat, Jun 13, 2015 at 5:16 PM, Roy Francis <roy.m.francis at outlook.com>
wrote:

> Hi Jean,
> Thank you for your quick reply. ExportStatsToIJAction().execute(trackmate)
> doesn't seem to work. It doesn't matter what approach is used. Is there any
> way to save the three output data to a text file during batch process using
> script? If there is no way to do that, how can I have the result tables be
> opened in new windows during batch process so that I can manually save them
> at the end?
> Thanks,
> Roy
>
>
> ------------------------------
> Date: Sat, 13 Jun 2015 16:31:10 +0200
> Subject: Re: Exporting trackmate data using ImageJ/Jython script
> From: jeanyves.tinevez at gmail.com
> To: roy.m.francis at outlook.com
>
>
>
>
> On Sat, Jun 13, 2015 at 4:17 PM, Roy Francis <roy.m.francis at outlook.com>
> wrote:
>
>
> Hi,
> I am using trackmate to track some cells in image files. They seem to work
> fine using the GUI. But, I have a folder full of files and wish to run
> trackmate non-interactively as a batch.
>
> I am using ImageJ macros to load images, convert avi to tiff sequence,
> convert to hyper stacks (for z-stack to time-stack) and then feed to the
> trackmate function which I created as a plugin based on instructions this
> page
>
> http://fiji.sc/Scripting_TrackMate
>
> Painfully, I have got it all to work except for the final part. The data
> exporting. Using the GUI, there is a button that opens three data tables
> for spot results, connections and track results. And once this is open it
> can be saved using IMJ macros.
>
> How can I open these data and/or save them to a text file either using IMJ
> or Jython? I have the feeling the answer is ExportStatsToIJAction(). But,
> I have no idea how to use it. The help page
>
> http://javadoc.imagej.net/Fiji/fiji/plugin/trackmate/action/ExportStatsToIJAction.html
> is utterly unreadable and doesn't explain anything.
>
> Any help is greatly appreciated. Full script below if required.
>
>
>
> Hi Roy
>
> I am afraid the action you mention cannot be used in an headless mode. It
> just generates the tables on ImageJ then you have to save them manually
>
> If it is still what you want to to, try something in the lione of:
>
> ExportStatsToIJAction().execute(trackmate)
>
> best
> jy
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://imagej.net/pipermail/imagej-devel/attachments/20150613/7b2e37b0/attachment.html>


More information about the ImageJ-devel mailing list