[ITK] [ITK-users] simpleitk image casting?

Robert.Atwood at diamond.ac.uk Robert.Atwood at diamond.ac.uk
Mon May 19 13:25:18 EDT 2014


Hi,
I have just discovered the iPython + simpleITK combination and may very well reduce a lot of barriers to the general use of ITK here by virtue of being 'simple' and working very well with NumPy 


However, I was just trying to implement a relatively simple algorithm previously programmed not using ITK at all .. in this I require the results of the gradient filter interpreted such that the horizontal gradient is the real part of a complex number and the vertical gradient is the imaginary part. I cannot figure out a 'simple' way to do this, can this be done within sitk or must I extrac the array , manipulate it in Numpy , and load it back as an  (complex) image?  Then the script is much less 'simple'!

Thanks in advance 
A SimpleITK convert ! 

Robert
 



-- 
This e-mail and any attachments may contain confidential, copyright and or privileged material, and are for the use of the intended addressee only. If you are not the intended addressee or an authorised recipient of the addressee please notify us of receipt by returning the e-mail and do not use, copy, retain, distribute or disclose the information in or attached to the e-mail.
Any opinions expressed within this e-mail are those of the individual and not necessarily of Diamond Light Source Ltd. 
Diamond Light Source Ltd. cannot guarantee that this e-mail or any attachments are free from viruses and we cannot accept liability for any damage which you may sustain as a result of software viruses which may be transmitted in or with the message.
Diamond Light Source Limited (company no. 4375679). Registered in England and Wales with its registered office at Diamond House, Harwell Science and Innovation Campus, Didcot, Oxfordshire, OX11 0DE, United Kingdom
 



_____________________________________
Powered by www.kitware.com

Visit other Kitware open-source projects at
http://www.kitware.com/opensource/opensource.html

Kitware offers ITK Training Courses, for more information visit:
http://www.kitware.com/products/protraining.php

Please keep messages on-topic and check the ITK FAQ at:
http://www.itk.org/Wiki/ITK_FAQ

Follow this link to subscribe/unsubscribe:
http://www.itk.org/mailman/listinfo/insight-users


More information about the Community mailing list