[ITK] Bruker Format

Dženan Zukić dzenanz at gmail.com
Sat Feb 11 19:45:21 EST 2017


Hi Tobias,

you can see the inheritance
<https://itk.org/Doxygen/html/classitk_1_1ImageIOBase.html> diagram of
ImageIOs (you have to click to expand). If you want to have some things
common with NIFTIImageIO, you could create a new class (you could call it
RescalableImageBase or something like that), and have both Bruker and Nifti
inherit from it (similar to how a few IOs inherit from IPLCommonImageIO).
Of course, put common methods inside that class. But CastCopy and
RescaleFunction are so small that I don't think it is nearly worth the
effort.

Regards,
Dženan

On Sat, Feb 11, 2017 at 5:21 PM, Wood, Tobias <tobias.wood at kcl.ac.uk> wrote:

> Hi Dzenan,
>
> > In case that NIFTI reader detects it needs to do rescale/slope
> transformation (in function ReadImageInformation), it says that
> this->m_ComponentType=FLOAT, no matter what is the real component type on
> disk. Then Read reads the image data, converts it to float, does
> rescale/slope transformation in place (float to float).
>
> Thanks so much - I had missed this part. I have copied the NIFTI code, and
> the rescaling is working now. There are two functions (CastCopy and
> RescaleFunction) that I have copied & pasted - these could go into a common
> file somewhere, but I have no idea where is appropriate in the ITK
> heirarchy.
>
> > On 11/02/2017, 16:18, "Jon Haitz Legarreta" <jhlegarreta at vicomtech.org>
> wrote:
> > Hi Tobias,
> > if you are to move the classes out of review/external module, please
> provide a test (if it does not already exist).
> > I can help you if required. You can add me as a reviewer to the gerrit
> topic.
> > Kind regards,
> > JON HAITZ
>
> Hi Jon,
>
> There does not appear to be a meaningful test at the moment - only a
> skeleton file that doesn’t actually test anything. I would like to
> implement a test but I’m not planning on extending the class to be able to
> write as well as read Bruker.  I have no use case for this, and I doubt
> anyone else would either. Hence without checking an actual file into the
> repo I’m not sure what test would be useful?
>
> I will work on this code more before submitting it to gerrit - there are a
> lot of corner cases I haven’t implemented yet.
>
> Best wishes,
> Toby
>
> _______________________________________________
> Community mailing list
> Community at itk.org
> http://public.kitware.com/mailman/listinfo/community
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/community/attachments/20170211/a8866eda/attachment-0001.html>


More information about the Community mailing list