[ome-users] Errors importing MSR files

David Gault (Staff) d.gault at dundee.ac.uk
Tue Jan 9 14:18:55 GMT 2018


Hi Nick,

Thank you for providing the sample files for testing. There are a few different messages in the log provided, I will try and briefly explain each of these and the possible ramifications they may have on the imported file.

With the files provided the SAXParseException is being thrown when the embedded Description tag is attempted to be parsed as XML. If the Description is not XML then Bio-Formats handles this by adding the value to the series metadata, in the case of the sample files provided this will show in the metadata as “Description = overview”. This particular warning should have no negative effects on the parsed metadata.

The SAXParser warnings for features and properties not being recognised are related to certain versions of the Xerces library. These warnings can be ignored from your perspective and will not impact on the parsing of metadata values.

Finally the validation error reported as duplicate key entries is occurring when attempting to parse OME-XML which is embedded in the file. If the embedded XML is valid then Bio-Formats will parse and use the data provided, however in this particular case the XML is not valid due to each of the 4 channels having an identical ID. If the embedded XML is not valid then Bio-Formats will attempt to read the file and rebuild a valid OME-XML metadata. In this particular scenario comparing the values of the embedded XML and the new generated XML show that the results are very similar and that the metadata for the file appears to have been read and generated successfully. The important difference would be the valid unique ID values now being used for each channel as shown below:
<Channel ID=“Channel:0:0”  SamplesPerPixel=“1”><LightPath/></Channel>
<Channel ID=“Channel:1:0”  SamplesPerPixel=“1”><LightPath/></Channel>
<Channel ID=“Channel:2:0”  SamplesPerPixel=“1”><LightPath/></Channel>
<Channel ID=“Channel:3:0”  SamplesPerPixel=“1”><LightPath/></Channel>


With Thanks,
David Gault

On 8 Jan 2018, at 16:03, Nick Petersen <EPeterse at scripps.edu<mailto:EPeterse at scripps.edu>> wrote:

I am using the most updated version of the Abberior STED microscope software and I’m getting the following errors when I try and import the files:

[WARN] Could not parse description as XML
org.xml.sax.SAXParseException: Content is not allowed in prolog.
              at org.apache.xerces.parsers.DOMParser.parse(Unknown Source)
              at org.apache.xerces.jaxp.DocumentBuilderImpl.parse(Unknown Source)
              at javax.xml.parsers.DocumentBuilder.parse(DocumentBuilder.java:121)
              at loci.common.xml.XMLTools.parseDOM(XMLTools.java:215)
              at loci.common.xml.XMLTools.parseDOM(XMLTools.java:196)
              at loci.formats.in.OBFReader.initStack(OBFReader.java:379)
              at loci.formats.in.OBFReader.initFile(OBFReader.java:184)
              at loci.formats.FormatReader.setId(FormatReader.java:1397)
              at loci.plugins.in.ImportProcess.initializeFile(ImportProcess.java:498)
              at loci.plugins.in.ImportProcess.execute(ImportProcess.java:141)
              at loci.plugins.in.Importer.showDialogs(Importer.java:140)
              at loci.plugins.in.Importer.run(Importer.java:76)
              at loci.plugins.LociImporter.run(LociImporter.java:78)
              at ij.IJ.runUserPlugIn(IJ.java:221)
              at ij.IJ.runPlugIn(IJ.java:185)
              at ij.IJ.runPlugIn(IJ.java:174)
              at HandleExtraFileTypes.openImage(HandleExtraFileTypes.java:499)
              at HandleExtraFileTypes.run(HandleExtraFileTypes.java:72)
              at ij.IJ.runUserPlugIn(IJ.java:221)
              at ij.IJ.runPlugIn(IJ.java:185)
              at ij.IJ.runPlugIn(IJ.java:174)
              at ij.io.Opener.openWithHandleExtraFileTypes(Opener.java:515)
              at ij.io.Opener.openImage(Opener.java:369)
              at ij.io.Opener.openImage(Opener.java:242)
              at ij.io.Opener.open(Opener.java:109)
              at ij.io.Opener.openAndAddToRecent(Opener.java:291)
              at ij.plugin.DragAndDrop.openFile(DragAndDrop.java:192)
              at ij.plugin.DragAndDrop.run(DragAndDrop.java:159)
              at java.lang.Thread.run(Thread.java:745)
Warning:  org.apache.xerces.jaxp.SAXParserImpl$JAXPSAXParser: Property 'http://www.oracle.com/xml/jaxp/properties/entityExpansionLimit'is not recognized.
Warning:  org.apache.xerces.parsers.SAXParser: Feature 'http://javax.xml.XMLConstants/feature/secure-processing'<http://javax.xml.xmlconstants/feature/secure-processing'> is not recognized.
Warning:  org.apache.xerces.parsers.SAXParser: Property 'http://javax.xml.XMLConstants/property/accessExternalDTD'<http://javax.xml.xmlconstants/property/accessExternalDTD'> is not recognized.
Warning:  org.apache.xerces.parsers.SAXParser: Property 'http://www.oracle.com/xml/jaxp/properties/entityExpansionLimit' is not recognized.
Parsing schema path
http://www.openmicroscopy.org/Schemas/OME/2016-06/ome.xsd
Validating OME-XML
[ERROR] cvc-identity-constraint.4.2.2: Duplicate key value [Channel:1] declared for identity constraint "ChannelIDKey" of element "OME".
[ERROR] cvc-identity-constraint.4.2.2: Duplicate key value [Channel:1] declared for identity constraint "ChannelIDKey" of element "OME".
[ERROR] cvc-identity-constraint.4.2.2: Duplicate key value [Channel:1] declared for identity constraint "ChannelIDKey" of element "OME".
Error validating document: 3 errors found
Reading header
Finding image offsets
[WARN] Unknown Immersion value 'null' will be stored as "Other"
[WARN] Unknown Correction value 'null' will be stored as "Other"
[WARN] Unknown Immersion value 'null' will be stored as "Other"
[WARN] Unknown Correction value 'null' will be stored as "Other"
[WARN] Unknown Immersion value 'null' will be stored as "Other"
[WARN] Unknown Correction value 'null' will be stored as "Other"
[WARN] Unknown Immersion value 'null' will be stored as "Other"
[WARN] Unknown Correction value 'null' will be stored as "Other"
[WARN] Could not parse description as XML
org.xml.sax.SAXParseException: Content is not allowed in prolog.
              at org.apache.xerces.parsers.DOMParser.parse(Unknown Source)
              at org.apache.xerces.jaxp.DocumentBuilderImpl.parse(Unknown Source)
              at javax.xml.parsers.DocumentBuilder.parse(DocumentBuilder.java:121)
              at loci.common.xml.XMLTools.parseDOM(XMLTools.java:215)
              at loci.common.xml.XMLTools.parseDOM(XMLTools.java:196)
              at loci.formats.in.OBFReader.initStack(OBFReader.java:379)
              at loci.formats.in.OBFReader.initFile(OBFReader.java:184)
              at loci.formats.FormatReader.setId(FormatReader.java:1397)
              at loci.plugins.in.ImportProcess.initializeFile(ImportProcess.java:498)
              at loci.plugins.in.ImportProcess.execute(ImportProcess.java:141)
              at loci.plugins.in.Importer.showDialogs(Importer.java:140)
              at loci.plugins.in.Importer.run(Importer.java:76)
              at loci.plugins.LociImporter.run(LociImporter.java:78)
              at ij.IJ.runUserPlugIn(IJ.java:221)
              at ij.IJ.runPlugIn(IJ.java:185)
              at ij.IJ.runPlugIn(IJ.java:174)
              at HandleExtraFileTypes.openImage(HandleExtraFileTypes.java:499)
              at HandleExtraFileTypes.run(HandleExtraFileTypes.java:72)
              at ij.IJ.runUserPlugIn(IJ.java:221)
              at ij.IJ.runPlugIn(IJ.java:185)
              at ij.IJ.runPlugIn(IJ.java:174)
              at ij.io.Opener.openWithHandleExtraFileTypes(Opener.java:515)
              at ij.io.Opener.openImage(Opener.java:369)
              at ij.io.Opener.openImage(Opener.java:242)
              at ij.io.Opener.open(Opener.java:109)
              at ij.io.Opener.openAndAddToRecent(Opener.java:291)
              at ij.plugin.DragAndDrop.openFile(DragAndDrop.java:192)
              at ij.plugin.DragAndDrop.run(DragAndDrop.java:159)
              at java.lang.Thread.run(Thread.java:745)
Warning:  org.apache.xerces.parsers.SAXParser: Feature 'http://javax.xml.XMLConstants/feature/secure-processing'<http://javax.xml.xmlconstants/feature/secure-processing'> is not recognized.
Warning:  org.apache.xerces.parsers.SAXParser: Property 'http://javax.xml.XMLConstants/property/accessExternalDTD'<http://javax.xml.xmlconstants/property/accessExternalDTD'> is not recognized.
Warning:  org.apache.xerces.parsers.SAXParser: Property 'http://www.oracle.com/xml/jaxp/properties/entityExpansionLimit' is not recognized.
Parsing schema path
http://www.openmicroscopy.org/Schemas/OME/2016-06/ome.xsd
Validating OME-XML
[ERROR] cvc-identity-constraint.4.2.2: Duplicate key value [Channel:1] declared for identity constraint "ChannelIDKey" of element "OME".
[ERROR] cvc-identity-constraint.4.2.2: Duplicate key value [Channel:1] declared for identity constraint "ChannelIDKey" of element "OME".
[ERROR] cvc-identity-constraint.4.2.2: Duplicate key value [Channel:1] declared for identity constraint "ChannelIDKey" of element "OME".
Error validating document: 3 errors found
[WARN] Could not parse description as XML
org.xml.sax.SAXParseException: Content is not allowed in prolog.
              at org.apache.xerces.parsers.DOMParser.parse(Unknown Source)
              at org.apache.xerces.jaxp.DocumentBuilderImpl.parse(Unknown Source)
              at javax.xml.parsers.DocumentBuilder.parse(DocumentBuilder.java:121)
              at loci.common.xml.XMLTools.parseDOM(XMLTools.java:215)
              at loci.common.xml.XMLTools.parseDOM(XMLTools.java:196)
              at loci.formats.in.OBFReader.initStack(OBFReader.java:379)
              at loci.formats.in.OBFReader.initFile(OBFReader.java:184)
              at loci.formats.FormatReader.setId(FormatReader.java:1397)
              at loci.plugins.in.ImportProcess.initializeFile(ImportProcess.java:498)
              at loci.plugins.in.ImportProcess.execute(ImportProcess.java:141)
              at loci.plugins.in.Importer.showDialogs(Importer.java:140)
              at loci.plugins.in.Importer.run(Importer.java:76)
              at loci.plugins.LociImporter.run(LociImporter.java:78)
              at ij.IJ.runUserPlugIn(IJ.java:221)
              at ij.IJ.runPlugIn(IJ.java:185)
              at ij.IJ.runPlugIn(IJ.java:174)
              at HandleExtraFileTypes.openImage(HandleExtraFileTypes.java:499)
              at HandleExtraFileTypes.run(HandleExtraFileTypes.java:72)
              at ij.IJ.runUserPlugIn(IJ.java:221)
              at ij.IJ.runPlugIn(IJ.java:185)
              at ij.IJ.runPlugIn(IJ.java:174)
              at ij.io.Opener.openWithHandleExtraFileTypes(Opener.java:515)
              at ij.io.Opener.openImage(Opener.java:369)
              at ij.io.Opener.openImage(Opener.java:242)
              at ij.io.Opener.open(Opener.java:109)
              at ij.io.Opener.openAndAddToRecent(Opener.java:291)
              at ij.plugin.DragAndDrop.openFile(DragAndDrop.java:192)
              at ij.plugin.DragAndDrop.run(DragAndDrop.java:159)
              at java.lang.Thread.run(Thread.java:745)
Warning:  org.apache.xerces.parsers.SAXParser: Feature 'http://javax.xml.XMLConstants/feature/secure-processing'<http://javax.xml.xmlconstants/feature/secure-processing'> is not recognized.
Warning:  org.apache.xerces.parsers.SAXParser: Property 'http://javax.xml.XMLConstants/property/accessExternalDTD'<http://javax.xml.xmlconstants/property/accessExternalDTD'> is not recognized.
Warning:  org.apache.xerces.parsers.SAXParser: Property 'http://www.oracle.com/xml/jaxp/properties/entityExpansionLimit' is not recognized.
Parsing schema path
http://www.openmicroscopy.org/Schemas/OME/2016-06/ome.xsd
Validating OME-XML
[ERROR] cvc-identity-constraint.4.2.2: Duplicate key value [Channel:1] declared for identity constraint "ChannelIDKey" of element "OME".
[ERROR] cvc-identity-constraint.4.2.2: Duplicate key value [Channel:1] declared for identity constraint "ChannelIDKey" of element "OME".
[ERROR] cvc-identity-constraint.4.2.2: Duplicate key value [Channel:1] declared for identity constraint "ChannelIDKey" of element "OME".
Error validating document: 3 errors found
[WARN] Could not parse description as XML
org.xml.sax.SAXParseException: Content is not allowed in prolog.
              at org.apache.xerces.parsers.DOMParser.parse(Unknown Source)
              at org.apache.xerces.jaxp.DocumentBuilderImpl.parse(Unknown Source)
              at javax.xml.parsers.DocumentBuilder.parse(DocumentBuilder.java:121)
              at loci.common.xml.XMLTools.parseDOM(XMLTools.java:215)
              at loci.common.xml.XMLTools.parseDOM(XMLTools.java:196)
              at loci.formats.in.OBFReader.initStack(OBFReader.java:379)
              at loci.formats.in.OBFReader.initFile(OBFReader.java:184)
              at loci.formats.FormatReader.setId(FormatReader.java:1397)
              at loci.plugins.in.ImportProcess.initializeFile(ImportProcess.java:498)
              at loci.plugins.in.ImportProcess.execute(ImportProcess.java:141)
              at loci.plugins.in.Importer.showDialogs(Importer.java:140)
              at loci.plugins.in.Importer.run(Importer.java:76)
              at loci.plugins.LociImporter.run(LociImporter.java:78)
              at ij.IJ.runUserPlugIn(IJ.java:221)
              at ij.IJ.runPlugIn(IJ.java:185)
              at ij.IJ.runPlugIn(IJ.java:174)
              at HandleExtraFileTypes.openImage(HandleExtraFileTypes.java:499)
              at HandleExtraFileTypes.run(HandleExtraFileTypes.java:72)
              at ij.IJ.runUserPlugIn(IJ.java:221)
              at ij.IJ.runPlugIn(IJ.java:185)
              at ij.IJ.runPlugIn(IJ.java:174)
              at ij.io.Opener.openWithHandleExtraFileTypes(Opener.java:515)
              at ij.io.Opener.openImage(Opener.java:369)
              at ij.io.Opener.openImage(Opener.java:242)
              at ij.io.Opener.open(Opener.java:109)
              at ij.io.Opener.openAndAddToRecent(Opener.java:291)
              at ij.plugin.DragAndDrop.openFile(DragAndDrop.java:192)
              at ij.plugin.DragAndDrop.run(DragAndDrop.java:159)
              at java.lang.Thread.run(Thread.java:745)
Warning:  org.apache.xerces.parsers.SAXParser: Feature 'http://javax.xml.XMLConstants/feature/secure-processing'<http://javax.xml.xmlconstants/feature/secure-processing'> is not recognized.
Warning:  org.apache.xerces.parsers.SAXParser: Property 'http://javax.xml.XMLConstants/property/accessExternalDTD'<http://javax.xml.xmlconstants/property/accessExternalDTD'> is not recognized.
Warning:  org.apache.xerces.parsers.SAXParser: Property 'http://www.oracle.com/xml/jaxp/properties/entityExpansionLimit' is not recognized.
Parsing schema path
http://www.openmicroscopy.org/Schemas/OME/2016-06/ome.xsd
Validating OME-XML
[ERROR] cvc-identity-constraint.4.2.2: Duplicate key value [Channel:1] declared for identity constraint "ChannelIDKey" of element "OME".
[ERROR] cvc-identity-constraint.4.2.2: Duplicate key value [Channel:1] declared for identity constraint "ChannelIDKey" of element "OME".
[ERROR] cvc-identity-constraint.4.2.2: Duplicate key value [Channel:1] declared for identity constraint "ChannelIDKey" of element "OME".
Error validating document: 3 errors found



I have updated Bio-Formats to the most recent version (5.7.2) and still get this error.  The images still open but I’m not sure if I’m losing more than metadata from the errors above. I have also updated Java to ensure the problem wasn’t there. I have attached 2 example files to replicate the issue

Thanks for the help!
<MSR files.zip>_______________________________________________
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/20180109/de218965/attachment.html>


More information about the ome-users mailing list