spatial_image_analysis.py 文件源码

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

项目:tissue_analysis 作者: VirtualPlants 项目源码 文件源码
def real_indices(slices, resolutions):
    """
    Transform the discrete (voxels based) coordinates of the boundingbox (`slices`) into their real-world size using `resolutions`.

    Args:
       slices: (list) - list of slices or boundingboxes found using scipy.ndimage.find_objects;
       resolutions: (list) - length-2 (2D) or length-3 (3D) vector of float indicating the size of a voxel in real-world units;
    """
    return [ (s.start*r, s.stop*r) for s,r in zip(slices,resolutions) ]
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号