<div dir="ltr"><div><div><div>Hi Tobias,<br></div>as for the testing, ITK will require an input file and checking that your contribution is working as expected, and that all new/refactored code is being covered by the test case.<br></div><div><br></div>I haven't had a look myself into the existing Bruker-related classes, and even if writing is not within your plans, if progress is made concerning the reading part, I think it is already worthwhile.<br><br></div><div>So sounds like a good plan; once you think you have 
something to share, submitting to gerrit will allow us to make further 
progress concerning the testing.<br><br></div><div>Kind regards,<br></div><div>JON HAITZ<br><br></div><div class="gmail_extra"><br clear="all"><div><div class="gmail_signature" data-smartmail="gmail_signature"><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr"><div dir="ltr"><table style="color:rgb(0,0,0);font-family:'Times New Roman';font-size:medium" cellspacing="0" cellpadding="0" border="0" align="center"><tbody><tr><td></td></tr></tbody></table><pre style="color:rgb(0,0,0);word-wrap:break-word;white-space:pre-wrap">--<br><br></pre><div><div dir="ltr"></div></div></div></div></div></div></div></div></div></div></div></div>
<br><div class="gmail_quote">On 12 February 2017 at 01:45, Dženan Zukić <span dir="ltr"><<a href="mailto:dzenanz@gmail.com" target="_blank">dzenanz@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div style="font-family:verdana,sans-serif;font-size:small">Hi Tobias,</div><div style="font-family:verdana,sans-serif;font-size:small"><br></div><div style="font-family:verdana,sans-serif;font-size:small">you can see the <a href="https://itk.org/Doxygen/html/classitk_1_1ImageIOBase.html" target="_blank">inheritance</a> 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.</div><div style="font-family:verdana,sans-serif;font-size:small"><br></div><div style="font-family:verdana,sans-serif;font-size:small">Regards,</div><div style="font-family:verdana,sans-serif;font-size:small">Dženan</div></div><div class="gmail_extra"><br><div class="gmail_quote"><div><div class="h5">On Sat, Feb 11, 2017 at 5:21 PM, Wood, Tobias <span dir="ltr"><<a href="mailto:tobias.wood@kcl.ac.uk" target="_blank">tobias.wood@kcl.ac.uk</a>></span> wrote:<br></div></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div><div class="h5">Hi Dzenan,<br>
<span><br>
> 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).<br>
<br>
</span>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.<br>
<br>
> On 11/02/2017, 16:18, "Jon Haitz Legarreta" <<a href="mailto:jhlegarreta@vicomtech.org" target="_blank">jhlegarreta@vicomtech.org</a>> wrote:<br>
> Hi Tobias,<br>
> if you are to move the classes out of review/external module, please provide a test (if it does not already exist).<br>
> I can help you if required. You can add me as a reviewer to the gerrit topic.<br>
> Kind regards,<br>
> JON HAITZ<br>
<br>
Hi Jon,<br>
<br>
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?<br>
<br>
I will work on this code more before submitting it to gerrit - there are a lot of corner cases I haven’t implemented yet.<br>
<br>
Best wishes,<br>
</div></div><div class="m_758280539080493685HOEnZb"><div class="m_758280539080493685h5">Toby<br>
<br><span class="">
______________________________<wbr>_________________<br>
Community mailing list<br>
<a href="mailto:Community@itk.org" target="_blank">Community@itk.org</a><br>
<a href="http://public.kitware.com/mailman/listinfo/community" rel="noreferrer" target="_blank">http://public.kitware.com/mail<wbr>man/listinfo/community</a><br>
</span></div></div></blockquote></div><br></div>
</blockquote></div><br></div></div>