[ome-users] How to get information from image

David Gault (Staff) d.gault at dundee.ac.uk
Tue Dec 5 12:20:16 GMT 2017


Hi Qi,

In the Bio-Formats developer documentation we have a section on handling whole slide images which may be of interest to you:Working with whole slide images<https://docs.openmicroscopy.org/bio-formats/5.7.2/developers/wsi.html>
There is also a short example on reading sub resolutions: https://github.com/openmicroscopy/bioformats/blob/develop/components/formats-gpl/utils/SubResolutionExample.java

More generally, in Bio-Formats access to metadata is provided via the MetadataStore and MetadataRetrieve interfaces. In this instance we would use MetadataRetrieve to access getters for all of the available metadata in the OME-XML model objects.
MetadataRetrieve can be used as below and a full list of the available getters can be found at https://downloads.openmicroscopy.org/bio-formats/5.7.2/api/loci/formats/meta/MetadataRetrieve.html

ServiceFactory factory = new ServiceFactory();
OMEXMLService service = factory.getInstance(OMEXMLService.class);
MetadataRetrieve retrieve = service.asRetrieve(reader.getMetadataStore());

Additionally Bio-Formats also stores original metadata which is not a part of the OME-XML model as key value pairs. The metadata stored here will differ depending on the specific format being read. These values can be accessed using the FormatReader interface as shown below:

// to retrieve original metadata specific to the current series
Hashtable<String, Object> seriesMetadata = reader.getSeriesMetadata();

// to retrieve original metadata not unique to the series
Hashtable<String, Object> globalMetadata = reader.getGlobalMetadata();

I hope that is of help as a starting point but if there is still specific metadata fields which you are still unsure how to access please do let us know along with the format you are using and we can help further.

With Thanks,
David Gault

On 4 Dec 2017, at 21:36, Qi Gong <qigong at gwmail.gwu.edu<mailto:qigong at gwmail.gwu.edu>> wrote:

Hello everyone,

We use Bioformats to load whole slide imaging. Does anyone know what function we can use to get all WSI information (e.g. each level image size, apparent  magnification, MMP, Image Type, Image Depth, Compression Type, Compression Ratio, Organization...). Thank you.

Regards,
Qi

--
mobile phone: 2024060862
_______________________________________________
ome-users mailing list
ome-users at lists.openmicroscopy.org.uk<mailto:ome-users at lists.openmicroscopy.org.uk>
http://lists.openmicroscopy.org.uk/mailman/listinfo/ome-users


The University of Dundee is a registered Scottish Charity, No: SC015096
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openmicroscopy.org.uk/pipermail/ome-users/attachments/20171205/ab0f9742/attachment.html>


More information about the ome-users mailing list