<s> __all__ = [ '<STR_LIT>' , '<STR_LIT>' ] <EOL> try : <EOL> import SimpleITK as sitk <EOL> except ImportError : <EOL> raise ImportError ( "<STR_LIT>" <EOL> "<STR_LIT>" <EOL> "<STR_LIT>" <EOL> "<STR_LIT>" <EOL> "<STR_LIT>" <EOL> "<STR_LIT>" ) <EOL> def imread ( fname ) : <EOL> sitk_img = sitk . ReadImage ( fname ) <EOL> return sitk . GetArrayFromImage ( sitk_img ) <EOL> def imsave ( fname , arr ) : <EOL> sitk_img = sitk . GetImageFromArray ( arr , isVector = True ) <EOL> sitk . WriteImage ( sitk_img , fname ) </s>
