Leica .lif metadata - Fiji - extracting laser settings for multiple channels?


Perhaps the question relates more to Leica metadata specifications, but I hope it’s the right place to ask.

I have recently started with imaging experiments, and I’m looking for a way to organize my data. The simplest thing I can think of is to make an excel table with some overview pictures together with microscope settings and protocols. I would like to access the settings stored in .lif file.

When I open .lif files in Fiji I have an option to see two different sets of metadata, one is “Display Metadata”, another is “Display OME-XML metadata”. When opening a .lif file that contains few image stacks, each with 4 channels, in the “OME-XML metadata” I am able to see some of the device information, including the four lasers involved in each series, but without the intensity information; further below I can see a lot of positional information for each series, which I don’t need. This output resembles “metadata” available in LAS AF viewer from Leica when I go to stack properties.

When I check “Display Metadata” I am presented with a two columns table where first column contains a parameter and the second its value. There I am able to see some more detailed information, including laser settings - however, it only lists information for one laser, which happens to be the one used to collect the last channel in series, or maybe the last image in series of four. I could use this table if it had information about other three lasers/channels as well, but I can’t find a way to extract it (Perhaps because the table is overwritten somewhere during parsing? I have no idea).

The information should be in there, because LAS software which controls the microscope is able to fetch and recreate laser settings from any .lif file you give it. I was wondering, if there’s a way to do the same in Fiji, since I already see some of that data, just not all of it.

Hi @Dmitry, normally you should find all the available metadata values from the file under “Display Metadata”, however it sounds as if Bio-Formats has missed some of the values for the earlier series. Would you be able to upload the sample file for us to test to https://www.openmicroscopy.org/qa2/qa/upload/?

Hi! Unfortunately I don’t have OMERO set up, and I’m not familiar with it. I presume the link only works together with that environment?

I think I was able to upload an example.

Thanks Dmitry, we received the sample file ok and I was able to reproduce the bug with the latest Bio-Formats. I have opened a GiHub Issue for this bug at https://github.com/ome/bioformats/issues/3513

I’m bumping this topic to add that this seems to happen to other per-channel metadata as well (such as exposure time).

Thanks for the report @erickratamero, is this affecting all per-channel metadata or just select values? If you have any samples showing exposure or other metadata being overridden would you also be able to upload them to https://www.openmicroscopy.org/qa2/qa/upload/?

It seems to me that all per-channel metadata (e.g. Emission Wavelength, Exposure, etc etc) is affected, but I haven’t checked each individual field extensively. Maybe related: it seems that exposure time, for example, is set to the same value for all individual captures/series inside the .lif file, despite each capture having its own exposure time (verified with Leica’s own software). Sample file uploaded.

Thanks @erickratamero for the extra sample file, those are always a great help for debugging these issues. I will try to keep both the GitHub Issue and this thread updated with any new information as I try to find a fix.