pyelastix.py 文件源码

python
阅读 44 收藏 0 点赞 0 评论 0

项目:pyelastix 作者: almarklein 项目源码 文件源码
def _get_fixed_params(im):
    """ Parameters that the user has no influence on. Mostly chosen
    bases on the input images.
    """

    p = Parameters()

    if not isinstance(im, np.ndarray):
        return p

    # Dimension of the inputs
    p.FixedImageDimension = im.ndim
    p.MovingImageDimension = im.ndim

    # Always write result, so I can verify
    p.WriteResultImage = True

    # How to write the result
    tmp = DTYPE_NP2ITK[im.dtype.name]
    p.ResultImagePixelType = tmp.split('_')[-1].lower()
    p.ResultImageFormat = "mhd"

    # Done
    return p
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号