[Insight-developers] astronomy images, SpecialCoordinatesImage and ImageIO

Kent Williams kent at psychiatry.uiowa.edu
Wed Aug 30 10:36:48 EDT 2006


Understood.  You will need to take special care of a couple of things at 
the application level: ensuring that the output images of a pipeline 
gets tagged with the proper astronomical coordinates, since the pipeline 
mechanism doesn't know it exists, and making sure that any filters that 
actually change the direction cosines are doing the right thing.

Michael Halle wrote:

> Kent Williams wrote:
>
>> You seem to be conflating two things that should be considered as 
>> separate issues.
>>
>> For ImageIO you need to do these things to produce properly oriented 
>> images.
>>
>> 1. Set the image origin in world (or patient) coordinates. This is 
>> well-defined for medical images; for Astronomy, you need to choose a 
>> convention and stick with it.
>> 2. Set the Direction Cosines for the image. This is 3 vectors 
>> representing the orthogonal X,Y, and Z images -- basically describing 
>> the way the local coordinate system of the image data is rotated from 
>> the canonical world coordinate system vectors.
>
>
> The point of distinction between astronomy and medical imaging is that 
> the coordinate systems in astronomy are usually spherical (right 
> ascension and declination), and that there are fifteen different 
> projections that convert from index to physical.  There is no 
> direction cosine approximation that works well enough for us, and the 
> projections are exceedingly complex and specialized.
>
> That's why, ultimately, we need to delegate to an implementation 
> library to do that work for us using function/method calls.  It may 
> not be as fast as the direction cosine approach, but for many 
> non-linear spaces it's basically what you need.
>
> It's not so hard to use the metadata dictionary to pass parameters 
> from  ImageIO to a new Image subclass, which will then set up its 
> transforms.  It's just less generic then the current direction 
> cosine-based approach (since you need to have new ImageIO and Image 
> subclasses).



More information about the Insight-developers mailing list