ome2singletiff error on windows, histocat conversion errors

Looking for ways to analyze your dataset? Need help with a software package?
Computational image analysis of multiplexed Imaging Mass Cytometry acquisitions
Post Reply
arcolombo698
Posts: 1
Joined: Wed Aug 01, 2018 8:41 pm

ome2singletiff error on windows, histocat conversion errors

Post by arcolombo698 » Wed Aug 01, 2018 8:56 pm

Hi this is a re-post from the github issue #27 that I opened.
https://github.com/BodenmillerGroup/imctools/issues/27

Hello. I am working on the IMCpipeline and the imc2tiff conversion successfully completed!
However when I issue the command to convert the ome.tiffs to HistoCAT compatible files, there is an error in the script ome2singletiff.

From the Jupyter IMCpipeline, I am working off the IMCpipeline in particular the histoCAT section:
if do_histocat:
if not(os.path.exists(folder_histocat)):
os.makedirs(folder_histocat)
ome2micat.omefolder2micatfolder(folder_ome, folder_histocat, dtype='uint16')
I do have the imctools with this script successfully installed.
python -m imctools.scripts.ome2micat -h
usage: ome2micat [-h] [--mask_folder MASK_FOLDER] [--mask_suffix MASK_SUFFIX]
[--imagetype {None,uint16,int16,float}]
ome_folder out_folder
Convertes an ome folder (or file) to a micat folder
positional arguments:
ome_folder A folder with ome images or a single ome file
out_folder Folder to output the micat folders

optional arguments:
-h, --help show this help message and exit
--mask_folder MASK_FOLDER
Folder containing the masks, or single mask file.
--mask_suffix MASK_SUFFIX
suffix of the mask tiffs
--imagetype {None,uint16,int16,float}
The output image type
##################
When I execute the command "ome2micat.omefolder2micatfolder(folder_ome, folder_histocat, dtype='uint16')
" I receive an error.

parameters folder_ome:
'C:/Users/Mohan/Desktop/testing/OUTPUT\ometiff'
parameters folder_histocat:
'C:/Users/Mohan/Desktop/testing/OUTPUT\histocat'

TRACEBACK:
ome2micat.omefolder2micatfolder(folder_ome, folder_histocat, dtype='uint16')
Traceback (most recent call last):
File "", line 1, in
File "C:\Users\Mohan\Anaconda3\lib\site-packages\imctools\scripts\ome2micat.py", line 72, in omefolder2micatfolder
ome2micatfolder(path_ome, outfolder, path_mask=path_mask, dtype=dtype)
File "C:\Users\Mohan\Anaconda3\lib\site-packages\imctools\scripts\ome2micat.py", line 39, in ome2micatfolder
ome2singletiff(path_ome, outfolder,basename='', dtype=dtype)
File "C:\Users\Mohan\Anaconda3\lib\site-packages\imctools\scripts\ome2micat.py", line 15, in ome2singletiff
ome = ometiffparser.OmetiffParser(path_ome)
File "C:\Users\Mohan\Anaconda3\lib\site-packages\imctools\io\ometiffparser.py", line 22, in init
self.read_image(original_file)
File "C:\Users\Mohan\Anaconda3\lib\site-packages\imctools\io\ometiffparser.py", line 46, in read_image
self.ome = tif.pages[0].tags['image_description'].value
KeyError: 'image_description'
I have tifffile installed
tifffile 0.15.1 py36_1 conda-forge

python -V
Python 3.6.4 :: Anaconda, Inc.

I have CellProfiler Desktop app installed version 2.2.0.
My question is that the error is related to ometiffparser, how can I debug this? is this related to my tifffile version? What should be the dtype parameter for a windows OS?

Thank you very much,

SIncerely,
AC
User avatar
votti
Posts: 26
Joined: Mon Nov 27, 2017 12:46 pm

Re: ome2singletiff error on windows, histocat conversion errors

Post by votti » Tue Aug 07, 2018 8:59 am

Hi there,

I refer to our discussion on Github: https://github.com/BodenmillerGroup/imctools/issues/27
Short summary: The error was already recognized in fixed in the development version that can be installed via:

Code: Select all

pip install git+https://github.com/BodenmillerGroup/imctools.git@development
Post Reply