[ome-devel] OME metadata in Micro-Manager

Melissa Linkert melissa at glencoesoftware.com
Tue May 19 23:49:12 BST 2015


Hi Chris,

> In brief: Micro-Manager contains code for writing OME metadata, none of us
> understand it, and it doesn't always work; help?
> 
> We at Micro-Manager recently discovered that we're using a badly
> out-of-date version of the OME metadata libraries. I don't know exactly
> what the version is, but it's still under the loci.common / loci.formats
> namespace. This breaks our compatibility with Fiji (at least when it comes
> to trying to save multipage TIFF files), which is pretty unfortunate.

loci.common and loci.formats are package names that are still used in
the latest version (5.1.1).  If all else fails, the value of the
'VERSION' constant in loci.formats.FormatTools should indicate which
version you have.

> Additionally, when bugs pop up, we're rather at sea. For example, I
> recently discovered that we get an ArrayIndexOutOfBoundsException when
> calling MetadataTools.populateMetadata() if the "series" parameter is not
> provided "in order" (that is, if we hand it 1 first then it errors; if we
> hand it 0 and then 1 then everything is fine). It took me a long time to
> even figure that much out, because the error contained no explanation; I
> had to compare the values of the arguments across multiple versions of
> Micro-Manager and play "spot the difference".
>
> Ideally, we'd patch our OME metadata-writing code so it could handle the
> "unordered" case cleanly, but I'm not confident in my ability to change
> this code without introducing potentially-subtle bugs. In fact, none of us
> have any working knowledge of the OME library; apparently our
> implementation was written for us by Melissa Linkert.

To clarify, I didn't write this code specifically, but I do remember
answering a number of questions regarding OME-TIFF creation in Micro-Manager
circa 2012.

> Micro-Manager doesn't actually read the OME metadata itself; it's present
> solely so that other programs can load some of our metadata. We'd like to
> upgrade our libraries to something more modern, but documentation appears
> to be scarce, and I wouldn't really know where to get started. Any advice
> would be appreciated.

If you haven't already, the best place to start reading would be the
following:

- example of how to save pixel data as OME-TIFF:
  http://www.openmicroscopy.org/site/support/bio-formats5.1/developers/export2.html

- overview of the current OME-XML schema (2015-01):
  http://www.openmicroscopy.org/site/support/ome-model/

- Bio-Formats Javadocs:
  http://downloads.openmicroscopy.org/bio-formats/5.1.1/api/
  http://downloads.openmicroscopy.org/bio-formats/5.1.1/api/index.html?ome/xml/model/package-use.html
  http://downloads.openmicroscopy.org/bio-formats/5.1.1/api/ome/xml/meta/MetadataStore.html

Note that the documentation for ome.xml.meta.MetadataStore warns against
populating metadata in a non-linear order; if you wish to populate
metadata in any other order, you may have better luck using the
ome.xml.model package directly (MetadataStore/MetadataTools is a
front-end for this).  See also:

http://www.openmicroscopy.org/site/support/ome-model/ome-xml/java-library.html

If you have any questions that aren't answered by those pages, please
let us know.

Regards,
-Melissa


On Mon, May 18, 2015 at 02:33:58PM -0700, Chris Weisiger wrote:
> Hello all,
> 
> In brief: Micro-Manager contains code for writing OME metadata, none of us
> understand it, and it doesn't always work; help?
> 
> We at Micro-Manager recently discovered that we're using a badly
> out-of-date version of the OME metadata libraries. I don't know exactly
> what the version is, but it's still under the loci.common / loci.formats
> namespace. This breaks our compatibility with Fiji (at least when it comes
> to trying to save multipage TIFF files), which is pretty unfortunate.
> 
> Additionally, when bugs pop up, we're rather at sea. For example, I
> recently discovered that we get an ArrayIndexOutOfBoundsException when
> calling MetadataTools.populateMetadata() if the "series" parameter is not
> provided "in order" (that is, if we hand it 1 first then it errors; if we
> hand it 0 and then 1 then everything is fine). It took me a long time to
> even figure that much out, because the error contained no explanation; I
> had to compare the values of the arguments across multiple versions of
> Micro-Manager and play "spot the difference".
> 
> Ideally, we'd patch our OME metadata-writing code so it could handle the
> "unordered" case cleanly, but I'm not confident in my ability to change
> this code without introducing potentially-subtle bugs. In fact, none of us
> have any working knowledge of the OME library; apparently our
> implementation was written for us by Melissa Linkert.
> 
> Micro-Manager doesn't actually read the OME metadata itself; it's present
> solely so that other programs can load some of our metadata. We'd like to
> upgrade our libraries to something more modern, but documentation appears
> to be scarce, and I wouldn't really know where to get started. Any advice
> would be appreciated.
> 
> Thanks for your time.
> 
> -Chris Weisiger

> _______________________________________________
> ome-devel mailing list
> ome-devel at lists.openmicroscopy.org.uk
> http://lists.openmicroscopy.org.uk/mailman/listinfo/ome-devel



More information about the ome-devel mailing list