I have a home-made plugin coded in Jython, which source code resides in
Fiji.app>scripts>Plugins>MyPlugins such that I can call it like other plugin from the menu bar.
I can also drag and drop this code to open and run it in the script editor.
It is an object detector plugin and we found out that when we look for several objects the difference of speed is massive when the plugin is run from the script interpreter than from the menu bar:
it is much faster from the script interpreter!
From the menu bar, it is not slower because it is doing nothing, the computational load is high (fan speed increasing…)
And I’m not talking about a delay before the GUI pops up, it’s really the process itself which is slower eventhough it is the same piece of code and the same parameters (recalled by the persistence service).
I can’t share the code yet, but I was wondering what can be the reason for this.
One difference we observe is that when the plugin is executed from the menu bar, the call to the function
MaximumFinder().getMaxima() seems to be slower: the progress bar shows “Analyzing maxima…” for long, while from the script editor it is quickly disappearing.