imagej / imagej-server

A RESTful web server for ImageJ [EXPERIMENTAL]
Apache License 2.0
38 stars 17 forks source link

How do I run an ijm script? #43

Open kylegalloway opened 3 years ago

kylegalloway commented 3 years ago

I'm attempting to run an ijm script by changing the example that runs a python script.

The script I'm attempting to run is as follows:

run("Set Scale...", "distance=4.585 known=1 pixel=1 unit=µm");
setAutoThreshold("MaxEntropy dark");
setOption("BlackBackground", true);
run("Convert to Mask");
run("Despeckle");
run("Watershed");
run("Analyze Particles...", "size=16-Infinity circularity=0.50-1.00 display exclude summarize");

I tried setting language to ijm and in1 to the script but that caused an error. I tried escaping the quotes, parentheses, and replacing the newlines with \n and that still caused an error. I tried changing in1 to be script and removing in2 and I'm still seeing errors.

Any help would be appreciated.