uniGradICON
uniGradICON copied to clipboard
first try failed.
This is my first try.... it seems the regularization is still a big issue....
Looks like this is a multi-modal test case. Can you run a case without instance optimization? If this works then it is possible that switching the similarity measure from 1-LNCC to 1-LNCC^2 for instance optimization could fix the issue.
Hi! As much as I bragged about getting spacing and orientation correct, it looks like I messed it up somewhere. Could you post the output of this program for the fixed and moving images?
import argparse
parser = argparse.ArgumentParser(description='info of a volume')
parser.add_argument('-w', action='store_true')
parser.add_argument('volumes', metavar='Volume', nargs='+',
help='volumes to investigate')
import SimpleITK as sitk
args = parser.parse_args()
for v in args.volumes:
reader = sitk.ImageFileReader()
reader.SetFileName(v)
reader.LoadPrivateTagsOn()
reader.ReadImageInformation()
print("=" * 30)
print(v)
if(args.w):
for k in reader.GetMetaDataKeys():
v = reader.GetMetaData(k)
print("({0}) = = \"{1}\"".format(k, v))
print("Image Size: {0}".format(reader.GetSize()))
print("Image PixelType: {0}"
.format(sitk.GetPixelIDValueAsString(reader.GetPixelID())))
print("Image Spacing: {0}".format(reader.GetSpacing()))
Our approach handles differences in spacing well, but not yet differences in axis orientation. The current best workaround when images have different axis orientations ( itk.Image.GetDirection() ) is to resample one image to the coordinate system of the other before registering. We hope to automate this process soon, but for now it can be handled with a call to unigradicon-warp to resample the image before calling unigradicon-register.
I've documented the issue and the fix in this notebook:
https://colab.research.google.com/drive/1CmbTUneDRAlOkjUjcOm8f9ebSOarZhT3?usp=sharing