Hi Chunyue,
If I understand, you have 2 opened windows "stack1.tif" and
"AVG_stack1.tif", you need to specify the source and target from ' -file '
to ' -window '. file paths do not matter.
I am not sure that TurboReg can do alignment for a stack, but a single
slice should be fine.
Yuekan
On Fri, Dec 2, 2016 at 11:49 PM, LCY <[hidden email]> wrote:> *This is how I do that* :
> Hi Curtis,
>
> Thank you very much for your help!
>
> This is what I have: window 10 system, Matlab 2015b, Fiji(based on java 6)
> which I store in "C:\Users\[my name]\Fiji.app".
>
> I want to do matching among many tiff stacks. Because my other codes are
> programmed by Matlab, I want to use TurboReg plugin from Matlab to process
> these files automatically.
>
> step 1: update Fiji as you suggested;> *The results showed in ImageJ Exception are as follow:*
> step 2: add path in Matlab:"C:\Users\[my name]\Fiji.app\scripts"
> step 3: start Fiji in my Matlab code by using the command "Miji;"
> step 4: open one tiff stack file by using "MIJ.run('Open...',
> ['path=','F:\TwoPhotonfile\stack1.tif']);"
> step 5: normalize and average my tiff stack file by using
> MIJ.run('Open...',...) and MIJ.run('Enhance Contrast...',..) separately.
> step 6: now there are two opened windows, one is the normalized tiff stack
> file, the other is the averaged image file (contains only one image)
> step 7: do matching by using
> " MIJ.run('TurboReg ', ['-align ', '-file ','stack1.tif',' ','0 0
> ',num2str(width),' ',num2str(height),' ',...
> '-file ','AVG_stack1.tif',' ','0 0 ',num2str(width),'
> ',num2str(height),' ','-rigidBody ',num2str(width/2),...
> ' ',num2str(height/2),' ',num2str(width/2),' ',num2str(height/2),' ','0
> ',num2str(height/2),' ','0 ',...
> num2str(height/2),' ',num2str(width-1),' ',num2str(height/2),'
> ',num2str(width-1),' ',num2str(height/2),' ','-showOutput']); "
>
> "ImageJ 1.50e; Java 1.7.0_60 [64-bit]; Windows 8 6.2; 178MB of 3725MB (4%)> *This is what I have done:*
>
> java.lang.NullPointerException
> at TurboReg_.alignImages(TurboReg_.java:893)
> at TurboReg_.run(TurboReg_.java:636)
> at ij.IJ.runUserPlugIn(IJ.java:212)
> at ij.IJ.runPlugIn(IJ.java:176)
> at ij.Executer.runCommand(Executer.java:136)
> at ij.Executer.run(Executer.java:65)
> at ij.IJ.run(IJ.java:292)
> at MIJ.run(MIJ.java:1171)"
>
>> --
> I try to change the source path to 'F:\TwoPhotonfile\stack1.tif', but this
> doesn' t work;
> I double clicked the information in Exception window, it showed "file is
> not
> in a supported format, a reader plugin is not available, or it was not
> found". But, this plugin works when I use it manually.
>
> Thank you for your help, Curtis!
>
> All the best,
>
> Chunyue
>
>
>
>
>
>
>
>
>
> View this message in context: http://imagej.1557.x6.nabble.
> com/Cannot-use-TurboReg-plugin-by-using-matlab- tp5017668p5017679.html
> Sent from the ImageJ mailing list archive at Nabble.com.
>
> --
> ImageJ mailing list: http://imagej.nih.gov/ij/list.html
>
--
ImageJ mailing list: http://imagej.nih.gov/ij/list.html
If you reply to this email, your message will be added to the discussion below:http://imagej.1557.x6.nabble.com/Cannot-use-TurboReg- plugin-by-using-matlab- tp5017668p5017688.html
Free forum by Nabble | Disable Popup Ads | Edit this page |