NOTICE! This is a static HTML version of a legacy Fiji BugZilla bug.

The Fiji project now uses GitHub Issues for issue tracking.

Please file all new issues there.

Bug 442 - registration failure causes crash
registration failure causes crash
Status: RESOLVED WORKSFORME
Product: Fiji
Classification: Unclassified
Component: Plugins
unspecified
PC Windows
: P4 normal
Assigned To: ImageJ Bugs Mailing List
Depends on:
Blocks:
 
Reported: 2012-06-23 23:03 CDT by Stan Kruger
Modified: 2012-09-18 20:24 CDT
2 users (show)

See Also:

Description Stan Kruger 2012-06-23 23:03:56 CDT
When running a bunwarpj registration, if the registration fails to complete for whatever reason, fiji locks up on the 'stop' symbol and I must restart fiji before I can continue to work.  Included is the code that causes the crash.  The data I'm loading is of length 256^3 uint32 (I suspect the bit depth is what's causing the registartion to fail, but that isn't my concern).

Thanks,

Stan Kruger

// Macro to perform 3D registration in a 2D Stack method

airdir = getDirectory("Choose a Target Directory");
airlist = getFileList(airdir);
oxydir = getDirectory("Choose a Source Directory");
oxylist = getFileList(oxydir);

for (i=0; i<256; i++ ) {
	ofnew = i*65536*4; //256 x 256 * bytedepth
	print(i);
	run("Raw...", "open=[" + airdir + airlist[0] + "] image=[32-bit Unsigned] width=256 height=256 offset=ofnew number=1 gap=0 little-endian");
	rename("air");
	run("Raw...", "open=[" + oxydir + oxylist[0] + "] image=[32-bit Unsigned] width=256 height=256 offset=ofnew number=1 gap=0 little-endian");
	rename("oxy");
	run("Extract SIFT Correspondences", "source_image=oxy target_image=air initial_gaussian_blur=1.60 steps_per_scale_octave=3 minimum_image_size=64 maximum_image_size=1024 feature_descriptor_size=4 feature_descriptor_orientation_bins=8 closest/next_closest_ratio=0.92 filter maximal_alignment_error=25 minimal_inlier_ratio=0.05 minimal_number_of_inliers=7 expected_transformation=Rigid");
	run("bUnwarpJ", "source_image=oxy target_image=air registration=Mono image_subsample_factor=0 initial_deformation=[Very Fine] final_deformation=[Super Fine] divergence_weight=0.5 curl_weight=0.5 landmark_weight=1 image_weight=1 consistency_weight=10 stop_threshold=0.01");

	selectWindow("air");
	close();
	selectWindow("oxy");
	close();

	selectWindow("Registered Source Image");
	run("Stack to Images");
	selectWindow("Warped Source Mask");
	close();

	if (i == 0) {
		selectWindow("Target Image");
		rename("airstack");
		selectWindow("Registered Source Image");
		rename("oxystack");
	} else { 
		run("Concatenate...", "  title=airstack image1=airstack            image2=[Target Image]  image3=[-- None --]");
		run("Concatenate...", "  title=oxystack image1=oxystack image2=[Registered Source Image]  image3=[-- None --]");
	}
}

selectWindow("airstack");
saveAs("Raw Data", "\\\\mpfsv\\Home\\sjkruger\\My Documents\\work\\O2\\SS2\\S05_1\\testreg_UTE\\reg\\air_reg.dat");
selectWindow("oxystack");
saveAs("Raw Data", "\\\\mpfsv\\Home\\sjkruger\\My Documents\\work\\O2\\SS2\\S05_1\\testreg_UTE\\reg\\oxy_reg.dat");
Comment 1 Johannes Schindelin 2012-06-24 05:17:15 CDT
Please click on Help>Report a bug and copy the information generated by Fiji. From your macro, one can guess that you are on Windows, but guessing is not a sensible game when we try to fix problems in our scarce time.

In the same spirit, could you verify that the problem also occurs with really small images? If so, you might want to provide a .zip file with all the files. Remember, the simpler you make it to reproduce your problem, the more likely some developer will go and try to help.
Comment 2 Johannes Schindelin 2012-09-18 20:24:06 CDT
I am closing this bug until there is an easy way to reproduce (such as the suggested small .zip file setting up a directory structure which demonstrates the issue).