Re: Problems While Using Command Line
Posted by
ctrueden on
Mar 20, 2008; 4:08pm
URL: http://imagej.273.s1.nabble.com/Loosing-Particles-when-Rotating-Image-tp3696797p3696800.html
Hi Alphonso,
By default, ImageJ looks for plugins in the plugins subfolder of the current
working directory. The problem you describe sounds like your working
directory is different than /Applications/ImageJ.
I tried "cd /Applications/ImageJ; java -jar ij" on my Mac and the plugins
show up.
However, from my home directory, "java -jar /Applications/ImageJ/ij.jar"
results in an empty plugins list.
It is also possible to manually specify the path to the plugins folder. The
following works on my machine regardless of the current working directory:
java -Dplugins.dir=/Applications/ImageJ/plugins -jar
/Applications/ImageJ/ij.jar
-Curtis
On Thu, Mar 20, 2008 at 10:48 AM, Alphonso Magri <
[hidden email]> wrote:
> I am attempting to run a custom made plugin on many different image
> sets and tried making a macro to do this. I found that after the
> second image set ImageJ crashes. The image sets are very large so this
> crash usually occurs after 1.5 days of running. I then looked for an
> automated way to open ImageJ, run the plugin twice, then close imageJ
> and repeat the process. I found that I can use a terminal on my Mac
> and call ImageJ and a macro. I do so by typing something like...
>
> "cd /Applications/ImageJ_1_37; java -jar ij.jar -batch Trial_run_1".
>
> I found that this can work for macros that do not call custom made
> plugins, and when I try to call my plugin from the macro which I call
> from the command line I get an error like...
>
> "Unrecognized command: Fitting algo", where Fitting algo is the name
> of my custom plugin.
>
> Why is it incapable of recognizing the plugin?
>
> The plugin is already complied and has a class file. To add to my
> confusion when I double click on the ij.jar file I get ImageJ with a
> plugins tab pull down menu full of plugins, however when I call ImageJ
> from the command line I find that the pull down menu for the plugins
> tab empty of plugins.
>
> Is there a way to call ImageJ from the Command line and being able to
> recognize custom plugins? Does anyone have another suggestion to solve
> my problem?
>
> Alphonso
>