I am using owl ontology for semantic analysis in emotional sentiment analysis project , I am trying to navigate the ontology to check a concepts and its relation , my ontology has classes like this :
<!-- http://purl.obolibrary.org/obo/MFOEM_000011 -->
<owl:Class rdf:about="http://purl.obolibrary.org/obo/MFOEM_000011">
<rdfs:subClassOf rdf:resource="http://purl.obolibrary.org/obo/MFOEM_000001" />
<rdfs:subClassOf>
<owl:Restriction>
<owl:onProperty rdf:resource="http://purl.obolibrary.org/obo/BFO_0000117" />
<owl:someValuesFrom rdf:resource="http://purl.obolibrary.org/obo/MFOEM_000208" />
</owl:Restriction>
</rdfs:subClassOf>
<obo:IAO_0000115>An unpleasant emotion closely related to anger but lower in intensity and without the moral dimension of blame and seriousness that is implicated in anger. [Source: OCEAS]</obo:IAO_0000115>
<obo:MFOEM_000010 xml:lang="es">irritación</obo:MFOEM_000010>
<obo:MFOEM_000010 xml:lang="fr">irritation</obo:MFOEM_000010>
<obo:MFOEM_000010 xml:lang="de">Ärger</obo:MFOEM_000010>
<obo:MFOEM_000165>irritated</obo:MFOEM_000165>
<rdfs:label>irritation</rdfs:label>
</owl:Class>
I am using this code to retrieve concepts from triples s,p,o :
from rdflib.namespace import RDF, RDFS, OWL ,FOAF
from pprint import pprint
properties2=set()
for p in g.subjects():
properties2.add(p)
pprint(properties2)
and the output is something like this :
rdflib.term.URIRef('http://purl.obolibrary.org/obo/MFOEM_000221')
rdflib.term.URIRef('http://purl.obolibrary.org/obo/MFOEM_000222')
rdflib.term.URIRef('http://purl.obolibrary.org/obo/MFOEM_000223')
rdflib.term.URIRef('http://purl.obolibrary.org/obo/MF_0000020')
rdflib.term.URIRef('http://purl.obolibrary.org/obo/MF_0000029')
rdflib.term.URIRef('http://purl.obolibrary.org/obo/MF_0000031')
rdflib.term.URIRef('http://purl.obolibrary.org/obo/MF_0000039')
rdflib.term.URIRef('http://purl.obolibrary.org/obo/NBO_0000003')
rdflib.term.URIRef('http://purl.obolibrary.org/obo/comment')
rdflib.term.URIRef('http://purl.org/dc/elements/1.1/contributor')
rdflib.term.URIRef('http://purl.org/dc/elements/1.1/title')
rdflib.term.URIRef('http://www.w3.org/2000/01/rdf-schema#comment')
rdflib.term.URIRef('http://www.w3.org/2000/01/rdf-schema#label')}
but ,it return URIRef instead of the concept value can anyone help me to understand why it returns that and how can I get the actual concepts behind of URI excuse me if I have misunderstanding but , I am new in this topic and i did a hard googling and didn't find any reslut