Annotation.py 文件源码

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

项目:pylidc 作者: pylidc 项目源码 文件源码
def estimate_surface_area(self):
        """
        Estimate the surface area by summing the areas of a trianglation
        of the nodules surface in 3d. Returned units are mm^2.
        """
        mask = self.get_boolean_mask()
        mask = np.pad(mask, [(1,1), (1,1), (1,1)], 'constant') # Cap the ends.
        dist = dtrans(mask) - dtrans(~mask)

        rxy  = self.scan.pixel_spacing
        rz   = self.scan.slice_thickness
        verts, faces, _, _ = marching_cubes(dist, 0, spacing=(rxy, rxy, rz))
        return mesh_surface_area(verts, faces)
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号