User Tools

Site Tools


documents:120206pyip_cooking:python_imagej_cookbook

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
documents:120206pyip_cooking:python_imagej_cookbook [2018/07/15 17:23]
kota [Particle Analysis]
documents:120206pyip_cooking:python_imagej_cookbook [2018/07/19 07:43] (current)
kota [Plugin: LOCI BioFormats, Replacing OME-TIFF XML]
Line 1522: Line 1522:
 cm.setPointSize(3) cm.setPointSize(3)
 </​code>​ </​code>​
-===== Plugin: LOCI BioFormats, Replacing OME-TIFF XML =====+===== Plugin: LOCI BioFormats ​===== 
 + 
 +==== Importing CZI file ==== 
 + 
 +<code python linenums:​1>​ 
 +from loci.plugins import BF 
 +from loci.plugins.in import ImporterOptions 
 + 
 +filepath = "/​path/​to/​image/​my.czi"​ 
 + 
 +# Options for Bioformats pluginincludeing the image path 
 +options = ImporterOptions() 
 +options.setOpenAllSeries(True) 
 +options.setShowOMEXML(False) 
 +options.setStitchTiles(False) 
 +options.setId(filepath) 
 +     
 +fullimps = BF.openImagePlus(options) 
 + 
 +#fullimps now holds multiple images contained within the czi file.  
 +# open the first one.  
 +fullimps[0].show() 
 +</​code>​ 
 + 
 +See here for more on metadata parsing and so on: [[https://​gist.github.com/​ctrueden/​6282856|bio-formats.py]] 
 + 
 +==== Replacing OME-TIFF XML ====
  
 <code python linenums:​1>​ <code python linenums:​1>​
documents/120206pyip_cooking/python_imagej_cookbook.txt · Last modified: 2018/07/19 07:43 by kota