本文整理汇总了Python中pylinac.core.image.Image.from_multiples方法的典型用法代码示例。如果您正苦于以下问题:Python Image.from_multiples方法的具体用法?Python Image.from_multiples怎么用?Python Image.from_multiples使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类pylinac.core.image.Image
的用法示例。
在下文中一共展示了Image.from_multiples方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: test_combine_multiples
# 需要导入模块: from pylinac.core.image import Image [as 别名]
# 或者: from pylinac.core.image.Image import from_multiples [as 别名]
def test_combine_multiples(self):
bad_img_path = [dcm_path, img_path]
self.assertRaises(AttributeError, Image.from_multiples, bad_img_path)
good_img_path = [img_path, img_path]
combined_img = Image.from_multiples(good_img_path)
self.assertIsInstance(combined_img, Image)
示例2: load_multiple_images
# 需要导入模块: from pylinac.core.image import Image [as 别名]
# 或者: from pylinac.core.image.Image import from_multiples [as 别名]
def load_multiple_images(self, filepath_list):
"""Load multiple images via the file path.
.. versionadded:: 0.5.1
Parameters
----------
filepath_list : sequence
An iterable sequence of filepath locations.
"""
self.image = Image.from_multiples(filepath_list)
示例3: load_multiple_images
# 需要导入模块: from pylinac.core.image import Image [as 别名]
# 或者: from pylinac.core.image.Image import from_multiples [as 别名]
def load_multiple_images(self, path_list):
"""Load and superimpose multiple images.
.. versionadded:: 0.9
Parameters
----------
path_list : iterable
An iterable of path locations to the files to be loaded/combined.
"""
self.image = Image.from_multiples(path_list, method='mean')
self._check_for_noise()
self.image.check_inversion()