The OME Data Model is now decoupled from the Bio-Formats code repository and available as a stand-alone ome-model GitHub repository.
There are sample files, along with an explanation of their structure, on the Sample image files page.
OME Model development process¶
The Model development process is currently being revised but we always aim to keep the community informed of major and breaking changes in advance. See the Contributing Developer documentation for further details on updating and publishing the schema.
Working with the OME Data Model¶
The Model Overview collection of diagrams shows the structure and connections between different parts of the OME Model. Generated documentation for the current version of the entire Schema is also available.
Individual parts of the model are covered in more detail in the following sections:
Screen Plate Well - our HCS solution
Support for additional dimensions is also covered:
Map Annotations, storing ‘key-value pairs’, are a type of Structured Annotation which were introduced in the Changes for January 2015. Further information is available in the OMERO developer documentation on Key-value pairs and a sample OME-XML file is also available.
Legacy solutions for tiled images and Single (or Selective) Plane Illumination Microscopy (also known as Light Sheet Microscopy) are detailed in the following sections for reference but both these methods have been superseded by the above:
The use of IDs and Life Science Identifiers is explained in this section:
The system of units used by the model is covered in this section:
The Schema versions section shows the Model changes with each release, helpful for those working with several versions of the OME Model, for example to support the loading/saving of a variety of files.
The current major release - see Changes For June 2016.
For further information, see the OME Data Model section in the OMERO developer documentation.
Working with OME-XML¶
In some cases, it is useful to extract specific parameters or tweak certain values in a dataset’s OME-XML metadata block. Further guidance on Using OME-XML schema elements is available, but below is a brief example of the OMEXMLMetadata class (which implements the MetadataStore and MetadataRetrieve interfaces) to greatly simplify OME-XML-related development tasks.
As in the ConvertToOmeTiff.java example in OME-TIFF example source code for common operations, we attach an
OME-XML MetadataStore object to the reader to extract OME-XML metadata from
the input file. We obtain the current image name (if any) by calling the
omexmlMeta.getImageName(0) method. The zero indicates the Image within
the OME-XML block we are interested in; in this case, we are
asking for the name of the first Image.
After updating the name somehow (in our case, reversing the string), we
write the updated name back into the metadata structure via a call to
omexmlMeta.setImageName(name, 0). Once again the zero indicates that we
wish to update the first Image.
Lastly, the loci.formats.services.OMEXMLService class contains a number of useful methods for working with Bio-Formats metadata objects (i.e. MetadataStore and MetadataRetrieve implementations), including the getOMEXML method for easily extracting an OME-XML string from a MetadataRetrieve object (which we utilize above), as well as the convertMetadata method for transcoding between metadata object implementations. You can obtain an OMEXMLService object as follows:
ServiceFactory factory = new ServiceFactory(); OMEXMLService service = factory.getInstance(OMEXMLService.class);