当前位置: 首页>>代码示例>>Python>>正文


Python ImagePlus.getStackSize方法代码示例

本文整理汇总了Python中ij.ImagePlus.getStackSize方法的典型用法代码示例。如果您正苦于以下问题:Python ImagePlus.getStackSize方法的具体用法?Python ImagePlus.getStackSize怎么用?Python ImagePlus.getStackSize使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在ij.ImagePlus的用法示例。


在下文中一共展示了ImagePlus.getStackSize方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。

示例1: StackCells

# 需要导入模块: from ij import ImagePlus [as 别名]
# 或者: from ij.ImagePlus import getStackSize [as 别名]

#.........这里部分代码省略.........
	def __boxaction5(self, event):
		self.__fire = event.getSource().isSelected()
		#self.__setDisplay(str(event.getSource().text)+" is "+str(event.getSource().isSelected()))

	def __boxaction6(self, event):
		self.__align = event.getSource().isSelected()
		#self.__setDisplay(str(event.getSource().text)+" is "+str(event.getSource().isSelected()))

	def __boxaction7(self, event):
		self.__enlarge = event.getSource().isSelected()
		#self.__setDisplay(str(event.getSource().text)+" is "+str(event.getSource().isSelected()))

	def __boxaction8(self, event):
		self.__measures = event.getSource().isSelected()
		#self.__setDisplay(str(event.getSource().text)+" is "+str(event.getSource().isSelected()))

	def __boxaction9(self, event):
		self.__alignC = event.getSource().isSelected()
		#self.__setDisplay(str(event.getSource().text)+" is "+str(event.getSource().isSelected()))
	
	def __boxaction10(self, event):
		self.__conEllipses = event.getSource().isSelected()
	
	def __favg(self) :
		zp = ZProjector(self.__impRes) 
		zp.setMethod(ZProjector.AVG_METHOD)
		zp.doProjection() 
		imp = zp.getProjection()
		imp.show()
		if self.__fire : IJ.run(imp, "Fire", "")

	def __fmosa(self) :
		mm = MontageMaker()
		imp = mm.makeMontage2(self.__impRes, 1, self.__impRes.getStackSize(), 1, 1, self.__impRes.getStackSize(), 1, 0, False)
		imp.setTitle("MONTAGE"+self.__name)
		imp.show()
		if self.__fire : IJ.run(imp, "Fire", "")

	def __fmaxfinder(self) :
		#stack = self.__impRes.getStack()
		self.__impD.killRoi()
		self.__impF.killRoi()
		stack = self.__impF.getStack()
		n_slices = stack.getSize()
		#newstack=ImageStack(self.__impRes.getWidth(), self.__impRes.getHeight())
		newstack=ImageStack(self.__impF.getWidth(), self.__impF.getHeight())
		noise = self.__display3.text
		for index in range(1,n_slices+1):
			IJ.selectWindow(self.__impF.getTitle())
			self.__impF.setSlice(index)
			ip = self.__impF.getProcessor()
			mf=MaximumFinder()
			ipmax = mf.findMaxima(ip, int(noise), 0, 0, False, False)
			newstack.addSlice("", ipmax)
			

		newimage=ImagePlus("max points"+self.__name, newstack)
		newimage.show()
		newimage.updateAndDraw()
		
		listip = []
		maxh=self.__impRes.getHeight()

		for roi in self.__cellsrois : 
			straightener = Straightener()
			newimage.setSlice(roi[1])
开发者ID:leec13,项目名称:MorphoBactDev,代码行数:70,代码来源:Stack_Cells.py


注:本文中的ij.ImagePlus.getStackSize方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。