label image thumbnail not displayed correctly

287 views
Skip to first unread message

Michelle Somerville

unread,
Jul 4, 2018, 6:28:51 AM7/4/18
to QuPath users
Hi there,

Apologies if someone has already asked this question before.

We are generating CZI files using a Zeiss Axioscan Z1 slide scanner. 
Qupath has been great for allowing our users to view our CZI files and we're hoping to use more of the functionality over time, so thank you. It's especially useful for our mac users as the Zeiss software Zen is not compatible with mac computers. However we find that the label image thumbnail never displays correctly within Qupath and is just black. The same file opened on Zen software shows the correct label image so it has been saved as part of the CZI file.
Is there any way of fixing this? The Zen software on the slide scanner is very clumsy when it comes to labelling so all the files are designated number and date so what we're having to do at the moment is open files in Zen re-label them and then open in Qupath but it would be great if we can just use Qupath.

Best wishes,

Michelle

Pete

unread,
Jul 4, 2018, 6:38:52 AM7/4/18
to QuPath users
I've noticed this too, but I didn't previously have access to a Windows computer with Zen to see how it is supposed to look... and no one had asked, so I gave up fairly quickly.

I'll have another go at this soon with a bit more determination now that I know it's important.  Just one thing: does this applied to both brightfield and fluorescence images, or only fluorescence?

From what I've seen, requesting the thumbnail from Bio-Formats produces a very low-contrast image that appears all black - and QuPath makes no effort to correct for this.  I've directly saved the image or sent it to ImageJ (by scripting in a very hack-y way, there's no direct way to do it in QuPath) just to see if there is any information there, and there is... although as I recall I think it's grayscale, and very very dark.

One small thing: you might want to check out https://petebankhead.github.io/qupath/2018/03/19/qupath-updates.html
Among the experimental changes there, QuPath will at least generate a more sensible thumbnail for fluorescence images when adding them to a project, while in v0.1.2 this also tends to be all dark (at least for 16-bit images).  This might help with your .czi experience with QuPath in general, although I understand you're interested specifically in the scanned label and that isn't addressed yet.

Pete

unread,
Jul 4, 2018, 8:53:38 AM7/4/18
to QuPath users
I checked again and I was wrong in my grayscale memory, although the label does seem to be 16-bit.

Anyhow, as a temporary workaround you can try this script: https://gist.github.com/petebankhead/863352f92d17facb15bb5cf35ed03f56

It should extract the label, and show it in ImageJ - with the contrast enhanced.  Therefore by running the script with a .czi image open in QuPath, hopefully it gives an alternative way to view the label without needing to open it in Zen.

Please let me know if this works and I can try to get the fix in a future QuPath release.

Michelle Somerville

unread,
Jul 4, 2018, 10:13:41 AM7/4/18
to QuPath users
Hi Pete,

Thanks so much for sorting the workaround so quickly that seems to work for both brightfield and fluorescence as I was having trouble with both. I was having problems with fluorescence even though I'm pretty sure I have v 0.0.6 extension installed - I dragged the new extension onto Qupath just to make sure.
I've attached a snip of how a label thumbnail looks in Zen so you could see, and how the workaround in Qupath looks.
In Zen there are two image files saved under an info tab, one is a label and one is of the slide. These are generated during the preview scan when the tissue detection takes place.

Thanks again for your help.

Michelle

Qupath thumbnail.PNG
Zen thumbnail.PNG

Pete

unread,
Jul 4, 2018, 11:22:35 AM7/4/18
to QuPath users
Hi Michelle,
Thanks, you can get the other image is you change the bit of the script that says 'label' to read 'macro'.
This is helpful, now it's clearer to me what I'm aiming for.  I'll have a look at getting it into the main software properly (with less aggressive contrast settings than those in the script).
Best wishes,
Pete
Reply all
Reply to author
Forward
0 new messages