I'm using an ontology for building profiles. Ontology instances are populated from mongodb. When I'm going to retrieve data through SPARQL queries it gives me an exception of parser error. So I can't get inferred information by querying the ontology. I'm using owlready2. What can I do for avoid this problem.
The exception is as follows:
It all went pear-shaped: Problem parsing file:///C:/Users/Yashoda/AppData/Local/Temp/tmptsmxo9hh
Could not parse ontology. Either a suitable parser could not be found, or parsing failed. See parser logs below for explanation.
The following parsers were tried:
1) RDFXMLParser
2) OWLXMLParser
3) OWLFunctionalSyntaxOWLParser
4) TurtleOntologyParser
5) OWLOBOParser
6) KRSS2OWLParser
7) ManchesterOWLSyntaxOntologyParser
Detailed logs:
--------------------------------------------------------------------------------
Parser: RDFXMLParser
org.xml.sax.SAXParseException; systemId: file:///C:/Users/Yashoda/AppData/Local/Temp/tmptsmxo9hh; lineNumber: 1; columnNumber: 8; Element type "http:" must be followed by either attribute specifications, ">" or "/>".
--------------------------------------------------------------------------------
Parser: OWLXMLParser
org.xml.sax.SAXParseException; systemId: file:///C:/Users/Yashoda/AppData/Local/Temp/tmptsmxo9hh; lineNumber: 1; columnNumber: 8; Element type "http:" must be followed by either attribute specifications, ">" or "/>".
--------------------------------------------------------------------------------
Parser: OWLFunctionalSyntaxOWLParser
Encountered " " "" at line 1, column 1.
Was expecting:
"Ontology" ...
(Line 0)
--------------------------------------------------------------------------------
Parser: TurtleOntologyParser
uk.ac.manchester.cs.owl.owlapi.turtle.parser.ParseException: Encountered " " "" at line 832, column 81.
Was expecting:
"." ...
--------------------------------------------------------------------------------
Parser: OWLOBOParser
org.coode.owlapi.obo.parser.ParseException: Encountered "" at line 1264, column 114.
Was expecting one of:
"[" ...
...
...
...
...
...
(Line 1264)
--------------------------------------------------------------------------------
Parser: KRSS2OWLParser
de.uulm.ecs.ai.owlapi.krssparser.ParseException: Encountered " ">" " "" at line 1, column 1.
Was expecting:
--------------------------------------------------------------------------------
Parser: ManchesterOWLSyntaxOntologyParser
Encountered at line 1 column 1. Expected one of:
Individual:
AnnotationProperty:
Datatype:
DataProperty:
ObjectProperty:
DisjointProperties:
ValuePartition:
EquivalentClasses:
Import:
Prefix:
DisjointClasses:
Class:
SameIndividual:
DifferentIndividuals:
(Line 1)
org.semanticweb.owlapi.io.UnparsableOntologyException: Problem parsing file:///C:/Users/Yashoda/AppData/Local/Temp/tmptsmxo9hh
Could not parse ontology. Either a suitable parser could not be found, or parsing failed. See parser logs below for explanation.
The following parsers were tried:
1) RDFXMLParser
2) OWLXMLParser
3) OWLFunctionalSyntaxOWLParser
4) TurtleOntologyParser
5) OWLOBOParser
6) KRSS2OWLParser
7) ManchesterOWLSyntaxOntologyParser
Detailed logs:
--------------------------------------------------------------------------------
Parser: RDFXMLParser
org.xml.sax.SAXParseException; systemId: file:///C:/Users/Yashoda/AppData/Local/Temp/tmptsmxo9hh; lineNumber: 1; columnNumber: 8; Element type "http:" must be followed by either attribute specifications, ">" or "/>".
--------------------------------------------------------------------------------
Parser: OWLXMLParser
org.xml.sax.SAXParseException; systemId: file:///C:/Users/Yashoda/AppData/Local/Temp/tmptsmxo9hh; lineNumber: 1; columnNumber: 8; Element type "http:" must be followed by either attribute specifications, ">" or "/>".
--------------------------------------------------------------------------------
Parser: OWLFunctionalSyntaxOWLParser
Encountered " " "" at line 1, column 1.
Was expecting:
"Ontology" ...
(Line 0)
--------------------------------------------------------------------------------
Parser: TurtleOntologyParser
uk.ac.manchester.cs.owl.owlapi.turtle.parser.ParseException: Encountered " " "" at line 832, column 81.
Was expecting:
"." ...
--------------------------------------------------------------------------------
Parser: OWLOBOParser
org.coode.owlapi.obo.parser.ParseException: Encountered "" at line 1264, column 114.
Was expecting one of:
"[" ...
...
...
...
...
...
(Line 1264)
--------------------------------------------------------------------------------
Parser: KRSS2OWLParser
de.uulm.ecs.ai.owlapi.krssparser.ParseException: Encountered " ">" " "" at line 1, column 1.
Was expecting:
--------------------------------------------------------------------------------
Parser: ManchesterOWLSyntaxOntologyParser
Encountered at line 1 column 1. Expected one of:
Individual:
AnnotationProperty:
Datatype:
DataProperty:
ObjectProperty:
DisjointProperties:
ValuePartition:
EquivalentClasses:
Import:
Prefix:
DisjointClasses:
Class:
SameIndividual:
DifferentIndividuals:
(Line 1)
at uk.ac.manchester.cs.owl.owlapi.ParsableOWLOntologyFactory.loadOWLOntology(ParsableOWLOntologyFactory.java:236)
at uk.ac.manchester.cs.owl.owlapi.OWLOntologyManagerImpl.loadOntology(OWLOntologyManagerImpl.java:880)
at uk.ac.manchester.cs.owl.owlapi.OWLOntologyManagerImpl.loadOntology(OWLOntologyManagerImpl.java:800)
at uk.ac.manchester.cs.owl.owlapi.OWLOntologyManagerImpl.loadOntology(OWLOntologyManagerImpl.java:758)
at org.semanticweb.HermiT.cli.CommandLine.main(CommandLine.java:771)